/* V718 replay review: a readable, shared TR/EN palette with native keyboard controls.
   This stylesheet never targets game canvases, camera scale or player geometry. */
:root {
  --bg: #0b1220;
  --panel: #111d2e;
  --panel-2: #18283c;
  --line: #617e9b;
  --text: #f1f5fb;
  --muted: #b8c7d9;
  --lime: #aee8c6;
  --cyan: #9edcff;
  --amber: #ffdc91;
  --danger: #ffabb0;
  font-family: Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}
body { background: var(--bg); line-height: 1.5; }
button, select, input, label, .fileButton { -webkit-tap-highlight-color: rgba(158,220,255,.2); }
button, select, .fileButton { min-height: 44px; touch-action: manipulation; }
button, .fileButton { font-weight: 650; transition: background .12s ease, border-color .12s ease; }
button:focus-visible, select:focus-visible, input:focus-visible, .fileButton:focus-within {
  outline: 3px solid #9edcff;
  outline-offset: 3px;
}
select, select option, select optgroup,
.replayCamera select, .replayCamera select option, .replayCamera select optgroup {
  color: var(--text); background: #18283c; color-scheme: dark;
}
select option:checked, .replayCamera select option:checked { color: #081522; background: #9edcff; }
select:disabled, .replayCamera select:disabled { color: var(--muted); background: #18283c; opacity: 1; }
.sideHead { padding: 18px 18px 10px; border-bottom: 1px solid var(--line); }
.sideHead h2 { color: var(--text); font-size: 1.04rem; font-weight: 700; line-height: 1.4; letter-spacing: .01em; text-transform: none; }
.filterBar { gap: 12px; padding: 16px 16px 10px; }
.filterGrid { gap: 12px; }
.filterBar label { color: #cbd8e8; font-size: .84rem; font-weight: 650; line-height: 1.4; letter-spacing: 0; text-transform: none; }
.filterBar select { padding: 10px 12px; font-size: .94rem; }
.clipCount { color: var(--muted); font-size: .84rem; line-height: 1.45; }
.eventList { padding: 10px 14px 16px; max-height: 540px; scrollbar-gutter: stable; overscroll-behavior: contain; }
.eventItem { grid-template-columns: 54px minmax(0,1fr); gap: 12px; min-height: 60px; padding: 12px; margin-bottom: 10px; background: #18283c; border: 1px solid #617e9b; border-radius: 10px; }
.eventItem:hover { border-color: #8abfdf; background: #233b54; }
.eventItem.active, .eventItem[aria-current="true"] { border-color: #9edcff; background: #26465f; box-shadow: inset 4px 0 0 #9edcff; }
.eventItem:focus-visible { outline-offset: -3px; }
.eventTime { color: #a7e1ff; font: 650 .83rem/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; font-variant-numeric: tabular-nums; }
.eventText b { color: var(--text); font-size: .94rem; font-weight: 650; line-height: 1.45; white-space: normal; overflow: visible; overflow-wrap: anywhere; }
.eventText small { color: #c5d2e2; font-size: .84rem; line-height: 1.5; white-space: normal; overflow: visible; overflow-wrap: anywhere; }
.passFacts { gap: 7px; padding: 9px 10px; border-color: #47637d; background: #122235; }
.passFact { grid-template-columns: minmax(80px,.9fr) minmax(0,1.6fr); gap: 10px; font-size: .81rem; line-height: 1.5; }
.passFact span:first-child { color: #b8c7d9; font-weight: 600; }
.badges { flex-direction: row; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.badge { color: #b6e5ff; border-color: #557b98; background: #132b41; padding: 3px 8px; font-size: .74rem; font-weight: 600; letter-spacing: 0; }
.sourceTag, .note, #tt662ReplayFlowStatus { font-size: .84rem; line-height: 1.55; }
.shotCard { border-color: #617e9b; background: #18283c; }
.shotCard .eventItem.active { box-shadow: inset 4px 0 0 #9edcff; }
.shotDetailsButton { color: #b6e5ff; background: #1f334b; border-color: #617e9b; padding: 10px 12px; font-size: .84rem; }
.shotDetailsButton:hover { background: #2c4862; }
#shotDetailsDialog, .replayCamera { background: #111d2e; border-color: #557b98; line-height: 1.55; }
#shotDetailsDialog table { font-size: .9rem; }
#shotDetailsDialog thead th { background: #20364a; color: #aee8c6; }
#shotDetailsDialog td, #shotDetailsDialog th { border-color: #617e9b; }
#shotDetailsDialog td:nth-child(2), .shotDetailsNote { color: #c5d2e2; }
.shotLearn, .shotFormulaCard { background: #18283c; border-color: #617e9b; }
.toggle, .cameraGrid label:not(.toggle) { font-size: .9rem; line-height: 1.5; }
.toggle { min-height: 44px; }
.toggle input { width: 18px; height: 18px; flex: 0 0 auto; }
.replayCompact684 { min-height: 44px; font-size: .84rem; }
@media (max-width: 640px) {
  .filterGrid { grid-template-columns: 1fr; }
  .filterField:first-child { grid-column: auto; }
  .filterBar select, .replayCamera select { font-size: 1rem; }
  .eventList { max-height: 420px; }
  .eventItem { grid-template-columns: 48px minmax(0,1fr); gap: 9px; }
  .passFact { grid-template-columns: minmax(74px,.9fr) minmax(0,1.6fr); }
  #shotDetailsDialog th, #shotDetailsDialog td { font-size: .84rem; }
  .cameraGrid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { button, .fileButton { transition: none; } button:active, .fileButton:active { transform: none; } }
@media (forced-colors: active) { .eventItem.active, .eventItem[aria-current="true"] { border: 2px solid Highlight; } }
