/* BUMP: one token sheet. Toy sport on TV: candy rubber balls in a deep teal studio. Soft rubber plates, one accent (spring
   green), the ball's own colours, round pips as the motif. Paytone One / Figtree / Victor Mono, self-hosted. */
@font-face { font-family: 'Paytone One'; src: url(/fonts/paytone-one-latin.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url(/fonts/figtree-latin.woff2) format('woff2'); font-weight: 300 900; font-display: swap; }
@font-face { font-family: 'Victor Mono'; src: url(/fonts/victor-mono-latin.woff2) format('woff2'); font-weight: 100 700; font-display: swap; }
:root {
  --bg: #04161a; --s1: #061d22; --s2: #0a2328; --s3: #0e2c32; --s4: #143840; --s5: #1b4750;
  --ink: #eafcf5; --ink-2: #a3c9c0; --ink-3: #6a948d; --ink-4: #4a7069;
  --line: rgba(160, 255, 222, 0.09); --line-2: rgba(160, 255, 222, 0.17);
  --acc: #2ee88a; --acc-d: #17b868; --acc-l: #9dffcb; --acc-glow: rgba(46, 232, 138, 0.35);
  --sol: #14f195; --gold: #ffd25e; --hot: #ff5d6c; --sky: #6fd3ff;
  --r: 18px; --r-2: 12px; --r-3: 8px;
  --f-d: 'Paytone One', 'Arial Rounded MT Bold', system-ui, sans-serif; --f-t: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif; --f-m: 'Victor Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --plate: linear-gradient(180deg, rgba(20, 56, 64, 0.94), rgba(10, 35, 40, 0.94));
  --lit: inset 0 1px 0 rgba(255, 255, 255, 0.07), inset 0 0 0 1px rgba(160, 255, 222, 0.07);
  --drop: 0 18px 40px -12px rgba(0, 0, 0, 0.6), 0 4px 10px -4px rgba(0, 0, 0, 0.45);
}
:where(*, *::before, *::after) { box-sizing: border-box; }
:where(html, body) { margin: 0; padding: 0; height: 100%; }
:where(button, input) { font: inherit; color: inherit; }
:where(button) { background: none; border: 0; padding: 0; cursor: pointer; }
:where(a) { color: inherit; text-decoration: none; }
:where(h1, h2, h3, p, ol, ul) { margin: 0; padding: 0; }
:where(ol, ul) { list-style: none; }
body { background: var(--bg); color: var(--ink); font: 500 15px/1.45 var(--f-t); overflow: hidden; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; overscroll-behavior: none; }
.is-hidden { display: none !important; }
#game, #layer { position: fixed; left: 0; top: 0; width: 1px; height: 1px; display: block; touch-action: none; pointer-events: none; }      /* (both placed over the arena by render.js; #layer, the still picture, under #game) */
/* the studio behind the arena: deep teal, a spotlight that sits on the arena (set from the page), still dots, a vignette */
/* the studio: ONE still layer (vignette, dots, the spotlight on the arena, the floor) painted once; the canvas over it is the only
   thing that changes in a frame (three stacked full-screen layers, one of them drifting, cost frames at 1920 wide) */
#bg { position: fixed; inset: 0; overflow: hidden; background: radial-gradient(ellipse 75% 70% at 50% 50%, transparent 55%, rgba(0, 6, 8, 0.55)), radial-gradient(rgba(160, 255, 222, 0.075) 1.1px, transparent 1.5px) 0 0 / 32px 32px, radial-gradient(46% 52% at var(--sx, 50%) var(--sy, 52%), rgba(52, 165, 150, 0.2), rgba(4, 22, 26, 0) 72%), linear-gradient(180deg, #06222a 0%, #04161a 52%, #021013 100%); }
kbd { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.07); box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.08); font: 600 11.5px/1 var(--f-m); color: var(--ink-2); vertical-align: middle; }
.mono { font-family: var(--f-m); }
.link { color: var(--ink-2); font-weight: 600; border-bottom: 1px solid transparent; transition: color 0.15s, border-color 0.15s; }
.link:hover { color: var(--ink); border-bottom-color: var(--line-2); }
.live-dot { position: relative; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--acc); box-shadow: 0 0 0 3px rgba(46, 232, 138, 0.18), 0 0 12px var(--acc-glow); }
.live-dot::after { content: ''; position: absolute; inset: -5px; border-radius: 50%; background: rgba(46, 232, 138, 0.16); animation: pulse 2s ease-in-out infinite; }      /* (opacity + scale: the compositor's work, no repaint a frame) */
@keyframes pulse { 50% { opacity: 0.25; transform: scale(1.35); } }
.card { background: var(--plate); border-radius: var(--r); box-shadow: var(--lit), var(--drop); }

