/* 25straight — Maccauw club gold and goose navy. Layout: one-column range tool — sticky header, scoring grid, thumb-height kill/lost pad fixed at the bottom */
:root {
  --bg: #EEF2EC;
  --surface: #FFFFFF;
  --surface-2: #F6F8F4;
  --ink: #16201A;
  --muted: #56635B;
  --line: #D3DBD2;
  --line-strong: #9AA79D;
  --clay: #A87400;
  --clay-soft: #FBEFC9;
  --on-clay: #FFFFFF;
  --hit: #1E7442;
  --hit-2: #5E7F1F;
  --miss: #B0281F;
  --on-hit: #FFFFFF;
  --wait: #9A6400;
  --wait-soft: #FCEFD4;
  --font-display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", sans-serif;
  --font-body: "Barlow", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0E1411; --surface: #17201B; --surface-2: #1D2822; --ink: #E7EEE9; --muted: #9DABA2;
    --line: #2B3730; --line-strong: #4E5E54; --clay: #F2C21B; --clay-soft: #3A300F; --on-clay: #1A1400;
    --hit: #4CC07C; --hit-2: #A4C44E; --miss: #FF6A5C; --on-hit: #0B1A10; --wait: #F2B640; --wait-soft: #33280F;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0E1411; --surface: #17201B; --surface-2: #1D2822; --ink: #E7EEE9; --muted: #9DABA2;
  --line: #2B3730; --line-strong: #4E5E54; --clay: #F2C21B; --clay-soft: #3A300F; --on-clay: #1A1400;
  --hit: #4CC07C; --hit-2: #A4C44E; --miss: #FF6A5C; --on-hit: #0B1A10; --wait: #F2B640; --wait-soft: #33280F;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.45; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, input:focus-visible { outline: 3px solid var(--clay); outline-offset: 2px; }
.num { font-variant-numeric: tabular-nums; }

.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); }
.top-in, .tabs-in, .main { max-width: 760px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-block: 10px 6px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; letter-spacing: .01em; line-height: 1; }
.brand-sub { font-size: .78rem; color: var(--muted); }
.sync { display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.sync::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--hit); }
.sync.wait { background: var(--wait-soft); color: var(--wait); }
.sync.wait::before { background: var(--wait); }
.tabs-in { display: flex; gap: 4px; }
.tab { flex: 1; background: none; border: 0; border-bottom: 3px solid transparent; padding: 8px 4px 9px; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.tab[aria-current="true"] { color: var(--ink); border-bottom-color: var(--clay); }

.main { padding-block: 18px 40px; display: flex; flex-direction: column; gap: 18px; }
.main.scoring { padding-bottom: calc(190px + env(safe-area-inset-bottom, 0px)); }
h1, h2 { font-family: var(--font-display); font-weight: 700; margin: 0; line-height: 1.05; text-wrap: balance; }
h1 { font-size: 1.9rem; }
h2 { font-size: 1.25rem; letter-spacing: .02em; }
.label { font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.lede { color: var(--muted); margin: 4px 0 0; max-width: 60ch; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1.5px solid var(--line-strong); background: var(--surface); border-radius: 8px; padding: 8px 14px; font-weight: 600; min-height: 44px; }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip.small { min-height: 36px; padding: 5px 11px; font-weight: 500; font-size: .92rem; }
.chip.small[disabled] { opacity: .4; cursor: default; }
.input { width: 100%; min-height: 46px; border: 1.5px solid var(--line-strong); border-radius: 8px; background: var(--surface); color: var(--ink); padding: 8px 12px; font: inherit; }
.row { display: flex; gap: 8px; align-items: center; }
.row > .input { flex: 1; min-width: 0; }
.btn { border: 0; border-radius: 10px; padding: 12px 18px; font-weight: 700; min-height: 48px; background: var(--surface-2); border: 1.5px solid var(--line-strong); }
.btn.primary { background: var(--clay); color: var(--on-clay); border-color: var(--clay); font-family: var(--font-display); font-size: 1.2rem; letter-spacing: .04em; text-transform: uppercase; }
.btn.primary[disabled] { opacity: .45; cursor: default; }
.btn.ghost { background: none; border-color: transparent; color: var(--muted); }
.btn.danger { color: var(--miss); border-color: var(--miss); background: none; }
.note { font-size: .9rem; color: var(--muted); margin: 0; }

.squad { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.squad li { display: flex; align-items: center; gap: 10px; background: var(--surface-2); border-radius: 8px; padding: 6px 6px 6px 10px; }
.squad .ord { font-family: var(--font-display); font-weight: 700; color: var(--clay); width: 1.2em; }
.squad .nm { flex: 1; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.icon-btn { width: 40px; height: 40px; border: 0; border-radius: 8px; background: none; color: var(--muted); font-size: 1.1rem; }

.resume { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; border: 2px solid var(--clay); background: var(--clay-soft); }
.queue { display: flex; gap: 12px; align-items: flex-start; }
.queue .big { font-family: var(--font-display); font-weight: 700; font-size: 2.6rem; line-height: .9; color: var(--wait); }
.round { display: flex; flex-direction: column; gap: 8px; }
.round-head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.round-title { font-weight: 700; }
.pill { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: var(--wait-soft); color: var(--wait); }
.pill.grey { background: var(--surface-2); color: var(--muted); }
.pill.clay { background: var(--clay-soft); color: var(--clay); }
.results { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr auto auto; gap: 2px 14px; font-size: .95rem; }
.results li { display: contents; }
.results .pct { color: var(--muted); text-align: right; }
.results .pts { text-align: right; font-weight: 600; }

/* scoring */
.score-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; }
.blocknav { display: flex; align-items: center; gap: 4px; }
.blocknav .cur { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; min-width: 7.5em; text-align: center; }
.blocknav button { width: 44px; height: 44px; border-radius: 8px; border: 1.5px solid var(--line-strong); background: var(--surface); font-size: 1.2rem; }
.blocknav button[disabled] { opacity: .35; cursor: default; }
.up { background: var(--ink); color: var(--bg); border-radius: 10px; padding: 12px 14px; display: flex; justify-content: space-between; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.up .who { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; line-height: 1.05; }
.up .what { font-size: .95rem; opacity: .85; }
.up.done { background: var(--hit); color: var(--on-hit); }
.grid-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.grid { border-collapse: collapse; width: 100%; }
.grid th, .grid td { padding: 0; text-align: center; border-bottom: 1px solid var(--line); }
.grid tr:last-child td { border-bottom: 0; }
.grid thead th { font-size: .72rem; font-weight: 700; letter-spacing: .05em; color: var(--muted); padding: 8px 2px 6px; white-space: nowrap; }
.grid .nmcell { text-align: left; padding: 6px 8px 6px 12px; font-weight: 600; white-space: nowrap; position: sticky; left: 0; background: var(--surface); }
.grid .tot { padding: 0 10px; font-weight: 700; white-space: nowrap; }
.grid .tot small { display: block; font-weight: 500; color: var(--muted); font-size: .72rem; }
.grid .gs { border-left: 2px solid var(--line-strong); }
.cell { width: 42px; height: 48px; border: 0; background: none; font-family: var(--font-display); font-weight: 700; font-size: 1.45rem; }
.cell.k { color: var(--hit); }
.cell.k2 { color: var(--hit-2); }
.cell.m { color: var(--miss); }
.cell.empty { color: var(--line-strong); font-size: 1rem; }
.cell.active { background: var(--clay-soft); box-shadow: inset 0 0 0 3px var(--clay); }
tr.row-active .nmcell { color: var(--clay); }
.strip { display: flex; gap: 6px; flex-wrap: wrap; }
.strip button { min-width: 40px; height: 36px; border-radius: 8px; border: 1.5px solid var(--line-strong); background: var(--surface); font-weight: 700; font-variant-numeric: tabular-nums; }
.strip button.full { background: var(--surface-2); border-color: var(--hit); color: var(--hit); }
.strip button[aria-current="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.legend { font-size: .85rem; color: var(--muted); display: flex; gap: 14px; flex-wrap: wrap; }
.legend b { font-family: var(--font-display); font-size: 1.1rem; }

.pad { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; background: var(--surface); border-top: 1px solid var(--line); padding-top: 10px; padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px)); padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.pad-in { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 8px; }
.pad-btns { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; }
.shot { border: 0; border-radius: 12px; min-height: 92px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-family: var(--font-display); font-weight: 700; font-size: 1.9rem; letter-spacing: .04em; text-transform: uppercase; color: var(--on-hit); }
.shot small { font-family: var(--font-body); font-size: .8rem; font-weight: 600; letter-spacing: 0; text-transform: none; opacity: .9; }
.shot.k { background: var(--hit); }
.shot.k2 { background: var(--hit-2); }
.shot.m { background: var(--miss); }
.shot:active { transform: translateY(1px); filter: brightness(.95); }
.shot[disabled] { opacity: .35; cursor: default; }
.pad-row { display: flex; justify-content: space-between; gap: 8px; }

/* ladder */
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.lt { border-collapse: collapse; width: 100%; font-size: .95rem; }
.lt th { text-align: left; font-size: .72rem; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); padding: 10px 10px 8px; border-bottom: 1px solid var(--line-strong); white-space: nowrap; }
.lt td { padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.lt tr:last-child td { border-bottom: 0; }
.lt .r { text-align: right; }
.lt .pos { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; width: 2.5em; }
.lt tr.top3 .pos { color: var(--clay); }
.lt .sub { color: var(--muted); font-size: .85rem; }
.toggle { display: flex; align-items: center; gap: 10px; font-size: .92rem; color: var(--muted); }
.toggle input { width: 20px; height: 20px; accent-color: var(--clay); }
.seg { display: inline-flex; border: 1.5px solid var(--line-strong); border-radius: 8px; overflow: hidden; }
.seg button { border: 0; background: var(--surface); padding: 8px 14px; font-weight: 600; min-height: 40px; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

.sheet-back { position: fixed; inset: 0; background: rgba(10, 14, 12, .55); z-index: 20; display: flex; align-items: flex-end; justify-content: center; padding: 16px; padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
.sheet { background: var(--surface); color: var(--ink); border-radius: 14px; padding: 18px; max-width: 460px; width: 100%; display: flex; flex-direction: column; gap: 12px; }
.sheet .row { justify-content: flex-end; }
.btn.small { min-height: 40px; padding: 8px 14px; font-size: .92rem; }
.btn[disabled] { opacity: .4; cursor: default; }
.btn.straight { background: var(--hit); border-color: var(--hit); color: var(--on-hit); }
.round-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 10px; }
.cell { position: relative; }
.cell .appeal { position: absolute; top: 3px; right: 3px; font-family: var(--font-body); font-size: .62rem; font-weight: 700; color: var(--on-clay); background: var(--clay); border-radius: 4px; padding: 0 3px; line-height: 1.4; }
.signoff { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.signoff li { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--surface-2); border-radius: 8px; padding: 8px 8px 8px 12px; }
.so-name { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.signoff .chip[aria-pressed="true"] { background: var(--hit); border-color: var(--hit); color: var(--on-hit); }
textarea.input { font-family: var(--font-body); resize: vertical; }
/* tablet in landscape: put the shot pad beside the card instead of under it */
@media (min-width: 900px) and (orientation: landscape) {
  .main.scoring { max-width: 1180px; padding-right: calc(360px + max(16px, env(safe-area-inset-right, 0px))); padding-bottom: 40px; }
  .pad { left: auto; top: 0; z-index: 4; width: 340px; border-top: 0; border-left: 1px solid var(--line); display: flex; align-items: center; padding-top: calc(16px + env(safe-area-inset-top, 0px)); }
  .pad-in { width: 100%; }
  .pad-btns { grid-auto-flow: row; grid-auto-columns: auto; }
  .shot { min-height: 120px; }
  .pad-row { flex-wrap: wrap; }
}
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(24px + env(safe-area-inset-bottom, 0px)); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 10px; font-weight: 600; z-index: 30; max-width: calc(100% - 32px); }
.empty-state { text-align: center; padding: 28px 16px; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
/* competitions */
.sub-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.comp-card { display: flex; flex-direction: column; gap: 10px; }
.comp-card .comp-meta { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.pill.open { background: var(--hit); color: var(--on-hit); }
.pill.ink { background: var(--ink); color: var(--bg); }
.poster { background: var(--ink); color: var(--bg); border-radius: 12px; padding: 22px 18px; display: flex; flex-direction: column; gap: 14px; position: relative; overflow: hidden; }
.poster .eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--clay); }
.poster h1 { font-size: clamp(2.2rem, 9vw, 3.4rem); line-height: .95; }
.poster .when { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; letter-spacing: .02em; }
.poster p { margin: 0; max-width: 60ch; opacity: .9; }
.poster .clays { position: absolute; right: -24px; top: -18px; opacity: .9; pointer-events: none; }
.poster .btn.primary { align-self: flex-start; }
.ev-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.ev-table th { text-align: left; font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; opacity: .7; padding: 6px 8px 6px 0; }
.ev-table td { padding: 8px 8px 8px 0; border-top: 1px solid color-mix(in srgb, currentColor 22%, transparent); vertical-align: top; }
.ev-table .r { text-align: right; padding-right: 0; }
.rules-list { margin: 0; padding-left: 1.1em; display: flex; flex-direction: column; gap: 4px; color: var(--muted); font-size: .92rem; }
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; min-width: 0; }
.tile .v { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; line-height: 1.05; }
.tile .k { font-size: .75rem; color: var(--muted); }
.entry-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.entry-row:first-child { border-top: 0; }
.entry-row .who { min-width: 0; flex: 1; }
.entry-row .who b { display: block; }
.pay { font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.pay.paid { background: var(--hit); color: var(--on-hit); }
.pay.eft, .pay.onsite { background: var(--wait-soft); color: var(--wait); }
.pay.unpaid { background: var(--clay-soft); color: var(--miss); }
.squad-card { display: flex; flex-direction: column; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.squad-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.squad-top b { font-family: var(--font-display); font-size: 1.15rem; }
.members { display: flex; flex-wrap: wrap; gap: 6px; }
.mchip { border: 1.5px solid var(--line-strong); background: var(--surface); border-radius: 8px; padding: 5px 10px; font-size: .9rem; display: inline-flex; gap: 6px; align-items: baseline; min-height: 36px; }
.mchip small { color: var(--muted); font-weight: 600; }
.mchip[aria-pressed="true"] { border-color: var(--clay); background: var(--clay-soft); }
.round-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.round-btns .chip.small.done { border-color: var(--hit); color: var(--hit); }
.round-btns .chip.small.live { border-color: var(--clay); color: var(--clay); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 520px) { .form-grid { grid-template-columns: 1fr; } }
select.input { appearance: auto; }
.ev-pick { display: flex; flex-direction: column; gap: 8px; }
.ev-opt { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1.5px solid var(--line-strong); border-radius: 10px; flex-wrap: wrap; }
.ev-opt.on { border-color: var(--clay); background: var(--clay-soft); }
.ev-opt input[type=checkbox] { width: 22px; height: 22px; accent-color: var(--clay); }
.ev-opt .ev-name { flex: 1; min-width: 0; font-weight: 600; }
.ev-opt select { width: auto; min-height: 38px; }
.radio-list { display: flex; flex-direction: column; gap: 6px; }
.radio-list label { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1.5px solid var(--line-strong); border-radius: 10px; cursor: pointer; }
.radio-list label.on { border-color: var(--clay); background: var(--clay-soft); }
.radio-list input { margin-top: 3px; accent-color: var(--clay); width: 18px; height: 18px; }
.radio-list small { display: block; color: var(--muted); }
.total-line { display: flex; justify-content: space-between; align-items: baseline; font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; }
.ev-builder { display: flex; flex-direction: column; gap: 10px; }
.ev-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.ev-row .full { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; }
@media (max-width: 520px) { .ev-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.mini-label { font-size: .7rem; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 3px; }
.podium { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.podium li { display: grid; grid-template-columns: 2.6em 1fr auto; gap: 8px; align-items: baseline; padding: 6px 0; border-top: 1px solid var(--line); }
.podium li:first-child { border-top: 0; }
.podium .medal { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; color: var(--clay); }
.podium .cb { display: block; font-size: .8rem; color: var(--muted); }
.result-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.shootoff { border: 2px dashed var(--clay); border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.lt .cbnote { font-size: .78rem; color: var(--muted); white-space: normal; }
.lt td.rs { color: var(--muted); }
.cb-order { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; letter-spacing: .03em; }
.demo-note { border-left: 3px solid var(--wait); padding: 6px 10px; background: var(--wait-soft); color: var(--ink); border-radius: 0 8px 8px 0; font-size: .9rem; margin: 0; }
/* brand */
.logo { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; background: #F2C21B; }
.logo.big { width: clamp(56px, 6vw, 96px); height: clamp(56px, 6vw, 96px); }
.brand-name .b25, .b25 { color: var(--clay); }
.poster-logo { position: absolute; right: 14px; top: 14px; width: clamp(72px, 18vw, 120px); height: auto; border-radius: 50%; pointer-events: none; }
.poster > :not(.poster-logo) { position: relative; }
.poster h1, .poster .eyebrow, .poster .when { padding-right: clamp(80px, 20vw, 130px); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* clubhouse TV scoreboard: one deliberate dark look, readable across a room */
.board { --b-bg: #0A0E0C; --b-panel: #131A16; --b-fg: #F5F2E7; --b-muted: #98A39C; --b-line: #26302A; --b-gold: #F2C21B; --b-red: #E5483B; --b-green: #4CC07C;
  background: var(--b-bg); color: var(--b-fg); min-height: 100vh; display: flex; flex-direction: column; gap: clamp(10px, 1.6vw, 22px);
  padding-block: clamp(10px, 1.5vw, 24px); padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); color-scheme: dark; }
.board-bar { display: flex; align-items: center; gap: clamp(10px, 1.5vw, 24px); }
.board-title { flex: 1; min-width: 0; }
.bt-app { font-size: clamp(.8rem, 1.2vw, 1.2rem); letter-spacing: .08em; text-transform: uppercase; color: var(--b-muted); font-weight: 600; }
.bt-app .b25 { color: var(--b-gold); }
.bt-comp { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.6rem, 4vw, 4rem); line-height: 1; text-wrap: balance; }
.board-clock { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.6rem, 4vw, 4rem); color: var(--b-gold); }
.board-ctrl { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.board-ctrl > :not(.menu) { opacity: .55; transition: opacity .2s; }
.board-ctrl:hover > *, .board-ctrl:focus-within > * { opacity: 1; }
.board-ctrl .btn.menu { border-color: var(--b-gold); color: var(--b-gold); text-decoration: none; }
.board-ctrl select { width: auto; max-width: 100%; min-height: 38px; background: var(--b-panel); color: var(--b-fg); border-color: var(--b-line); }
.board-ctrl .btn { background: var(--b-panel); color: var(--b-fg); border-color: var(--b-line); }
.board-main { flex: 1; display: grid; grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr); gap: clamp(12px, 2vw, 32px); align-items: start; }
@media (max-width: 760px) { .board-main { grid-template-columns: 1fr; } }
.board-table { min-width: 0; overflow-x: auto; }
.board-ev { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-family: var(--font-display); font-weight: 700; font-size: clamp(1.3rem, 2.8vw, 2.8rem); margin-bottom: clamp(6px, 1vw, 14px); }
.live-dot, .final { font-family: var(--font-body); font-size: clamp(.7rem, 1vw, 1rem); letter-spacing: .1em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; }
.live-dot { background: var(--b-red); color: #fff; }
.live-dot::before { content: "● "; }
.final { background: var(--b-gold); color: #1A1400; }
.bt { width: 100%; border-collapse: collapse; font-size: clamp(1rem, 1.9vw, 2rem); font-variant-numeric: tabular-nums; }
.bt th { text-align: center; font-size: .55em; letter-spacing: .1em; text-transform: uppercase; color: var(--b-muted); padding: 0 .4em .4em; border-bottom: 2px solid var(--b-line); }
.bt th:nth-child(2) { text-align: left; }
.bt td { padding: .28em .4em; border-bottom: 1px solid var(--b-line); text-align: center; white-space: nowrap; }
.bt tr:nth-child(-n+3) .bpos { color: var(--b-gold); }
.bt .bpos { font-family: var(--font-display); font-weight: 700; width: 2.2em; }
.bt .bname { text-align: left; font-weight: 600; }
.bt .bcl { color: var(--b-muted); }
.bt .br { color: var(--b-fg); }
.bt .tot { font-family: var(--font-display); font-weight: 700; font-size: 1.15em; color: var(--b-gold); }
.straight { display: inline-grid; place-items: center; min-width: 1.9em; height: 1.9em; border: .12em solid var(--b-red, #E5483B); border-radius: 50%; color: var(--b-red, #E5483B); font-weight: 700; line-height: 1; }
.cbt { font-size: .5em; vertical-align: middle; font-weight: 700; letter-spacing: .06em; padding: .15em .45em; border-radius: 4px; background: var(--b-line); color: var(--b-muted); }
.bmore { color: var(--b-muted); margin-top: 8px; font-size: clamp(.9rem, 1.2vw, 1.2rem); }
.board-side { display: flex; flex-direction: column; gap: clamp(10px, 1.4vw, 20px); min-width: 0; }
.bs-block { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 12px; padding: clamp(10px, 1.2vw, 18px); display: flex; flex-direction: column; gap: 6px; }
.bs-block.on { border-color: var(--b-red); }
.bs-h { font-size: clamp(.75rem, 1vw, 1.05rem); letter-spacing: .1em; text-transform: uppercase; color: var(--b-gold); font-weight: 700; }
.bs-big { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.1rem, 1.7vw, 1.8rem); }
.bs-row { display: grid; grid-template-columns: 2.4em 1fr auto; gap: 8px; align-items: baseline; font-size: clamp(1rem, 1.6vw, 1.7rem); }
.bs-row b { font-family: var(--font-display); color: var(--b-fg); }
.medal-n { font-family: var(--font-display); font-weight: 700; color: var(--b-gold); }
.bs-note { color: var(--b-muted); font-size: clamp(.85rem, 1.1vw, 1.15rem); }
.board-empty { font-size: clamp(1.2rem, 2.4vw, 2.4rem); color: var(--b-muted); padding: 1em 0; }
.board-empty span { font-size: .7em; }
.board-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; color: var(--b-muted); font-size: clamp(.8rem, 1.1vw, 1.15rem); }
.board-foot .dots { display: flex; gap: 8px; flex-wrap: wrap; }
.board-foot .dots span { padding: 4px 12px; border-radius: 999px; border: 1px solid var(--b-line); }
.board-foot .dots span.on { background: var(--b-gold); color: #1A1400; border-color: var(--b-gold); font-weight: 700; }
.legend-tv .straight { min-width: 1.7em; height: 1.7em; font-size: .9em; }
.lt .straight, .results .straight { --b-red: var(--miss); }
.member-list { max-height: 220px; overflow-y: auto; padding: 2px; }

html,body{margin:0}body{font-size:16px}[hidden]{display:none!important}.hdr-right{display:flex;align-items:center;gap:6px}
/* previous results */
.prev-list { padding: 0; gap: 0; }
.prev-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.prev-row:first-child { border-top: 0; }
.prev-row:hover, .prev-row:focus-visible { background: var(--bg); }
.prev-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prev-main b { overflow-wrap: anywhere; }
.prev-go { flex: none; font-weight: 700; color: var(--clay); white-space: nowrap; }
@media (max-width: 440px) { .tab { font-size: .88rem; letter-spacing: .02em; padding-left: 2px; padding-right: 2px; } }
/* winners sheet, my results, print */
.print-only { display: none; }
.win-head { display: flex; flex-direction: column; gap: 2px; }
.win-event { display: flex; flex-direction: column; gap: 10px; }
.win-event h3 { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; }
.mine-row { display: flex; justify-content: space-between; gap: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.mine-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mine-score { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
#mineBox { flex: 1; min-width: 0; }
@media print {
  :root, :root:not([data-theme="light"]), :root[data-theme="dark"] {
    --bg: #fff; --surface: #fff; --surface-2: #fff; --ink: #000; --muted: #444; --line: #bbb; --line-strong: #666; --clay: #7a5500; color-scheme: light;
  }
  @page { margin: 14mm; }
  body { background: #fff; font-size: 11pt; }
  body > *:not(#app), body::before { display: none !important; }
  .top, .sub-tabs, .chips, .btn, .no-print, .toast { display: none !important; }
  .main { max-width: none; padding: 0; }
  .print-only { display: block; }
  .row:has(> .btn), .row:has(> .pill) { display: none; }
  .panel, .win-event h2, .lt tr { break-inside: avoid; }
  .win-event h2 { break-after: avoid; }
  .panel { border-color: #bbb; padding: 8px 10px; }
  .result-groups { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .table-wrap { overflow: visible; border: 0; }
  .lt td, .lt th { padding: 4px 6px; }
}
