/* The Know-It-All Arms: "Victorian pub sign" look (design direction B).
   Bottle-green walls with cream text; gold trim; cream "beer mat" cards with dark ink. */
:root {
  --bg: #133524; --bg-deep: #0e2a1c; --fg: #f3e7cc; --muted: #cdbf9f; --gold: #d9b25f; --gold-hi: #fff6dc;
  --card: #f3e7cc; --ink: #2a1a10; --ink-muted: #5a4630; --ink-gold: #8a5a17; --link: #6b3f0e;
  --ok: #1d6b38; --okbg: #dcefdf; --bad: #8f1d1d; --badbg: #f6dcd6; --track: #3c5a48;
  --display: 'Playfair Display', Georgia, serif; --body: 'Source Sans 3', system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; font: 1.0625rem/1.5 var(--body); background: var(--bg); color: var(--fg); min-height: 100vh; display: flex; flex-direction: column; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--card); color: var(--ink); padding: .5rem 1rem; z-index: 10; }
.skip:focus { left: 0; }
/* Visible on green and on cream: a dark ring inside a gold-white one. */
:focus-visible { outline: 3px solid var(--bg-deep); outline-offset: 1px; box-shadow: 0 0 0 6px var(--gold-hi); }
a { color: var(--gold); } a:hover { color: var(--gold-hi); }

/* Header: the hanging pub sign */
.top { padding: 1rem 1rem .75rem; display: flex; flex-direction: column; align-items: center; gap: .6rem; }
.sign { width: 100%; max-width: 28rem; border: 3px double var(--gold); border-radius: 999px; background: var(--bg-deep); padding: .55rem 1.25rem .6rem;
  display: flex; flex-direction: column; align-items: center; gap: .1rem; text-align: center; }
