
:root{font-family:Inter,Segoe UI,sans-serif;color:#143c3b;background:#d6e6df;font-synthesis:none}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;border:0;cursor:pointer;border-radius:14px;background:#fffaf0;color:#173c3b;padding:12px 17px;font-weight:650}button:focus-visible,a:focus-visible{outline:3px solid #e26b36;outline-offset:3px}button:disabled{opacity:.45;cursor:default}[hidden]{display:none!important}#city{position:fixed;inset:0;width:100%;height:100%}header{position:absolute;top:24px;left:30px;right:30px;display:flex;justify-content:space-between;align-items:center}.brand{text-decoration:none;color:#163e3c;font-weight:800;font-size:22px;display:flex;align-items:center;gap:10px}.brand>span:last-child{font-size:13px;font-weight:500;max-width:55px}.brand-icon{background:#1c5148;color:#f9e6ac;border-radius:13px;padding:8px 13px}.top-actions{display:flex;gap:8px}.navigator{position:absolute;top:95px;left:30px;background:#fffaf0;width:min(510px,calc(100% - 60px));border-radius:22px;box-shadow:0 12px 35px #173d3820;padding:22px 24px 0;overflow:hidden}.eyebrow{font-size:10px;letter-spacing:2px;font-weight:800;color:#57756c}.instruction-row{display:flex;align-items:center;gap:18px;margin:13px 0}.instruction-row>span{font-size:40px;color:#b05b35}h1{font-size:23px;line-height:1.25;margin:0;letter-spacing:-.5px}.nav-bottom{display:flex;justify-content:space-between;align-items:center;font-size:12px;color:#647b71}.nav-bottom button{font-size:12px;padding:9px}.track{height:4px;background:#e5e5d7;margin:12px -24px 0}#bar{height:100%;background:#d47a43;transition:width .4s;width:0}.panel{position:absolute;right:30px;top:110px;width:345px;background:#fffaf0f5;border-radius:24px;padding:28px;box-shadow:0 18px 60px #173d3830}h2{font-size:31px;letter-spacing:-1px;margin:12px 0}p{line-height:1.5;font-size:14px;color:#60766d}.hint{font-size:12px}.panel small{font-size:11px;color:#687e73}#missions{display:grid;gap:9px;margin:22px 0}#missions button{text-align:left;background:#e9eddf;border:1px solid #d6decc;padding:15px}#missions button span{display:block;font-size:10px;color:#5e796e;margin-bottom:6px}#missions button:hover{background:#d8e6cf}.primary{background:#1d574b;color:#fff8e8}.map-card{position:absolute;right:30px;bottom:32px;padding:14px;border-radius:20px;background:#fffaf0df;width:238px}.map-card>span{font-size:10px;letter-spacing:2px;font-weight:800}.map-card small{display:block;font-size:10px;color:#61766d}#map{width:210px;height:180px;display:block}.controls{position:absolute;bottom:35px;left:50%;transform:translateX(-50%);display:flex;gap:12px;align-items:stretch}.choices{display:flex;gap:6px}.choices button{font-size:24px;min-width:75px;box-shadow:0 5px 20px #143c3b15}.choices span,#go span{display:block;font-size:10px;margin-top:5px}.choices button.selected{background:#efb97b}#go{min-width:145px;touch-action:none;user-select:none}#go.held{background:#d0743e}#feedback{position:absolute;bottom:140px;left:50%;transform:translateX(-50%);max-width:560px;width:calc(100% - 50px);text-align:center;background:#fffaf0ed;border-radius:14px;padding:12px 18px;font-size:13px;line-height:1.4;box-shadow:0 4px 22px #12382d10}.menu{position:absolute;bottom:35px;left:30px;font-size:11px}body.intro .controls,body.intro #feedback,body.intro .menu{display:none}body.intro .map-card{bottom:28px}#fatal{top:30%;left:50%;transform:translateX(-50%)}
@media(max-width:950px){.map-card{display:none}.panel{top:290px;right:30px;max-height:calc(100dvh - 310px);overflow:auto}.controls{bottom:25px}.menu{bottom:115px;left:20px}#feedback{bottom:160px}header{top:16px;left:18px;right:18px}.navigator{left:18px;top:80px;width:calc(100% - 36px)}}
@media(max-width:540px){.brand{font-size:17px;gap:7px}.top-actions button{font-size:11px;padding:10px}.navigator{padding:15px 18px 0}.instruction-row{gap:12px;margin:9px 0}h1{font-size:19px}.instruction-row>span{font-size:30px}.eyebrow{font-size:9px}.panel{top:255px;left:18px;right:18px;width:auto;padding:20px;max-height:calc(100dvh - 270px)}h2{font-size:27px}.controls{width:calc(100% - 28px);gap:8px;bottom:20px}.choices{flex:1}.choices button{min-width:0;flex:1;padding:12px}.choices span{font-size:9px}#go{min-width:112px;padding:12px;font-size:14px}#go span{font-size:8px}#feedback{bottom:150px;font-size:12px}.menu{bottom:105px}#missions{margin:15px 0;gap:6px}#missions button{padding:12px}}
@media(max-height:600px) and (min-width:650px){.panel{top:85px;right:20px;left:auto;max-height:calc(100dvh - 100px);width:320px}.navigator{width:45%;top:85px}.controls{left:30px;transform:none;bottom:15px}#feedback{bottom:110px;width:48%;left:26%}.menu{bottom:190px}.map-card{display:none}}
/* Free driving HUD: the car stays visible between navigator and pedals. */
#upcoming{border-top:1px solid #dce2d5;padding:10px 0 4px;font-size:12px;color:#526d60;line-height:1.65}#upcoming div+div{margin-top:3px}.navigator{width:min(480px,calc(100% - 36px))}.map-card{width:278px}#map{width:250px;height:180px}.controls{left:30px;right:30px;bottom:25px;transform:none;justify-content:space-between;width:auto;pointer-events:none}.steering,.pedals{display:flex;gap:8px;pointer-events:auto}.controls button{touch-action:none;user-select:none;-webkit-user-select:none;min-width:75px;height:72px;font-size:23px;box-shadow:0 5px 20px #12382d24}.controls button span{display:block;font-size:10px;margin-top:4px}.controls button[data-drive=brake],.controls button[data-drive=drift]{font-size:14px}.controls button.held{background:#e9a465;color:#173c3b}.map-card{bottom:195px}.menu{padding:0;background:none;bottom:112px;left:30px;display:flex;gap:6px}.menu button{font-size:11px;padding:10px 12px}.dashboard{position:absolute;right:30px;bottom:112px;display:flex;align-items:center;gap:15px;background:#fffaf0ec;padding:10px 16px;border-radius:15px}.dashboard strong{font-size:26px}.dashboard small{font-size:10px;font-weight:500}.dashboard>span{font-size:12px}.wanted{color:#b33d32;font-weight:750}#feedback{bottom:110px;width:38%;font-size:12px;max-width:520px}#paused{position:absolute;left:50%;top:48%;transform:translateX(-50%);background:#173e38ed;color:#fff7df;padding:20px 28px;border-radius:18px;font-weight:700;z-index:5}body.intro .dashboard{display:none}.panel{max-height:calc(100dvh - 140px);overflow:auto}.top-actions button{font-size:12px}
@media(max-width:950px){.controls{left:18px;right:18px;bottom:20px}.menu{bottom:110px;left:18px}.dashboard{right:18px;bottom:110px}#feedback{width:calc(100% - 36px);bottom:165px}.panel{top:325px;max-height:calc(100dvh - 340px)}.navigator{width:min(480px,calc(100% - 36px))}}
@media(max-width:540px){header{align-items:flex-start;gap:8px}.brand{font-size:15px}.brand-icon{padding:7px 9px}.brand>span:last-child{font-size:10px}.top-actions{gap:4px;flex-wrap:wrap;justify-content:flex-end;max-width:175px}.top-actions button{font-size:10px;padding:8px 9px}.navigator{top:83px}.navigator h1{font-size:17px}.instruction-row{margin:8px 0}#upcoming{font-size:10px;padding:6px 0;line-height:1.45}.eyebrow{letter-spacing:1px}.panel{top:308px;max-height:calc(100dvh - 325px)}.panel h2{font-size:25px}.panel p{font-size:12px}.controls{left:10px;right:10px;bottom:15px;gap:8px;align-items:flex-end}.steering{gap:5px}.pedals{display:grid;grid-template-columns:repeat(2,62px);gap:5px}.controls button{min-width:0;width:62px;height:55px;font-size:25px;padding:6px}.controls button span{font-size:8px}.controls button[data-drive=drift],.controls button[data-drive=brake]{font-size:12px}.dashboard{bottom:143px;left:12px;right:12px;padding:8px 12px;justify-content:space-between}.dashboard strong{font-size:22px}.dashboard>span{font-size:11px}.menu{bottom:85px;left:10px;display:grid;gap:4px}.menu button{padding:7px 9px;font-size:9px}#feedback{bottom:197px;font-size:10px;padding:9px 12px;width:calc(100% - 24px)}#paused{font-size:12px;width:80%;text-align:center}.nav-bottom{font-size:10px}}
@media(max-height:600px) and (min-width:650px){.navigator{top:70px;width:40%;padding-top:12px}.navigator h1{font-size:17px}#upcoming{font-size:10px}.panel{top:80px;max-height:calc(100dvh - 100px)}.controls{left:18px;right:18px;bottom:12px}.controls button{height:55px;min-width:65px}.menu{bottom:80px}.dashboard{bottom:80px}#feedback{bottom:20px;left:45%;width:30%;font-size:10px}.map-card{display:none}}

#missions button small{display:block;margin-top:7px;line-height:1.45;font-weight:400}#missions button.primary{background:#1d574b;color:#fff8e8}#missions button.primary small{color:#e0eade}.dashboard>span{max-width:280px}

#order-card{position:absolute;top:105px;right:30px;width:340px;padding:19px;display:flex;gap:14px;background:#fffaf0f5;border:1px solid #e0dfcb;border-radius:22px;box-shadow:0 12px 35px #173d3820;pointer-events:none;animation:order-arrive .25s ease-out}
#customer-face{display:flex;align-items:center;justify-content:center;width:62px;height:70px;flex-shrink:0;border-radius:18px;background:#e6ebdc;font-size:43px}
#customer-name{display:block;margin-top:7px;font-size:14px}#customer-message{margin:7px 0 0;font-size:13px;line-height:1.5}
@keyframes order-arrive{from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:none}}
@media(max-width:950px){#order-card{top:310px;left:18px;right:auto;width:min(370px,calc(100% - 36px));padding:14px}#customer-message{font-size:12px}}
@media(max-height:650px){#order-card{top:75px;left:auto;right:18px;width:42%;max-width:340px;padding:12px}#customer-face{width:42px;height:50px;font-size:32px}}
@media(prefers-reduced-motion:reduce){#order-card{animation:none}}

#order-card{top:36%;left:50%;right:auto;transform:translate(-50%,-50%);width:min(440px,calc(100% - 36px));padding:22px;z-index:8;animation:order-center .25s ease-out}
#customer-message{font-size:16px}#customer-name{font-size:16px}#cargo{position:absolute;right:30px;top:82px;background:#fffaf0f2;border:1px solid #dce2cf;border-radius:20px;padding:10px 16px;font-size:13px;font-weight:700;pointer-events:none}
body.intro #cargo{display:none}
@keyframes order-center{from{opacity:0;transform:translate(-50%,-45%)}to{opacity:1;transform:translate(-50%,-50%)}}
@media(max-width:950px){#order-card{top:48%;padding:16px}#customer-message{font-size:14px}#cargo{top:auto;bottom:245px;right:18px}}
@media(prefers-reduced-motion:reduce){#order-card{animation:none}}

#order-stats{position:absolute;right:30px;top:130px;background:#fffaf0ed;border-radius:15px;padding:10px 16px;font-size:13px}body.intro #order-stats{display:none}@media(max-width:950px){#order-stats{top:auto;bottom:284px;right:18px;font-size:11px}}

#speed-limit{display:block;font-size:11px;font-weight:600;letter-spacing:.02em;margin-bottom:4px;color:#526e65}

#vehicle-care{position:absolute;left:30px;bottom:155px;background:#fffaf0ed;border-radius:16px;padding:12px 16px;display:grid;gap:6px;max-width:300px;font-size:13px;pointer-events:none}#vehicle-care[hidden]{display:none}#vehicle-care label{display:flex;align-items:center;gap:9px}#fuel-meter{width:100px;height:16px}#service-help{color:#526e65}@media(max-width:950px){#vehicle-care{left:16px;bottom:180px;max-width:230px;font-size:11px}}

/* Compact touch layout: reserve the bottom strip for simultaneous steering/pedals. */
#mobile-options{display:none}button{touch-action:manipulation}html,body{overscroll-behavior:none}
@media(max-width:950px),(pointer:coarse){
 header{top:max(8px,env(safe-area-inset-top));left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));height:36px;flex-wrap:nowrap}
 .brand{font-size:16px}.brand-icon{width:30px;height:30px}#mobile-options{display:block;min-width:44px;min-height:36px;padding:4px 12px}
 .top-actions{display:none!important;position:absolute;right:0;top:42px;max-width:230px!important;background:#fffaf0;padding:12px;border-radius:16px;flex-wrap:wrap;z-index:30}
 .options-open .top-actions{display:flex!important}.top-actions button{min-height:44px}
 .navigator{top:54px;left:10px;right:10px;width:auto;max-width:none;padding:10px 12px;border-radius:16px}
 .navigator .eyebrow,.navigator #upcoming,.navigator #progress,.navigator .track{display:none}
 .instruction-row{gap:10px;margin:0;padding-right:42px}.instruction-row h1{font-size:17px;line-height:1.25;margin:0}#direction{font-size:26px;min-width:28px;width:28px}
 .nav-bottom{position:absolute;right:7px;top:5px;margin:0}#repeat{font-size:0;width:40px;height:40px;padding:0}#repeat::after{content:'↻';font-size:24px}
 .panel,#welcome,#result{top:50%;left:50%;right:auto;bottom:auto;transform:translate(-50%,-50%);width:min(430px,calc(100% - 24px));max-height:calc(100dvh - 114px);overflow:auto;padding:20px}
 #welcome h2{font-size:26px;margin:8px 0}#welcome p{font-size:14px;margin:10px 0}#welcome>small{display:none}#welcome .hint{font-size:12px}#missions{gap:10px}#missions button{padding:13px}
 body.intro .navigator{display:none}
 .controls{left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));bottom:max(10px,env(safe-area-inset-bottom));gap:10px;align-items:flex-end}
 .steering,.pedals{display:flex;gap:6px}.controls button{min-width:0;width:58px;height:64px;padding:5px;font-size:26px;border-radius:16px}.controls button span{font-size:10px}.controls [data-drive=brake]{display:none}
 .dashboard{left:auto;right:10px;bottom:88px;padding:5px 10px;max-width:48%;font-size:10px;border-radius:12px}.dashboard strong{font-size:18px}#speed-limit{font-size:9px;margin:0}#alert{display:none}
 #vehicle-care{left:10px;bottom:88px;max-width:48%;padding:6px 9px;gap:3px;font-size:10px;border-radius:12px}#vehicle-care label{gap:4px}#fuel-meter{width:42px;height:10px}#engine-state{font-size:9px}#service-help{display:none}
 #cargo{top:112px;bottom:auto;left:10px;right:auto;padding:5px 8px;font-size:10px;border-radius:10px}#order-stats{top:142px;bottom:auto;right:auto;left:10px;padding:4px 8px;font-size:9px;border-radius:8px}
 #feedback{left:50%;right:auto;bottom:145px;transform:translateX(-50%);width:calc(100% - 24px);max-width:460px;padding:7px 10px;font-size:11px;pointer-events:none}
 .menu{display:none;left:auto;right:10px;bottom:auto;top:210px;z-index:31;background:#fffaf0;padding:10px;border-radius:12px}.options-open .menu{display:flex;flex-direction:column}.menu button{min-height:44px}
 .map-card{display:none;top:112px;bottom:auto;right:10px;width:210px;padding:10px;z-index:7}.map-open .map-card{display:block}.map-card canvas{width:190px;height:137px}
 #order-card{top:43%;width:min(390px,calc(100% - 24px));padding:14px;gap:10px;pointer-events:none}#customer-face{font-size:36px;min-width:42px;width:42px;height:48px}#customer-message{font-size:13px}#customer-name{font-size:14px}
 #paused{font-size:18px}
}
@media(max-width:950px) and (max-height:500px){
 .brand{display:none}.navigator{top:8px;left:10px;right:64px;width:auto;padding:8px 12px}.instruction-row h1{font-size:16px}
 #cargo{top:65px}#order-stats{top:91px}.controls button{height:58px;width:62px}
 #vehicle-care{bottom:10px;left:155px;max-width:190px}.dashboard{bottom:10px;right:155px;max-width:130px}
 #feedback{bottom:78px;width:52%;font-size:10px}#order-card{top:44%;width:360px;padding:12px}
 .panel,#welcome,#result{max-height:calc(100dvh - 24px);width:440px}#welcome .hint{margin-bottom:0}#welcome>p:not(.hint){display:none}
 .map-card{top:60px;width:180px}.map-card canvas{width:160px;height:115px}.menu{top:160px}
}

@media(max-width:950px) and (min-height:501px){#cargo{top:auto;bottom:189px}#order-stats{top:auto;bottom:165px}}
@media(max-width:950px),(pointer:coarse){header{z-index:20;pointer-events:none}header button,header a{pointer-events:auto}#mobile-options{margin-left:auto}.controls button span{font-size:9px;line-height:1.1;margin-top:2px}.controls button{line-height:1.1}}
@media(max-width:950px) and (max-height:500px){.controls button{height:64px}.controls button span{font-size:8px}}
@media(max-width:950px),(pointer:coarse){.map-card #map{width:190px;height:137px}}
@media(max-width:950px) and (max-height:500px){.map-card #map{width:160px;height:115px}}
@media(max-width:950px) and (min-height:501px){#feedback{bottom:217px}.map-card{top:160px}}

/* A real resume action, above temporary customer messages on every screen. */
#paused{z-index:40;min-height:52px;box-shadow:0 8px 32px #143c3b40;cursor:pointer}
@media(max-width:950px),(pointer:coarse){
 .brand,#vehicle-care,.dashboard,#order-stats{display:none!important}
 .navigator{top:max(8px,env(safe-area-inset-top));left:max(10px,env(safe-area-inset-left));right:64px;width:auto;padding:9px 10px}
 .instruction-row h1{font-size:15px}.instruction-row{padding-right:30px;gap:6px}#direction{font-size:22px;min-width:22px;width:22px}#repeat{width:32px}
 #cargo{top:auto;bottom:86px;left:10px;right:auto;font-size:10px;padding:4px 8px}
 #feedback{display:none;top:auto;bottom:116px;width:calc(100% - 24px);max-width:430px;font-size:11px;padding:7px 10px}
 #feedback.notice-active{display:block}
 #paused{width:auto;max-width:calc(100% - 24px);white-space:nowrap;font-size:15px;padding:16px 22px}
 .map-card{top:110px}
}
@media(max-width:950px) and (max-height:500px){#cargo{bottom:14px;left:155px}#feedback{bottom:86px;width:56%;font-size:10px}}

/* Driving view: one instruction, no secondary paragraphs or progress panel. */
.navigator .eyebrow,.navigator #upcoming,.navigator #progress,.navigator .track{display:none}
.navigator{padding:12px 14px;width:min(390px,calc(100% - 36px));border-radius:16px}
.instruction-row{margin:0;gap:10px;padding-right:38px}.instruction-row h1{font-size:18px;line-height:1.3}.instruction-row #direction{font-size:28px;min-width:26px;width:26px}
.navigator .nav-bottom{position:absolute;right:7px;top:8px;margin:0}.navigator #repeat{font-size:0;width:38px;height:38px;padding:0}.navigator #repeat::after{content:'↻';font-size:23px}
.menu{display:none!important}body.game-paused .menu{display:flex!important;position:absolute;top:calc(48% + 75px);bottom:auto;left:50%;right:auto;transform:translateX(-50%);z-index:41;white-space:nowrap}
body.game-paused .menu #recover{display:none}
@media(min-width:951px){.navigator{top:82px}header .brand{font-size:17px}.map-card{width:208px;padding:10px;bottom:190px}.map-card #map{width:188px;height:135px}.map-card>span,.map-card small{font-size:8px}}
@media(max-width:950px),(pointer:coarse){.navigator{width:auto;padding:9px 10px}.instruction-row h1{font-size:15px}.navigator #repeat{width:32px}.instruction-row{padding-right:30px}.instruction-row #direction{font-size:22px;min-width:22px;width:22px}}

/* Keep the road clear: status messages remain available to screen readers. */
#feedback,#feedback.notice-active{display:block!important;position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important}
.navigator .nav-bottom{display:none}.navigator{width:min(310px,calc(100% - 36px));padding:10px 12px}.instruction-row{padding-right:0;gap:8px}.instruction-row h1{font-size:16px}
#vehicle-care{padding:8px 10px;gap:4px;font-size:11px;border-radius:12px;max-width:225px}#vehicle-care label{gap:6px}#fuel-meter{width:65px;height:12px}#engine-state{font-size:11px}#service-help{display:none}
@media(max-width:950px),(pointer:coarse){.navigator{width:auto;max-width:310px}.instruction-row{padding-right:0}.instruction-row h1{font-size:14px}}

/* Navigation takes the former brand position. */
header .brand{display:none}header{justify-content:flex-end}.navigator{top:24px}
@media(max-width:950px),(pointer:coarse){.navigator{top:8px}}

#customer-wait{position:absolute;left:30px;top:108px;width:310px;padding:12px 14px;background:#fff8e8f5;border:1px solid #ddbd7b;border-radius:14px;color:#224f46;pointer-events:none;z-index:18;box-shadow:0 4px 16px #29483e18}#customer-wait[hidden]{display:none}#customer-wait strong{font-size:12px}#customer-wait p{font-size:13px;line-height:1.4;margin:5px 0 0}body.game-paused #customer-wait{display:none}
@media(max-width:950px),(pointer:coarse){#customer-wait{left:10px;top:92px;width:min(290px,calc(100% - 70px));padding:9px 11px}#customer-wait p{font-size:12px}}

#shift-dialog{width:min(370px,calc(100% - 24px));border:0;border-radius:18px;padding:22px;background:#fffaf0;color:#173c3b;text-align:center}
#shift-dialog::backdrop{background:#153e374a}#shift-dialog h2{margin:0 0 10px}#shift-dialog p{line-height:1.45}#shift-dialog button{margin:3px}
