/* GAME-03 shell and screens (exports/game03-reference/mockups: 390 px artboards). Square corners, no emoji,
   inline stroke SVG icons. Mobile first; >= 601 px: top nav, a centred column <= 520 px, the stage up to 1120 x 480 (COURT-01). */
/* INFRA-02 3.2: self-hosted fonts (web/fonts/, Fontsource 5.3.0 latin, SIL OFL 1.1 - web/fonts/OFL.txt); no third-party
   font host. Five faces: other weights map to the nearest one (Space Grotesk 600 -> 700, Inter 500 -> 400, 700 -> 600). */
@font-face { font-family: Silkscreen; src: url(fonts/silkscreen-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url(fonts/space-grotesk-latin-500-normal.woff2) format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url(fonts/space-grotesk-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: Inter; src: url(fonts/inter-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: Inter; src: url(fonts/inter-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
:root {
  --ground: #0B1020; --surface: #121A2F; --board: #05070F; --line: #243052; --line-2: #3A4A7A;
  --ink: #EEF2FA; --muted: #8C98B8; --faint: #4A5578; --accent: #D4FF3A; --accent-2: #EEFF9A;
  --clay: #D8703E; --glass: #39D0FF; --match: #1E7A48; --close: #B8861B; --cream: #F2E6C9; --olive: #5B6B3A;
  --olive-ink: #4A5A2C; --stamp-red: #A2471C;
  --c-mystery: #F2E6C9; --c-slamrun: #D4FF3A; --c-deuce: #D8703E; --c-tiebreak: #5B6B3A; --c-rally: #39D0FF;
  --led: 400 10px Silkscreen, ui-monospace, monospace;
}
* { box-sizing: border-box; }
html { background: var(--ground); }
body.g3 { margin: 0; background: var(--ground); color: var(--ink); font: 15px/1.45 Inter, system-ui, sans-serif; min-height: 100vh; display: flex; flex-direction: column; }
body.g3 a { color: var(--accent); }
.g3 .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.g3 :focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.g3 button { font: inherit; }
.g3 .silk { font: var(--led); letter-spacing: 1px; }


/* stage */
.g3-stagewrap { flex: none; background: var(--board); }
.g3-stage { position: relative; width: 100%; aspect-ratio: 7 / 3; background: var(--board); overflow: hidden; }   /* COURT-01: the new court's 1120 x 480 frame, 7:3 at every width */
.g3-stage .stage-box { position: absolute; inset: 0; }
.g3-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; image-rendering: pixelated; pointer-events: none; }
.g3-stage .tag { position: absolute; top: 8px; background: var(--board); border: 1px solid var(--line); padding: 4px 7px; font: var(--led); letter-spacing: 1px; z-index: 3; display: flex; align-items: center; gap: 5px; }
.g3-stage .tag.l { left: 8px; } .g3-stage .tag.r { right: 8px; }
.g3-stage .tag.bl { top: auto; bottom: 8px; left: 8px; }
.g3-live { width: 6px; height: 6px; background: var(--accent); display: inline-block; animation: g3blink 1s steps(2, start) infinite; }
@keyframes g3blink { to { visibility: hidden; } }
.stage-unsupported::after { content: 'The court needs WebGL. The game works without it.'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--muted); font: 13px Inter, sans-serif; }

/* umpire bar */
.g3-ump { flex: none; display: flex; align-items: center; gap: 10px; padding: 8px 16px; background: var(--board); border-bottom: 1px solid var(--line); min-height: 64px; }
.g3-ump img { width: 50px; height: 48px; object-fit: contain; image-rendering: pixelated; flex: none; }
.g3-ump .lab { font: 400 9px Silkscreen, monospace; letter-spacing: 2px; color: var(--accent); }
.g3-ump .line { font: 600 15px 'Space Grotesk', sans-serif; }
.g3-ump > div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }

/* main column */
.g3-main { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 12px 16px 16px; width: 100%; }
.g3-h1 { margin: 0; font: 700 22px 'Space Grotesk', sans-serif; letter-spacing: -.3px; }
.g3-rowhead { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.g3-muted { color: var(--muted); }

/* order of play */
/* PLAY-01 H4: the home page's main button - today's set (Deuce) */
.g3-lead { display: flex; width: 100%; font-size: 17px; }
@media (min-width: 1024px) { body.g3.today .g3-lead { min-height: 40px; font-size: 16px; } }   /* the desktop panel: the order of play still fits 1280 x 720 */
.g3-ct { display: flex; align-items: stretch; min-height: 60px; flex: none; border: 1px solid var(--line); background: var(--surface); color: var(--ink) !important; text-decoration: none; }
.g3-ct .num { width: 54px; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--ground); }
.g3-ct .num b { font: 700 22px Silkscreen, monospace; line-height: 1; }
.g3-ct .txt { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 6px 12px; gap: 2px; min-width: 0; }
.g3-ct .t1 { font: 700 16px 'Space Grotesk', sans-serif; }
.g3-ct .t2 { font: 400 12px Inter, sans-serif; color: var(--muted); }
.g3-ct .act { width: 92px; flex: none; display: flex; align-items: center; justify-content: center; }
.g3-play { border: 1px solid var(--accent); color: var(--accent); font: 700 14px 'Space Grotesk', sans-serif; padding: 8px 13px; min-height: 44px; display: inline-flex; align-items: center; }
.g3-play.solid { background: var(--accent); color: var(--ground); animation: g3pulse 1.6s ease-in-out infinite; }
@keyframes g3pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(212,255,58,.55); } 50% { box-shadow: 0 0 0 6px rgba(212,255,58,0); } }
.g3-stamp { transform: rotate(-8deg); border: 3px solid currentColor; padding: 3px 6px; font: 700 13px Silkscreen, monospace; letter-spacing: 1px; white-space: nowrap; }
.g3-ct.locked { border-style: dashed; background: transparent; }
.g3-ct.locked .num { background: transparent !important; color: var(--faint); border-right: 1px dashed var(--line); }
.g3-ct.locked .t1, .g3-ct.locked .t2 { color: var(--muted); }
.g3-lock { display: flex; align-items: center; gap: 5px; font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.g3-lock .again { display: flex; flex-direction: column; gap: 3px; text-align: right; letter-spacing: .5px; } .g3-lock .again span { white-space: nowrap; }   /* GAME-07 3.6 */
.g3-ct.locked .act { width: auto; padding: 0 10px 0 6px; }
.g3-ct.off { opacity: .55; }

/* free counter + ticket */
.g3-free { display: flex; align-items: center; gap: 10px; padding: 4px 2px 0; flex-wrap: wrap; }
.g3-free .balls { display: flex; gap: 6px; }
.g3-ball { animation: g3bounce 1.2s ease-in-out infinite; }
@keyframes g3bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
.g3-ticket { display: flex; align-items: center; gap: 12px; background-color: var(--cream); color: var(--ground); padding: 10px 12px 10px 20px; flex: none;
  background-image: radial-gradient(circle at 0 50%, var(--ground) 0 6px, transparent 6.5px); background-size: 14px 14px; background-repeat: repeat-y; background-position: 0 3px; text-decoration: none; }
.g3-ticket .k { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--olive-ink); }
.g3-ticket .h { font: 700 15px 'Space Grotesk', sans-serif; line-height: 1.2; color: var(--ground); }
.g3-ticket .go { flex: none; min-height: 44px; padding: 0 14px; border: 0; background: var(--ground); color: var(--accent); font: 700 14px 'Space Grotesk', sans-serif; display: flex; align-items: center; }
.g3-ticket.big { flex-direction: column; align-items: stretch; gap: 10px; padding: 14px 14px 14px 22px; }
.g3-ticket.big .h { font-size: 19px; }
.g3-ticket.big .b { font: 400 13px/1.4 Inter, sans-serif; color: var(--olive-ink2, #3A4220); }
.g3-ticket.big .go { min-height: 48px; justify-content: center; font-size: 15px; text-decoration: none; }


/* buttons */
.g3-btn { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line-2); background: transparent; color: var(--ink) !important; text-decoration: none; font: 600 15px 'Space Grotesk', sans-serif; padding: 0 14px; cursor: pointer; }
.g3-btn.acid { background: var(--accent); color: var(--ground) !important; border-color: var(--accent); font-weight: 700; }
.g3-btn:disabled { opacity: .45; cursor: default; }

@media (min-width: 601px) {
  .g3-stagewrap { display: flex; justify-content: center; border-bottom: 1px solid var(--line); }
  .g3-stage { max-width: 1120px; }
  .g3-ump { justify-content: center; }
  .g3-ump > div { max-width: 520px; flex: 1; }
  .g3-main { max-width: 520px; margin: 0 auto; }
}
@media (max-width: 370px) {
  .g3-ct .act { width: 84px; }
}
body.g3 { padding-bottom: 0; }
/* INFRA-02 3.12: legal links at the foot of every g3 page */
.g3-foot { border-top: 1px solid var(--line); padding: 14px 16px 18px; margin-top: 24px; }
.g3-foot nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; font-size: 12px; }
.g3-foot a { color: var(--muted); text-underline-offset: 3px; } .g3-foot a:hover { color: var(--ink); }
@media (prefers-reduced-motion: reduce) {
  .g3-play.solid, .g3-ball, .g3-live { animation: none; }
}

