/* ZEROBOUND: original light adventure, not a dashboard. */
:root{--ink:#263e50;--muted:#667a87;--accent:#bf5c39;--line:#dce3e6;--paper:#faf9f5}body{background:var(--paper);color:var(--ink)}button,input,textarea,select{font:inherit}button{touch-action:manipulation}button:focus-visible,textarea:focus-visible,canvas:focus-visible{outline:3px solid #c87835;outline-offset:4px}.primary{background:#294f65;border-color:#294f65;box-shadow:0 4px 0 #1a3546;color:white;border-radius:13px;min-height:46px}.primary:hover{background:#37667f}.topbar{background:#fffefa;box-shadow:none;border-bottom:1px solid #e4e5e1;padding:15px 3%;gap:22px}.brand-mark{background:#d4835c;color:#fff8e8;border-radius:12px 12px 16px 4px}.nav-button{border-radius:9px}.nav-button.active{background:#edf0ed;color:#26475c}.account{font-size:12px}#main{max-width:1480px;padding:25px 4% 45px}.app-footer{background:transparent}.quest-map-title{display:flex;justify-content:space-between;align-items:center;padding:0 8px 18px}.quest-map-title h1{font-size:36px;letter-spacing:-1.6px;margin:4px 0}.quest-map-title p{margin:0;color:var(--muted)}.eyebrow{color:#8c6c4f;font-size:10px;letter-spacing:2px}.quest-progress{font-size:24px;text-align:right}.quest-progress small{display:block;font-size:11px;color:var(--muted);margin-top:4px}.quest-world{height:480px;height:clamp(340px,53vh,580px);background:#e8f3fa;position:relative;border-radius:30px;overflow:hidden;isolation:isolate}.quest-world>canvas{display:block;width:100%;height:100%;touch-action:none}.world-help{position:absolute;left:24px;bottom:18px;z-index:2;font-size:11px;color:#426376;pointer-events:none}.world-label{position:absolute;transform:translate(-50%,-50%);color:#355466;background:#fffcf0ed;border:1px solid #d5d5c8;border-radius:20px;padding:5px 11px;font-size:12px;white-space:nowrap;pointer-events:none}.world-reset{position:absolute;right:18px;bottom:14px;background:#ffffffdd;border:1px solid #d3dfe4;border-radius:12px;padding:8px 13px;font-size:11px}.world-unavailable{padding:100px 30px;text-align:center}.quest-departure{display:flex;align-items:center;gap:24px;padding:24px 20px 28px;border-bottom:1px solid #e0e2dc;margin-bottom:28px}.quest-departure h2{font-size:21px;margin:2px 0 5px}.quest-departure p{font-size:13px;color:var(--muted);margin:0}.quest-departure small{font-size:10px;color:#a06e40}.quest-departure>.primary{margin-left:auto;min-width:145px}.quest-robot{display:inline-block;position:relative;flex:none;width:60px;height:63px;background:#e2b05f;border:3px solid #806847;border-radius:14px 14px 20px 20px;box-shadow:inset 0 -12px #f8d497,0 7px 0 -3px #d7d5c9;transform:rotate(-5deg)}.quest-robot:before{content:'';position:absolute;left:27px;top:-12px;height:10px;width:3px;background:#806847}.quest-robot:after{content:'';position:absolute;left:23px;top:-15px;height:8px;width:10px;border-radius:50%;background:#de825a}.quest-robot b{display:block;background:#304d5c;color:#ffebba;letter-spacing:8px;padding-left:8px;text-align:center;line-height:26px;margin:8px 5px;border-radius:6px;font-size:22px}.quest-robot i{position:absolute;bottom:5px;left:23px;width:10px;height:3px;background:#9e7850}.chapter-paths{display:grid;grid-template-columns:repeat(3,1fr);gap:22px 36px}.chapter-island{padding:0 0 20px}.chapter-island header{display:flex;align-items:center;gap:13px;padding:15px 0}.chapter-island header>span{font-size:21px;color:#ad8c58}.chapter-island h2{font-size:16px;margin:0}.chapter-island header p{font-size:11px;margin:3px 0;color:var(--muted)}.chapter-island ol{list-style:none;padding:0;margin:0 0 0 15px;border-left:2px dashed #d6d3c7}.quest-node{width:100%;display:flex;gap:13px;align-items:center;text-align:left;padding:8px 0 8px 0;background:transparent;border:0;min-height:58px;border-radius:12px}.quest-node:hover:not(:disabled){background:#ecebe2}.quest-node b{width:34px;height:34px;border:2px solid #b48c50;background:#fff3d3;color:#8c6636;border-radius:50%;display:grid;place-items:center;flex:none;transform:translateX(-18px);margin-right:-17px}.quest-node span{font-size:12px}.quest-node small{display:block;font-size:10px;color:#7a847f;margin-top:3px}.quest-node.is-locked{opacity:.58}.quest-node.is-locked b{background:#e5e6df;color:#8e9b97;border-color:#c9d0c9}.quest-node.is-complete b{background:#d6e8d8;border-color:#7b9e83;color:#3e6c53}.quest-level-heading{display:flex;align-items:center;gap:24px;margin-bottom:22px}.quest-level-heading h1{font-size:25px;margin:2px 0}.quest-level-heading>button:last-child{margin-left:auto}.quest-mission{padding:0 0 20px}.npc-line{display:flex;align-items:center;gap:18px}.npc-line .quest-robot{transform:scale(.72) rotate(-5deg);margin:-6px}.npc-line p{font-size:13px;line-height:1.8;margin:0;max-width:850px}.npc-line p b{display:block;font-size:11px;color:#a87543}.npc-line button{margin-left:auto;white-space:nowrap;background:#fff8e8;border:1px solid #e2cda8;border-radius:12px;padding:10px 16px;font-size:12px;min-height:44px}.quest-objective{display:flex;gap:14px;font-size:14px;align-items:baseline;margin:12px 0 0 66px}.quest-objective>span{font-size:10px;background:#eceee7;padding:4px 8px;border-radius:6px;flex:none}.quest-playfield{display:grid;grid-template-columns:minmax(0,1fr) 245px;min-height:370px;background:#e7edf0;border-radius:25px;overflow:hidden}.quest-scene{min-height:370px;position:relative;overflow:hidden;background:#e6eef0;isolation:isolate}.board-ground{position:absolute;inset:13% 4% 8%;border-radius:42%;background:#d5dfd5;box-shadow:0 16px 0 #c5c6b1,0 22px 0 #d7cfba;transform:rotate(-4deg);z-index:-1}.kind-gate .board-ground{background:#e7d9bc}.kind-pipeline .board-ground{background:#d6e2da}.kind-timeline .board-ground{background:#dadde7}.kind-mesh .board-ground{background:#e4d7df}.kind-console .board-ground{background:#d3dee7}.board-edges{pointer-events:none;position:absolute;inset:0;width:100%;height:100%;z-index:-1}.board-edges line{stroke:#8c9f9d;stroke-width:.65;stroke-dasharray:1.7 1}.scene-kind-label{position:absolute;top:20px;left:22px;font-size:11px;letter-spacing:2px;color:#6a7f87}.scene-object{position:absolute;left:clamp(65px,var(--x),calc(100% - 65px));top:clamp(65px,var(--y),calc(100% - 50px));transform:translate(-50%,-50%);display:flex;align-items:center;flex-direction:column;background:transparent;border:0;min-width:95px;max-width:155px;min-height:80px;padding:0;color:#2e4c5d}.scene-object-art{display:grid;place-items:center;width:65px;height:58px;background:#fcf9e8;box-shadow:0 6px 0 #b6bda9,0 11px 8px #68807722;border:2px solid #9dabb0;border-radius:12px 12px 8px 8px;font-size:35px;line-height:1;color:#648799;margin-bottom:8px}.scene-object b{font-size:11px;background:#fffdf0d9;padding:3px 7px;border-radius:6px;max-width:150px}.scene-object small{font-size:9px;color:#6a7a78}.scene-object:hover .scene-object-art,.scene-object.selected .scene-object-art{border-color:#c88837;transform:translateY(-4px)}.board-courier{position:absolute;left:8%;bottom:7%;transform:scale(.7)}.quest-inspector{padding:25px 22px;background:#fffdf4ba;border-left:1px solid #ccd6d6}.quest-inspector h2{font-size:16px;line-height:1.6;margin-top:20px}.quest-inspector p{font-size:12px;line-height:1.9;color:#60727a;white-space:pre-wrap;overflow-wrap:anywhere}.npc-hint{font-size:12px;line-height:1.8;border-top:1px dashed #d0c9af;padding-top:18px;color:#8b663e;margin-top:20px}.quest-workbench{padding:24px 4px 10px}.quest-workbench header{display:flex;align-items:baseline;gap:20px;margin-bottom:15px}.quest-workbench h2{font-size:18px;margin:0}.board-tools{display:flex;gap:16px;flex-wrap:wrap}.board-tools fieldset{border:0;background:transparent;border-radius:0;margin:0;padding:6px 0;flex:1;min-width:min(100%,240px)}.board-tools legend{font-size:12px;font-weight:650;padding:0;margin-bottom:8px}.board-tools button{min-height:44px}.tool-switch>div{display:flex;gap:8px;flex-wrap:wrap}.switch-piece{padding:9px 14px;border:1px solid #cbd3d4;background:white;border-radius:11px;font-size:12px}.switch-piece.chosen{background:#e7d9bc;border:2px solid #aa7d40;color:#654e29}.editor-caption{font-size:11px;color:#74818a;display:block;margin-bottom:7px}.tool-editor textarea{width:100%;min-height:70px;background:#fffefa;border:1px solid #bfcdd1;border-radius:10px;padding:12px 15px;resize:vertical;font-family:ui-monospace,monospace;font-size:13px;line-height:1.5;color:#36515d}.order-slots{min-height:63px;display:flex;gap:8px;align-items:center;flex-wrap:wrap;padding:11px;border:2px dashed #c7c6b8;border-radius:13px;background:#f0efe6}.empty-slot{font-size:12px;color:#7e8177}.order-piece{background:#fffdf4;border:1px solid #b7bfae;border-radius:10px;display:flex;align-items:center;box-shadow:0 3px 0 #d4d6c6}.order-piece>span{font-size:12px;padding:10px}.order-piece button{padding:2px 8px;border:0;border-left:1px solid #e3e4d8;background:transparent;min-width:31px;color:#6d7d7c}.parts-tray{display:flex;gap:7px;flex-wrap:wrap;margin-top:10px}.part-chip{font-size:11px;background:white;border:1px solid #d4dad5;border-radius:10px;padding:8px 12px}.quest-runbar{display:flex;align-items:center;gap:22px;border-top:1px solid #dddeda;padding-top:18px;margin-top:8px}.quest-runbar #quest-status{font-size:11px;color:#75817d}.quest-runbar>.primary{margin-left:auto;min-width:160px}.quest-feedback{margin-top:28px;padding:0 5px}.quest-feedback h2{font-size:20px}.quest-feedback>p{font-size:13px;line-height:1.8}.trace-list{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:10px}.trace-step{display:flex;gap:10px;padding:13px;background:#f0eee7;border:1px solid #dfdfd4;border-radius:12px;flex:1;min-width:190px}.trace-step>span{color:#9c6c39;font-size:11px}.trace-step b{font-size:12px}.trace-step p{font-size:11px;color:#6f7a75;line-height:1.7;margin:5px 0 0}.trace-step.trace-visible{animation:tracepop .3s ease-out;background:#f4e5c7}.trace-active .scene-object-art{background:#ffe5a2;transform:translateY(-7px);box-shadow:0 6px 0 #b39150,0 0 25px #e6b14e}.check-list{display:flex;flex-wrap:wrap;gap:8px 24px;font-size:12px}.check-pass{color:#4a7358}.check-fail{color:#ac6247}.quest-principle{background:#eeeee3;padding:15px;border-radius:10px}.victory{border-top:2px solid #cfb268;padding-top:20px}.victory-footer{display:flex;justify-content:space-between;align-items:center;gap:15px;padding:20px 0;color:#6d733e;font-size:13px}.quest-reference{position:fixed;z-index:20;right:18px;top:90px;bottom:24px;width:min(420px,calc(100vw - 36px));overflow:auto;padding:24px;background:#fffdf6;border:1px solid #dcd6c7;box-shadow:0 20px 80px #344f6833;border-radius:20px}.quest-reference p{font-size:13px;line-height:1.9}.quest-reference h2{font-size:23px}.library-home{max-width:1000px;margin:40px auto}.library-shelves{margin-top:40px;display:flex;flex-direction:column}.library-shelves button{display:flex;justify-content:space-between;align-items:center;gap:15px;background:none;border:0;border-bottom:1px solid #dddcd3;padding:25px 10px;text-align:left}.library-shelves button:hover{background:#eeeee5}.library-shelves b{font-size:20px}.library-shelves span{font-size:13px;color:#76817d}.auth-layout{background:#faf8f1}.auth-story{background:#e9eef0}.story-copy h1{font-size:clamp(36px,4vw,62px);color:#294c60;letter-spacing:-2px}.story-copy p{color:#71828b}.auth-card{box-shadow:none!important;border:0!important;background:transparent!important}.auth-panel{background:#fffdf8}.auth-story .guardian{background:#ecc778;border-color:#876b44}.story-foot{font-size:11px}.auth-story .library{display:none}.auth-story .island-ground{background:#c9d7c4}.auth-story .welcome-island{height:260px}.auth-story .guardian{transform:scale(2);left:45%;bottom:80px}.auth-story .scene-caption{font-size:10px}.privacy-copy{font-size:11px;line-height:1.8}.text-button{min-height:44px}#toast{z-index:100}
/* Miniature stage polish: distinct terrain, original silhouettes, real evidence. */
.chapter-toggle{font:inherit;font-weight:650;color:inherit;border:0;background:transparent;padding:0;min-height:44px;text-align:left;cursor:pointer}.chapter-toggle span{display:inline-block;margin-left:8px;color:#9b865e}.chapter-toggle[aria-expanded="true"] span{transform:rotate(180deg)}.chapter-island ol[hidden]{display:none!important}.chapter-paths{align-items:start;gap:4px 32px}.chapter-island{padding-bottom:4px}.quest-concept{letter-spacing:.7px;color:#71838a}.quest-level-heading h1{font-size:28px}.quest-scene{min-height:420px;background:#dceef1}.board-ground{inset:15% 3% 24%;border-radius:24px 65px 34px 24px;transform:rotate(-2deg);background:#bdd3b7;box-shadow:0 9px 0 #8fab9d,0 17px 0 #d6ddbd}.kind-route .board-ground:after{content:'';position:absolute;inset:22% 5%;border-top:14px solid #f7ecd1;border-bottom:14px solid #f7ecd1;transform:rotate(2deg);opacity:.8}.kind-gate .quest-scene{background:#f1e9db}.kind-gate .board-ground{inset:22% 3% 24%;background:#d8c3a2;border-radius:8px;transform:none;box-shadow:0 10px #baaa91}.kind-gate .board-ground:after{content:'';position:absolute;inset:42% 0;border-top:3px dashed #faf4e6;border-bottom:3px dashed #faf4e6}.kind-pipeline .quest-scene{background:#deeee6}.kind-pipeline .board-ground{background:#c0d6c7;transform:none;border-radius:20px;box-shadow:0 10px #96b6a5;background-image:linear-gradient(#edf6ec66 1px,transparent 1px),linear-gradient(90deg,#edf6ec66 1px,transparent 1px);background-size:35px 35px}.kind-timeline .quest-scene{background:#e8ecf5}.kind-timeline .board-ground{border-radius:10px;background:#d1d8e7;box-shadow:0 10px #aab7cf;transform:rotate(1deg);border:8px solid #bec9dd}.kind-mesh .quest-scene{background:#efe7ef}.kind-mesh .board-ground{background:#d9cddd;border-radius:28px;box-shadow:0 10px #b4a5be;transform:none}.kind-console .quest-scene{background:#e4eef3}.kind-console .board-ground{background:#bfcfd8;border-radius:16px 16px 45px 45px;box-shadow:0 10px #91a9b9;transform:none}.board-edges{z-index:0}.board-edges line{stroke:#7d9d9d;stroke-width:.7;stroke-dasharray:1.4 1.1}.scene-kind-label{top:18px;color:#4f6f78}.quest-level .scene-object .scene-object-art{width:96px;height:96px;background:none;border:0;border-radius:0;box-shadow:none;margin-bottom:0;display:block;transition:transform .15s}.station-illustration{display:block;width:100%;height:100%;overflow:visible}.scene-object{max-width:170px}.scene-object b{background:#fffdf3eb;font-size:11px;box-shadow:0 2px 0 #81999522}.scene-object:hover .scene-object-art,.scene-object.selected .scene-object-art{transform:translateY(-5px)}.trace-active .scene-object-art{filter:drop-shadow(0 0 6px #fff4c3)}.scene-object[data-check-status="open"] .gate-barrier{transform:rotate(-65deg);transform-origin:24px 49px}.scene-object[data-check-status="open"] .gate-lamp{fill:#4f9475}.scene-object[data-check-status="closed"] .gate-lamp{fill:#bb654e}.gate-barrier{transition:transform .18s}.board-courier{z-index:4;left:8%;top:70%;bottom:auto;width:42px;height:36px;transform:translate(-50%,-50%);visibility:hidden;filter:drop-shadow(0 5px 2px #58727a33)}.board-courier svg{width:100%;height:100%}.board-live{position:absolute;bottom:14px;left:18px;right:18px;z-index:5;background:#fffdf4f5;border:1px solid #cdd9d4;border-radius:12px;padding:10px 14px;pointer-events:none;box-shadow:0 3px 0 #627c7912;max-height:105px;overflow:auto}.board-live small,.board-live b,.board-live span{display:block;overflow-wrap:anywhere}.board-live small{font-size:10px;color:#6b8084}.board-live b{font-size:13px;margin:3px 0;color:#34586a}.board-live span{font-size:11px;color:#62757c;line-height:1.5}.board-live[data-result="error"]{border-color:#dbb8a0}.board-live[data-result="ok"]{border-color:#9cbdac}.trace-details{border-top:1px solid #d9e0d9;padding:12px 0}.trace-details summary{cursor:pointer;min-height:44px;display:list-item;font-size:12px;color:#536e78;padding:10px}.trace-details .trace-list{display:block;max-height:330px;overflow:auto}.trace-details .trace-step{min-width:0;margin:5px 0;padding:10px;background:#f2f3ed}.trace-step>button{align-self:start;font-size:11px;border:1px solid #c6d3cd;background:#fffefa;border-radius:8px;min-height:44px;padding:5px 9px;flex:none;color:#536f75}.trace-details .check-list{display:block;font-size:11px;padding:0 10px}.quest-feedback{margin-top:18px}.quest-feedback h2{margin-bottom:6px}.quest-feedback>p{margin-top:0}.quest-workbench{padding-top:20px}
@media(max-width:600px){.quest-level-heading h1{font-size:22px}.quest-level .scene-object .scene-object-art{width:65px;height:65px}.scene-object{max-width:90px;top:clamp(75px,var(--y),calc(100% - 110px))}.scene-object b{font-size:9px;padding:3px 5px}.quest-scene{min-height:390px}.board-live{bottom:10px;left:10px;right:10px;padding:8px 10px;max-height:91px}.board-live small{font-size:9px}.board-live b{font-size:11px}.board-live span{font-size:10px}.scene-kind-label{font-size:10px;top:14px;left:14px}.quest-inspector{padding:12px 15px}.chapter-island header{padding:5px 0}.chapter-island ol{padding-bottom:15px}.chapter-toggle{font-size:14px}.board-courier{width:34px;height:28px}.trace-step{gap:7px}.trace-step>button{font-size:10px;max-width:95px}.quest-level-heading .quest-concept{letter-spacing:0;line-height:1.6}}
@keyframes tracepop{from{transform:translateY(8px);opacity:.4}to{transform:translateY(0);opacity:1}}
@media(min-width:1500px){.quest-world{height:550px}}
@media(max-width:900px){.topbar{flex-wrap:wrap;padding:12px 4%}.topbar nav{order:3;width:100%;justify-content:flex-start}.account{margin-left:auto}.quest-playfield{grid-template-columns:minmax(0,1fr) 200px}.chapter-paths{grid-template-columns:repeat(2,1fr)}.quest-map-title h1{font-size:29px}.quest-map-title p{font-size:12px}}
@media(max-width:600px){#main{padding:20px 16px 35px}.topbar{gap:9px}.brand{font-size:14px}.brand small,#account-level{display:none}.account{gap:8px}.account #account-name{max-width:75px;overflow:hidden;text-overflow:ellipsis}.topbar nav{gap:3px;overflow:auto;white-space:nowrap}.nav-button{font-size:11px;padding:9px 10px;min-height:44px}.quest-map-title{padding:0 0 15px}.quest-map-title h1{font-size:29px}.quest-map-title .eyebrow{font-size:8px;letter-spacing:1px}.quest-map-title p{font-size:11px;max-width:210px;line-height:1.8}.quest-progress{font-size:19px}.quest-progress small{font-size:9px}.quest-world{height:355px;border-radius:20px;margin:0 -4px}.world-help{left:12px;bottom:13px;font-size:8px;max-width:165px}.world-label{font-size:9px;padding:4px 6px}.world-reset{font-size:9px;right:9px;bottom:7px}.quest-departure{padding:20px 0;gap:13px;flex-wrap:wrap}.quest-departure .quest-robot{transform:scale(.8);margin:-5px}.quest-departure h2{font-size:16px;max-width:210px}.quest-departure p{font-size:10px}.quest-departure>.primary{width:100%;margin:3px 0 0}.chapter-paths{grid-template-columns:1fr;gap:10px}.chapter-island{padding-bottom:8px}.chapter-island ol{display:grid;grid-template-columns:1fr 1fr;gap:4px 8px;border:0;margin:0}.quest-node{gap:8px;align-items:flex-start;min-height:68px;padding:7px 0}.quest-node b{transform:none;margin:0;width:27px;height:27px;font-size:11px}.quest-node span{font-size:10px;line-height:1.6}.quest-node small{font-size:8px}.quest-level-heading{gap:10px;align-items:flex-start;flex-wrap:wrap;margin-bottom:10px}.quest-level-heading>button{font-size:10px;padding:0}.quest-level-heading>div{flex:1}.quest-level-heading h1{font-size:19px}.quest-level-heading .eyebrow{font-size:8px}.quest-level-heading>button:last-child{margin-left:auto}.npc-line{gap:12px;align-items:flex-start;flex-wrap:wrap}.npc-line p{flex:1;min-width:150px;font-size:11px;line-height:1.8}.npc-line button{font-size:10px;margin-left:57px;padding:6px 14px}.quest-objective{margin:13px 0 0;font-size:11px;gap:8px;line-height:1.8}.quest-playfield{display:block;min-height:0;border-radius:18px}.quest-scene{min-height:350px}.scene-object{min-width:62px;max-width:90px;left:clamp(45px,var(--x),calc(100% - 45px));top:clamp(75px,var(--y),calc(100% - 55px))}.scene-object-art{width:45px;height:44px;font-size:26px;border-radius:9px}.scene-object b{font-size:9px;max-width:95px}.scene-object small{font-size:7px}.quest-inspector{border-left:0;border-top:1px solid #ccd6d6;padding:15px}.quest-inspector h2{font-size:13px;margin:8px 0}.quest-inspector p{font-size:11px;margin:3px 0}.npc-hint{margin-top:12px;padding-top:10px;font-size:11px}.quest-workbench{padding-top:20px}.quest-workbench header{display:block}.quest-workbench h2{font-size:16px;margin-top:5px}.board-tools{display:block}.board-tools fieldset{width:100%;min-width:0;padding:8px 0}.board-tools legend{font-size:11px}.order-piece>span{font-size:10px;padding:7px}.order-piece button{min-width:30px}.order-slots{padding:8px}.parts-tray{gap:6px}.part-chip{padding:8px;font-size:10px}.switch-piece{font-size:11px;padding:8px 10px}.quest-runbar{gap:10px;flex-wrap:wrap}.quest-runbar #quest-status{font-size:9px;flex:1;text-align:right}.quest-runbar>.primary{width:100%;margin:0}.quest-runbar>.text-button{font-size:10px}.trace-list{display:block}.trace-step{margin-bottom:8px}.victory-footer{flex-direction:column;align-items:stretch;font-size:11px}.quest-feedback h2{font-size:17px}.library-home{margin:20px 0}.library-shelves button{display:block;padding:22px 4px}.library-shelves b{display:block;font-size:18px;margin-bottom:6px}.library-shelves span{font-size:11px}.story-copy h1{font-size:36px}.auth-story .welcome-island{height:160px}.auth-story .guardian{transform:scale(1.3);bottom:45px}.story-foot{display:none}.auth-story{padding-bottom:0}.story-copy{padding-bottom:0}.auth-panel{padding:28px 20px}.quest-reference{top:40px}}
.scene-object:active:not(:disabled){transform:translate(-50%,-50%)!important}.board-ground,.board-courier,.scene-kind-label{pointer-events:none}.scene-object{z-index:2}.quest-node:disabled{background:transparent!important}.quest-node.is-locked{opacity:.72}.scene-object:disabled{opacity:1}
.quest-reference pre{white-space:pre-wrap;font-size:11px;overflow-wrap:anywhere}
.quest-level .scene-object .scene-object-art{background:none;border:0;border-radius:0;box-shadow:none}.gate-barrier{opacity:.3;stroke-dasharray:4 2}.scene-object[data-check-status] .gate-barrier{opacity:1;stroke-dasharray:none}@media(max-width:600px){.quest-scene{min-height:420px}.scene-object{top:clamp(75px,var(--y),calc(100% - 130px))}}
@media(prefers-reduced-motion:reduce){*{animation:none!important;scroll-behavior:auto!important;transition:none!important}}

/* Scene-first teaching: the town is the interface, the manual stays in a pocket. */
#main .game-first{display:flex;flex-direction:column;gap:12px;color:#244754;padding-bottom:24px}
#main .game-first .quest-level-heading{order:0;margin:0;align-items:center;gap:12px}
#main .game-first .quest-level-heading h1{font-size:clamp(20px,3vw,30px);letter-spacing:0;margin:3px 0}
#main .game-first .quest-concept{font-size:11px;letter-spacing:0;color:#586e73}
#main .game-first button,#main .game-first summary{min-height:44px;min-width:44px;touch-action:manipulation}
#main .game-first button:disabled{cursor:wait;opacity:.65}
#main .game-first .quest-playfield{order:2;display:flex;flex-direction:column;gap:0;border:2px solid #7ba6a2;background:#eef7eb;overflow:hidden;border-radius:16px}
#main .game-first .quest-scene{min-height:480px;height:54vh;max-height:700px;background:#d8eff3!important;border:0;isolation:isolate}
#main .game-first .quest-scene:before{content:'';position:absolute;top:22px;right:12%;width:66px;height:22px;background:#fffdf3;border-radius:50%;box-shadow:15px -9px 0 1px #fffdf3,35px 2px 0 #fffdf3;opacity:.8;animation:town-cloud 15s ease-in-out infinite alternate;pointer-events:none}
#main .game-first .board-ground{inset:16% 3% 25%;background:#b9d4ac!important;background-image:linear-gradient(#ebf4d933 1px,transparent 1px),linear-gradient(90deg,#ebf4d933 1px,transparent 1px)!important;border:2px solid #85ac8c;box-shadow:0 7px 0 #8fb395!important;border-radius:18px!important;transform:none!important}
#main .game-first .board-ground:after{border-color:#fff3d9;opacity:.75}
#main .game-first .board-edges{z-index:1;opacity:.8}
#main .game-first .board-edges line{stroke:#5c9692;stroke-width:.8;stroke-dasharray:2 1;animation:town-flow 3s linear infinite}
#main .game-first .scene-object{width:142px;max-width:142px;min-width:44px;min-height:100px;padding:0 4px;top:var(--y);left:var(--x);z-index:2;outline-offset:2px}
#main .game-first .scene-object .scene-object-art{width:92px;height:92px;display:block;margin:0;filter:drop-shadow(0 4px 0 #688d7a33)}
#main .game-first .scene-object b{font-size:13px;line-height:1.45;padding:5px 7px;max-width:138px;background:#fff9e7;color:#244754;box-shadow:0 2px 0 #87a491;border:1px solid #9ab7a0;overflow-wrap:anywhere}
#main .game-first .scene-object.selected b,#main .game-first .trace-active b{border-color:#ae6e31;background:#fff0bd}
#main .game-first .scene-kind-label{left:16px;top:16px;font-size:12px;letter-spacing:0;color:#386975}
#main .game-first .board-live{left:12px;right:12px;bottom:12px;max-height:112px;padding:10px 12px;background:#fffdf1;border:1px solid #91b4ac;box-shadow:0 3px 0 #a4c2b5;border-radius:9px;overflow:auto}
#main .game-first .board-live small{font-size:12px;color:#546e74}
#main .game-first .board-live b{font-size:16px;line-height:1.5}
#main .game-first .board-live span{font-size:13px;line-height:1.5}
#main .game-first .quest-mission{order:-1;margin:0;padding:12px 16px;background:#fff9e7;border:0;border-bottom:1px solid #c4d5bd}
#main .game-first .npc-line{display:flex;align-items:center;gap:12px;flex-wrap:nowrap}
#main .game-first .npc-line p{font-size:15px;line-height:1.7;max-width:none;min-width:0;flex:1}
#main .game-first .npc-line p b{font-size:12px;color:#956234}
#main .game-first .npc-line .quest-robot{flex-shrink:0;transform:scale(.68);margin:-8px}
#main .game-first .npc-line button{margin:0;padding:6px 12px;font-size:13px;background:#f8edce;white-space:nowrap}
#main .game-first .quest-objective{font-size:13px;line-height:1.7;margin:8px 0 0 48px;color:#48695e}
#main .game-first .quest-inspector{order:3;border:0;border-top:1px solid #a9c4b8;background:#f4f9ed;padding:12px 18px}
#main .game-first [hidden]{display:none!important}
#main .game-first .quest-inspector h2{font-size:15px;margin:0 0 5px}
#main .game-first .quest-inspector p{font-size:14px;margin:0;line-height:1.8}
#main .game-first .quest-runbar{order:1;display:flex;align-items:center;gap:12px;position:sticky;top:0;z-index:7;margin:0;padding:8px 12px;background:#faf7e9f5;border:1px solid #becdb4;box-shadow:0 3px 0 #c3d0b855;min-height:64px}
#main .game-first .quest-runbar #quest-status{font-size:12px;line-height:1.5;flex:1;min-width:0}
#main .game-first .quest-runbar .primary{font-size:16px;min-height:48px;min-width:180px;width:auto;margin:0 0 0 auto;padding:10px 20px;background:#2e6868;border:2px solid #244f55;box-shadow:0 3px 0 #adbf9f}
#main .game-first .quest-workbench{order:3;margin:0;padding:14px 16px;background:#f6f5e8;border:1px solid #becdb4}
#main .game-first .quest-workbench header{display:flex;flex-wrap:wrap;align-items:center;gap:8px 18px;margin-bottom:12px}
#main .game-first .quest-workbench h2{font-size:18px;line-height:1.5;margin:0}
#main .game-first .quest-workbench small{font-size:13px;color:#5e7369}
#main .game-first .board-tools{display:flex;flex-wrap:wrap;gap:16px}
#main .game-first .board-tools fieldset{min-width:0;flex:1 1 270px;margin:0;padding:0;border:0}
#main .game-first .board-tools legend{font-size:14px;line-height:1.7;margin-bottom:8px;max-width:100%}
#main .game-first .order-slots{display:flex;align-items:stretch;flex-wrap:wrap;gap:9px;padding:10px;background:#dce8d0;border:1px dashed #86a48b;min-height:68px}
#main .game-first .order-piece{display:flex;align-items:center;flex-wrap:wrap;gap:0;max-width:100%;padding:3px 4px;background:#fff9e3;border:1px solid #91aa8a;font-size:14px;box-shadow:0 3px 0 #a5bb9d}
#main .game-first .order-piece>span{width:100%;max-width:250px;overflow-wrap:anywhere;padding:4px}
#main .game-first .order-piece button{min-width:44px;width:44px;height:44px;padding:2px;font-size:20px;border:0;background:#f3edce;color:#3e6b6b}
#main .game-first .parts-tray,#main .game-first .tool-switch>div,#main .game-first .rule-gate{display:flex;flex-wrap:wrap;gap:9px;margin-top:10px}
#main .game-first .part-chip,#main .game-first .switch-piece,#main .game-first .rule-chip{font-size:14px;line-height:1.5;min-height:48px;padding:9px 12px;max-width:100%;white-space:normal;overflow-wrap:anywhere;background:#fff9df;border:1px solid #9eb48c;box-shadow:0 3px 0 #b0c39c;color:#315856}
#main .game-first .chosen{background:#d7ecd8;border-color:#467d70;box-shadow:0 3px 0 #7ba68e}
#main .game-first .rule-caption,#main .game-first .editor-caption{font-size:13px;line-height:1.7;color:#5b716d}
#main .game-first summary{display:flex;align-items:center;font-size:14px;line-height:1.6;cursor:pointer;padding:7px 0;gap:8px}
#main .game-first summary:before{content:'＋';flex:none;font-size:16px}
#main .game-first details[open]>summary:before{content:'−'}
#main .game-first textarea{width:100%;font-size:15px;line-height:1.8;background:#fffdf2;color:#264d58;padding:10px;min-height:88px;overflow-wrap:anywhere;border:1px solid #91afa3}
#main .game-first .dial-controls{display:flex;align-items:center;gap:8px}
#main .game-first .dial-controls button{width:48px;height:48px;background:#f7eccb;color:#315b5e;font-size:22px;border:1px solid #9cb38d}
#main .game-first .dial-controls input{width:120px;max-width:100%;min-height:48px;text-align:center;background:#fff9e2;color:#315b5e;border:2px solid #93ac91;font-size:18px}
#main .game-first .sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0)}
#main .game-first .quest-feedback{order:4;margin:0;padding:12px 16px;border:1px solid #bbcdaf;background:#f7f5e6}
#main .game-first .quest-feedback h2{font-size:19px;margin:0 0 6px}
#main .game-first .quest-feedback p,#main .game-first .quest-feedback button{font-size:14px;line-height:1.8}
#main .game-first .tutor-pocket{order:5;padding:4px 16px;background:#f2f4e7;border-top:1px dashed #9fb39b}
#main .game-first .tutor-pocket p{font-size:14px;line-height:1.8}
#main .game-first .quest-reference{order:6}
@keyframes town-cloud{to{transform:translateX(25px)}}
@keyframes town-flow{to{stroke-dashoffset:-12}}
@media(max-width:600px){
 #main .game-first{gap:9px}
 #main .game-first .quest-level-heading{gap:6px;flex-wrap:wrap}
 #main .game-first .quest-level-heading>div{min-width:145px}
 #main .game-first .quest-level-heading h1{font-size:21px}
 #main .game-first .quest-level-heading>button{font-size:12px}
 #main .game-first .quest-runbar{gap:8px;padding:7px 8px;flex-wrap:wrap;top:0}
 #main .game-first .quest-runbar>.text-button{font-size:12px;padding:0 3px}
 #main .game-first .quest-runbar #quest-status{font-size:11px;text-align:left}
 #main .game-first .quest-runbar .primary{font-size:16px;min-width:0;width:100%;margin:0;padding:8px}
 #main .game-first .quest-playfield{border-radius:10px}
 #main .game-first .quest-scene{height:auto;max-height:none;min-height:500px}
 #main .game-first .scene-object{width:128px;max-width:128px;min-height:104px;padding:0 3px}
 #main .game-first .scene-object .scene-object-art{width:70px;height:70px}
 #main .game-first .scene-object b{font-size:12px;padding:4px 5px;max-width:122px}
 #main .game-first .quest-mission{padding:10px}
 #main .game-first .npc-line{gap:8px;align-items:flex-start}
 #main .game-first .npc-line p{font-size:14px;line-height:1.65}
 #main .game-first .npc-line .quest-robot{width:40px;margin:-8px -5px;transform:scale(.58)}
 #main .game-first .npc-line button{font-size:12px;padding:3px 7px;min-width:44px}
 #main .game-first .quest-objective{font-size:12px;margin:5px 0 0 35px}
 #main .game-first .board-live{left:8px;right:8px;bottom:8px;max-height:105px;padding:8px}
 #main .game-first .board-live small{font-size:11px}
 #main .game-first .board-live b{font-size:14px}
 #main .game-first .board-live span{font-size:12px}
 #main .game-first .quest-workbench{padding:12px 10px}
 #main .game-first .board-tools fieldset{flex-basis:100%}
 #main .game-first .order-piece{width:calc(50% - 5px);min-width:138px}
 #main .game-first .order-piece>span{font-size:13px;min-height:38px}
 #main .game-first .quest-feedback{padding:12px}
 #main .game-first .trace-step{display:block}
 #main .game-first .trace-step>button{max-width:none;font-size:13px}
}
@media(max-width:350px){
 #main .game-first .scene-object{width:117px;max-width:117px}
 #main .game-first .scene-object b{max-width:110px}
 #main .game-first .order-piece{width:100%}
 #main .game-first .npc-line .quest-robot{display:none}
 #main .game-first .quest-objective{margin-left:0}
}
@media(prefers-reduced-motion:reduce){#main .game-first .quest-scene:before,#main .game-first .board-edges line{animation:none}}
