/* beeTXC event look: the logo's navy and amber on a deep navy ground, for the scorer, admin, and (later) the talent
   desk. One dark look by choice: it reads in a bright gym and matches the stream. /admin can override the tokens. */
:root {
  --ink: #081a30;        /* page ground */
  --panel: #0f2744;      /* raised surfaces */
  --panel2: #163456;     /* inputs, rows */
  --line: #24476f;
  --fg: #f3f7fc;
  --muted: #9fb4cc;
  --navy: #124272;       /* logo "bee" */
  --blue: #1872b4;       /* logo gradient */
  --amber: #f6a218;      /* logo "TXC" */
  --honey: #f6ba12;      /* the bee */
  --on-amber: #1a1200;
  --good: #2fbf71;
  --bad: #ef5350;
  --good-soft: rgba(47, 191, 113, .16);
  --bad-soft: rgba(239, 83, 80, .16);
  --amber-soft: rgba(246, 162, 24, .16);
  --display: 'Poppins', 'Avenir Next', 'Segoe UI', system-ui, sans-serif;
  --body: 'Source Sans 3', 'Segoe UI', system-ui, -apple-system, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--ink); color: var(--fg); }
body { font: 400 17px/1.45 var(--body); -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
[hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; }

/* top bar */
.bar { display: flex; align-items: center; gap: 14px; padding: 10px max(16px, env(safe-area-inset-right, 0px)) 10px max(16px, env(safe-area-inset-left, 0px));
  background: var(--panel); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
/* the logo's navy "bee" needs a light plate on the dark ground */
.bar img { height: 38px; width: auto; display: block; padding: 4px 8px; background: #f3f7fc; border-radius: 10px; }
.bar .where { font: 600 15px/1.2 var(--display); display: flex; flex-direction: column; }
.bar .where small { font: 500 13px var(--body); color: var(--muted); }
.bar .grow { flex: 1; }
.chip { display: inline-flex; align-items: center; gap: 6px; font: 600 12px/1 var(--display); letter-spacing: .04em; text-transform: uppercase;
  padding: 7px 10px; border-radius: 999px; background: var(--panel2); color: var(--muted); white-space: nowrap; }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.chip.live { background: var(--good-soft); color: var(--good); }
.chip.off { background: var(--bad-soft); color: var(--bad); }
.chip.amber { background: var(--amber-soft); color: var(--amber); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 10px 18px;
  border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); font: 600 16px var(--display); }
.btn:hover { border-color: var(--amber); }
.btn:disabled { opacity: .4; cursor: not-allowed; border-color: var(--line); }
.btn.primary { background: var(--amber); border-color: var(--amber); color: var(--on-amber); }
.btn.ghost { background: transparent; }
.btn.small { min-height: 38px; padding: 6px 12px; font-size: 14px; border-radius: 10px; }
.btn.danger { border-color: var(--bad); color: var(--bad); background: transparent; }
.btn svg { width: 20px; height: 20px; flex: none; }

/* pills */
.pill { display: inline-block; font: 600 11px/1 var(--display); letter-spacing: .05em; text-transform: uppercase; padding: 5px 8px; border-radius: 6px;
  background: var(--panel2); color: var(--muted); white-space: nowrap; vertical-align: middle; }
.pill.ret { background: var(--amber-soft); color: var(--amber); }
.pill.good { background: var(--good-soft); color: var(--good); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }

/* modal sheet */
.scrim { position: fixed; inset: 0; background: rgba(3, 10, 20, .72); display: grid; place-items: center; z-index: 20; padding: 16px; }
.sheet { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; width: min(560px, 100%); max-height: calc(100% - 32px);
  overflow: auto; padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.sheet h2 { margin: 0; font: 700 24px/1.15 var(--display); }
.sheet p { margin: 0; }
.sheet .row { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.sheet .list { display: flex; flex-direction: column; gap: 8px; }
.sheet .item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--panel2); }
.sheet .item .grow { flex: 1; min-width: 0; }

/* toast */
.toast { position: fixed; left: 50%; bottom: max(20px, env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 30;
  background: var(--fg); color: var(--ink); font: 600 15px var(--display); padding: 12px 18px; border-radius: 12px; max-width: calc(100% - 32px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .4); }
.toast.bad { background: var(--bad); color: #fff; }

@media (prefers-reduced-motion: no-preference) {
  .toast { animation: rise .2s ease-out; }
  @keyframes rise { from { transform: translate(-50%, 10px); opacity: 0; } }
}

/* the "i" that explains, on hover, tap, or focus */
.info { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-left: 8px; padding: 0; vertical-align: 2px; border-radius: 50%;
  border: 1.5px solid var(--muted); background: transparent; color: var(--muted); font: 700 12px/1 var(--display); text-transform: none; letter-spacing: 0; cursor: help; }
.info:hover, .info:focus-visible { border-color: var(--amber); color: var(--amber); }
.info.word { display: inline; width: auto; height: auto; margin: 0; border: 0; border-radius: 0; font: inherit; color: inherit; text-decoration: underline dotted var(--muted); text-underline-offset: 3px; }
.infopop { position: fixed; z-index: 60; background: var(--panel2); color: var(--fg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px;
  font: 400 15px/1.45 var(--body); box-shadow: 0 10px 30px rgba(0, 0, 0, .35); white-space: pre-line; }

/* a fact or answer the desk or pronouncer can mark as mentioned on air */
.notes { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; }
.notes.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.note { display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer;
  background: var(--panel2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.note:hover { border-color: var(--muted); }
.note .tick { flex: none; width: 24px; height: 24px; margin-top: 1px; border-radius: 50%; border: 2px solid var(--muted); display: grid; place-items: center; color: #06210f; }
.note .tick svg { width: 16px; height: 16px; }
.note .txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.note .txt small { font: 700 11px var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.note .by { font: 600 12px var(--display); color: var(--good); }
.note.used { background: transparent; border-style: dashed; }
.note.used .txt > span:not(.by) { color: var(--muted); }
.note.used .tick { background: var(--good); border-color: var(--good); }
.note.lie small { color: var(--bad); }

/* the word pattern strip on the scorer and the pronouncer */
.pattern { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; font-size: 14px; }
.pattern .plbl { display: inline-flex; align-items: center; gap: 4px; font: 700 11px var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.pattern .steps { display: inline-flex; gap: 4px; }
.pattern .steps b { min-width: 24px; height: 24px; padding: 0 4px; border-radius: 6px; display: grid; place-items: center; font: 700 13px var(--display);
  background: var(--panel2); color: var(--muted); border: 1px solid var(--line); }
.pattern .steps b.now { background: var(--amber); border-color: var(--amber); color: #1a1200; }
.pattern small { color: var(--muted); font-size: 13px; }