/* ---------- mode pages (SlamRun / Deuce / Tiebreak mockups) */
.g3-mode .g3-ump { min-height: 52px; padding: 6px 16px; }
.g3-mode .g3-ump img { width: 50px; height: 48px; }   /* FIX-02: at least 48 px tall on a phone (was 40) */
.g3-mode .g3-ump .line { font-size: 14px; }
.g3-draw { flex: none; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--board); }
.g3-draw .cells { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 3px; max-width: 1120px; margin: 0 auto; }
.g3-draw .c { height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; position: relative; background: var(--surface); color: var(--muted); }
.g3-draw .c .r { font: 400 10px Silkscreen, monospace; } .g3-draw .c .p { font: 600 9px Inter, sans-serif; }
.g3-draw .c .q { font: 400 8px Silkscreen, monospace; letter-spacing: .5px; }   /* GAME-07 3.5: the points of the round (PLAY-01: no money above them) */
.g3-draw .c.done { background: var(--accent); color: var(--ground); }
.g3-draw .c.now { border: 2px solid var(--accent); background: var(--ground); color: var(--accent); }
.g3-draw .c.now .p { color: var(--ink); }
.g3-draw .c.now::after { content: ''; position: absolute; top: 3px; right: 3px; width: 4px; height: 4px; background: var(--accent); animation: g3blink 1s steps(2, start) infinite; }
.g3-draw .c.lost { background: var(--clay); color: var(--ground); }
/* PLAY-01 S2-S3: the strip shows points only; the two safe steps carry a small lock + SAFE, a run that took its points
   ends on a cell in the accent's outline; TAKE sits above the helps, the free-shot line in its place on a safe step */
