/* Layout and installable web-app support. Safari15.4+,320px and up. */
html{height:100%;overflow:hidden;-webkit-text-size-adjust:100%;overscroll-behavior:none}body{height:100vh;height:100dvh;height:var(--app-height,100dvh);position:fixed;inset:0;min-width:0;overflow:hidden;padding-top:env(safe-area-inset-top,0px);padding-bottom:max(8px,env(safe-area-inset-bottom,0px));padding-left:max(24px,env(safe-area-inset-left,0px));padding-right:max(24px,env(safe-area-inset-right,0px));grid-template-rows:72px minmax(0,1fr) 84px;overscroll-behavior:none}body[data-screen="welcome"]{grid-template-rows:72px minmax(0,1fr) 12px}main,.view{min-width:0}button{touch-action:manipulation}button,a,input,select{-webkit-tap-highlight-color:transparent}button,input,select{min-height:44px}input,select,textarea{font-size:16px}.mobile-games,.mobile-body-filter{display:none}#navigation button{min-width:0;flex:1;padding-left:15px;padding-right:15px}#navigation{width:min(100%,760px)}.car-card{min-height:0;overflow:hidden;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:16px 27px minmax(40px,1fr) 38px 44px;gap:4px;padding:13px 15px}.car-info{min-height:0}.car-info h2{margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.car-photo{min-height:0;height:100%;margin:0}.car-description{margin:0;font-size:14px;line-height:19px;color:#727c89;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.car-bottom button{min-height:40px}.car-bottom{min-width:0}.car-price{white-space:nowrap;font-size:15px}.car-grid{min-height:0}.garage-view{grid-template-rows:70px 60px minmax(0,1fr) 50px}.garage-bottom{min-height:0}.garage-tools input,.garage-tools select{min-width:0}.garage-bottom .pager button{min-height:44px}.empty p{max-width:420px}.empty button{justify-self:center}.model-description{font-size:14px;line-height:1.55;color:#6f7b89}.game-menu{display:grid;grid-template-rows:90px minmax(0,1fr);padding:24px 3% 0;gap:16px}.game-menu h1{font-size:40px;letter-spacing:-1.7px;margin:12px 0}.game-choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));gap:16px;padding-bottom:16px}.game-choices button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;background:white;border:1px solid #e2e7ef;border-radius:24px;padding:15px;min-height:0}.game-choices strong{font-size:19px;font-weight:550}.game-choices button>span:last-child{font-size:14px;color:#7d8794}.choice-icon{font-size:32px;color:#4c7ea8}.install-link{margin-left:16px}.install-steps{padding-left:23px;display:grid;gap:12px;font-size:15px;line-height:1.5;color:#6d7682}.install-steps strong{color:#303844;font-weight:550}.install-source{font-size:14px}.offline-page{display:grid;place-items:center;padding:25px}.offline-page main{height:auto;max-width:440px}.offline-page h1{font-size:45px}.offline-page p{font-size:16px;margin-bottom:30px}.offline-page .primary{text-decoration:none;display:inline-block}.offline-page .brand-mark{width:50px;height:50px}.compact-cards .car-card{grid-template-columns:115px minmax(0,1fr);grid-template-rows:16px 25px minmax(30px,1fr) 44px;gap:4px 12px}.compact-cards .car-photo{grid-column:1;grid-row:1/4}.compact-cards .model-meta,.compact-cards .car-info,.compact-cards .car-description{grid-column:2}.compact-cards .car-bottom{grid-column:1/-1}.compact-cards .model-meta{font-size:11px}.compact-cards .car-description{font-size:12px;line-height:16px}#close-dialog{position:absolute;right:12px;top:12px;z-index:10;display:grid;place-items:center;padding:0;width:40px;height:40px;min-height:40px;border:1px solid #e0e4ea;border-radius:50%;background:#fffffff2;color:#4d5868;box-shadow:0 2px 10px #15213a12;line-height:1;-webkit-appearance:none;appearance:none}#close-dialog svg{width:18px;height:18px;display:block;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;pointer-events:none}dialog{position:fixed;top:calc(var(--vv-top,0px) + max(12px,env(safe-area-inset-top,0px)));bottom:auto;left:0;right:0;margin:0 auto;max-height:calc(var(--vv-height,100dvh) - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px) - 24px);overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;scroll-padding:50px 16px 24px}dialog:focus{outline:none}.profile-form input,.auth-form input,.garage-tools input,.garage-tools select,.config-label select{font-size:16px}dialog .form-error{overflow-wrap:anywhere}.play-footer{min-height:44px}.play-footer #touch-controls button{min-width:44px;min-height:44px}.play-footer #bank-out{min-height:44px}.session-actions{flex-wrap:wrap}.code-display{box-sizing:border-box}.game-overlay{overflow:auto;overscroll-behavior:contain}.game-overlay .primary{flex:none}.garage-heading{gap:10px}.garage-heading h1{white-space:nowrap}
@media(max-width:700px){body{padding-left:max(12px,env(safe-area-inset-left,0px));padding-right:max(12px,env(safe-area-inset-right,0px));grid-template-rows:58px minmax(0,1fr) 74px}body[data-screen="welcome"]{grid-template-rows:58px minmax(0,1fr) 8px}.mobile-games{display:grid!important}#navigation .desktop-game{display:none}#navigation{width:100%;border-radius:19px;gap:3px}#navigation button{font-size:12px;padding:7px 4px;min-height:55px}.nav-icon{font-size:22px}header{gap:9px}.brand{gap:7px;font-size:16px}.brand-mark{width:30px;height:30px;min-width:30px}.brand-light{display:none}#account-button{font-size:12px;max-width:100px;padding:8px 10px}.wallet{gap:2px}.wallet strong{font-size:17px;white-space:nowrap}.wallet span{font-size:10px}#help{width:32px;min-width:32px;height:32px;min-height:32px}.garage-view{padding:10px 0 0;grid-template-rows:48px 48px minmax(0,1fr) 46px;gap:7px}.garage-heading h1{font-size:28px;letter-spacing:-1px;margin:5px 0}.garage-heading .eyebrow{font-size:10px;letter-spacing:1px}.garage-heading .subtle{font-size:12px}.garage-heading #guest-back{font-size:13px;padding:7px 12px}.filters{display:block;min-width:0}.filters .segments{display:none}.garage-tools{height:100%;display:grid;grid-template-columns:minmax(90px,1fr) 99px 98px;gap:7px;min-width:0}.mobile-body-filter{display:block}.garage-tools input{width:100%;font-size:16px;padding:10px;min-height:44px}.garage-tools select{max-width:none;width:100%;font-size:13px;padding:8px 9px;min-height:44px}.garage-tools .search{min-width:0}.car-grid{gap:9px}.car-card{border-radius:18px;grid-template-rows:15px 24px minmax(35px,1fr) 36px 44px;padding:12px;gap:5px}.car-info h2{font-size:19px}.car-card .model-meta{font-size:11px}.car-description{font-size:13px;line-height:18px}.car-bottom button{font-size:14px;padding:8px 16px;min-height:44px}.car-price{font-size:16px}.garage-bottom{flex-direction:row;gap:8px;justify-content:space-between}.garage-bottom>span{display:none}.pager{justify-content:space-between;width:100%;font-size:13px;gap:8px}.pager .soft-button{font-size:14px;padding:8px 14px;min-height:44px}.compact-cards .car-card{grid-template-columns:98px minmax(0,1fr);grid-template-rows:14px 22px minmax(23px,1fr) 44px;gap:3px 10px;padding:10px}.compact-cards .car-info h2{font-size:17px}.compact-cards .car-description{font-size:12px;line-height:15px}.compact-cards .model-meta>span:last-child{display:none}.game-menu{grid-template-rows:57px minmax(0,1fr);padding:16px 0 0;gap:12px}.game-menu h1{font-size:29px;margin:8px 0}.game-menu .eyebrow{font-size:11px}.game-choices{grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(3,minmax(0,1fr));gap:10px;padding-bottom:5px}.game-choices button{border-radius:19px;gap:7px;padding:10px}.game-choices button:last-child{grid-column:1/-1}.game-choices strong{font-size:16px}.game-choices button>span:last-child{font-size:12px}.choice-icon{font-size:25px}.install-link{margin-left:0;display:block;width:100%;padding:6px 0 10px;font-size:14px}.welcome-view{padding-top:17px;gap:12px}.welcome-view h1{font-size:36px;margin:12px 0}.welcome-view p{font-size:14px}.welcome-actions{margin-top:15px}.welcome-actions button{min-height:44px;font-size:14px}.welcome-note{font-size:11px}.welcome-art{max-height:none;padding:12px}.welcome-art .welcome-features{margin-top:9px}.welcome-art #welcome-car{margin:9px 0;min-height:0}.welcome-art .welcome-label{font-size:10px}.play-view{padding-top:8px;grid-template-rows:86px minmax(0,1fr) 56px;gap:7px}.play-heading h1{font-size:26px}.play-heading>.soft-button{top:17px;min-height:40px}.play-footer{gap:3px;justify-content:center}.play-footer>span:first-child{display:none}.play-footer #touch-controls{gap:5px}.play-footer #touch-controls button{padding:9px 13px;font-size:12px;min-width:44px;min-height:44px}.play-footer #bank-out{font-size:12px;padding:8px 12px}.game-overlay h2{font-size:27px}.game-overlay p{font-size:14px;line-height:1.5}.life-hud{right:10px;top:10px;padding:6px 8px;font-size:20px!important;letter-spacing:1px!important}.city-heading h1{font-size:29px}.city-heading p{font-size:13px}.city-grid{gap:8px}.city-card{padding:12px 10px}.city-card button{font-size:12px;min-height:44px;padding:7px 10px}.city-card p{font-size:12px}.city-card h2{font-size:16px}.city-icon{width:29px;height:29px}.city-view{padding-top:14px;gap:12px}.city-ledger .vehicle-note{font-size:11px!important}.detail-photo{height:165px}.model-description{font-size:14px!important;line-height:1.5!important}.detail-numbers strong{font-size:17px}.vehicle-detail .config-label select{font-size:16px}.vehicle-actions button{min-height:44px;font-size:14px}.spec-strip span{font-size:12px}.auth-form input,.profile-form input{font-size:16px!important}.auth-form .code-input{font-size:16px}.install-steps{font-size:14px;gap:10px}dialog{width:calc(100% - 20px);padding:25px;max-height:calc(var(--vv-height,100dvh) - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px) - 20px)}.detail-photo{margin:-25px -25px 18px}#close-dialog{right:10px;top:10px;width:40px;height:40px}.code-display{font-size:15px;letter-spacing:.3px;height:96px}.profile-code .code-display{font-size:15px}.form-note{font-size:12px}.session-actions button{font-size:13px;min-height:44px}.profile-form{gap:12px}.profile-row button{min-height:44px}.code-actions{flex-wrap:wrap}.code-actions button{min-height:44px}}
@media(max-width:380px){.garage-tools{grid-template-columns:minmax(75px,1fr) 87px 88px;gap:5px}.garage-tools select{font-size:12px;padding:8px 5px}.wallet strong{font-size:15px}#account-button{max-width:77px;font-size:12px;padding:7px 8px}.brand-mark{width:27px;height:27px;min-width:27px}.brand{font-size:14px}.welcome-view h1{font-size:31px}.code-display,.profile-code .code-display{font-size:13px;letter-spacing:.3px}.compact-cards .car-card{grid-template-columns:85px minmax(0,1fr);gap:3px 8px}.compact-cards .car-info h2{font-size:16px}}
@media(max-width:700px) and (max-height:650px){body{grid-template-rows:50px minmax(0,1fr) 67px}body[data-screen="welcome"]{grid-template-rows:50px minmax(0,1fr) 5px}.game-menu{grid-template-rows:42px minmax(0,1fr);gap:8px;padding-top:8px}.game-menu h1{font-size:25px;margin:5px 0}.game-menu .eyebrow{font-size:10px}.game-choices{gap:7px}.game-choices button{gap:4px;padding:7px}.game-choices .choice-icon{font-size:20px}.game-choices strong{font-size:14px}.game-choices button>span:last-child{font-size:11px}.garage-view{grid-template-rows:42px 44px minmax(0,1fr) 44px;gap:5px;padding-top:5px}.garage-heading h1{font-size:24px}.garage-heading .eyebrow{font-size:9px}.play-view{grid-template-rows:72px minmax(0,1fr) 50px;gap:5px}.play-heading h1{font-size:23px}.game-stats span{font-size:10px}.game-stats strong{font-size:13px}.play-heading>.soft-button{top:11px}.game-overlay h2{font-size:22px}.game-overlay p{font-size:13px;margin:9px 0 15px}.game-overlay .overlay-tag{font-size:10px}.game-overlay{padding:15px}.welcome-copy .eyebrow{font-size:10px}.welcome-view{padding-top:10px;gap:5px}.welcome-view h1{font-size:29px;margin:9px 0}.welcome-view p{font-size:12px}.welcome-actions{margin-top:10px;gap:7px}.welcome-actions button{font-size:12px!important;padding:9px 13px!important}.welcome-copy .text-button{min-height:35px;padding:5px 0;font-size:12px}.welcome-copy .welcome-note{font-size:10px}.welcome-art .welcome-model{font-size:11px}.welcome-art .welcome-label,.welcome-art .welcome-features{display:none}.city-heading .eyebrow{font-size:10px}.city-heading h1{font-size:25px}.city-view{gap:9px;padding-top:9px}.city-ledger .vehicle-note{display:none}.city-card p{display:none}}
@media(orientation:landscape) and (max-height:500px){body{grid-template-columns:66px minmax(0,1fr);grid-template-rows:46px minmax(0,1fr);gap:0 10px;padding-bottom:max(6px,env(safe-area-inset-bottom,0px));padding-left:max(10px,env(safe-area-inset-left,0px));padding-right:max(10px,env(safe-area-inset-right,0px))}body[data-screen="welcome"]{grid-template-columns:1fr;grid-template-rows:46px minmax(0,1fr)}header{grid-column:1/-1;grid-row:1}main{grid-column:2;grid-row:2}body[data-screen="welcome"] main{grid-column:1}#navigation{grid-column:1;grid-row:2;display:flex;flex-direction:column;justify-content:center;width:66px;height:100%;gap:3px;padding:4px;margin:0;border-radius:16px}#navigation button{min-width:0;min-height:44px;flex:1;padding:3px 1px;font-size:10px;gap:1px}#navigation .desktop-game{display:none}.mobile-games{display:grid!important}.nav-icon{font-size:20px;line-height:21px}.play-view{grid-template-rows:47px minmax(0,1fr) 46px;gap:5px;padding-top:5px}.play-heading{flex-wrap:nowrap;gap:10px}.play-heading>div:first-child{width:auto}.play-heading h1{font-size:21px;margin:3px 0}.play-heading .eyebrow{display:none}.game-stats{width:auto;margin-left:auto;gap:14px}.game-stats>div{display:grid;gap:2px}.game-stats span{font-size:10px}.game-stats strong{font-size:13px}.play-heading>.soft-button{position:static;min-height:36px;padding:6px 10px;font-size:12px}.play-footer>span:first-child{display:none}.play-footer{justify-content:center;gap:8px}#touch-controls button{min-height:40px;padding:7px 12px;font-size:12px}.arena{border-radius:14px}.life-hud{top:6px;right:8px;font-size:17px!important;padding:3px 7px}.game-overlay{padding:10px}.game-overlay h2{font-size:22px;margin:6px 0}.game-overlay .overlay-tag{display:none}.game-overlay p{font-size:12px;line-height:1.4;margin:7px 0 10px;max-width:500px}.game-overlay .primary{font-size:14px;padding:9px 22px;min-height:38px}.garage-view{grid-template-rows:37px 44px minmax(0,1fr) 42px;gap:4px;padding-top:4px}.garage-heading h1{font-size:23px;margin:3px 0}.garage-heading .eyebrow{display:none}.garage-heading .subtle{font-size:12px}.segments{display:none}.filters{display:block}.garage-tools{display:grid;grid-template-columns:1fr 120px 110px;height:100%;width:100%}.mobile-body-filter{display:block}.garage-tools select{max-width:none;font-size:13px}.garage-tools input{font-size:16px;padding:8px 12px}.garage-bottom>span{display:none}.pager{width:100%;justify-content:space-between}.pager button{min-height:38px;font-size:12px}.car-card{grid-template-columns:100px minmax(0,1fr);grid-template-rows:14px 22px minmax(20px,1fr) 38px;gap:3px 8px;padding:8px}.car-photo{grid-column:1;grid-row:1/4}.model-meta,.car-info,.car-description{grid-column:2}.car-bottom{grid-column:1/-1}.car-description{font-size:11px;line-height:14px}.car-info h2{font-size:16px}.car-bottom button{min-height:36px;padding:5px 10px;font-size:12px}.car-price{font-size:13px}.game-menu{grid-template-rows:38px minmax(0,1fr);gap:8px;padding:5px 0}.game-menu .eyebrow{display:none}.game-menu h1{font-size:24px;margin:5px 0}.game-choices{grid-template-columns:repeat(5,minmax(0,1fr));grid-template-rows:1fr;gap:7px;padding:0}.game-choices button:last-child{grid-column:auto}.game-choices button{padding:10px 5px;gap:7px;border-radius:17px}.game-choices strong{font-size:13px}.game-choices button>span:last-child{font-size:11px}.welcome-view{grid-template-columns:1fr 1fr;grid-template-rows:1fr;gap:20px;padding:8px 20px}.welcome-view h1{font-size:30px;margin:9px 0}.welcome-view p{font-size:12px}.welcome-actions{margin-top:12px;gap:7px}.welcome-actions button{font-size:12px;padding:9px 13px}.welcome-copy .text-button{min-height:30px;font-size:12px;padding:4px 0}.welcome-note{font-size:10px}.welcome-art{height:100%;min-height:0;aspect-ratio:auto;padding:12px}.welcome-art .welcome-label,.welcome-art .welcome-features{display:none}.welcome-art #welcome-car{min-height:0;margin:5px 0}.welcome-model{font-size:11px}.city-view{grid-template-columns:1fr;grid-template-rows:42px minmax(0,1fr);gap:8px;padding:6px 0}.city-heading .eyebrow{display:none}.city-heading h1{font-size:23px;margin:0 0 5px}.city-heading p{font-size:11px}.city-grid{gap:8px}.city-card{padding:12px}.city-card p{font-size:11px;line-height:1.3;margin:7px 0 10px}.city-card .city-icon{display:none}.city-card h2{font-size:16px;margin:3px 0}.city-card button{min-height:38px;font-size:12px;padding:7px 10px}.city-ledger{display:none}}
.vehicle-picker{display:flex;align-items:center;justify-content:center;gap:14px;margin:0 0 15px}.vehicle-picker canvas{width:140px;height:94px;object-fit:contain}.vehicle-picker label{display:grid;gap:6px;text-align:left;font-size:13px;color:#6f7b89}.vehicle-picker select{font-size:16px;min-height:44px;width:195px;max-width:100%}.offline-page{grid-template-columns:1fr!important;grid-template-rows:1fr!important}.offline-page main{grid-column:1;grid-row:1}.offline-page .primary{min-height:44px}#body-select{font-size:16px}
@media(max-width:700px){.vehicle-picker{gap:8px;margin-bottom:12px}.vehicle-picker canvas{width:95px;height:64px}.vehicle-picker select{width:170px;font-size:16px}.vehicle-picker label{font-size:12px}.game-overlay:has(.vehicle-picker:not([hidden])) p{margin-bottom:10px}}
@media(max-width:700px) and (max-height:650px){.tap-view{padding-top:9px;grid-template-rows:auto minmax(0,1fr) 50px}.intro-stats{display:none}.intro h1{font-size:29px;margin:9px 0 6px}.intro p{font-size:12px}.coin-stage{padding-bottom:35px}#coin{width:clamp(94px,22vh,148px);height:clamp(94px,22vh,148px)}.coin-symbol{font-size:57px}.coin-top{font-size:5px;letter-spacing:1px}.coin-bottom{font-size:6px}.orbit-one{width:150px;height:150px;top:calc(50% - 93px)}.orbit-two{width:190px;height:190px;top:calc(50% - 113px)}.tap-caption{top:calc(50% + 43px)}.tap-caption strong{font-size:15px}.tap-caption span{font-size:10px}.next-car{height:50px}.vehicle-picker canvas{width:80px;height:54px}.vehicle-picker{margin-bottom:8px}.vehicle-picker select{min-height:40px}.game-overlay:has(.vehicle-picker:not([hidden])) h2{font-size:21px}.game-overlay:has(.vehicle-picker:not([hidden])) p{font-size:12px}}
@media(orientation:landscape) and (max-height:500px){.vehicle-picker canvas{width:75px;height:50px}.vehicle-picker{gap:12px;margin-bottom:7px}.vehicle-picker label{font-size:11px}.vehicle-picker select{width:165px;font-size:15px;min-height:36px}.game-overlay:has(.vehicle-picker:not([hidden])) p{display:none}.game-overlay:has(.vehicle-picker:not([hidden])) h2{font-size:20px;margin:3px 0 7px}}
@media(orientation:landscape) and (max-height:375px){.garage-view{grid-template-rows:44px minmax(0,1fr) 40px}.garage-heading{display:none}.compact-cards .car-card{grid-template-columns:85px minmax(0,1fr);grid-template-rows:12px 20px minmax(15px,1fr) 36px;gap:2px 7px;padding:6px}.compact-cards .car-description{font-size:11px;line-height:14px}.compact-cards .car-info h2{font-size:15px}.compact-cards .car-bottom button{min-height:36px}.game-overlay{overflow:auto}}
@media(max-height:300px){.garage-view{overflow:auto;grid-template-rows:44px minmax(120px,1fr) 40px;overscroll-behavior:contain}}
#close-dialog{width:44px;height:44px;min-height:44px}#close-dialog svg{width:22px;height:22px}
@media(max-width:700px){.garage-tools select,#drive-vehicle{font-size:16px!important}.code-display,.profile-code .code-display{font-size:16px;letter-spacing:0}}
@media(orientation:landscape) and (max-height:500px){#drive-vehicle{font-size:16px!important}#touch-controls button,.game-overlay .primary{min-height:44px}}
.play-heading>div:first-child{min-width:0}.play-heading h1{max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* v6: visible viewport, bottom dock and independent thumb controls. */
body{inset:auto 0 auto 0;top:var(--app-top,0px);height:var(--app-height,100dvh)}
@media(min-width:701px) and (min-height:501px){#navigation{width:min(100%,960px)}}
#navigation{align-self:end;margin:0 auto 0;flex-shrink:0}
button,button *,#canvas,#touch-controls,#touch-controls *{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}
#canvas,#touch-controls,#touch-controls *{touch-action:none}
input,textarea{-webkit-user-select:text;user-select:text;-webkit-touch-callout:default}
#touch-controls{width:min(100%,500px);min-width:0;display:block}
.steering-pad,.pedal-pad{display:flex;gap:12px}.wide-pad,.direction-pad{display:flex;width:100%;justify-content:space-between;gap:12px}
#touch-controls[data-mode="parking"]{display:flex;justify-content:space-between;gap:24px}
.play-footer #touch-controls .game-control{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-width:64px;min-height:64px;padding:8px;border:1px solid #dce2ea;border-radius:20px;background:linear-gradient(#fff,#f5f7fb);color:#34465c;box-shadow:0 3px 0 #dce2e9,0 4px 12px #1e345108;font-size:11px;line-height:1;transition:background .1s,box-shadow .1s,transform .1s}
.game-control svg{display:block;width:26px;height:26px;fill:none;stroke:currentColor;stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.play-footer #touch-controls .game-control:active,.play-footer #touch-controls .game-control.is-pressed{background:#e4efff;color:#0067ce;box-shadow:0 1px 0 #c5d8f1;transform:translateY(2px)}

.play-view{grid-template-rows:80px minmax(0,1fr) 82px}
.city-card{min-width:0}.city-card h2{overflow-wrap:anywhere}
@media(max-width:700px){
 body{grid-template-rows:58px minmax(0,1fr) 68px;padding-bottom:max(4px,env(safe-area-inset-bottom,0px))}
 #navigation{align-self:end;border-radius:22px;padding:4px}#navigation button{min-height:52px}
 .play-view{grid-template-rows:82px minmax(0,1fr) 86px;gap:8px;padding-top:6px}
 .play-footer{position:relative;flex-wrap:nowrap;justify-content:space-between;gap:8px;padding:4px 2px 7px;align-items:center}
 .play-footer #touch-controls .game-control{width:64px;min-width:58px;min-height:66px;border-radius:19px;font-size:10px;padding:8px 5px}
 #touch-controls[data-mode="banana"]{flex:1;width:auto}.play-footer #bank-out{width:92px;min-height:58px;border-radius:17px;line-height:1.25;font-size:12px;padding:8px}
 .city-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.city-card{padding:15px}.city-card:last-child{grid-column:1/-1;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px 14px;align-items:center}.city-card:last-child .city-icon{display:none}.city-card:last-child h2,.city-card:last-child p{grid-column:1;margin:0}.city-card:last-child button{grid-column:2;grid-row:1/3}.city-card h2{font-size:17px}.city-card p{font-size:13px;line-height:1.45}.city-card button{font-size:13px}.city-ledger{min-height:0;overflow:auto;overscroll-behavior:contain}.city-view{gap:12px}.city-heading h1{font-size:28px}.city-heading p{line-height:1.45;margin:8px 0 0}
}
@media(max-width:380px){.steering-pad,.pedal-pad{gap:8px}#touch-controls[data-mode="parking"]{gap:16px}.play-footer #touch-controls .game-control{width:58px;min-width:54px}.city-card{padding:12px}.city-heading h1{font-size:25px}}
@media(max-width:700px) and (max-height:650px){body{grid-template-rows:50px minmax(0,1fr) 63px}.play-view{grid-template-rows:70px minmax(0,1fr) 76px;gap:5px}.play-footer #touch-controls .game-control{min-height:60px}.city-grid{gap:7px}.city-card{padding:10px}.city-card p{display:none}.city-card:last-child button{grid-row:1}.city-card:last-child h2{font-size:15px}.city-icon{display:none}}
@media(orientation:landscape) and (max-height:500px){body{grid-template-rows:46px minmax(0,1fr);padding-bottom:max(4px,env(safe-area-inset-bottom,0px))}#navigation{margin:0;align-self:stretch}.play-view{grid-template-rows:42px minmax(0,1fr) 68px;gap:4px}.play-footer{padding:0 4px 5px}.play-footer #touch-controls .game-control{min-height:55px;min-width:64px;padding:5px;border-radius:15px}.game-control svg{width:22px;height:22px}.city-view{grid-template-rows:auto minmax(0,1fr)}.city-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.city-card:last-child{grid-column:auto;display:flex}.city-card p{display:none}.city-ledger{display:none}.city-heading h1{font-size:22px}.city-heading p{font-size:11px;margin:4px 0}.city-heading .eyebrow{display:none}}

.vehicle-picker canvas{width:140px;height:94px;object-fit:contain;flex-shrink:0}
@media(max-width:700px){.vehicle-picker canvas{width:95px;height:64px}}
/* Drive: steering with one thumb, an independent brake under the other. */
#touch-controls[data-mode="drive"]{display:flex;justify-content:space-between;gap:24px}
.play-footer #touch-controls .control-brake{min-width:88px;color:#a93f40;background:linear-gradient(#fff4f2,#f8e6e4);border-color:#edd2cf}
.play-footer #touch-controls .control-brake.is-pressed,.play-footer #touch-controls .control-brake:active{background:#f0cbc6;color:#8b282a;box-shadow:0 1px 0 #e0b5ae}
@media(max-width:380px){#touch-controls[data-mode="drive"]{gap:16px}.play-footer #touch-controls .control-brake{min-width:80px}}

/* v8: show the entire catalogue photograph; landscape 4:3, constrained by the screen. */
.car-photo{position:relative;aspect-ratio:4/3;width:100%;height:auto;max-height:100%;align-self:center;justify-self:center;display:block;background:#eef0f3}
.car-photo img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;object-position:center;display:block}
.detail-photo{position:relative;aspect-ratio:4/3;height:auto;background:#eef0f3}
.detail-photo img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;object-position:center;display:block}

/* v9: selection is disabled throughout the game, not only on buttons. */
html,body,body *{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}
input,textarea,[contenteditable="true"],.code-display{-webkit-user-select:text!important;user-select:text!important;-webkit-touch-callout:default}
.life-hud{pointer-events:none}
@supports(height:100dvh){body{height:100dvh;top:0}html[data-keyboard="open"] body{height:var(--vv-height,100dvh);top:var(--vv-top,0px)}}
.play-footer #touch-controls .control-up{background:linear-gradient(#fff,#f5f7fb);border-color:#dce2ea;color:#34465c}
.play-footer #touch-controls .game-control:active:not(.is-pressed){background:linear-gradient(#fff,#f5f7fb);color:#34465c;box-shadow:0 3px 0 #dce2e9;transform:none}
.play-footer #touch-controls .game-control.is-pressed{background:#e4efff;color:#0067ce;box-shadow:0 1px 0 #c5d8f1;transform:translateY(2px)}
.parking-picker{width:min(100%,340px);margin:0 0 12px}.parking-picker label{display:grid;gap:6px;font-size:13px;color:#6f7b89}.parking-picker select{font-size:16px;min-height:44px;width:100%;padding:10px 12px;border:1px solid #dbe1e9;border-radius:12px;background:#fff;color:#283444}.parking-picker p{font-size:13px;margin:8px 0!important;line-height:1.4}#parking-next{margin-top:10px;min-height:44px}
.tap-view>.intro-stats{grid-column:1;position:static;margin:0;align-self:start}.tap-view>.coin-stage{grid-column:2;grid-row:1/3}
@media(max-width:700px) and (orientation:portrait){
 .tap-view{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto 54px;align-items:stretch;gap:10px;padding:14px 0 0;text-align:center}
 .tap-view .intro{grid-row:1}.intro h1{font-size:clamp(29px,4.4dvh,40px);line-height:1.05;letter-spacing:-1.3px;margin:12px 0}.intro p{font-size:14px;line-height:1.45;margin:0}.intro .eyebrow{font-size:10px;letter-spacing:1px}
 .tap-view>.coin-stage{grid-column:1;grid-row:2;min-height:0;max-height:none;padding:0;gap:14px;justify-content:center;overflow:hidden}
 #coin{flex-shrink:0;width:clamp(106px,23dvh,205px);height:clamp(106px,23dvh,205px)}.coin-symbol{font-size:clamp(64px,12dvh,112px)}.coin-top{font-size:6px}.coin-bottom{font-size:8px}
 .tap-caption{position:static;gap:4px;z-index:1}.tap-caption strong{font-size:20px}.tap-caption span{font-size:11px}
 .orbit-one,.orbit-two{width:clamp(150px,29dvh,265px);height:clamp(150px,29dvh,265px);top:calc(50% - 22px);left:50%;transform:translate(-50%,-50%);pointer-events:none}.orbit-two{width:clamp(175px,34dvh,305px);height:clamp(175px,34dvh,305px)}
 .tap-view>.intro-stats{grid-column:1;grid-row:3;position:static;display:flex;margin:0;padding:5px 0;justify-content:center;gap:30px}.intro-stats strong{font-size:20px}.intro-stats span{font-size:11px}
 .next-car{grid-row:4;position:static;height:54px;min-height:44px;gap:8px;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.7fr);font-size:11px;align-content:center}.next-car strong{font-size:12px;text-align:right}.next-car>span:last-child{grid-column:1/-1;text-align:right;color:#7e8792}
}
@media(orientation:landscape) and (max-height:500px){.tap-view>.intro-stats{position:static;grid-column:1;margin:0}.tap-view>.coin-stage{grid-column:2;grid-row:1/3}.parking-picker{margin:0 0 6px}.parking-picker label{display:flex;align-items:center;gap:9px}.parking-picker p{display:none}#parking-next{margin:5px 0 0;min-height:36px}}

/* v13: the phone dock is anchored to the viewport, independent of grid content. */
@media(max-width:700px) and (orientation:portrait){
 body{inset:0;top:0;height:100%;height:100dvh;grid-template-rows:58px minmax(0,1fr);padding-bottom:0}
 body main{padding-bottom:calc(78px + env(safe-area-inset-bottom,0px))}
 body[data-screen="welcome"]{grid-template-rows:58px minmax(0,1fr)}
 body:has(#welcome:not([hidden])){grid-template-rows:58px minmax(0,1fr)}
 body[data-screen="welcome"] main{padding-bottom:max(8px,env(safe-area-inset-bottom,0px))}
 #navigation{position:fixed;z-index:8;left:max(12px,env(safe-area-inset-left,0px));right:max(12px,env(safe-area-inset-right,0px));bottom:max(6px,env(safe-area-inset-bottom,0px));width:auto;height:64px;margin:0;align-self:auto;box-shadow:0 4px 18px #17243809}
 html[data-keyboard="open"] #navigation{display:none}
 .garage-view{grid-template-rows:48px 48px minmax(0,1fr) 46px}
}
.install-guide-steps{list-style:none;padding:0;margin:20px 0;display:grid;gap:18px}
.install-guide-steps li{border:1px solid #e0e4ec;border-radius:18px;background:#f7f8fb;padding:16px;overflow:hidden}
.install-guide-steps h3{font-size:18px;margin:0 0 8px;letter-spacing:-.4px}
.install-guide-steps p{font-size:15px;margin:0 0 14px;color:#606976}
.install-guide-steps img{display:block;width:100%;height:auto;border-radius:12px;border:1px solid #e3e6eb;background:#fff;object-fit:contain}
.install-important{padding:14px;border-radius:14px;background:#eaf3ff;color:#28577f;font-size:16px!important}
.rental-finance{margin-top:20px;padding:16px;border:1px solid #e1e5ec;border-radius:16px;background:#f8f9fb}
.rental-finance h3{font-size:18px;margin:0 0 14px}.rental-finance dl{margin:0;display:grid;gap:10px}
.rental-finance dl>div{display:flex;gap:12px;justify-content:space-between;font-size:14px}.rental-finance dd{margin:0;white-space:nowrap;font-variant-numeric:tabular-nums}
.rental-finance .finance-total{border-top:1px solid #dbe1e8;padding-top:12px;font-weight:600;font-size:16px}
.rental-finance p{font-size:14px!important;color:#667181;line-height:1.5!important}.fleet-actions{display:grid;gap:10px;margin-top:20px}.fleet-actions button{min-height:48px;font-size:15px;white-space:normal}

/* v16: swipe collection and direct snake gestures. */
#car-grid{touch-action:pan-y;overscroll-behavior-x:contain}
#car-grid img{-webkit-user-drag:none;user-select:none}
#car-grid:focus-visible{outline:2px solid #9fc5ef;outline-offset:3px;border-radius:18px}
.garage-bottom .pager{width:100%;justify-content:space-between;gap:12px;padding:0 6px}
.swipe-hint{font-size:13px;color:#7c8795}
#page{font-variant-numeric:tabular-nums;font-size:14px;white-space:nowrap}
body[data-screen="snake"] .play-footer{display:none}
body[data-screen="snake"] .play-view{grid-template-rows:min-content minmax(0,1fr) 0}
body[data-screen="snake"] #canvas{touch-action:none;cursor:crosshair}