.est { font-size: .72rem; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.top h1 { margin: 0; font: 900 1.6rem/1.15 var(--display); letter-spacing: .01em; }
.controls { display: flex; flex-direction: column; gap: .35rem; align-items: center; color: var(--muted); font-size: .95rem; }
/* Hanging pub signs used by the difficulty picker. */
.switch { position: relative; display: inline-flex; align-items: center; cursor: pointer; min-height: 44px; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.sign-board { position: relative; display: inline-flex; align-items: center; gap: .6rem; min-height: 44px; padding: .4rem .95rem; margin-top: .5rem;
  background: var(--bg); border: 2px solid var(--gold); border-radius: 6px; box-shadow: inset 0 0 0 2px var(--bg), inset 0 0 0 3px var(--gold); }
.sign-board::before { content: ""; position: absolute; left: 50%; top: -.55rem; width: 55%; height: 3px; transform: translateX(-50%); background: var(--gold); border-radius: 99px; }
.switch:hover .sign-board { border-color: var(--gold-hi); }
.switch input:focus-visible + .sign-board { outline: 3px solid var(--gold-hi); outline-offset: 3px; }
.sign-name { font: 700 1.05rem/1.2 var(--display); color: var(--gold-hi); }
.sign-lamp { width: .7rem; height: .7rem; border-radius: 50%; border: 1px solid var(--gold); background: var(--track); flex: none; }

/* Difficulty picker on the menu: three hanging pub signs that wrap on a narrow screen. */
.diff-picker { border: 0; margin: .25rem 0 1rem; padding: 0; min-width: 0; }
.diff-picker legend { font: 700 1.15rem/1.3 var(--display); color: var(--gold-hi); padding: 0; margin-bottom: .2rem; }
.diff-help { margin: 0; color: var(--muted); font-size: .92rem; }
.diff-options { display: flex; flex-wrap: wrap; gap: .2rem .6rem; }
/* The strength on each question card: a small gold tag with the word, so the level is not only a colour. */
.diff-line { margin: .5rem 0 0; text-align: center; }
.diff-badge { display: inline-block; padding: .2rem .65rem; border-radius: 999px; background: var(--gold); color: #1a120a; border: 2px solid var(--gold-hi);
  font: 800 .72rem/1.2 var(--body); letter-spacing: .12em; text-transform: uppercase; }
/* The top-up line: one cream beer mat, announced once when the round starts. */
.diff-note { margin: .75rem 0 0; padding: .6rem .9rem; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; font-weight: 600; }

main { flex: 1; width: 100%; max-width: 40rem; margin: 0 auto; padding: .5rem 1rem 1.5rem; position: relative; }
h2 { font: 700 1.6rem/1.25 var(--display); margin: .5rem 0 1rem; }
h2:focus { outline: none; box-shadow: none; }
h2.sub { margin-top: 1.75rem; font-size: 1.25rem; }
#qtext { text-align: center; font-size: 1.65rem; margin: .4rem 0 1.1rem; }
/* Topic as a gold rule with the name in the middle */
.topic { display: flex; align-items: center; gap: .75rem; margin: 1rem 0 0; color: var(--gold); font-size: .78rem; font-weight: 700; letter-spacing: .25em; text-transform: uppercase; }
.topic::before, .topic::after { content: ""; flex: 1; height: 1px; background: var(--gold); }
.err { color: #ffb3a8; font-weight: 600; }
main > p { color: var(--muted); }

/* Buttons are beer mats: cream, gold rim, rounded */
button { font: inherit; cursor: pointer; min-height: 44px; padding: .55rem 1rem; border-radius: 18px; border: 2px solid var(--gold); background: var(--card); color: var(--ink); }
button:hover:not(:disabled) { border-color: var(--gold-hi); box-shadow: 0 0 0 2px var(--gold); }
button.primary { background: var(--gold); color: #1a120a; border-color: var(--gold); border-radius: 999px; font-weight: 700; padding: .65rem 1.5rem; margin: .75rem .5rem .5rem 0; }
button.link { border: 0; background: none; text-decoration: underline; color: var(--muted); padding-left: 0; }
button.link:hover:not(:disabled) { color: var(--gold-hi); box-shadow: none; }
main > button { margin-top: .5rem; }

.levels { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; }
.level { width: 100%; text-align: left; display: flex; flex-direction: column; gap: .1rem; padding: .85rem 1.1rem; }
.lname { font: 700 1.15rem/1.3 var(--display); }
.lmeta { color: var(--ink-muted); font-size: .92rem; }

/* Round status */
.stats { display: flex; flex-wrap: wrap; gap: .3rem 1rem; justify-content: space-between; align-items: center; font-weight: 700; color: var(--gold); }
.hearts { letter-spacing: .12em; font-size: 1.25rem; }
.streak.hot { color: var(--gold-hi); }
.timer { margin-top: .5rem; font-weight: 600; color: var(--muted); }
.timer.low { color: #ffb3a8; }
.bar { height: .5rem; background: var(--track); border-radius: 99px; overflow: hidden; }
.fill { height: 100%; width: 100%; background: var(--gold); transition: width 1s linear; }
.timer.low .fill { background: #e0705f; }


/* Answers: a 2 x 2 grid of beer mats */
.options { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.opt { min-height: 5.75rem; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .3rem; text-align: center; padding: .7rem .6rem; font-weight: 600; line-height: 1.3; position: relative; }
.key { font: 900 1.1rem/1 var(--display); color: var(--ink-gold); }
.opt:disabled { cursor: default; color: var(--ink); }
.opt:disabled:not(.right):not(.wrong) { opacity: .7; }
.opt.right { background: var(--gold); border: 3px solid var(--gold-hi); color: #1a120a; }
.opt.right .key { color: #1a120a; }
.opt.wrong { background: var(--badbg); border: 3px solid var(--bad); color: var(--ink); }
.opt.right::after, .opt.wrong::after { position: absolute; top: .45rem; right: .65rem; font-weight: 800; font-size: .8rem; letter-spacing: .04em; }
.opt.right::after { content: "✓ Correct"; color: #1a120a; }
.opt.wrong::after { content: "✗ Your pick"; color: var(--bad); }

/* Feedback card */
.feedback:empty { display: none; }
.feedback { margin-top: 1rem; padding: .9rem 1.1rem; border-radius: 18px; background: var(--card); color: var(--ink); border: 2px solid var(--gold); }
.feedback strong { font: 700 1.2rem var(--display); }
.feedback.ok strong { color: var(--ok); }
.feedback.bad strong { color: var(--bad); }
.feedback p { margin: .4rem 0; }
.feedback a { color: var(--link); word-break: break-word; }
.feedback a:hover { color: var(--ink); }
.hint { color: var(--muted); font-size: .9rem; text-align: center; }

/* Results */
.big { font: 900 3.2rem/1.1 var(--display); margin: .2rem 0; color: var(--gold); }
.newbest { font-weight: 700; color: var(--gold-hi); }
.summary { display: grid; grid-template-columns: auto 1fr; gap: .3rem 1rem; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .9rem 1.1rem; }
.summary dt { font-weight: 700; } .summary dd { margin: 0; }

.celebrate { position: fixed; left: 50%; top: 5rem; transform: translateX(-50%); padding: .6rem 1.3rem; border-radius: 99px; font: 800 1.05rem var(--display);
  background: var(--gold); color: #1a120a; border: 3px solid var(--gold-hi); box-shadow: 0 6px 20px rgba(0,0,0,.4); z-index: 5; animation: pop 2.2s ease both; }
.celebrate.c1 { background: var(--card); }
.celebrate.c2 { background: var(--gold-hi); font-size: 1.25rem; }
@keyframes pop { 0% { opacity: 0; transform: translate(-50%, 20px) scale(.6); } 15% { opacity: 1; transform: translate(-50%, 0) scale(1.1); }
  25% { transform: translate(-50%, 0) scale(1); } 85% { opacity: 1; } 100% { opacity: 0; } }
.shake { display: inline-block; animation: shake .4s; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

.notice { background: var(--bg-deep); color: var(--muted); border-top: 1px solid var(--gold); text-align: center; padding: .7rem 1rem; font-size: .88rem; }
.notice p { margin: .1rem 0; }
noscript .notice { display: block; }
@media (min-width: 40rem) { .levels { grid-template-columns: 1fr 1fr; } .top h1 { font-size: 1.9rem; } }

/* Mascot: the landlord in a gold oval portrait, speech on a cream card */
.mascot { display: flex; align-items: center; gap: .8rem; margin: .75rem 0 .25rem; }
.mascot-art { flex: none; width: 76px; height: 88px; border-radius: 50%; border: 3px solid var(--gold); background: var(--card); overflow: hidden; display: grid; place-items: center; }
.mascot-art svg { width: 70px; height: 70px; }
.bubble { margin: 0; padding: .6rem .9rem; background: var(--card); color: var(--ink); border-radius: 4px 16px 16px 16px; font-weight: 600; line-height: 1.35; }
.mascot .face { fill: #f2c9a5; stroke: #7a4b2a; stroke-width: 2; }
.mascot .shirt { fill: #ffffff; stroke: #5c4a36; stroke-width: 2; }
.mascot .apron { fill: #133524; }
.mascot .hair { fill: #8a8f96; }
.mascot .cheek { fill: #e88a7a; opacity: .7; }
.mascot .tache { fill: #5a3a22; }
.mascot .pint { fill: #c8811c; stroke: #6b4a12; stroke-width: 1.5; }
.mascot .foam { fill: #fffaf0; stroke: #b9ad94; stroke-width: 1; }
.mascot .eye { fill: #1f1a14; }
.mascot .mouth { stroke: #1f1a14; stroke-width: 3; stroke-linecap: round; }
.mascot .mouth-open { fill: #6b0f1a; stroke: #1f1a14; stroke-width: 2; }
.mascot .tear { fill: #4aa3ff; }
.mascot .m-happy, .mascot .m-sad { display: none; }
.mascot.mood-happy .m-neutral, .mascot.mood-sad .m-neutral { display: none; }
.mascot.mood-happy .m-happy, .mascot.mood-sad .m-sad { display: inline; }
.mascot.mood-happy .mascot-art { animation: hop .5s ease 2; }
.mascot.mood-sad .mascot-art { transform: rotate(-4deg); }
@keyframes hop { 50% { transform: translateY(-10px); } }

.report { display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; color: var(--ink-muted); font-size: .92rem; }
.report button.link { color: var(--ink-muted); padding: 0; min-height: 44px; }
.report button.link:hover:not(:disabled) { color: var(--ink); }
.chip-btn { min-height: 44px; padding: .2rem .8rem; border-radius: 999px; font-size: .9rem; }
.rate { display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; color: var(--ink-muted); }
.rate button { padding: .25rem .8rem; }

/* Last orders (true / false) */
.statement { font: 700 1.3rem/1.35 var(--display); background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .9rem 1.1rem; text-align: center; }
.tfrow { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.tf { display: flex; gap: .6rem; align-items: center; justify-content: center; font-weight: 700; padding: .9rem 1rem; min-height: 3.5rem; }
.tf-true { border-color: var(--ok); } .tf-false { border-color: var(--bad); }
.big-time { font: 700 1.4rem var(--display); color: var(--gold); }

/* Timeline */
.timeline { list-style: none; counter-reset: tl; margin: 1rem 0; padding: 0; display: grid; gap: .6rem; }
.tl-item { counter-increment: tl; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .55rem .8rem; }
.tl-item::before { content: counter(tl); font: 900 1rem var(--display); color: var(--ink-gold); width: 1.7rem; height: 1.7rem; display: grid; place-items: center; border-radius: 50%; border: 2px solid var(--gold); flex: none; }
.tl-item.right { background: var(--okbg); border-color: var(--ok); }
.tl-item.wrong { background: var(--badbg); border-color: var(--bad); }
.tl-text { flex: 1 1 12rem; }
.tl-btns { display: flex; gap: .4rem; }
.tl-btns button { min-width: 44px; font-weight: 800; }
.tl-year { flex-basis: 100%; color: var(--ink-muted); }
.srcs { padding-left: 1.2rem; font-size: .95rem; } .srcs a { word-break: break-word; }

/* Badges and progress */
.badges { list-style: none; margin: 1rem 0; padding: 0; display: grid; gap: .6rem; }
.badge { display: flex; gap: .8rem; align-items: center; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .65rem .95rem; }
.badge.earned { background: var(--gold); border-color: var(--gold-hi); color: #1a120a; }
.badge.locked { opacity: .75; }
.bicon { font-size: 2rem; } .btext { display: flex; flex-direction: column; }
.newbadge { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip { background: var(--gold); border: 2px solid var(--gold-hi); border-radius: 99px; padding: .2rem .8rem; font-weight: 700; color: #1a120a; }

.mapgrid { list-style: none; margin: 1rem 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .6rem; }
.tile { display: flex; flex-direction: column; gap: .15rem; border: 2px solid var(--gold); border-radius: 18px; padding: .65rem .85rem; background: var(--card); color: var(--ink); }
.tile .pct { font: 900 1.7rem var(--display); } .tile .meta { font-size: .85rem; color: var(--ink-muted); }
.tile .bar { background: #e2d4b3; }
.tile.lv-high { background: var(--okbg); border-color: var(--ok); }
.tile.lv-mid { background: #fbefc8; border-color: #8a6a00; }
.tile.lv-low { background: var(--badbg); border-color: var(--bad); }
.tile.lv-high .fill { background: var(--ok); } .tile.lv-mid .fill { background: #8a6a00; } .tile.lv-low .fill { background: var(--bad); }
.tile .fill { transition: none; }

.dailyshare { margin: .75rem 0; padding: .9rem 1.1rem; border-radius: 18px; background: var(--card); color: var(--ink); border: 2px solid var(--gold); }
.sharetext { margin: 0 0 .6rem; font-weight: 700; overflow-wrap: anywhere; word-break: break-word; }
.sharerow { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.sharerow button.primary { margin: 0; }
.copied { color: var(--ok); font-weight: 700; }
.sharefallback { position: fixed; left: -999px; top: 0; }
.share { margin: .75rem 0; }
.sharecard { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-top: .6rem; }
.sharecard img { border: 2px solid var(--gold); border-radius: 12px; max-width: 100%; height: auto; }
.sharecard .dl { font-weight: 700; }
.confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 20; }
@media (prefers-reduced-motion: reduce) {
  .celebrate, .shake { animation: none; }
  .fill { transition: none; }
  .mascot.mood-happy .mascot-art { animation: none; }
  .confetti { display: none; }
}

/* Sign-in: the header control (cream beer mat with gold text), the premium badge, and the dialog */
.auth { display: flex; flex-wrap: wrap; gap: .4rem .6rem; align-items: center; justify-content: center; }
.auth[hidden] { display: none; }
.auth-name { color: var(--gold-hi); font-weight: 700; max-width: 11rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.auth-btn { min-height: 44px; padding: .35rem 1rem; border-radius: 999px; font-weight: 700; background: var(--gold); color: #1a120a; border-color: var(--gold); }
.m-host .badge { display: inline-block; padding: .1rem .6rem; border-radius: 999px; background: var(--gold); color: #1a120a; border: 2px solid var(--gold-hi);
  font-size: .75rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; align-self: flex-start; margin-top: .3rem; }
.m-host .badge.owned { background: var(--gold-hi); box-shadow: 0 0 0 2px var(--gold); }
.hostnote { color: var(--gold-hi); font-weight: 700; margin: .4rem 0 0; }

.auth-back { position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(14, 42, 28, .82); display: flex; align-items: center; justify-content: center;
  padding: 1rem; z-index: 30; }
.auth-box { background: var(--card); color: var(--ink); border: 3px double var(--gold); border-radius: 18px; padding: 1.1rem 1.2rem; width: 100%; max-width: 24rem;
  max-height: 100%; overflow: auto; }
.auth-box h2 { font-size: 1.45rem; margin: 0 0 .6rem; color: var(--ink); }
.auth-field { display: block; font-weight: 700; margin: .7rem 0 .3rem; }
.auth-box input[type="text"], .auth-box input[type="email"] { width: 100%; min-height: 44px; font: inherit; padding: .5rem .7rem; border: 2px solid var(--gold);
  border-radius: 12px; background: #fffdf6; color: var(--ink); }
.auth-check { display: flex; gap: .5rem; align-items: center; min-height: 44px; cursor: pointer; }
.auth-check input { width: 1.2rem; height: 1.2rem; accent-color: var(--gold); }
.auth-provider { display: block; width: 100%; margin: .5rem 0 0; text-align: center; font-weight: 700; }
.auth-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .8rem; align-items: center; }
.auth-actions button { margin: 0; }
.auth-msg { min-height: 1.4em; margin: .7rem 0 0; font-weight: 700; color: var(--ok); }
.auth-msg.err { color: var(--bad); }

/* Landlord host mode (premium). Setup and the run use the beer-mat cards and the gold sign-board look. Everything stays
   one column at 360px with no sideways scroll; the TV view (.tv) is bigger from 1280px. */
.host-offers { color: var(--fg); padding-left: 1.2rem; margin: .5rem 0 1rem; }
.host-offers li { margin: .3rem 0; }
.host-lock { font-weight: 700; color: var(--gold-hi); }
.host-field { display: flex; flex-direction: column; gap: .25rem; margin: .6rem 0; min-width: 0; }
.host-field label, .host-label { font-weight: 700; color: var(--gold-hi); }
.host-input, .host-select { width: 100%; min-width: 0; min-height: 44px; font: inherit; padding: .45rem .6rem; border: 2px solid var(--gold);
  border-radius: 12px; background: var(--card); color: var(--ink); }
.host-group { border: 0; margin: .8rem 0 0; padding: 0; min-width: 0; }
.host-group legend, .host-round legend { font: 700 1.15rem/1.3 var(--display); color: var(--gold-hi); padding: 0; }
.host-list { list-style: none; margin: .4rem 0 0; padding: 0; display: grid; gap: .5rem; }
.host-row { display: flex; flex-wrap: wrap; gap: .3rem .5rem; align-items: center; }
.host-row .host-label { flex: 1 1 100%; }
.host-row .host-input { flex: 1 1 8rem; width: auto; }
.host-small { min-height: 44px; padding: .3rem .8rem; }
.host-round { border: 2px solid var(--gold); border-radius: 18px; background: var(--card); color: var(--ink); padding: .5rem .9rem .8rem; margin: .8rem 0 0; min-width: 0; }
.host-round legend { color: var(--ink); }
.host-round .host-field label { color: var(--ink); }
.host-grid { display: grid; gap: 0 .8rem; grid-template-columns: 1fr; }
@media (min-width: 30rem) { .host-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.host-err { font-weight: 700; color: #ffb3a8; }
.host-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; align-items: center; }
.host-actions button { margin: 0; }
.host-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .4rem .8rem; }
.host-bar button { margin: 0; }
.host-progress { margin: 0; color: var(--gold); font-weight: 700; }
.host-warn { font-weight: 700; color: #ffb3a8; }
.host-resume-note { margin: 1rem 0; }
.host-resume-note button { margin: .5rem 0 0; }
.host-resume { background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .9rem 1.1rem; margin: .5rem 0 1rem; }
.host-resume h3 { font: 700 1.2rem var(--display); margin: 0 0 .3rem; }
.host-resume button { margin: .6rem .5rem 0 0; }
.tv-round { margin: .5rem 0 0; text-align: center; color: var(--gold); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; font-size: .85rem; }
.tv-count { margin: .2rem 0 0; text-align: center; color: var(--muted); }
.tv-q { font: 700 1.5rem/1.25 var(--display); text-align: center; margin: .6rem 0 1rem; overflow-wrap: anywhere; }
.tv-opts { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.tv-opt { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .7rem; padding: .7rem .9rem; border-radius: 18px; background: var(--card); color: var(--ink);
  border: 3px solid transparent; font-weight: 600; min-width: 0; }
.tv-key { font: 900 1.2rem/1 var(--display); color: var(--ink-gold); }
.tv-text { flex: 1 1 10rem; min-width: 0; overflow-wrap: anywhere; }
/* The revealed answer: gold, a ring, and the words "Correct answer" with a tick, so colour is not the only cue. */
.tv-opt.is-correct { background: var(--gold); border-color: var(--gold-hi); color: #1a120a; }
.tv-opt.is-correct .tv-key { color: #1a120a; }
.tv-tag { font-weight: 800; font-size: .9rem; letter-spacing: .03em; }
.host-scores { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; gap: .6rem; }
.host-scores li { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .7rem; background: var(--card); color: var(--ink); border: 2px solid var(--gold);
  border-radius: 18px; padding: .6rem .9rem; }
.host-scores label { flex: 1 1 8rem; min-width: 0; font-weight: 700; overflow-wrap: anywhere; }
.host-num { width: 6rem; flex: 0 0 6rem; text-align: center; font-weight: 800; }
.host-total { min-width: 5.5rem; text-align: right; font-weight: 700; }
.host-table { width: 100%; border-collapse: collapse; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; }
.host-table th, .host-table td { padding: .5rem .7rem; border-bottom: 1px solid var(--gold); text-align: left; overflow-wrap: anywhere; }
.host-signoff { margin: 1rem 0 0; padding: .9rem 1.1rem; background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px;
  font: 600 1.1rem/1.4 var(--display); }
@media (min-width: 1280px) {
  #app.host-tv { max-width: 72rem; }
  .tv-round { font-size: 1.1rem; }
  .tv-count { font-size: 1.15rem; }
  .tv-q { font-size: 2.9rem; line-height: 1.2; margin: .8rem 0 1.6rem; }
  .tv-opts { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .tv-opt { font-size: 1.7rem; padding: 1.2rem 1.4rem; min-height: 6rem; }
  .tv-key { font-size: 2rem; }
  .tv-tag { font-size: 1.1rem; }
}

/* Picture questions: a framed print above the question, sized to fit (360px on a phone, wider on bigger screens) and never
   taller than 45% of the screen. The credit sits under it in small text. A missing picture is a dashed note, not a gap. */
.picture { margin: .6rem auto .2rem; max-width: 100%; text-align: center; }
.picture-slot { display: flex; justify-content: center; }
.picture img { display: block; width: 100%; max-width: 360px; height: auto; max-height: 45vh; object-fit: contain; margin: 0 auto;
  padding: .4rem; box-sizing: border-box; background: var(--card); border: 3px solid var(--gold); border-radius: 12px; }
.picture figcaption { margin-top: .35rem; font-size: .8rem; color: var(--muted); }
@media (min-width: 40rem) { .picture img { max-width: 640px; } }
@media (min-width: 1280px) { .picture img { max-width: 1280px; } }
.picture-missing { margin: 0 auto; max-width: 360px; padding: .6rem .9rem; border: 2px dashed var(--gold); border-radius: 12px; color: var(--gold-hi); font-weight: 700; text-align: center; }

/* The answer sheet: hidden on screen. When printed, only the sheet shows, in black on white. */
.print-sheet { display: none; }
@media print {
  body > :not(.print-sheet) { display: none !important; }
  body { display: block; min-height: 0; background: #fff; color: #000; font: 12pt/1.45 Georgia, 'Times New Roman', serif; }
  .print-sheet { display: block; color: #000; background: #fff; }
  .print-sheet * { color: #000 !important; background: #fff !important; border: 0 !important; box-shadow: none !important; }
  .print-sheet h1 { font-size: 22pt; margin: 0 0 .2em; }
  .print-sheet h2 { font-size: 14pt; margin: 1em 0 .3em; border-bottom: 1px solid #000 !important; }
  .print-sheet .sheet-q { break-inside: avoid; margin: 0 0 .7em; }
  .print-sheet .sheet-qt { font-weight: 700; margin: 0; }
  .print-sheet .sheet-opts { list-style: none; margin: .2em 0 .2em 1.2em; padding: 0; }
  .print-sheet .sheet-ans { margin: .2em 0 0; font-weight: 700; }
  .picture img { max-height: 8cm; max-width: 100%; width: auto; border: 0; background: #fff; padding: 0; }
  .picture figcaption { color: #000; font-size: 9pt; }
}

/* Privacy page: cream beer-mat card on the green wall */
.privacy { background: var(--card); color: var(--ink); border: 3px double var(--gold); border-radius: 18px; padding: 1.1rem 1.2rem; margin-top: .5rem; }
.privacy h1 { font: 900 1.9rem/1.2 var(--display); margin: .25rem 0; }
.privacy h2 { font: 700 1.25rem/1.25 var(--display); margin: 1.4rem 0 .4rem; }
.privacy p, .privacy li { color: var(--ink); }
.privacy ul { padding-left: 1.2rem; margin: .3rem 0 .6rem; }
.privacy li { margin: .25rem 0; }
.privacy .updated, .privacy .back { color: var(--ink-muted); font-size: .92rem; margin: .2rem 0; }
.privacy a { color: var(--link); }
.privacy a:hover { color: var(--ink-gold); }

/* Accounts, challenges and the limit screen: the same cream card and gold border as the sign-in dialog and the summary. */
.signin-panel { margin: 1rem 0; }
.signin-panel h2 { color: var(--ink); }
.signin-panel .auth-provider { margin-top: .4rem; }
.account { margin-top: 1.2rem; display: flex; flex-direction: column; align-items: flex-start; gap: .4rem; }
.account-who { margin: 0; color: var(--muted); }
.delete-confirm { background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 14px; padding: .8rem 1rem; }
.delete-confirm button { margin: .3rem .3rem 0 0; }
.versus, .challenge-box, .premium-note { background: var(--card); color: var(--ink); border: 2px solid var(--gold); border-radius: 18px; padding: .9rem 1.1rem; margin: .8rem 0; }
.versus .big { color: var(--ink); }
.challenge-box input { margin: .3rem 0 .6rem; }
.premium-note h3 { margin: 0 0 .3rem; font-family: var(--display); }
.challenge-note { color: var(--gold-hi); font-weight: 700; }

/* A quieter pub entrance: compact controls, then the daily quiz before the sign-in invitation. */
.top { max-width: 56rem; width: 100%; margin: auto; padding-top: 1.2rem; gap: .8rem; }
.controls { width: min(100%, 28rem); display: grid; grid-template-columns: 1fr auto; gap: 0 .75rem; }
.controls .switch { grid-column: 1; grid-row: 1; justify-self: start; }
.controls .auth { grid-column: 2; grid-row: 1 / span 2; justify-self: end; }
.sign-board { margin-top: .15rem; }
.sign-board::before { display: none; }
.menu-eyebrow { margin: 1rem 0 .25rem; font: 800 .72rem/1.4 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }
body[data-screen="menu"] #h { margin-bottom: .4rem; font-size: clamp(1.7rem, 6vw, 2.25rem); }
body[data-screen="menu"] .m-daily { position: relative; min-height: 7.5rem; border-radius: 12px; padding: 1.1rem 1.2rem; border-width: 3px; box-shadow: 0 5px 0 #091e14; }
body[data-screen="menu"] .m-daily .lname { font-size: 1.35rem; }
.signin-panel { max-width: none; border: 0; border-top: 1px solid var(--gold); border-radius: 0; background: transparent; color: var(--fg); padding: 1.25rem 0 .4rem; margin-top: 1.8rem; box-shadow: none; }
.signin-panel h2, .signin-panel h2.sub { color: var(--fg); font-size: 1.3rem; margin-top: 0; }
.signin-panel p { color: var(--muted); margin: .5rem 0; }
.signin-panel .auth-provider { border-radius: 8px; min-height: 48px; }
.signin-panel .auth-msg.err { color: #ffb3a8; }
.host-teaser { margin: 1.4rem 0 .5rem; padding: 1rem 0; display: flex; flex-direction: column; gap: .4rem; border-top: 1px solid var(--track); color: var(--fg); text-decoration: none; }
.host-teaser .menu-eyebrow { margin: 0; }
.host-teaser strong { font: 700 1.35rem var(--display); }
.host-teaser > span:not(.menu-eyebrow):not(.host-teaser-link) { color: var(--muted); }
.host-teaser-link { color: var(--gold); text-decoration: underline; font-weight: 700; }
.daily-feature { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 1rem; margin: .9rem 0 1.6rem; padding: clamp(1rem, 4vw, 1.4rem); border: 2px solid var(--gold); border-radius: 20px; background: var(--card); color: var(--ink); }
.daily-feature .menu-eyebrow { margin: 0; color: var(--ink-gold); }
.daily-feature h2 { margin: .2rem 0 .35rem; color: var(--ink); font-size: clamp(1.45rem, 5vw, 2rem); }
.daily-feature-note { margin: .25rem 0 .6rem; color: var(--ink-muted); }
.daily-feature button.m-daily { width: auto; min-height: 48px; margin: .35rem 0 0; padding: .65rem 1.5rem; border-radius: 999px; background: var(--gold); color: #1a120a; border-color: var(--gold); font-weight: 700; text-align: center; align-items: center; }
.daily-mark { width: 5.5rem; height: 5.5rem; border: 2px solid var(--gold); border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--ink-gold); line-height: 1.05; }
.daily-mark strong { font: 900 2.8rem/1 var(--display); }
.daily-mark span { margin-top: .2rem; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.daily-feature:focus-within { outline: 3px solid var(--gold-hi); outline-offset: 3px; }
.signin-recovery { padding: .9rem 1rem; border-left: 4px solid var(--gold); background: var(--bg-deep); margin-bottom: 1rem; }
.signin-recovery p { margin: .35rem 0 0; color: var(--muted); }
body[data-screen="question"] .est { display: none; }
body[data-screen="question"] .top { padding-top: .65rem; }
body[data-screen="question"] .top h1 { font-size: 1.15rem; }
body[data-screen="question"] .sign { padding: .4rem .8rem; }
.plan-page { max-width: 56rem; }
.plan-intro { max-width: 38rem; margin-bottom: 2rem; }
.plan-intro h1 { font: 900 clamp(2rem, 6vw, 3rem)/1.12 var(--display); margin: .4rem 0 .8rem; }
.plan-status { display: inline-block; padding: .25rem .65rem; border: 1px solid var(--gold); border-radius: 4px; font-weight: 700; }
.plan-comparison { display: grid; gap: 1.5rem; }
.plan-column { border-top: 3px solid var(--gold); padding-top: 1rem; }
.plan-column h2 { margin-top: 0; }
.plan-column ul { padding-left: 1.2rem; }
.plan-column li { margin: .6rem 0; }
.plan-column p { color: var(--muted); }
.plan-link { display: inline-block; min-height: 44px; padding: .65rem 1rem; border: 2px solid var(--gold); border-radius: 8px; background: var(--gold); color: var(--ink); font-weight: 800; text-decoration: none; }
.plan-link:hover { color: var(--ink); background: var(--gold-hi); }
@media (min-width: 48rem) {
  .top { flex-direction: row; justify-content: space-between; padding: 1.5rem 1rem 1rem; }
  .sign { max-width: 26rem; }
  .controls { width: auto; }
  .plan-comparison { grid-template-columns: 1fr 1fr; gap: 3rem; }
}
@media (max-width: 24rem) { .auth-name { max-width: 5.5rem; } .sign-name { font-size: .95rem; } .controls { column-gap: .4rem; } }
