@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Playfair+Display:ital,wght@0,600;0,700;1,600&display=swap');
:root{color-scheme:dark;--ink:#eceff3;--muted:#a4acb8;--cream:#090b0f;--orange:#e5b46d;--line:#303640}*{box-sizing:border-box}body{margin:0;background:var(--cream);color:var(--ink);font-family:'DM Sans',sans-serif}button,input{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:wait}header{height:88px;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 6%;gap:35px}.brand{font-weight:700;letter-spacing:2px;text-decoration:none;color:var(--ink);display:flex;align-items:center;gap:13px}.brand-icon{display:grid;place-items:center;background:var(--ink);color:var(--cream);width:38px;height:42px;border-radius:7px;font-size:28px}.tagline,.live{font-size:10px;letter-spacing:2px}.live{margin-left:auto}.live i{display:inline-block;width:6px;height:6px;background:#669a56;border-radius:50%;margin-right:8px}main{max-width:1320px;margin:auto;padding:0 6%}.intro{display:flex;justify-content:space-between;align-items:center;padding:55px 0 40px}.eyebrow{font-size:10px;font-weight:700;letter-spacing:2px;color:var(--orange);margin:0 0 15px}h1,h2{font-family:'Playfair Display',Georgia,serif;margin:0;font-weight:600}h1{font-size:clamp(38px,4.5vw,62px);line-height:1.12;letter-spacing:-1.8px}h1 em{color:var(--orange)}.sub{font-size:14px;line-height:1.7;color:var(--muted);margin-top:21px}.intro-mark{border:1px solid #303640;border-radius:100%;height:180px;width:180px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:64px;transform:rotate(9deg);background:#151a22}.intro-mark span{font-size:9px;letter-spacing:2px;text-align:center;line-height:1.7}.setup{display:grid;grid-template-columns:1fr 1fr;border:1px solid var(--line);background:#14181f;border-radius:12px;overflow:hidden}.setup>div{padding:32px 38px}.setup>div+div{border-left:1px solid var(--line)}h2{font-size:28px}label{display:block;font-size:11px;font-weight:700;margin:23px 0 10px}input{width:100%;border:1px solid var(--line);background:var(--cream);padding:13px 15px;border-radius:5px;color:var(--ink);outline:none}input:focus{border-color:var(--ink)}.avatars{display:grid;grid-template-columns:repeat(6,1fr);gap:7px}.avatars button{height:45px;font-size:25px;border:1px solid var(--line);border-radius:6px;background:var(--cream)}.avatars .selected,.lengths .selected{border-color:var(--ink);background:#283344;box-shadow:inset 0 0 0 1px var(--ink)}.lengths{display:flex;gap:8px;margin-bottom:20px}.lengths button{flex:1;background:var(--cream);border:1px solid var(--line);border-radius:6px;padding:15px 5px;font-size:12px;font-weight:700;color:var(--ink)}.lengths span{display:block;font-size:10px;color:var(--muted);font-weight:400;margin-top:5px}.primary{background:#d6ad71;color:#101216;border:0;border-radius:5px;padding:15px 21px;font-weight:600;font-size:13px}.setup .primary{width:100%;display:flex;justify-content:space-between}.secondary{width:100%;padding:11px;border:none;background:none;color:var(--muted);font-size:11px}.join{display:flex;border-top:1px solid var(--line);padding-top:15px;gap:10px}.join input{width:50%;font-size:11px;letter-spacing:2px}.join button{flex:1;background:none;border:1px solid var(--line);border-radius:5px;color:var(--ink);font-size:12px}.paytable{display:grid;grid-template-columns:1fr 1.6fr;gap:35px;padding:38px 0}.paytable h2{font-size:24px}.paytable p:not(.eyebrow){font-size:11px;line-height:1.8;color:var(--muted)}.scores{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.score{border-bottom:1px solid var(--line);padding:7px 0 13px;font-size:11px}.score strong{display:block;font-size:19px;margin-top:6px}.score strong span{font-size:9px;font-weight:400;color:var(--muted)}footer{border-top:1px solid var(--line);padding:22px 0 30px;display:flex;justify-content:space-between;font-size:9px;color:var(--muted);letter-spacing:1px}.error{color:#ff9a8b;font-size:13px}.race-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:22px}.room-box{text-align:right}.room-box span{font-size:9px;display:block;letter-spacing:1px;color:var(--muted)}.room-box button{background:none;border:0;color:var(--ink);font-weight:700;letter-spacing:3px;font-size:20px;margin-top:8px}.track-shell{background:#12161d;padding:20px;border-radius:12px;border:1px solid #303640}.track-top{display:flex;justify-content:space-between;font-size:9px;letter-spacing:1.2px;font-weight:700;margin-bottom:12px}.track{background:#1b212a;border:3px solid #363f4b;border-radius:12px;overflow:hidden;max-height:550px;overflow-y:auto}.lane{position:relative;height:21px;border-bottom:1px dashed #39414e;background-image:linear-gradient(90deg,transparent calc(100% - 1px),#ffffff25 0);background-size:var(--step) 100%;margin:0 40px 0 24px}.lane:last-child{border-bottom:0}.lane:after{content:'';position:absolute;right:-19px;width:15px;top:0;bottom:0;background:repeating-conic-gradient(#d1d5db 0% 25%,#313947 0% 50%) 0/12px 12px}.racer{position:absolute;left:var(--position);top:1px;transform:translateX(-50%);width:18px;height:18px;background:#232b37;border:1px solid #536071;border-radius:50%;font-size:12px;padding:0;line-height:1;display:grid;place-items:center;transition:left 1.4s ease;z-index:1}.racer.me{border-color:var(--ink);box-shadow:0 0 0 1px #e5b46d35}.racer:focus{outline:3px solid var(--ink)}.lane-label{position:absolute;left:10px;top:5px;color:#adb6c5;font-size:9px;opacity:.65;pointer-events:none}.racer:hover:after,.racer:focus:after{content:attr(data-name);position:absolute;background:#080b10;color:var(--ink);padding:6px 10px;white-space:nowrap;border-radius:4px;font-size:11px;bottom:20px;z-index:5}.race-actions{display:flex;justify-content:space-between;align-items:center;margin:17px 0}.race-actions p{font-size:12px;color:var(--muted)}.hand-panel{background:#14181f;border:1px solid var(--line);padding:27px 35px;border-radius:12px}.hand-heading{display:flex;justify-content:space-between}.hand-heading h2{font-size:25px}.hand-heading p:not(.eyebrow){color:var(--muted);font-size:11px}.timer{text-align:center}.timer strong{font-size:36px;font-weight:500}.timer span{display:block;font-size:8px;letter-spacing:1px;color:var(--muted)}.cards{display:flex;gap:15px;justify-content:center;padding:20px 0 25px}.card{position:relative;width:104px;height:143px;border:1px solid #424b59;background:#20262f;border-radius:8px;box-shadow:0 3px 6px #00000040;display:flex;flex-direction:column;align-items:center;justify-content:center;color:var(--ink);transition:transform .15s,border .15s}.card.red{color:#ff868c}.card .corner{position:absolute;left:10px;top:8px;font-size:18px;font-weight:700}.card .suit{font-size:42px}.card .rank{font-size:22px;font-family:Georgia,serif}.card.held{transform:none}.card .hold{position:absolute;bottom:-19px;color:var(--ink);font-size:9px;letter-spacing:1.5px;font-weight:700}.timer-bar{height:3px;background:#303640;margin-top:10px}.timer-bar i{display:block;height:100%;background:var(--orange);transition:width .1s linear}.saved{text-align:center;font-size:10px;color:var(--muted);min-height:13px;margin-bottom:0}[hidden]{display:none!important}@media(max-width:700px){header{padding:0 5%;height:70px}.tagline,.intro-mark{display:none}.live{font-size:8px}main{padding:0 5%}.intro{padding:35px 0 24px}h1{font-size:40px}.setup{grid-template-columns:1fr}.setup>div{padding:25px}.setup>div+div{border-left:0;border-top:1px solid var(--line)}.paytable{grid-template-columns:1fr;gap:12px}.scores{grid-template-columns:repeat(4,1fr)}.score{font-size:9px}.cards{gap:8px}.card{width:18%;height:115px}.card .corner{font-size:15px;left:6px}.card .suit{font-size:31px}.hand-panel{padding:22px 15px}.hand-heading h2{font-size:22px}.hand-heading p:not(.eyebrow){max-width:220px;line-height:1.6}.track-shell{padding:12px}.track-top{font-size:7px;letter-spacing:0}.room-box span{font-size:7px}.race-heading h2{font-size:24px}footer{gap:20px;line-height:1.7}.wide{display:none}}

.draw-actions{text-align:center;margin:6px 0 20px}

.lobby-button{border:1px solid var(--line);background:transparent;color:var(--ink);padding:9px 14px;border-radius:6px;margin-left:auto;font-size:12px}header:has(.lobby-button:not([hidden])) .live{margin-left:0}
.card{perspective:800px;padding:0;background:transparent!important;border:0!important;box-shadow:none;overflow:visible}.card-inner{width:100%;height:100%;position:relative;transform-style:preserve-3d;transition:transform .35s ease;transform:rotateY(180deg)}.card.revealed .card-inner{transform:rotateY(0)}.card-face,.card-back{position:absolute;inset:0;border:1px solid #424b59;border-radius:8px;backface-visibility:hidden;box-shadow:0 3px 6px #00000040}.card-face{background:#ffffff;display:flex;flex-direction:column;align-items:center;justify-content:center}.card-back{transform:rotateY(180deg);background:repeating-linear-gradient(45deg,#941c32 0 5px,#b32943 5px 7px);border:5px solid #14181f;display:grid;place-items:center;color:#e9d7ac;font-size:42px}.card-back:after{content:'♠';border:1px solid #e9d7ac88;width:70%;height:75%;display:grid;place-items:center;border-radius:5px}.card.held .card-face{border:1px solid #cfd3d9;background:#ffffff}.card .hold{bottom:-19px}.outcome{position:relative;width:min(480px,100%);margin:18px auto 6px;padding:22px;background:#14181f;border:1px solid #505c70;border-radius:14px;box-shadow:0 15px 65px #00000080;z-index:30;animation:outcome-in .3s ease}.outcome h2{font-size:30px}.outcome p:not(.eyebrow){font-size:14px;line-height:1.6;margin-bottom:0}.outcome>button{position:absolute;right:12px;top:8px;border:0;background:none;font-size:25px;color:var(--muted)}#outcomeAvatar{display:block;font-size:34px;margin-top:10px}.racer.moving{transition:left 1.8s ease-in-out;box-shadow:0 0 0 2px #e5b46d44}.racer.moving:before{content:'💨';position:absolute;right:13px;font-size:12px}@keyframes outcome-in{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:translateY(0)}}@media(max-width:700px){header{gap:12px}.brand{font-size:12px;letter-spacing:1px}header:has(.lobby-button:not([hidden])) .live{display:none}.outcome{margin:16px auto 6px}}

.card:disabled{opacity:1;cursor:default}.card .hold{font-size:11px;bottom:-21px;line-height:16px;min-height:16px}.card.held{transform:none}

.card-stage{position:relative;isolation:isolate}
.card-stage .outcome{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:min(480px,100%);margin:0;padding:18px 22px;background:rgba(15,19,26,.76);border:1px solid rgba(203,213,225,.35);box-shadow:0 8px 28px rgba(0,0,0,.4);animation:overlay-in .3s ease}
.card-stage .outcome h2{font-size:26px}.card-stage .outcome .eyebrow{margin-bottom:8px}.card-stage #outcomeAvatar{position:absolute;right:24px;bottom:15px;font-size:26px;margin:0}.card-stage .outcome p:not(.eyebrow){padding-right:35px;margin-top:8px;font-weight:500}
@keyframes overlay-in{from{opacity:0;transform:translate(-50%,-45%)}to{opacity:1;transform:translate(-50%,-50%)}}
@media(max-width:700px){.card-stage .outcome{padding:14px 18px}.card-stage .outcome h2{font-size:23px}.card-stage .outcome p:not(.eyebrow){font-size:12px}.card-stage .outcome .eyebrow{font-size:8px}}

input::placeholder{color:#939dab}.racer.me{border-color:var(--orange)}.card-back{color:#e5b46d}.card-back:after{border-color:#e5b46d88}.track-shell{padding:14px}.live i{background:#8cc9a0}

.card{color:#14181f}.card.red{color:#bc2f3c}.card-face{border-color:#cfd3d9}.card-back{border-color:#ffffff}

.lane.your-lane{background-color:rgba(229,180,109,.12)}.your-lane .lane-label{color:#ffe0a3;font-weight:700;opacity:1}.racer.me{background:#e5b46d;border:2px solid #fff0c8;box-shadow:0 0 0 2px #e5b46d55,0 0 9px #e5b46d99;z-index:3}.racer.me.moving{box-shadow:0 0 0 2px #e5b46d55,0 0 9px #e5b46d99}.card-back{color:#fff5ee}.card-back:after{border-color:#fff5ee99}

/* Reserve each region so revealing cards, hiding Draw, and changing messages never resize the panel. */
.hand-panel{display:grid;grid-template-rows:136px 188px 72px 3px 28px;gap:0}
.hand-heading{height:136px;min-height:0;gap:16px}.hand-heading>div:first-child{flex:1;min-width:0}.hand-heading .eyebrow{line-height:14px;margin:0 0 8px}.hand-heading h2{height:60px;line-height:30px;overflow:hidden}.hand-heading p:not(.eyebrow){height:40px;line-height:20px;margin:8px 0 0;overflow:hidden}
.timer{flex:0 0 88px}.timer strong{display:block;height:46px;line-height:46px}.timer span{height:24px;line-height:12px}
.card-stage{height:188px;min-height:0}.cards{height:188px;margin:0}.draw-actions{height:72px;margin:0;display:flex;align-items:center;justify-content:center}.timer-bar{height:3px;margin:0}.saved{height:28px;line-height:14px;margin:10px 0 0;overflow:hidden}
.race-actions{min-height:48px}
@media(max-width:700px){.hand-panel{grid-template-rows:156px 160px 72px 3px 36px}.hand-heading{height:156px;gap:10px}.hand-heading h2{height:56px;line-height:28px}.hand-heading p:not(.eyebrow){height:66px;line-height:22px;max-width:none}.timer{flex-basis:72px}.card-stage,.cards{height:160px}.saved{height:36px}}

.sound-button{background:transparent;border:1px solid var(--line);color:var(--muted);border-radius:6px;padding:9px 12px;font-size:11px;margin-left:auto}.sound-button+.lobby-button{margin-left:0}
.card-stage .outcome.look-up{background:rgba(15,19,26,.76);border-color:#e5b46d;box-shadow:0 0 25px #e5b46d22}.outcome.look-up h2{color:#ffe0a3;animation:look-up-bounce .85s ease-in-out infinite}
@keyframes look-up-bounce{0%,100%{transform:translateY(0) rotate(-1deg)}50%{transform:translateY(-4px) rotate(1deg)}}
.pause-overlay{position:fixed;inset:0;background:#000b;z-index:100;display:grid;place-items:center;padding:20px}.pause-dialog{width:min(460px,100%);padding:32px;background:#151a22;border:1px solid #e5b46d;border-radius:14px;box-shadow:0 20px 80px #0009}.pause-dialog h2{font-size:29px;line-height:1.3}.pause-dialog>p:not(.eyebrow){font-size:13px;line-height:1.6;color:var(--muted)}.pause-buttons{display:flex;gap:12px;justify-content:center;margin-top:25px}.pause-buttons .lobby-button{margin-left:0}.pause-dialog #pauseCountdown{font-variant-numeric:tabular-nums}
@media(prefers-reduced-motion:reduce){.outcome.look-up h2{animation:none}}
@media(max-width:700px){.sound-button{font-size:9px;padding:8px}header{gap:8px}.tagline{display:none}}

.hand-panel{min-width:0;grid-template-columns:minmax(0,1fr)}.card-stage{min-width:0}.card-inner{min-width:0}
@media(max-width:700px){
 .cards{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:clamp(3px,1.4vw,8px);width:100%;min-width:0;align-items:start}
 .cards .card{width:100%;min-width:0;max-width:none;height:clamp(84px,25vw,115px);touch-action:manipulation}
 .cards .card .corner{font-size:clamp(11px,3.2vw,15px);left:5px;top:6px;line-height:1.1}
 .cards .card .suit{font-size:clamp(23px,6.5vw,31px)}.cards .card .rank{font-size:clamp(17px,4.5vw,22px)}
 .cards .card .hold{font-size:9px;letter-spacing:.7px;white-space:nowrap}.cards .card-back{border-width:3px;font-size:30px}
 .hand-panel{padding-left:12px;padding-right:12px}.hand-heading>div:first-child{overflow-wrap:anywhere}
 .race-heading{gap:12px}.race-heading>div:first-child{min-width:0}.race-heading h2{font-size:clamp(19px,5vw,24px)}.room-box{flex-shrink:0}.live{display:none}
}
@media(max-width:380px){header{padding-left:3%;padding-right:3%}.brand{font-size:10px;gap:7px}.brand-icon{width:28px;height:34px;font-size:24px}.lobby-button{font-size:10px;padding:8px 9px}main{padding-left:3%;padding-right:3%}}

.guide-actions{display:flex;justify-content:flex-end;margin:-10px 0 12px}.guide-actions .lobby-button{margin:0}.guide-dialog{width:min(620px,calc(100% - 32px));max-height:calc(100dvh - 48px);overflow:auto;padding:32px;background:#151a22;color:var(--ink);border:1px solid #657087;border-radius:14px;box-shadow:0 20px 80px #0009}.guide-dialog::backdrop{background:#000b}.guide-dialog>p:not(.eyebrow){font-size:13px;line-height:1.7;color:var(--muted)}.guide-dialog .scores{margin:24px 0}.guide-close{position:absolute;right:12px;top:8px;border:0;background:none;color:var(--ink);font-size:28px;cursor:pointer}#start{font-variant-numeric:tabular-nums;white-space:nowrap}
@media(max-width:700px){.guide-dialog{padding:25px 20px}.race-actions{gap:12px;flex-wrap:wrap}.race-actions #start{margin-left:auto}.guide-dialog .scores{grid-template-columns:repeat(2,minmax(0,1fr))}}

#start{width:240px;min-width:240px;max-width:240px;height:48px;flex:0 0 240px;text-align:center;font-variant-numeric:tabular-nums}

.racer.winner,.racer.me.winner{background:#ffe29a;border-color:#fff9dc;box-shadow:0 0 0 2px #ffd16b80,0 0 14px #ffd16bcc;z-index:5}.racer.winner-flashing{animation:finish-flash .5s ease-in-out infinite}@keyframes finish-flash{0%,100%{filter:brightness(1);box-shadow:0 0 0 2px #ffd16b80,0 0 9px #ffd16b99}50%{filter:brightness(1.7);box-shadow:0 0 0 4px #fff3b1bb,0 0 22px #ffd16b}}
.finish-overlay{position:fixed;inset:0;z-index:110;background:#000c;display:grid;place-items:center;padding:20px}.finish-dialog{width:min(520px,100%);height:min(560px,calc(100dvh - 40px));padding:28px;border:1px solid #d6ad71;border-radius:16px;background:#151a22;box-shadow:0 20px 80px #0009;display:grid;grid-template-rows:106px 48px minmax(0,1fr) 62px;gap:12px;text-align:center}.finish-icon{font-size:46px;line-height:58px;display:block}.finish-heading h2{font-size:30px;line-height:40px;margin:0}.finish-dialog>p{margin:0;font-size:13px;line-height:22px;color:var(--muted)}.finish-winners{overflow:auto;min-height:0}.finish-winners .eyebrow{margin:8px 0 12px}.winner-row{display:flex;align-items:center;justify-content:center;gap:12px;min-height:36px;font-size:15px}.winner-avatar{font-size:27px}.finish-countdown{border-top:1px solid var(--line);display:flex;align-items:center;justify-content:center;gap:14px;font-size:13px}.finish-countdown strong{display:inline-block;width:70px;min-width:70px;font-size:25px;font-variant-numeric:tabular-nums;line-height:36px}
@media(max-width:700px){.finish-dialog{padding:22px 18px;grid-template-rows:106px 54px minmax(0,1fr) 62px;gap:10px}.finish-heading h2{font-size:27px}}

.race-actions:has(> #raceStatus[hidden]):has(> #start[hidden]):has(> #restart[hidden]){height:0;min-height:0;margin:6px 0;padding:0}

select{width:100%;font:inherit;padding:12px;border:1px solid var(--line);border-radius:5px;background:#090b0f;color:var(--ink);margin-bottom:14px}.public-races{margin:28px 0;padding:26px;border:1px solid var(--line);background:#14181f;border-radius:12px}.public-heading{display:flex;align-items:center;justify-content:space-between;gap:15px}.public-heading .lobby-button{margin:0}.public-hint{font-size:12px;line-height:1.7;color:var(--muted)}.race-list{display:grid;gap:10px}.public-race-row{display:flex;justify-content:space-between;align-items:center;gap:15px;padding:15px;background:#0d1117;border:1px solid var(--line);border-radius:7px}.public-race-row>div{min-width:0}.public-race-row strong{display:block;font-size:14px;overflow-wrap:anywhere}.public-race-row span{display:block;color:var(--muted);font-size:11px;margin-top:6px;line-height:1.6}.public-race-row .primary{white-space:nowrap;padding:12px 15px}.public-races .saved{height:auto;overflow:visible;margin-top:14px}@media(max-width:700px){.public-races{padding:20px 15px}.public-race-row{padding:12px;gap:10px}.public-race-row .primary{font-size:11px;padding:11px}.public-heading h2{font-size:24px}}

.lobby-intro{padding:30px 0 22px;gap:15px}.lobby-intro .lobby-button{margin:0;white-space:nowrap}.rules-dialog h2{font-size:32px;line-height:1.25}.rules-dialog .rules-step{color:var(--ink);font-weight:600;margin-top:23px}.rules-dialog .rules-finish{color:var(--orange);font-family:'Playfair Display',Georgia,serif;font-size:21px;margin-top:24px}.rules-dialog .scores{grid-template-columns:repeat(2,minmax(0,1fr))}.rules-dialog .score{font-size:13px}.rules-dialog .score strong span{font-size:11px}

.finish-icon{font-size:82px;line-height:96px}.finish-dialog{grid-template-rows:142px 100px minmax(0,1fr) 62px}.finish-details{min-height:0;overflow:auto;font-size:14px;line-height:22px;color:var(--muted)}.finish-details>p{margin:0}.tie-heading{color:var(--ink);font-weight:600;margin:9px 0 5px}.tie-row{font-size:14px;line-height:26px;color:var(--ink)}
@media(max-width:700px){.finish-dialog{grid-template-rows:142px 116px minmax(0,1fr) 62px}}

.lane-label,.your-lane .lane-label{color:#ffffff;opacity:1}.racer-hand{position:absolute;left:calc(100% + 5px);top:50%;transform:translateY(-50%);background:#12161de8;color:#fff;padding:2px 5px;border-radius:3px;font:600 9px/12px 'DM Sans',sans-serif;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;pointer-events:none;z-index:4}.racer-hand.hand-left{left:auto;right:calc(100% + 5px)}.racer.me .racer-hand{color:#ffe0a3}

.lobby-join{width:100%;margin-top:12px;justify-content:center!important}.race-browser{width:min(720px,calc(100% - 32px))}.race-browser .public-races{margin:0;padding:5px;border:0;background:transparent}.race-browser .public-heading{padding-right:20px}.private-forms{display:grid;grid-template-columns:1fr 1fr;gap:25px;margin-top:22px}.private-forms h3{font-size:16px}.private-forms .primary{margin-top:18px;width:100%;padding:13px}.private-forms input{font-size:13px}.private-forms label{margin-top:16px}@media(max-width:700px){.private-forms{grid-template-columns:1fr}.private-forms>section+section{border-top:1px solid var(--line);padding-top:12px}}

.current-race-name{font-size:12px;color:var(--muted);margin:8px 0 0}

.private-race-info{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:8px 0 12px;color:#e8edf5}.private-race-info[hidden]{display:none}.private-race-info strong{font-family:monospace;font-size:20px;letter-spacing:3px}.private-race-info [role="status"]{font-size:13px;color:#b6c4d7}

.setup :is(#create,#join,#privateRaces,#browsePrivate){width:100%;height:48px;min-height:48px;max-height:48px;margin:12px 0 0;padding:0 16px;display:flex;align-items:center;justify-content:center;gap:8px;border:1px solid var(--line);border-radius:5px;font-size:13px;font-weight:600;line-height:1.2}.setup #create{margin-top:0}

.room-box #copyRoom{max-width:240px;white-space:normal;overflow-wrap:anywhere}@media(max-width:700px){.room-box #copyRoom{max-width:140px}}

.setup :is(#privateRaces,#browsePrivate){background:#b96f62;color:#101216;border-color:#b96f62}.setup :is(#privateRaces,#browsePrivate):hover{background:#ca8073;border-color:#ca8073}.setup :is(#privateRaces,#browsePrivate):focus-visible{outline:2px solid #f5c9bf;outline-offset:3px}

.private-waiting{width:min(520px,calc(100% - 28px));max-height:90dvh;overflow:auto}.waiting-players{display:grid;gap:8px;max-height:240px;overflow:auto;text-align:left;margin:18px 0}.waiting-player{padding:10px 14px;background:#171d27;border:1px solid var(--line);border-radius:6px;color:white}.waiting-countdown{display:flex;align-items:center;justify-content:center;gap:12px;margin:20px 0}.waiting-countdown strong{display:inline-block;width:5ch;font-variant-numeric:tabular-nums;font-size:24px}.private-waiting #waitingInvite{margin-top:16px;white-space:normal}

.brand{flex-shrink:0}.brand-logo{display:block;width:230px;height:auto}.lobby-logo{display:block;width:min(440px,100%);height:auto;margin-bottom:24px}.lobby-intro>div{min-width:0}.lobby-intro{gap:18px}@media(max-width:700px){.brand-logo{width:170px}.lobby-logo{width:min(340px,100%)}.lobby-intro{align-items:flex-end}.lobby-intro #openRules{flex-shrink:0}}@media(max-width:400px){.brand-logo{width:140px}.lobby-intro{flex-wrap:wrap}.lobby-logo{width:290px;max-width:100%}}

/* Reserve a name column before the starting gate in every race. */
.track-shell{--name-column:120px;--gate-gap:16px}.track-top{position:relative;padding-left:calc(var(--name-column) + var(--gate-gap) + 3px)}.track-top:before{content:'RACERS';position:absolute;left:10px;color:white}.track .lane{margin-left:calc(var(--name-column) + var(--gate-gap));margin-right:28px}.track .lane-label{left:calc(-1 * (var(--name-column) + var(--gate-gap)));top:0;width:var(--name-column);height:100%;display:flex;align-items:center;padding:0 9px;color:#fff;opacity:1;font-size:10px;background:#12161d;border-right:1px solid #46505f;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;pointer-events:auto}.track .your-lane .lane-label{background:#30281e;color:#fff;font-weight:700}.track .lane-label .racer-name{min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}@media(max-width:700px){.track-shell{--name-column:82px;--gate-gap:12px}.track .lane-label{font-size:9px;padding:0 6px}.track-top:before{left:6px}.track .lane{margin-right:22px}}

.finish-dialog{grid-template-rows:142px 100px minmax(60px,1fr) 52px 42px;overflow:auto}.finish-dialog #finishLobby{height:42px;width:100%;margin:0}@media(max-width:700px){.finish-dialog{grid-template-rows:142px 100px minmax(60px,1fr) 48px 42px}}

.public-race-row .public-game-id{color:#e5b46d;font-family:monospace;font-size:12px;letter-spacing:1px}

.computer-choice{display:flex;align-items:center;gap:12px;margin:12px 0 20px}.computer-choice input{width:22px;height:22px;margin:0;padding:0;accent-color:#b96f62;cursor:pointer}.computer-choice label{margin:0;font-size:14px;min-width:25px;cursor:pointer}.computer-choice-hint{color:var(--muted);font-size:12px}

.finish-overlay.is-winner .finish-dialog{grid-template-rows:142px 48px minmax(120px,1fr) 52px 42px}.is-winner #winnerList{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:14px;padding:10px 8px}.is-winner .winner-row{flex-direction:column;gap:8px;min-height:114px}.is-winner .winner-avatar{display:block;font-size:70px;line-height:80px;transform-origin:50% 90%;animation:winner-dance 1.1s ease-in-out infinite}.is-winner .winner-row:nth-child(even) .winner-avatar{animation-delay:-.55s}.is-winner .winner-name{display:block;font-size:16px;line-height:22px;font-weight:700;color:#fff4df;overflow-wrap:anywhere}.is-winner .finish-winners .eyebrow{margin:4px 0 2px}@keyframes winner-dance{0%,100%{transform:translateY(0) rotate(-9deg)}25%{transform:translateY(-7px) rotate(8deg)}50%{transform:translateY(0) rotate(9deg) scale(1.04,.96)}75%{transform:translateY(-7px) rotate(-8deg)}}@media(max-width:700px){.finish-overlay.is-winner .finish-dialog{grid-template-rows:142px 48px minmax(120px,1fr) 48px 42px}}@media(prefers-reduced-motion:reduce){.is-winner .winner-avatar{animation:none}}

.room-box #privateGameTitle{font-size:20px;letter-spacing:0;margin:8px 0 6px;color:#fff4df}.room-box .private-race-info{position:relative;display:flex;flex-wrap:nowrap;justify-content:flex-end;align-items:center;gap:10px;margin:0 0 12px;white-space:nowrap}.room-box .private-pin-label{display:flex;align-items:center;gap:7px;color:#e8edf5;font-size:12px;letter-spacing:0}.room-box .private-pin-label strong{font-size:18px;letter-spacing:2px}.room-box #sharePrivate{font-size:12px;letter-spacing:0;margin:0;padding:8px 10px;border:1px solid var(--line);border-radius:6px}.room-box #shareStatus{position:absolute;top:100%;right:0;max-width:260px;white-space:normal;letter-spacing:0;font-size:10px}@media(max-width:700px){.room-box #privateGameTitle{font-size:17px}.room-box .private-race-info{gap:6px}.room-box #sharePrivate{font-size:11px;padding:7px 8px}}

/* Compact card area, with the progress bar immediately above the cards. */
.hand-panel{padding:18px 20px;grid-template-rows:100px 3px 178px 48px 20px}.hand-heading{height:100px}.hand-heading h2{height:32px;line-height:32px;font-size:24px}.hand-heading p:not(.eyebrow){height:40px;line-height:18px;margin-top:6px}.card-stage,.cards{height:178px}.cards{padding:12px 0 23px}.draw-actions{height:48px}.draw-actions #draw{padding:10px 18px;font-size:12px;min-height:36px}.saved{height:20px;margin:4px 0 0;line-height:16px}.timer-bar{margin:0;height:3px}@media(max-width:700px){.hand-panel{padding:14px 12px;grid-template-rows:108px 3px 148px 48px 22px}.hand-heading{height:108px}.hand-heading h2{height:52px;line-height:26px;font-size:21px}.hand-heading p:not(.eyebrow){height:36px;line-height:18px;margin-top:4px}.card-stage,.cards{height:148px}.saved{height:22px}}

/* Five clipped symbol strips stop independently from left to right. */
#cards.cards{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;padding:12px;background:#121212;border:3px solid #d8b766;border-radius:18px;box-shadow:inset 0 0 20px #000;max-width:620px;width:100%;margin:auto}
.slot-reel{position:relative;height:148px;min-width:0;overflow:hidden;background:linear-gradient(#c5c5c5,#fff 35%,#fff 65%,#c5c5c5);border-radius:10px;color:#171717;box-shadow:inset 0 0 12px #555}
.slot-reel:after{content:'';position:absolute;inset:0;pointer-events:none;background:linear-gradient(#0004,transparent 30%,transparent 70%,#0004)}
.reel-strip{height:100%;will-change:transform}.reel-symbol{height:50%;display:flex;align-items:center;justify-content:center;font-size:clamp(27px,6vw,62px);line-height:1}
.slot-reel.spinning .reel-symbol{filter:blur(.6px)}
@media(max-width:700px){#cards.cards{gap:5px;padding:8px}.slot-reel{height:126px;border-radius:7px}}
@media(prefers-reduced-motion:reduce){.slot-reel.spinning .reel-symbol{filter:none}}

.slot-reel{padding:0;border:2px solid transparent;cursor:pointer;font:inherit}.slot-reel.held{border-color:#e9cc83;box-shadow:inset 0 0 12px #555,0 0 10px #e9cc8380}.slot-reel:focus-visible{outline:3px solid #fff;outline-offset:2px}.reel-hold{position:absolute;z-index:1;bottom:3px;left:0;right:0;text-align:center;font:700 10px/16px sans-serif;color:#333;letter-spacing:1px;background:#ffffffc9}.held .reel-hold{background:#e9cc83;color:#171717}.slot-reel:disabled{cursor:default;opacity:1}

/* The center cell is the scoring payline; adjacent symbols are half visible. */
.slot-reel:before{content:'';position:absolute;z-index:1;pointer-events:none;left:0;right:0;top:25%;height:50%;border-top:1px solid #c39840aa;border-bottom:1px solid #c39840aa;background:#e9cc8309}
.reel-symbol{font-size:clamp(25px,5vw,56px);flex-shrink:0}.reel-hold{bottom:0;line-height:13px;font-size:9px;background:#ffffffe6}

/* Compact payline guide stays above the reel window at every screen size. */
.hand-panel{grid-template-rows:100px 76px 3px 178px 48px 20px}
.reel-legend{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;padding:6px 0 9px;text-align:center}
.legend-symbols{display:flex;align-items:center;gap:7px;height:22px;font-size:19px;line-height:22px}.legend-values{display:flex;justify-content:center;gap:16px;color:#ddd;font-size:11px;line-height:16px}.legend-values strong{color:#e9cc83;margin-left:3px}.reel-legend small{color:var(--muted);font-size:9px;line-height:12px}
.slot-seven{display:inline-block;color:#df152b;font-family:Impact,'Arial Black',sans-serif;font-weight:900;font-style:italic;font-size:1.08em;line-height:1;transform:skew(-7deg);-webkit-text-stroke:1px #8f0716;text-shadow:1px 1px 0 #fff2cb,2px 2px 0 #8f0716,3px 3px 0 #830713;letter-spacing:-.07em;padding-right:.1em}
.legend-symbols .slot-seven{font-size:24px;-webkit-text-stroke:.5px #8f0716;text-shadow:1px 1px 0 #fff2cb,2px 2px 0 #8f0716}
@media(max-width:700px){.hand-panel{grid-template-rows:108px 76px 3px 148px 48px 22px}.legend-values{gap:10px;font-size:10px}}

/* Compact symbol-specific payouts, shared with both scoring guides. */
.hand-panel{grid-template-rows:100px 174px 3px 178px 48px 20px}
.reel-legend{padding:3px 0 10px;display:block}.symbol-paytable{border-collapse:collapse;width:100%;max-width:440px;margin:auto;table-layout:fixed;font-size:11px;line-height:16px;text-align:center}.symbol-paytable caption{caption-side:bottom;color:var(--muted);font-size:9px;line-height:18px}.symbol-paytable th,.symbol-paytable td{padding:0 5px;height:19px;border-bottom:1px solid #ffffff0d}.symbol-paytable thead{color:var(--muted);font-size:10px}.symbol-paytable tbody th{font-size:15px}.symbol-paytable td{color:#e9cc83;font-variant-numeric:tabular-nums}.symbol-paytable .slot-seven{font-size:18px;-webkit-text-stroke:.5px #8f0716;text-shadow:1px 1px #fff2cb,2px 2px #8f0716}.scores:has(.symbol-paytable){display:block}.scores .symbol-paytable{font-size:13px}.scores .symbol-paytable th,.scores .symbol-paytable td{height:26px}
@media(max-width:700px){.hand-panel{grid-template-rows:108px 174px 3px 148px 48px 22px}}

/* Payouts sit below the reel controls and status message. */
.hand-panel{grid-template-rows:100px 3px 178px 48px 20px 174px}.reel-legend{padding:10px 0 3px}
@media(max-width:700px){.hand-panel{grid-template-rows:108px 3px 148px 48px 22px 174px}}

.crazy-banner{position:absolute;z-index:5;left:50%;top:50%;transform:translate(-50%,-50%) rotate(-4deg);width:min(370px,94%);padding:14px 12px;background:linear-gradient(125deg,#7224b5,#c21472,#8534c5);border:3px solid #ffe478;border-radius:22px;text-align:center;box-shadow:0 0 22px #cf3ea880;pointer-events:none}.crazy-banner>span{display:block;font-size:38px;line-height:42px}.crazy-banner strong{display:block;color:#fff180;font:900 italic clamp(23px,5vw,34px)/1.15 'Arial Black',sans-serif;text-shadow:2px 3px #7b1549}.crazy-banner small{display:block;margin-top:6px;color:white;font-size:11px}.crazy-pop{animation:crazy-bounce .65s ease-in-out 4}.crazy-symbol{filter:drop-shadow(0 0 4px #ac34cc)}@keyframes crazy-bounce{0%,100%{transform:translate(-50%,-50%) rotate(-4deg) scale(1)}50%{transform:translate(-50%,-50%) rotate(4deg) scale(1.06)}}@media(prefers-reduced-motion:reduce){.crazy-pop{animation:none}}

/* Broad, continuous top bar on the custom red seven. */
.slot-seven{width:.76em;height:.95em;padding:0;letter-spacing:0;transform:skew(-5deg);vertical-align:middle;filter:drop-shadow(2px 2px 0 #fff2cb)}.slot-seven svg{display:block;width:100%;height:100%;overflow:visible}
.confetti-layer{position:fixed;inset:0;z-index:1000;pointer-events:none;overflow:hidden}.confetti-layer i{position:absolute;top:-20px;width:8px;height:13px;border-radius:2px;animation:confetti-fall 1.8s ease-out both}.confetti-layer i:nth-child(3n){border-radius:50%;width:9px;height:9px}@keyframes confetti-fall{from{transform:translate(0,-20px) rotate(0);opacity:1}to{transform:translate(var(--drift),105vh) rotate(var(--turn));opacity:0}}@media(prefers-reduced-motion:reduce){.confetti-layer i{top:12%;animation:confetti-fade 1s ease-out both!important}@keyframes confetti-fade{from{opacity:1}to{opacity:0}}}

.theme-select{width:100%;padding:11px 13px;border:1px solid var(--line);border-radius:6px;background:#101318;color:var(--ink);font:inherit}.theme-select:focus-visible{outline:2px solid #e9cc83;outline-offset:2px}.theme-preview{display:flex;gap:8px;align-items:center;justify-content:center;margin:12px 0 0}.theme-preview>span{display:flex;align-items:center;justify-content:center;width:32px;height:36px;font-size:25px}.theme-note{color:var(--muted);font-size:10px;margin:7px 0 0}.jungle-symbol{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none}.reel-symbol .jungle-symbol{width:auto;max-width:100%;height:100%}.symbol-paytable .jungle-symbol{width:24px;height:19px;margin:auto}.scores .symbol-paytable .jungle-symbol{width:30px;height:26px}.theme-preview .jungle-symbol{width:36px;height:36px}
body[data-theme="jungle"]{--orange:#e9c86d;--cream:#07130e;--line:#315142}body[data-theme="jungle"] .hand-panel,body[data-theme="jungle"] .setup{background:linear-gradient(140deg,#102c20,#0c1913)}body[data-theme="jungle"] #cards.cards{background:#0c2619;border-color:#c8ad57;box-shadow:inset 0 0 20px #000,0 0 18px #39784733}body[data-theme="jungle"] .slot-reel{background:linear-gradient(#829879,#f3f5dc 35%,#f3f5dc 65%,#829879)}
@media(max-width:400px){.theme-preview{gap:4px}.theme-preview>span{width:28px;height:30px}}

.bonus-symbol{display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1}.bonus-symbol small{font:900 9px/12px sans-serif;color:#784c00;letter-spacing:.5px}.bonus-overlay{position:fixed;inset:0;z-index:600;background:#020b08cf;display:grid;place-items:center;padding:16px}.bonus-dialog{width:min(580px,100%);min-height:350px;text-align:center;background:radial-gradient(ellipse at top,#31572d,#101b13);border:3px solid #e9cc83;border-radius:22px;padding:26px 18px;box-shadow:0 0 55px #e9cc8330}.bonus-chests{display:flex;justify-content:center;gap:12px;min-height:165px;align-items:center}.treasure-chest{background:#8e551f55;border:2px solid #bfa164;border-radius:14px;padding:14px 10px;color:#ffe7a0;min-width:0;flex:1}.treasure-chest span{display:block;font-size:clamp(38px,9vw,65px);line-height:1.3}.treasure-chest strong{display:block;font-size:13px}.treasure-chest:focus-visible{outline:3px solid white;outline-offset:3px}.treasure-chest:disabled{opacity:1;cursor:default}.treasure-chosen{flex:0 1 260px;transform:scale(1.12);background:#a16a2666;animation:treasure-reveal .35s ease-out}.treasure-chosen strong{font-size:25px}.treasure-chosen span{font-size:80px}#bonusPrize{color:#ffe49d;font-weight:700}#bonusCountdown{font-size:13px;color:#eee5c9}@keyframes treasure-reveal{from{transform:scale(.85)}to{transform:scale(1.12)}}@media(prefers-reduced-motion:reduce){.treasure-chosen{animation:none;transform:none}}

.treasure-chest svg{display:block;width:100%;max-width:100px;height:85px;margin:auto;filter:drop-shadow(0 4px 4px #0006)}.treasure-chosen svg{max-width:155px;height:125px}

body[data-theme="pirate"]{--orange:#e9c16d;--cream:#09131e;--line:#395267}body[data-theme="pirate"] .hand-panel,body[data-theme="pirate"] .setup{background:linear-gradient(140deg,#193448,#101c2a)}body[data-theme="pirate"] #cards.cards{background:linear-gradient(#57351d,#281b14);border-color:#cba15a;box-shadow:inset 0 0 20px #000,0 0 18px #cba15a22}body[data-theme="pirate"] .slot-reel{background:linear-gradient(#a59c82,#fff0d0 35%,#fff0d0 65%,#a59c82)}

.setup-message{width:min(440px,calc(100% - 32px))}.setup-message ul{padding-left:22px;margin:18px 0 24px;line-height:1.7;color:#ffe5b2}.setup-message p{color:var(--muted);font-size:13px}.setup-message .primary{width:100%}

.treasure-chest img{display:block;width:100%;max-width:110px;height:95px;object-fit:contain;margin:auto;filter:drop-shadow(0 4px 4px #0006)}.treasure-chosen img{max-width:175px;height:150px}

/* Keep the reel header quiet and the countdown compact. */
.hand-panel{grid-template-rows:56px 3px 178px 48px 20px 174px}.hand-heading{height:56px;align-items:center}.hand-heading .eyebrow{margin:0}.hand-heading .timer{flex-basis:76px}.hand-heading .timer strong{font-size:28px;height:32px;line-height:32px}.hand-heading .timer span{font-size:8px;height:20px;line-height:10px}.finish-countdown strong{font-size:20px;line-height:28px}
@media(max-width:700px){.hand-panel{grid-template-rows:54px 3px 148px 48px 22px 174px}.hand-heading{height:54px}.hand-heading .timer{flex-basis:68px}.hand-heading .timer strong{font-size:26px;height:30px;line-height:30px}}

/* Countdown and progress sit below the reel window. */
.hand-panel{grid-template-rows:178px 44px 48px 20px}.reel-countdown{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:14px;align-items:center;min-width:0}.reel-countdown .timer-bar{width:100%;margin:0;height:3px}.reel-countdown .timer{min-width:42px;flex:none}.reel-countdown .timer strong{font-size:28px;line-height:32px;height:32px}.reel-countdown .timer span:empty{display:none}.reel-countdown .timer span{font-size:8px;height:auto;line-height:10px}
@media(max-width:700px){.hand-panel{grid-template-rows:148px 42px 48px 22px}.reel-countdown .timer strong{font-size:26px;line-height:30px;height:30px}}

/* Phone play view keeps the full eight-lane track and reels together. */
@media(max-width:700px){
 body.playing header{height:50px;padding:0 12px;gap:8px}body.playing .brand-logo{width:125px}body.playing header .lobby-button,body.playing header .sound-button{padding:8px;font-size:10px;min-height:34px}
 body.playing main{padding:0 8px 8px}body.playing #game{margin-top:6px!important;display:grid;grid-template-columns:minmax(0,1fr);gap:4px;position:relative}
 body.playing .race-heading{margin:0;min-height:22px;gap:5px}body.playing .race-heading .eyebrow{margin:0;font-size:8px;line-height:12px}body.playing .race-heading h2{font-size:14px;line-height:18px}body.playing .race-heading .current-race-name,body.playing .race-heading .room-box{display:none}
 body.playing .guide-actions{margin:0;position:absolute;right:0;top:0}body.playing #openGuide{padding:7px 9px;min-height:32px;font-size:10px}body.playing .race-heading>div:first-child{padding-right:95px}
 body.playing .track-shell{padding:7px 6px;border-radius:8px;--name-column:76px;--gate-gap:10px}body.playing .track-top{font-size:7px;letter-spacing:0;margin-bottom:5px;line-height:12px}body.playing .track{max-height:none;overflow-y:hidden;border-width:2px}body.playing .lane{height:21px}body.playing .race-actions{height:0!important;min-height:0;margin:0!important;padding:0}
 body.playing .hand-panel{padding:7px 8px;grid-template-rows:128px 30px 44px 16px;min-width:0;border-radius:8px}body.playing .card-stage,body.playing #cards.cards{height:128px}body.playing #cards.cards{padding:6px;gap:5px;border-width:2px}body.playing .slot-reel{height:112px}body.playing .reel-symbol{font-size:clamp(24px,7vw,38px)}body.playing .reel-hold{font-size:8px;line-height:12px}
 body.playing .reel-countdown{gap:10px}body.playing .reel-countdown .timer strong{height:26px;line-height:26px;font-size:23px}body.playing .draw-actions{height:44px}body.playing .draw-actions #draw{min-height:40px;padding:9px 16px}body.playing .saved{height:16px;line-height:14px;font-size:9px;margin:0;overflow:hidden}
 body.playing #reelLegend,body.playing footer{display:none}body.playing #error:empty{display:none}body.playing .card-stage .outcome{padding:10px 12px}body.playing .card-stage .outcome h2{font-size:20px}body.playing .card-stage .outcome p:not(.eyebrow){font-size:11px;margin:4px 0 0}body.playing .card-stage .outcome .eyebrow{margin-bottom:4px}
}
@media(max-width:700px) and (max-height:500px) and (min-width:500px){
 body.playing #game{grid-template-columns:minmax(0,1fr) minmax(0,1fr);column-gap:8px}body.playing .race-heading{grid-column:1/-1}body.playing .track-shell{grid-column:1;grid-row:2}body.playing .hand-panel{grid-column:2;grid-row:2}body.playing .race-actions{display:none}
}

.saved.crazy-waiting,body.playing .saved.crazy-waiting{color:#ffe09b;font-size:11px;font-weight:600}

/* Preserve the label strip as blank white space when holds are unavailable. */
.slot-reel.hold-unavailable .reel-hold,.slot-reel.held.hold-unavailable .reel-hold{background:#fff;color:transparent}

@media(pointer:coarse){html,body{touch-action:pan-y;overflow-y:auto}button,a,select,input{touch-action:pan-y}}

.theme-choices{border:0;padding:0;margin:23px 0 16px;min-width:0}.theme-choices legend{padding:0;margin-bottom:10px;font-size:11px;font-weight:700}.theme-options{display:flex;gap:8px}.theme-options label{display:flex;align-items:center;justify-content:center;gap:7px;flex:1;min-width:0;margin:0;padding:12px 8px;border:1px solid var(--line);border-radius:7px;background:#0b1016;font-size:12px;cursor:pointer}.theme-options input{width:18px;height:18px;margin:0;padding:0;accent-color:#d6ad71;flex:none}.theme-options label:has(input:checked){border-color:#d6ad71;background:#30271b;color:#ffe6b0}.theme-options label:has(input:focus-visible){outline:2px solid white;outline-offset:2px}#setup #join{margin:0 0 2px}@media(max-width:380px){.theme-options{gap:5px}.theme-options label{padding:11px 5px;gap:4px;font-size:11px}}

#setup .racer-picker-title{font-size:15px;line-height:21px;margin-bottom:18px}

.saved.crazy-flash{animation:crazy-wait-pulse 1.4s ease-in-out infinite}@keyframes crazy-wait-pulse{0%,100%{opacity:1}50%{opacity:.3}}@media(prefers-reduced-motion:reduce){.saved.crazy-flash{animation:none;text-decoration:underline}}
/* Let longer finish headings occupy their own space above the placement text. */
.finish-dialog,.finish-overlay.is-winner .finish-dialog{height:min(620px,calc(100dvh - 32px));grid-template-rows:auto auto minmax(60px,1fr) 44px 42px;gap:12px;padding:24px;overflow:auto}.finish-heading{min-width:0}.finish-icon{font-size:64px;line-height:76px}.finish-heading h2{font-size:28px;line-height:1.2;overflow-wrap:break-word;margin:6px 0 0}.finish-details{max-height:116px;overflow:auto;padding-top:2px;line-height:22px}.finish-details>p{position:static;margin:0}
@media(max-width:700px){.finish-overlay{padding:16px}.finish-dialog,.finish-overlay.is-winner .finish-dialog{padding:18px 16px;gap:10px;grid-template-rows:auto auto minmax(60px,1fr) 40px 42px}.finish-heading h2{font-size:24px;line-height:29px}.finish-icon{font-size:56px;line-height:66px}}

/* Large-screen play keeps the course and reels in a single TV-friendly view. */
@media(min-width:1000px) and (min-height:600px){
 body.playing header{height:clamp(60px,7vh,100px);padding:0 4%;gap:24px}body.playing .brand-logo{width:clamp(175px,15vw,285px)}body.playing header button{font-size:clamp(12px,1vw,18px)}
 body.playing main{width:92%;max-width:1800px;padding:0 0 12px}body.playing #game{margin-top:10px!important;display:grid;grid-template-columns:minmax(0,1fr);gap:8px;position:relative}
 body.playing .race-heading{margin:0;min-height:42px;padding-right:140px}body.playing .race-heading .eyebrow{margin:0 0 3px;font-size:clamp(10px,.8vw,15px)}body.playing .race-heading h2{font-size:clamp(19px,1.5vw,30px);line-height:1.15}body.playing .current-race-name{display:none}body.playing .race-heading .room-box{display:none}
 body.playing .guide-actions{position:absolute;top:0;right:0;margin:0}body.playing #openGuide{font-size:clamp(12px,.9vw,18px);min-height:40px}
 body.playing .track-shell{padding:10px 14px;--name-column:clamp(100px,11vw,190px);--gate-gap:18px}body.playing .track-top{font-size:clamp(10px,.8vw,16px);line-height:18px;margin-bottom:7px}body.playing .track{max-height:none;overflow-y:hidden}body.playing .lane{height:clamp(25px,3.25vh,52px)}body.playing .track .lane-label{font-size:clamp(11px,1vw,19px)}body.playing .racer{width:clamp(20px,2.5vh,40px);height:clamp(20px,2.5vh,40px);font-size:clamp(14px,1.7vh,28px);top:2px}body.playing .racer-hand{font-size:clamp(10px,.8vw,16px)}
 body.playing .race-actions{height:0!important;min-height:0;margin:0!important;padding:0}body.playing .hand-panel{padding:10px 18px;grid-template-rows:clamp(140px,21vh,320px) 36px 48px 20px}
 body.playing .card-stage,body.playing #cards.cards{height:clamp(140px,21vh,320px)}body.playing #cards.cards{max-width:min(900px,75%);padding:8px 12px;gap:10px}body.playing .slot-reel{height:calc(clamp(140px,21vh,320px) - 22px)}body.playing .reel-symbol{font-size:clamp(34px,5.5vh,92px)}body.playing .reel-hold{font-size:clamp(10px,.7vw,15px);line-height:18px}
 body.playing .reel-countdown{max-width:900px;width:100%;margin:auto}body.playing .reel-countdown .timer strong{font-size:clamp(25px,2vw,38px)}body.playing .draw-actions{height:48px}body.playing .draw-actions #draw{min-height:42px;font-size:clamp(13px,.9vw,18px)}body.playing .saved{height:20px;line-height:18px;font-size:clamp(11px,.8vw,16px);margin:0}
 body.playing #reelLegend,body.playing footer{display:none}body.playing #error:empty{display:none}
}

#openLobbyPayouts{justify-self:start;align-self:center}#guideDialog>.eyebrow{margin-bottom:12px}

.wild-symbol{position:relative;display:inline-flex;align-items:center;justify-content:center;width:100%;height:100%;min-width:0}.wild-symbol>small{position:absolute;bottom:1px;left:50%;transform:translateX(-50%);background:#513073;color:#fff1a6;border-radius:3px;padding:1px 4px;font:800 8px/10px sans-serif;letter-spacing:.6px}.wild-symbol>.jungle-symbol{width:auto;max-width:100%;height:100%}.symbol-paytable .wild-symbol{width:36px;height:27px}.symbol-paytable .wild-symbol>.jungle-symbol{height:24px}.symbol-paytable .wild-symbol>small{font-size:6px;line-height:7px;bottom:0;padding:0 2px}.theme-preview .wild-symbol{height:36px}

.guide-actions{align-items:center;gap:9px;position:relative}.top-room-code{font-size:11px;color:var(--muted);white-space:nowrap}.top-room-code strong{color:#ffe6ad;font-size:13px;letter-spacing:1px;font-variant-numeric:tabular-nums}.invite-status{position:absolute;right:0;top:100%;font-size:10px}.invite-buttons{display:flex;gap:12px;margin-top:18px;align-items:center}.race-heading .room-box{display:none}
@media(max-width:700px){body.playing .guide-actions{position:static;justify-content:flex-end;gap:6px}body.playing #game{gap:3px}body.playing .race-heading>div:first-child{padding-right:0}body.playing #inviteRace{font-size:10px;min-height:32px;padding:7px 9px}.top-room-code{font-size:10px}.top-room-code strong{font-size:12px}body.playing #openGuide{padding:7px 8px}}
@media(min-width:1000px) and (min-height:600px){body.playing .race-heading{padding-right:350px}body.playing #inviteRace{min-height:40px;font-size:clamp(12px,.9vw,18px)}body.playing .top-room-code{font-size:clamp(11px,.8vw,16px)}body.playing .top-room-code strong{font-size:clamp(13px,1vw,20px)}}

.crazy-banner{width:min(310px,88%);padding:10px;border-width:2px;border-radius:16px;background:linear-gradient(125deg,rgba(114,36,181,.76),rgba(194,20,114,.76),rgba(133,52,197,.76));box-shadow:0 0 16px #cf3ea850}.crazy-banner>span{font-size:29px;line-height:32px}.crazy-banner strong{font-size:clamp(20px,4.5vw,27px);line-height:1.12}.crazy-banner small{margin-top:4px;font-size:10px}

.wild-symbol-image{display:block;object-fit:contain;max-width:100%;height:100%;width:auto}.wild-symbol-classic{width:.76em;height:1.14em;filter:drop-shadow(2px 2px 0 #fff2cb)}.theme-preview .wild-symbol-image{width:36px;height:36px}.symbol-paytable .wild-symbol-image{width:28px;height:26px;margin:auto}

.amusement-notice{margin:7px 0 0;text-align:center;color:var(--muted);font-size:10px;line-height:14px}@media(max-width:700px){body.playing .amusement-notice{margin:0;font-size:9px;line-height:12px}}@media(max-width:700px) and (max-height:500px) and (min-width:500px){body.playing .amusement-notice{grid-column:1/-1}}

body[data-theme="hawaii"]{--orange:#ffd884;--cream:#081f2b;--line:#357586}body[data-theme="hawaii"] .hand-panel,body[data-theme="hawaii"] .setup{background:linear-gradient(135deg,#153f46,#102d37)}body[data-theme="hawaii"] #cards.cards{background:linear-gradient(#1c6269,#16434c);border-color:#e5be73;box-shadow:inset 0 0 20px #062731,0 0 18px #3db5aa33}body[data-theme="hawaii"] .slot-reel{background:linear-gradient(#8baaa5,#fff5d9 35%,#fff5d9 65%,#8baaa5)}.theme-preview{flex-wrap:wrap}
@media(max-width:700px){.theme-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}}

/* A larger animated face, independent of the reel strip's scrolling transform. */
.crazy-character{display:inline-block;font-size:1.18em;line-height:1;transform-origin:center;animation:crazy-character-wobble .9s ease-in-out infinite;filter:drop-shadow(0 0 4px #b14bdc88)}.slot-reel.spinning .crazy-character{animation:none}.crazy-banner>span{font-size:35px;line-height:38px;animation:crazy-character-wobble .9s ease-in-out infinite}@keyframes crazy-character-wobble{0%,100%{transform:rotate(-8deg) translateY(0)}30%{transform:rotate(9deg) translateY(-2px)}65%{transform:rotate(-4deg) translateY(1px)}}@media(prefers-reduced-motion:reduce){.crazy-character,.crazy-banner>span{animation:none}}

.wild-symbol-classic{height:1.28em}

.lobby-menu-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.game-menu-link{display:inline-flex;align-items:center;justify-content:center;text-decoration:none;white-space:nowrap}.crazy-avatar-label{background:#603172ed;color:#fff1a5!important;font-weight:800}

/* Three full symbol rows and three horizontal scoring lines. */
.hand-panel{grid-template-rows:242px 44px 48px 20px}.card-stage,#cards.cards{height:242px}.slot-reel{height:212px;--hold-height:14px}.slot-reel:before{content:none}.reel-window{position:relative;height:calc(100% - var(--hold-height));overflow:hidden}.reel-strip{height:100%}.reel-symbol{height:33.333333%;font-size:clamp(27px,5vw,54px)}.reel-hold{height:var(--hold-height);line-height:var(--hold-height);bottom:0}.reel-payline{position:absolute;left:0;right:0;border-top:1px dotted #ad802949;pointer-events:none;z-index:1}.payline-markers{position:absolute;z-index:2;left:0;top:12px;bottom:26px;width:14px;pointer-events:none}.payline-markers span{position:absolute;left:1px;font:bold 9px/12px sans-serif;color:#ffe6ac;background:#382b19;border-radius:3px;width:12px;text-align:center;transform:translateY(-50%)}.payline-markers span:nth-child(1){top:16.666%}.payline-markers span:nth-child(2){top:50%}.payline-markers span:nth-child(3){top:83.333%}
@media(max-width:700px){body.playing .hand-panel{grid-template-rows:158px 26px 40px 16px}body.playing .card-stage,body.playing #cards.cards{height:158px}body.playing .slot-reel{height:142px;--hold-height:12px}body.playing .reel-symbol{font-size:clamp(22px,6vw,34px)}body.playing .lane{height:18px}body.playing .racer{width:16px;height:16px;font-size:11px}body.playing .draw-actions{height:40px}body.playing .draw-actions #draw{min-height:36px;padding:7px 14px}body.playing .payline-markers{top:8px;bottom:24px;width:10px}body.playing .payline-markers span{font-size:8px;width:10px;left:-2px}body.playing .card-stage .outcome{max-height:150px;overflow:auto}body.playing .card-stage .outcome h2{font-size:19px}}
@media(min-width:1000px) and (min-height:600px){body.playing .hand-panel{grid-template-rows:clamp(180px,25vh,360px) 36px 48px 20px}body.playing .card-stage,body.playing #cards.cards{height:clamp(180px,25vh,360px)}body.playing .slot-reel{height:calc(clamp(180px,25vh,360px) - 22px);--hold-height:18px}body.playing .reel-symbol{font-size:clamp(30px,4.8vh,82px)}}

/* Clear guides across all three horizontal paylines. */
.reel-payline{border-top:2px dashed #b77b4299}

/* Three complete symbol rows, including room for artwork and BONUS labels. */
.payline-markers{display:none!important}
.hand-panel{grid-template-rows:272px 44px 48px 20px}.card-stage,#cards.cards{height:272px}.slot-reel{height:242px}
.reel-symbol{overflow:hidden;padding:3px 0}
.reel-symbol .bonus-symbol{height:100%;max-height:100%;font-size:.72em}
.reel-symbol .crazy-character{font-size:1em}
.reel-symbol .wild-symbol-image,.reel-symbol .jungle-symbol{max-height:100%;max-width:100%;object-fit:contain}
@media(max-width:700px){body.playing .hand-panel{grid-template-rows:178px 26px 40px 16px}body.playing .card-stage,body.playing #cards.cards{height:178px}body.playing .slot-reel{height:162px}}
@media(min-width:1000px) and (min-height:600px){body.playing .hand-panel{grid-template-rows:clamp(210px,28vh,390px) 36px 48px 20px}body.playing .card-stage,body.playing #cards.cards{height:clamp(210px,28vh,390px)}body.playing .slot-reel{height:calc(clamp(210px,28vh,390px) - 22px)}}

/* Hide unavailable hold controls and keep the guides beneath the artwork. */
.slot-reel.hold-unavailable .reel-hold{display:none;background:transparent}
.slot-reel.hold-unavailable .reel-window{height:calc(100% - var(--hold-height))}
.reel-window{isolation:isolate}.reel-payline{z-index:0}.reel-strip{position:relative;z-index:1}
.bonus-art{display:block;width:auto;height:100%;max-width:100%;object-fit:contain;transform-origin:50% 65%;animation:bonus-gift-bounce 1.8s ease-in-out infinite;filter:drop-shadow(0 1px 2px #6b174133)}
.reel-symbol .bonus-art{max-height:100%}.slot-reel.spinning .bonus-art{animation:none}
@keyframes bonus-gift-bounce{0%,100%{transform:scale(.92) rotate(-3deg)}45%{transform:scale(1) rotate(3deg)}65%{transform:scale(.97) rotate(0)}}
@media(prefers-reduced-motion:reduce){.bonus-art{animation:none}}

/* A held Crazy symbol is inactive, including its decorative motion. */
.slot-reel.held .crazy-character{animation:none;transform:none;filter:none}

/* Hold availability must never resize the symbol window at the end of a spin. */
.slot-reel.spinning .reel-symbol{filter:none}
.slot-reel.spinning .bonus-art{animation:bonus-gift-bounce 1.8s ease-in-out infinite}
.slot-reel.spinning .crazy-character{animation:crazy-character-wobble .9s ease-in-out infinite}
.slot-reel.held .crazy-character{animation:none}
@media(prefers-reduced-motion:reduce){.slot-reel.spinning .bonus-art,.slot-reel.spinning .crazy-character{animation:none}}

/* Make the marked wild artwork fill its row and shimmer gently. */
.reel-symbol:has(.wild-symbol-image){padding:0;overflow:hidden}
.reel-symbol .wild-symbol-image{width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain;transform-origin:center;animation:wild-symbol-shimmer 1.9s ease-in-out infinite}
@keyframes wild-symbol-shimmer{0%,100%{transform:scale(.96) rotate(-2deg);filter:drop-shadow(0 0 1px #c38a2d)}50%{transform:scale(1) rotate(2deg);filter:drop-shadow(0 0 4px #e5b444)}}
@media(prefers-reduced-motion:reduce){.reel-symbol .wild-symbol-image{animation:none}}
