:root{--ink:#173c34;--muted:#647368;--paper:#f7f4e9;--cream:#ede9d9;--coral:#cc6346;--gold:#e2bc6d;--line:rgba(31,63,51,.17);--safe-top:env(safe-area-inset-top,0px);--safe-right:env(safe-area-inset-right,0px);--safe-bottom:env(safe-area-inset-bottom,0px);--safe-left:env(safe-area-inset-left,0px);font-family:Arial,Helvetica,sans-serif;color:var(--ink);font-synthesis:none}
*{box-sizing:border-box}html,body{width:100%;height:100%;margin:0;overflow:hidden}body{background:#b8d4d1}button,input,select{font:inherit}button,a,select,input{ -webkit-tap-highlight-color:transparent}button{cursor:pointer;border:0;color:inherit}button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible,[tabindex]:focus-visible{outline:3px solid #cd6949;outline-offset:4px}button:disabled{opacity:.5;cursor:default}button{touch-action:manipulation}a{color:inherit}svg{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex:none}.hidden{display:none!important}#game-canvas{display:block;width:100%;height:100%;position:fixed;inset:0;outline:none;touch-action:none;background:linear-gradient(#a9ced3 0%,#e7e5cf 67%,#9aafa0 100%)}.scene-shade{position:fixed;inset:0;pointer-events:none;background:linear-gradient(90deg,rgba(247,244,233,.98) 0%,rgba(247,244,233,.95) 24%,rgba(247,244,233,.67) 38%,rgba(247,244,233,0) 62%);transition:opacity .4s}.topbar{position:fixed;top:0;left:0;right:0;z-index:20;display:flex;align-items:center;justify-content:space-between;gap:22px;padding:calc(30px + var(--safe-top)) calc(3.7vw + var(--safe-right)) 16px calc(3.7vw + var(--safe-left));pointer-events:none}.topbar>*{pointer-events:auto}.wordmark{display:flex;align-items:center;gap:10px;text-decoration:none;font-size:18px;font-weight:900;letter-spacing:1.6px;white-space:nowrap}.wordmark-light{font-weight:400;margin-left:5px;letter-spacing:2px}.brand-mark{height:29px;width:24px;transform:skew(-19deg);display:flex;gap:3px;align-items:center}.brand-mark i{height:25px;width:5px;background:var(--ink)}.brand-mark i:nth-child(2){height:17px}.brand-mark i:nth-child(3){height:10px}.header-edition{font-size:10px;font-weight:700;letter-spacing:2.3px;margin-right:auto;margin-left:24px}.top-actions{display:flex;align-items:center;gap:7px}.icon-button,.quiet-button{height:44px;min-width:44px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:rgba(247,244,233,.78);border:1px solid rgba(23,60,52,.1);backdrop-filter:blur(10px);transition:background .15s,transform .15s}.icon-button:hover,.quiet-button:hover{background:var(--paper);transform:translateY(-1px)}.quiet-button{border-radius:28px;padding:0 17px;gap:8px;font-size:12px;font-weight:700}.screen{position:fixed;inset:0}.home-screen,.garage-screen{padding:calc(125px + var(--safe-top)) calc(3.7vw + var(--safe-right)) calc(65px + var(--safe-bottom)) calc(5.2vw + var(--safe-left));pointer-events:none}.screen button,.screen a{pointer-events:auto}.hero-copy{width:min(420px,35vw);position:relative;z-index:2;top:50%;transform:translateY(-55%)}.eyebrow{font-size:10px;letter-spacing:2.4px;font-weight:700;display:flex;align-items:center;gap:12px;margin:0 0 28px}.edition-number{height:31px;min-width:31px;border:1px solid var(--ink);border-radius:50%;display:inline-flex;align-items:center;justify-content:center;font-weight:400;letter-spacing:0;font-size:12px}h1{font-family:Georgia,'Times New Roman',serif;font-size:clamp(49px,5.5vw,89px);font-weight:400;line-height:1.005;letter-spacing:-3.5px;margin:0 0 25px}h1 em{font-weight:400;color:var(--coral)}.hero-description{font-size:15px;line-height:1.65;color:#536257;margin:0 0 30px}.hero-actions{max-width:325px}.button{height:54px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:0 23px;border-radius:4px;font-size:13px;font-weight:700;text-align:left;transition:background .16s,transform .16s;letter-spacing:.1px}.button:hover{transform:translateY(-2px)}.primary{background:var(--ink);color:var(--paper);box-shadow:0 8px 22px rgba(23,60,52,.1)}.primary:hover{background:#255649}.primary>span:last-child{font-size:22px;font-weight:400}.secondary{background:rgba(247,244,233,.6);border:1px solid var(--line)}.secondary:hover{background:var(--paper)}.hero-actions>.primary{width:100%}.secondary-row{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:12px}.secondary-row>.button{height:46px;padding:0 16px;font-size:12px;min-width:139px}.text-button{background:none;padding:10px 0;min-height:44px;font-size:12px;font-weight:700;display:inline-flex;align-items:center;gap:11px}.text-button:hover{text-decoration:underline;text-underline-offset:5px}.first-drive-note{font-size:10px;line-height:1.6;color:#748075;max-width:285px;margin:21px 0 0;display:flex;align-items:flex-start;gap:10px}.small-line{width:17px;height:1px;background:#8e9789;flex:none;margin-top:7px}.destination-caption{position:absolute;right:calc(4.2vw + var(--safe-right));top:24%;color:var(--ink);text-align:right}.destination-caption>span:first-child{font-size:10px;font-weight:700;letter-spacing:3px;display:block;margin-bottom:13px}.destination-caption strong{font-family:Georgia,serif;font-weight:400;font-size:27px;line-height:1.13;display:block}.caption-rule{display:block;height:1px;background:currentColor;width:36px;margin:17px 0 12px auto;opacity:.6}.destination-caption small{font-size:8px;letter-spacing:1.6px;font-weight:700}.expedition-footer{position:absolute;bottom:calc(26px + var(--safe-bottom));left:calc(5.2vw + var(--safe-left));display:flex;gap:18px;align-items:center;font-size:10px;color:#627366;letter-spacing:.15px}.expedition-footer>span{display:flex;align-items:center;gap:8px}.status-dot{width:5px;height:5px;border-radius:50%;background:var(--coral)}.footer-divider{height:12px;width:1px;background:var(--line)}
body[data-screen="garage"]{background:#e9e4d7}body[data-screen="garage"] .scene-shade{background:linear-gradient(90deg,rgba(247,244,233,.98),rgba(247,244,233,.9) 24%,rgba(247,244,233,0) 55%)}.garage-copy{position:relative;z-index:2;width:min(385px,34vw);top:50%;transform:translateY(-52%)}.back-link{margin:0 0 25px;color:var(--muted);font-size:11px}.garage-copy h1{font-size:clamp(46px,5vw,73px);margin-bottom:21px}.garage-copy .eyebrow{font-size:9px;letter-spacing:1.7px;margin-bottom:23px}.garage-copy h1 em{font-size:.77em;letter-spacing:-2px;white-space:nowrap}.garage-copy .hero-description{margin-bottom:25px}.field-label{font-size:9px;font-weight:700;letter-spacing:1.9px;display:block}.paint-selector{margin:0 0 20px}.swatch-row{display:flex;gap:10px;margin-top:10px}.paint-swatch{width:44px;height:44px;background:none;border:1px solid transparent;border-radius:50%;padding:5px}.paint-swatch span{display:block;border-radius:50%;width:100%;height:100%;background:var(--paint);box-shadow:inset 0 -4px 0 rgba(0,0,0,.08)}.paint-swatch.selected,.paint-swatch[aria-pressed="true"]{border-color:var(--ink)}.garage-details{font-size:12px;line-height:1.8;color:var(--muted);margin:0 0 23px}.garage-details span{padding:0 5px}.garage-copy>.primary{width:280px;max-width:100%}.orbit-hint{position:absolute;bottom:calc(44px + var(--safe-bottom));left:66%;transform:translateX(-50%);display:flex;align-items:center;gap:10px;font-size:11px;color:var(--muted);white-space:nowrap}.orbit-hint svg{width:28px;height:28px}.garage-watermark{position:absolute;right:5%;bottom:6%;font-family:Georgia,serif;font-size:clamp(80px,13vw,180px);font-style:italic;color:rgba(23,60,52,.065);z-index:-1}
body[data-screen="race"] .scene-shade{opacity:0}body[data-screen="race"] .topbar{display:none}.race-hud{position:fixed;inset:0;pointer-events:none;padding:calc(24px + var(--safe-top)) calc(28px + var(--safe-right)) calc(24px + var(--safe-bottom)) calc(28px + var(--safe-left));color:var(--paper)}.race-top{display:flex;gap:24px;align-items:flex-start}.route-card{width:200px;background:rgba(17,47,41,.85);border:1px solid rgba(255,255,255,.12);backdrop-filter:blur(12px);padding:16px 18px;border-radius:7px}.route-card>.field-label{color:#d4dccc;font-size:9px}.route-progress{display:flex;align-items:baseline;gap:12px;margin:5px 0 9px}.route-progress #progress-text{font-size:27px;font-weight:700;letter-spacing:-1px}.route-word{font-size:8px;letter-spacing:1px;opacity:.7}.progress-track{height:3px;width:100%;background:rgba(255,255,255,.22);border-radius:2px;overflow:hidden}#progress-fill{display:block;height:100%;width:0%;background:var(--gold);border-radius:2px}.time-card{background:rgba(17,47,41,.83);border:1px solid rgba(255,255,255,.12);padding:14px 17px;border-radius:7px;min-width:113px;backdrop-filter:blur(12px)}.time-card .field-label{font-size:8px;color:#d4dccc}#race-time{font-variant-numeric:tabular-nums;font-size:22px;letter-spacing:.2px;display:block;margin-top:7px}.pause-button{margin-left:auto;background:rgba(17,47,41,.86);color:var(--paper);border:1px solid rgba(255,255,255,.2);pointer-events:auto;width:48px;height:48px}.pause-button:hover{background:var(--ink)}.lesson-card{position:absolute;top:calc(28px + var(--safe-top));left:50%;transform:translateX(-50%);width:min(390px,32vw);display:flex;gap:14px;background:rgba(247,244,233,.94);color:var(--ink);padding:16px 20px;border-radius:7px;box-shadow:0 7px 25px rgba(31,53,40,.12)}.lesson-number{font-size:9px;letter-spacing:.5px;white-space:nowrap;color:var(--coral);padding-top:5px;font-weight:700}.lesson-card h2{font-size:15px;margin:0 0 5px;font-weight:700}.lesson-card p{font-size:12px;line-height:1.45;margin:0;color:#5e6b60}.lesson-checks{display:flex;gap:6px;margin-top:9px;font-size:10px}.lesson-checks:empty{display:none}.lesson-checks span{height:4px;background:#ccd3c5;border-radius:3px;flex:1}.lesson-checks .done{background:var(--ink)}.speed-card{position:absolute;bottom:calc(33px + var(--safe-bottom));left:50%;transform:translateX(-50%);display:flex;align-items:baseline;gap:6px;text-shadow:0 2px 8px rgba(0,0,0,.6)}.speed-card strong{font-size:38px;line-height:1;font-weight:700;letter-spacing:-1px;font-variant-numeric:tabular-nums}.speed-card>span{font-size:9px;letter-spacing:1px;font-weight:700}
.touch-controls{position:fixed;inset:0;pointer-events:none;user-select:none;-webkit-user-select:none;touch-action:none;z-index:15}.touch-controls>*{pointer-events:auto}.simple-steering{position:absolute;left:calc(36px + var(--safe-left));bottom:calc(42px + var(--safe-bottom));width:210px;height:86px;display:flex;align-items:center;justify-content:space-between;padding:0 19px;border-radius:50px;background:rgba(18,46,41,.62);border:1px solid rgba(247,244,233,.4);backdrop-filter:blur(8px);touch-action:none;color:var(--paper)}.steer-arrow{font-size:27px;line-height:1;opacity:.65}.steer-rail{position:absolute;left:30px;right:30px;height:1px;background:rgba(247,244,233,.2)}.steer-thumb{position:absolute;left:calc(50% - 30px);top:12px;width:60px;height:60px;border-radius:50%;border:1px solid rgba(247,244,233,.55);background:rgba(247,244,233,.15);display:flex;align-items:center;justify-content:center;box-shadow:0 4px 12px rgba(0,0,0,.1);pointer-events:none}.steer-thumb svg{width:24px;height:24px}.control-caption{position:absolute;top:calc(100% + 10px);left:50%;transform:translateX(-50%);font-size:8px;font-weight:700;letter-spacing:1.5px;white-space:nowrap;color:var(--paper);text-shadow:0 1px 3px #16332c}.drive-action{position:absolute;bottom:calc(39px + var(--safe-bottom));right:calc(40px + var(--safe-right));width:120px;height:120px;border-radius:50%;background:rgba(234,191,99,.92);color:#41391f;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:5px;touch-action:none;border:4px solid rgba(255,243,196,.65);box-shadow:0 0 0 6px rgba(21,49,42,.3);font-size:11px;font-weight:700}.drive-action svg{height:32px;width:32px;stroke-width:1.5}.drive-action small{position:absolute;bottom:-26px;white-space:nowrap;font-weight:400;color:var(--paper);font-size:8px;text-shadow:0 1px 3px #16332c;right:-3px}.held{filter:brightness(1.2);box-shadow:0 0 0 5px rgba(247,230,151,.35)!important}.touch-wheel{position:absolute;left:calc(38px + var(--safe-left));bottom:calc(39px + var(--safe-bottom));width:162px;height:162px;touch-action:none}.wheel-face{position:absolute;inset:0;border:14px solid rgba(244,236,211,.9);border-radius:50%;background:rgba(20,44,37,.45);box-shadow:0 0 0 4px rgba(20,44,37,.55),inset 0 0 0 4px rgba(20,44,37,.55);display:flex;align-items:center;justify-content:center}.wheel-spoke{position:absolute;width:50%;height:11px;background:#d5d1be;left:50%;top:calc(50% - 5px);transform-origin:0 50%}.wheel-spoke.one{transform:rotate(0deg)}.wheel-spoke.two{transform:rotate(180deg)}.wheel-spoke.three{transform:rotate(90deg)}.wheel-hub{position:absolute;width:38px;height:38px;background:var(--ink);border-radius:50%;border:2px solid #bcbba9}.wheel-marker{position:absolute;top:-15px;left:calc(50% - 5px);height:17px;width:10px;background:var(--coral);border-radius:2px}.manual-pedals{position:absolute;right:calc(32px + var(--safe-right));bottom:calc(30px + var(--safe-bottom));display:flex;gap:14px;pointer-events:none}.pedal{pointer-events:auto;height:103px;width:77px;border-radius:15px;background:rgba(247,244,233,.85);border:1px solid rgba(255,255,255,.6);font-size:10px;font-weight:700;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:7px;touch-action:none}.pedal>span{font-size:28px}.throttle-pedal{background:rgba(231,189,98,.94);height:120px}.manual-actions{position:absolute;right:calc(40px + var(--safe-right));bottom:calc(178px + var(--safe-bottom));display:flex;gap:12px;pointer-events:none}.round-action{pointer-events:auto;width:65px;height:65px;border-radius:50%;background:rgba(247,244,233,.88);border:2px solid rgba(255,255,255,.6);font-size:11px;font-weight:700;touch-action:none}.boost-action{background:rgba(222,179,85,.95)}body[data-controls="simple"] .touch-wheel,body[data-controls="simple"] .manual-pedals,body[data-controls="simple"] .manual-actions{display:none}body[data-controls="manual"] .simple-steering,body[data-controls="manual"] .drive-action{display:none}
dialog{position:fixed;border:1px solid rgba(23,60,52,.12);background:var(--paper);color:var(--ink);border-radius:12px;max-height:calc(100dvh - 48px - var(--safe-top) - var(--safe-bottom));box-shadow:0 25px 100px rgba(10,37,27,.25);padding:32px;overflow:auto}dialog::backdrop{background:rgba(12,36,29,.42);backdrop-filter:blur(9px)}.settings-dialog{width:550px;max-width:calc(100vw - 28px)}.dialog-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:15px;margin-bottom:25px}.dialog-heading .eyebrow{margin:0 0 9px;font-size:8px;letter-spacing:2px}.dialog-heading h2,.pause-dialog h2{font-family:Georgia,serif;font-size:32px;font-weight:400;letter-spacing:-1px;margin:0}.dialog-heading>.icon-button{font-size:25px;flex:none;background:transparent;border-color:var(--line)}fieldset{border:0;padding:0;margin:0}.control-options legend{font-size:11px;letter-spacing:.2px;font-weight:700;margin-bottom:11px}.control-option{display:flex;align-items:flex-start;gap:12px;background:#efeddf;border:1px solid var(--line);border-radius:7px;padding:14px;margin-bottom:10px;cursor:pointer}.control-option:has(input:checked){background:#e5ebdd;border-color:#5e7b63}.control-option input{width:17px;height:17px;margin:2px 0 0;accent-color:var(--ink);flex:none}.option-heading{font-size:13px;font-weight:700;display:flex;align-items:center;gap:12px}.option-heading small{font-size:8px;font-weight:700;letter-spacing:1px;color:var(--coral)}.control-option p{margin:6px 0 0;font-size:12px;line-height:1.5;color:#687466}.keyboard-tip{font-size:11px;line-height:1.5;margin:17px 0;padding:0 1px}.keyboard-tip strong{display:block;margin-bottom:4px}.keyboard-tip span{color:var(--muted);display:block}.settings-grid{border-top:1px solid var(--line);margin-top:22px;padding-top:3px}.setting-row{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:13px 0;font-size:12px;border-bottom:1px solid rgba(23,60,52,.08);min-height:49px}.setting-row:last-child{border-bottom:0}.setting-detail{font-size:10px;color:var(--muted);display:block;margin-top:4px}.switch{appearance:none;-webkit-appearance:none;position:relative;width:38px;height:22px;border-radius:20px;background:#d5d9cb;flex:none;cursor:pointer;transition:background .2s}.switch:before{content:'';position:absolute;top:3px;left:3px;width:16px;height:16px;background:var(--paper);box-shadow:0 1px 3px #0002;border-radius:50%;transition:transform .2s}.switch:checked{background:var(--ink)}.switch:checked:before{transform:translateX(16px)}select{border:1px solid var(--line);background:var(--paper);color:var(--ink);border-radius:5px;min-height:38px;padding:0 9px;font-size:11px}.pause-dialog{width:365px;max-width:calc(100vw - 28px);padding:35px}.pause-dialog>.eyebrow{font-size:9px;letter-spacing:1.8px;margin-bottom:15px}.pause-dialog h2{font-size:34px;line-height:1.1}.pause-dialog>p:not(.eyebrow){font-size:13px;color:var(--muted);margin:14px 0 26px}.pause-actions{display:flex;flex-direction:column;gap:10px}.pause-actions>.text-button{align-self:center;margin-top:3px}
body[data-screen="results"] .scene-shade{background:rgba(23,60,52,.25);backdrop-filter:blur(4px)}.results-screen{display:flex;align-items:center;justify-content:center;padding:calc(95px + var(--safe-top)) 20px calc(25px + var(--safe-bottom));overflow:auto}.result-panel{background:var(--paper);border-radius:9px;padding:32px 40px;position:relative;width:min(490px,100%);box-shadow:0 15px 60px rgba(12,39,30,.16)}.result-panel>.eyebrow{font-size:9px;letter-spacing:1.7px;margin-bottom:18px}.result-panel h1{font-size:48px;letter-spacing:-2px;margin-bottom:15px;position:relative;z-index:1}.result-panel>p:not(.eyebrow){font-size:12px;line-height:1.6;color:var(--muted);max-width:350px;margin:0 0 18px}.finish-flourish{font-family:Georgia,serif;position:absolute;top:40px;right:30px;font-size:110px;font-weight:400;line-height:1;color:#e5b15e;opacity:.5}.result-stat{display:flex;align-items:center;gap:24px;border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:15px 0}.result-stat strong{font-size:29px;font-weight:400;letter-spacing:-.5px;font-variant-numeric:tabular-nums}.result-checks{font-size:11px;line-height:1.8;margin:13px 0;color:#59715c}.result-checks:empty{display:none}.result-actions{display:flex;flex-direction:column;gap:9px;margin-top:20px}.result-actions>.button{height:49px}.result-actions>.text-button{align-self:center;font-size:11px}.compatibility{position:fixed;inset:0;background:var(--paper);z-index:100;display:flex;align-items:center;justify-content:center;padding:24px}.compatibility>div{width:min(420px,100%)}.compatibility h1{font-size:56px;letter-spacing:-2px}.compatibility p:not(.eyebrow){font-size:15px;line-height:1.65;color:var(--muted);margin-bottom:25px}.reduced-motion *{scroll-behavior:auto}.reduced-motion *{transition:none!important;animation:none!important}
@media(min-width:1700px){.hero-copy{width:450px}.hero-description{font-size:17px}.hero-actions{max-width:350px}.hero-actions .button{font-size:14px;height:58px}.topbar{padding-top:40px}.destination-caption strong{font-size:32px}}
@media(max-width:1050px){.header-edition{display:none}.hero-copy{width:40vw}.home-screen,.garage-screen{padding-left:5vw}.scene-shade{background:linear-gradient(90deg,rgba(247,244,233,.98),rgba(247,244,233,.88) 28%,rgba(247,244,233,0) 69%)}h1{font-size:64px;letter-spacing:-3px}.hero-description{font-size:14px}.hero-actions{max-width:295px}.hero-actions .button{padding-left:16px;padding-right:16px;font-size:12px}.secondary-row{gap:9px}.secondary-row>.button{min-width:125px}.secondary-row .text-button{font-size:11px}.destination-caption{top:25%}.destination-caption strong{font-size:23px}.lesson-card{left:52%;width:34vw;gap:9px;padding:13px 15px}.race-top{gap:12px}.route-card{width:166px;padding:13px}.time-card{min-width:95px;padding:12px}.route-word{font-size:7px}.garage-copy{width:36vw}.garage-copy h1{font-size:53px}.garage-copy .hero-description{font-size:13px}}
@media(max-width:700px) and (orientation:portrait){.topbar{padding:calc(18px + var(--safe-top)) calc(20px + var(--safe-right)) 8px calc(20px + var(--safe-left));gap:10px}.wordmark{font-size:13px;letter-spacing:1px;gap:7px}.wordmark-light{letter-spacing:1px;margin-left:3px}.brand-mark{height:23px;width:18px;gap:2px}.brand-mark i{height:20px;width:4px}.brand-mark i:nth-child(2){height:14px}.brand-mark i:nth-child(3){height:8px}.top-actions{gap:3px}.top-actions .icon-button{width:39px;min-width:39px;height:42px;border:0;background:rgba(247,244,233,.65)}.settings-trigger{width:40px;min-width:40px;padding:0;border:0;background:rgba(247,244,233,.65)}.settings-trigger span{display:none}#fullscreen-btn{display:none}.home-screen,.garage-screen{padding:calc(100px + var(--safe-top)) 26px calc(36px + var(--safe-bottom));overflow-y:auto;pointer-events:auto}.scene-shade{background:linear-gradient(180deg,rgba(247,244,233,.98) 0%,rgba(247,244,233,.93) 29%,rgba(247,244,233,.48) 51%,rgba(247,244,233,0) 72%)}.hero-copy{width:100%;max-width:360px;top:auto;transform:none}.eyebrow{font-size:9px;letter-spacing:2px;margin-bottom:19px}.edition-number{height:27px;min-width:27px;font-size:11px}h1{font-size:61px;letter-spacing:-3px;margin-bottom:18px}.hero-description{font-size:13px;margin-bottom:20px;line-height:1.55}.hero-actions{max-width:290px}.hero-actions>.button{height:49px}.secondary-row{margin-top:8px}.secondary-row>.button{height:44px}.first-drive-note{font-size:9px;margin-top:15px}.destination-caption{display:none}.expedition-footer{left:26px;bottom:calc(17px + var(--safe-bottom));gap:12px;font-size:9px;color:var(--paper);text-shadow:0 1px 4px rgba(12,42,28,.8)}.expedition-footer .footer-divider{background:rgba(255,255,255,.3)}.expedition-footer>span:last-child,.expedition-footer>span:nth-last-child(2){display:none}body[data-screen="garage"] .scene-shade{background:linear-gradient(180deg,rgba(247,244,233,.98),rgba(247,244,233,.9) 23%,rgba(247,244,233,0) 63%)}.garage-copy{top:auto;transform:none;width:100%;max-width:360px}.back-link{margin:0 0 14px;min-height:28px;padding-top:0}.garage-copy .eyebrow{margin-bottom:16px;font-size:8px}.garage-copy h1{font-size:50px;margin-bottom:15px}.garage-copy .hero-description{display:none}.paint-selector{margin-bottom:15px}.garage-details{display:none}.garage-copy>.primary{width:240px;height:46px;font-size:12px}.orbit-hint{left:50%;bottom:calc(26px + var(--safe-bottom));font-size:10px}.garage-watermark{font-size:90px;bottom:8%;right:8%}.race-hud{padding:calc(16px + var(--safe-top)) 16px 20px}.race-top{gap:8px}.route-card{width:150px;padding:11px}.route-progress{margin:5px 0}.route-progress #progress-text{font-size:23px}.time-card{min-width:82px;padding:10px}.time-card #race-time{font-size:18px}.pause-button{height:43px;width:43px;min-width:43px}.lesson-card{left:16px;right:16px;top:calc(112px + var(--safe-top));transform:none;width:auto;padding:12px 14px;gap:11px}.lesson-card h2{font-size:14px}.lesson-card p{font-size:12px}.simple-steering{left:calc(18px + var(--safe-left));bottom:calc(44px + var(--safe-bottom));width:175px;height:73px;padding:0 16px}.steer-thumb{width:51px;height:51px;left:calc(50% - 25.5px);top:10px}.drive-action{width:97px;height:97px;right:calc(24px + var(--safe-right));bottom:calc(42px + var(--safe-bottom));font-size:9px;gap:4px;border-width:3px}.drive-action svg{height:26px;width:26px}.drive-action small{font-size:7px;right:-10px;white-space:normal;width:120px;line-height:1.3;bottom:-30px}.speed-card{bottom:calc(153px + var(--safe-bottom))}.speed-card strong{font-size:30px}.touch-wheel{width:130px;height:130px;left:calc(23px + var(--safe-left));bottom:calc(37px + var(--safe-bottom))}.wheel-face{border-width:12px}.manual-pedals{right:calc(17px + var(--safe-right));bottom:calc(30px + var(--safe-bottom));gap:9px}.pedal{width:60px;height:84px;font-size:9px}.throttle-pedal{height:101px}.manual-actions{right:calc(20px + var(--safe-right));bottom:calc(149px + var(--safe-bottom));gap:10px}.round-action{width:55px;height:55px;font-size:10px}.results-screen{padding-top:calc(95px + var(--safe-top));align-items:flex-start}.result-panel{padding:26px}.result-panel h1{font-size:43px}.result-panel>.eyebrow{font-size:8px;letter-spacing:1.4px}.result-panel .edition-number{height:25px;min-width:25px}.finish-flourish{font-size:90px;right:20px}.settings-dialog{padding:24px}.dialog-heading h2{font-size:30px}.dialog-heading{margin-bottom:20px}.settings-grid{margin-top:18px}.control-option{padding:12px}.compatibility h1{font-size:48px}}
@media(max-height:600px) and (orientation:landscape){.topbar{padding:calc(15px + var(--safe-top)) calc(25px + var(--safe-right)) 7px calc(25px + var(--safe-left))}.wordmark{font-size:14px;letter-spacing:1.2px}.brand-mark{height:24px}.brand-mark i{height:22px}.header-edition{display:none}.top-actions{gap:4px}.top-actions .icon-button{height:42px;min-width:42px}.quiet-button{font-size:11px;height:42px}.home-screen,.garage-screen{padding:calc(85px + var(--safe-top)) calc(30px + var(--safe-right)) calc(40px + var(--safe-bottom)) calc(34px + var(--safe-left));overflow-y:auto}.hero-copy{width:39vw;top:50%;transform:translateY(-50%)}.eyebrow{font-size:8px;margin-bottom:15px;letter-spacing:1.8px;gap:9px}.edition-number{height:24px;min-width:24px;font-size:10px}h1{font-size:49px;letter-spacing:-2px;margin-bottom:15px}.hero-description{font-size:12px;line-height:1.5;margin-bottom:19px}.hero-actions{max-width:280px}.hero-actions>.button{height:45px;font-size:11px}.secondary-row{margin-top:7px}.secondary-row>.button{height:44px;font-size:10px;min-width:115px;padding:0 12px}.secondary-row .text-button{font-size:10px}.first-drive-note{display:none}.destination-caption{top:24%;right:4%}.destination-caption strong{font-size:21px}.destination-caption>span:first-child{font-size:8px;letter-spacing:2px;margin-bottom:9px}.destination-caption small{font-size:7px}.expedition-footer{bottom:calc(15px + var(--safe-bottom));left:calc(34px + var(--safe-left));font-size:8px;gap:12px}.garage-copy{top:50%;transform:translateY(-50%);width:37vw}.back-link{min-height:28px;margin:0 0 10px;padding:0;font-size:10px}.garage-copy .eyebrow{font-size:7px;letter-spacing:1.2px;margin-bottom:12px}.garage-copy h1{font-size:42px;margin-bottom:17px}.garage-copy .hero-description,.garage-details{display:none}.paint-selector{margin-bottom:14px}.field-label{font-size:8px;letter-spacing:1.3px}.swatch-row{margin-top:5px;gap:8px}.paint-swatch{width:40px;height:40px}.garage-copy>.primary{width:240px;height:44px;font-size:11px}.orbit-hint{bottom:calc(22px + var(--safe-bottom));font-size:9px;left:68%;gap:8px}.race-hud{padding:calc(13px + var(--safe-top)) calc(20px + var(--safe-right)) 15px calc(20px + var(--safe-left))}.race-top{gap:9px}.route-card{width:140px;padding:10px 12px}.route-progress #progress-text{font-size:23px}.route-progress{margin:3px 0 6px;gap:8px}.route-card>.field-label{font-size:8px}.route-word{font-size:6px;letter-spacing:.4px}.time-card{min-width:90px;padding:10px 12px}.time-card .field-label{font-size:7px}.time-card #race-time{font-size:19px;margin-top:5px}.pause-button{height:43px;width:43px;min-width:43px}.lesson-card{top:calc(14px + var(--safe-top));left:56%;width:33vw;padding:11px 12px;gap:8px}.lesson-number{font-size:8px;padding-top:2px}.lesson-card h2{font-size:12px;margin-bottom:4px}.lesson-card p{font-size:10px;line-height:1.4}.lesson-checks{margin-top:6px}.speed-card{bottom:calc(20px + var(--safe-bottom))}.speed-card strong{font-size:29px}.speed-card>span{font-size:8px}.simple-steering{width:184px;height:72px;left:calc(29px + var(--safe-left));bottom:calc(32px + var(--safe-bottom));padding:0 16px}.steer-thumb{height:51px;width:51px;left:calc(50% - 25.5px);top:10px}.control-caption{top:calc(100% + 8px);font-size:7px;letter-spacing:1.2px}.drive-action{right:calc(35px + var(--safe-right));bottom:calc(31px + var(--safe-bottom));width:101px;height:101px;font-size:10px;gap:4px;border-width:3px}.drive-action svg{height:27px;width:27px}.drive-action small{bottom:-22px;font-size:7px;right:-1px}.touch-wheel{width:126px;height:126px;left:calc(30px + var(--safe-left));bottom:calc(28px + var(--safe-bottom))}.wheel-face{border-width:11px}.wheel-hub{width:30px;height:30px}.wheel-marker{top:-12px;height:13px;width:8px;left:calc(50% - 4px)}.manual-pedals{right:calc(25px + var(--safe-right));bottom:calc(21px + var(--safe-bottom));gap:10px}.pedal{height:80px;width:66px;font-size:9px;gap:5px}.pedal>span{font-size:24px}.throttle-pedal{height:96px}.manual-actions{right:calc(28px + var(--safe-right));bottom:calc(132px + var(--safe-bottom));gap:10px}.round-action{width:56px;height:56px;font-size:10px}.results-screen{padding:calc(75px + var(--safe-top)) 20px calc(20px + var(--safe-bottom));align-items:flex-start}.result-panel{width:570px;padding:22px 30px}.result-panel>.eyebrow{font-size:8px;margin-bottom:12px}.result-panel h1{font-size:37px;letter-spacing:-1.5px;margin-bottom:11px}.result-panel>p:not(.eyebrow){font-size:11px;margin-bottom:12px;max-width:100%}.result-stat{padding:8px 0}.result-stat strong{font-size:24px}.result-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:13px}.result-actions>.button{height:44px;font-size:10px;padding:0 15px}.result-actions>.text-button{grid-column:1/-1;justify-self:center;min-height:30px;padding:4px 0;font-size:10px}.finish-flourish{font-size:80px;right:30px;top:28px}.result-checks{font-size:10px;line-height:1.5;margin:9px 0}.settings-dialog{max-height:calc(100dvh - 20px);padding:23px}.pause-dialog{padding:26px;width:350px}.pause-dialog h2{font-size:31px}.pause-dialog>.eyebrow{margin-bottom:11px}.pause-dialog>p:not(.eyebrow){margin:10px 0 18px}.pause-actions>.button{height:44px}}
@media(max-height:390px) and (orientation:landscape){.topbar{padding-top:10px}.home-screen,.garage-screen{padding-top:65px;padding-bottom:25px}.hero-copy{top:auto;transform:none}.eyebrow{margin-bottom:9px}.hero-description{font-size:11px;margin-bottom:12px}h1{font-size:42px;margin-bottom:10px}.secondary-row{margin-top:5px}.expedition-footer{display:none}.garage-copy{top:auto;transform:none}.garage-copy h1{font-size:36px;margin-bottom:12px}.garage-copy .eyebrow{margin-bottom:8px}.back-link{margin-bottom:7px}.paint-selector{margin-bottom:10px}.swatch-row{margin-top:3px}.paint-swatch{height:37px;width:37px}.garage-copy>.primary{height:44px}.lesson-card{width:34vw;left:56%;padding:9px 11px}.lesson-card p{font-size:9px}.lesson-number{display:none}.manual-actions{right:calc(185px + var(--safe-right));bottom:calc(29px + var(--safe-bottom));flex-direction:column;gap:8px}.round-action{width:48px;height:48px;font-size:9px}.drive-action{width:89px;height:89px}.simple-steering{width:172px;height:65px}.steer-thumb{width:46px;height:46px;left:calc(50% - 23px);top:9px}}
/* Reading text keeps a useful size even when landscape space is tight. */
.hero-description,.control-option p,.keyboard-tip,.setting-row,.pause-dialog>p:not(.eyebrow),.result-panel>p:not(.eyebrow){font-size:14px}
.button,.text-button,.quiet-button,.option-heading{font-size:14px}
.hero-actions .button,.secondary-row>.button,.secondary-row .text-button,.garage-copy>.primary,.result-actions>.button{font-size:14px}
.setting-detail{font-size:12px}.keyboard-tip span{line-height:1.6}.control-option p{line-height:1.5}
.hero-actions{max-width:345px}.secondary-row{gap:13px}.secondary-row>.button{min-width:125px}.hero-copy{width:min(440px,38vw)}
.control-option input,.switch{min-height:22px}.setting-row{min-height:54px}
@media(max-width:700px) and (orientation:portrait){.hero-copy{width:100%;max-width:360px}.hero-actions{max-width:320px}.secondary-row>.button{min-width:132px}.hero-description{font-size:14px}.text-button,.button{font-size:14px}.hero-actions .button{font-size:14px}.first-drive-note{font-size:11px}.lesson-card p{font-size:13px}.settings-trigger{font-size:14px}.settings-dialog{padding:23px}.option-heading{font-size:14px}.option-heading small{font-size:9px}.setting-row{font-size:14px}.result-actions>.button{font-size:14px}}
@media(max-height:600px) and (orientation:landscape){.hero-copy{width:42vw;max-width:345px}.hero-description{font-size:14px;margin-bottom:15px}.hero-actions .button,.secondary-row>.button,.secondary-row .text-button,.garage-copy>.primary{font-size:13px}.lesson-card p{font-size:12px}.lesson-card h2{font-size:14px}.garage-copy{width:39vw}.garage-copy h1{font-size:42px}.result-panel>p:not(.eyebrow){font-size:14px}.result-actions>.button{font-size:13px}.garage-copy>.primary{width:250px}}
@media(max-height:390px) and (orientation:landscape){.hero-description{font-size:13px;margin-bottom:10px}.hero-copy{width:44vw;max-width:345px}.lesson-card p{font-size:11px}.lesson-card h2{font-size:13px}.garage-copy h1{font-size:36px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

/* Shared driving feedback: visible with keyboard and touch alike. */
.keyboard-hint{position:absolute;left:calc(28px + var(--safe-left));bottom:calc(24px + var(--safe-bottom));margin:0;padding:11px 15px;max-width:40%;font-size:12px;line-height:1.7;letter-spacing:.1px;color:var(--paper);background:rgba(18,47,40,.75);border:1px solid rgba(247,244,233,.12);border-radius:5px;backdrop-filter:blur(8px)}
.keyboard-hint span{padding:0 5px;opacity:.55}.touch .keyboard-hint{display:none}
.drift-meter{position:absolute;bottom:calc(86px + var(--safe-bottom));left:50%;transform:translateX(-50%);width:172px;text-align:center;text-shadow:0 1px 4px #133b2b;color:var(--paper)}
#drift-label{display:block;font-size:10px;font-weight:700;line-height:1.4;letter-spacing:.3px;margin-bottom:7px}.drift-track{height:5px;border-radius:4px;background:rgba(14,42,33,.48);border:1px solid rgba(247,244,233,.25);overflow:hidden}#drift-fill{display:block;width:0%;height:100%;background:var(--gold);border-radius:3px;transition:width .08s linear}.drift-meter.charged #drift-fill{background:#fff0b1}.drift-meter.charged #drift-label{color:#ffdf8e}.drive-action.charged{box-shadow:0 0 0 6px rgba(240,197,89,.4),0 0 24px rgba(255,225,141,.6);background:#f2d380}.drive-action.charged svg{transform:rotate(-8deg)}
/* Keep the entire uncovered kart area draggable, including portrait. */
.garage-screen{pointer-events:none!important}.garage-copy{pointer-events:none}.garage-copy button{pointer-events:auto}
@media(min-width:701px) and (min-height:601px){.lesson-card{left:58%;width:min(390px,30vw)}}
@media(max-width:700px) and (orientation:portrait){.drift-meter{bottom:calc(195px + var(--safe-bottom));width:170px}.keyboard-hint{left:16px;right:16px;bottom:calc(22px + var(--safe-bottom));max-width:none;font-size:12px}.hero-copy .text-button,.hero-copy .button{font-size:14px}.garage-copy>.primary{font-size:14px}}
@media(max-height:600px) and (orientation:landscape){.drift-meter{bottom:calc(61px + var(--safe-bottom));width:155px}#drift-label{font-size:9px;margin-bottom:5px}.keyboard-hint{bottom:calc(17px + var(--safe-bottom));left:calc(20px + var(--safe-left));font-size:11px;padding:8px 11px;max-width:38%}.hero-actions .button,.secondary-row>.button,.secondary-row .text-button,.garage-copy>.primary,.result-actions>.button{font-size:14px}.secondary-row{gap:10px}.hero-actions{max-width:340px}.secondary-row>.button{min-width:122px}.pause-dialog{max-height:calc(100dvh - 22px);padding:23px}.pause-actions{gap:8px}}
@media(max-height:390px) and (orientation:landscape){.drift-meter{bottom:calc(59px + var(--safe-bottom));width:140px}#drift-label{font-size:8px}.keyboard-hint{font-size:10px;max-width:37%;padding:6px 10px}}

body[data-screen="garage"] #game-canvas{background:radial-gradient(ellipse at 65% 36%,#f9f6eb 0%,#dedccc 72%,#cbd2bf 100%)}
.orbit-hint{padding:5px 12px;border-radius:24px;background:rgba(247,244,233,.86);color:#36564d;backdrop-filter:blur(8px)}

/* V2: blue open sky and warm haze match the richer wetland materials. */
#game-canvas{background:linear-gradient(#80b4dd 0%,#b7d1df 43%,#d6dfd7 74%,#94afa0 100%)}
body[data-screen="garage"] #game-canvas{background:radial-gradient(ellipse at 65% 36%,#f9f6eb 0%,#dedccc 72%,#cbd2bf 100%)}


/* V4 Mokoro collection: six real finishes on the same driven kart. */
.home-variant-name{font-weight:700;color:var(--ink)}
.garage-copy{width:min(390px,35vw)}
.garage-copy .hero-description{display:none}
.garage-copy .back-link{margin-bottom:18px}
.garage-copy .eyebrow{margin-bottom:18px}
.garage-copy h1{margin-bottom:25px}
.collection-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}
.collection-count{font-size:10px;font-variant-numeric:tabular-nums;letter-spacing:1.3px;color:var(--muted)}
.swatch-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:11px}
.paint-swatch{position:relative;width:auto;height:54px;padding:8px 9px;display:flex;align-items:center;gap:8px;border-radius:6px;border:1px solid rgba(23,60,52,.16);background:rgba(247,244,233,.68);text-align:left;transition:border-color .16s,background .16s,box-shadow .16s}
.paint-swatch:hover{background:rgba(255,253,247,.95);border-color:rgba(23,60,52,.5)}
.paint-swatch span{display:block;width:auto;height:auto;border-radius:0;background:none;box-shadow:none}
.paint-swatch .paint-chip{width:21px;height:28px;flex:none;border-radius:6px;background:linear-gradient(145deg,rgba(255,255,255,.26),transparent 48%,rgba(0,0,0,.14)),var(--paint);box-shadow:inset 0 0 0 1px rgba(0,0,0,.08),0 2px 3px rgba(23,60,52,.1);transform:skew(-7deg)}
.paint-swatch .paint-name{font-size:11px;font-weight:700;line-height:1.25;padding-right:1px}
.paint-swatch .paint-selected{position:absolute;top:2px;right:4px;font-size:10px;font-weight:700;opacity:0}
.paint-swatch.selected,.paint-swatch[aria-pressed="true"]{border-color:var(--ink);background:#fffdf5;box-shadow:inset 0 0 0 1px var(--ink),0 2px 7px rgba(23,60,52,.06)}
.paint-swatch[aria-pressed="true"] .paint-selected{opacity:1}
.variant-caption{min-height:53px;margin-top:13px;padding-left:1px}
.variant-caption strong{display:block;font-family:Georgia,'Times New Roman',serif;font-size:20px;font-weight:400;line-height:1.1;color:var(--ink)}
.variant-caption>span{display:block;font-size:12px;line-height:1.4;color:var(--muted);margin-top:5px;max-width:340px}
.paint-selector{margin-bottom:18px}
.garage-details{font-size:11px;line-height:1.6;margin-bottom:19px}
.speed-card .surface-badge{font-size:8px;line-height:1;letter-spacing:1px;padding:6px 8px;border-radius:16px;border:1px solid rgba(247,244,233,.25);background:rgba(17,47,41,.65);color:#f3ecd5;align-self:center;margin-left:5px;white-space:nowrap;text-shadow:none}
.speed-card .surface-badge[data-surface="mud"]{background:rgba(95,63,35,.8)}
.speed-card .surface-badge[data-surface="grass"]{background:rgba(40,79,49,.82)}
.speed-card .surface-badge[data-surface="water"]{background:rgba(33,83,99,.84)}
@media(max-width:1050px) and (min-height:601px) and (orientation:landscape){
 .garage-copy{width:38vw}.paint-swatch{gap:6px;padding:7px}.paint-swatch .paint-chip{width:17px;height:26px}.paint-swatch .paint-name{font-size:10px}
}
@media(max-width:700px) and (orientation:portrait){
 .garage-screen{padding-top:calc(90px + var(--safe-top))}
 .garage-copy{width:100%;max-width:360px}
 .garage-copy .back-link{margin-bottom:9px;min-height:30px}
 .garage-copy .eyebrow{margin-bottom:10px;font-size:8px;letter-spacing:1.35px}
 .garage-copy h1{font-size:38px;letter-spacing:-1.8px;margin-bottom:17px}
 .garage-copy h1 em{font-size:.86em;letter-spacing:-1.3px}
 .collection-heading .field-label{font-size:8px;letter-spacing:1.2px}
 .collection-count{font-size:9px}
 .swatch-row{gap:6px;margin-top:8px}
 .paint-swatch{height:48px;padding:7px;gap:7px}
 .paint-swatch .paint-chip{width:18px;height:26px}
 .paint-swatch .paint-name{font-size:10px;line-height:1.25}
 .variant-caption{min-height:42px;margin-top:10px}
 .variant-caption strong{font-size:17px}
 .variant-caption>span{font-size:10px;margin-top:4px;line-height:1.4}
 .paint-selector{margin-bottom:12px}
 .garage-copy>.primary{height:46px;width:240px}
 .orbit-hint{bottom:calc(21px + var(--safe-bottom));font-size:10px}
}
@media(max-height:600px) and (orientation:landscape){
 .garage-screen{padding-top:calc(76px + var(--safe-top));padding-bottom:calc(19px + var(--safe-bottom))}
 .garage-copy{width:39vw;max-width:365px;top:0;transform:none}
 .garage-copy .back-link{min-height:24px;margin-bottom:6px;font-size:11px}
 .garage-copy .eyebrow{display:none}
 .garage-copy h1{font-size:32px;line-height:1.05;letter-spacing:-1px;margin-bottom:12px}
 .garage-copy h1 br{display:none}.garage-copy h1 em{font-size:.82em;letter-spacing:-1px;margin-left:5px}
 .collection-heading .field-label{font-size:8px;letter-spacing:1px}
 .collection-count{font-size:8px}
 .swatch-row{gap:5px;margin-top:7px}
 .paint-swatch{height:44px;padding:6px;gap:6px}
 .paint-swatch .paint-chip{width:16px;height:25px}
 .paint-swatch .paint-name{font-size:10px}
 .variant-caption{min-height:16px;margin-top:8px}
 .variant-caption strong{font-family:Arial,Helvetica,sans-serif;font-size:11px;font-weight:700}
 .variant-caption>span{display:none}
 .paint-selector{margin-bottom:10px}
 .garage-copy>.primary{height:44px;width:250px;font-size:13px}
 .surface-badge{max-width:74px;overflow:hidden;text-overflow:ellipsis}
}
@media(max-height:390px) and (orientation:landscape){
 .garage-screen{padding-top:calc(65px + var(--safe-top))}
 .garage-copy .back-link{margin-bottom:5px}
 .garage-copy h1{font-size:29px;margin-bottom:10px}
}

/* Wild Racing: destinations, machines and an explicit accelerator. */
.home-screen .hero-copy{width:min(438px,39vw)}
.home-screen .eyebrow{margin-bottom:19px}
.home-screen h1{font-size:clamp(50px,5.15vw,80px);margin-bottom:17px}
.home-screen .hero-description{font-size:14px;line-height:1.5;margin:0 0 21px;max-width:365px}
.map-picker{margin-bottom:19px;width:100%;max-width:390px}
.route-count{font-size:8px;letter-spacing:1px;color:var(--muted);white-space:nowrap}
.map-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:9px}
.map-option{position:relative;min-width:0;min-height:103px;padding:10px 10px 11px;background:rgba(247,244,233,.77);border:1px solid var(--line);border-radius:7px;text-align:left;transition:background .15s,border-color .15s,transform .15s;overflow:hidden}
.map-option:hover{background:#fffdf5;border-color:#819187;transform:translateY(-2px)}
.map-option.selected,.map-option[aria-pressed="true"]{background:#fdfbf1;border-color:var(--ink);box-shadow:inset 0 0 0 1px var(--ink)}
.map-option svg{display:block;width:100%;height:34px;stroke:var(--ink);margin:3px 0 9px;stroke-width:1.8;fill:none}
.map-option .map-route{stroke-width:2;stroke:var(--coral)}
.map-option .map-water{stroke:#94b6a5;stroke-width:1.2;opacity:.65}
.map-option[data-map="makgadikgadi"] .map-water{stroke:#b4a287}
.map-option[data-map="chobe"] .map-water{stroke:#5d8a5f}
.map-option circle{fill:var(--coral);stroke:#fdfbf1;stroke-width:1}
.map-option strong{font-size:11px;line-height:1.3;letter-spacing:-.1px;display:block;white-space:nowrap}
.map-option>span{display:block;font-size:9px;line-height:1.35;color:var(--muted);margin-top:3px;white-space:nowrap}
.map-option>i{position:absolute;right:7px;top:6px;font-size:8px;font-style:normal;letter-spacing:.8px;color:#889386}
.hero-actions{max-width:390px}
.hero-actions .secondary-row{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-top:9px}
.hero-actions .secondary-row>.button{min-width:0;padding:0 15px;height:44px;font-size:12px}
.hero-actions>.primary{height:51px;font-size:14px;padding:0 19px}
.primary .race-button-note{font-size:8px;font-weight:400;letter-spacing:1.2px;white-space:nowrap;opacity:.75;margin-left:auto}
.hero-actions .garage-entry{display:flex;justify-content:space-between;gap:10px;width:100%;font-size:12px;margin-top:4px;min-height:42px}
.garage-entry .home-variant-name{font-size:10px;color:var(--muted);font-weight:400;margin-left:auto}
.first-drive-note{margin-top:7px;font-size:10px;max-width:none}
.destination-caption small{max-width:170px;display:block;margin-left:auto;line-height:1.7}
.garage-copy{width:min(400px,36vw)}
.garage-copy .back-link{margin-bottom:10px}
.garage-copy .eyebrow{margin-bottom:12px;font-size:8px;letter-spacing:1.7px}
.garage-copy h1{font-size:50px;line-height:1.06;margin-bottom:18px}
.garage-copy h1 em{font-size:.8em}
.vehicle-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-bottom:19px}
.vehicle-option{border:1px solid var(--line);background:rgba(247,244,233,.72);border-radius:6px;padding:8px;min-width:0;min-height:86px;text-align:left;transition:background .15s,border-color .15s}
.vehicle-option:hover{background:#fffdf5;border-color:#819187}
.vehicle-option.selected,.vehicle-option[aria-pressed="true"]{border-color:var(--ink);background:#fffdf5;box-shadow:inset 0 0 0 1px var(--ink)}
.vehicle-option svg{height:31px;width:100%;display:block;stroke-width:1.3;margin-bottom:6px}
.vehicle-option strong{display:block;font-size:11px;line-height:1.2;white-space:nowrap}
.vehicle-option>span{display:block;font-size:9px;line-height:1.3;color:var(--muted);margin-top:3px}
.paint-selector{margin-bottom:12px}
.swatch-row{gap:6px;margin-top:8px}
.paint-swatch{height:46px}
.paint-swatch .paint-chip{height:24px;width:18px}
.variant-caption{min-height:0;margin-top:9px}
.variant-caption strong{font-family:Arial,Helvetica,sans-serif;font-size:11px;font-weight:700}
.variant-caption>span{font-size:11px;line-height:1.4;margin-top:4px}
.garage-details{display:block;font-size:11px;line-height:1.45;margin:11px 0 16px}
.garage-details p{margin:0 0 5px;color:var(--muted)}
.garage-details>span{padding:0;font-size:10px;color:var(--ink)}
.garage-copy>.primary{height:49px;font-size:13px;width:100%;max-width:280px}
.position-card{border:1px solid rgba(255,255,255,.12);background:rgba(17,47,41,.87);border-radius:7px;padding:12px 17px;min-width:100px;backdrop-filter:blur(12px)}
.position-card .field-label{font-size:8px;color:#d4dccc;letter-spacing:1.2px}
.position-card strong{font-size:35px;line-height:1;display:block;margin-top:6px;color:var(--gold);font-variant-numeric:tabular-nums}
.position-card strong small{font-size:19px;font-weight:400;color:var(--paper)}
.race-top{gap:12px}
.race-countdown{position:absolute;top:42%;left:50%;transform:translate(-50%,-50%);min-width:140px;text-align:center;font-family:Georgia,'Times New Roman',serif;font-size:112px;font-style:italic;font-weight:700;color:#fff5d8;text-shadow:0 3px 0 rgba(23,60,52,.4),0 9px 40px rgba(13,40,31,.75);line-height:1;z-index:2}
.race-standings{position:absolute;left:calc(28px + var(--safe-left));top:calc(134px + var(--safe-top));list-style:none;margin:0;padding:9px 12px;width:175px;background:rgba(17,47,41,.76);border:1px solid rgba(255,255,255,.13);border-radius:6px;color:#e9eedc;font-size:11px;line-height:1.65;backdrop-filter:blur(10px);font-variant-numeric:tabular-nums}
.race-standings li{display:flex;align-items:center;justify-content:space-between;gap:9px;padding:2px 0}
.race-standings li.player,.race-standings li[data-player="true"],.race-standings .is-player{color:#ffe0a1;font-weight:700}
.race-standings .standing-name{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.race-standings .standing-gap{font-size:9px;opacity:.8;margin-left:auto}
.result-rank{font-size:16px;font-weight:700;color:var(--coral);margin-left:auto;white-space:nowrap}
.result-standings{list-style:none;padding:7px 0;margin:11px 0 0;border-bottom:1px solid var(--line);font-size:12px;line-height:1.45}
.result-standings li{display:flex;gap:12px;justify-content:space-between;align-items:center;padding:7px 5px;border-bottom:1px solid rgba(23,60,52,.06)}
.result-standings li:last-child{border:0}
.result-standings .player,.result-standings [data-player="true"],.result-standings .is-player{background:#e9eddf;border-radius:4px;font-weight:700}
.result-standings .standing-name{margin-right:auto}
.result-standings .standing-time,.result-standings .standing-gap{font-variant-numeric:tabular-nums;font-size:11px;color:var(--muted)}
body[data-controls="pedals"] .touch-wheel,body[data-controls="pedals"] .drive-action{display:none}
body[data-controls="pedals"] .simple-steering{display:flex}
body[data-controls="pedals"] .manual-pedals,body[data-controls="pedals"] .manual-actions{display:flex}
body[data-controls="pedals"] .throttle-pedal{background:rgba(237,195,100,.97);border-color:#fae1a2;box-shadow:0 0 0 3px rgba(20,45,36,.25)}
body[data-controls="pedals"] .brake-pedal{background:rgba(238,239,219,.92)}
@media(min-width:701px) and (min-height:601px){
 .home-screen{padding-top:calc(107px + var(--safe-top));padding-bottom:calc(52px + var(--safe-bottom))}
 .home-screen .hero-copy{transform:translateY(-50%)}
 .garage-screen{padding-top:calc(103px + var(--safe-top));padding-bottom:calc(36px + var(--safe-bottom))}
 .garage-copy{transform:translateY(-50%)}
 body[data-screen="race"] .lesson-card{left:65%;width:min(340px,28vw)}
}
@media(min-width:701px) and (min-height:601px) and (max-height:820px){
 .home-screen h1{font-size:58px}.home-screen .eyebrow{margin-bottom:12px}.home-screen .hero-description{margin-bottom:14px}.map-option{min-height:90px;padding:8px}.map-picker{margin-bottom:14px}.map-option svg{margin-bottom:6px;height:28px}
 .garage-copy h1{font-size:39px;margin-bottom:13px}.garage-copy h1 br{display:none}.garage-copy h1 em{margin-left:5px}.vehicle-option{min-height:77px}.vehicle-options{margin-bottom:14px}.variant-caption>span{display:none}.garage-details{margin:10px 0 13px}
}
@media(max-width:700px) and (orientation:portrait){
 .home-screen{padding:calc(86px + var(--safe-top)) 23px calc(40px + var(--safe-bottom))}
 .home-screen .hero-copy{width:100%;max-width:420px;transform:none;top:0}
 .home-screen .eyebrow{font-size:8px;letter-spacing:1.5px;gap:9px;margin-bottom:12px}
 .home-screen .edition-number{height:24px;min-width:24px;font-size:10px}
 .home-screen h1{font-size:49px;line-height:.98;letter-spacing:-2px;margin-bottom:13px}
 .home-screen .hero-description{font-size:12px;line-height:1.45;margin-bottom:16px;max-width:320px}
 .map-picker{max-width:none;margin-bottom:15px}
 .map-picker .field-label{font-size:8px;letter-spacing:1.2px}.route-count{font-size:7px;letter-spacing:.8px}
 .map-options{gap:6px;margin-top:8px}.map-option{min-height:91px;padding:8px}
 .map-option svg{height:28px;margin:3px 0 7px}.map-option strong{font-size:10px;letter-spacing:-.15px}.map-option>span{font-size:8px;margin-top:3px}.map-option>i{font-size:7px;top:5px;right:6px}
 .hero-actions{max-width:none}.hero-actions>.primary{height:48px;font-size:14px}.primary .race-button-note{font-size:7px;letter-spacing:1px}
 .hero-actions .secondary-row>.button{font-size:12px;height:42px;padding:0 13px}.hero-actions .garage-entry{font-size:12px;min-height:39px;margin-top:2px}.garage-entry .home-variant-name{font-size:10px}.first-drive-note{display:none}
 .expedition-footer{font-size:9px;left:23px}.expedition-footer>span:nth-child(3){display:none}.expedition-footer .footer-divider{display:none}
 .garage-screen{padding:calc(81px + var(--safe-top)) 23px calc(24px + var(--safe-bottom))}
 .garage-copy{width:100%;max-width:420px}
 .garage-copy .back-link{min-height:27px;font-size:11px;margin-bottom:7px;padding:0}
 .garage-copy .eyebrow{display:none}
 .garage-copy h1{font-size:31px;line-height:1.05;margin-bottom:13px;letter-spacing:-1.3px}
 .garage-copy h1 br{display:none}.garage-copy h1 em{font-size:.85em;letter-spacing:-.7px;margin-left:4px}
 .vehicle-options{gap:6px;margin-bottom:13px}.vehicle-option{padding:7px;min-height:70px}.vehicle-option svg{height:24px;margin-bottom:5px}.vehicle-option strong{font-size:10px}.vehicle-option>span{font-size:8px;margin-top:3px}
 .collection-heading .field-label{font-size:8px}.swatch-row{margin-top:7px;gap:6px}.paint-swatch{height:43px;padding:6px;gap:6px}.paint-swatch .paint-chip{height:23px;width:16px}.paint-swatch .paint-name{font-size:9px}
 .variant-caption{margin-top:8px;min-height:0}.variant-caption strong{font-size:10px}.variant-caption>span{display:none}.paint-selector{margin-bottom:9px}
 .garage-details{display:block;margin:0 0 12px;font-size:10px;line-height:1.4}.garage-details p{display:none}.garage-details>span{font-size:10px;padding:0}
 .garage-copy>.primary{height:44px;max-width:250px;font-size:12px}.orbit-hint{bottom:calc(19px + var(--safe-bottom));font-size:9px}
 .race-hud{padding-left:14px;padding-right:14px}.race-top{gap:7px}
 .position-card{min-width:65px;padding:9px 10px}.position-card .field-label{font-size:7px;letter-spacing:.7px}.position-card strong{font-size:29px;margin-top:7px}.position-card strong small{font-size:15px}
 .route-card{width:128px;padding:10px}.route-card>.field-label{font-size:8px;letter-spacing:1px}.route-progress{gap:6px}.route-progress #progress-text{font-size:22px}.route-word{font-size:6px;letter-spacing:.3px;line-height:1.4}
 .time-card{min-width:72px;padding:10px 9px}.time-card .field-label{font-size:7px;letter-spacing:.7px}.time-card #race-time{font-size:16px;margin-top:8px}.pause-button{height:41px;min-width:41px;width:41px}
 .race-countdown{top:39%;font-size:94px;min-width:110px}
 .race-standings{left:14px;top:calc(102px + var(--safe-top));width:142px;padding:7px 10px;font-size:10px;line-height:1.55}
 .race-standings .standing-gap{font-size:8px}
 body[data-controls="pedals"] .simple-steering{width:151px;height:73px;left:calc(17px + var(--safe-left));bottom:calc(43px + var(--safe-bottom))}
 .manual-pedals{right:calc(16px + var(--safe-right));bottom:calc(31px + var(--safe-bottom));gap:8px}.pedal{width:61px;height:87px;font-size:10px}.throttle-pedal{height:105px}.pedal>span{font-size:26px}
 .manual-actions{right:calc(19px + var(--safe-right));bottom:calc(154px + var(--safe-bottom));gap:12px}.round-action{width:53px;height:53px;font-size:10px}
 .touch .speed-card{bottom:calc(164px + var(--safe-bottom));left:31%;}.touch .drift-meter{bottom:calc(216px + var(--safe-bottom));left:31%;width:150px}
 .touch .speed-card .surface-badge{position:absolute;top:calc(100% + 8px);left:50%;transform:translateX(-50%);margin:0;font-size:7px}
 .result-stat{gap:16px}.result-rank{font-size:13px}.result-standings{font-size:11px}.result-standings li{padding:7px 3px}.result-actions{margin-top:15px}
}
@media(max-width:360px) and (orientation:portrait){
 .topbar{padding-left:14px;padding-right:14px}.wordmark{font-size:12px}.home-screen,.garage-screen{padding-left:17px;padding-right:17px}.map-option{padding:7px 6px}.map-option strong{font-size:9px}.map-option>span{font-size:7px}.vehicle-option strong{font-size:9px}.paint-swatch .paint-name{font-size:8px}
 .race-hud{padding-left:10px;padding-right:10px}.race-top{gap:5px}.position-card{padding:9px 8px;min-width:59px}.route-card{width:106px;padding:10px 8px}.time-card{min-width:65px;padding:10px 7px}.time-card #race-time{font-size:15px}.pause-button{width:38px;height:38px;min-width:38px}
 body[data-controls="pedals"] .simple-steering{width:133px;left:12px}.manual-pedals{right:12px;gap:7px}.pedal{width:57px;font-size:9px}.manual-actions{right:14px;gap:10px}.round-action{width:51px;height:51px}.touch .drift-meter{width:130px}.touch .speed-card{left:28%}.touch .drift-meter{left:28%}
}
@media(max-height:600px) and (orientation:landscape){
 .home-screen,.garage-screen{padding-top:calc(73px + var(--safe-top));padding-bottom:calc(20px + var(--safe-bottom));overflow-y:auto}
 .home-screen .hero-copy{width:42vw;max-width:390px;top:0;transform:none}
 .home-screen .eyebrow{font-size:7px;letter-spacing:1.2px;gap:8px;margin-bottom:8px}.home-screen .edition-number{height:21px;min-width:21px;font-size:9px}
 .home-screen h1{font-size:38px;letter-spacing:-1.5px;line-height:1;margin-bottom:9px}.home-screen h1 br{display:none}.home-screen h1 em{margin-left:7px}
 .home-screen .hero-description{font-size:11px;line-height:1.4;margin-bottom:11px;max-width:none}
 .map-picker{margin-bottom:11px;max-width:none}.map-picker .field-label{font-size:7px;letter-spacing:1.1px}.route-count{font-size:7px;letter-spacing:.7px}
 .map-options{margin-top:6px;gap:6px}.map-option{min-height:76px;padding:6px 8px}.map-option svg{height:23px;margin:2px 0 5px}.map-option strong{font-size:10px}.map-option>span{font-size:8px;margin-top:2px}.map-option>i{font-size:6px}
 .hero-actions{max-width:none;display:grid;grid-template-columns:1fr;gap:0}.hero-actions>.primary{height:44px;padding:0 16px;font-size:12px}.primary .race-button-note{font-size:7px;letter-spacing:1px}.hero-actions .secondary-row{margin-top:7px;gap:7px}.hero-actions .secondary-row>.button{height:40px;min-height:40px;padding:0 12px;font-size:11px}.hero-actions .garage-entry{font-size:11px;min-height:35px;padding:7px 0;margin-top:0}.garage-entry .home-variant-name{font-size:9px}
 .first-drive-note,.expedition-footer{display:none}.destination-caption{top:24%}
 .garage-copy{width:40vw;max-width:370px;top:0;transform:none}.garage-copy .back-link{min-height:22px;margin-bottom:4px;font-size:10px}.garage-copy .eyebrow{display:none}.garage-copy h1{font-size:28px;line-height:1;margin-bottom:10px}.garage-copy h1 br{display:none}.garage-copy h1 em{font-size:.8em;letter-spacing:-.7px;margin-left:5px}
 .vehicle-options{gap:5px;margin-bottom:10px}.vehicle-option{min-height:61px;padding:6px 7px}.vehicle-option svg{height:21px;margin-bottom:4px}.vehicle-option strong{font-size:9px}.vehicle-option>span{font-size:7px;margin-top:2px}
 .collection-heading .field-label{font-size:7px;letter-spacing:1px}.swatch-row{margin-top:6px;gap:5px}.paint-swatch{height:40px;padding:5px;gap:5px}.paint-swatch .paint-chip{width:15px;height:22px}.paint-swatch .paint-name{font-size:9px}
 .variant-caption{display:none}.paint-selector{margin-bottom:10px}.garage-details{display:none}.garage-copy>.primary{height:42px;font-size:12px;width:100%;max-width:260px}
 .position-card{min-width:69px;padding:9px 11px}.position-card .field-label{font-size:7px;letter-spacing:.8px}.position-card strong{font-size:29px;margin-top:5px}.position-card strong small{font-size:15px}
 .race-top{gap:8px}.race-countdown{font-size:83px;top:45%}.race-standings{left:20px;top:calc(93px + var(--safe-top));width:139px;padding:6px 9px;font-size:9px;line-height:1.4}.race-standings .standing-gap{font-size:8px}
 body[data-controls="pedals"] .simple-steering{width:175px;height:68px;left:calc(26px + var(--safe-left));bottom:calc(31px + var(--safe-bottom))}
 .manual-pedals{right:calc(25px + var(--safe-right));bottom:calc(23px + var(--safe-bottom));gap:9px}.pedal{width:65px;height:78px;font-size:10px}.throttle-pedal{height:94px}
 .manual-actions{right:calc(179px + var(--safe-right));bottom:calc(25px + var(--safe-bottom));flex-direction:column;gap:9px}.round-action{width:48px;height:48px;font-size:9px}
 .result-standings{display:grid;grid-template-columns:1fr 1fr;gap:0 15px;font-size:11px}.result-standings li{padding:6px 3px;gap:7px}
}
@media(max-height:390px) and (orientation:landscape){
 .home-screen,.garage-screen{padding-top:calc(65px + var(--safe-top));padding-bottom:15px}
 .home-screen .hero-copy{width:42vw;max-width:365px}.home-screen .eyebrow{display:none}.home-screen h1{font-size:33px;margin-bottom:8px}.home-screen .hero-description{font-size:11px;margin-bottom:10px}
 .map-option{min-height:73px}.map-option svg{height:22px}.hero-actions .secondary-row>.button{height:39px;min-height:39px}.hero-actions>.primary{height:44px}
 .garage-copy .back-link{min-height:20px;margin-bottom:4px}.garage-copy h1{font-size:27px;margin-bottom:9px}.vehicle-options{margin-bottom:9px}.vehicle-option{min-height:59px}.paint-swatch{height:39px}.paint-selector{margin-bottom:9px}
}

/* Circuit Club: six machines, real route maps and personal controls. */
.visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.screen select{pointer-events:auto}.race-format{display:flex;gap:10px;max-width:390px;margin:0 0 12px;pointer-events:auto}.race-format label{display:flex;align-items:center;justify-content:space-between;gap:10px;flex:1;font-size:8px;letter-spacing:1.5px;font-weight:700;border-bottom:1px solid var(--line);padding:0 0 7px}.race-format select{border:0;background:transparent;color:var(--ink);font-size:12px;font-weight:700;min-height:30px;min-width:87px;cursor:pointer}.map-option svg .map-route{stroke-width:1.8}.map-option svg .map-start{fill:var(--coral);stroke:var(--paper);stroke-width:.7}
.garage-screen{padding-top:calc(105px + var(--safe-top));padding-bottom:calc(23px + var(--safe-bottom));overflow:hidden}.garage-copy{top:0;transform:none;width:min(420px,38vw);max-height:100%;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#a9b3a2 transparent;padding:0 7px 0 0;pointer-events:auto}.garage-copy .back-link{margin-bottom:9px;min-height:28px}.garage-copy .eyebrow{margin-bottom:12px}.garage-copy h1{font-size:43px;margin-bottom:15px}.garage-copy h1 br{display:none}.garage-copy h1 em{font-size:.78em;margin-left:4px;letter-spacing:-1.5px}.vehicle-options{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin-bottom:15px}.vehicle-option{min-height:71px;padding:8px 5px 7px}.vehicle-option svg{height:23px;width:62px;margin-bottom:3px}.vehicle-option strong{font-size:11px}.vehicle-option>span{font-size:9px}.driver-selector{margin-bottom:13px}.driver-options{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin-top:7px}.driver-option{height:47px;border:1px solid var(--line);border-radius:5px;display:flex;gap:7px;align-items:center;justify-content:center;background:rgba(247,244,233,.72);padding:5px}.driver-option strong{font-size:10px}.driver-option.selected{border-color:var(--ink);box-shadow:inset 0 0 0 1px var(--ink);background:#fffdf5}.driver-avatar{display:block;width:24px;height:31px;position:relative;overflow:hidden;flex:none;border-radius:6px}.driver-avatar:before{content:'';position:absolute;bottom:-7px;left:0;right:0;height:22px;border-radius:9px 9px 0 0;background:var(--suit);border:1px solid rgba(0,0,0,.15)}.driver-avatar i{position:absolute;width:20px;height:21px;top:0;left:2px;background:linear-gradient(90deg,transparent 43%,var(--accent) 43%,var(--accent) 57%,transparent 57%),var(--helmet);border-radius:9px 9px 7px 7px;box-shadow:inset 0 -3px 0 rgba(0,0,0,.11)}.driver-avatar i:after{content:'';position:absolute;left:2px;right:2px;top:9px;height:5px;border-radius:2px 2px 4px 4px;background:#253a39}.driver-description{font-size:10px;line-height:1.35;color:var(--muted);margin:6px 0 0;min-height:14px}.garage-copy .paint-selector{margin-bottom:11px}.garage-copy .swatch-row{margin-top:7px;gap:6px}.garage-copy .paint-swatch{height:42px;padding:6px 8px}.garage-copy .paint-chip{width:17px;height:24px}.garage-copy .paint-name{font-size:10px}.garage-copy .variant-caption{margin-top:7px;min-height:17px}.garage-copy .variant-caption strong{font-size:15px}.garage-copy .variant-caption>span{display:none}.garage-details{margin-bottom:12px;font-size:10px;line-height:1.45}.garage-details p{margin:0 0 4px}.garage-copy>.primary{position:sticky;bottom:0;width:100%;max-width:none;height:46px;z-index:4;margin-top:8px;box-shadow:0 -7px 18px rgba(247,244,233,.95),0 3px 12px rgba(23,60,52,.12)}
.lap-counter{font-size:10px;letter-spacing:1px;white-space:nowrap}.lap-counter strong{font-size:27px;letter-spacing:-1px;margin-left:3px}.lap-counter small{font-size:15px;font-weight:400;opacity:.65;letter-spacing:0}.route-progress{gap:8px}.route-progress #progress-text{font-size:11px;letter-spacing:0;opacity:.6;margin-left:auto}.route-progress .route-word{display:none}.lap-timing{position:absolute;left:calc(28px + var(--safe-left));top:calc(114px + var(--safe-top));display:flex;gap:16px;color:#f7f4e9;background:rgba(17,47,41,.68);border:1px solid rgba(255,255,255,.12);padding:7px 11px;border-radius:5px;font-size:8px;letter-spacing:1px;backdrop-filter:blur(9px)}.lap-timing strong{font-size:12px;letter-spacing:.2px;margin-left:6px;font-variant-numeric:tabular-nums}.race-standings{top:calc(153px + var(--safe-top))}.minimap-panel{position:absolute;right:calc(28px + var(--safe-right));top:calc(88px + var(--safe-top));width:192px;color:var(--paper);background:rgba(17,47,41,.78);border:1px solid rgba(255,255,255,.19);border-radius:7px;backdrop-filter:blur(10px);overflow:hidden;pointer-events:auto}.minimap-toggle{display:flex;align-items:center;justify-content:space-between;gap:9px;width:100%;height:32px;padding:0 11px;background:transparent;color:inherit;font-size:8px;letter-spacing:1.4px;font-weight:700}.minimap-toggle svg{width:14px;height:14px}.minimap-content>svg{width:100%;height:auto;display:block;stroke-linecap:round;stroke-linejoin:round}.minimap-content>p{display:flex;align-items:center;justify-content:center;gap:4px;font-size:8px;letter-spacing:.15px;line-height:1;margin:0 0 11px;opacity:.8}.minimap-content>p span:not(:first-child){margin-left:4px}.minimap-road-edge{fill:none;stroke:rgba(6,24,19,.65);stroke-width:10}.minimap-road{fill:none;stroke:#cbd3b8;stroke-width:5}.minimap-start-ring{fill:#f7f4e9;stroke:#173c34;stroke-width:1}.minimap-player{fill:#f4cd77;stroke:#173c34;stroke-width:1.1}.minimap-rival{fill:#f7f4e9;stroke:#173c34;stroke-width:1.1}.minimap-animal{fill:#df8a57;stroke:#193f34;stroke-width:.7}.map-legend-player{color:#f4cd77}.map-legend-rival{color:#f7f4e9}.map-legend-animal{color:#df8a57}.minimap-panel.collapsed .minimap-content{display:none}.minimap-panel.collapsed .minimap-toggle svg{transform:rotate(180deg)}
.keyboard-settings{margin:18px 0 5px;padding-top:18px;border-top:1px solid var(--line)}.binding-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.binding-heading h3{font-size:15px;margin:0}.binding-heading select,.touch-layout-row select{min-height:38px;border:1px solid var(--line);border-radius:5px;background:#fffdf7;color:var(--ink);padding:0 8px;font-size:12px;max-width:170px}.keyboard-explainer{font-size:12px;line-height:1.5;color:var(--muted);margin:10px 0 13px}.key-bindings{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.key-binding{min-height:50px;padding:9px 10px;display:flex;align-items:center;justify-content:space-between;gap:6px;border:1px solid var(--line);background:#fffdf7;border-radius:5px;font-size:11px;text-align:left}.key-binding kbd{font:700 12px Arial,sans-serif;border:1px solid #ced4c8;min-width:26px;min-height:25px;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;padding:3px 5px;background:#f1f0e5;border-radius:4px;box-shadow:0 2px 0 #d9ddcf}.key-binding.capturing{border-color:var(--coral);background:#fbe9d9;box-shadow:0 0 0 1px var(--coral)}.binding-status{font-size:11px;line-height:1.5;color:var(--muted);min-height:33px;margin:10px 0 0}.touch-layout-row{gap:16px}.touch-layout-row .setting-detail{max-width:285px}.settings-dialog{width:min(610px,calc(100vw - 32px));max-height:calc(100dvh - 40px);overscroll-behavior:contain}.settings-dialog .dialog-heading{position:sticky;top:-30px;z-index:2;background:var(--paper);padding-bottom:10px}.settings-dialog .control-option p{font-size:12px}.settings-dialog .option-heading{font-size:13px}
.button-steering{display:none;position:absolute;left:calc(36px + var(--safe-left));bottom:calc(42px + var(--safe-bottom));gap:11px}.steer-button{width:82px;height:82px;border-radius:22px;background:rgba(18,46,41,.68);border:1px solid rgba(247,244,233,.48);color:var(--paper);font-size:36px;touch-action:none;backdrop-filter:blur(8px)}.steer-button:active,.steer-button.active{background:rgba(247,244,233,.32);transform:translateY(2px)}.horn-action{position:absolute;right:calc(183px + var(--safe-right));bottom:calc(177px + var(--safe-bottom));width:48px;height:48px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;background:rgba(18,46,41,.7);font-size:8px;touch-action:none}.horn-action svg{width:19px;height:19px}.pedal .pedal-label{font-size:11px;line-height:1;font-weight:700}.pedal .pedal-symbol{font-size:30px;line-height:1}.pedal-label:before{display:none}
body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .simple-steering,body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .touch-wheel{display:none!important}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .button-steering{display:flex}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .drive-action{display:none!important}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .manual-pedals,body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .manual-actions{display:flex!important}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal{border-radius:50%;width:91px;height:91px;gap:6px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{width:104px;height:104px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-symbol{font-size:0}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-symbol:after{font-size:31px;font-weight:700;content:'B'}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal .pedal-symbol:after{content:'A'}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-label{font-size:10px}
body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .simple-steering,body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .touch-wheel{left:auto;right:calc(36px + var(--safe-right))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-pedals{right:auto;left:calc(36px + var(--safe-left));flex-direction:row-reverse}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-actions{right:auto;left:calc(40px + var(--safe-left));flex-direction:row-reverse}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .drive-action{right:auto;left:calc(40px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .horn-action{right:auto;left:calc(183px + var(--safe-left))}
@media(min-width:701px) and (min-height:601px){.hero-copy{top:50%;transform:translateY(-51%)}.hero-copy h1{margin-bottom:17px}.hero-copy .hero-description{margin-bottom:18px}.map-picker{margin-bottom:12px}.garage-copy{max-height:calc(100dvh - 130px)}}
@media(max-width:700px) and (orientation:portrait){
 .race-format{margin-bottom:9px;gap:14px}.race-format label{font-size:8px;padding-bottom:4px}.race-format select{font-size:11px;min-height:26px;min-width:82px}.map-picker{margin-bottom:8px}.hero-copy h1{margin-bottom:12px}.hero-copy .hero-description{margin-bottom:13px}.hero-copy .first-drive-note{margin-top:9px}.hero-copy .garage-entry{margin-top:4px}.hero-copy .map-option{min-height:85px}
 .garage-screen{padding:calc(77px + var(--safe-top)) calc(20px + var(--safe-right)) calc(23px + var(--safe-bottom)) calc(23px + var(--safe-left))}.garage-copy{width:100%;max-width:420px;max-height:54dvh;padding-right:3px}.garage-copy .back-link{font-size:10px;margin-bottom:3px;min-height:22px}.garage-copy .eyebrow{display:none}.garage-copy h1{font-size:29px;letter-spacing:-1.3px;margin-bottom:10px}.garage-copy h1 em{font-size:.83em;letter-spacing:-1px}.vehicle-options{gap:5px;margin-bottom:10px}.vehicle-option{min-height:55px;padding:5px 4px}.vehicle-option svg{height:17px;width:49px;margin-bottom:2px}.vehicle-option strong{font-size:10px}.vehicle-option>span{font-size:8px}.driver-selector{margin-bottom:10px}.driver-options{gap:5px;margin-top:5px}.driver-option{height:37px;gap:5px;padding:3px}.driver-option strong{font-size:9px}.driver-avatar{height:27px;width:21px}.driver-avatar i{width:18px;height:19px;left:1px}.driver-description{display:none}.garage-copy .paint-swatch{height:34px;padding:4px 6px;gap:5px}.garage-copy .paint-chip{width:14px;height:22px}.garage-copy .paint-name{font-size:9px}.garage-copy .swatch-row{gap:5px;margin-top:5px}.garage-copy .variant-caption{min-height:12px;margin-top:5px}.garage-copy .variant-caption strong{font-size:11px;font-family:Arial,sans-serif;font-weight:700}.garage-copy .paint-selector{margin-bottom:7px}.garage-details{margin-bottom:6px}.garage-details #vehicle-description{display:none}#vehicle-stats{font-size:9px}.garage-copy>.primary{height:40px;margin-top:4px;width:100%;max-width:none;font-size:12px}.orbit-hint{left:50%;font-size:9px}
 .route-card{width:129px}.lap-counter{font-size:8px;letter-spacing:.5px}.lap-counter strong{font-size:23px}.lap-counter small{font-size:12px}.route-progress{gap:4px}.route-progress #progress-text{font-size:9px}.lap-timing{left:calc(14px + var(--safe-left));top:calc(103px + var(--safe-top));gap:12px;padding:6px 8px;font-size:7px}.lap-timing strong{font-size:10px}.race-standings{top:calc(138px + var(--safe-top));width:137px}.minimap-panel{right:calc(14px + var(--safe-right));top:calc(138px + var(--safe-top));width:135px}.minimap-toggle{height:27px;padding:0 8px;font-size:7px;letter-spacing:.8px}.minimap-content>p{font-size:6px;gap:2px;margin-bottom:8px}.minimap-content>p span:not(:first-child){margin-left:2px}.minimap-content>svg{margin-top:-4px}.horn-action{right:calc(19px + var(--safe-right));bottom:calc(220px + var(--safe-bottom));width:40px;height:40px}.button-steering{left:calc(17px + var(--safe-left));bottom:calc(43px + var(--safe-bottom));gap:9px}.steer-button{width:65px;height:70px;border-radius:18px;font-size:30px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .manual-pedals{gap:8px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal{width:64px;height:70px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{width:73px;height:82px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-symbol:after{font-size:25px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-label{font-size:8px}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .simple-steering,body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .touch-wheel{right:calc(17px + var(--safe-right))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-pedals{left:calc(16px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-actions{left:calc(19px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .horn-action{left:calc(19px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .drive-action{left:calc(20px + var(--safe-left))}
 .settings-dialog{padding:22px;width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}.settings-dialog .dialog-heading{top:-22px}.key-bindings{grid-template-columns:repeat(2,minmax(0,1fr))}.key-binding{min-height:47px;font-size:10px;padding:7px 8px}.touch-layout-row{gap:8px}.touch-layout-row select{max-width:130px;font-size:11px}.touch-layout-row .setting-detail{font-size:10px}.binding-heading select{max-width:145px;font-size:11px}
}
@media(max-height:600px) and (orientation:landscape){
 .home-screen{overflow-y:auto}.hero-copy{padding-bottom:15px}.race-format{margin:0 0 7px}.race-format label{font-size:7px;padding-bottom:3px}.race-format select{font-size:10px;min-height:24px}.garage-screen{padding-top:calc(66px + var(--safe-top));padding-bottom:calc(12px + var(--safe-bottom));overflow:hidden}.garage-copy{width:39vw;max-height:calc(100dvh - 78px);padding-right:7px}.garage-copy .back-link{min-height:22px;margin-bottom:4px}.garage-copy h1{font-size:25px;margin-bottom:10px}.vehicle-options{gap:5px;margin-bottom:10px}.vehicle-option{min-height:57px;padding:5px}.vehicle-option svg{height:19px;margin-bottom:2px}.vehicle-option strong{font-size:10px}.vehicle-option>span{font-size:8px}.driver-selector{margin-bottom:10px}.driver-options{gap:5px;margin-top:5px}.driver-option{height:37px;padding:3px;gap:4px}.driver-option strong{font-size:9px}.driver-avatar{width:20px;height:27px}.driver-avatar i{width:18px;height:19px;left:1px}.driver-description{display:none}.garage-copy .paint-swatch{height:33px;padding:4px 5px;gap:4px}.garage-copy .paint-name{font-size:9px}.garage-copy .paint-chip{width:13px;height:21px}.garage-copy .variant-caption{min-height:12px}.garage-copy .variant-caption strong{font-size:10px;font-family:Arial,sans-serif;font-weight:700}.garage-copy>.primary{height:39px;margin-top:4px;font-size:12px}.garage-details{font-size:9px;margin-bottom:4px}.garage-details #vehicle-description{display:none}.orbit-hint{bottom:14px}
 .lap-timing{left:calc(20px + var(--safe-left));top:calc(91px + var(--safe-top));padding:5px 8px;font-size:7px;gap:12px}.lap-timing strong{font-size:10px}.race-standings{top:calc(124px + var(--safe-top));width:139px;font-size:9px}.minimap-panel{width:140px;top:calc(77px + var(--safe-top));right:calc(20px + var(--safe-right))}.minimap-toggle{height:25px;font-size:7px;padding:0 8px}.minimap-content>svg{max-height:92px}.minimap-content>p{font-size:6px;margin-bottom:7px}.horn-action{right:calc(239px + var(--safe-right));bottom:calc(28px + var(--safe-bottom));width:42px;height:42px}.button-steering{left:calc(26px + var(--safe-left));bottom:calc(31px + var(--safe-bottom));gap:10px}.steer-button{width:71px;height:68px;border-radius:19px;font-size:30px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal{width:67px;height:70px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{width:76px;height:82px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-label{font-size:9px}body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-symbol:after{font-size:27px}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .simple-steering,body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .touch-wheel{right:calc(26px + var(--safe-right))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-pedals{left:calc(25px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-actions{left:calc(179px + var(--safe-left));flex-direction:column}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .horn-action{left:calc(239px + var(--safe-left))}body:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .drive-action{left:calc(25px + var(--safe-left))}
}
@media(max-width:360px) and (orientation:portrait){.garage-screen{padding-left:16px;padding-right:16px}.garage-copy h1{font-size:25px}.driver-option strong{font-size:8px}.driver-option{gap:3px}.race-top{gap:6px}.route-card{width:119px}.position-card{width:57px}.time-card{min-width:64px}.minimap-panel{width:121px}.minimap-content>p{font-size:5.5px}.key-binding{gap:4px;padding:6px;font-size:9px}.key-binding kbd{font-size:10px}.binding-heading select{max-width:130px}}
@media(max-width:700px) and (orientation:portrait){}
@media(max-height:600px) and (orientation:landscape){}

/* Circuit character and meaningful vehicle choices. */
.circuit-character{font-size:10px;line-height:1.5;color:var(--muted);margin:0 0 13px;max-width:410px}
.map-option .map-difficulty{font-size:7px;font-weight:700;letter-spacing:.5px;display:inline-block;padding:3px 6px;margin-top:5px;border-radius:3px;background:#dce8d6;color:#315243}
.map-option .map-difficulty[data-level="medium"]{background:#eee0b9;color:#6b5324}.map-option .map-difficulty[data-level="hard"]{background:#f0d5c9;color:#854832}
.vehicle-profile{margin:0 0 14px;padding:12px 13px;border:1px solid rgba(35,67,51,.16);border-radius:7px;background:rgba(255,253,246,.65)}
.vehicle-ability-title{display:flex;align-items:center;justify-content:space-between;gap:10px}.vehicle-ability-title .field-label{font-size:7px;letter-spacing:1.1px}.vehicle-ability-title strong{font-size:13px;color:var(--ink)}
#garage-ability-description{font-size:10px;line-height:1.45;color:var(--muted);margin:7px 0 10px}
.vehicle-ratings{display:grid;grid-template-columns:1fr 1fr;gap:7px 15px;margin-bottom:10px}.vehicle-ratings>div{display:flex;align-items:center;justify-content:space-between;gap:7px;font-size:9px;color:var(--muted)}
.rating-track{display:flex;gap:2px;flex:none}.rating-track i{width:7px;height:7px;background:#d8ddcf;border-radius:1px}.rating-track .filled{background:#4d7560}
.vehicle-tradeoffs{margin:0;display:grid;gap:5px;font-size:9px;line-height:1.4;color:var(--muted)}.vehicle-tradeoffs>div{display:grid;grid-template-columns:58px 1fr;gap:6px}.vehicle-tradeoffs dt{font-weight:700;color:var(--ink)}.vehicle-tradeoffs dd{margin:0}
.ability-button{position:absolute;left:50%;bottom:calc(97px + var(--safe-bottom));transform:translateX(-50%);pointer-events:auto;touch-action:none;user-select:none;display:flex;gap:10px;align-items:center;width:172px;min-height:49px;padding:9px 12px 11px;border:1px solid rgba(242,215,153,.7);border-radius:8px;background:rgba(22,53,44,.93);color:#f8f0d7;overflow:hidden;box-shadow:0 4px 15px rgba(13,31,24,.18);z-index:16;text-align:left}
.ability-button kbd{font-size:14px;border:1px solid rgba(255,255,255,.35);border-radius:4px;min-width:27px;line-height:25px;text-align:center;flex:none;font-family:inherit}.ability-button span{display:grid;gap:4px}.ability-button strong{font-size:12px;white-space:nowrap}.ability-button small{font-size:7px;letter-spacing:1px;color:#eac27b}.ability-button>i{position:absolute;bottom:0;left:0;height:3px;width:100%;background:#edbd67;transition:width .12s linear}.ability-button.held,.ability-button.ability-active{background:#7d5d27;border-color:#ffdb85}.ability-button.ability-active>i{background:#ffdb85}.ability-button.ability-cooling{border-color:#819184;background:rgba(31,51,45,.9)}.ability-button.ability-cooling small{color:#c4d0bf}.touch .ability-button kbd{display:none}.touch .ability-button{justify-content:center;text-align:center}
@media(max-width:700px) and (orientation:portrait){
 .circuit-character{font-size:9px;margin-bottom:8px;max-width:340px}.map-option .map-difficulty{font-size:6px;padding:2px 5px;margin-top:3px}.hero-copy .map-option{min-height:95px}
 .vehicle-profile{padding:9px 10px;margin-bottom:10px}.vehicle-ability-title strong{font-size:11px}#garage-ability-description{font-size:9px;margin:6px 0 8px}.vehicle-ratings{gap:5px 12px;margin-bottom:8px}.vehicle-ratings>div,.vehicle-tradeoffs{font-size:8px}.vehicle-tradeoffs>div{grid-template-columns:51px 1fr}.rating-track i{width:6px;height:6px}
 .ability-button{bottom:calc(102px + var(--safe-bottom));width:144px;min-height:45px;padding:8px 10px 10px}.ability-button strong{font-size:11px}.ability-button small{font-size:6px}
 .touch .ability-button{bottom:calc(143px + var(--safe-bottom));width:118px;min-height:45px}.touch .speed-card{bottom:calc(232px + var(--safe-bottom));left:25%;}.touch .drift-meter{bottom:calc(279px + var(--safe-bottom));left:25%;width:122px}.touch .speed-card .surface-badge{top:calc(100% + 4px)}
}
@media(max-height:600px) and (orientation:landscape){
 .circuit-character{font-size:8px;margin-bottom:8px}.map-option .map-difficulty{font-size:6px;margin-top:2px;padding:2px 4px}.vehicle-profile{padding:9px 10px;margin-bottom:10px}.vehicle-ability-title strong{font-size:11px}#garage-ability-description{font-size:9px}.vehicle-ratings{gap:5px 10px}.vehicle-ratings>div,.vehicle-tradeoffs{font-size:8px}.vehicle-tradeoffs>div{grid-template-columns:49px 1fr}.rating-track i{width:6px;height:6px}
 .ability-button{bottom:calc(88px + var(--safe-bottom));width:139px;min-height:43px;padding:7px 9px 10px}.ability-button strong{font-size:11px}.ability-button small{font-size:6px}
}

.workshop-entry{display:flex;align-items:center;justify-content:space-between;gap:18px;font-size:11px;color:var(--ink);background:#f3f1e4e8;text-decoration:none;padding:9px 12px;margin-top:8px;max-width:390px;border:1px solid #cbd2c0;border-radius:4px}.workshop-entry:hover{background:#fffef4;border-color:var(--ink)}.workshop-entry span{font-size:16px}
@media(max-width:700px){.workshop-entry{font-size:10px;padding:7px 10px;margin-top:4px}}

/* Six-region expedition selector. The menu remains scrollable on short screens. */
.map-option.new-region{background:#edf0e7e8}.map-option.new-region[aria-pressed="true"]{background:#fffdf3}
.map-option strong{white-space:normal}.map-options{row-gap:8px}.hero-copy .map-option{min-height:92px}
.rival-description{max-width:390px;margin:-4px 0 12px;color:#446256;font-size:10px;line-height:1.45}
.roadmap-entry{display:block;max-width:390px;font-size:10px;padding:9px 12px;color:var(--ink);text-decoration:none;pointer-events:auto}.roadmap-entry span{float:right}.roadmap-entry:hover{text-decoration:underline}
.home-screen{overflow-y:auto;pointer-events:auto;padding-top:calc(110px + var(--safe-top));padding-bottom:calc(26px + var(--safe-bottom))}
.home-screen .hero-copy{top:0;transform:none}
.home-screen .expedition-footer{position:relative;left:auto;bottom:auto;margin-top:24px;flex-wrap:wrap}
body[data-map="nyanga"] #game-canvas{background:linear-gradient(#8aaac4,#bac8c6 58%,#879881)}
body[data-map="victoria-falls"] #game-canvas{background:linear-gradient(#7db5dc,#ccd8d3 65%,#8da78e)}
body[data-map="zambezi"] #game-canvas{background:linear-gradient(#83b9d4,#dce0c7 70%,#a9b994)}
@media(max-width:700px){.hero-copy .map-option{min-height:88px}.map-option svg{height:24px;margin:2px 0 6px}.map-option strong{font-size:10px}.map-option .map-difficulty{font-size:6px}.rival-description{font-size:9px;margin-bottom:9px}.hero-copy .hero-description{margin-bottom:10px}.home-screen .expedition-footer{position:relative;margin-top:28px}.home-screen{padding-bottom:28px}}
@media(max-height:600px) and (orientation:landscape){.home-screen{padding-top:calc(73px + var(--safe-top))}.hero-copy .map-option{min-height:76px}.map-option svg{height:20px}.rival-description{font-size:9px}.roadmap-entry{padding-top:7px;padding-bottom:7px}}
@media(max-width:700px) and (orientation:portrait){.home-screen{padding-top:calc(86px + var(--safe-top))}body[data-screen="home"] .scene-shade{background:linear-gradient(180deg,rgba(247,244,233,.98),rgba(247,244,233,.91) 55%,rgba(247,244,233,.86))}.home-screen .expedition-footer{color:#536257;text-shadow:none}}

/* Readable selection panels keep the main action in view while choices scroll. */
.home-screen{overflow:hidden;padding-top:calc(106px + var(--safe-top));padding-bottom:calc(20px + var(--safe-bottom))}
.home-screen .hero-copy,.garage-screen .garage-copy{display:flex;flex-direction:column;width:min(460px,44vw);max-width:none;height:100%;max-height:100%;padding:0;top:0;transform:none;overflow:visible}
.home-scroll,.garage-scroll{min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#a7b4a0 transparent;padding:4px 12px 12px 4px;margin-left:-4px;scroll-padding-block:8px}
.home-scroll{flex:1}
.home-screen h1{font-size:clamp(44px,4.3vw,62px);line-height:1.02;margin-bottom:14px}
.home-screen .eyebrow{font-size:11px;letter-spacing:1.7px;margin-bottom:14px}
.home-screen .hero-description{font-size:14px;line-height:1.5;max-width:none;margin-bottom:18px}
.home-screen .collection-heading .field-label,.garage-screen .field-label{font-size:10px;letter-spacing:1.2px}
.route-count,.collection-count{font-size:10px;letter-spacing:.5px}
.map-options{gap:9px;grid-template-columns:repeat(3,minmax(0,1fr))}
.hero-copy .map-option{min-height:116px;padding:10px 9px}
.map-option svg{height:29px;margin:2px 0 8px}
.map-option strong{font-size:13px;line-height:1.3;overflow-wrap:anywhere}
.map-option>span{font-size:11px;line-height:1.4;margin-top:4px}
.map-option>i{font-size:9px}
.map-option .map-difficulty{font-size:10px;line-height:1.25;padding:3px 6px;letter-spacing:.25px;margin-top:7px}
.circuit-character,.rival-description{font-size:12px;line-height:1.5;max-width:none;margin:9px 0 13px}
.race-format{gap:14px;margin-bottom:8px}
.race-format label{font-size:10px;letter-spacing:1.1px}
.race-format select{min-height:44px;font-size:14px;margin-top:4px}
.hero-actions{max-width:none}
.hero-actions .secondary-row{margin-top:0;gap:10px}
.hero-actions .secondary-row>.button{height:44px;min-height:44px;font-size:13px;padding:0 13px}
.hero-actions .garage-entry{font-size:13px;min-height:44px;margin-top:5px}
.home-variant-name{font-size:11px}
.discovery-links{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:6px}
.discovery-links a{display:flex;align-items:center;justify-content:space-between;gap:6px;min-height:44px;max-width:none;margin:0;padding:8px 10px;border:1px solid var(--line);border-radius:4px;font-size:12px;line-height:1.4;text-decoration:none;background:rgba(247,244,233,.88)}
.discovery-links a:hover{background:var(--paper);border-color:#7a9282}
.discovery-links span{font-size:16px;float:none}
.first-drive-note{font-size:11px;line-height:1.5;margin:15px 0 0}
.home-screen .expedition-footer{position:relative;left:auto;bottom:auto;margin:14px 0 0;font-size:10px;line-height:1.5;gap:9px;color:var(--muted);text-shadow:none}
.home-screen .destination-caption{max-width:min(270px,36vw);padding:17px 20px;border:1px solid rgba(247,244,233,.65);border-radius:7px;background:rgba(247,244,233,.92);color:var(--ink);box-shadow:0 4px 20px rgba(23,60,52,.1);pointer-events:none}
.home-screen .destination-caption>span:first-child{font-size:10px;letter-spacing:2px;margin-bottom:10px}
.home-screen .destination-caption strong{font-size:28px;line-height:1.14}
.home-screen .destination-caption small{font-size:10px;line-height:1.5;letter-spacing:.7px;max-width:220px}
.home-start,.garage-start{flex:none;padding:12px 12px 0 0;background:linear-gradient(180deg,rgba(247,244,233,.7),var(--paper) 22%)}
.home-start>.button,.garage-start>.button{width:100%;max-width:none;height:52px;min-height:48px;font-size:14px;padding:0 18px}
.home-start .race-button-note{font-size:10px;letter-spacing:.5px;margin-left:auto}
.garage-screen{padding-top:calc(106px + var(--safe-top));padding-bottom:calc(24px + var(--safe-bottom));overflow:hidden}
.garage-screen .garage-copy{pointer-events:auto}
.garage-scroll{flex:1}
.garage-scroll .back-link{min-height:44px;margin-bottom:8px;font-size:13px;padding:8px 0}
.garage-copy h1{font-size:40px;line-height:1.06;margin-bottom:18px;letter-spacing:-1.3px}
.garage-copy h1 em{font-size:.84em}
.vehicle-options{gap:8px;margin-bottom:15px}
.vehicle-option{min-height:83px;padding:8px 6px}
.vehicle-option svg{height:24px;margin-bottom:5px}
.vehicle-option strong{font-size:12px;line-height:1.3}
.vehicle-option>span{font-size:11px;line-height:1.4}
.vehicle-profile{padding:13px;margin-bottom:16px}
.vehicle-ability-title{flex-wrap:wrap;gap:5px}
.vehicle-ability-title .field-label{font-size:10px}
.vehicle-ability-title strong{font-size:14px}
#garage-ability-description{font-size:12px;line-height:1.5;margin:8px 0 12px}
.vehicle-ratings{gap:10px 15px;margin-bottom:13px}
.vehicle-ratings>div,.vehicle-tradeoffs{font-size:11px;line-height:1.5}
.vehicle-tradeoffs>div{grid-template-columns:67px 1fr;gap:8px}
.driver-selector{margin-bottom:16px}
.driver-options{gap:7px;margin-top:8px}
.driver-option{height:48px;padding:5px;gap:6px}
.driver-option strong{font-size:11px}
.driver-description{display:block;font-size:11px;line-height:1.5;margin-top:8px}
.garage-copy .swatch-row{gap:7px;margin-top:8px}
.garage-copy .paint-swatch{height:auto;min-height:46px;padding:6px;gap:6px}
.garage-copy .paint-name{font-size:11px;line-height:1.3;white-space:normal}
.garage-copy .paint-chip{width:15px;height:27px;flex:none}
.garage-copy .variant-caption{min-height:0;line-height:1.5;margin-top:9px}
.garage-copy .variant-caption strong{font-size:13px}
.garage-copy .variant-caption span,#vehicle-stats{font-size:11px;line-height:1.5}
.garage-details{font-size:12px;line-height:1.5}
.garage-details #vehicle-description{display:block;font-size:12px;line-height:1.5}
.orbit-hint{font-size:11px}
.control-option p,.keyboard-explainer,.setting-detail,.binding-status{font-size:12px;line-height:1.5}
.key-binding{min-height:44px;font-size:12px}
.setting-row select{min-height:44px;font-size:14px}
.pause-button{min-width:44px;min-height:44px}
.ability-button small{font-size:10px;letter-spacing:.5px}
.result-actions>.text-button{min-height:44px;font-size:12px}
.save-status{position:fixed;z-index:50;left:50%;bottom:calc(18px + var(--safe-bottom));transform:translateX(-50%);width:max-content;max-width:min(620px,calc(100vw - 32px));display:flex;align-items:center;gap:16px;padding:12px 14px;border:1px solid #b68c59;border-radius:7px;background:#fff3d7;color:#59411f;box-shadow:0 4px 20px #173c3426;font-size:13px;line-height:1.5}
.save-status[hidden]{display:none}
.save-status button{flex:none;min-height:44px;padding:0 13px;border:1px solid #b68c59;border-radius:4px;background:#fffaf0;font-weight:700}
dialog .save-status{position:static;transform:none;width:100%;max-width:none;margin-top:18px;box-shadow:none;flex-wrap:wrap}
.hero-copy>.save-status,.garage-copy>.save-status{position:static;flex:none;transform:none;width:calc(100% - 12px);max-width:none;margin-top:10px;box-shadow:none;flex-wrap:wrap}
@media(max-width:1050px) and (min-width:701px){
 .home-screen .hero-copy,.garage-screen .garage-copy{width:min(440px,48vw)}
 .map-options{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:700px) and (orientation:portrait){
 .topbar{padding:calc(14px + var(--safe-top)) 18px 9px;gap:8px}
 .top-actions{gap:3px}
 .top-actions .icon-button,.top-actions .quiet-button{height:44px;min-width:44px;width:44px}
 .top-actions .quiet-button{padding:0}
 .settings-trigger span{display:none}
 .wordmark{font-size:14px;gap:8px;letter-spacing:1.1px}
 .wordmark-light{letter-spacing:1.2px;margin-left:3px}
 .home-screen{padding:calc(78px + var(--safe-top)) 18px calc(12px + var(--safe-bottom));overflow:hidden}
 .home-screen .hero-copy,.garage-screen .garage-copy{width:100%;max-width:none;height:100%;padding:0}
 .home-screen h1{font-size:45px;line-height:1.02;margin-bottom:12px}
 .home-screen .eyebrow{font-size:10px;margin-bottom:12px}
 .home-screen .hero-description{font-size:13px;line-height:1.5;margin-bottom:16px}
 .home-scroll,.garage-scroll{padding-right:7px}
 .map-options,.vehicle-options,.garage-copy .swatch-row{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .hero-copy .map-option{min-height:114px;padding:10px}
 .map-option strong{font-size:13px}
 .map-option>span{font-size:11px}
 .map-option .map-difficulty{font-size:10px}
 .route-count{font-size:9px}
 .race-format select,.setting-row select{font-size:16px}
 .home-start,.garage-start{padding-top:10px;padding-right:7px}
 .hero-copy>.save-status,.garage-copy>.save-status{width:calc(100% - 7px);margin-top:8px}
 .home-start>.button,.garage-start>.button{height:48px}
 .hero-actions .secondary-row>.button{font-size:13px;height:44px;min-height:44px}
 .hero-actions .garage-entry{font-size:13px;min-height:44px}
 .home-screen .expedition-footer{font-size:10px;margin-top:14px}
 .garage-screen{padding:calc(78px + var(--safe-top)) 18px calc(20px + var(--safe-bottom));overflow:hidden}
 .garage-screen .garage-copy{height:50dvh;max-height:calc(100dvh - 200px - var(--safe-top) - var(--safe-bottom));background:linear-gradient(180deg,rgba(247,244,233,.7),rgba(247,244,233,.94))}
 .garage-scroll .back-link{min-height:44px;font-size:13px;margin-bottom:7px}
 .garage-copy h1{font-size:31px;line-height:1.05;margin-bottom:14px}
 .garage-copy h1 br{display:none}
 .vehicle-option{min-height:82px;padding:8px}
 .vehicle-option strong{font-size:12px}
 .vehicle-option>span{font-size:11px}
 .vehicle-ratings{grid-template-columns:1fr;gap:7px}
 .driver-option{height:46px;gap:4px;padding:4px}
 .driver-option strong{font-size:11px}
 .garage-copy .paint-swatch{min-height:46px}
 .garage-copy .paint-name{font-size:11px}
 .orbit-hint{font-size:11px;bottom:calc(16px + var(--safe-bottom))}
 .save-status{gap:10px;flex-wrap:wrap;bottom:calc(10px + var(--safe-bottom));font-size:12px}
}
@media(max-height:600px) and (orientation:landscape){
 .home-screen,.garage-screen{padding-top:calc(70px + var(--safe-top));padding-bottom:calc(12px + var(--safe-bottom));overflow:hidden}
 .home-screen .hero-copy,.garage-screen .garage-copy{width:min(450px,48vw);height:100%;max-height:100%;padding-bottom:0}
 .home-screen h1{font-size:36px;line-height:1.05;margin-bottom:10px}
 .home-screen .eyebrow{display:flex;font-size:10px;margin-bottom:10px}
 .home-screen .hero-description{font-size:13px;line-height:1.5;margin-bottom:13px}
 .home-screen .destination-caption{padding:12px 14px;max-width:31vw}
 .home-screen .destination-caption strong{font-size:23px}
 .map-options,.vehicle-options,.garage-copy .swatch-row{grid-template-columns:repeat(2,minmax(0,1fr))}
 .hero-copy .map-option{min-height:110px;padding:9px}
 .map-option strong{font-size:13px}
 .map-option>span{font-size:11px}
 .map-option svg{height:26px;margin-bottom:7px}
 .map-option .map-difficulty{font-size:10px}
 .race-format label{font-size:10px}
 .race-format select{min-height:44px;font-size:14px}
 .circuit-character,.rival-description{font-size:12px}
 .home-start,.garage-start{padding-top:8px}
 .home-start>.button,.garage-start>.button{height:46px;min-height:46px}
 .hero-actions .secondary-row>.button{height:44px;min-height:44px;font-size:13px}
 .hero-actions .garage-entry{min-height:44px;font-size:13px}
 .garage-copy h1{font-size:29px;line-height:1.05;margin-bottom:13px}
 .garage-scroll .back-link{min-height:44px;font-size:13px}
 .driver-option{height:46px}
 .driver-option strong{font-size:11px}
 .garage-copy .paint-swatch{min-height:46px}
 .garage-copy .paint-name{font-size:11px}
 .vehicle-option{min-height:80px;padding:8px}
 .vehicle-option strong{font-size:12px}
 .vehicle-option>span{font-size:11px}
 .vehicle-ratings{grid-template-columns:1fr}
 .ability-button small{font-size:9px}
}

/* 1.8.3 · Mobile cockpit. Every control uses a local Kapital Karts drawing. */
.kk-icon{display:inline-block;width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex:none;vertical-align:middle}
.button>.kk-icon,.text-button>.kk-icon,.discovery-links .kk-icon{width:20px;height:20px}
.paint-selected .kk-icon{width:12px;height:12px;stroke-width:2.2}
.finish-flourish .kk-icon{width:100px;height:100px;stroke-width:.8}
.pedal-symbol .kk-icon{width:32px;height:32px}
body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-symbol:after,body:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal .pedal-symbol:after{content:none}
.manual-actions .round-action{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px}
.manual-actions .kk-icon{width:23px;height:23px}
.steer-button .kk-icon{width:30px;height:30px}
.steer-arrow .kk-icon{width:20px;height:20px}
.ability-icon{display:none}
.map-legend-player,.map-legend-rival,.map-legend-animal{display:inline-block;width:6px;height:6px;background:currentColor;border-radius:50%;flex:none}
.map-legend-player{border-radius:1px;transform:rotate(45deg)}
.race-tools{display:none}
html{overscroll-behavior:none;-webkit-text-size-adjust:100%;text-size-adjust:100%}
body[data-screen="race"]{overscroll-behavior:none;touch-action:none;-webkit-user-select:none;user-select:none}
body[data-screen="race"] .race-hud,body[data-screen="race"] .race-hud button,.touch-controls button,.touch-controls [role="slider"]{touch-action:none;-webkit-touch-callout:none}
/* Pausing restores pinch zoom throughout the visible surface. In particular,
   a player who zoomed a menu must be able to zoom out before resuming a race. */
body[data-screen="race"].race-paused,
body[data-screen="race"].race-paused #game-canvas,
body[data-screen="race"].race-paused .race-hud,
body[data-screen="race"].race-paused .race-hud button,
body[data-screen="race"].race-paused dialog,
body[data-screen="race"].race-paused dialog::backdrop{touch-action:auto}
.screen,.race-hud,.touch-controls,.scene-shade,#game-canvas{width:var(--game-width,100vw);height:var(--game-height,100dvh)}
.home-scroll,.garage-scroll,.settings-dialog,.pause-dialog,.result-panel{overscroll-behavior:contain}
@media(pointer:coarse){select,input{font-size:16px!important}}

body.touch{
 --drive-edge:12px;--drive-bottom:14px;--drive-steering:clamp(144px,42vw,190px);
 --drive-pedal:68px;--drive-throttle:76px;--drive-secondary:114px;
}
.touch .race-hud{padding:calc(8px + var(--safe-top)) calc(12px + var(--safe-right)) calc(8px + var(--safe-bottom)) calc(12px + var(--safe-left))}
.touch .race-top{display:grid;grid-template-columns:56px minmax(78px,132px) 80px minmax(44px,1fr);gap:6px;align-items:start}
.touch .position-card,.touch .route-card,.touch .time-card{height:48px;min-width:0;width:auto;margin:0;padding:6px 8px;border-radius:10px;background:rgba(16,43,36,.88);backdrop-filter:blur(8px)}
.touch .position-card .field-label,.touch .route-card>.field-label,.touch .time-card .field-label{display:block;font-size:8px;line-height:10px;letter-spacing:.45px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.touch .position-card strong{font-size:23px;line-height:24px;margin:0}
.touch .position-card strong small{font-size:11px}
.touch .route-progress{gap:4px;margin:1px 0 3px;height:19px}
.touch .lap-counter{font-size:9px;letter-spacing:.3px;line-height:19px}
.touch .lap-counter strong{font-size:18px;margin-left:2px;letter-spacing:0}
.touch .lap-counter small{font-size:11px}
.touch .route-progress #progress-text{font-size:9px;letter-spacing:0;align-self:center}
.touch .progress-track{height:2px}
.touch .time-card #race-time{font-size:16px;line-height:24px;margin:0;letter-spacing:0}
.touch .pause-button{width:44px;min-width:44px;height:48px;min-height:48px;margin:0 0 0 auto;border-radius:12px}
.touch .lap-timing{display:none}
.touch .race-tools{position:absolute;display:flex;gap:6px;right:calc(62px + var(--safe-right));top:calc(64px + var(--safe-top));pointer-events:none}
.touch .race-tool{pointer-events:auto;display:flex;align-items:center;justify-content:center;width:44px;height:44px;padding:0;border:1px solid rgba(247,244,233,.32);border-radius:12px;background:rgba(16,43,36,.84);color:var(--paper);touch-action:none;backdrop-filter:blur(8px)}
.touch .race-tool[aria-expanded="true"]{background:var(--paper);color:var(--ink)}
.touch .race-tool:active{background:#496456}
.touch .race-tools .race-tool .kk-icon{width:23px;height:23px}
.touch .minimap-panel{top:calc(64px + var(--safe-top));right:calc(12px + var(--safe-right));width:44px;overflow:visible;border:0;background:none;backdrop-filter:none;border-radius:0;z-index:18}
.touch .minimap-toggle{width:44px;height:44px;padding:0;justify-content:center;border-radius:12px;border:1px solid rgba(247,244,233,.32);background:rgba(16,43,36,.84);backdrop-filter:blur(8px)}
.touch .minimap-toggle>span{display:none}
.touch .minimap-toggle .kk-icon{width:23px;height:23px;transform:none}
.touch .minimap-panel:not(.collapsed) .minimap-toggle{background:var(--paper);color:var(--ink)}
.touch .minimap-content{position:absolute;right:0;top:50px;width:164px;padding:7px 0 2px;border:1px solid rgba(247,244,233,.3);border-radius:10px;background:rgba(16,43,36,.94);box-shadow:0 4px 20px #0c231a40}
.touch .minimap-content>svg{height:112px;max-height:none;margin:0}
.touch .minimap-content>p{font-size:8px;gap:4px;margin:1px 0 10px}
.touch .minimap-content>p span:not(:first-child){margin-left:3px}
.touch #race-standings:not(.expanded){display:none}
.touch .race-standings{left:auto;right:calc(62px + var(--safe-right));top:calc(114px + var(--safe-top));width:190px;padding:9px 11px;font-size:11px;line-height:1.6;border-radius:10px;background:rgba(16,43,36,.94);z-index:18}
.touch .race-standings .standing-gap{font-size:10px}
.touch .speed-card{top:calc(64px + var(--safe-top));bottom:auto;left:calc(12px + var(--safe-left));transform:none;min-width:88px;height:44px;padding:7px 9px;gap:5px;align-items:baseline;border-radius:10px;background:rgba(16,43,36,.78);text-shadow:none}
.touch .speed-card strong{font-size:26px;line-height:30px;letter-spacing:-.5px}
.touch .speed-card>span{font-size:8px;letter-spacing:.3px}
.touch .speed-card .surface-badge{position:absolute;top:calc(100% + 5px);bottom:auto;left:0;transform:none;margin:0;max-width:150px;padding:5px 6px;font-size:9px;line-height:1.25;white-space:normal;text-align:left}
.touch .ability-button{left:calc(var(--drive-edge) + var(--safe-left));right:auto;bottom:calc(var(--drive-secondary) + var(--safe-bottom));transform:none;width:var(--drive-steering);min-height:54px;height:54px;padding:8px 10px 10px;gap:8px;justify-content:flex-start;text-align:left;border-radius:12px;background:rgba(16,43,36,.9)}
.touch .ability-icon{display:block;width:23px;height:23px;color:#edc987}
.touch .ability-button>span{min-width:0;gap:4px}
.touch .ability-button strong{font-size:11px;line-height:13px;white-space:normal}
.touch .ability-button small{font-size:9px;line-height:11px;letter-spacing:.4px}
.touch .ability-button>i{height:3px}
.touch .simple-steering,body.touch[data-controls="pedals"] .simple-steering{left:calc(var(--drive-edge) + var(--safe-left));right:auto;bottom:calc(var(--drive-bottom) + var(--safe-bottom));width:var(--drive-steering);height:90px;padding:0 12px 18px;border-radius:24px;background:rgba(16,43,36,.68);border:1px solid rgba(247,244,233,.5);box-shadow:inset 0 1px 0 rgba(247,244,233,.12)}
.touch .steer-thumb{width:52px;height:52px;left:calc(50% - 26px);top:10px;border:1px solid rgba(247,244,233,.7);background:rgba(247,244,233,.23)}
.touch .steer-thumb .kk-icon{width:25px;height:25px}
.touch .steer-rail{left:24px;right:24px;top:36px}
.touch .steer-arrow{font-size:0;opacity:.7}
.touch .control-caption{top:auto;bottom:8px;font-size:9px;line-height:11px;letter-spacing:.65px;text-shadow:none}
.touch .manual-pedals{left:auto;right:calc(var(--drive-edge) + var(--safe-right));bottom:calc(var(--drive-bottom) + var(--safe-bottom));gap:8px;align-items:flex-end;flex-direction:row}
.touch .pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal{height:78px;width:var(--drive-pedal);padding:6px 3px;border-radius:18px;gap:7px;border:1px solid rgba(255,255,255,.7)}
.touch .throttle-pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{height:90px;width:var(--drive-throttle);border-radius:18px;background:#e7be6e;border-color:#ffe0a5;box-shadow:0 2px 12px #0c231a30}
.touch .pedal .pedal-symbol{font-size:0;line-height:1}
.touch .pedal .pedal-symbol .kk-icon{width:29px;height:29px}
.touch .pedal .pedal-label,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal-label{font-size:10px;line-height:12px;letter-spacing:0}
.touch .manual-actions{left:auto;right:calc(var(--drive-edge) + var(--safe-right));bottom:calc(var(--drive-secondary) + var(--safe-bottom));gap:8px;flex-direction:row}
.touch .manual-actions .round-action{width:var(--drive-pedal);height:54px;padding:4px;border:1px solid rgba(255,255,255,.6);border-radius:14px;font-size:10px;line-height:12px;background:rgba(247,244,233,.9);gap:2px}
.touch .manual-actions .boost-action{width:var(--drive-throttle);background:#e7be6e}
.touch .manual-actions .kk-icon{width:23px;height:23px}
.touch .button-steering{left:calc(var(--drive-edge) + var(--safe-left));right:auto;bottom:calc(var(--drive-bottom) + var(--safe-bottom));width:var(--drive-steering);gap:8px}
.touch .steer-button{width:calc((100% - 8px)/2);height:90px;border-radius:18px}
.touch .touch-wheel{left:calc(var(--drive-edge) + var(--safe-left));right:auto;bottom:calc(var(--drive-bottom) + var(--safe-bottom));width:112px;height:112px}
.touch .touch-wheel .control-caption{bottom:-2px;transform:translate(-50%,100%);font-size:8px}
.touch .wheel-face{border-width:9px}
.touch .wheel-marker{top:-10px;height:12px;width:8px;left:calc(50% - 4px)}
.touch .wheel-hub{width:29px;height:29px}
.touch .wheel-spoke{height:8px;top:calc(50% - 4px)}
.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])){--drive-secondary:138px}
.touch .drive-action{right:calc(var(--drive-edge) + var(--safe-right));left:auto;bottom:calc(var(--drive-bottom) + var(--safe-bottom));width:calc(var(--drive-pedal) + var(--drive-throttle) + 8px);height:90px;border-radius:22px;border-width:1px;gap:3px;box-shadow:0 2px 12px #0c231a30;font-size:12px}
.touch .drive-action small{position:static;font-size:8px;line-height:11px;text-shadow:none;color:#4c462a;white-space:normal;max-width:125px;width:auto;right:auto;bottom:auto}
.touch .drive-action .kk-icon{width:28px;height:28px}
.touch .drift-meter{left:50%;transform:translateX(-50%);bottom:calc(184px + var(--safe-bottom));width:140px}
.touch #drift-label{font-size:10px;line-height:13px;margin-bottom:4px}
.touch .race-countdown{top:43%;font-size:82px;min-width:100px}
.touch .lesson-card{top:calc(126px + var(--safe-top));left:12px;right:12px;width:auto;transform:none;max-width:360px;padding:10px 12px;gap:9px;border-radius:10px}
.touch .lesson-number{font-size:9px}
.touch .lesson-card h2{font-size:13px}
.touch .lesson-card p{font-size:11px;line-height:1.4}

/* Mirroring moves the whole thumb station, including its secondary actions. */
body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .simple-steering,body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .touch-wheel,body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .ability-button{left:auto;right:calc(var(--drive-edge) + var(--safe-right))}
body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-pedals,body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .manual-actions{right:auto;left:calc(var(--drive-edge) + var(--safe-left));flex-direction:row-reverse}
body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .drive-action{right:auto;left:calc(var(--drive-edge) + var(--safe-left))}
@media(max-width:359px) and (orientation:portrait){
 body.touch{--drive-edge:8px;--drive-steering:144px;--drive-pedal:64px;--drive-throttle:72px}
 .touch .race-hud{padding-left:8px;padding-right:8px}
 .touch .race-top{grid-template-columns:52px minmax(78px,1fr) 76px 44px;gap:5px}
 .touch .ability-button{gap:5px;padding-left:8px;padding-right:8px}
 .touch .ability-button strong{font-size:10px}
 .touch .ability-icon{width:20px;height:20px}
}
@media(orientation:landscape){
 body.touch{--drive-steering:184px;--drive-secondary:114px}
 .touch .race-top{display:flex;gap:6px}
 .touch .position-card{width:56px}
 .touch .route-card{width:132px}
 .touch .time-card{width:80px}
 .touch .pause-button{position:absolute;right:calc(12px + var(--safe-right));top:calc(8px + var(--safe-top))}
 .touch .minimap-panel{right:calc(62px + var(--safe-right));top:calc(8px + var(--safe-top))}
 .touch .race-tools{right:calc(112px + var(--safe-right));top:calc(8px + var(--safe-top))}
 .touch .race-tool,.touch .minimap-toggle{height:48px}
 .touch .minimap-content{top:54px}
 .touch .race-standings{right:calc(112px + var(--safe-right));top:calc(62px + var(--safe-top))}
 .touch .lesson-card{top:calc(64px + var(--safe-top));left:50%;right:auto;transform:translateX(-50%);width:min(300px,38vw);max-width:none;padding:9px 11px}
 .touch .lesson-number{display:none}
 .touch .lesson-card h2{font-size:12px;margin-bottom:3px}
 .touch .lesson-card p{font-size:11px;line-height:1.35}
 .touch .lesson-checks{margin-top:5px}
 .touch .drift-meter{bottom:calc(18px + var(--safe-bottom));width:130px}
}
@media(orientation:landscape) and (min-width:760px){
 .touch .speed-card{left:calc(298px + var(--safe-left));top:calc(8px + var(--safe-top));height:48px;padding-top:9px}
}
@media(orientation:landscape) and (max-width:650px){
 .touch .position-card{width:52px}.touch .route-card{width:112px}.touch .time-card{width:74px}
 .touch .race-tool,.touch .minimap-toggle,.touch .pause-button{width:44px;min-width:44px}
 .touch .race-tools{gap:4px;right:calc(108px + var(--safe-right))}
 .touch .minimap-panel{right:calc(60px + var(--safe-right))}
 .touch .lesson-card{width:34vw;font-size:10px}
}
@media(orientation:landscape) and (max-height:350px){
 body.touch{--drive-bottom:8px;--drive-steering:170px;--drive-secondary:96px}
 .touch .simple-steering,body.touch[data-controls="pedals"] .simple-steering{height:76px}
 .touch .steer-thumb{width:46px;height:46px;left:calc(50% - 23px);top:5px}
 .touch .steer-rail{top:28px}
 .touch .simple-steering{padding-bottom:20px}
 .touch .steer-arrow .kk-icon{width:18px;height:18px}
 .touch .control-caption{bottom:6px;font-size:8px}
 .touch .pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .pedal{height:70px}
 .touch .throttle-pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{height:80px}
 .touch .ability-button,.touch .manual-actions .round-action{height:44px;min-height:44px;padding-top:4px;padding-bottom:5px}
 .touch .ability-button strong{font-size:10px;line-height:11px}
 .touch .ability-button small{font-size:8px;line-height:10px}
 .touch .manual-actions .kk-icon{width:19px;height:19px}
 .touch .manual-actions .round-action{font-size:9px;gap:0}
 .touch .steer-button{height:76px}
 .touch .touch-wheel{width:90px;height:90px}
 .touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])){--drive-secondary:108px}
 .touch .touch-wheel .control-caption{display:none}
 .touch .drive-action{height:80px}
 .touch .drive-action small{font-size:8px}
 .touch .speed-card{height:38px;padding-top:4px;padding-bottom:4px}
 .touch .speed-card strong{font-size:24px}
 .touch .race-countdown{font-size:65px}
}
@media(prefers-reduced-motion:reduce){.touch-controls *,.race-hud *{transition:none!important}}
/* Installation and updates live in the scrolling menu, outside the race view. */
.discovery-links .install-app-entry{grid-column:1/-1;display:flex;align-items:center;gap:9px;min-height:48px;width:100%;padding:8px 10px;border:1px solid var(--line);border-radius:4px;background:#e7ecdf;text-align:left;font-size:12px;font-weight:700}
.install-app-entry small{margin-left:auto;font-size:10px;font-weight:400;color:#52675a}
.pwa-status-panel{margin:12px 0 0;padding:12px 13px;border:1px solid #bac9af;border-radius:7px;background:#f3f5e8;color:var(--ink);font-size:12px;line-height:1.5;pointer-events:auto}
.pwa-status-panel p{margin:0 0 8px}
.pwa-status-panel>div{display:flex;gap:8px;flex-wrap:wrap}
.pwa-status-panel button{min-height:44px;padding:8px 13px;border:1px solid #8da087;border-radius:5px;background:var(--paper);font-size:12px;font-weight:700}
.pwa-status-panel #pwa-update-btn{color:var(--paper);background:var(--ink)}
.pwa-status-panel[hidden],.pwa-status-panel button[hidden],.install-app-entry[hidden],body:not([data-screen="home"]) .pwa-status-panel{display:none!important}
.position-card .compact-label{display:none}
.touch .position-card .wide-label{display:none}
.touch .position-card .compact-label{display:inline}
/* Open map/order panels use the middle lane on short landscape screens,
   so they never cover either thumb station. The close buttons stay put. */
@media(orientation:landscape) and (max-height:600px){
 .touch .minimap-content{position:fixed;top:calc(62px + var(--safe-top));left:50%;right:auto;transform:translateX(-50%);width:clamp(128px,calc(var(--game-width,100vw) - 380px - var(--safe-left) - var(--safe-right)),164px)}
 .touch .minimap-content>svg{height:100px}
 .touch .race-standings{left:50%;right:auto;transform:translateX(-50%);width:clamp(128px,calc(var(--game-width,100vw) - 380px - var(--safe-left) - var(--safe-right)),190px);max-height:calc(var(--game-height,100dvh) - 72px - var(--safe-top) - var(--safe-bottom));overflow:auto}
}

/* Narrow portrait keeps the secondary row below the central driving view. */
@media(max-width:359px) and (orientation:portrait){
 body.touch{--drive-secondary:104px}
 .touch .ability-button,.touch .manual-actions .round-action{height:44px;min-height:44px}
 .touch .simple-steering,body.touch[data-controls="pedals"] .simple-steering,.touch .steer-button{height:80px}
 .touch .throttle-pedal{height:80px}
 .touch .brake-pedal{height:70px}
}
/* Wheel mode reserves height only above the wheel, keeping pedals lower. */
@media(orientation:portrait){
 body.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .ability-button{width:112px}
 body.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .manual-actions{bottom:calc(114px + var(--safe-bottom))}
}
@media(max-width:359px) and (orientation:portrait){
 body.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .manual-actions{bottom:calc(104px + var(--safe-bottom))}
 .touch .throttle-pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .throttle-pedal{height:80px}
 .touch .brake-pedal,body.touch:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"]) .brake-pedal{height:70px}
}

/* Full local model pack status stays within the existing menu column. */
.model-detail-status{max-width:38rem;margin:10px 0 0;color:#426156;font-size:12px;line-height:1.4}.model-detail-status[hidden]{display:none}

/* 1.8.5: keep automatic messages outside the moving road view. */
.race-announcer{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important;pointer-events:none!important}
body[data-screen="race"]:not(.race-paused) #save-status,body[data-screen="race"] #keyboard-hint{display:none!important}
body[data-screen="race"] .pwa-status-panel,body[data-screen="race"] .install-app-entry{display:none!important}
#pause-dialog .pause-guidance{position:static;left:auto;right:auto;top:auto;bottom:auto;transform:none;width:100%;max-width:none;margin:0 0 16px;padding:12px 14px;gap:10px;border:1px solid #cdd7c3;border-radius:8px;background:#e9eee1;box-shadow:none;text-align:left}
#pause-dialog .pause-guidance .lesson-number{display:block;flex:none;padding-top:2px;font-size:10px}
#pause-dialog .pause-guidance h2{font-size:15px;line-height:1.3;letter-spacing:0;margin:0 0 5px}
#pause-dialog .pause-guidance p{font-size:13px;line-height:1.5;margin:0}
#pause-dialog .pause-run-summary{font-size:12px;line-height:1.4;margin:0 0 15px;color:#52675a}
.result-panel>.save-status{position:static;transform:none;width:100%;max-width:none;margin:14px 0 0;box-shadow:none;flex-wrap:wrap}
body:not(.touch) .drift-meter{left:calc(28px + var(--safe-left));right:auto;bottom:calc(24px + var(--safe-bottom));transform:none;width:172px;text-align:left}
body.touch .drift-meter{left:auto;right:calc(var(--drive-edge) + var(--safe-right));bottom:calc(var(--drive-secondary) - 7px + var(--safe-bottom));transform:none;width:calc(var(--drive-pedal) + var(--drive-throttle) + 8px);height:3px;margin:0;padding:0;text-shadow:none;pointer-events:none}
body.touch .drift-meter #drift-label{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);clip-path:inset(50%);white-space:nowrap;margin:-1px;padding:0;border:0}
body.touch .drift-meter .drift-track{height:3px;box-shadow:none}
body.touch:is([data-touch-layout="lefty"],[data-touch-layout="buttons-lefty"]) .drift-meter{right:auto;left:calc(var(--drive-edge) + var(--safe-left))}
@media(orientation:portrait){body.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .drift-meter{bottom:calc(107px + var(--safe-bottom))}}
@media(max-width:359px) and (orientation:portrait){body.touch[data-controls="manual"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .drift-meter{bottom:calc(97px + var(--safe-bottom))}}
/* Automatic assist has a single taller brake/drift control. */
body.touch[data-controls="simple"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .drift-meter{bottom:calc(var(--drive-bottom) + 94px + var(--safe-bottom))}
@media(orientation:landscape) and (max-height:350px){body.touch[data-controls="simple"]:not(:is([data-touch-layout="buttons"],[data-touch-layout="buttons-lefty"])) .drift-meter{bottom:calc(var(--drive-bottom) + 84px + var(--safe-bottom))}}
