:root {

  --board-bg: #0a1628;

  --slot-cover: #163a62;

  --slot-cover-hi: #1e4a7a;

  --slot-revealed: #1e5a9e;

  --slot-revealed-hi: #2a6cb8;

  --slot-inactive-border: rgba(255, 255, 255, 0.35);

  --slot-text: #ffffff;

  --points-bg: #0f2844;

  --question-bg: #142238;

  --led-yellow: #f5c518;

  --led-blue: #2ea3ff;

  --strike-red: #e02424;

  --bank-gold: #ffd54a;

  --team-a: #2ea3ff;

  --team-b: #ff8c42;

  --host-bg: rgba(10, 22, 40, 0.96);

  --board-min-height: 76vh;

  --board-gap: clamp(0.5rem, 1.2vh, 0.85rem);

}



* {

  box-sizing: border-box;

}



html,

body {

  margin: 0;

  padding: 0;

  height: 100%;

  overflow: hidden;

  background: var(--board-bg);

  color: var(--slot-text);

  font-family: Arial, Helvetica, sans-serif;

}



.app {

  height: 100vh;

  height: 100dvh;

  display: flex;

  flex-direction: column;

}



.screen {

  flex: 1;

  display: flex;

  flex-direction: column;

  min-height: 0;

}



.screen[hidden] {

  display: none !important;

}



/* Setup */

.setup-screen {

  align-items: center;

  justify-content: center;

  padding: 1.5rem;

  overflow-y: auto;

}



.setup-card {

  width: min(420px, 100%);

  background: var(--question-bg);

  border: 2px solid rgba(245, 197, 24, 0.45);

  border-radius: 16px;

  padding: 1.75rem;

  text-align: center;

}



.setup-card h1 {

  margin: 0 0 0.35rem;

  font-size: 2rem;

  color: var(--bank-gold);

  text-transform: uppercase;

  letter-spacing: 0.06em;

}



.setup-tag {

  margin: 0 0 1.25rem;

  color: rgba(255, 255, 255, 0.7);

}



.setup-card label {

  display: block;

  text-align: left;

  margin-bottom: 0.75rem;

  font-size: 0.85rem;

  font-weight: 700;

}



.setup-card input {

  display: block;

  width: 100%;

  margin-top: 0.35rem;

  padding: 0.55rem 0.65rem;

  border-radius: 8px;

  border: 1px solid rgba(255, 255, 255, 0.25);

  background: #0a1628;

  color: #fff;

  font-size: 1rem;

}



.timer-settings {

  border: 1px solid rgba(255, 255, 255, 0.15);

  border-radius: 8px;

  padding: 0.65rem 0.75rem;

  margin: 0.75rem 0;

  text-align: left;

}



.timer-settings legend {

  font-size: 0.75rem;

  font-weight: 700;

  color: rgba(255, 255, 255, 0.65);

  padding: 0 0.25rem;

}



.timer-setting {

  display: inline-block;

  width: calc(50% - 0.35rem);

  margin-bottom: 0 !important;

  font-size: 0.78rem !important;

}



.timer-setting + .timer-setting {

  margin-left: 0.5rem;

}



.timer-setting input {

  margin-top: 0.25rem;

}



.setup-hint {

  font-size: 0.78rem;

  color: rgba(255, 255, 255, 0.55);

  margin: 0.5rem 0 1.25rem;

}



.setup-hint code {

  font-size: 0.72rem;

  color: var(--bank-gold);

}



.setup-loading-wrap {

  margin: 1rem 0 1.25rem;

}



.setup-loading {

  color: rgba(255, 255, 255, 0.75);

  margin: 0.75rem 0 0;

  font-size: 0.95rem;

}



.setup-loading--error {

  color: #ff8a80;

}



.setup-spinner {

  width: 2rem;

  height: 2rem;

  margin: 0 auto;

  border: 3px solid rgba(255, 255, 255, 0.15);

  border-top-color: var(--bank-gold);

  border-radius: 50%;

  animation: setup-spin 0.75s linear infinite;

}



.setup-spinner[hidden] {

  display: none;

}



@keyframes setup-spin {

  to {

    transform: rotate(360deg);

  }

}



.setup-retry {

  margin-top: 0.75rem;

}



.keyboard-split {

  display: grid;

  grid-template-columns: 1fr 1fr;

  gap: 0.5rem;

  margin: 0.75rem 0;

  font-size: 0.72rem;

  font-weight: 700;

}



