/* The player page: two recordings, each on one screen. style.css is a copy of ../web/style.css. */
header.topbar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; padding: 10px 16px 6px; }
header.topbar h1 { margin: 0; font-size: 17px; }
header.topbar .spacer { flex: 1; }
.segmented { display: inline-flex; align-items: center; gap: 2px; padding: 2px; border: 1px solid var(--line); border-radius: 7px; background: var(--panel); }
.segmented button { border: 0; background: transparent; color: var(--dim); padding: 4px 11px; }
.segmented button[aria-pressed="true"] { background: #2a2233; color: var(--text); }
.help-link { color: var(--dim); text-decoration: none; border: 1px solid var(--line); border-radius: 6px; padding: 3px 10px; font-size: 13px; }
.help-link:hover { color: var(--text); border-color: var(--dim); }
.q-sample { display: inline-grid; place-items: center; width: 14px; height: 14px; border: 1px solid rgba(79, 227, 232, 0.55); border-radius: 50%; color: #4fe3e8; font: 700 9px/1 ui-monospace, Menlo, monospace; vertical-align: 1px; }

main { display: block; padding: 6px 16px 16px; }
[hidden] { display: none !important; }

/* brain + look-ahead: the highlights, as large as the screen allows */
.hl-wrap { position: relative; width: min(100%, calc((100vh - 124px) * 16 / 9)); aspect-ratio: 16 / 9; margin: 0 auto; }
html.embedded .hl-wrap { width: min(100%, calc((100vh - 100px) * 16 / 9)); }
#hl { display: block; width: 100%; height: 100%; background: #000; border: 1px solid var(--line); border-radius: 6px; }
.hl-hint { margin: 6px auto 0; max-width: 900px; color: var(--dim); font-size: 12px; text-align: center; }

/* brain alone: the game and its brain side by side */
.player { display: grid; justify-content: center; align-items: start; gap: 18px;
  grid-template-columns: max(300px, min(44vw, calc((100vh - 300px) * 240 / 224))) min(50vw, calc((100vh - 90px) * 1000 / 900)); }
.player .answer { gap: 14px; }
.player .dpad { grid-template: 24px 24px 24px / 24px 24px 24px; }
.player .ab span { width: 38px; height: 38px; }
.player .slots { min-width: 200px; }
.player .game, .player .brain { min-width: 0; }
.video-box { position: relative; }
#video { display: block; width: 100%; aspect-ratio: 240 / 224; background: #000; border: 1px solid var(--line); border-radius: 6px; image-rendering: pixelated; }
.player .stats { margin-top: 8px; }
.live-row { display: flex; gap: 12px; align-items: center; margin: 8px 0; }
#live { white-space: nowrap; }
#live.on { border-color: var(--on); color: var(--on); }
.note.bad { color: var(--accent); }
.note.good { color: #7ad08a; }
.player .answer-card { margin-top: 6px; padding: 10px 12px; }
.player .answer-card h2 { margin-bottom: 6px; }
.brain-head { display: flex; align-items: baseline; gap: 8px; margin: 0 0 6px; }
.brain-head h2 { margin: 0; }
.brain-stage { position: relative; }
#brainview { display: block; width: 100%; height: auto; background: #0b090e; border-radius: 6px; }

@media (max-width: 860px) {
  .player { grid-template-columns: minmax(0, 1fr); }
  .hl-wrap { width: 100%; }
}
