:root{font-family:Arial,Helvetica,sans-serif;color:#f2efe7;background:#11172b;font-synthesis:none;--mint:#b0ffe0;--gold:#f7ca88;--ink:#11172b}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,a,summary{-webkit-tap-highlight-color:transparent}button{font:inherit;color:inherit;cursor:pointer}button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #b0ffe0;outline-offset:5px}button:disabled{cursor:wait;opacity:.5}[hidden]{display:none!important}#world,#vignette{position:fixed;inset:0}#world canvas{display:block}#vignette{pointer-events:none;background:linear-gradient(90deg,rgba(9,15,30,.84),transparent 68%),linear-gradient(0deg,rgba(8,14,28,.7),transparent 35%)}body.playing #vignette{background:linear-gradient(0deg,rgba(8,14,28,.7),transparent 27%),linear-gradient(180deg,rgba(8,14,28,.6),transparent 25%)}header{position:fixed;top:28px;left:38px;right:38px;display:flex;justify-content:space-between;align-items:center;z-index:5}.wordmark{text-decoration:none;color:var(--mint);font-weight:900;font-size:25px;letter-spacing:5px}.wordmark span{display:block;color:#a7aabb;font-size:8px;letter-spacing:2px;margin-top:7px}.top-actions{display:flex;gap:10px}.top-actions button{border:1px solid #ffffff25;background:#11172b70;padding:11px 13px;font-size:9px;letter-spacing:1.5px;border-radius:3px}.top-actions button:hover{border-color:var(--mint)}kbd{font:inherit;font-size:10px;padding:4px 5px;border:1px solid #ffffff40;border-radius:3px;margin-left:4px}.panel{position:fixed;left:7vw;top:21vh;max-width:510px}.eyebrow{color:var(--gold);font-size:10px;letter-spacing:4px;margin-bottom:20px}h1{font-size:clamp(58px,7.6vw,112px);line-height:.85;letter-spacing:-5px;font-weight:800;margin:0}h1 em{font-style:normal;font-weight:300;color:var(--mint)}h1 span{display:block;font-size:10px;letter-spacing:5px;margin-top:25px;font-weight:500}.lead{font-size:18px;line-height:1.5;color:#e3e2e7;margin-top:26px}.intro-rule{width:45px;height:1px;background:var(--gold);margin:22px 0}.intro-detail{font-size:12px;line-height:1.8;color:#a9afc3}.primary{border:0;background:var(--mint);color:#132b2b;font-weight:800;font-size:11px;letter-spacing:2px;padding:18px 26px;border-radius:3px;margin-top:12px;min-width:250px;box-shadow:0 4px 35px #86ffd020}.primary:hover{background:#d0ffed;transform:translateY(-1px)}#load-status{font-size:10px;max-width:400px;line-height:1.5;color:#a5b2c4}details{max-width:370px;font-size:11px;line-height:1.7;color:#a9afc3;margin-top:18px}summary{letter-spacing:2px;font-size:9px;cursor:pointer}#level-select{display:flex;gap:7px;margin-top:14px}#level-select button{font-size:9px;border:1px solid #ffffff30;background:transparent;padding:8px 10px;border-radius:3px}#level-select button.selected{border-color:var(--mint);color:var(--mint)}
#hud{position:fixed;left:38px;right:38px;top:113px;display:flex;justify-content:space-between;pointer-events:none}.chapter small,.stats small{font-size:8px;letter-spacing:2px;color:#a9b4cd}.chapter h2{font-size:20px;letter-spacing:-.5px;margin:8px 0}.chapter p{font-size:11px;color:#b9c3d1;margin:6px 0}.stats{display:flex;gap:35px;text-align:right}.stats strong{display:block;font-size:20px;margin-top:9px;font-weight:400;color:var(--gold)}.stats #lives{font-size:15px;letter-spacing:3px}#progress{position:absolute;top:84px;left:0;width:210px;height:2px;background:#ffffff20}#progress i{display:block;height:100%;background:var(--mint);width:0;transition:width .4s}#crew{position:fixed;bottom:38px;left:38px;display:flex;gap:9px}#crew button{background:#111b2ddd;border:1px solid #ffffff25;border-radius:6px;min-width:112px;padding:12px 15px;text-align:left;box-shadow:0 6px 24px #0003}#crew button.active{border-color:var(--mint);background:#173b3be0}#crew button small{display:block;color:#9faec3;font-size:8px;letter-spacing:1px;margin-bottom:7px}#crew button strong{font-size:13px}#crew button span{display:block;font-size:9px;color:#b3c6cb;margin-top:5px}#ability{position:fixed;bottom:40px;right:38px;width:185px;text-align:right}#ability>span{font-size:10px;letter-spacing:2px;color:var(--mint)}#ability>div{height:3px;background:#ffffff20;margin:10px 0}#ability i{display:block;height:100%;background:var(--mint);width:100%}#ability small{font-size:8px;letter-spacing:2px;color:#99a8be}#message{position:fixed;bottom:155px;left:50%;transform:translateX(-50%);font-size:13px;text-align:center;color:#e0fff3;padding:12px 20px;border-radius:4px;max-width:90vw;pointer-events:none;text-shadow:0 1px 8px #000;background:#102333a0;opacity:0;transition:opacity .2s}#message.visible{opacity:1}#help{position:fixed;bottom:16px;left:50%;transform:translateX(-50%);font-size:8px;letter-spacing:1px;color:#8e9db4;white-space:nowrap}#help kbd{margin-right:7px;font-size:8px;padding:2px 4px}.modal{position:fixed;inset:0;background:#070d21b8;backdrop-filter:blur(12px);display:grid;place-items:center;z-index:10}.modal-card{max-width:520px;width:90%;text-align:center;border:1px solid #b0ffe02a;background:#111c31;padding:48px 35px;border-radius:10px;box-shadow:0 25px 100px #0007}.modal-card>small{font-size:9px;letter-spacing:3px;color:var(--gold)}.modal-card h2{font-size:44px;letter-spacing:-2px;margin:20px 0}.modal-card p{font-size:13px;line-height:1.8;color:#b7c5d8;white-space:pre-line}#overlay-buttons{display:flex;gap:10px;justify-content:center;flex-wrap:wrap}#overlay-buttons button{padding:13px 20px;border-radius:3px;border:1px solid #b0ffe060;background:#1a3f42;font-size:11px;letter-spacing:1px}#overlay-buttons button:hover{background:#28615d}#toast{position:fixed;top:82px;right:38px;font-size:10px;color:var(--gold)}#touch{position:fixed;bottom:145px;left:20px;right:20px;display:flex;justify-content:space-between;pointer-events:none}#touch button{pointer-events:auto;touch-action:none;border:1px solid #ffffff40;background:#172439d9;border-radius:7px;width:48px;height:45px;font-size:17px;color:var(--mint)}.dpad{display:grid;grid-template-columns:repeat(3,48px);gap:4px}.dpad button:first-child{grid-column:2}.dpad button:nth-child(2){grid-column:1}.touch-actions{display:flex;align-items:end;gap:5px}.touch-actions button{font-size:8px!important;width:56px!important}body.calm *{transition:none!important}
@media(max-width:700px){header{top:18px;left:20px;right:20px}.wordmark{font-size:20px}.top-actions{gap:5px}.top-actions button{font-size:7px;padding:9px 7px}.top-actions kbd{display:none}.wordmark span{font-size:6px}.panel{left:8vw;top:18vh;right:8vw}.eyebrow{font-size:8px}h1{font-size:72px}.lead{font-size:15px}.intro-rule{margin:15px 0}.intro-detail{font-size:11px}details{margin-top:10px}.panel .primary{margin-top:5px}#hud{left:20px;right:20px;top:91px}.chapter h2{font-size:17px}.stats{gap:14px}.stats strong{font-size:16px}.stats #lives{font-size:10px;letter-spacing:1px}.stats small{font-size:7px;letter-spacing:1px}.chapter p{font-size:9px;max-width:170px}#crew{left:20px;bottom:35px;gap:5px}#crew button{min-width:80px;padding:10px}#crew button strong{font-size:11px}#crew button small{font-size:7px}#crew button span{font-size:8px}#ability{right:20px;bottom:112px;width:130px}#ability>span{font-size:9px}#help{display:none!important}#message{bottom:250px;font-size:11px}#progress{width:160px}#vignette{background:linear-gradient(90deg,#0b1227e8,#0b122750)}.modal-card{padding:35px 24px}.modal-card h2{font-size:34px}}
@media(max-height:720px){.panel{top:17vh}h1{font-size:68px}.lead{font-size:14px;margin-top:20px}.intro-rule{margin:12px 0}.intro-detail{line-height:1.6}details{margin-top:8px}.eyebrow{margin-bottom:15px}}
@media(max-width:700px){#intro h1{font-size:clamp(44px,15.4vw,72px);letter-spacing:-3px}#intro{max-height:calc(100dvh - 110px);overflow-y:auto;padding-bottom:24px}}

/* Route identity is secondary to the objective; preserve the compact mobile HUD. */
#route-note{color:var(--gold)!important;font-size:9px!important;letter-spacing:1.6px;text-transform:uppercase;margin:6px 0 8px!important}#progress{top:105px}#crew button.active{box-shadow:0 0 0 1px #b0ffe030,0 7px 25px #0005}body.playing #vignette{background:linear-gradient(0deg,rgba(8,14,28,.7),transparent 25%),linear-gradient(180deg,rgba(8,14,28,.6),transparent 22%)}@media(max-width:700px){#route-note{font-size:7px!important;letter-spacing:.7px;max-width:150px}#progress{top:106px}}

/* Portrait play uses separate, non-overlapping HUD, ability and touch-control bands. */
@media(max-width:700px){
 #hud{top:78px;left:12px;right:12px;padding:12px 11px 15px;background:#0c182df2;border:1px solid #b0ffe024;border-radius:9px;box-shadow:0 8px 30px #0003;gap:8px}
 .chapter{min-width:0}.chapter small{font-size:7px;letter-spacing:1px}.chapter h2{font-size:16px;margin:6px 0}.chapter p{color:#e0e8ed;line-height:1.4;margin:5px 0;font-size:10px;max-width:190px}
 #route-note{font-size:7px!important;margin:4px 0!important;max-width:180px}.stats{gap:10px;flex-shrink:0}.stats small{font-size:6px}.stats strong{font-size:15px;margin-top:8px}.stats #lives{font-size:9px}
 #progress{top:auto;bottom:6px;left:11px;width:calc(100% - 22px)}
 #crew{left:12px;right:12px;bottom:calc(12px + env(safe-area-inset-bottom));display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
 #crew button{min-width:0;height:58px;padding:7px 9px}#crew button small{font-size:6px;margin-bottom:5px;letter-spacing:.6px}#crew button strong{font-size:12px}#crew button span{font-size:7px;margin-top:4px}
 #touch{left:12px;right:12px;bottom:calc(94px + env(safe-area-inset-bottom));align-items:end}
 .dpad{grid-template-columns:repeat(3,42px);gap:4px}#touch button{width:42px;height:42px;background:#14283fee;border-color:#c4e5e66b}.touch-actions{gap:4px}.touch-actions button{width:46px!important;font-size:7px!important}
 #ability{right:12px;bottom:calc(202px + env(safe-area-inset-bottom));width:148px;padding:7px 10px;background:#0c182dee;border:1px solid #b0ffe02a;border-radius:6px}
 #ability>span{font-size:9px;letter-spacing:1px}#ability>div{margin:6px 0 0}#ability small{display:none}
 #message{top:205px;bottom:auto;max-width:calc(100% - 36px);width:max-content;padding:8px 12px;font-size:10px;background:#102333ed}
}
@media(max-width:700px) and (max-height:600px){
 #hud{top:70px;padding:8px 11px 13px}.chapter h2{font-size:14px;margin:3px 0}#route-note,.chapter #mission{display:none}
 #crew{bottom:8px}#crew button{height:46px}#crew button span{display:none}#touch{bottom:68px}.dpad{display:flex}#ability{bottom:120px}#message{top:132px;max-width:55%;left:35%}
}

#skill-status{font-size:10px;color:#a0f8dc;margin:5px 0;letter-spacing:.05em}@media(max-width:700px){#skill-status{font-size:8px!important}#message{top:230px}}