.key-side {

  padding: 0.45rem 0.35rem;

  border-radius: 6px;

  text-align: center;

}



.key-side--left {

  background: rgba(46, 163, 255, 0.15);

  border: 1px solid rgba(46, 163, 255, 0.4);

  color: var(--team-a);

}



.key-side--right {

  background: rgba(255, 140, 66, 0.15);

  border: 1px solid rgba(255, 140, 66, 0.4);

  color: var(--team-b);

}



/* Host cheat sheet (?host=1) — same page sidebar */

.host-cheat {

  position: absolute;

  top: 4.5rem;

  right: 0.5rem;

  width: min(220px, 40vw);

  max-height: calc(var(--board-min-height) - 3rem);

  overflow-y: auto;

  background: rgba(0, 0, 0, 0.88);

  border: 1px solid rgba(245, 197, 24, 0.4);

  border-radius: 8px;

  padding: 0.5rem 0.65rem;

  z-index: 25;

  font-size: 0.72rem;

}



.host-cheat h3 {

  margin: 0 0 0.35rem;

  font-size: 0.7rem;

  letter-spacing: 0.1em;

  color: var(--bank-gold);

  text-transform: uppercase;

}



.host-cheat ol {

  margin: 0;

  padding-left: 1.1rem;

}



.host-cheat li {

  margin-bottom: 0.2rem;

  color: rgba(255, 255, 255, 0.85);

}



.host-cheat .cheat-num {

  color: var(--led-blue);

  font-weight: 700;

}



.host-cheat .cheat-revealed {

  opacity: 0.4;

  text-decoration: line-through;

}



/* Game layout — unified single page */

.game-screen {

  position: relative;

  min-height: 0;

  gap: var(--board-gap);

}



