@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Space+Grotesk:wght@400;500;600;700&display=swap');
:root { --ink:#f4f1e9; --muted:#8c918e; --yellow:#ffd43b; --green:#57ef9b; --red:#ff5c65; --line:#4d5552; }
* { box-sizing:border-box; }
body { margin:0; background:radial-gradient(circle at 50% -20%,#26302d 0,#101313 48%); color:var(--ink); font-family:'Space Grotesk',Arial,sans-serif; min-height:100vh; }
.app-shell { max-width:1500px; margin:auto; padding:48px 28px 28px; }
.hero { display:flex; justify-content:space-between; align-items:end; gap:28px; margin-bottom:34px; }
.eyebrow,.small-label,.display-topline,.hint,footer,.live-pill,.speed-control { font-family:'DM Mono',monospace; letter-spacing:.1em; text-transform:uppercase; }
.eyebrow { color:var(--yellow); font-size:12px; margin:0 0 15px; }
.hero h1 { font-size:clamp(2.4rem,6vw,5.6rem); line-height:.94; letter-spacing:-.07em; margin:0; }
.intro { color:var(--muted); font-size:18px; margin:19px 0 0; max-width:550px; }
.live-pill { font-size:11px; border:1px solid #35403d; border-radius:100px; padding:11px 14px; white-space:nowrap; color:#c2cbc7; }
.live-dot { display:inline-block; width:7px; height:7px; background:var(--green); border-radius:50%; margin-right:8px; }
.display-card { background:#080a0a; border:1px solid #38413e; border-radius:18px; padding:27px 28px 25px; box-shadow:0 24px 80px #0008; }
.display-topline { display:flex; justify-content:space-between; color:#a6aaa6; font-size:12px; border-bottom:1px solid #29302e; padding-bottom:18px; }
.route-name { color:var(--yellow); }
.journey-heading { display:flex; justify-content:space-between; align-items:end; padding:22px 0 0; }
.small-label { color:#919b95; font-size:12px; display:block; margin-bottom:8px; }
.journey-heading strong { font-size:clamp(1.45rem,3.2vw,3rem); letter-spacing:-.05em; }
.destination { text-align:right; }
.route-viewport { width:100%; min-width:0; }
#routeMap { display:block; width:100%; height:auto; }
.route-track,.route-fill { fill:none; stroke-width:8; stroke-linecap:round; }
.route-track { stroke:var(--line); }
.route-fill { stroke:var(--yellow); stroke-dasharray:1; stroke-dashoffset:1; }
.station-name { fill:#b0b9b2; font:500 17px 'Space Grotesk',Arial,sans-serif; }
.label-leader { stroke:#68736c; fill:none; stroke-width:1; }
.station-marker { fill:#080a0a; stroke:var(--line); stroke-width:4; }
.station-halo { fill:none; stroke:transparent; stroke-width:2; }
.passed .station-marker { fill:var(--yellow); stroke:var(--yellow); }
.passed .station-name { fill:#e0ddcb; }
.current .station-marker { fill:var(--green); stroke:var(--green); }
.current .station-halo { stroke:var(--green); animation:breathe 2.4s ease-in-out infinite; }
.current .station-name { fill:var(--green); }
.next .station-marker { stroke:var(--red); }
.next .station-halo { stroke:var(--red); animation:breathe 2.4s ease-in-out infinite; }
.next .station-name { fill:var(--red); }
.interchange-branch path { fill:none; stroke:var(--connection); stroke-width:6; stroke-linejoin:round; stroke-linecap:round; }
.interchange-branch text { fill:var(--connection); font:600 17px 'Space Grotesk',Arial,sans-serif; }
.interchange-disc { display:none; transform-box:fill-box; transform-origin:center; }
.yellow-half { fill:var(--yellow); }
.connection-half { fill:var(--connection); }
.interchange.reached .station-marker { fill:#080a0a; stroke:#dce3dc; stroke-width:3; }
.interchange.reached .interchange-disc { display:block; animation:interchange-turn 3s ease-in-out 1; }
@keyframes breathe { 0%,100% { opacity:.25; } 50% { opacity:.85; } }
@keyframes interchange-turn { from { transform:rotate(0deg); } to { transform:rotate(360deg); } }
.display-legend { border-top:1px solid #29302e; padding-top:17px; color:#9da79f; font:12px 'DM Mono',monospace; display:flex; gap:28px; flex-wrap:wrap; }
.legend-dot { display:inline-block; height:8px; width:8px; border-radius:50%; margin-right:6px; }
.legend-dot.green { background:var(--green); }.legend-dot.red { background:var(--red); }
.controls-panel { background:#171b1a; border:1px solid #29302e; border-radius:14px; padding:20px 22px; margin-top:18px; }
.controls-row { display:flex; gap:10px; flex-wrap:wrap; }
button { background:#242b28; color:var(--ink); border:1px solid #414b46; border-radius:8px; padding:12px 17px; font:500 16px 'Space Grotesk',Arial,sans-serif; cursor:pointer; }
button:hover:not(:disabled) { border-color:var(--yellow); }
button.primary { background:var(--yellow); border-color:var(--yellow); color:#181a15; }
button:disabled { opacity:.65; cursor:default; }
:focus-visible { outline:2px solid var(--yellow); outline-offset:4px; }
.speed-control { display:block; color:#a5afa8; font-size:12px; margin-top:20px; max-width:360px; }
.speed-control output { float:right; color:var(--yellow); }
input { width:100%; accent-color:var(--yellow); margin-top:11px; }
.hint { color:#929e95; font-size:12px; letter-spacing:.03em; text-transform:none; margin:15px 0 0; line-height:1.5; }
footer { display:flex; justify-content:space-between; gap:20px; color:#89958c; font-size:10px; margin-top:23px; }
@media(max-width:900px) {
  .app-shell { padding:30px 16px; }.hero { display:block; }.live-pill { display:inline-block; margin-top:24px; }
  .display-card { padding:22px 16px; }.display-legend { gap:16px; } footer { display:block; line-height:2; }
}
@media(prefers-reduced-motion:reduce) { .station-halo,.interchange.reached .interchange-disc { animation:none; } .current .station-halo,.next .station-halo { opacity:.65; } }
