/* r30: road-first cockpit. Icon artwork is small; touch targets stay 44 px. */
:root{--cockpit-glass:#080d15d9;--cockpit-edge:#b6c7db38;--boost-mint:#81ffe6}
.sr-only{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;white-space:nowrap!important;border:0!important}
.control-icon{width:24px;height:24px;flex:0 0 auto;vertical-align:middle;pointer-events:none}
.icon-button{display:inline-flex;align-items:center;justify-content:center;gap:9px}
#raceTools{user-select:none;touch-action:manipulation;display:flex;align-items:center;gap:2px;margin-left:auto;pointer-events:auto}
#raceTools button,#raceTools .audio-mute,body.large-text #raceTools button{position:relative;inset:auto;width:44px;height:44px;min-height:44px;min-width:44px;padding:10px;margin:0;border:0;background:transparent;border-radius:50%;color:#f4f6fb;font-size:0;isolation:isolate}
#raceTools button:before,body.large-text #raceTools button:before{content:'';position:absolute;inset:4px;background:#080d15d9;border:1px solid #ffffff38;border-radius:50%;z-index:-1}
#raceTools button:hover:before,#raceTools button[aria-pressed=true]:before{border-color:#e9c447;background:#262718}
#raceTools .control-icon{width:21px;height:21px}
body:not(.playing) #raceTools #raceInfo,body:not(.playing) #raceTools #pause{display:none}
.playing header{left:max(16px,env(safe-area-inset-left));right:max(16px,env(safe-area-inset-right));top:max(10px,env(safe-area-inset-top));min-height:44px;pointer-events:none}
.playing header>img,.playing header>.edition,.playing header>.language-control{display:none}
.playing .hud-brand{top:max(23px,calc(env(safe-area-inset-top) + 13px));left:max(20px,env(safe-area-inset-left))}
.playing .hud-brand img{width:112px}.playing .hud-brand span{font-size:9px}
.hudtop{top:max(70px,calc(env(safe-area-inset-top) + 60px));right:auto;left:24px;grid-template-columns:148px 132px;gap:8px}
.hudtop>div{padding:9px 12px;background:var(--cockpit-glass);border-color:var(--cockpit-edge)}
.hudtop strong{font-size:2rem}.hudtop small{font-size:10px}
.healthtrack{height:4px;margin:9px 0 5px}
#hud>.progress{position:absolute;left:24px;right:auto;bottom:24px;width:310px;max-width:calc(100vw - 48px);padding:9px 11px;background:var(--cockpit-glass);border:1px solid var(--cockpit-edge);border-radius:8px;display:grid;gap:3px;transform:none}
#hud>.progress>div{font-size:10px;line-height:1.3;display:flex;justify-content:space-between;gap:4px}
#hud>.progress #chart{display:block;width:100%;height:44px}
#hud>.progress #price{display:block;font:600 10px/1.3 system-ui,sans-serif;white-space:nowrap}
#hud>.progress #trackPeriod{display:none}
#hud>.progress>div:last-child>span:last-child{display:none}
#hud>.progress #percent{color:#f6d765;font-variant-numeric:tabular-nums}
#hint{display:none}
.cockpit-dial.telemetry{left:24px;bottom:133px;width:164px;height:152px;display:block;color:#f1ce61;background:radial-gradient(ellipse at 50% 51%,#080d18dd 38%,#080d1880 61%,transparent 69%);pointer-events:none}
.speed-dial{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
.speed-dial text{font:10px system-ui,sans-serif;fill:#aeb9ca}
#speedNeedle{transform-origin:100px 100px}
.cockpit-dial #speed{position:absolute;left:0;right:0;top:57px;text-align:center;font:700 46px/.9 'Barlow Condensed',sans-serif;letter-spacing:-.025em;color:#fff;font-variant-numeric:tabular-nums}
.cockpit-dial>span{position:absolute;top:103px;left:0;right:0;text-align:center;font:9px/1 system-ui,sans-serif;letter-spacing:.18em;color:#b6c0d1}
.cockpit-dial #hudLev{position:absolute;top:122px;left:0;right:0;text-align:center;font:600 13px/1.1 'Barlow Condensed',sans-serif;letter-spacing:.06em;color:#edce75}
.cockpit-dial.nitro-active{color:#72eaff}.cockpit-dial.strip-active{color:var(--boost-mint)}
#stripStatus{position:absolute;top:-16px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:4px;white-space:nowrap;padding:3px 7px;border:1px solid #83ffe773;border-radius:5px;color:#b0ffec;background:#062c28ed;font:700 9px/1.2 system-ui,sans-serif}
#stripStatus .control-icon{width:12px;height:12px}
#touch{bottom:24px}#touch .control-icon{width:26px;height:26px}
#touch [data-control=brake]{color:#f5d5bb}
#touch .boost{color:#93eeff;background:#092934d9;border-color:#57cee980}
#damageStatus{min-width:116px;top:calc(100% + 7px)}
#damageStatus>strong{font-size:16px}#damageStatus>span{font-size:10px}
/* The poster itself is the primary result, using the same canvas as PNG export. */
.poster-result .modalbody{width:min(940px,100%);display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:0 28px;padding:24px;align-items:start}
#resultPosterPanel{grid-column:1;grid-row:1/7;margin:0;width:100%;align-self:center;min-width:0}
#resultPoster{display:block;width:100%;height:auto;max-height:calc(100dvh - 92px);object-fit:contain;border:1px solid #ffffff1a;border-radius:5px}
.poster-placeholder{aspect-ratio:4/5;display:grid;place-items:center;color:#d6c47e;background:#080c12;border:1px solid #ffffff1a;font-size:13px}
.poster-result .modalbody> :not(#resultPosterPanel){grid-column:2}
.poster-result .result-weex{width:116px;margin-bottom:12px}
.poster-result #resultTag{font-size:9px}.poster-result h2{font-size:24px;margin:9px 0}
.poster-result .result-time{font-size:42px}.poster-result #resultContent>p:not(.market-result):not(.disclaimer){font-size:12px;margin:8px 0}
.poster-result .result-stats{gap:10px;padding:12px 0;margin-top:12px}.poster-result .result-stats span{font-size:10px}.poster-result .result-stats b{font-size:17px}
.poster-result .market-result{font-size:10px;padding:8px;margin:4px 0}.poster-result .disclaimer{font-size:9px;line-height:1.5}
.poster-result .actions{gap:7px;margin-top:14px}.poster-result .actions button{font-size:11px;min-height:44px;padding:9px 7px}.poster-result .actions .control-icon{width:18px;height:18px}
@media(pointer:coarse),(max-width:650px){
 .playing .hud-brand{left:max(16px,env(safe-area-inset-left));top:max(23px,calc(env(safe-area-inset-top) + 13px))}.playing .hud-brand img{width:96px}
 .hudtop,body.large-text .hudtop{left:var(--drive-left);top:max(65px,calc(env(safe-area-inset-top) + 55px));width:calc(52% - 21px);grid-template-columns:1fr;gap:0}
 .hudtop>div{padding:5px 8px;border:0;border-radius:0;background:var(--cockpit-glass)}
 .hudtop>div:first-child{border-radius:7px 7px 0 0}.hudtop .health{border-radius:0 0 7px 7px;padding-top:3px;padding-bottom:7px;display:grid;grid-template-columns:1fr 25px;align-items:center;gap:0 5px}
 .hudtop small,body.large-text .hudtop small{font-size:8px;line-height:1.25}.hudtop strong,body.large-text .hudtop strong{font-size:25px;line-height:1.1}
 .health small{display:none}.healthtrack{margin:0;height:4px}.health b,body.large-text .health b{font:600 12px/1.2 'Barlow Condensed',sans-serif;text-align:right}
 #hud>.progress,body.large-text #hud>.progress{top:max(65px,calc(env(safe-area-inset-top) + 55px));left:auto;right:var(--drive-right);bottom:auto;width:calc(48% - 19px);padding:7px 8px;gap:2px;min-height:67px}
 #hud>.progress>div,#hud>.progress>div>span{font-size:8px;line-height:1.2}
 #hud>.progress>div:first-child{display:block}#hud>.progress #date{display:none}#hud>.progress #price{font-size:9px;overflow:hidden;text-overflow:ellipsis}
 #hud>.progress #chart{display:block;height:30px}#hud>.progress>div:last-child{margin:0}
 .cockpit-dial.telemetry{left:var(--drive-left);bottom:calc(var(--drive-bottom) + 85px);width:122px;height:113px}
 .cockpit-dial #speed{top:42px;font-size:35px}.cockpit-dial>span{top:77px;font-size:7px}.cockpit-dial #hudLev{top:91px;font-size:11px}
 #touch button,#touch button.boost,body.large-text #touch button{min-height:64px;border-width:1px;border-radius:12px}
 #touch .control-icon{width:26px;height:26px}
 #damageStatus{left:0;transform:translateX(0)!important;min-width:112px;width:max-content;padding:5px 8px}
 #damageStatus>strong{font-size:14px!important}#damageStatus>span{font-size:9px}
 .health.impacted #pickupStatus{top:calc(100% + 58px)}
 #nitroStatus{bottom:calc(var(--drive-bottom) + 77px)}
}
@media(pointer:coarse) and (orientation:landscape){
 .hudtop,body.large-text .hudtop{width:154px}.cockpit-dial.telemetry{width:100px;height:93px;bottom:calc(var(--drive-bottom) + 70px)}
 .cockpit-dial #speed{top:35px;font-size:29px}.cockpit-dial>span{top:63px;font-size:6px}.cockpit-dial #hudLev{top:76px;font-size:9px}
 #hud>.progress,body.large-text #hud>.progress{width:174px}
 #stripStatus{top:-12px;font-size:8px}
}
@media(max-width:650px){
 .poster-result .modalbody{display:block;padding:16px;width:100%;max-height:calc(100dvh - 24px)}
 .poster-result #resultPosterPanel{width:min(100%,360px);margin:0 auto 14px}
 #resultPoster{max-height:56dvh}
 .poster-result .result-weex,.poster-result #resultTag,.poster-result .result-time,.poster-result #resultContent>p:not(.market-result):not(.disclaimer):not(#shareStatus){display:none}
 .poster-result h2{font-size:18px;margin:8px 0}.poster-result .result-stats{grid-template-columns:repeat(4,minmax(0,1fr));padding:8px 0;margin-top:6px;gap:6px}
 .poster-result .result-stats span{font-size:9px}.poster-result .result-stats b{font-size:14px}
 .poster-result .market-result,.poster-result .disclaimer{display:none}.poster-result .actions{margin-top:9px}.poster-result .actions .primary{min-height:46px}
}
@media(prefers-reduced-motion:reduce){.cockpit-dial{transition:none}.icon-button{transition:none}}

/* Combined boost is a separate gold tier, with one compact status label. */
.cockpit-dial.combo-active{color:#ffe58c}
.combo-active #stripStatus{color:#fff1b8;border-color:#ffe28caa;background:#392a07ed;box-shadow:0 0 16px #ffd06d28}
@media(prefers-reduced-motion:reduce){.combo-active #stripStatus{box-shadow:none}}
