/* POP spatial — compact toolbox and responsive device simulator. */
.spatial-dock{width:min(535px,calc(100% - 20px - env(safe-area-inset-left,0px) - env(safe-area-inset-right,0px)));grid-template-columns:repeat(4,minmax(0,1fr));}
.spatial-dock .dock-action,.spatial-dock .pop-chat-launch{font-size:clamp(11px,3.1vw,14px);padding-inline:2px;letter-spacing:0;gap:3px}
#toolbox-panel[hidden],.device-view[hidden],#device-browser-frame[hidden],#device-browser-landing[hidden],#device-browser-notice[hidden],#device-boot[hidden]{display:none!important}
#toolbox-panel{position:absolute;bottom:calc(100% + 8px);right:0;width:min(100%,400px);max-height:calc(var(--pop-vh,100dvh) - 98px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));overflow:auto;overscroll-behavior:contain;touch-action:pan-y;padding:13px;border:1px solid #70dfff99;border-radius:14px;background:#071724f7;box-shadow:0 14px 35px #0008;color:#fff;font:13px/1.45 system-ui,sans-serif}
.toolbox-header{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:9px}.toolbox-header h2{font-size:17px;margin:0}.toolbox-header small{display:block;color:#a1c6d7;margin-top:3px}
.toolbox-header button,#device-dialog button,#device-dialog a.device-action{cursor:pointer;touch-action:manipulation}.toolbox-header button{color:#ecf9ff;background:#183448;border:1px solid #7ad9ff55;border-radius:8px;width:42px;height:42px;font-size:22px}
.toolbox-options{display:grid;grid-template-columns:1fr 1fr;gap:8px}.toolbox-choice{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:6px;text-align:left;background:linear-gradient(145deg,#14334a,#0b1b29);border:1px solid #79ccf85e;border-radius:10px;color:#fff;min-height:94px;padding:12px;cursor:pointer;font:600 14px system-ui,sans-serif}.toolbox-choice small{color:#b9d4e2;font-size:11px;font-weight:400}.toolbox-choice svg{width:30px;height:30px;stroke:#b4efff;stroke-width:1.6;fill:none}.toolbox-note{margin:10px 0 0;color:#9db5c4;font-size:11px}
#device-dialog{position:fixed;inset:0;width:100%;height:100%;height:var(--pop-vh,100dvh);max-width:none;max-height:none;margin:0;padding:0;border:0;overflow:hidden;background:transparent;color:#f5faff;box-sizing:border-box;font:14px/1.35 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;overscroll-behavior:contain}
#device-dialog:not([open]){display:none}#device-dialog::backdrop{background:rgba(2,9,17,.68);backdrop-filter:blur(7px)}
.device-stage{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;box-sizing:border-box;padding:max(8px,env(safe-area-inset-top,0px)) max(10px,env(safe-area-inset-right,0px)) max(10px,env(safe-area-inset-bottom,0px)) max(10px,env(safe-area-inset-left,0px));perspective:1200px;overflow:hidden}
.device-world-bar{flex:0 0 auto;display:flex;justify-content:space-between;align-items:center;width:min(96%,880px);gap:10px;color:#f4fbff}.device-world-bar strong{font-size:13px;letter-spacing:.06em}.device-world-bar small{display:block;font-size:10px;color:#c0d0dd;margin-top:2px}.device-world-bar button{min-height:40px;padding:8px 13px;border:1px solid #8cdaed99;border-radius:8px;background:#06182bec;color:#fff;font:700 13px system-ui,sans-serif;white-space:nowrap}
.device-rig{position:relative;display:flex;flex-direction:column;align-items:center;min-height:0;transform-style:preserve-3d;flex:0 1 auto;width:min(100%,880px);animation:device-pull .48s cubic-bezier(.2,.8,.18,1) both}
@keyframes device-pull{from{opacity:0;transform:translate3d(0,45vh,-220px) rotateX(19deg) rotateZ(-6deg)}to{opacity:1;transform:translate3d(0,0,0) rotateX(0) rotateZ(0)}}
.device-lid{position:relative;min-height:0;display:flex;flex-direction:column;border:1px solid #8195a5;border-radius:14px;padding:12px 10px 11px;background:linear-gradient(145deg,#344555 0,#121a24 36%,#080e15 72%,#344353);box-shadow:0 17px 36px #0009,inset 0 1px 1px #c3d1dd55;box-sizing:border-box;width:100%;height:min(66vh,580px);height:min(66dvh,580px);transform-origin:50% 100%;transform-style:preserve-3d;overflow:hidden}
#device-dialog[data-device=laptop] .device-lid{animation:device-lid-open .7s .12s cubic-bezier(.22,.72,.2,1) both}
@keyframes device-lid-open{from{transform:rotateX(-86deg)}to{transform:rotateX(0deg)}}
.device-camera{position:absolute;top:4px;left:50%;width:5px;height:5px;border-radius:50%;background:#668aa6;box-shadow:0 0 0 2px #111a22;z-index:3}
.device-screen{position:relative;display:flex;flex-direction:column;flex:1;min-height:0;overflow:hidden;isolation:isolate;background:#081729;border-radius:5px;color:#eaf4fa;border:1px solid #364c60}
.device-deck{display:block;width:calc(100% + 32px);height:clamp(28px,10vh,95px);height:clamp(28px,10dvh,95px);position:relative;transform-origin:50% 0;transform:rotateX(50deg);margin-top:-1px;border:1px solid #647787;background:linear-gradient(180deg,#455768,#222d37 52%,#81929f);border-radius:0 0 19px 19px;box-shadow:0 8px 16px #000a;flex:none}
.device-deck:before{content:"";position:absolute;inset:7% 12% 36%;border:4px solid #29333d;border-radius:4px;background:repeating-linear-gradient(90deg,transparent 0 6.8%,#2e3a45 6.8% 7.6%),repeating-linear-gradient(0deg,#111a23 0 26%,#34424e 26% 33%);box-shadow:inset 0 2px 3px #000}
.device-deck:after{content:"";position:absolute;bottom:6%;height:27%;left:40%;right:40%;border:1px solid #1a2632;border-radius:3px;background:#516371}
#device-dialog[data-device=phone] .device-rig{width:min(100%,350px);max-height:calc(var(--pop-vh,100dvh) - 74px)}
#device-dialog[data-device=phone] .device-lid{height:min(75dvh,650px);height:min(75vh,650px);height:min(75dvh,650px);border-radius:34px;padding:19px 8px 12px;border:2px solid #77899b;box-shadow:0 18px 38px #000b,inset 0 0 0 2px #15202a}
#device-dialog[data-device=phone] .device-screen{border-radius:22px}#device-dialog[data-device=phone] .device-camera{top:6px;width:38px;height:6px;border-radius:8px;background:#02070c;box-shadow:inset 0 1px 1px #5e718a}#device-dialog[data-device=phone] .device-deck{display:none}
#device-boot{position:absolute;inset:0;background:#050d18;z-index:9;display:grid;place-content:center;text-align:center;color:#e9f9ff;letter-spacing:.1em;font-weight:650}.boot-mark{display:block;margin:auto auto 14px;width:34px;height:34px;border-radius:50%;border:2px solid #567b99;border-top-color:#b0eaff;animation:device-spin .6s linear infinite}@keyframes device-spin{to{transform:rotate(360deg)}}
.device-view{height:100%;min-height:0;display:flex;flex-direction:column;overflow:hidden}.device-desktop{position:relative;background:radial-gradient(ellipse at 82% 36%,#3689bf 0,transparent 35%),radial-gradient(ellipse at 56% 79%,#174b85 0,transparent 60%),linear-gradient(142deg,#08192d,#0e3154 55%,#102444);isolation:isolate}.device-desktop:after{content:"";position:absolute;z-index:-1;width:140%;height:75%;top:25%;left:16%;background:linear-gradient(165deg,transparent 0 23%,#64bce72e 24% 31%,#b0efff55 32% 34%,#367dba25 35% 64%,transparent 65%);transform:rotate(-32deg);border-radius:50%;filter:blur(1px)}
.device-statusline{display:flex;justify-content:space-between;align-items:center;padding:9px 12px;color:#effaff;font-size:11px;font-weight:600;flex:none}.device-statusline span:last-child{letter-spacing:.12em}.desktop-heading{padding:14px 17px 4px}.desktop-heading h2{margin:0;font-size:clamp(18px,4vw,28px);font-weight:650;letter-spacing:-.04em}.desktop-heading p{margin:4px 0 0;color:#bdd5e8;font-size:11px}.desktop-icons{display:grid;grid-template-columns:repeat(auto-fill,minmax(105px,128px));align-content:start;gap:8px;padding:13px;overflow:auto;flex:1;min-height:0}.desktop-shortcut{background:#ebf7ff0c;border:1px solid transparent;border-radius:10px;color:#fff;text-align:center;display:flex;align-items:center;flex-direction:column;gap:6px;min-height:88px;padding:9px 5px;font:600 12px system-ui,sans-serif;overflow-wrap:anywhere}.desktop-shortcut:hover,.desktop-shortcut:focus-visible{border-color:#a8ddff;background:#d7f2ff25}.desktop-shortcut svg{width:42px;height:42px;filter:drop-shadow(0 3px 6px #0006)}.desktop-shortcut small{font-size:10px;color:#c0d6e6;font-weight:400}.device-taskbar{display:flex;align-items:center;justify-content:center;gap:7px;padding:5px 8px;background:#071725c9;border-top:1px solid #d8f7ff26;flex:none}.device-taskbar button{min-height:34px;padding:4px 10px;border:1px solid #91bce055;border-radius:6px;background:#ffffff0b;color:white;font:600 11px system-ui,sans-serif}.device-taskbar span{margin-left:auto;font-size:10px;color:#b6cfe3}.device-taskbar svg{width:17px;height:17px;vertical-align:middle}
#device-dialog[data-device=phone] .desktop-icons{grid-template-columns:repeat(2,minmax(0,1fr));align-content:start}.device-browser{background:#f5f7fb;color:#172b42}.device-browser-bar{background:#e6edf7;color:#152a41;display:flex;align-items:center;gap:6px;padding:7px;border-bottom:1px solid #cbd4df;flex:none}.device-browser-bar button{background:#fff;border:1px solid #b7c6d9;border-radius:7px;padding:5px 8px;min-height:32px;color:#253b54;font-size:12px;white-space:nowrap}.device-browser-bar strong{font-size:12px;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.device-address-form{display:flex;align-items:center;gap:5px;padding:7px;background:#f5f7fb;border-bottom:1px solid #d7dfeb;flex:none;min-width:0}.device-address-form input{width:100%;min-width:0;flex:1;font:14px/1.1 system-ui,sans-serif;border:1px solid #b7c7d7;background:white;color:#142638;border-radius:18px;padding:9px 10px;box-sizing:border-box;touch-action:manipulation}.device-address-form button{min-height:36px;border:0;background:#1766bb;color:#fff;border-radius:8px;padding:0 12px;font:700 12px system-ui,sans-serif}.device-browser-content{position:relative;display:flex;flex-direction:column;flex:1;min-height:0;overflow:hidden}.device-browser-landing{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:14px;overflow:auto;text-align:center;color:#25425b}.device-browser-landing svg{width:50px;height:50px;flex:none}.device-browser-landing h3{margin:0;font-size:17px}.device-browser-landing p{font-size:12px;max-width:330px;margin:0;color:#51667b;line-height:1.5}.device-bookmarks{display:flex;flex-wrap:wrap;justify-content:center;gap:6px}.device-bookmarks button,.device-action{display:inline-flex;align-items:center;justify-content:center;min-height:34px;box-sizing:border-box;padding:6px 9px;border:1px solid #aebed2;border-radius:7px;background:white;color:#183c62;font:600 12px system-ui,sans-serif;text-decoration:none;cursor:pointer}.device-browser-notice{background:#e9f0f8;border-bottom:1px solid #cad7e5;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:5px;padding:6px 8px;font-size:11px;flex:none;color:#334d65}.device-browser-notice p{margin:0;flex:1 1 140px;overflow-wrap:anywhere}#device-external{min-height:30px;white-space:nowrap}#device-browser-frame{border:0;width:100%;flex:1;min-height:0;background:#fff}.device-view a:focus-visible,.device-view button:focus-visible,#device-close:focus-visible,#toolbox-panel button:focus-visible{outline:2px solid #48b9ef;outline-offset:2px}.device-archive-note{font-weight:600;color:#194e77}
@media(max-width:480px){#device-dialog[data-device=laptop] .device-lid{height:min(71dvh,590px);padding:10px 6px 8px}.device-stage{gap:6px}.device-world-bar strong{font-size:12px}.device-deck{width:calc(100% + 8px)}.desktop-icons{grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;padding:8px}.desktop-heading{padding:10px 12px 2px}.desktop-shortcut{min-height:74px}.desktop-shortcut svg{width:35px;height:35px}.device-taskbar{gap:4px;padding:4px}.device-taskbar button{padding-inline:6px}.device-browser-bar button{font-size:11px;padding:4px 6px}.device-address-form input{font-size:16px}}
@media(max-height:460px){.device-stage{gap:4px}.device-world-bar button{min-height:34px;padding-block:5px}.device-world-bar small{display:none}#device-dialog[data-device=laptop] .device-lid{height:calc(var(--pop-vh,100dvh) - 95px);height:calc(var(--pop-vh,100dvh) - 95px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px))}.device-deck{height:28px}#device-dialog[data-device=phone] .device-lid{height:calc(var(--pop-vh,100dvh) - 62px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));border-radius:23px;padding:12px 5px 7px}#device-dialog[data-device=phone] .device-screen{border-radius:13px}.desktop-heading{padding:5px 12px 1px}.desktop-heading h2{font-size:18px}.desktop-heading p{display:none}.desktop-icons{padding:5px 9px}.desktop-shortcut{min-height:63px;padding:5px}.desktop-shortcut svg{width:28px;height:28px}.device-statusline{padding:4px 9px}.device-browser-landing{padding:8px;gap:5px}.device-browser-landing svg{width:32px;height:32px}.device-browser-bar,.device-address-form{padding:4px}.device-browser-notice{padding:4px}}
@media(prefers-reduced-motion:reduce){.device-rig,#device-dialog[data-device=laptop] .device-lid,.boot-mark{animation:none!important}}
.desktop-shortcut[hidden],#device-external[hidden]{display:none!important}
