:root { color-scheme: dark; font-family: "Trebuchet MS", system-ui, sans-serif; background: #15171b; color: #f1f1ef; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: radial-gradient(circle at 12% 0%, #30343d 0, transparent 32rem), #1e2026; }
html.embedded body { min-height: 0; }
main { width: min(1400px, calc(100% - 2rem)); margin: auto; padding: 2rem 0 4rem; }
.masthead { display: flex; align-items: end; justify-content: space-between; gap: 2rem; padding-bottom: 1.2rem; border-bottom: 1px solid #4a4d55; }
.kicker, label, .clock span, .stat-grid span { color: #9dbed4; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
h1, h2 { margin: 0; font-family: Georgia, serif; font-weight: 400; }
h1 { font-size: clamp(2.7rem, 6vw, 5rem); line-height: .9; background: linear-gradient(#ffc65f, #d48810); background-clip: text; color: transparent; filter: drop-shadow(0 2px 1px #000); }
.masthead p:last-child { margin: .8rem 0 0; color: #b8bac0; }
.clock { text-align: right; }.clock strong { display: block; margin-top: .25rem; font: 2rem Georgia, serif; }
.replay-grid { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 1.5rem; margin-top: 1.5rem; }
.map-panel, aside { border: 1px solid #4a4d55; background: rgba(12,13,16,.55); box-shadow: 0 3px 9px rgba(0,0,0,.22); }
.map-toolbar, .controls { display: flex; align-items: center; gap: 1rem; padding: .75rem 1rem; }
.map-toolbar { justify-content: space-between; border-bottom: 1px solid #3f4249; }.map-toolbar label { display: flex; align-items: center; gap: .7rem; }
select, button { border: 1px solid #5a5e67; background: #252830; color: #f1f1ef; padding: .48rem .65rem; font: inherit; }
button { min-width: 5rem; cursor: pointer; } button:hover { border-color: #4da9ff; }
.map-stage { position: relative; min-height: 28rem; aspect-ratio: 3 / 2; overflow: hidden; background: #282b31; }
.map-stage img { display: none; width: 100%; height: 100%; object-fit: fill; filter: saturate(.84) contrast(1.05) brightness(.78); }
.map-stage.has-image img { display: block; }.map-stage.has-image .map-grid { display: none; }
.map-grid { position: absolute; inset: 0; background-color: #2b3036; background-image: linear-gradient(rgba(169,202,223,.11) 1px, transparent 1px), linear-gradient(90deg, rgba(169,202,223,.11) 1px, transparent 1px); background-size: 10% 10%; }
.map-grid::after { position: absolute; inset: 50% auto auto 50%; content: "Map art unavailable"; color: #92959d; transform: translate(-50%,-50%); }
#route-layer { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.route-complete { fill: none; stroke: rgba(9,25,38,.78); stroke-width: 9; vector-effect: non-scaling-stroke; }
.route-played { fill: none; stroke: #59b8ff; stroke-width: 4; vector-effect: non-scaling-stroke; filter: drop-shadow(0 1px 2px #000); }
.event-marker { fill: #f0aa20; stroke: #101114; stroke-width: 2; vector-effect: non-scaling-stroke; }
.player-marker { fill: #fff; stroke: #d58e12; stroke-width: 4; vector-effect: non-scaling-stroke; filter: drop-shadow(0 2px 3px #000); }
.controls { border-top: 1px solid #3f4249; flex-wrap: wrap; }.controls input[type=range] { flex: 1 1 18rem; accent-color: #1990ff; }.follow { margin-left: auto; }
aside { padding: 1.2rem; } aside h2 { margin: 2rem 0 1rem; font-size: 1.5rem; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: #42454d; }.stat-grid div { padding: .8rem; background: #22252b; }.stat-grid strong { display: block; margin-top: .25rem; font: 1.3rem Georgia, serif; }
#events { margin: 0; padding: 0; list-style: none; }
#events li { padding: .65rem 0; border-top: 1px solid #383b42; color: #aeb1b8; font-size: .82rem; line-height: 1.45; }
#events li.current { color: #fff; } #events time { display: block; color: #8db9d6; font-size: .7rem; }
@media (max-width: 900px) { .replay-grid { grid-template-columns: 1fr; }.map-stage { min-height: 0; }.masthead { align-items: start; flex-direction: column; }.clock { text-align: left; } }
@media (max-width: 560px) { main { width: min(100% - 1rem, 1400px); padding-top: 1rem; }.map-toolbar, .controls { align-items: stretch; flex-direction: column; }.controls input[type=range] { width: 100%; flex-basis: auto; }.follow { margin-left: 0; } }