.score-header {

  flex-shrink: 0;

  display: flex;

  flex-direction: column;

  gap: 0.35rem;

  padding-bottom: 0.45rem;

  background: linear-gradient(180deg, #0d1e38 0%, var(--board-bg) 100%);

}



.score-strip {

  display: grid;

  grid-template-columns: 1fr auto 1fr;

  gap: 0.5rem;

  align-items: center;

  padding: 0.45rem 1.25rem 0;

}



.team-score {

  display: flex;

  flex-direction: column;

  gap: 0.15rem;

}



.team-score--b {

  text-align: right;

}



.team-label {

  font-size: clamp(0.9rem, 2.2vw, 1.35rem);

  font-weight: 700;

  letter-spacing: 0.08em;

  opacity: 0.85;

}



.team-score--a .team-label { color: var(--team-a); }

.team-score--b .team-label { color: var(--team-b); }



.team-total {

  font-size: clamp(2.4rem, 6vw, 4.5rem);

  font-weight: 700;

  line-height: 1;

}



.team-score--a.flash .team-total { color: var(--team-a); animation: scoreFlash 0.8s ease; }

.team-score--b.flash .team-total { color: var(--team-b); animation: scoreFlash 0.8s ease; }



.team-score--a.team-score--active .team-label,

.team-score--a.team-score--active .team-total {

  animation: teamGlowA 1.2s ease-in-out infinite;

}



.team-score--b.team-score--active .team-label,

.team-score--b.team-score--active .team-total {

  animation: teamGlowB 1.2s ease-in-out infinite;

}



@keyframes teamGlowA {

  0%, 100% { text-shadow: 0 0 8px rgba(46, 163, 255, 0.35); }

  50% { text-shadow: 0 0 18px rgba(46, 163, 255, 0.85); }

}



@keyframes teamGlowB {

  0%, 100% { text-shadow: 0 0 8px rgba(255, 140, 66, 0.35); }

  50% { text-shadow: 0 0 18px rgba(255, 140, 66, 0.85); }

}



.board-frame--team-a .board-inner {

  box-shadow: inset 0 0 40px rgba(46, 163, 255, 0.12);

}



.board-frame--team-b .board-inner {

  box-shadow: inset 0 0 40px rgba(255, 140, 66, 0.12);

}



@keyframes scoreFlash {

  0%, 100% { transform: scale(1); }

  40% { transform: scale(1.12); }

}



.round-meta {

  text-align: center;

}



.round-label {

  display: block;

  font-size: clamp(0.85rem, 2vw, 1.2rem);

  font-weight: 700;

  letter-spacing: 0.12em;

  color: var(--bank-gold);

  margin-bottom: 0.2rem;

}



.bank-caption {

  display: block;

  font-size: clamp(0.62rem, 1.4vw, 0.85rem);

  letter-spacing: 0.1em;

  opacity: 0.7;

}



.bank-value {

  font-size: clamp(2rem, 5vw, 3.5rem);

  font-weight: 700;

  color: var(--bank-gold);

  font-variant-numeric: tabular-nums;

  display: inline-block;

}



.bank-value.bank-pulse {

  animation: bankPulse 0.45s ease;

}



@keyframes bankPulse {

  0% { transform: scale(1); }

  40% { transform: scale(1.15); color: #fff; }

  100% { transform: scale(1); }

}



/* Workflow step bar — integrated under score strip */

.workflow-bar {

  display: flex;

  justify-content: center;

  gap: 0.35rem;

  padding: 0.35rem 1rem;

  flex-shrink: 0;

  background: rgba(0, 0, 0, 0.25);

}



.workflow-bar--integrated {

  background: transparent;

  padding: 0.15rem 1rem 0.35rem;

  margin-top: 0.1rem;

}



.workflow-step {

  font-size: 0.6rem;

  font-weight: 600;

  letter-spacing: 0.07em;

  text-transform: uppercase;

  padding: 0.18rem 0.55rem;

  border-radius: 999px;

  color: rgba(255, 255, 255, 0.38);

  border: 1px solid transparent;

}



.workflow-step--active {

  color: var(--bank-gold);

  border-color: rgba(245, 197, 24, 0.5);

  background: rgba(245, 197, 24, 0.12);

}



.workflow-step--done {

  color: rgba(255, 255, 255, 0.65);

}



/* Board stage — dominates viewport */

.board-stage {

  flex: 1 1 var(--board-min-height);

  min-height: 0;

  position: relative;

  display: flex;

  flex-direction: column;

  gap: var(--board-gap);

  margin: 0 1rem 0.5rem;

}



.board-frame {

  flex: 1;

  min-height: 0;

  position: relative;

  display: flex;

  align-items: stretch;

  justify-content: center;

}



.led-border {

  position: absolute;

  inset: 0;

  border-radius: 12px;

  padding: 4px;

  background: linear-gradient(135deg, var(--led-yellow), #fff8dc, var(--led-yellow));

  border: 3px solid var(--led-yellow);

  opacity: 0.95;

}



@supports (background: conic-gradient(from 0deg, red, blue)) {

  .led-border {

    border: none;

    background: conic-gradient(

      from var(--led-angle, 0deg),

      var(--led-yellow),

      #fff8dc,

      var(--led-yellow),

      transparent 25%

    );

    animation: ledSpin 3s linear infinite;

  }

}



.board-frame--blue .led-border {

  background: linear-gradient(135deg, var(--led-blue), #a8dcff, var(--led-blue));

  border-color: var(--led-blue);

}



@supports (background: conic-gradient(from 0deg, red, blue)) {

  .board-frame--blue .led-border {

    border: none;

    background: conic-gradient(

      from var(--led-angle, 0deg),

      var(--led-blue),

      #a8dcff,

      var(--led-blue),

      transparent 25%

    );

  }

}



@keyframes ledSpin {

  to { --led-angle: 360deg; }

}



@property --led-angle {

  syntax: '<angle>';

  initial-value: 0deg;

  inherits: false;

}



.board-inner {

  position: relative;

  flex: 1;

  margin: 4px;

  background: linear-gradient(180deg, #0c1830 0%, #081224 100%);

  border-radius: 8px;

  display: flex;

  flex-direction: column;

  min-height: 0;

  overflow: hidden;

  z-index: 1;

}



.question-bar {

  background: var(--question-bg);

  padding: clamp(1rem, 2.5vh, 1.5rem) 1.5rem clamp(1.1rem, 2.8vh, 1.65rem);

  text-align: center;

  border-bottom: none;

  flex: 0 0 auto;

  min-height: clamp(5.5rem, 14vh, 8rem);

  display: flex;

  flex-direction: column;

  justify-content: center;

  gap: clamp(0.35rem, 1vh, 0.65rem);

  overflow: visible;

  position: relative;

  z-index: 2;

}



.preamble {

  margin: 0;

  flex-shrink: 0;

  font-size: clamp(0.85rem, 2vw, 1.25rem);

  letter-spacing: 0.08em;

  text-transform: uppercase;

  color: rgba(255, 255, 255, 0.72);

  line-height: 1.25;

}



.question-text {

  margin: 0;

  font-size: clamp(1.15rem, 3.2vw, 2.35rem);

  font-weight: 700;

  text-transform: uppercase;

  line-height: 1.22;

  display: -webkit-box;

  -webkit-line-clamp: 3;

  -webkit-box-orient: vertical;

  overflow: hidden;

}



.question-text--long {

  font-size: clamp(0.95rem, 2.5vw, 1.75rem);

  line-height: 1.28;

}



.question-bar--blank .question-text,

.question-bar--blank .preamble {

  opacity: 0;

}



/* Answer grid — stacks below fixed question bar */

.board-grid {

  flex: 1 1 auto;

  min-height: 0;

  display: grid;

  gap: clamp(12px, 1.8vh, 20px);

  padding: clamp(0.85rem, 2vh, 1.35rem) clamp(1rem, 2.5vw, 1.5rem);

  align-content: center;

  align-items: stretch;

  overflow: hidden;

  position: relative;

  z-index: 1;

  border-top: 1px solid rgba(255, 255, 255, 0.07);

}



.board-grid--dual {

  grid-template-columns: 1fr 1fr;

  grid-auto-rows: minmax(0, 1fr);

}



.board-grid--single {

  grid-template-columns: 1fr;

  justify-items: center;

  grid-auto-rows: minmax(0, 1fr);

}



.board-grid--single .slot {

  width: 85%;

  max-width: none;

}



.slot {

  display: grid;

  grid-template-columns: 3rem 1fr 5rem;

  align-items: stretch;

  min-height: clamp(3rem, 8vh, 5.5rem);

  border-radius: 4px;

  overflow: hidden;

}



.slot--inactive {

  grid-template-columns: 1fr;

  border: 2px solid var(--slot-inactive-border);

  background: transparent;

  min-height: clamp(2rem, 5vh, 2.8rem);

}



.slot--inactive .slot-num,

.slot--inactive .slot-answer,

.slot--inactive .slot-points {

  display: none;

}



.slot-num {

  display: flex;

  align-items: center;

  justify-content: center;

  background: var(--slot-cover);

  font-weight: 700;

  font-size: clamp(1rem, 2.2vw, 1.5rem);

}



.slot-answer {

  display: flex;

  align-items: center;

  padding: 0 0.6rem;

  background: linear-gradient(180deg, var(--slot-cover-hi), var(--slot-cover));

  font-weight: 700;

  font-size: clamp(1rem, 2.4vw, 1.6rem);

  text-transform: uppercase;

  overflow: hidden;

}



.slot-points {

  display: flex;

  align-items: center;

  justify-content: center;

  background: var(--points-bg);

  font-weight: 700;

  font-size: clamp(1rem, 2.4vw, 1.5rem);

  font-variant-numeric: tabular-nums;

}



.slot--cover .slot-answer-text,

.slot--cover .slot-points-value {

  visibility: hidden;

}



.slot--cover .slot-answer::after {

  content: '';

  flex: 1;

  height: 60%;

  background: rgba(0, 0, 0, 0.25);

  border-radius: 2px;

}



.slot--revealed-answer .slot-answer,

.slot--revealed-answer .slot-num {

  background: linear-gradient(180deg, var(--slot-revealed-hi), var(--slot-revealed));

}



.slot--revealed-answer .slot-answer::after {

  display: none;

}



.slot--revealed-answer .slot-answer-text {

  visibility: visible;

  animation: flipIn 0.45s ease;

}



.slot--revealed-full .slot-points-value {

  visibility: visible;

  animation: popIn 0.35s ease;

}



@keyframes flipIn {

  from { transform: rotateX(-90deg); opacity: 0; }

  to { transform: rotateX(0); opacity: 1; }

}



@keyframes popIn {

  from { transform: scale(0.5); opacity: 0; }

  to { transform: scale(1); opacity: 1; }

}



.slot--hidden-row {

  visibility: hidden;

  height: 0;

  min-height: 0;

  margin: 0;

  padding: 0;

  overflow: hidden;

}



.board-footer {

  display: flex;

  align-items: center;

  justify-content: space-between;

  padding: clamp(0.65rem, 1.5vh, 1rem) clamp(1rem, 2.5vw, 1.5rem) clamp(0.85rem, 2vh, 1.15rem);

  gap: 0.75rem;

  flex: 0 0 auto;

  border-top: 1px solid rgba(255, 255, 255, 0.06);

}



.strikes {

  display: flex;

  gap: 0.6rem;

}



.strikes--tv .strike-slot {

  width: clamp(2.5rem, 6vw, 4.5rem);

  height: clamp(2.5rem, 6vw, 4.5rem);

  border: 3px solid rgba(255, 255, 255, 0.3);

  border-radius: 6px;

}



.strike-slot {

  width: 2rem;

  height: 2rem;

  border: 2px solid rgba(255, 255, 255, 0.25);

  border-radius: 4px;

  display: flex;

  align-items: center;

  justify-content: center;

  font-weight: 900;

  font-size: clamp(1.5rem, 4vw, 2.8rem);

  color: var(--strike-red);

}



.strike-slot.active {

  border-color: var(--strike-red);

  background: rgba(224, 36, 36, 0.2);

  animation: strikeSlam 0.3s ease;

  box-shadow: 0 0 20px rgba(224, 36, 36, 0.5);

}



.strike-slot.active::after {

  content: 'X';

}



@keyframes strikeSlam {

  0% { transform: scale(1.6); }

  60% { transform: scale(0.9); }

  100% { transform: scale(1); }

}



.multiplier-banner {

  font-weight: 900;

  font-size: clamp(0.95rem, 2.4vw, 1.5rem);

  letter-spacing: 0.15em;

  color: var(--bank-gold);

  text-shadow: 0 0 12px rgba(255, 213, 74, 0.5);

}



/* Timer badge — above board, never over question bar */

.timer-bar {

  flex-shrink: 0;

  display: flex;

  justify-content: flex-end;

  align-items: center;

  min-height: 0;

  padding: 0.35rem 0.75rem 0;

}



.timer-bar:has(.timer-overlay:not([hidden])) {

  min-height: 4.5rem;

  padding-bottom: 0.35rem;

}



.timer-overlay {

  position: relative;

  z-index: 19;

  display: flex;

  flex-direction: column;

  align-items: center;

  justify-content: center;

  min-width: clamp(4.5rem, 12vw, 8rem);

  padding: 0.4rem 0.75rem;

  border-radius: 12px;

  background: rgba(0, 0, 0, 0.72);

  border: 3px solid var(--bank-gold);

  box-shadow: 0 0 24px rgba(245, 197, 24, 0.35);

  pointer-events: none;

}



.timer-overlay[hidden] {

  display: none !important;

}



.timer-label {

  font-size: clamp(0.65rem, 1.5vw, 0.85rem);

  font-weight: 700;

  letter-spacing: 0.12em;

  text-transform: uppercase;

  color: rgba(255, 255, 255, 0.75);

  margin-bottom: 0.15rem;

}



.timer-count {

  font-size: clamp(2.5rem, 8vw, 5.5rem);

  font-weight: 900;

  line-height: 1;

  color: var(--bank-gold);

  font-variant-numeric: tabular-nums;

  text-shadow: 0 0 20px rgba(245, 197, 24, 0.6);

}



.timer-overlay--urgent {

  border-color: var(--strike-red);

  animation: timerPulse 0.5s ease infinite;

}



.timer-overlay--urgent .timer-count {

  color: var(--strike-red);

  text-shadow: 0 0 20px rgba(224, 36, 36, 0.6);

}



.timer-overlay--paused {

  border-color: var(--led-blue);

  box-shadow: 0 0 24px rgba(46, 163, 255, 0.45);

  animation: none;

}



.timer-overlay--paused .timer-label {

  color: var(--led-blue);

  font-size: clamp(0.75rem, 1.8vw, 1rem);

}



.timer-overlay--paused .timer-count {

  opacity: 0.85;

}



@keyframes timerPulse {

  0%, 100% { transform: scale(1); }

  50% { transform: scale(1.04); }

}



/* Dramatic strike overlay — full board stage slam */

.strike-overlay {

  position: absolute;

  inset: 0;

  z-index: 30;

  display: flex;

  align-items: center;

  justify-content: center;

  pointer-events: none;

  background: rgba(0, 0, 0, 0.55);

}



.strike-overlay[hidden] {

  display: none !important;

}



.strike-overlay-x {

  font-weight: 900;

  color: var(--strike-red);

  text-shadow:

    0 0 40px rgba(224, 36, 36, 0.9),

    0 0 80px rgba(224, 36, 36, 0.6),

    6px 6px 0 #8b0000,

    12px 12px 0 rgba(0, 0, 0, 0.45);

  line-height: 0.85;

  font-size: clamp(10rem, 42vmin, 28rem);

  animation: strikeOverlaySlam 0.65s cubic-bezier(0.2, 1.4, 0.4, 1) forwards;

  transform: scale(0);

  opacity: 0;

}



.strike-overlay.strike-overlay--show .strike-overlay-x {

  opacity: 1;

}



@keyframes strikeOverlaySlam {

  0% {

    transform: scale(4) rotate(-14deg);

    opacity: 0;

  }

  30% {

    transform: scale(0.75) rotate(6deg);

    opacity: 1;

  }

  50% {

    transform: scale(1.12) rotate(-3deg);

  }

  100% {

    transform: scale(1) rotate(0deg);

    opacity: 1;

  }

}



.not-on-board-flash {

  position: absolute;

  inset: 0;

  z-index: 17;

  display: flex;

  align-items: center;

  justify-content: center;

  pointer-events: none;

  background: rgba(139, 0, 0, 0.45);

}



.not-on-board-flash[hidden] {

  display: none !important;

}



.not-on-board-flash span {

  font-size: clamp(1.8rem, 6vw, 4.5rem);

  font-weight: 900;

  letter-spacing: 0.06em;

  color: #fff;

  text-transform: uppercase;

  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.8);

  animation: notOnBoardPop 0.9s ease forwards;

}



@keyframes notOnBoardPop {

  0% { transform: scale(0.6); opacity: 0; }

  20% { transform: scale(1.05); opacity: 1; }

  75% { transform: scale(1); opacity: 1; }

  100% { transform: scale(1); opacity: 0; }

}



.overlay {

  position: absolute;

  inset: 0;

  background: rgba(0, 0, 0, 0.55);

  display: flex;

  align-items: center;

  justify-content: center;

  z-index: 20;

  pointer-events: none;

  opacity: 0;

  transition: opacity 0.2s ease;

}



.overlay.overlay--show {

  opacity: 1;

}



.overlay-text {

  font-size: clamp(1.8rem, 6vw, 4rem);

  font-weight: 900;

  text-transform: uppercase;

  letter-spacing: 0.08em;

  color: var(--bank-gold);

  text-align: center;

  padding: 1rem;

  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.8);

  animation: overlayPop 0.35s ease;

}



@keyframes overlayPop {

  from { transform: scale(0.85); opacity: 0; }

  to { transform: scale(1); opacity: 1; }

}



.overlay--steal .overlay-text { color: var(--led-blue); }



.overlay--playpass .overlay-text {

  font-size: clamp(1.4rem, 5vw, 3rem);

  color: #fff;

}



.play-pass-bar {

  position: absolute;

  bottom: 12%;

  left: 50%;

  transform: translateX(-50%);

  display: flex;

  gap: 1rem;

  z-index: 22;

  width: min(520px, 90%);

}



.play-pass-bar[hidden] {

  display: none !important;

}



.btn-tv {

  flex: 1;

  padding: clamp(0.75rem, 2vw, 1.25rem) 1.5rem;

  font-size: clamp(1.2rem, 3.5vw, 2.2rem);

  letter-spacing: 0.12em;

  border-radius: 10px;

  border-width: 3px;

}



.buzz-zones {

  position: absolute;

  left: 0.75rem;

  right: 0.75rem;

  bottom: 0.35rem;

  top: auto;

  height: clamp(3.25rem, 11vh, 4.75rem);

  display: none;

  grid-template-columns: 1fr 1fr;

  gap: 0.5rem;

  z-index: 18;

  pointer-events: none;

}



.buzz-zones.buzz-zones--live {

  display: grid;

  pointer-events: auto;

}



.buzz-zones[hidden] {

  display: none !important;

}



.buzz-zone {

  display: flex;

  align-items: center;

  justify-content: center;

  padding: 0.35rem 0.5rem;

  font-weight: 700;

  font-size: clamp(0.85rem, 2vw, 1.35rem);

  letter-spacing: 0.06em;

  text-align: center;

  border-radius: 8px;

  opacity: 0.55;

  transition: opacity 0.15s, background 0.15s;

  cursor: pointer;

  user-select: none;

  -webkit-tap-highlight-color: transparent;

}



.buzz-zone--flash {

  opacity: 1;

  background: rgba(255, 255, 255, 0.08);

}



.buzz-zone--left.buzz-zone--flash { box-shadow: inset 0 0 80px var(--team-a); }

.buzz-zone--right.buzz-zone--flash { box-shadow: inset 0 0 80px var(--team-b); }



/* Host panel — always visible bottom strip */

.host-panel {

  flex-shrink: 0;

  background: var(--host-bg);

  border-top: 1px solid rgba(255, 255, 255, 0.1);

  max-height: 24vh;

  overflow-y: auto;

}



.host-toggle {

  width: 100%;

  padding: 0.4rem;

  background: rgba(255, 255, 255, 0.04);

  border: none;

  border-bottom: 1px solid rgba(255, 255, 255, 0.08);

  color: rgba(255, 255, 255, 0.7);

  font-size: 0.75rem;

  font-weight: 700;

  letter-spacing: 0.06em;

  cursor: pointer;

}



.host-body {

  padding: 0.85rem 1.25rem 1rem;

  min-height: 120px;

  display: flex;

  flex-direction: column;

  gap: 0.65rem;

}



.host-panel.collapsed .host-body {

  display: none;

}



.host-status {

  margin: 0;

  font-size: clamp(1.05rem, 2.2vw, 1.35rem);

  color: rgba(255, 255, 255, 0.92);

  font-weight: 700;

  line-height: 1.4;

}



#pauseTimerBtn[aria-pressed="true"] {

  color: var(--led-blue);

  border-color: rgba(46, 163, 255, 0.55);

  background: rgba(46, 163, 255, 0.12);

}



.host-guess {

  display: flex;

  gap: 0.65rem;

  margin-bottom: 0;

}



.host-guess input {

  flex: 1;

  padding: 0.75rem 1rem;

  border-radius: 10px;

  border: 1px solid rgba(255, 255, 255, 0.28);

  background: #0a1628;

  color: #fff;

  font-size: clamp(1.05rem, 2vw, 1.25rem);

  min-height: 2.75rem;

}



.host-guess .btn {

  padding: 0.65rem 1.15rem;

  font-size: clamp(0.95rem, 1.8vw, 1.1rem);

  min-height: 2.75rem;

}



.host-actions {

  display: flex;

  flex-wrap: wrap;

  gap: 0.55rem;

  align-items: center;

}



.host-primary {

  font-size: clamp(0.95rem, 1.8vw, 1.1rem);

  padding: 0.6rem 1rem;

}



.host-actions .btn {

  padding: 0.55rem 0.95rem;

  font-size: clamp(0.88rem, 1.6vw, 1rem);

}



.btn {

  padding: 0.45rem 0.75rem;

  border-radius: 8px;

  border: 1px solid rgba(255, 255, 255, 0.25);

  background: rgba(255, 255, 255, 0.08);

  color: #fff;

  font-size: 0.82rem;

  font-weight: 700;

  cursor: pointer;

}



.btn:hover:not(:disabled) { background: rgba(255, 255, 255, 0.14); }



.btn:focus-visible,

.host-toggle:focus-visible,

.host-guess input:focus-visible,

.setup-card input:focus-visible {

  outline: 2px solid var(--led-blue);

  outline-offset: 2px;

}



.btn:disabled,

.host-guess input:disabled {

  opacity: 0.45;

  cursor: not-allowed;

}



.btn-primary {

  background: var(--slot-revealed-hi);

  border-color: var(--led-blue);

}



.btn-play {

  background: #1f7a4c;

  border-color: #34d399;

}



.btn-pass {

  background: #7a4a1f;

  border-color: #f59e0b;

}



.btn-ghost {

  background: transparent;

}



.sr-only {

  position: absolute;

  width: 1px;

  height: 1px;

  padding: 0;

  margin: -1px;

  overflow: hidden;

  clip: rect(0, 0, 0, 0);

  border: 0;

}



@media (prefers-reduced-motion: reduce) {

  .led-border { animation: none; }

  .slot--revealed-answer .slot-answer-text,

  .slot--revealed-full .slot-points-value,

  .strike-slot.active,

  .strike-overlay-x,

  .not-on-board-flash span,

  .overlay-text,

  .bank-value.bank-pulse,

  .team-score--a.team-score--active .team-label,

  .team-score--a.team-score--active .team-total,

  .team-score--b.team-score--active .team-label,

  .team-score--b.team-score--active .team-total,

  .team-score.flash .team-total,

  .timer-overlay--urgent {

    animation: none;

  }

  .strike-overlay-x {

    transform: scale(1);

    opacity: 1;

  }

}



@media (max-width: 640px) {

  :root {

    --board-min-height: 62vh;

  }

  .board-grid--dual {

    grid-template-columns: 1fr;

  }

  .host-actions .btn {

    font-size: 0.82rem;

    padding: 0.45rem 0.65rem;

  }

  .play-pass-bar {

    bottom: 8%;

    gap: 0.5rem;

  }

  .host-cheat {

    max-height: 30vh;

    width: min(180px, 45vw);

  }

  .workflow-step {

    font-size: 0.58rem;

    padding: 0.2rem 0.4rem;

  }

}



/* Remote host + display sync */

.remote-host-setup {

  margin-top: 1.25rem;

  padding: 1rem;

  border: 1px solid rgba(255, 215, 0, 0.35);

  border-radius: 10px;

  background: rgba(0, 0, 0, 0.25);

}



.remote-host-title {

  margin: 0 0 0.35rem;

  font-size: 1rem;

  color: #ffd700;

}



.remote-host-desc {

  margin: 0 0 0.75rem;

  font-size: 0.85rem;

  opacity: 0.9;

}



.room-code-row {

  display: flex;

  align-items: center;

  gap: 0.75rem;

  margin: 0.75rem 0;

}



.room-code-label {

  font-size: 0.75rem;

  text-transform: uppercase;

  letter-spacing: 0.08em;

  opacity: 0.75;

}



.room-code-value {

  font-size: 1.75rem;

  font-weight: 800;

  letter-spacing: 0.2em;

  color: #ffd700;

}



.display-link-field {

  display: block;

  margin: 0.75rem 0;

  font-size: 0.8rem;

}



.display-link-field input {

  width: 100%;

  margin-top: 0.35rem;

  font-size: 0.75rem;

}



.display-conn-status {

  margin: 0.5rem 0 0;

  font-size: 0.85rem;

  color: #ffb347;

}



.display-conn-status.display-conn--ok {

  color: #7dff9a;

}



.host-answer-picker {

  margin-top: 0.75rem;

}



.host-picker-label {

  margin: 0 0 0.5rem;

  font-size: 0.85rem;

  font-weight: 600;

}



.host-answer-grid {

  display: grid;

  grid-template-columns: 1fr;

  gap: 0.4rem;

  max-height: 32vh;

  overflow-y: auto;

  margin-bottom: 0.5rem;

}



.host-answer-btn {

  display: grid;

  grid-template-columns: 2rem 1fr auto;

  align-items: center;

  gap: 0.5rem;

  padding: 0.55rem 0.65rem;

  border: 1px solid rgba(255, 215, 0, 0.45);

  border-radius: 8px;

  background: rgba(20, 40, 80, 0.85);

  color: #fff;

  text-align: left;

  cursor: pointer;

  font: inherit;

}



.host-answer-btn:hover {

  background: rgba(40, 70, 130, 0.95);

  border-color: #ffd700;

}



.host-answer-num {

  font-weight: 800;

  color: #ffd700;

}



.host-answer-pts {

  font-weight: 700;

  color: #7dff9a;

}



.btn-strike {

  width: 100%;

  margin-top: 0.25rem;

  background: rgba(180, 30, 30, 0.85);

  border: 1px solid rgba(255, 100, 100, 0.6);

  color: #fff;

  font-weight: 700;

}



body.display-mode .host-panel,

body.display-mode .host-cheat,

body.display-mode .play-pass-bar {

  display: none !important;

}



body.display-mode .game-screen {

  padding-bottom: 0;

}



body.remote-host-mode .host-guess {

  display: none;

}



body.remote-host-mode .host-panel {

  max-height: 38vh;

}



.host-buzz-row {

  display: flex;

  flex-wrap: wrap;

  align-items: center;

  gap: 0.5rem;

  margin-top: 0.65rem;

}



.host-buzz-label {

  font-size: 0.8rem;

  font-weight: 600;

  width: 100%;

}



body.display-mode .buzz-zones,

body.display-mode .workflow-bar {

  display: none !important;

}



body.display-mode .board-stage {

  padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right))

    max(12px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));

}



body.display-mode .question-text {

  font-size: clamp(1.1rem, 2.8vw, 2rem);

}



.display-conn-banner {

  position: fixed;

  top: 0;

  left: 0;

  right: 0;

  z-index: 9999;

  padding: 0.5rem 1rem;

  background: rgba(180, 60, 0, 0.92);

  color: #fff;

  text-align: center;

  font-weight: 600;

}



.display-chrome {

  position: fixed;

  bottom: max(8px, env(safe-area-inset-bottom));

  right: max(8px, env(safe-area-inset-right));

  z-index: 100;

  display: flex;

  gap: 0.35rem;

  opacity: 0.35;

  transition: opacity 0.2s;

}



.display-chrome:hover,

.display-chrome:focus-within {

  opacity: 1;

}