/* ---------------------------------------------------------------- the title: a triptych around the live arena */
.title { position: fixed; inset: 0; display: grid; grid-template-columns: minmax(380px, 440px) 1fr minmax(320px, 360px); grid-template-rows: 64px minmax(0, 1fr) 46px; column-gap: 30px; padding: 0 30px; pointer-events: none; }
.title > * { pointer-events: auto; }
.bar { grid-column: 1 / -1; display: flex; align-items: center; gap: 22px; min-width: 0; }
.brand { display: flex; align-items: center; gap: 11px; flex: none; }
.brand-mark { width: 34px; height: 34px; display: block; flex: none; }
.brand-mark svg, .brand-mark .mark-img { width: 100%; height: 100%; display: block; border-radius: 50%; object-fit: cover; }
.brand-word { font: 400 25px/1 var(--f-d); letter-spacing: 0.01em; color: var(--ink); }
.bar-nav { display: flex; gap: 20px; font-size: 14px; }
.ticker { flex: none; font: 600 13px/1 var(--f-m); color: var(--acc); padding: 7px 11px; border-radius: 999px; background: rgba(46, 232, 138, 0.09); box-shadow: inset 0 0 0 1px rgba(46, 232, 138, 0.25); }
.ca-wrap { position: relative; flex: 1 1 auto; min-width: 0; height: 38px; }
.ca-pill { position: absolute; right: 0; top: 0; display: flex; align-items: center; gap: 8px; height: 38px; max-width: 100%; padding: 0 6px 0 14px; border-radius: 999px; background: rgba(10, 35, 40, 0.86); box-shadow: var(--lit); }
.ca-pill.is-live { box-shadow: inset 0 0 0 1px rgba(46, 232, 138, 0.45); }
.ca-lab { font: 700 12px/1 var(--f-t); letter-spacing: 0.04em; color: var(--ink-3); white-space: nowrap; }
.ca-addr { display: flex; align-items: center; gap: 8px; min-width: 0; height: 28px; padding: 0 4px 0 2px; border-radius: 999px; font: 600 12.5px/1 var(--f-m); color: var(--ink); cursor: copy; user-select: text; -webkit-user-select: text; }
.ca-addr:disabled { cursor: default; color: var(--ink-3); font: 600 12.5px/1 var(--f-t); padding-right: 10px; }
.ca-addr > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ca-copy { flex: none; font: 800 11.5px/1 var(--f-t); font-style: normal; padding: 6px 11px; border-radius: 999px; background: var(--acc); color: #032016; min-width: 56px; text-align: center; }
.ca-link { flex: none; font: 700 11.5px/1 var(--f-t); padding: 7px 11px; border-radius: 999px; background: var(--s4); color: var(--ink-2); white-space: nowrap; }
.ca-link:hover { color: var(--ink); }
.live { flex: none; display: flex; align-items: center; gap: 9px; font-size: 13.5px; color: var(--ink-2); }
.live b { font: 700 14px/1 var(--f-m); color: var(--ink); }

.col { min-height: 0; display: flex; flex-direction: column; }
.col-left { justify-content: center; gap: 0; padding-bottom: 8px; }
.eyebrow { display: flex; align-items: center; gap: 10px; font: 600 12.5px/1 var(--f-m); letter-spacing: 0.02em; color: var(--ink-2); margin-bottom: 18px; }
.headline { font: 400 clamp(40px, 2.55vw, 50px)/1.02 var(--f-d); white-space: nowrap; letter-spacing: -0.01em; color: var(--ink); text-shadow: 0 6px 30px rgba(0, 0, 0, 0.45); }
.headline em { font-style: normal; color: var(--acc); }
.lede { margin: 18px 0 22px; max-width: 380px; font-size: 15.5px; color: var(--ink-2); }
.play { padding: 18px 18px 14px; display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font: 700 11.5px/1 var(--f-t); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.field > span em { font-style: normal; text-transform: none; letter-spacing: 0; font-weight: 600; color: var(--ink-4); margin-left: 6px; }
.field input { height: 44px; padding: 0 14px; border-radius: var(--r-2); border: 0; outline: 0; background: rgba(2, 14, 17, 0.72); box-shadow: inset 0 0 0 1px var(--line), inset 0 2px 6px rgba(0, 0, 0, 0.35); font: 600 15px/1 var(--f-t); color: var(--ink); min-width: 0; transition: box-shadow 0.15s; }
.field input::placeholder { color: var(--ink-4); }
.field input:focus { box-shadow: inset 0 0 0 2px var(--acc), 0 0 0 4px rgba(46, 232, 138, 0.12); }
#t-addr, #m-addr { font: 600 13px/1 var(--f-m); }
.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mode { position: relative; text-align: left; padding: 12px 14px 12px; border-radius: var(--r-2); background: rgba(2, 14, 17, 0.5); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow 0.18s, background 0.18s, transform 0.18s; }
.mode b { display: block; font: 400 18px/1.1 var(--f-d); color: var(--ink-2); transition: color 0.18s; }
.mode span { display: block; margin-top: 3px; font-size: 12.5px; color: var(--ink-4); }
.mode-n { position: absolute; right: 12px; top: 12px; font: 600 11px/1 var(--f-m); font-style: normal; color: var(--ink-4); }
.mode-n::after { content: ' in'; }
.mode:hover { background: rgba(14, 44, 50, 0.6); }
.mode.is-on { background: radial-gradient(120% 140% at 0% 0%, rgba(46, 232, 138, 0.2), rgba(46, 232, 138, 0.04) 60%), rgba(2, 14, 17, 0.5); box-shadow: inset 0 0 0 2px var(--acc), 0 0 24px -6px var(--acc-glow); }
.mode.is-on b { color: var(--ink); }
.mode.is-on span { color: var(--ink-2); }
.mode.is-on .mode-n { color: var(--acc-l); }
.ballbtn { position: relative; display: flex; align-items: center; justify-content: center; gap: 12px; height: 58px; border-radius: 999px; color: #022015; font: 400 24px/1 var(--f-d); letter-spacing: 0.01em;
  background: radial-gradient(120% 90% at 30% 15%, #b7ffd8 0%, #4cf59e 22%, #2ee88a 45%, #16b768 82%, #0f9555 100%); box-shadow: inset 0 -5px 0 rgba(0, 60, 30, 0.35), inset 0 2px 0 rgba(255, 255, 255, 0.55), 0 10px 26px -8px rgba(46, 232, 138, 0.65), 0 2px 0 rgba(0, 0, 0, 0.3); transition: transform 0.12s, filter 0.15s; }
.ballbtn:hover { filter: brightness(1.06); transform: translateY(-1px); }
.ballbtn:active { transform: translateY(1px) scale(0.995); }
.ballbtn kbd { background: rgba(0, 40, 22, 0.18); box-shadow: inset 0 0 0 1px rgba(0, 40, 22, 0.25); color: #04331f; }
.ballbtn-ball { position: absolute; left: 10px; top: 50%; width: 40px; height: 40px; margin-top: -20px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #ffffff 0 9%, #eafff4 10%, #5ef7a6 40%, #13a75d 100%); box-shadow: inset 0 -3px 6px rgba(0, 50, 25, 0.45), 0 2px 6px rgba(0, 0, 0, 0.25); }
.ballbtn-ball::before, .ballbtn-ball::after { content: ''; position: absolute; top: 14px; width: 8px; height: 10px; border-radius: 50%; background: #042a18; box-shadow: inset 2px -1px 0 #fff; }
.ballbtn-ball::before { left: 15px; } .ballbtn-ball::after { left: 25px; }
.ballbtn.small { height: 46px; font-size: 19px; padding: 0 22px 0 58px; }
.ballbtn.small .ballbtn-ball { width: 32px; height: 32px; margin-top: -16px; left: 8px; }
.ballbtn.small .ballbtn-ball::before, .ballbtn.small .ballbtn-ball::after { top: 11px; width: 6px; height: 8px; }
.ballbtn.small .ballbtn-ball::before { left: 11px; } .ballbtn.small .ballbtn-ball::after { left: 19px; }
.ballbtn[disabled] { filter: grayscale(0.7) brightness(0.7); cursor: default; }
.play-alt { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.play-alt .sep { width: 1px; height: 18px; background: var(--line-2); }
.code-join { display: flex; align-items: center; gap: 8px; }
.code-join input { width: 78px; height: 30px; padding: 0 10px; border-radius: 9px; border: 0; outline: 0; background: rgba(2, 14, 17, 0.72); box-shadow: inset 0 0 0 1px var(--line); font: 700 13px/1 var(--f-m); letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink); }
.code-join input:focus { box-shadow: inset 0 0 0 2px var(--acc); }
.play-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-3); border-top: 1px solid var(--line); padding-top: 10px; }
.who { font: 600 12px/1 var(--f-m); color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.col-mid { position: relative; align-items: center; justify-content: flex-start; padding-top: 6px; pointer-events: none; }
.bug { pointer-events: auto; position: relative; z-index: 2; display: flex; align-items: stretch; gap: 0; max-width: 100%; border-radius: 16px; background: rgba(6, 26, 31, 0.9); box-shadow: var(--lit), 0 12px 30px -10px rgba(0, 0, 0, 0.6); overflow: hidden; }
.bug-head { display: flex; flex-direction: column; justify-content: center; gap: 3px; padding: 9px 14px; background: linear-gradient(180deg, rgba(46, 232, 138, 0.16), rgba(46, 232, 138, 0.06)); box-shadow: inset -1px 0 0 var(--line); min-width: 120px; }
.bug-head b { font: 400 15px/1 var(--f-d); color: var(--ink); }
.bug-head span { font: 600 11px/1.15 var(--f-m); color: var(--ink-2); white-space: nowrap; }
.bug-head .bug-round { color: var(--acc-l); }
.bug-rows { display: flex; align-items: center; gap: 2px; padding: 6px 8px; min-width: 0; overflow: hidden; }
.bug-rows li { display: flex; flex-direction: column; gap: 5px; padding: 6px 9px; border-radius: 10px; min-width: 74px; max-width: 108px; }
.bug-rows li.is-lead { background: rgba(255, 255, 255, 0.05); }
.bug-rows li.is-out .bn { opacity: 0.45; }
.bn { display: flex; align-items: center; gap: 6px; font: 700 12.5px/1 var(--f-t); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dot { flex: none; width: 11px; height: 11px; border-radius: 50%; box-shadow: inset 0 -2px 2px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 0, 0, 0.35); }
.pips { display: flex; gap: 4px; }
.pips i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, 0.1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06); }
.pips i.on { background: var(--c, var(--acc)); box-shadow: 0 0 8px -1px var(--c, var(--acc)), inset 0 -1.5px 1.5px rgba(0, 0, 0, 0.3); }
.bug-prize { display: flex; flex-direction: column; justify-content: center; gap: 3px; padding: 8px 14px; box-shadow: inset 1px 0 0 var(--line); min-width: 118px; }
.bug-prize span { font: 700 10.5px/1 var(--f-t); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 1px; }
.bug-prize b { font: 600 11.5px/1.2 var(--f-m); color: var(--sol); white-space: nowrap; }
.bug-prize b::before { color: var(--ink-3); margin-right: 6px; }
#bug-p1::before { content: '1st'; } #bug-p2::before { content: '2nd'; } #bug-p3::before { content: '3rd'; }
.stage-cap { position: absolute; bottom: 6px; left: 50%; transform: translateX(-50%); font: 600 11.5px/1 var(--f-m); color: var(--ink-3); white-space: nowrap; }

.col-right { justify-content: center; gap: 16px; padding-bottom: 8px; }
.rooms { padding: 14px 14px 12px; display: flex; flex-direction: column; min-height: 0; }
.rooms-head { display: flex; justify-content: space-between; align-items: baseline; padding: 0 4px 10px; }
.rooms-head b { font: 400 20px/1 var(--f-d); }
.rooms-head span { font: 600 12px/1 var(--f-m); color: var(--ink-3); }
.rooms-list { display: flex; flex-direction: column; gap: 6px; overflow: hidden; max-height: 372px; }
.room { display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto; column-gap: 10px; row-gap: 6px; padding: 10px 10px 10px 12px; border-radius: var(--r-2); background: rgba(2, 14, 17, 0.45); box-shadow: inset 0 0 0 1px var(--line); }
.room.is-feat { box-shadow: inset 0 0 0 1px rgba(46, 232, 138, 0.35); }
.room-t { display: flex; align-items: center; gap: 8px; min-width: 0; font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; }
.room-t .m { font: 600 10.5px/1 var(--f-m); padding: 4px 7px; border-radius: 999px; background: var(--s4); color: var(--ink-2); }
.room-t .m.arrows { background: rgba(255, 210, 94, 0.14); color: var(--gold); }
.room-t .mp { color: var(--ink-3); font-weight: 600; font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
.room-b { display: flex; align-items: center; gap: 4px; min-width: 0; }
.room-b .dot { width: 10px; height: 10px; }
.room-b .n { margin-left: 6px; font: 600 11.5px/1 var(--f-m); color: var(--ink-3); }
.room-p { grid-row: 1; grid-column: 2; font: 600 12px/1 var(--f-m); color: var(--sol); text-align: right; align-self: center; }
.room-a { grid-row: 2; grid-column: 2; display: flex; gap: 6px; justify-content: flex-end; }
.room-a button { font: 700 12px/1 var(--f-t); padding: 6px 10px; border-radius: 999px; background: var(--s4); color: var(--ink-2); }
.room-a button:hover { color: var(--ink); background: var(--s5); }
.room-a button.go { background: var(--acc); color: #032016; }
.room-a button.go:hover { filter: brightness(1.08); }
.rooms-foot { padding: 10px 4px 0; font-size: 12.5px; color: var(--ink-3); }
.pot { padding: 14px 16px; display: flex; flex-direction: column; gap: 9px; }
.pot-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pot-row span { font-size: 13.5px; color: var(--ink-2); }
.pot-row b { font: 600 15px/1 var(--f-m); color: var(--sol); }
.pot-rule { font-size: 12.5px; color: var(--ink-3); border-top: 1px solid var(--line); padding-top: 9px; }
.tape { grid-column: 1 / -1; display: flex; align-items: center; gap: 16px; min-width: 0; overflow: hidden; border-top: 1px solid var(--line); }
.tape-lab { flex: none; font: 700 11px/1 var(--f-t); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.tape-run { display: flex; gap: 26px; min-width: 0; overflow: hidden; white-space: nowrap; font-size: 13px; color: var(--ink-2); mask-image: linear-gradient(90deg, #000 85%, transparent); -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); }
.tape-run b { color: var(--ink); font-weight: 700; }
.tape-run em { font: 600 12px/1 var(--f-m); font-style: normal; color: var(--sol); }
.tape-empty { color: var(--ink-3); }

/* ---------------------------------------------------------------- in the game */
.hud { position: fixed; inset: 0; pointer-events: none; }
.hud button, .hud .touch { pointer-events: auto; }
.score { position: absolute; left: 16px; top: 14px; display: flex; flex-direction: column; gap: 4px; padding: 8px; border-radius: 14px; background: rgba(6, 26, 31, 0.78); box-shadow: var(--lit); min-width: 196px; }
.score li { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; padding: 5px 8px; border-radius: 9px; }
.score li.is-me { background: rgba(46, 232, 138, 0.1); box-shadow: inset 0 0 0 1px rgba(46, 232, 138, 0.28); }
.score li.is-out .bn { opacity: 0.4; text-decoration: line-through; text-decoration-color: rgba(255, 255, 255, 0.3); }
.score li.is-wait .bn { opacity: 0.55; }
.hud-top { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; }
.round-chip { display: flex; align-items: center; gap: 10px; height: 36px; padding: 0 16px; border-radius: 999px; background: rgba(6, 26, 31, 0.8); box-shadow: var(--lit); white-space: nowrap; }
.round-chip b { font: 400 17px/1 var(--f-d); }
.round-chip span { font: 600 11.5px/1 var(--f-m); color: var(--ink-2); }
.round-chip #h-first { color: var(--acc-l); }
.sudden { display: flex; align-items: center; gap: 10px; height: 28px; padding: 0 12px; border-radius: 999px; background: rgba(60, 10, 18, 0.82); box-shadow: inset 0 0 0 1px rgba(255, 93, 108, 0.45); font: 700 11.5px/1 var(--f-t); letter-spacing: 0.08em; text-transform: uppercase; color: #ffd0d5; }
.sudden i { width: 120px; height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.12); overflow: hidden; }
.sudden em { display: block; height: 100%; width: 100%; background: var(--hot); border-radius: 999px; transform-origin: left; }
.hud-right { position: absolute; right: 16px; top: 14px; display: flex; align-items: center; gap: 10px; }
.prize-line { display: flex; align-items: center; gap: 10px; height: 36px; padding: 0 14px; border-radius: 999px; background: rgba(6, 26, 31, 0.8); box-shadow: var(--lit); white-space: nowrap; }
.prize-line span { font: 700 10.5px/1 var(--f-t); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.prize-line b { font: 600 14px/1 var(--f-m); color: var(--sol); }
.prize-line em { font: 600 11px/1 var(--f-m); font-style: normal; color: var(--ink-3); }
.chip { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 8px; border-radius: 999px; background: rgba(6, 26, 31, 0.8); box-shadow: var(--lit); font-weight: 700; font-size: 13px; color: var(--ink-2); }
.dock { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; gap: 10px; }
.gauge { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 14px 0 7px; border-radius: 999px; background: rgba(6, 26, 31, 0.82); box-shadow: var(--lit); }
.gauge b { font: 400 15px/1 var(--f-d); color: var(--ink-2); }
.gauge-ball { position: relative; width: 34px; height: 34px; border-radius: 50%; background: rgba(255, 255, 255, 0.07); overflow: hidden; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.1); }
.gauge-ball i { position: absolute; left: 0; right: 0; bottom: 0; height: 100%; background: linear-gradient(180deg, #e9fff4, #7fd9ae 50%, #3e8f6c); transform-origin: bottom; transition: transform 0.08s linear; }
.gauge-ball.bow i { background: linear-gradient(180deg, #fff1c4, var(--gold)); }
.gauge.is-on { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.6), 0 0 20px -4px rgba(255, 255, 255, 0.35); }
.gauge.is-on b { color: var(--ink); }
.gauge.is-low .gauge-ball i { background: linear-gradient(180deg, #ffd0d5, var(--hot)); }
.feed { position: absolute; left: 16px; bottom: 18px; display: flex; flex-direction: column-reverse; gap: 5px; max-width: 360px; }
.feed p { padding: 6px 11px; border-radius: 10px; background: rgba(6, 26, 31, 0.72); font-size: 13px; color: var(--ink-2); animation: feedin 0.25s ease-out; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed p b { color: var(--ink); }
@keyframes feedin { from { opacity: 0; transform: translateY(6px); } }
.moment { position: absolute; left: 50%; top: 34%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 8px; opacity: 0; text-align: center; pointer-events: none; }
.moment b { font: 400 clamp(46px, 7vw, 96px)/1 var(--f-d); color: var(--mc, var(--ink)); text-shadow: 0 6px 0 rgba(0, 0, 0, 0.35), 0 0 40px rgba(0, 0, 0, 0.5); white-space: nowrap; }
.moment span { font: 600 16px/1.2 var(--f-t); color: var(--ink); text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7); padding: 7px 14px; border-radius: 999px; background: rgba(4, 22, 26, 0.6); }
.moment span:empty { display: none; }
.moment.is-on { animation: moment 1.5s cubic-bezier(.2, .9, .3, 1.2) forwards; }
.moment.is-count { animation: count 0.9s ease-out forwards; }
@keyframes moment { 0% { opacity: 0; transform: translate(-50%, -50%) scale(0.6); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1.06); } 22% { transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -54%) scale(1); } }
@keyframes count { 0% { opacity: 0; transform: translate(-50%, -50%) scale(1.5); } 20% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) scale(0.9); } }
.wait { position: absolute; left: 50%; bottom: 84px; transform: translateX(-50%); display: flex; align-items: center; gap: 12px; padding: 10px 18px; border-radius: 999px; background: rgba(6, 26, 31, 0.86); box-shadow: var(--lit); white-space: nowrap; }
.wait b { font: 400 17px/1 var(--f-d); color: var(--acc); }
.wait span { font-size: 14px; color: var(--ink-2); }
.touch { display: none; }
.t-only { display: none; }
.phone-only { display: none; }

.spec { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); pointer-events: none; }
.spec-bar { display: flex; align-items: center; gap: 20px; height: 46px; padding: 0 18px; border-radius: 999px; background: rgba(6, 26, 31, 0.84); box-shadow: var(--lit); white-space: nowrap; }
.spec-bar .brand-word { font-size: 20px; }
.spec-live { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--ink-2); }
.spec-keys { font-size: 13px; color: var(--ink-3); display: flex; gap: 4px; align-items: center; pointer-events: auto; }
.spec-btn { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: 999px; font: 600 13px/1 var(--f-t); color: var(--ink-2); background: transparent; cursor: pointer; }
.spec-btn:hover { background: rgba(255, 255, 255, 0.07); color: var(--ink); }

/* ---------------------------------------------------------------- sheets */
.veil { position: fixed; inset: 0; background: radial-gradient(80% 80% at 50% 45%, rgba(2, 12, 14, 0.55), rgba(2, 12, 14, 0.85)); z-index: 20; }
.sheet { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 21; width: min(560px, calc(100vw - 28px)); max-height: calc(100vh - 28px); overflow: auto; padding: 26px 26px 22px; border-radius: 24px; background: var(--plate); box-shadow: var(--lit), 0 30px 80px -20px rgba(0, 0, 0, 0.8); animation: sheetin 0.28s cubic-bezier(.2, .9, .3, 1.15); }
@keyframes sheetin { from { opacity: 0; transform: translate(-50%, -46%) scale(0.97); } }
.sheet-eyebrow { font: 600 12px/1 var(--f-m); color: var(--ink-3); margin-bottom: 8px; }
.sheet-title { font: 400 44px/1 var(--f-d); color: var(--ink); margin-bottom: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-title.small { font-size: 30px; margin-bottom: 12px; }
.sheet-sub { color: var(--ink-2); margin: -4px 0 16px; font-size: 14px; }
.sheet-actions { display: flex; align-items: center; gap: 18px; margin-top: 20px; flex-wrap: wrap; }
.sheet .field { margin-bottom: 12px; }
.lab { display: block; font: 700 11.5px/1 var(--f-t); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin: 6px 0 8px; }
.seg { display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(2, 14, 17, 0.6); box-shadow: inset 0 0 0 1px var(--line); margin-bottom: 12px; width: max-content; max-width: 100%; flex-wrap: wrap; }
.seg button { padding: 8px 14px; border-radius: 999px; font-weight: 700; font-size: 13.5px; color: var(--ink-3); }
.seg button.is-on { background: var(--acc); color: #032016; }
.check { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--acc); }
.err { min-height: 18px; color: var(--hot); font-size: 13.5px; font-weight: 600; }
.results { width: min(640px, calc(100vw - 28px)); }
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 12px; margin: 6px 0 14px; }
.pod { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; }
.pod-ball { width: 58px; height: 58px; border-radius: 50%; position: relative; box-shadow: inset 0 -6px 10px rgba(0, 0, 0, 0.35), inset 0 3px 4px rgba(255, 255, 255, 0.35), 0 8px 18px -6px rgba(0, 0, 0, 0.6); }
.pod-ball::before, .pod-ball::after { content: ''; position: absolute; top: 34%; width: 11px; height: 14px; border-radius: 50%; background: #fff; box-shadow: inset 3px -2px 0 3px #0b1416; }
.pod-ball::before { left: 30%; } .pod-ball::after { left: 54%; }
.pod.first .pod-ball { width: 74px; height: 74px; }
.pod-n { font-weight: 800; font-size: 15px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pod-step { width: 100%; border-radius: 14px 14px 6px 6px; background: linear-gradient(180deg, var(--s4), var(--s2)); box-shadow: var(--lit); display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 6px 12px; }
.pod.first .pod-step { min-height: 112px; background: linear-gradient(180deg, rgba(46, 232, 138, 0.28), var(--s2)); }
.pod.second .pod-step { min-height: 88px; } .pod.third .pod-step { min-height: 70px; }
.pod-step .pl { font: 400 22px/1 var(--f-d); color: var(--ink); }
.pod-step .pay { font: 600 13px/1 var(--f-m); color: var(--sol); }
.pod-step .pay.none { color: var(--ink-3); font-family: var(--f-t); font-weight: 600; font-size: 12px; }
.r-rest { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.r-rest li { display: grid; grid-template-columns: 26px 1fr auto; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 10px; background: rgba(2, 14, 17, 0.35); font-size: 13.5px; }
.r-rest li .pl { font: 600 12px/1 var(--f-m); color: var(--ink-3); }
.r-mine { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; padding: 12px 14px; border-radius: 14px; background: rgba(20, 241, 149, 0.07); box-shadow: inset 0 0 0 1px rgba(20, 241, 149, 0.25); }
.r-mine b { font: 600 18px/1 var(--f-m); color: var(--sol); }
.r-mine > span:first-child { color: var(--ink-2); font-size: 14px; }
.pay-steps { display: flex; gap: 6px; }
.pay-steps i { font: 700 11.5px/1 var(--f-t); font-style: normal; padding: 5px 9px; border-radius: 999px; background: rgba(255, 255, 255, 0.06); color: var(--ink-4); }
.pay-steps i.is-on { background: var(--acc); color: #032016; }
.r-next { margin-left: auto; font: 600 12px/1 var(--f-m); color: var(--ink-3); }
.menu-room { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; padding: 10px 12px; border-radius: 12px; background: rgba(2, 14, 17, 0.45); margin-bottom: 14px; font-size: 14px; color: var(--ink-2); }
.menu-room b { color: var(--ink); }
.menu-host { margin: 4px 0 14px; padding: 12px 14px 4px; border-radius: 14px; background: rgba(2, 14, 17, 0.4); }
.menu-row { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.field.slim { flex: 1; min-width: 160px; margin: 0; }
.field input[type=range] { height: 24px; padding: 0; background: none; box-shadow: none; accent-color: var(--acc); }
.menu-acct { margin-top: 12px; font-size: 13.5px; color: var(--ink-3); }
.how-list { display: flex; flex-direction: column; gap: 10px; counter-reset: h; }
.how-list li { display: grid; grid-template-columns: 30px 128px 1fr; gap: 10px; align-items: start; padding: 10px 12px; border-radius: 14px; background: rgba(2, 14, 17, 0.4); counter-increment: h; }
.how-list li::before { content: counter(h); display: flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; background: var(--acc); color: #032016; font: 400 15px/1 var(--f-d); }
.how-list b { font: 400 18px/1.25 var(--f-d); }
.how-list li > span { color: var(--ink-2); font-size: 14px; }
.how-arrows { margin-top: 12px; font-size: 14px; color: var(--ink-2); }
.how-arrows b { font: 400 15px/1 var(--f-d); color: var(--gold); margin-right: 8px; }
.toasts { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; z-index: 40; pointer-events: none; }
.toast { padding: 11px 16px; border-radius: 999px; background: rgba(10, 35, 40, 0.96); box-shadow: var(--lit), var(--drop); font-size: 14px; color: var(--ink); animation: feedin 0.2s ease-out; max-width: calc(100vw - 30px); }
.toast.bad { box-shadow: inset 0 0 0 1px rgba(255, 93, 108, 0.5), var(--drop); }
.toast.good { box-shadow: inset 0 0 0 1px rgba(46, 232, 138, 0.5), var(--drop); }
.nojs { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 18px; }
body.is-title .hud, body.is-title .spec { display: none; }
body.is-game .title, body.is-spec .title { display: none; }

/* ---------------------------------------------------------------- narrower screens: the rooms move under the play card */
@media (max-width: 1500px) {
  .title { grid-template-columns: minmax(360px, 410px) 1fr; column-gap: 24px; padding: 0 24px; }
  .col-right { display: none; }
  .headline { font-size: clamp(38px, 3.1vw, 46px); }
  .lede { margin: 14px 0 16px; }
}
@media (max-height: 800px) and (min-width: 821px) {
  .headline { font-size: 44px; } .lede { font-size: 14.5px; margin: 12px 0 14px; } .eyebrow { margin-bottom: 12px; }
  .play { gap: 9px; padding: 14px 16px 12px; } .field input { height: 40px; } .ballbtn { height: 52px; } .mode { padding: 9px 12px; }
}

/* ---------------------------------------------------------------- phones */
@media (max-width: 820px) {
  body { overflow: hidden; }
  .title { display: flex; flex-direction: column; overflow-y: auto; overflow-x: hidden; padding: 0 14px 20px; pointer-events: auto; }
  .title > * { flex: none; } .col { min-height: auto; }
  .bar { order: 0; } .col-mid { order: 1; } .col-left { order: 2; } .col-right { order: 3; } .tape { order: 4; }
  .eyebrow { font-size: 11px; }
  .bar { height: 56px; gap: 12px; }
  .bar-nav { display: none; }
  .ticker { display: none; }
  .ca-wrap { height: 34px; }
  .ca-pill { height: 34px; left: 0; right: 0; } .ca-lab { display: none; } .ca-addr { flex: 1; font-size: 11px; } .ca-addr:disabled { font-size: 11px; } .ca-link { padding: 6px 8px; font-size: 11px; }
  .live { font-size: 12.5px; }
  .col-mid { flex: none; height: 42vh; min-height: 280px; padding-top: 4px; }
  .bug { transform: scale(0.82); transform-origin: top center; }
  .bug-prize { display: none; }
  .col-left { padding: 6px 0 16px; }
  .headline { font-size: 34px; white-space: normal; }
  .lede { font-size: 14.5px; margin: 10px 0 14px; }
  .col-right { display: flex; padding: 0; }
  .rooms-list { max-height: none; }
  .tape { display: none; }
  .score { left: 8px; top: 8px; min-width: 0; padding: 5px; gap: 2px; transform: scale(0.86); transform-origin: top left; }
  .hud-top { top: 8px; }
  .round-chip #h-mode, .round-chip #h-first { display: none; }
  .hud-right { right: 8px; top: 8px; }
  .prize-line { display: none; }
  .dock { bottom: auto; top: 54px; transform: translateX(-50%) scale(0.86); }
  .feed { display: none; }
  .touch { display: block; position: absolute; left: 0; right: 0; bottom: 0; height: 38vh; }
  .stick { position: absolute; left: 22px; bottom: 26px; width: 150px; height: 150px; border-radius: 50%; background: rgba(255, 255, 255, 0.05); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.1); touch-action: none; }
  .stick i { position: absolute; left: 50%; top: 50%; width: 62px; height: 62px; margin: -31px 0 0 -31px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff 0 8%, #bdfadb 12%, #2ee88a 55%, #12925a); box-shadow: 0 6px 14px rgba(0, 0, 0, 0.45); }
  .tbtn { position: absolute; width: 84px; height: 84px; border-radius: 50%; font: 400 15px/1 var(--f-d); color: var(--ink); background: rgba(255, 255, 255, 0.08); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.14); touch-action: none; }
  .tbtn.up { right: 112px; bottom: 30px; }
  .tbtn.heavy { right: 20px; bottom: 96px; background: rgba(255, 255, 255, 0.12); }
  .tbtn.bow { right: 20px; bottom: 6px; width: 76px; height: 76px; color: var(--gold); }
  .tbtn.is-on { background: rgba(255, 255, 255, 0.32); }
  .moment b { font-size: 46px; }
  .results .podium { gap: 6px; } .sheet { padding: 20px 16px 16px; } .sheet-title { font-size: 34px; }
  .how-list li { grid-template-columns: 26px 1fr; } .how-list li > span { grid-column: 2; }
  .k-only, .dock kbd, .chip kbd, .ballbtn kbd, .spec-btn kbd { display: none; } .t-only { display: inline; } .phone-only { display: inline-flex; }
  .spec { left: 8px; right: 8px; transform: none; } .spec-bar { gap: 8px; padding: 0 6px 0 14px; justify-content: space-between; } .spec-bar .brand-word { display: none; } .spec-live { font-size: 13px; min-width: 0; overflow: hidden; text-overflow: ellipsis; } .spec-btn { padding: 0 9px; }
}