.g3-draw .c .s { display: inline-flex; align-items: center; gap: 2px; font: 400 7px Silkscreen, monospace; letter-spacing: .5px; }
.g3-draw .c.safe:not(.done):not(.now):not(.lost) { box-shadow: inset 0 0 0 1px var(--line); }
.g3-draw .c.cashed { border: 2px solid var(--accent); background: var(--ground); color: var(--accent); }
.g3-take { align-self: center; min-width: 180px; }
.g3-free { text-align: center; color: var(--accent); }
.g3-clockbar { height: 4px; flex: none; background: var(--line); position: relative; }
.g3-clockbar span { position: absolute; left: 0; top: 0; bottom: 0; display: block; background: var(--accent); }
.g3-clockbar span.late { background: var(--clay); }
.g3-label { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.g3-q { margin: 0 0 6px; font: 700 23px/1.2 'Space Grotesk', sans-serif; letter-spacing: -.3px; }
.g3-opts { display: flex; flex-direction: column; gap: 6px; }
.g3-opt { position: relative; overflow: hidden; min-height: 50px; display: flex; align-items: center; gap: 12px; padding: 0 12px 0 0; background: var(--surface); border: 1px solid var(--line-2); color: var(--ink); text-align: left; cursor: pointer; width: 100%; }
.g3-opt .L { position: relative; width: 44px; align-self: stretch; flex: none; background: var(--board); color: var(--accent); display: flex; align-items: center; justify-content: center; font: 400 15px Silkscreen, monospace; }
.g3-opt .N { position: relative; flex: 1; font: 600 17px 'Space Grotesk', sans-serif; }
.g3-opt .V { position: relative; font: 400 12px Silkscreen, monospace; color: var(--accent); }
.g3-opt .bar { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(212,255,58,.14); display: block; }
.g3-opt.removed { background: var(--ground); border: 1px dashed var(--line); color: var(--faint); cursor: default; }
.g3-opt.removed .L { background: transparent; color: var(--faint); } .g3-opt.removed .N { text-decoration: line-through; }
.g3-opt.right { background: var(--match); border-color: var(--match); } .g3-opt.right .N { font-weight: 700; }
.g3-opt.wrong { background: var(--clay); border-color: var(--clay); color: var(--ground); } .g3-opt.wrong .L { color: var(--clay); }
.g3-opt.dim { background: var(--ground); border-color: var(--line); color: var(--muted); } .g3-opt.dim .L { background: transparent; color: var(--muted); }
.g3-opt .tag { position: relative; font: 400 11px Silkscreen, monospace; letter-spacing: 1px; }
.g3-helps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.g3-help { min-height: 54px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; background: var(--board); border: 1px solid var(--accent); color: var(--accent); cursor: pointer; }
.g3-help .k { display: flex; align-items: center; gap: 6px; font: 400 11px Silkscreen, monospace; letter-spacing: 1px; }
.g3-help .s { font: 500 11px Inter, sans-serif; color: var(--ink); }
.g3-help:disabled { background: var(--ground); border: 1px dashed var(--line); color: var(--faint); cursor: default; }
.g3-help:disabled .k { text-decoration: line-through; } .g3-help:disabled .s { color: var(--faint); }
.g3-coach { display: flex; gap: 10px; align-items: center; padding: 8px 12px; background: var(--cream); color: var(--ground); }
.g3-coach .k { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--olive-ink); display: block; }
.g3-coach .t { font: 700 14px 'Space Grotesk', sans-serif; }
.g3-result { display: flex; align-items: center; gap: 16px; padding: 12px 14px; background: var(--board); border: 1px solid var(--line); }
.g3-result .ti { font: 700 17px 'Space Grotesk', sans-serif; display: block; } .g3-result .su { font: 400 13px Inter, sans-serif; color: var(--muted); display: block; }
.g3-bigstamp { display: inline-block; flex: none; border: 4px solid; padding: 6px 10px; font: 700 22px Silkscreen, monospace; letter-spacing: 2px; transform: rotate(-7deg); animation: g3stamp .38s cubic-bezier(.2,1.5,.4,1) both; white-space: nowrap; }
@keyframes g3stamp { from { transform: rotate(-7deg) scale(1.9); opacity: 0; } to { transform: rotate(-7deg) scale(1); opacity: 1; } }
.g3-in { animation: g3in .3s ease-out both; }
@keyframes g3in { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }
.g3-btns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.g3-btns.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g3-million { background: var(--accent); color: var(--ground); font: 400 12px Silkscreen, monospace; letter-spacing: 2px; padding: 6px 10px; text-align: center; animation: g3in .3s ease-out both; }
/* Deuce scoreboard */
.g3-board { flex: none; margin: 10px 12px 0; padding: 8px 12px 10px; background: var(--board); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.g3-board .grid { display: grid; grid-template-columns: minmax(0, 1fr) 64px 78px; column-gap: 6px; row-gap: 4px; align-items: center; }
.g3-board .h { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); text-align: center; }
.g3-board .who { display: flex; align-items: center; gap: 8px; font: 400 15px Silkscreen, monospace; letter-spacing: 1px; }
.g3-board .who.opp { color: #C9D2EA; }
.g3-board .dot { width: 8px; height: 8px; display: inline-block; }
.g3-board .dot.on { background: var(--accent); }
.g3-board .num { height: 32px; background: var(--ground); display: flex; align-items: center; justify-content: center; font: 400 24px Silkscreen, monospace; }
.g3-board .num.acid { color: var(--accent); }
.g3-board .foot { display: flex; align-items: center; gap: 8px; }
.g3-banner { padding: 5px 9px; font: 400 12px Silkscreen, monospace; letter-spacing: 2px; background: var(--surface); color: var(--ink); }
.g3-banner.hot { background: var(--clay); color: var(--ground); animation: g3blink 1s steps(2, start) 3; }
.g3-banner.good { background: var(--accent); color: var(--ground); }
.g3-banner.sm { padding: 4px 8px; font-size: 11px; letter-spacing: 1px; }   /* Tiebreak (mockup) */
.g3-board .stats { margin-left: auto; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.g3-duel { position: relative; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.g3-card { min-height: 190px; padding: 10px 8px; display: flex; flex-direction: column; align-items: center; gap: 4px; background: var(--surface); border: 2px solid var(--line-2); color: var(--ink); text-align: center; cursor: pointer; }
.g3-card .sil { height: 96px; display: flex; align-items: flex-end; justify-content: center; }
.g3-card .sil img { height: 96px; width: auto; image-rendering: pixelated; }
.g3-card .nm { font: 700 16px/1.2 'Space Grotesk', sans-serif; } .g3-card .mt { font: 400 11px Inter, sans-serif; opacity: .85; }
.g3-card .val { margin-top: 2px; padding: 3px 8px; background: var(--board); color: var(--ink); font: 400 13px Silkscreen, monospace; }
.g3-card.right { background: var(--match); border-color: var(--match); } .g3-card.wrong { background: var(--clay); border-color: var(--clay); color: var(--ground); }
.g3-card.other { opacity: .75; } .g3-card:disabled { cursor: default; }
/* GAME-04: a return point is a trio - the third answer under the two, the same width */
.g3-duel.trio .g3-card { min-height: 150px; } .g3-duel.trio .g3-card .sil, .g3-duel.trio .g3-card .sil img { height: 72px; }
/* GAME-07 3.2: a text card of an authored question - the option large, no silhouette */
.g3-card.text { justify-content: center; min-height: 132px; padding: 14px 12px; }
.g3-card.text .nm { font: 700 20px/1.2 'Space Grotesk', sans-serif; overflow-wrap: anywhere; }
.g3-duel.trio .g3-card.text { min-height: 96px; } .g3-duel.trio .g3-card.text .nm { font-size: 18px; }
.g3-duel:has(.g3-card.text) .g3-vs { top: calc(50% - 17px); }
.g3-duel.trio .g3-card:nth-child(3) { grid-column: 1 / -1; justify-self: center; width: calc(50% - 5px); }
/* WEB-03 3.4: the key of an answer - a small badge on the card, shown in the desktop interface only */
.g3-key { display: none; }
/* GAME-07 3.5 / 3.6: the rules card of a mode page, the lock panel (no free match left), «How it works» */
.g3-rules { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; background: var(--board); border: 1px solid var(--line); }
.g3-rules p { margin: 0; font: 400 14px/1.45 Inter, sans-serif; color: var(--ink); }
.g3-rules .g3-btn { margin-top: 4px; }
.g3-linkbtn { align-self: center; min-height: 44px; padding: 0 12px; background: none; border: 0; color: var(--accent); font: 400 11px Silkscreen, monospace; letter-spacing: 1px; text-decoration: underline; cursor: pointer; }
.lock-panel { display: flex; flex-direction: column; gap: 8px; padding: 14px; background: var(--ground); border: 2px solid var(--accent); color: var(--ink); }
.lock-panel .lp-label { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--accent); }
.lock-panel .lp-title { margin: 0; font: 700 20px/1.2 'Space Grotesk', sans-serif; letter-spacing: -.2px; }
.lock-panel .lp-text { margin: 0; font: 400 14px/1.45 Inter, sans-serif; }
.lock-panel .lp-btn { display: flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 14px; background: var(--accent); color: var(--ground) !important; font: 700 15px 'Space Grotesk', sans-serif; text-decoration: none; text-align: center; }
/* GAME-07 3.4: the set's length - two big buttons before the first point */
.g3-duel.choice { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3-len { position: relative; min-height: 150px; padding: 18px 12px 14px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; background: var(--surface); border: 2px solid var(--line-2); color: var(--ink); text-align: center; cursor: pointer; }
.g3-len .nm { font: 400 17px Silkscreen, monospace; letter-spacing: 1px; } .g3-len .mt { font: 400 13px/1.35 Inter, sans-serif; opacity: .9; }
.g3-len.sel { border-color: var(--accent); } .g3-len .tag { position: absolute; top: 0; right: 0; padding: 3px 6px; background: var(--accent); color: var(--ground); font: 400 9px Silkscreen, monospace; letter-spacing: 1px; }
.g3-len:hover { border-color: var(--cream); }
@media (max-width: 420px) { .g3-len { min-height: 168px; padding: 20px 8px 12px; } .g3-len .nm { font-size: 15px; } }
.g3-vs { position: absolute; left: 50%; top: 44px; transform: translateX(-50%); width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; background: var(--clay); color: var(--ground); font: 400 12px Silkscreen, monospace; pointer-events: none; }
.g3-dclock { position: relative; height: 8px; background: var(--line); overflow: hidden; }
.g3-dclock span { position: absolute; left: 0; top: 0; bottom: 0; display: block; background: var(--cream); }
.g3-dclock i { position: absolute; left: 25%; top: 0; bottom: 0; width: 2px; background: var(--ground); display: block; }
@media (prefers-reduced-motion: reduce) { .g3-bigstamp, .g3-in, .g3-million, .g3-banner.hot { animation: none; } }
@media (min-width: 601px) { .g3-board { width: calc(100% - 24px); max-width: 520px; margin: 10px auto 0; } }
/* Tiebreak */
.g3-tbrow { display: flex; align-items: center; gap: 10px; }
.g3-tbrow .who { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; flex: 1; min-width: 0; }
.g3-tbrow .who.r { align-items: flex-end; }
.g3-tbrow .lab { font: 400 14px Silkscreen, monospace; letter-spacing: 1px; }
.g3-pips { display: flex; gap: 3px; } .g3-pips i { width: 10px; height: 10px; display: block; background: var(--line); }
.g3-pips i.on { background: var(--accent); } .g3-pips i.st { background: var(--cream); }
.g3-tbnum { width: 54px; height: 50px; background: var(--ground); display: flex; align-items: center; justify-content: center; font: 400 34px Silkscreen, monospace; }
.g3-asker { display: flex; align-items: center; gap: 10px; }
.g3-asker .face { flex: none; width: 56px; height: 56px; background: var(--surface); border: 1px solid var(--line-2); display: block; position: relative; overflow: hidden; box-sizing: content-box; }
.g3-asker .face img { image-rendering: pixelated; display: block; }
.g3-spin { transform-box: view-box; transform-origin: 20px 20px; transform: rotate(90deg); animation: g3spin 1.8s cubic-bezier(.15,.7,.2,1) both; }
@keyframes g3spin { from { transform: rotate(0deg); } to { transform: rotate(1170deg); } }   /* ends pointing at the asker */
.g3-cheer { animation: g3cheer .5s ease-out 2; }
@keyframes g3cheer { 50% { transform: translateY(-6px); } }
.g3-qcard { background: var(--cream); color: var(--ground); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.g3-qcard .k { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--olive-ink); }
.g3-qcard p, .g3-qcard h1 { margin: 0; font: 600 17px/1.35 'Space Grotesk', sans-serif; letter-spacing: 0; }
.g3-tbform { display: flex; flex-direction: column; gap: 6px; }
.g3-tbform label { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.g3-tbform .row { display: flex; gap: 8px; }
.g3-tbform input { flex: 1; min-width: 0; height: 48px; padding: 0 12px; background: var(--board); border: 1px solid var(--line-2); color: var(--ink); font: 500 16px Inter, sans-serif; outline-color: var(--accent); }
.g3-note { padding: 8px 12px; background: var(--surface); border: 1px solid var(--line-2); font: 400 12px Inter, sans-serif; }
@media (prefers-reduced-motion: reduce) { .g3-spin, .g3-cheer { animation: none; } }
/* My day / Career / Archive */
.g3-poster { background: var(--cream); color: var(--ground); padding: 14px 16px 12px; position: relative; overflow: hidden;
  background-image: radial-gradient(rgba(74,90,44,.14) 1px, transparent 1.2px); background-size: 6px 6px; }
.g3-poster .k { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; color: var(--olive-ink); }
.g3-poster h1 { margin: 6px 0 8px; font: 700 34px/1.05 'Space Grotesk', sans-serif; letter-spacing: -.5px; max-width: 64%; }
.g3-poster .pts { display: inline-block; background: var(--ground); color: var(--accent); font: 400 26px Silkscreen, monospace; padding: 8px 12px; }
.g3-poster .s { font: 400 13px Inter, sans-serif; color: #3A4220; margin-top: 8px; }
.g3-poster .hero { position: absolute; right: 6px; bottom: 0; height: 88%; image-rendering: pixelated; }
.g3-poster .well { position: absolute; right: 24px; top: 22px; transform: rotate(-12deg); border: 3px solid var(--stamp-red); color: var(--stamp-red); font: 700 13px Silkscreen, monospace; padding: 4px 8px; background: rgba(242,230,201,.85); }
.g3-sum { display: flex; align-items: stretch; min-height: 58px; border: 1px solid var(--line); background: var(--surface); }
.g3-sum.left { border-style: dashed; background: transparent; }
.g3-sum .num { width: 50px; flex: none; display: flex; align-items: center; justify-content: center; font: 700 18px Silkscreen, monospace; color: var(--ground); }
.g3-sum.left .num { color: var(--muted); border-right: 1px dashed var(--line); }
.g3-sum .txt { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 6px 12px; gap: 1px; min-width: 0; }
.g3-sum .t1 { font: 700 15px 'Space Grotesk', sans-serif; } .g3-sum .t2 { font: 400 12px Inter, sans-serif; color: var(--muted); }
.g3-sum .act { display: flex; align-items: center; gap: 10px; padding-right: 12px; }
.g3-sum .pts { font: 400 14px Silkscreen, monospace; color: var(--accent); }
.g3-sum .st { transform: rotate(-6deg); border: 2px solid currentColor; padding: 2px 5px; font: 700 10px Silkscreen, monospace; letter-spacing: 1px; }
.g3-panel { border: 1px solid var(--line); background: var(--board); padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.g3-prog { height: 10px; background: var(--line); position: relative; } .g3-prog span { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); display: block; }
.g3-prog i { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--cream); display: block; }
.g3-rungs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.g3-rungs span { border: 1px solid var(--line-2); padding: 8px 4px; text-align: center; font: 400 8px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.g3-rungs span.on { background: var(--accent); color: var(--ground); border-color: var(--accent); } .g3-rungs span.next { border-style: dashed; }
.g3-rungs span.locked { background: var(--board); border-color: var(--line); } /* GAME-04: World No. 1 needs the weekly ranking (server) */
.g3-week { display: flex; gap: 4px; } .g3-week span { width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; font: 400 8px Silkscreen, monospace; border: 1px dashed var(--line-2); color: var(--muted); }
.g3-week span.on { background: var(--clay); border: 0; color: var(--ground); } .g3-week span.today { background: var(--accent); border: 0; color: var(--ground); }
.g3-sheet { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.g3-sheet a { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--ink) !important; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; }
.g3-sheet img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border: 1px solid var(--line); background: var(--board); }
dialog.g3-dlg { background: var(--ground); color: var(--ink); border: 1px solid var(--line-2); padding: 16px; width: min(560px, calc(100vw - 32px)); max-height: 86vh; }
dialog.g3-dlg::backdrop { background: rgba(5,7,15,.7); }
.g3-ladder { display: flex; flex-direction: column; gap: 8px; }
.g3-rung { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); background: var(--surface); }
.g3-rung.locked { border-style: dashed; background: transparent; color: var(--muted); }
.g3-rung.cur { border: 2px solid var(--accent); flex-direction: column; align-items: stretch; }
.g3-rung.done { background: var(--board); }
.g3-rung .n { font: 400 11px Silkscreen, monospace; letter-spacing: 2px; display: flex; align-items: center; gap: 10px; }
.g3-rung .r { margin-left: auto; font: 400 13px Inter, sans-serif; color: var(--muted); }
.g3-bars { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; align-items: end; height: 110px; }
.g3-bars span { display: block; background: var(--accent); min-height: 3px; position: relative; }
.g3-bars span.rest { background: var(--line-2); height: 3px !important; }
.g3-bars b { position: absolute; top: -18px; left: 50%; transform: translateX(-50%); font: 400 9px Silkscreen, monospace; color: var(--ink); font-weight: 400; white-space: nowrap; }
.g3-modecard { border: 1px solid var(--line); background: var(--surface); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.g3-modecard .h { display: flex; align-items: center; gap: 8px; font: 700 15px 'Space Grotesk', sans-serif; }
.g3-modecard .h i { width: 10px; height: 10px; display: inline-block; } .g3-modecard .h b { margin-left: auto; font: 400 13px Silkscreen, monospace; }
.g3-modecard .s { font: 400 12px Inter, sans-serif; color: var(--muted); }
.g3-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.g3-tile { border: 1px solid var(--line); background: var(--surface); padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.g3-tile b { font: 400 24px Silkscreen, monospace; font-weight: 400; } .g3-tile b.a { color: var(--accent); } .g3-tile span { font: 400 13px Inter, sans-serif; color: var(--muted); }
.g3-arch { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border: 1px solid var(--line); background: var(--surface); flex-wrap: wrap; }
.g3-arch .d { font: 400 10px Silkscreen, monospace; letter-spacing: 1px; width: 92px; flex: none; }
.g3-arch .m { display: flex; gap: 6px; flex-wrap: wrap; }
.g3-arch .m a, .g3-arch .m span { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; font: 400 10px Silkscreen, monospace; text-decoration: none; color: var(--ground) !important; padding: 0 8px; }
.g3-arch .m span { opacity: .35; }


/* GAME-03 skin of the ART-03 mode pages (Mystery, Rally): the mode header, the stage full width on phones, the umpire
   bar of the other mode pages, 16 px side padding (app.css .page zeroed the .wrap padding). */
body.g3m { --led: Silkscreen, ui-monospace, monospace; }   /* app.css uses --led as a font family */
.g3m .g3-mhead { position: relative; z-index: 5; }
.g3m .g3m-tools { display: flex; align-items: center; gap: 4px; }
.g3m .g3m-tools .icon-btn { width: 44px; height: 44px; border: 0; background: none; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.g3m .g3m-tools .pill { padding: 7px 8px; background: none; border: 1px solid var(--line); color: var(--muted); font: 400 10px Silkscreen, monospace; letter-spacing: 1px; white-space: nowrap; }
.g3m .wrap.page { padding: 0 16px 32px; gap: 12px; }
.g3m .tabs, .g3m .bottom-bar { display: none; }
.g3m .stage { border-left: 0; border-right: 0; border-top: 0; }
.g3m .umpire { margin-top: -12px; border: 0; border-bottom: 1px solid var(--line); padding: 8px 16px; min-height: 64px; gap: 0 10px;
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; align-items: center; }
.g3m .umpire .umpire-portrait { grid-row: 1 / 3; width: 50px; height: 48px; margin: 0; align-self: center; }
.g3m .umpire .umpire-portrait img { width: 50px; height: 48px; }
.g3m .umpire .umpire-label { display: none; }
.g3m .umpire .who { font: 400 9px Silkscreen, monospace; letter-spacing: 2px; color: var(--accent); align-self: end; }
.g3m .umpire .line { font: 600 15px 'Space Grotesk', sans-serif; align-self: start; }
.g3m .umpire .meta { display: none; }
.g3m h1 { font-size: 22px; line-height: 1.15; }
@media (max-width: 600px) {
  .g3m .wrap.page { padding-top: 0; }
  .g3m .stage, .g3m .umpire { margin-left: -16px; margin-right: -16px; width: auto; }
  .g3m .g3m-tools .pill { display: none; }
  .g3m .sound-btn { width: 44px; height: 44px; bottom: 4px; right: 4px; }   /* tap target 44 px */
}
@media (min-width: 601px) {
  .g3m .wrap.page { padding-top: 16px; }
  .g3m .stage { border: 1px solid var(--line); }
  .g3m .umpire { border: 1px solid var(--line); }
}

/* INFRA-02 3.9: Rankings (board Leaderboard.dc.html) and Your player (board Avatar.dc.html) */
.g3-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.rk-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.rk-tabs button, .rk-modes button, .pl-tabs button { min-height: 44px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 400 11px Silkscreen, monospace; letter-spacing: 1px; cursor: pointer; }
.rk-tabs button[aria-pressed="true"], .pl-tabs button[aria-pressed="true"] { background: var(--accent); color: var(--ground); border-color: var(--accent); }
.rk-modes { display: flex; flex-wrap: wrap; gap: 4px; }
.rk-modes button { min-height: 32px; padding: 0 8px; background: transparent; color: var(--muted); border-color: var(--line-2); font-size: 9px; }
.rk-modes button[aria-pressed="true"] { background: var(--cream); color: var(--ground); border-color: var(--cream); }
.rk-podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; align-items: end; min-height: 150px; margin-top: 6px; }
.rk-pod { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; position: relative; }
.rk-pod .rk-name { font: 600 12px Inter, sans-serif; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-pod .rk-sub { font: 400 9px Silkscreen, monospace; color: var(--muted); letter-spacing: 1px; white-space: nowrap; }
.rk-base { width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 4px; color: var(--ground); }
.rk-pod.p1 .rk-base { background: var(--accent); min-height: 66px; } .rk-pod.p2 .rk-base { background: var(--cream); min-height: 54px; } .rk-pod.p3 .rk-base { background: var(--clay); min-height: 46px; }
.rk-rank { font: 400 10px Silkscreen, monospace; }
.rk-crown { margin-bottom: -6px; position: relative; z-index: 1; }
.rk-av { width: 30px; height: 30px; flex: none; background: var(--surface); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.rk-av.big { width: 52px; height: 52px; border: 2px solid var(--line-2); } .rk-av.big.first { border-color: var(--accent); }
.rk-av.big img { width: 48px; height: 48px; }
.rk-flag { font: 400 11px Silkscreen, monospace; color: var(--ink); }
.rk-rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.rk-row { min-height: 48px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.rk-row.you { border: 1px solid var(--accent); padding: 0 6px; }
.rk-r { width: 34px; font: 400 13px Silkscreen, monospace; color: var(--muted); text-align: right; flex: none; }
.rk-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.rk-n { font: 600 14px 'Space Grotesk', sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-t { display: flex; align-items: center; gap: 4px; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.rk-f { color: var(--muted); }
.rk-v { font: 400 13px Silkscreen, monospace; white-space: nowrap; }
.rk-foot, .rk-emptyline { font-size: 12px; color: var(--muted); margin: 6px 0 0; }
.rk-emptyline { grid-column: 1 / -1; align-self: center; text-align: center; }
.rk-note { font-size: 12px; color: var(--muted); margin: 0; }
.rk-you { position: sticky; bottom: 62px; z-index: 4; min-height: 64px; display: flex; align-items: center; gap: 10px; padding: 8px 12px; margin: 8px -16px 0; background: var(--surface); border-top: 2px solid var(--accent); }
@media (min-width: 601px) { .rk-you { bottom: 0; margin: 8px 0 0; } }
.rk-yr { font: 400 12px Silkscreen, monospace; color: var(--accent); white-space: nowrap; }
.rk-yw { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.rk-y1 { font: 700 15px 'Space Grotesk', sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-y2 { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.rk-yv { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; font: 400 15px Silkscreen, monospace; color: var(--accent); }
.rk-ybtn { min-height: 28px; display: inline-flex; align-items: center; padding: 0 8px; background: var(--accent); color: var(--ground) !important; text-decoration: none; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; }
button.rk-ybtn { border: 0; cursor: pointer; }   /* INFRA-03: the way to the sheet "Join the rankings" is a button */
.rk-empty { display: flex; flex-direction: column; gap: 12px; padding-top: 24px; } .rk-empty p { color: var(--muted); margin: 0; }
.pl-sec { display: flex; flex-direction: column; gap: 8px; }
.pl-sec h2 { margin: 0; font: 700 18px 'Space Grotesk', sans-serif; }
.pl-label { font: 400 10px Silkscreen, monospace; letter-spacing: 2px; color: var(--muted); }
.pl-preview { display: flex; align-items: center; gap: 12px; padding: 12px; background: var(--surface); border: 1px solid var(--line); }
.pl-preview .rk-av.big { width: 64px; height: 64px; } .pl-preview .rk-av.big img { width: 60px; height: 60px; }
.pl-input { min-height: 48px; padding: 0 12px; background: var(--board); border: 1px solid var(--line-2); color: var(--ink); font: 600 16px 'Space Grotesk', sans-serif; width: 100%; box-sizing: border-box; }
.pl-status { font-size: 13px; min-height: 18px; margin: 0; }
.pl-status.ok { color: var(--accent); } .pl-status.bad { color: var(--clay); } .pl-status.wait { color: var(--muted); }
.pl-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.pl-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pl-pick { min-height: 72px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 6px 2px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; font: 400 8px Silkscreen, monospace; letter-spacing: 1px; }
.pl-pick[aria-pressed="true"] { border-color: var(--accent); }
.pl-pick.locked { color: var(--muted); } .pl-pick.locked img { filter: grayscale(1) brightness(.55); }
.rk-modes[hidden], .pl-sports[hidden] { display: none; }
.pl-pick > span { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; text-align: center; }
.pl-pick .rule { font: 400 10px Inter, sans-serif; letter-spacing: 0; text-align: center; color: var(--muted); }
.pl-pick .unl { color: var(--accent); }
.pl-sports { display: flex; gap: 4px; }
.pl-flags { max-height: 220px; overflow: auto; border: 1px solid var(--line); }
.pl-flag { width: 100%; min-height: 44px; display: flex; align-items: center; gap: 10px; padding: 0 12px; background: transparent; border: 0; border-bottom: 1px solid var(--line); color: var(--ink); text-align: left; cursor: pointer; font: 14px Inter, sans-serif; }
.pl-flag[aria-pressed="true"] { background: var(--select, #1C2744); }
.pl-flag b { font: 400 11px Silkscreen, monospace; width: 36px; color: var(--accent); }
.pl-note { font-size: 13px; color: var(--muted); margin: 0; }
.pl-save { position: sticky; bottom: 62px; } @media (min-width: 601px) { .pl-save { bottom: 0; } }
@media (prefers-reduced-motion: no-preference) { .rk-row, .rk-pod { animation: rkIn .28s ease-out both; } }
@keyframes rkIn { from { transform: translateY(6px); opacity: 0; } to { transform: none; opacity: 1; } }

/* GAME-06 3.7: the season strip under the header */
.ss-strip { display: flex; align-items: center; gap: 6px 12px; flex-wrap: wrap; min-height: 44px; padding: 6px 16px; box-sizing: border-box; border-bottom: 1px solid var(--line); background: var(--board); color: var(--ink) !important; text-decoration: none; }
.ss-strip:hover .ss-label { color: var(--accent); }
.ss-sq { width: 8px; height: 8px; background: var(--accent); flex: none; }
.ss-label { font: 600 13px Inter, system-ui, sans-serif; letter-spacing: 0; }   /* FIX-02: «Season: Oct–Dec · Indoor & Finals» in plain words */
.ss-left { font: 12px Inter, system-ui, sans-serif; color: var(--muted); margin-left: -6px; }
.ss-first { flex: 0 0 100%; font: 13px/1.4 Inter, system-ui, sans-serif; color: var(--ink); }
.ss-next { font: 12px Inter, system-ui, sans-serif; color: var(--muted); }

/* GAME-06 T2: season.html */
.sp-hero { display: flex; flex-direction: column; gap: 4px; padding: 16px; margin: -12px -16px 0; background: var(--board); border-bottom: 1px solid var(--line); }
.sp-hero h2 { margin: 0; font: 700 30px/1.1 'Space Grotesk', sans-serif; }
.sp-k { font: 400 10px Silkscreen, monospace; letter-spacing: 2px; color: var(--muted); }
.sp-d { font-size: 13px; color: var(--muted); } .sp-next { font-size: 14px; color: var(--accent); }
.sp-sec { display: flex; flex-direction: column; gap: 8px; padding-top: 6px; }
.sp-sec h2 { margin: 0; font: 700 18px 'Space Grotesk', sans-serif; }
.sp-row { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.sp-big { font: 400 26px Silkscreen, monospace; color: var(--accent); } .sp-mid { font: 600 15px 'Space Grotesk', sans-serif; } .sp-lab { font-size: 13px; color: var(--muted); }
.sp-muted { margin: 0; font-size: 13px; color: var(--muted); } .sp-note { margin: 0; font-size: 14px; padding: 10px 12px; border: 1px solid var(--line-2); }
.sp-cal, .sp-tro { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.sp-ev { display: grid; grid-template-columns: 64px 1fr; gap: 2px 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.sp-ev .sp-t { font-weight: 600; } .sp-ev .sp-d { grid-column: 2; }
.sp-tro li { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.sp-badges { display: flex; gap: 6px; } .sp-badge { min-width: 44px; padding: 6px 8px; text-align: center; border: 1px solid var(--line-2); font: 400 12px Silkscreen, monospace; color: var(--muted); }
.sp-badge.on { border-color: var(--accent); color: var(--ground); background: var(--accent); }
/* GAME-06 picks.html: two big player buttons per match, the lock line, the shares, the quiz, the champion picks */
.pk-na { font-size: 12px; color: var(--muted); }
.pk-days { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; }
.pk-days a { min-height: 44px; display: flex; align-items: center; font: 400 10px Silkscreen, monospace; letter-spacing: 1px; text-decoration: none; }
.pk-days a.nx { justify-content: flex-end; }
.pk-days b { font: 400 11px Silkscreen, monospace; letter-spacing: 1px; text-align: center; }
.pk-lock { margin: 0; padding: 10px 12px; border: 1px solid var(--line-2); font: 400 10px/1.5 Silkscreen, monospace; letter-spacing: 1px; color: var(--accent); }
.pk-lock.on { border-color: var(--line); color: var(--muted); }
.pk-ro { margin: 0; font-size: 14px; padding: 10px 12px; border: 1px dashed var(--line-2); color: var(--cream); }
.pk-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.pk-m { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.pk-mh { display: flex; justify-content: space-between; gap: 8px; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); }
.pk-res { white-space: nowrap; } .pk-res.ok, .pk .ok, b.ok { color: var(--accent); } .pk-res.no, b.no { color: var(--clay); }
.pk-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px; }
.pk-p { min-height: 72px; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; padding: 8px 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); text-align: left; cursor: pointer; }
.pk-p[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--ground); }
.pk-p:disabled { cursor: default; }
.pk-p:disabled:not([aria-pressed="true"]) { background: transparent; }
.pk-p.won:not([aria-pressed="true"]) { border-color: var(--accent); }
.pk-fl { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; opacity: .8; } .pk-sd { margin-left: 2px; }
.pk-nm { font: 700 15px/1.15 'Space Grotesk', sans-serif; overflow-wrap: anywhere; }
.pk-tag { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; opacity: .8; }
.pk-bar { display: flex; height: 4px; background: var(--line-2); } .pk-bar i { display: block; background: var(--glass); }
.pk-sum { margin: 0; font: 400 12px Silkscreen, monospace; letter-spacing: 1px; color: var(--accent); }
.pk-q { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.pk-qt { font-weight: 600; } .pk-qa { font-size: 14px; }
.pk-in, .pk-ch select { min-height: 44px; width: 100%; padding: 0 10px; border: 1px solid var(--line-2); background: var(--board); color: var(--ink); font: 15px Inter, system-ui, sans-serif; }
.pk-in:disabled { opacity: .5; }
.pk-ch { display: flex; flex-direction: column; gap: 4px; }
.pk-chl { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.pk-you { margin: 0; padding: 8px 10px; border-left: 3px solid var(--accent); background: var(--surface); font: 600 14px 'Space Grotesk', sans-serif; }
.pk-saved:empty { display: none; }
.pk-free { padding-top: 6px; }
.pk-dh { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; } .pk-dh h2 { margin: 0; font: 700 18px 'Space Grotesk', sans-serif; } .pk-dh .g3-btn { margin-left: auto; min-height: 44px; }
.pk-dn { font-size: 12px; margin: 10px 0 0; }
#pk-chsave { white-space: nowrap; }
/* the toast of share.js (Saved / Copied) on the g3 pages, above the phone tab bar */
.g3 .toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%) translateY(12px); background: var(--accent); color: var(--ground); font: 700 15px 'Space Grotesk', sans-serif; padding: 12px 20px; opacity: 0; transition: opacity .15s, transform .15s; z-index: 50; pointer-events: none; }
.g3 .toast.show { opacity: 1; transform: translateX(-50%); }
@media (min-width: 601px) { .g3 .toast { bottom: 32px; } }
@media (prefers-reduced-motion: reduce) { .g3 .toast { transition: none; } }
/* GAME-06 finals.html: groups, day-by-day head-to-heads, the champion, the set player */
.fn-champ { display: flex; flex-direction: column; gap: 6px; padding: 14px 12px; border: 2px solid var(--accent); background: var(--surface); }
.fn-champ .fn-who b { font: 700 22px 'Space Grotesk', sans-serif; }
.fn-tab { width: 100%; border-collapse: collapse; font-size: 14px; }
.fn-tab th { text-align: left; font: 400 9px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); padding: 4px 6px; border-bottom: 1px solid var(--line-2); }
.fn-tab td { padding: 6px; border-bottom: 1px solid var(--line); } .fn-tab td:nth-child(n+3), .fn-tab th:nth-child(n+3) { text-align: right; font-family: Silkscreen, monospace; }
.fn-tab tr.you td { background: var(--surface); } .fn-tab tr.you td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
.fn-who { display: inline-flex; align-items: center; gap: 6px; min-width: 0; } .fn-who .rk-av { width: 22px; height: 22px; }
.fn-who b { font: 600 14px 'Space Grotesk', sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 9.5em; }
.fn-fl { font: 400 9px Silkscreen, monospace; color: var(--muted); }
.fn-days, .fn-list, .fn-res { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.fn-day { display: flex; flex-direction: column; gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.fn-day.today > .sp-k { color: var(--accent); }
.fn-h2h { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 6px; }
.fn-side { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-width: 0; padding: 6px 8px; border: 1px solid var(--line); }
.fn-side.won { border-color: var(--accent); } .fn-side.won b { color: var(--accent); }
.fn-v { font: 400 9px Silkscreen, monospace; color: var(--muted); }
.fn-sc { font: 400 12px Silkscreen, monospace; } .fn-sc.off { color: var(--clay); font-size: 9px; }
.fn-chip { font: 400 8px Silkscreen, monospace; letter-spacing: 1px; color: var(--muted); } .fn-chip.on { color: var(--accent); }
.fn-rev { font: 400 9px Silkscreen, monospace; letter-spacing: 1px; text-decoration: none; }
.fn-would { margin: 0; font: 700 18px 'Space Grotesk', sans-serif; color: var(--accent); }
.fn-res li { padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 14px; } .fn-res .ok { color: var(--accent); } .fn-res .no { color: var(--clay); }
.fn-play { display: flex; flex-direction: column; gap: 10px; padding: 14px 12px; border: 2px solid var(--accent); background: var(--board); }
.fn-bar { height: 6px; background: var(--line); } .fn-bar i { display: block; height: 100%; width: 100%; background: var(--accent); }
.fn-q { margin: 0; font: 700 18px/1.3 'Space Grotesk', sans-serif; }
@media (max-width: 420px) {
  .fn-h2h { grid-template-columns: minmax(0, 1fr); gap: 0; border: 1px solid var(--line); }
  .fn-v { display: none; } .fn-side { border: 0; padding: 6px 8px; } .fn-side.r { flex-direction: row-reverse; border-top: 1px dashed var(--line); }
  .fn-side.won { box-shadow: inset 3px 0 0 var(--accent); }
}
.fn-on > :not(.fn-play) { display: none; }

/* ================================================================================================================
   WEB-03: the desktop interface. From 1024 x 600 up a court page is one screen - the court on the left, the play
   panel on the right (exports/WEB-03.md 3.2). Phone (<= 600 px) and middle widths keep every rule above untouched;
   everything of the desktop lives under this one media query. web/js/desk.js moves the nodes whose place in the DOM
   differs (the scoreboard, the draw strip, Slam Run's clock) and moves them back when the window shrinks.
   ================================================================================================================ */
@media (min-width: 1024px) and (min-height: 600px) {
  /* ---- the grid: header on top (full width, its inner padding follows the 1680 px box), court column, play panel */
  body.g3.today, body.g3.g3-mode { --pad: max(24px, calc(50vw - 840px)); display: grid; grid-template-columns: minmax(0, 1fr) clamp(400px, 30vw, 480px);
    grid-template-rows: auto auto auto auto auto minmax(0, 1fr) auto; column-gap: 24px; height: 100vh; padding: 0 var(--pad) 16px; }   /* (FIX-02: + the «Play unlimited» row under the court) */
  body.g3.today > .g3-head, body.g3.g3-mode > .g3-mhead { grid-column: 1 / -1; grid-row: 1; margin: 0 calc(-1 * var(--pad)); padding-left: var(--pad); padding-right: var(--pad); }
  body.g3.today > .ss-strip { grid-column: 1 / -1; grid-row: 2; margin: 0 calc(-1 * var(--pad)); padding-left: var(--pad); padding-right: var(--pad); }
  body.g3.today > .g3-stagewrap, body.g3.g3-mode > .g3-stagewrap { grid-column: 1; grid-row: 3; margin-top: 16px !important; display: block; border-bottom: 0; }
  body.g3.today .g3-stage, body.g3.g3-mode .g3-stage { max-width: 1400px; }
  body.g3.today > .g3-unl, body.g3.g3-mode > .g3-unl { grid-column: 1; grid-row: 4; }
  body.g3.today > #ump-slot, body.g3.today > .g3-ump, body.g3.g3-mode > #ump-slot, body.g3.g3-mode > .g3-ump { grid-column: 1; grid-row: 5; justify-content: flex-start; }
  body.g3.today > .g3-ump > div, body.g3.g3-mode > .g3-ump > div { max-width: none; }
  body.g3.today > .g3-under, body.g3.g3-mode > .g3-under { grid-column: 1; grid-row: 6; min-height: 0; display: flex; align-items: flex-start; gap: 12px; padding-top: 12px; }
  body.g3.today > .g3-foot, body.g3.g3-mode > .g3-foot { grid-column: 1; grid-row: 7; margin: 0; padding: 10px 0 0; }
  body.g3.today > .g3-foot nav, body.g3.g3-mode > .g3-foot nav { justify-content: flex-start; }
  /* (a node desk.js has not moved yet - the scoreboard, the draw - waits under the court, never over the panel) */
  body.g3.g3-mode > #board, body.g3.g3-mode > .g3-draw, body.g3.g3-mode > .g3-clockbar { grid-column: 1; grid-row: 6; align-self: start; }
  /* ---- the play panel: a surface card as tall as the window under the header; only its own content may scroll */
  body.g3.today > main.g3-main, body.g3.g3-mode > main.g3-main { grid-column: 2; grid-row: 3 / 8; margin: 16px 0 0; max-width: none; min-height: 0; overflow-y: auto;
    background: var(--surface); border: 1px solid var(--line); padding: 16px; }
  /* (a page that writes its <main> anew at every step - Tiebreak - gets the panel as a box around scoreboard and main) */
  body.g3.g3-mode > .g3-panel { grid-column: 2; grid-row: 3 / 8; margin: 16px 0 0; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 10px;
    background: var(--surface); border: 1px solid var(--line); padding: 16px; }
  body.g3.g3-mode > .g3-panel > main.g3-main { flex: none; max-width: none; margin: 0; padding: 0; }
  body.g3.g3-mode > .g3-panel > .g3-board { width: auto; max-width: none; margin: 0; }
  :where(body.g3.today, body.g3.g3-mode) main.g3-main :where(.g3-ct, .g3-card, .g3-opt, .g3-len) { background: var(--ground); }
  body.g3.g3-mode main.g3-main .g3-board { width: auto; max-width: none; margin: 0; }
  body.g3.g3-mode .g3-q { font-size: 23px; }
  /* Slam Run: round, question, shot clock and its bar open the panel (on the phone they sit on and under the court) */
  .g3-phead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; flex: none; }
  .g3-phead .tag { display: flex; align-items: center; gap: 5px; padding: 4px 7px; background: var(--board); border: 1px solid var(--line); font: var(--led); letter-spacing: 1px; }
  .g3-phead .g3-clockbar { flex: 0 0 100%; }
  /* Slam Run: the rules card (before the first question, or behind «How it works») opens under the court, in two
     columns with its button in the title row; while it is open it takes the place of the draw strip. The question
     and its answers stay in the panel - rules and question together do not fit the panel of a 1280 x 720 window */
  body.g3.slamrun > .g3-under { flex-direction: column; align-items: stretch; gap: 0; }
  body.g3.slamrun > .g3-under:has(#rules) > .g3-draw { display: none; }
  body.g3.slamrun > .g3-under .g3-rules { display: block; position: relative; columns: 2; column-gap: 24px; padding: 8px 14px 10px; }
  body.g3.slamrun > .g3-under .g3-rules .g3-label { display: block; column-span: all; line-height: 36px; margin-bottom: 4px; }
  body.g3.slamrun > .g3-under .g3-rules p { font-size: 13px; line-height: 1.4; margin: 0 0 6px; break-inside: avoid; }
  body.g3.slamrun > .g3-under .g3-rules .g3-btn { position: absolute; top: 8px; right: 14px; width: auto; min-height: 36px; margin: 0; padding: 0 20px; }
  /* COURT-01: the 7:3 court stands 44 px taller than the 8:3 stage did; in a window up to 760 px high the rules card is
     set a little tighter so that it ends above the footer (1280 x 720: 218 -> 184 px; the title row keeps the button's height) */
  @media (max-height: 760px) {
    body.g3.slamrun > .g3-under .g3-rules p { font-size: 12.5px; line-height: 1.35; margin: 0 0 4px; }
  }
  /* ---- under the court */
  body.g3.today > .g3-under > * { flex: 1 1 0; min-width: 0; }
  body.g3.g3-mode > .g3-under > .g3-draw { flex: 1; padding: 0; border: 0; background: none; }
  body.g3.g3-mode > .g3-under > .g3-draw .cells { max-width: none; }
  /* Deuce, Tiebreak: the last point - question, right answer, fact (web/js/desk.js underNote) */
  body.g3.g3-mode > #desk-note { flex-direction: column; align-items: stretch; gap: 4px; margin-top: 12px; padding: 12px 14px; background: var(--board); border: 1px solid var(--line); align-self: start; }
  body.g3.g3-mode > #desk-note[hidden] { display: none; }
  #desk-note .q { font: 600 15px/1.35 'Space Grotesk', sans-serif; color: var(--ink); }
  #desk-note .a { font: 700 15px/1.3 'Space Grotesk', sans-serif; color: var(--accent); }
  #desk-note .f { font: 400 13px/1.45 Inter, sans-serif; color: var(--muted); }
  /* FIX-01 Block 1: Today's track switch is in the header on the desktop, as on every page (web/menu.css); its own row
     in the panel (.g3-trackrow, GAME-07) stays hidden here - the phone and the tablet keep it */
  /* ---- the keyboard (web/js/keys.js): each Deuce card shows its key; Slam Run's rows keep their A-D letters */
  body.g3.g3-mode .g3-card { position: relative; }
  body.g3.g3-mode .g3-key { display: flex; position: absolute; top: 5px; left: 5px; min-width: 18px; height: 18px; align-items: center; justify-content: center;
    background: var(--board); border: 1px solid var(--line); color: var(--accent); font: 400 10px Silkscreen, monospace; }
  /* ---- 3.3 the other pages: a dashboard, not a column. <main> is a container of up to 1120 px with two columns -
     the page's main list or board (up to 720 px, never stretched) and its independent sections as tiles beside it
     (web/js/desk.js sorts the children of <main> into .g3-dmain and .g3-dside). Each column keeps the 16 px side
     padding <main> has on the phone, so full-bleed pieces (the poster, a hero, the umpire) end at the column's edge */
  body.g3 > main.g3-main:has(> .g3-dmain) { max-width: 1120px; display: grid; grid-template-columns: minmax(0, 720px) minmax(320px, 400px); justify-content: center;
    column-gap: 0 !important; align-items: start; padding-left: 0; padding-right: 0; }
  .g3-dmain, .g3-dside { display: flex; flex-direction: column; row-gap: inherit; min-width: 0; padding: 0 16px; }
  .g3-dside { padding-left: 8px; }
  body.g3.myday .g3-dside, body.g3.career .g3-dside { padding-top: 12px; }   /* (their <main> starts flush under the strip, for the poster) */
  .g3-dside > .sp-sec { padding: 10px 14px 12px; background: var(--board); border: 1px solid var(--line); }
  /* Rankings, Your player, Archive: the side column stays in view beside a long board, form or list */
  body.g3.rankings .g3-dside, body.g3.player .g3-dside, body.g3.archive .g3-dside { position: sticky; top: 12px; }
  .g3-dside > .rk-you { position: static; margin: 0; flex-wrap: wrap; border: 1px solid var(--line); border-top: 2px solid var(--accent); }
  .g3-dside > .rk-foot { margin: 0; order: 1; }
  /* Picks: the day's matches are two columns of match cards */
  .g3-dmain .pk-list:has(> .pk-m) { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 14px; }
  /* Finals: the two groups side by side; while a set runs its player takes the main column and the day list stays beside it */
  body.g3.finals main:not(.fn-on) > .g3-dmain { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 16px; align-content: start; }
  body.g3.finals .g3-dmain > * { grid-column: 1 / -1; }
  body.g3.finals .g3-dmain > .fn-grp { grid-column: auto; }
  body.g3.finals main.fn-on > .g3-dside { display: flex; }
  /* (in the narrow side column a head-to-head is two rows, as on a phone: the names keep their width) */
  .g3-dside .fn-h2h { grid-template-columns: minmax(0, 1fr); gap: 0; border: 1px solid var(--line); }
  .g3-dside .fn-v { display: none; } .g3-dside .fn-side { border: 0; padding: 6px 8px; } .g3-dside .fn-side.r { flex-direction: row-reverse; border-top: 1px dashed var(--line); }
  .g3-dside .fn-side.won { box-shadow: inset 3px 0 0 var(--accent); }
  body.g3.finals main.fn-on > .fn-play { grid-column: 1; margin: 12px 16px 0; }
  /* ---- a pointer: every answer and button shows it and answers a hover */
  :where(body.g3) :where(.g3-btn, .g3-ct, .g3-play, .g3-help, .g3-linkbtn) { cursor: pointer; }
  :where(body.g3) .g3-btn:disabled, :where(body.g3) .g3-help:disabled { cursor: default; }
  :where(body.g3) :where(.g3-card:not(:disabled), .g3-opt:not(:disabled):not(.removed), .g3-len, .g3-btn:not(:disabled), .g3-help:not(:disabled), .g3-ct[href]):hover { border-color: var(--accent); }
}
/* a low desktop window (1280 x 720, 1366 x 768): the answers are a little smaller so that the trio and its clock fit */
@media (min-width: 1024px) and (min-height: 600px) and (max-height: 820px) {
  body.g3.g3-mode main.g3-main { gap: 6px; padding: 12px 14px; }
  body.g3.g3-mode .g3-card { min-height: 148px; } body.g3.g3-mode .g3-card .sil, body.g3.g3-mode .g3-card .sil img { height: 68px; }
  body.g3.g3-mode .g3-duel.trio .g3-card { min-height: 116px; } body.g3.g3-mode .g3-duel.trio .g3-card .sil, body.g3.g3-mode .g3-duel.trio .g3-card .sil img { height: 50px; }
  body.g3.g3-mode .g3-card.text { min-height: 104px; } body.g3.g3-mode .g3-duel.trio .g3-card.text { min-height: 76px; }
  body.g3.g3-mode .g3-len { min-height: 124px; }
  body.g3.g3-mode .g3-q { font-size: 22px; margin-bottom: 2px; }
}


/* RELEASE-01 3.2 (Z3): tap targets on the phone - at least 44 px high */
.g3-link { display: inline-flex; align-items: center; min-height: 44px; }
@media (max-width: 720px) {
  .rk-modes button { min-height: 44px; min-width: 44px; }
  .rk-ybtn { min-height: 44px; }
  .sp-ev .sp-t a { display: inline-flex; align-items: center; min-height: 44px; }
  .g3-foot nav { gap: 0 6px; }
  .g3-foot nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 44px; padding: 0 6px; }   /* (PLAY-01: «X» is one letter - 44 px wide all the same) */
}

/* FIX-01 Block 3: the sound button on the court of the home page, Deuce, Slam Run and Tiebreak - the court's
   bottom-right corner, where Mystery and Rally have it, 44 px at every width (web/js/soundbtn.js) */
.g3-stage > .sound-btn { position: absolute; bottom: 4px; right: 4px; z-index: 3; width: 44px; height: 44px; padding: 0; background: var(--board); border: 1px solid var(--line); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.g3-stage > .sound-btn[aria-pressed="false"] { color: var(--muted); }

/* PLAY-02 Block 3 (the founder: "it blinks white while the point is played; the point is played, and only then it turns
   green or red"): between an answer and the court's answer the five modes show THAT an answer was taken - the answer
   given blinks cream, every other option is dimmed, a line says the point is in play - and nothing of what it was worth */
.pending, .g3-card.pending, .g3-opt.pending, .grow .cell.pending, .g3-tbform input.pending { border-color: var(--cream); color: var(--cream); animation: dd-pending .9s ease-in-out infinite; }
@keyframes dd-pending { 0%, 100% { background: rgba(242, 230, 201, .08) } 50% { background: rgba(242, 230, 201, .30) } }
@media (prefers-reduced-motion: reduce) { .pending, .g3-card.pending, .g3-opt.pending, .grow .cell.pending, .g3-tbform input.pending { animation: none; background: rgba(242, 230, 201, .18); } }
html.motion-low .pending, html.motion-low .g3-card.pending, html.motion-low .g3-opt.pending, html.motion-low .grow .cell.pending, html.motion-low .g3-tbform input.pending { animation: none; background: rgba(242, 230, 201, .18); }
.g3-card.held, .g3-opt.held { opacity: .45; }
.g3-inplay { margin: 0; font: 400 10px/1.4 Silkscreen, ui-monospace, monospace; letter-spacing: 2px; color: var(--cream); text-transform: uppercase; }

/* PLAY-02 Block 4: a match has an end - one panel in the five modes: the points, three buttons, the free-match line */
.g3-endpanel { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.g3-endpts { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; font: 400 11px/1.3 Silkscreen, ui-monospace, monospace; letter-spacing: 1px; color: var(--muted); text-transform: uppercase; }
.g3-endpts b { font: 400 18px/1.2 Silkscreen, ui-monospace, monospace; letter-spacing: 1px; color: var(--cream); }
.g3-endpts b.plus { color: var(--accent); }
.g3-endbtns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.g3-endbtns > * { min-width: 0; text-align: center; }
.g3-endbtns .g3-btn { flex-wrap: wrap; row-gap: 2px; column-gap: 6px; padding: 6px 8px; line-height: 1.2; }   /* (a narrow phone: the UNLIMITED tag goes under the words, nothing is cut off) */
.g3-endbtns .g3-tag-unl { margin-left: 0; }
.g3-endbtns .g3-end-one { align-self: center; font: 400 12px/1.3 Inter, system-ui, sans-serif; color: var(--muted); }
.g3-tag-unl { display: inline-block; margin-left: 6px; padding: 2px 4px; font: 400 9px/1 Silkscreen, ui-monospace, monospace; letter-spacing: 1px; background: var(--accent); color: var(--ground); vertical-align: middle; }
@media (max-width: 720px) { .g3-endbtns { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3-endbtns .g3-end-next { grid-column: 1 / -1; } }
.g3-board .grid.two { grid-template-columns: minmax(0, 1fr) 64px; }
/* PLAY-02 Block 5: the line of a card under way (5c) and the practice label of Rally and Mystery (5a) */
.g3-cont { margin: 0; font: 400 12px/1.4 Inter, system-ui, sans-serif; color: var(--cream); }
.g3-practice { display: block; margin: 0 0 4px; font: 400 10px/1.3 Silkscreen, ui-monospace, monospace; letter-spacing: 1px; color: var(--accent); text-transform: uppercase; }

/* FIX-02 Block 2: today's card played on another device of the account (web/js/endpanel.js elsewhereHtml) - its
   result and the end panel instead of the question */
.g3-elsewhere { display: flex; flex-direction: column; gap: 6px; padding: 14px 14px 12px; border: 1px solid var(--line-2); border-left: 4px solid var(--accent); background: var(--board); }
.g3-elsewhere .g3-q { margin: 0; }
.g3-elsewhere-line { margin: 0; font: 700 17px 'Space Grotesk', sans-serif; color: var(--accent); }
.g3-elsewhere-note { margin: 0; font-size: 13px; }

/* FIX-02 Block 3: under «Today's 5 matches» the line that the card is everybody's */
.g3-same { margin: -4px 0 0; font: 400 14px/1.4 Inter, system-ui, sans-serif; color: var(--muted); }
/* FIX-02 Block 3: the ME page - «Today» on top, «All time» below, each with its heading bar */
.g3-mesec { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: 8px; }
.g3-mebody { display: flex; flex-direction: column; gap: 12px; }
.g3-mehead { margin: 8px -16px 0; padding: 10px 16px; background: var(--board); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  font: 400 13px Silkscreen, monospace; letter-spacing: 2px; text-transform: uppercase; color: var(--accent); }
#today > .g3-mehead { margin-top: 0; border-top: 0; }

/* FIX-02 Block 3: «▶ Play unlimited — from €4.99» directly under the court of Today and the five games (web/js/limit.js
   mountUnlLine); a player with Unlimited reads «UNLIMITED ✓» there in gold (the founder's addition of 17 Nov) */
:root { --gold: #E8B931; --gold-ink: #1A1405; }
.g3-unl { margin: 0; flex: none; display: flex; background: var(--board); border-bottom: 1px solid var(--line); }
.g3-unl a { flex: 1; display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; box-sizing: border-box; color: var(--accent) !important;
  font: 700 15px 'Space Grotesk', sans-serif; text-decoration: none; }
.g3-unl a span { font-size: 12px; }
.g3-unl a:hover { text-decoration: underline; }
.g3-unl.on a { color: var(--gold) !important; font: 400 12px Silkscreen, monospace; letter-spacing: 2px; }
.g3m .wrap.page > .g3-unl { margin: -12px -16px 0; }
@media (min-width: 1024px) and (min-height: 600px) {
  body.g3m .wrap.page > .g3-unl { grid-column: 1; grid-row: 3; margin: 0; }
  body.g3.today > .g3-unl a, body.g3.g3-mode > .g3-unl a { padding: 0 12px; }
}

/* PLAY-03 Block 1 (the founder on 18 Nov: "Deuce barely fits a Pro Max"): on a phone (<= 600 px) Deuce is one screen -
   the board is one row (YOU · games · points | points · games · CHALLENGER, no header row, smaller digits) with the
   banner and ACES · BP SAVED on a short line under it; the question a size smaller; the answers 56 px buttons, two per
   row (the third of a trio under them), a player card's silhouette small at its side. The court keeps its size; wider
   screens are untouched. tools/verify_play03.py deuce measures it at 393 x 852, 375 x 667 and 430 x 932. */
@media (max-width: 600px) {
  body.deuce .g3-board { margin: 6px 12px 0; padding: 5px 8px 6px; gap: 4px; }
  body.deuce .g3-board .grid { grid-template-columns: auto 26px 32px 32px 26px minmax(0, 1fr); column-gap: 4px; row-gap: 0; }
  body.deuce .g3-board .grid.two { grid-template-columns: auto 26px 26px minmax(0, 1fr); }
  body.deuce .g3-board .grid > .corner, body.deuce .g3-board .grid > .h { display: none; }
  body.deuce .g3-board .grid > * { grid-row: 1; }
  body.deuce .g3-board .who.you { grid-column: 1; }
  body.deuce .g3-board .num.g.you { grid-column: 2; } body.deuce .g3-board .num.p.you { grid-column: 3; }
  body.deuce .g3-board .num.p.opp { grid-column: 4; } body.deuce .g3-board .num.g.opp { grid-column: 5; }
  body.deuce .g3-board .who.opp { grid-column: 6; justify-content: flex-start; flex-direction: row-reverse; }
  body.deuce .g3-board .grid.two .num.g.opp { grid-column: 3; } body.deuce .g3-board .grid.two .who.opp { grid-column: 4; }
  body.deuce .g3-board .who { font-size: 12px; gap: 5px; min-width: 0; }
  body.deuce .g3-board .who.opp { justify-content: flex-end; }
  body.deuce .g3-board .num { height: 26px; font-size: 16px; }
  body.deuce .g3-board .foot { gap: 6px; }
  body.deuce .g3-board .g3-banner { padding: 3px 7px; font-size: 10px; letter-spacing: 1px; }
  body.deuce .g3-board .stats { font-size: 8px; }
  body.deuce > .g3-stagewrap { margin-top: 6px !important; }
  body.deuce > main.g3-main { padding: 8px 16px 12px; gap: 4px !important; }
  body.deuce #q-text { font-size: 19px !important; margin: 0 0 2px; }
  body.deuce .g3-duel { gap: 8px; }
  body.deuce .g3-card, body.deuce .g3-duel.trio .g3-card { min-height: 56px; padding: 6px 8px; display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 8px; row-gap: 1px;
    align-items: center; align-content: center; justify-items: start; text-align: left; }
  body.deuce .g3-card .sil, body.deuce .g3-duel.trio .g3-card .sil { height: 40px; grid-column: 1; grid-row: 1 / span 3; }
  body.deuce .g3-card .sil img, body.deuce .g3-duel.trio .g3-card .sil img { height: 40px; }
  body.deuce .g3-card .nm { grid-column: 2; font-size: 15px; } body.deuce .g3-card .mt { grid-column: 2; font-size: 11px; }
  body.deuce .g3-card .val { grid-column: 2; margin-top: 1px; padding: 2px 6px; font-size: 11px; }
  /* a duel faces itself: the second card has its silhouette on the outer side, the VS between the two names */
  body.deuce .g3-duel:not(.trio) .g3-card:nth-child(1) { padding-right: 14px; }
  body.deuce .g3-duel:not(.trio) .g3-card:nth-child(2):not(.text) { padding-left: 14px; grid-template-columns: minmax(0, 1fr) auto; justify-items: end; text-align: right; }
  body.deuce .g3-duel:not(.trio) .g3-card:nth-child(2):not(.text) .sil { grid-column: 2; }
  body.deuce .g3-duel:not(.trio) .g3-card:nth-child(2):not(.text) :is(.nm, .mt, .val) { grid-column: 1; }
  body.deuce .g3-card.text, body.deuce .g3-duel.trio .g3-card.text { display: flex; min-height: 56px; padding: 8px 10px; justify-content: center; text-align: center; }
  body.deuce .g3-card.text .nm, body.deuce .g3-duel.trio .g3-card.text .nm { font-size: 16px; }
  body.deuce .g3-duel:not(.trio) .g3-card.text:nth-child(1) { padding-right: 14px; } body.deuce .g3-duel:not(.trio) .g3-card.text:nth-child(2) { padding-left: 14px; }
  body.deuce .g3-duel.trio .g3-card:nth-child(3) { width: calc(50% - 4px); }
  body.deuce .g3-vs, body.deuce .g3-duel:has(.g3-card.text) .g3-vs { top: calc(50% - 12px); width: 24px; height: 24px; font-size: 10px; }
  body.deuce .g3-result { padding: 8px 10px; gap: 12px; }
  body.deuce .g3-result .g3-bigstamp { font-size: 18px; padding: 4px 8px; border-width: 3px; }
}

/* PLAY-03 Block 2 (the founder did not find "take the points and leave": TAKE sat under the four options, below the
   fold): Slam Run's TAKE in the question's header row, right of «ROUND OF 16 · PLAYING FOR 45 PTS», while a question is
   asked - «TAKE 25 PTS» where a take changes something, the note «25 PTS SAFE» (no button) on a safe step, nothing on the
   first question. The row keeps its height on every question (no jump). */
.g3-qhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; }
.g3-qhead .g3-label { flex: 1; min-width: 0; }
.g3-qtake { flex: none; display: flex; }
.g3 .g3-take { min-width: 0; min-height: 44px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; background: var(--ground); color: var(--accent);
  border: 2px solid var(--accent); font: 400 12px Silkscreen, monospace; letter-spacing: 1px; white-space: nowrap; cursor: pointer; }
.g3 .g3-take:hover { background: var(--accent); color: var(--ground); }
.g3-take-safe { display: inline-flex; align-items: center; padding: 6px 9px; border: 1px dashed var(--line-2); color: var(--accent); font: 400 11px Silkscreen, monospace; letter-spacing: 1px; white-space: nowrap; }
