/* Shared mobile-web visual language. Line colours identify services; status colours describe delays. */
:root { --secondary:#aeb8c3; --panel:#242d38; }
body { color:#f5f7fa; }
button,input,a { touch-action:manipulation; }
button,input { font:inherit; }
input[type=search] { font-size:16px; }
a { color:inherit; }
.service-nav { position:absolute; top:12px; left:16px; right:16px; height:44px; display:flex; align-items:center; justify-content:space-between; z-index:25; }
.service-nav>a { display:flex; align-items:center; gap:6px; min-height:44px; text-decoration:none; font-size:14px; font-weight:600; }
.service-nav>span { font-size:10px; letter-spacing:2px; color:#9ba9b8; }
.service-nav .demo-tag { letter-spacing:.4px; border:1px solid #526070; border-radius:6px; padding:4px 7px; font-size:10px; }
.demo-commute .footer .u{visibility:hidden}
.notice-dot{width:9px;height:9px;border-radius:50%;background:var(--minor);box-shadow:0 0 12px #ffa12b88}
html.mode-phone .service-nav { top:calc(6px + env(safe-area-inset-top,0px)/var(--s,1)); }
.statusbar { display:none; }
.safari { background:none; backdrop-filter:none; -webkit-backdrop-filter:none; pointer-events:none; }
.safari .addr,.safari .more,.safari .home { display:none; }
.safari .back { pointer-events:auto; }
html.mode-frame .safari { top:8px; z-index:60; }
html.mode-frame .safari .back { position:absolute; top:0; left:12px; }

.demo-label { margin-top:12px; font-size:11px; color:#aab5c1; letter-spacing:.4px; }
.data-note { color:var(--secondary); font-size:12px; line-height:1.6; text-align:center; }
.data-note a { text-decoration:underline; text-underline-offset:3px; }
/* One marker construction, reused at every scale. Prediction never uses a filled centre. */
.delay-dot { position:relative; display:inline-block; width:16px; height:16px; flex:0 0 16px; border-radius:50%; --status:var(--minor); box-sizing:border-box; }
.delay-dot.severe { --status:var(--severe); }
.delay-dot.good { --status:var(--good); }
.delay-dot.now { background:var(--status); border:3px solid #1a2029; box-shadow:0 0 0 1px var(--status); }
.delay-dot.next { background:#1a2029; border:2px dashed var(--status); }
.delay-dot.next:after { content:''; position:absolute; inset:-5px; border:1px solid var(--status); border-radius:50%; animation:forecast-pulse 2.8s ease-out infinite; pointer-events:none; }
@keyframes forecast-pulse { 0%,100%{opacity:0;transform:scale(.8)} 25%{opacity:.35} 80%{opacity:0;transform:scale(1.35)} }
.map-dot { position:absolute; transform:translate(-50%,-50%); }
.status-key { display:flex; flex-wrap:wrap; gap:10px 18px; padding:12px 0; color:#dce3ea; font-size:12px; }
.status-key>span { display:flex; align-items:center; gap:8px; }
.status-key small { width:100%; color:var(--secondary); font-size:11px; }
/* Map chrome: search, line summary, then compact time/state key. */
.map-phone .safari { display:none; }
.map-phone .ui.sbox { top:calc(var(--map-top,62px)); }
.map-phone #sp { top:calc(var(--map-top,62px) + 48px); }
.map-phone .chip { top:calc(var(--map-top,62px) + 52px); font-size:13px; height:32px; }
.map-phone .map-key { position:absolute;z-index:20;left:16px;top:calc(var(--map-top,62px) + 92px);width:358px;display:flex;align-items:center;justify-content:space-between;gap:6px; }
.map-filters { display:flex;gap:2px;padding:3px;background:#202832;border:1px solid #3a4653;border-radius:12px; }
.map-filters button { display:flex;align-items:center;gap:6px;border:0;background:none;border-radius:8px;color:#aebac7;min-height:34px;padding:0 10px;font-size:11px;cursor:pointer; }
.map-filters button[aria-pressed=true] { color:#fff;background:#394552; }
.map-filters .delay-dot { width:11px;height:11px;flex-basis:11px; }
.map-filters .delay-dot:after { display:none; }
.map-key details { position:relative; }
.map-key summary { list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:center;width:38px;height:40px;border-radius:12px;background:#202832;color:#b9c4cf;font-size:13px;border:1px solid #3a4653; }
.map-key details>div { position:absolute;right:0;top:47px;width:264px;background:#25303b;padding:16px;border:1px solid #455363;border-radius:16px;box-shadow:0 12px 28px #0006; }
.map-key details p { font-size:12px;line-height:19px;color:#c4cfda;margin-bottom:6px; }
.map-key details b { color:white; }
.map-phone .stackbtn { left:auto;right:16px;top:auto;bottom:24px;width:52px;height:52px;border:1px solid #52616f;border-radius:17px; }
.map-phone .stackbtn i { transform:translate(4px,4px); }
.map-phone .routebtn { left:16px;right:auto;top:auto;bottom:24px;width:auto;min-width:144px;height:52px;gap:10px;padding:0 16px;border-radius:17px;text-decoration:none;font-size:14px;font-weight:600; }
.map-phone .routebtn svg { width:24px;height:24px; }
.map-phone .zoomctl { left:auto;right:20px;top:min(calc(var(--H,844px) - 184px),var(--zt,9999px)); }
html.mode-phone .map-phone { --map-top:calc(58px + env(safe-area-inset-top,0px)/var(--s,1)); }
html.mode-phone .map-phone .stackbtn,html.mode-phone .map-phone .routebtn { bottom:calc(16px + env(safe-area-inset-bottom,0px)/var(--s,1)); }
#world svg .base { transition:opacity .24s ease; }
#world svg.focus .base { filter:none;opacity:.24; }
#world svg.route .base { filter:none;opacity:.12; }
#world svg.route .hl { opacity:0; }
#world.route-focus .station-marker { opacity:.13;pointer-events:none; }
.map-label-layer.route-focus .lbl { opacity:0;visibility:hidden!important;pointer-events:none; }
.map-label-layer.route-focus .lbl.route-label { opacity:1;visibility:visible!important;color:#fff; }
.map-label-layer.route-focus .lbl.endpoint-label{opacity:0;visibility:hidden!important}
.map-label-layer .lbl { font-family:var(--sf);font-size:11px;font-weight:600;text-shadow:0 0 3px #1a2029,0 0 6px #1a2029,0 1px 1px #1a2029; }
.map-label-layer.zoom-wide .lbl { visibility:hidden; }
.map-label-layer.zoom-wide .lbl.route-label { visibility:visible; }
.map-label-layer.zoom-wide .lbl.route-label:not(.endpoint-label) { visibility:hidden; }
.station-marker { position:absolute;width:44px;height:44px;margin:-22px 0 0 -22px;display:flex;align-items:center;justify-content:center;background:none;border:0;cursor:pointer;transform:scale(var(--mk,var(--ls)));z-index:4; }
.station-marker .delay-dot { width:18px;height:18px;flex-basis:18px;pointer-events:none; }
#world[data-filter=now] [data-kind=next],#world[data-filter=next] [data-kind=now] { display:none; }
#world[data-filter=now] .dz-forecast { display:none; }

.dz-current { stroke:var(--minor);stroke-width:3;opacity:0; }
.sev-severe .dz-current { stroke:var(--severe); }
.dz-forecast { stroke-width:2;stroke-dasharray:5 6;opacity:.7; }
#world svg.route .dz-i { opacity:.12; }
.fsel b { top:-44px; }
.fend b { top:-38px;font-size:12px; }
.rt-case { opacity:.75;stroke-width:calc(var(--rw,6) + 3px); }
/* Sheet hierarchy: station now / station forecast / line-level context. */
.fs-scroll { background:#202934;backdrop-filter:none;-webkit-backdrop-filter:none;padding:26px 18px calc(20px + env(safe-area-inset-bottom,0px)/var(--s,1)); }
.fs-t h2 { font-size:20px;line-height:25px;letter-spacing:-.4px; }
.fs-t p { font-size:12px;line-height:17px;color:#aebcc9; }
.fs-x,.fs-back { width:40px;height:40px; }
.station-status { border:1px solid #3b4654;border-radius:16px;overflow:hidden;margin:12px 0; }
.station-status-row { display:flex;gap:12px;align-items:center;width:100%;border:0;background:#29333f;color:#fff;text-align:left;padding:13px 14px; }
.station-status-row+ .station-status-row { border-top:1px solid #3b4654; }
.station-status-row>div { flex:1; }
.station-status-row small { display:block;color:#b6c2cf;font-size:11px;line-height:17px; }
.station-status-row b { display:block;font-size:14px;line-height:20px;font-weight:600; }
.line-alerts { margin:14px 0; }
.line-alerts>small { font-size:10px;color:#92a3b4;letter-spacing:.7px; }
.line-alerts button { display:flex;align-items:center;gap:8px;width:100%;min-height:38px;border:0;background:none;color:#e1e7ed;font-size:12px;text-align:left; }
.line-alerts button i { height:14px;width:3px;border-radius:2px; }
.line-alerts button span { margin-left:auto;font-size:11px;color:#b8c3ce; }
.dz-direction { color:#bac7d4;font-size:12px;margin:14px 0; }
.route-mode .fs-pane { display:flex;flex-direction:column;height:100%;min-height:0; }
.route-mode .fs-head,.route-mode .fs-actions { flex:none; }
.route-mode .ro-list { flex:1;overflow-y:auto;min-height:0;overscroll-behavior:contain;padding:2px 1px; }
.route-mode .fs-actions { border-top:1px solid #3b4654;padding-top:12px;margin-top:10px;background:#202934; }
.route-mode .ro { border:1px solid #3b4755;border-radius:16px;padding:12px;margin-bottom:9px;background:#2a3440; }
.route-mode .ro.on { border:2px solid #70cbc5;background:#283f46;padding:11px; }
.route-mode .ro-top>b { font-size:29px; }
.route-mode .ro-top .tag { font-size:10px;color:#78d2cb; }
.route-mode .ro-meta { font-size:11px; }
.ro-legs { flex-wrap:wrap; }
.lp { font-size:12px;padding:0 9px;height:26px; }
.fs-actions .btn-p,.fs-actions .btn-s { min-height:46px;font-size:14px; }
.journey-confirm { display:flex;gap:10px;align-items:center;border:1px solid #468e89;border-radius:14px;padding:12px;margin:0 0 14px;background:#25423f; }
.journey-confirm>span { font-size:22px;color:#8fe2c7; }
.journey-confirm b { display:block;font-size:14px; }
.journey-confirm small { display:block;font-size:11px;color:#b5d5d0;margin-top:3px; }
.journey-steps { flex:1;min-height:0;overflow:auto;list-style:none;margin:0;padding:0 4px; }
.journey-steps li { display:flex;flex-direction:column;gap:4px;border-left:3px solid var(--line-color);padding:0 0 16px 12px;margin-left:4px; }
.journey-steps small { font-size:11px;color:#a9bac9; }
.journey-steps b { font-size:15px; }
.journey-steps span { font-size:12px;color:#d0dbe4; }
.page-hidden * { animation-play-state:paused !important; }
@media (prefers-reduced-motion:reduce) { .delay-dot:after { animation:none;display:none; } .station-marker,.line-card,.fs-pane { transition:none; } }
@media (prefers-contrast:more) { .line-card,.fs-scroll,.station-status { border-color:#aebbc9; } .data-note,.line-card p { color:#e1e7ed; } }
@media (max-width:340px) { .map-filters button { min-height:42px; } .fs-actions .btn-p,.fs-actions .btn-s { min-height:54px; } }
.station-mode .fs-pane { display:flex;flex-direction:column;height:100%;min-height:0; }
.station-mode .fs-head,.station-mode .fs-actions { flex:none; }
.station-body { flex:1;overflow-y:auto;min-height:0;overscroll-behavior:contain; }
.station-mode .fs-actions { margin-top:10px;padding-top:10px;border-top:1px solid #3b4654; }
.map-phone.routing #chip,.map-phone.routing .map-key,.map-phone.routing .ui.sbox,.map-phone.routing #sp { display:none!important; }
.map-label-layer .lbl { transition:none; }
.map-label-layer.route-focus .lbl.endpoint-label { visibility:hidden; }
/* Stable, legible end labels at any map zoom. */
.fend b,.fsel b { transform:translateX(-50%) scale(var(--ms,1));transform-origin:50% 100%; }
.fend i { transform:scale(var(--ms,1)); }
.fend b { top:-18px; }
.ro-list,.journey-steps,.station-body { scrollbar-width:none; }
.ro-list::-webkit-scrollbar,.journey-steps::-webkit-scrollbar,.station-body::-webkit-scrollbar { display:none; }
.enter { animation-duration:240ms;animation-delay:0ms; }
.fs-head { touch-action:none; }
.fs-scroll,.station-body,.ro-list,.journey-steps { touch-action:pan-y; }


html.mode-phone input { font-size:max(16px,calc(16px / var(--s,1))); }
.route-edit { flex:none;align-self:flex-start;padding:0 0 8px;border:0;background:none;color:#92cfcf;font-size:11px;cursor:pointer;min-height:28px; }
.route-mode .fs-head { margin-bottom:4px; }
/* Preserve the supplied main diagram, rings and directional glow. Only directory density changes. */
.lines .scroll { top:58px; }
.lines .lcontent,html.mode-phone .lines .lcontent { padding:10px 16px 28px;gap:8px; }
html.mode-phone .lines .title { padding:0; }
.lines .lcontent h1 { font-size:28px;line-height:34px; }
.lines .sbox { height:38px;min-height:38px; }
.lines .sbox input { background:none;border:0;color:#fff;width:100%;outline:none;padding:0 10px; }
.lines .status-key { padding:2px 0 4px;gap:18px;font-size:11px; }
.lines .status-key .delay-dot { width:12px;height:12px;flex-basis:12px; }
.lines #sp { top:95px;z-index:35; }
#line-directory { display:flex;flex-direction:column;gap:7px; }
.line-stack .lrow { padding:9px 16px 7px;gap:3px;text-decoration:none; }
.line-stack .lrow .hdr { height:28px; }
.line-stack .lrow .nm { font-size:15px;line-height:19px; }
.line-stack .lrow .sm { font-size:11px; }
.line-stack .lrow .big { font-size:25px;line-height:28px; }
.line-stack .track { height:49px; }
.line-stack .track .st { top:0!important;transform:translateX(-50%);font-size:10px;line-height:12px; }
.line-stack .track .lc { top:22px; }
.line-stack .track .glow { top:17.5px; }
/* Identical size, halo and pulse construction to the line forecast card. */
.line-stack .station-symbol { position:absolute;top:9.5px;width:28px;height:28px;pointer-events:none; }
.line-stack .station-symbol .nowglow { left:0;top:0;width:28px;height:28px; }
.line-stack .station-symbol .nowdot { left:8px;top:8px;width:12px;height:12px;box-shadow:none; }
.line-stack .station-symbol .pred { left:-13.43px;top:-13.43px; }
.line-stack .track .glow i { opacity:.6; }
.line-stack .track .dir { top:36px;font-size:10px;line-height:12px; }
.line-stack .track+.track { margin-top:2px; }
.line-stack .nrow { height:46px;padding:0 14px;text-decoration:none;gap:7px; }
.line-stack .nrow .nm { font-size:14px; }
.line-stack .nrow .sm { font-size:11px; }
.line-stack .nrow .off-mark { color:var(--sec); }
.line-stack .offscreen * { animation-play-state:paused!important; }
.station-marker>.nowglow { position:absolute;left:2px;top:2px;width:40px;height:40px; }
.station-marker>.nowglow.severe { background:radial-gradient(circle closest-side,rgba(220,36,31,.55),transparent); }
.station-marker>.nowdot { position:absolute;left:15px;top:15px;width:14px;height:14px;border:2px solid #12161c; }
.station-marker>.pred { left:50%;top:50%;transform:translate(-50%,-50%); }
.demo-forecast{animation:forecastEnter .6s var(--ease) var(--forecast-delay,0s) both}
@keyframes forecastEnter{from{opacity:0;filter:blur(3px)}to{opacity:1;filter:blur(0)}}
.dz-forecast.dz-dash { stroke-dasharray:7 9;animation:dzFlow 1.8s linear infinite;opacity:.75; }
.dz-i .dz-glow { stroke-width:10;opacity:.28;filter:blur(3px);animation:dzPulse 2.2s ease-in-out infinite; }
@media (prefers-reduced-motion:reduce) { .dz-forecast.dz-dash,.dz-i .dz-glow { animation:none; } }

/* The overview and directory share compact cards; the radial diagram stays untouched. */
.watch.line-stack { gap:7px; }
.watch.line-stack .nrow { display:flex;align-items:center;flex:none; }
.watch.line-stack .nrow .bar { width:4px;height:18px;border-radius:2px;flex:none; }
.watch.line-stack .nrow .nm { font-weight:600;white-space:nowrap; }
.watch.line-stack .nrow .sm { flex:1;color:var(--sec); }
.watch.line-stack a:focus-visible { outline:2px solid var(--navy-light);outline-offset:2px; }

/* Compact weather-style pager, just above the browser's visible bottom edge. */
.pg .bottomctl { left:23px;right:23px;width:auto;top:auto;bottom:14px; }
.pg .bottomctl .btn.list { left:auto;right:0; }
.pg .pagepos { left:50%;transform:translateX(-50%);width:168px;height:40px;top:2px;padding:0 8px; }
.pg .pagepos .pd { height:38px;flex:0 0 20px; }
.pg .pagepos .pd[hidden] { display:none; }
.pg .pagepos .pd.edge i { transform:scale(.7);opacity:.6; }
html.mode-phone .pg .bottomctl { top:auto;bottom:calc(6px + max(0px,env(safe-area-inset-bottom,0px) - var(--browser-inset,0px))/var(--s,1)); }
@media (display-mode:standalone) { html.mode-phone .pg .bottomctl { bottom:calc(6px + env(safe-area-inset-bottom,0px)/var(--s,1)); } }
.pg .pager.is-moving * { animation-play-state:paused!important; }
.pg .pager-page .enter { animation:none; }
.pg .pager-page { contain:layout paint; }
.mapview { contain:layout paint; }
/* Keep static network artwork in its own cached image, above dynamic delay layers. */
.mapview .glw:not(.on) { display:none; }

/* Unified directory and always-visible delay scale. */
.map-phone .map-key { flex-wrap:wrap;justify-content:flex-start;gap:7px;width:auto;right:16px; }
.severity-key { display:flex;align-items:center;gap:8px;font-size:10px;color:#c0c9d3; }
.severity-key i { width:70px;height:5px;border-radius:9px;background:linear-gradient(90deg,var(--minor),var(--severe)); }
.map-key .severity-key { flex-basis:100%;padding:3px 8px;background:#1a2029e8;width:max-content;border-radius:12px; }
.overview-search { position:relative; }
.overview-search input { width:100%;height:42px;border:1px solid #ffffff18;border-radius:18px;background:#303740;color:white;padding:0 14px; }
.overview-search .sp { position:absolute;top:46px;left:0;width:100%;max-height:280px; }
.watch .status-key { padding:5px 4px; }
.watch .severity-key { padding:0 4px 8px; }
.all-line-cards { display:flex;flex-direction:column;gap:7px; }
.pg .pagepos { touch-action:none;user-select:none;overscroll-behavior-x:contain; }
.pg .pagepos.scrubbing { background:#37414d;box-shadow:0 0 0 1px #ffffff40; }
/* One station centre at every interchange; status overlays share that centre. */
.station-base { position:absolute;width:0;height:0;pointer-events:none;z-index:3;transform:scale(var(--ds,var(--ls))); }
#world.zoom-far .station-base { display:none; }
.station-base>i { position:absolute;width:12px;height:12px;left:-6px;top:-6px;background:#f1f4f7;border:2px solid #151c24;border-radius:50%;box-sizing:border-box; }
#world.route-focus .station-base { opacity:.15; }
.map-label-layer .lbl { z-index:6; }
.dz-i .dz-glow { stroke-width:7;opacity:.22;animation:none;filter:none; }
.dz-i .dz-current { stroke-width:3;opacity:.35; }
.dz-i .dz-flow { stroke-width:3;stroke-dasharray:14 86;stroke-linecap:round;animation:directionFlow 2.4s linear infinite;filter:drop-shadow(0 0 3px currentColor);opacity:.9; }
@keyframes directionFlow { to { stroke-dashoffset:-100; } }
.fs-chips .lpa { border:1px solid transparent;padding:3px;border-radius:12px;background:none;color:white;cursor:pointer; }
.fs-chips .lpa[aria-pressed=true] { border-color:#aec7d5;background:#ffffff10; }
.pick-mode .fs-head { margin-bottom:12px; }
.pick-mode .rp-fields { margin-bottom:8px; }
.pick-mode .rp-f { min-height:54px;height:54px; }
.pick-mode .rp-search,.pick-mode .rp-quick,.pick-mode .rp-list { display:none; }
.pick-mode.pick-search .rp-search,.pick-mode.pick-search .rp-list { display:block; }
.pick-mode.pick-search .rp-fields { display:none; }
.pick-search-toggle { min-height:38px;border:0;background:none;color:#9bd4d1;font-size:12px;padding:4px 0;cursor:pointer; }
.pick-mode .fs-scroll { padding-top:25px; }
.journey-steps details { font-size:12px;line-height:1.6; }
.journey-steps summary { color:#b8cbd7;min-height:32px;cursor:pointer; }
.leg-stops { display:flex;flex-direction:column;gap:9px;padding:4px 0 10px; }
.leg-stops span { display:flex;align-items:center;gap:8px; }
.leg-stops i { width:6px;height:6px;border:1px solid #dce5ed;border-radius:50%; }
.journey-note { font-size:10px;color:#aab9c7;margin:6px 0; }
@media(prefers-reduced-motion:reduce){.dz-i .dz-flow{animation:none;stroke-dasharray:none;opacity:.5}}
.map-label-layer .lbl.selected-label { visibility:hidden; }
.line-alerts>a { display:block;font-size:12px;line-height:20px;margin-top:7px; }
/* Single-height map legend and vector artwork. */
.map-phone #chip { display:none; }
.map-phone .map-key { top:calc(var(--map-top,62px) + 51px);display:flex;flex-wrap:nowrap;gap:9px;padding:4px 9px;border-radius:14px;background:#1a2029ed;border:1px solid #ffffff18; }
.map-key .map-filters { border:0;background:none;padding:0;gap:4px;flex:none; }
.map-key .map-filters button { font-size:10px;min-height:30px;padding:0 3px;gap:5px; }
.map-key .map-filters button[aria-pressed=true] { background:#ffffff15; }
.map-key .severity-key { flex-basis:auto;flex:1;gap:5px;padding:0;background:none;font-size:9px;white-space:nowrap; }
.map-key .severity-key i { flex:1;min-width:24px;width:36px;height:4px; }
.direction-light { filter:drop-shadow(0 0 2px #ffaf4655); }
.dz-i .dz-glow { opacity:.12;stroke-width:5; }
#world .base { shape-rendering:geometricPrecision; }
.pg .page-backdrop { pointer-events:none;z-index:0;top:0; }
.pg .pager-page .scroll { z-index:1;mask-image:linear-gradient(to bottom,transparent,#000 5px);-webkit-mask-image:linear-gradient(to bottom,transparent,#000 5px); }
.pg .chdr-bg { display:none; }
.pg .chdr-in { text-shadow:0 1px 8px #101722; }
@media(prefers-reduced-motion:reduce){.direction-light{display:none}}
.pg .page-backdrop .fade { background:linear-gradient(180deg,rgba(26,33,41,.15),rgba(26,33,41,0) 32%,rgba(26,33,41,0) 72%,rgba(26,33,41,.7) 90%,#1a2129); }
/* Focus scrolling must not move the fixed header's parent. Only .scroll is scrollable. */
.pg .pager-page { overflow:clip; }
/* A consistent three-part forecast ring, rather than browser-dependent dashed borders. */
.delay-dot.next,.pred .c { --ring-color:var(--minor);border:0!important;background:conic-gradient(from -90deg,var(--ring-color) 0deg 88deg,transparent 88deg 120deg,var(--ring-color) 120deg 208deg,transparent 208deg 240deg,var(--ring-color) 240deg 328deg,transparent 328deg);mask:radial-gradient(farthest-side,transparent calc(100% - 2px),#000 calc(100% - 1.5px));-webkit-mask:radial-gradient(farthest-side,transparent calc(100% - 2px),#000 calc(100% - 1.5px)); }
.delay-dot.next.severe,.pred.severe .c { --ring-color:var(--severe); }
.delay-dot.next.good,.pred.good .c { --ring-color:var(--good); }
.delay-dot.next:after { display:none; }
.pg .card { background:rgba(42,50,61,.96);backdrop-filter:blur(18px);-webkit-backdrop-filter:blur(18px); }
.pg .card.fc { background:linear-gradient(110deg,rgba(40,52,65,.97),rgba(55,47,61,.97)); }
.directory-key { display:flex;align-items:center;gap:12px;padding:8px 7px;background:#202832e8;border-radius:13px; }
.directory-key .status-key { padding:0;flex-wrap:nowrap;gap:10px;font-size:10px;white-space:nowrap; }
.directory-key .status-key>span { gap:5px; }
.directory-key .delay-dot { width:11px;height:11px;flex-basis:11px; }
.directory-key .severity-key { flex:1;white-space:nowrap;gap:5px;padding:0;font-size:9px; }
.directory-key .severity-key i { width:auto;flex:1;min-width:24px;height:4px; }
.fit-network { display:block;width:44px;min-height:36px;background:#1a2029;color:#dbe7ee;border:0;border-top:1px solid #ffffff20;font-size:11px;border-radius:0 0 18px 18px;cursor:pointer; }
.map-phone .zoomctl { height:auto;overflow:visible; }
.map-label-layer.zoom-wide .lbl { visibility:hidden; }
.find-journey { width:100%;min-height:48px;border-radius:14px;margin-top:8px;flex:none; }
.find-journey:disabled { opacity:.4; }
.pick-mode .rp-fields { margin-bottom:0; }
.pick-mode .pick-search-toggle { min-height:32px; }
.pick-mode:not(.pick-search) .fs-pane { display:flex;flex-direction:column;height:100%;min-height:0; }
.pick-ready .fs-head { margin-bottom:5px; }
.pick-ready .rp-fields { padding-top:2px;padding-bottom:5px; }
.route-ready { display:flex;align-items:center;gap:10px;margin-top:2px;padding:9px 11px;border:1px solid #ffffff18;border-radius:13px;background:#28333f; }
.route-ready>i { width:10px;height:10px;flex:none;border-radius:50%;background:var(--good);box-shadow:0 0 12px #1fa6a688; }
.route-ready.delay { border-color:#ffa12b55;background:#3a3025; }
.route-ready.delay>i { background:var(--minor);box-shadow:0 0 12px #ffa12baa; }
.route-ready b,.route-ready span { display:block; }
.route-ready b { font-size:12px;line-height:16px; }
.route-ready span { color:#b5c0cb;font-size:10px;line-height:14px; }
.pick-ready .pick-search-toggle { margin-top:5px;color:#9fcece; }
#world.route-preview svg .base { opacity:.055;filter:saturate(.08) brightness(.4); }
#world.route-preview .station-base { opacity:.08; }
#world.route-preview .station-marker { opacity:.08; }
#world.route-preview .station-marker[data-line=central] { opacity:1; }
.map-label-layer.route-preview .lbl { opacity:0;visibility:hidden!important; }
.map-label-layer.route-preview .lbl.route-label:not(.endpoint-label) { opacity:1;visibility:visible!important;color:#fff; }
#world.route-preview .rt-preview { opacity:1; }
#world.route-preview .fxfer.preview:after { animation:transferPulse 1.8s ease-out infinite; }
.pick-mode.pick-search .rp-search { margin:0 0 8px; }
.pick-mode.pick-search .fs-pane { display:flex;flex-direction:column;height:100%; }
.pick-mode.pick-search .rp-list { flex:1;min-height:0;overflow:auto; }
.pick-mode.pick-search .fs-head,.pick-mode.pick-search .rp-search,.pick-mode.pick-search .pick-search-toggle { flex:none; }
.pick-mode.pick-search .fs-scroll { background:#202934; }
.pick-mode.pick-search .rp-list-label { padding:8px 0 5px;color:#8f9eac;font-size:10px;line-height:14px;letter-spacing:.5px;text-transform:uppercase; }
.pick-mode.pick-search .rp-r { min-height:48px; }
html.keyboard-open .pick-mode.pick-search .fs-scroll { border-radius:18px 18px 0 0;padding-top:12px;padding-bottom:10px;background:#202934;box-shadow:0 -8px 28px #0008; }
html.keyboard-open .pick-mode.pick-search { transform:translate3d(0,0,0)!important;height:var(--H,844px); }
html.keyboard-open .pick-mode.pick-search .fs-scroll { top:0;bottom:0!important; }
html.keyboard-open .pick-mode.pick-search .fs-head { min-height:40px;margin-bottom:6px; }
html.keyboard-open .pick-mode.pick-search .fs-t h2 { font-size:18px;line-height:22px; }
html.keyboard-open .pick-mode.pick-search .fs-t p { font-size:11px;line-height:15px; }
html.keyboard-open .pick-mode.pick-search .fs-back,html.keyboard-open .pick-mode.pick-search .fs-x { width:36px;height:36px; }
html.keyboard-open .pick-mode.pick-search .rp-search input { height:46px;border:1px solid #ffffff18;background:#151c24; }

/* The visual viewport is the usable screen while iPhone Safari's keyboard is
   open. Keep global station search and its results inside that viewport. */
html.mode-phone.keyboard-open.station-search-open .overview-search.on {
  position:sticky;top:calc(8px + env(safe-area-inset-top,0px)/var(--s,1));z-index:70;
}
html.mode-phone.keyboard-open.station-search-open .overview-search.on .sp {
  max-height:calc(var(--H,844px) - 68px - env(safe-area-inset-top,0px)/var(--s,1));
  overscroll-behavior:contain;
}
html.mode-phone.keyboard-open.station-search-open .pg .bottomctl {
  opacity:0;pointer-events:none;
}
html.mode-phone.keyboard-open.station-search-open .map-phone #sp {
  max-height:calc(var(--H,844px) - var(--map-top,58px) - 56px);
  overscroll-behavior:contain;
}
html.mode-phone.keyboard-open.station-search-open .map-phone .map-key,
html.mode-phone.keyboard-open.station-search-open .map-phone .routebtn,
html.mode-phone.keyboard-open.station-search-open .map-phone .stackbtn,
html.mode-phone.keyboard-open.station-search-open .map-phone .zoomctl {
  opacity:0;pointer-events:none;
}
.route-loading{font-size:0;display:grid;gap:10px;padding:10px 0}
.route-loading:before,.route-loading:after{content:'';display:block;height:112px;border:1px solid #3b4755;border-radius:16px;background:linear-gradient(100deg,#2a3440 20%,#36424f 38%,#2a3440 56%);background-size:240% 100%;animation:routeSkeleton 1.05s linear infinite}
.route-loading:after{height:92px;opacity:.7}
@keyframes routeSkeleton{to{background-position:-140% 0}}
.route-compare{display:flex;flex-direction:column;gap:2px;margin:0 0 9px;padding:9px 11px;border-radius:12px;background:#1f3c3d;border:1px solid #397370}
.route-compare b{font-size:11px;color:#86ddd4}.route-compare span{font-size:12px;line-height:16px;color:#e0eeec}
.ro-times { color:#c9d9e4;font-size:12px;margin-top:8px; }
.provider-notice { font-size:11px;color:#f4c68f;line-height:1.4;margin:8px 0 0; }
.rt-walk { stroke-dasharray:3 5;stroke:#d9e2ea; }
.direction-light { filter:none; }
.service-nav .demo-tag { font-size:8px;letter-spacing:0; }
@media(prefers-reduced-motion:reduce){.direction-light{display:none}}

/* Keep the camera input path light. Direction lights resume on release; station
   status remains visible throughout the gesture. */
.mapview.camera-moving .direction-light{visibility:hidden}

/* Extended schematic labels keep a readable size; collision selection is camera-driven. */
.map-phone .map-label-layer .lbl { font-size:11px; }

/* Line width on screen = max(4.5px*k, 1.3px); station dots follow it (see --ds in map-page.js). */
#world .network-lines path { stroke-width:max(2.05px, calc(.6px * var(--ms))); }

/* Clear arrival hierarchy: direction, next train, then following services. */
.fs-dirs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.arrival-card{min-width:0;margin:0;padding:12px;background:#2a3440;border:1px solid #3b4654;border-radius:14px}
.arrival-card h3{margin:0 0 8px;font:500 12px/16px var(--sf,system-ui);color:#c4cdd7}
.arrival-next{display:flex;align-items:baseline;gap:5px;flex-wrap:wrap;font-variant-numeric:tabular-nums}
.arrival-next b{font:650 30px/34px var(--sf,system-ui);letter-spacing:-1px;color:#fff}
.arrival-next>span{font-size:12px;color:#c4cdd7}
.arrival-next small{flex-basis:100%;font-size:10px;line-height:14px;color:#9eacba;margin-top:-3px}
.arrival-later{display:flex;align-items:baseline;gap:7px;margin-top:10px;padding-top:8px;border-top:1px solid #ffffff12;font-size:11px;color:#9eacba;white-space:nowrap;font-variant-numeric:tabular-nums}
.arrival-later b{font-size:14px;font-weight:550;color:#dbe3eb}.arrival-later i{font-style:normal;color:#788795}
#world .fend,#world .fsel{z-index:9}
#world .fend b{top:-36px}

/* Anchored interchange connector, perpendicular to the shared corridor. */
.station-base.interchange{transform:rotate(var(--station-angle,0deg)) scale(var(--ds,1))}
.station-base.interchange>i{width:10px;height:18px;left:-5px;top:-9px;border-radius:999px;background:#eaf0f5;border:2px solid #151c24}
.route-expand{display:none}
.route-mode.peek .fs-pane>*{display:none}
.route-mode.peek .fs-pane>.fs-head,.route-mode.peek .fs-pane>.route-expand{display:flex;flex:none}
.route-mode.peek .fs-head{margin-bottom:6px}
.route-mode.peek .fs-head h2{font-size:17px;line-height:21px;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.route-mode.peek .fs-head p{font-size:11px;line-height:15px}
.route-expand{align-items:center;justify-content:center;min-height:40px;width:100%;border:1px solid #ffffff20;border-radius:12px;color:#a3e2db;background:#293c44;font:600 13px system-ui}
#world .fend b,#world .fsel b{top:0;transform:translate(-50%,calc(-100% - 18px)) scale(var(--ms));transform-origin:50% 100%}

#world .fend,#world .fsel{transform:scale(var(--ms));transform-origin:0 0}
#world .fend b,#world .fsel b{top:-18px;transform:translate(-50%,-100%);transform-origin:50% 100%}
#world .fend i{transform:none}
#world .fsel i{animation:anchorPulse 1.8s ease-out infinite}
#world .fsel i+i{animation-delay:.9s}
@keyframes anchorPulse{from{opacity:.8;transform:scale(.65)}to{opacity:0;transform:scale(1.4)}}
@media(prefers-reduced-motion:reduce){#world .fsel i{animation:none;transform:none}}

/* One-tap handoff after Tubecast has explained the delay and route options. */
.google-route{display:grid;grid-template-columns:34px 1fr;grid-template-rows:auto auto;column-gap:10px;align-items:center;min-height:50px;margin:10px 0 0;padding:9px 12px;border:1px solid #ffffff20;border-radius:14px;background:#2a3440;color:#fff;text-decoration:none}
.google-route>span{grid-row:1/3;display:grid;place-items:center;width:30px;height:30px;border-radius:50%;background:#fff;color:#4285f4;font:700 16px/1 var(--sf,system-ui)}
.google-route>b{font-size:12px;line-height:16px}.google-route>small{font-size:9px;line-height:12px;color:#aebcc9}
.google-route:active{transform:scale(.985)}
.route-mode.peek .google-route{display:none}
.google-legs{margin:10px 0 0;padding:10px;border:1px solid #ffffff20;border-radius:14px;background:#2a3440}
.google-legs-head{display:flex;align-items:center;gap:10px;margin-bottom:8px}.google-legs-head>span{display:grid;place-items:center;flex:0 0 30px;width:30px;height:30px;border-radius:50%;background:#fff;color:#4285f4;font:700 16px/1 var(--sf,system-ui)}
.google-legs-head div{display:flex;min-width:0;flex-direction:column}.google-legs-head b{font-size:12px;line-height:16px}.google-legs-head small{font-size:9px;line-height:12px;color:#aebcc9}
.google-leg{display:grid;grid-template-columns:24px 1fr auto;gap:8px;align-items:center;min-height:42px;padding:6px 8px;border-top:1px solid #ffffff12;color:#fff;text-decoration:none}.google-leg>i{display:grid;place-items:center;width:22px;height:22px;border-radius:50%;background:#ffffff12;color:#dce7ef;font:700 10px/1 var(--sf,system-ui);font-style:normal}.google-leg>span{display:flex;min-width:0;flex-direction:column}.google-leg b{font-size:11px;line-height:15px}.google-leg small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:9px;line-height:12px;color:#aebcc9}.google-leg strong{font-size:10px;color:#70ddd4}.google-leg:active{background:#ffffff0a}
.route-mode.peek .google-legs{display:none}
@media(prefers-reduced-motion:reduce){.rt-draw{animation:none;stroke-dashoffset:0}.rt-traveler,.fxfer:after,.route-loading:before,.route-loading:after{animation:none}}

/* Labels fade in/out as the camera moves instead of popping. */
.map-label-layer .lbl{transition:opacity .18s ease}
.map-label-layer .lbl.lbl-off{opacity:0;pointer-events:none}
