:root{color-scheme:dark;--cab:#294b4e;--panel:#132e33;--text:#edf3ef;--muted:#a9c4c5;--yellow:#f3cf74;--sea:#62aeb9;--red:#d97c6a;font-family:'Yu Gothic','Hiragino Kaku Gothic ProN',Meiryo,sans-serif;font-weight:500;background:#19363b;color:var(--text)}
*{box-sizing:border-box}body{margin:0}button,input{font:inherit}button{cursor:pointer;border:1px solid #6a8786;background:#35575a;color:var(--text);border-radius:6px;min-height:40px;font-weight:700;transition:background .15s,transform .1s}button:hover:enabled{background:#45696b}button:active:enabled{transform:translateY(1px)}button:disabled{opacity:.42;cursor:default}button:focus-visible,input:focus-visible{outline:3px solid var(--yellow);outline-offset:4px}[hidden]{display:none!important}kbd{font:12px Consolas,monospace;opacity:.65;margin-left:7px}.cab{max-width:1680px;margin:auto;box-shadow:0 0 80px #10282e}.topbar{height:78px;display:flex;align-items:center;justify-content:space-between;padding:0 32px;gap:20px;background:var(--cab);border-bottom:5px solid #1a353a}.brand{display:flex;align-items:center;gap:12px}.rail-mark{font-size:24px;border:2px solid #dce9e1;border-radius:50% 50% 10% 10%;width:40px;height:40px;text-align:center;line-height:36px}h1{font-size:20px;letter-spacing:.16em;margin:0;font-weight:800}.brand div>span{font-size:10px;color:#b9cdcb;letter-spacing:.09em}.service{display:flex;gap:16px;align-items:center}.service>span{padding:4px 13px;background:#d9e9dd;color:#2d4c46;font-size:13px;font-weight:800}.service b{font-size:16px;letter-spacing:.12em}.service small{font-size:11px;color:var(--muted)}.utilities{display:flex;gap:8px}.utilities button{font-size:12px;padding:0 12px;min-height:34px}.utilities #help{font:700 17px Georgia,serif;min-width:34px;padding:0}.window{position:relative;height:clamp(340px,49vh,620px);overflow:hidden;border:solid #19363b;border-width:0 12px;background:#9ecbd5}.window:after{content:'';position:absolute;inset:0;box-shadow:inset 0 14px 25px #18373b26,inset 0 -12px 22px #142e3226;pointer-events:none}#scenery{width:100%;height:100%;display:block}.window-top{position:absolute;top:20px;left:24px;right:24px;display:flex;justify-content:space-between;color:#1c454c;font-size:12px;font-weight:700}.weather{background:#f0f7f0ba;padding:8px 13px;border-radius:3px}.weather i{display:inline-block;width:7px;height:7px;background:#e2b94a;border-radius:50%;margin:0 7px 1px 15px}.clock{font:17px Consolas,monospace;background:#24474acb;color:#e6f3ec;padding:8px 13px;border-radius:3px}.window-status{position:absolute;bottom:17px;left:24px;right:24px;display:flex;justify-content:space-between;align-items:center;gap:10px;font-size:12px;text-shadow:0 1px 6px #102f3a}.window-status>span{background:#17383cda;color:#ecf5ec;padding:7px 12px;border-radius:3px}.signal{color:#b6e6bf!important}.signal.red{color:#f8b7a3!important}.wiper{position:absolute;width:27%;height:5px;bottom:1px;right:16%;background:#20373bd9;transform-origin:right;transform:rotate(-14deg);box-shadow:0 -2px 0 #c1cfca55}.welcome{position:absolute;top:50%;left:7%;transform:translateY(-50%);width:330px;background:#eff4edee;color:#24484b;padding:26px 28px 22px;border-radius:3px 3px 18px 3px;box-shadow:0 12px 40px #20484920;border-top:5px solid var(--cab)}.ticket-stamp{font-size:11px;font-weight:800;letter-spacing:.12em;color:#557570}.welcome h2{font-size:31px;line-height:1.5;margin:12px 0 10px;letter-spacing:.05em}.welcome p{font-size:12px;line-height:1.9;color:#526c69}.trip-info{border-top:1px solid #c6d4cd;margin-top:16px;padding:12px 0;display:flex;justify-content:space-between;font-size:10px;font-weight:700}.primary{background:#f3cf74;color:#293e3c;border:0;min-height:46px;padding:12px 20px;font-weight:800}.primary:hover:enabled{background:#ffdb88}.welcome .primary{width:100%;display:flex;justify-content:space-between;align-items:center;font-size:14px}.welcome>small{display:block;font-size:9px;text-align:center;margin-top:11px;color:#617974}.route-strip{display:flex;align-items:center;background:#e1e9de;color:#3e5d59;padding:0 32px;height:55px;gap:44px;border-bottom:4px solid #728e83}.route-label{font-size:12px;font-weight:800;white-space:nowrap}.route-strip ol{list-style:none;display:flex;justify-content:space-between;position:relative;width:600px;padding:0;margin:0;gap:28px}.route-strip ol:before{content:'';height:3px;background:#a2b6ac;position:absolute;left:0;right:0;top:50%}.route-strip li{position:relative;background:#e1e9de;font-size:12px;font-weight:700;padding:0 10px 0 20px;white-space:nowrap}.route-strip li:before{content:'';width:10px;height:10px;background:#e1e9de;border:2px solid #93a99e;position:absolute;left:0;top:3px;border-radius:50%}.route-strip li.visited:before{background:#527b70;border-color:#527b70}.route-strip li.next{color:#173d40}.route-strip li.next:before{background:#f0c765;border-color:#5e7762;box-shadow:0 0 0 3px #f0c76555}.train-id{margin-left:auto;font:12px Consolas,monospace;color:#6b8379}.console{display:grid;grid-template-columns:minmax(200px,.86fr) minmax(300px,1.35fr) minmax(290px,1.1fr);gap:20px;background:linear-gradient(#36575a,#294b4e);padding:24px 32px 20px;border-top:2px solid #56817c}.instrument{background:var(--panel);border:1px solid #557374;box-shadow:0 2px 1px #15373a,inset 0 1px 4px #10292e;border-radius:12px;padding:16px 20px}.panel-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;color:var(--muted);font-size:11px;min-height:24px}.limit-label{border:1px solid #819588;border-radius:4px;padding:2px 7px;color:#dce6d8}.limit-label strong{font:700 18px Consolas,monospace;margin-left:7px;color:var(--yellow)}.dial{position:relative;max-width:244px;height:166px;margin:-6px auto -5px}.dial svg{width:100%;height:100%;overflow:visible}.digital-speed{position:absolute;bottom:9px;width:100%;display:flex;align-items:baseline;justify-content:center;gap:7px}.digital-speed strong{font:52px Consolas,'Courier New',monospace;letter-spacing:-3px;color:#eff6ed}.digital-speed span{font-size:10px;color:var(--muted)}.digital-speed.overspeed strong{color:#ffaf96}.lamps{display:flex;justify-content:space-between;font-size:10px;color:#accdb0;border-top:1px solid #355053;padding-top:9px}.lamps .off{color:#678486}.lamps .open{color:#f3cf74}.destination{display:flex;align-items:center;justify-content:space-between;margin:17px 0 20px;gap:10px}.destination h2{font-size:30px;letter-spacing:.14em;margin:0 0 4px}.destination div>span{font-size:10px;color:var(--muted);letter-spacing:.12em}.distance{white-space:nowrap}.distance strong{font:38px Consolas,monospace;margin:0 5px;color:#d7f1df}.distance-track{height:4px;background:#365756;position:relative;border-radius:4px}.distance-track>div{height:100%;background:#9ac9b0;border-radius:4px;width:0}.distance-track>span{position:absolute;right:0;top:-3px;width:4px;height:10px;background:var(--yellow)}.driving-advice{display:flex;gap:9px;align-items:center;min-height:43px}.advice-dot{width:6px;height:6px;background:var(--yellow);border-radius:50%;flex-shrink:0}.driving-advice p{margin:10px 0;font-size:11px;line-height:1.6;color:#d6e6dc}.station-controls{display:flex;align-items:center;justify-content:space-between;gap:8px}.station-controls button{font-size:11px;min-height:34px;padding:6px 12px}.station-controls button:enabled{background:#dbe9d9;color:#234443}.stop-target{font-size:10px;color:var(--muted)}.controller{padding:2px 3px}.controller .panel-heading{font-size:12px;margin-bottom:16px}.controller output{font:700 23px Consolas,monospace;color:var(--yellow);min-width:55px;text-align:center;background:#1b383e;padding:3px 8px;border-radius:4px;box-shadow:inset 0 1px 4px #142a2b}.handle-labels{display:grid;grid-template-columns:7fr 1fr 5fr;color:#becfca;font-size:10px;padding:0 8px}.handle-labels span:nth-child(2){text-align:center;white-space:nowrap}.handle-labels span:last-child{text-align:right}input[type=range]{appearance:none;width:100%;height:17px;background:linear-gradient(to right,#b88875 0%,#b88875 56.5%,#c3d4ba 56.5%,#c3d4ba 61%,#75a297 61%);border:5px solid #203b40;border-radius:7px;box-shadow:0 1px 0 #6d8581;margin:20px 0 8px;cursor:ew-resize;touch-action:pan-y}input[type=range]::-webkit-slider-thumb{appearance:none;width:30px;height:40px;background:linear-gradient(90deg,#a1b5af,#ecede0 35%,#c0cfc4 70%,#829d96);border:2px solid #284749;border-radius:5px;box-shadow:0 4px 4px #152d32}input[type=range]::-moz-range-thumb{width:27px;height:36px;background:#dbe2d3;border:2px solid #284749;border-radius:5px}.notch-scale{display:grid;grid-template-columns:7fr 1fr 5fr;font:10px Consolas,monospace;color:#96b0aa;padding:0 6px}.notch-scale span:nth-child(2){text-align:center}.notch-scale span:last-child{text-align:right}.drive-buttons{display:grid;grid-template-columns:1fr .85fr 1fr;gap:8px;margin-top:18px}.drive-buttons button{min-height:49px;display:flex;align-items:center;justify-content:center;gap:4px;border-bottom:4px solid #18383b;background:#4b6d6b;font-size:13px}.drive-buttons #power{background:#668e7e}.drive-buttons #brake{background:#766e60}.drive-buttons kbd{font-size:16px}.secondary-controls{display:flex;gap:9px;margin-top:11px}.secondary-controls button{flex:1;min-height:32px;font-size:10px;background:transparent}.secondary-controls #emergency{color:#f5baab;border-color:#a6796a}footer{display:flex;justify-content:space-between;padding:11px 32px 16px;background:var(--cab);font-size:10px;color:#a9c0b9;gap:15px}.notice,.pause-screen{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:min(410px,90%);background:#eff4edee;color:#284c4e;padding:28px;text-align:center;border-top:5px solid #648e7e;border-radius:5px;box-shadow:0 10px 50px #183b3d33}.notice h2{font-size:23px;margin:0 0 10px}.notice p,.pause-screen p{font-size:12px;line-height:1.8}.notice button{margin-top:8px}.pause-screen{z-index:5}.pause-screen b{font-size:28px}.pause-screen .primary{margin-top:10px}dialog{background:#eff4ed;color:#2b4a49;border:1px solid #97b2a7;border-top:7px solid #527e72;border-radius:8px;padding:32px;width:min(540px,calc(100% - 32px));max-height:90dvh;box-shadow:0 20px 100px #122e3980}dialog::backdrop{background:#102f38b3;backdrop-filter:blur(5px)}dialog h2{font-size:24px;line-height:1.5;margin:12px 0}.close-dialog{position:absolute;right:15px;top:12px;width:32px;min-height:32px;border:0;background:transparent;color:#41665f;font-size:23px}.instructions{padding-left:25px;font-size:13px;line-height:1.7}.instructions li{padding:8px 0 6px 7px}.instructions p{margin:3px 0;color:#527168;font-size:12px}.help-note{font-size:11px;line-height:1.8;color:#5f7c72;border-top:1px solid #c9d8cd;padding-top:12px}dialog>.primary{width:100%;margin-top:12px}.result-intro{font-size:12px}.total-score{display:flex;align-items:baseline;gap:10px;margin:20px 0}.total-score strong{font:62px Consolas,monospace}.total-score>span{font-size:12px}.total-score b{margin-left:auto;color:#537d6d;font-size:19px}table{border-collapse:collapse;width:100%;font-size:11px}th,td{padding:12px 5px;border-bottom:1px solid #c9d8cd;text-align:right}th:first-child,td:first-child{text-align:left}th{color:#688479;font-weight:500}#result-feedback{font-size:12px;line-height:1.9;margin:18px 0}.plain{width:100%;background:transparent;color:#527468;border:0;font-size:11px;margin-top:10px}
@media(min-width:1500px){.console{gap:28px;padding-left:48px;padding-right:48px}.dial{height:180px}.destination{margin-top:21px;margin-bottom:24px}}
@media(max-width:1000px){.topbar{padding:0 20px}.service small{display:none}.console{gap:12px;padding:18px 18px 15px;grid-template-columns:.8fr 1.2fr 1fr}.instrument{padding:12px}.destination h2{font-size:26px}.distance strong{font-size:30px}.dial{height:150px}.controller{padding:0}.drive-buttons{gap:5px}.drive-buttons button{font-size:11px}.secondary-controls kbd{display:none}.stop-target{font-size:9px}.route-strip{padding:0 20px;gap:25px}.service{gap:8px}.brand div>span{font-size:9px}}
@media(max-width:740px){.topbar{height:64px;padding:0 13px;gap:10px}.brand{gap:8px}.rail-mark{width:31px;height:33px;line-height:29px;font-size:21px}h1{font-size:16px}.brand div>span{font-size:8px}.service{display:none}.utilities{gap:5px}.utilities button{font-size:10px;padding:0 8px;min-height:31px}.utilities #help{min-width:28px}.window{height:clamp(280px,41vh,450px);border-width:0 6px}.window-top{left:12px;right:12px;top:12px;font-size:10px}.clock{font-size:13px}.weather,.clock{padding:6px 9px}.window-status{bottom:10px;left:12px;right:12px;font-size:9px}.window-status>span{padding:5px 8px}.welcome{left:5%;width:260px;padding:17px 21px 15px}.welcome h2{font-size:24px;margin:7px 0}.welcome p{font-size:10px;margin:5px 0}.ticket-stamp{font-size:9px}.trip-info{font-size:9px;padding:8px 0;margin-top:9px}.welcome .primary{min-height:39px;font-size:12px;padding:9px 13px}.welcome>small{font-size:8px;margin-top:7px}.route-strip{height:45px;padding:0 12px;gap:14px}.route-label{font-size:10px}.route-strip ol{width:100%;gap:6px}.route-strip li{font-size:10px;padding:0 5px 0 15px}.route-strip li:before{width:8px;height:8px;top:3px}.train-id{display:none}.console{grid-template-columns:125px minmax(0,1fr);gap:10px;padding:12px}.speed-instrument{padding:10px 8px}.panel-heading{font-size:9px;min-height:22px}.limit-label{font-size:9px;padding:1px 4px}.limit-label strong{font-size:14px;margin-left:3px}.dial{height:100px;margin:3px auto 0}.digital-speed{bottom:3px;gap:4px}.digital-speed strong{font-size:34px;letter-spacing:-2px}.digital-speed span{font-size:8px}.lamps{font-size:8px;flex-direction:column;gap:5px;padding-top:6px}.guidance{padding:10px 12px}.destination{margin:9px 0 12px}.destination h2{font-size:23px;letter-spacing:.08em}.destination div>span{font-size:8px}.distance strong{font-size:27px;margin:0 2px}.driving-advice{min-height:36px;gap:6px}.driving-advice p{font-size:9px;line-height:1.6;margin:7px 0}.station-controls{gap:5px}.station-controls button{font-size:9px;min-height:30px;padding:4px 8px}.station-controls kbd{display:none}.stop-target{font-size:8px}.controller{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:0 18px;padding:8px 3px 0;border-top:1px solid #65827b}.controller .panel-heading{grid-column:1;margin:0;grid-row:1;font-size:11px}.controller output{font-size:18px;padding:2px 8px;min-width:46px}.handle-labels{grid-column:1;grid-row:2;margin-top:9px;font-size:9px;padding:0 3px}.controller input{grid-column:1;grid-row:3;margin:15px 0 9px;height:15px}.controller input::-webkit-slider-thumb{width:24px;height:34px}.notch-scale{grid-column:1;grid-row:4;font-size:9px}.drive-buttons{grid-column:2;grid-row:1/4;margin:0;align-self:center;gap:5px}.drive-buttons button{min-height:55px;display:flex;flex-direction:column;gap:3px;font-size:11px}.drive-buttons kbd{font-size:14px;margin:0}.secondary-controls{grid-column:2;grid-row:4;margin:4px 0 0;gap:5px}.secondary-controls button{font-size:9px;min-height:29px;padding:0 3px}footer{font-size:8px;padding:6px 15px 12px}.desktop-copy{display:none}.notice,.pause-screen{padding:20px;width:min(360px,90%)}.notice h2{font-size:20px}.notice p{font-size:11px}.notice .primary{font-size:12px;min-height:38px}dialog{padding:25px 22px}dialog h2{font-size:20px}}
@media(max-width:370px){.console{grid-template-columns:110px minmax(0,1fr);gap:8px;padding:10px}.guidance{padding:9px}.destination h2{font-size:21px}.distance strong{font-size:24px}.stop-target{font-size:7px}.route-label{display:none}.controller{gap:0 12px}.window{height:290px}}
@media(prefers-reduced-motion:reduce){button{transition:none}}
.map-credit{position:absolute;top:44px;right:12px;font-size:10px;color:#fff;text-decoration:none;text-shadow:0 1px 3px #000c;opacity:.9}.map-credit:hover,.map-credit:focus-visible{text-decoration:underline}

/* Stop forecast (stop-forecast.js): over the view, below the top bar, colour matches the bar on the rails. */
.stop-forecast{position:absolute;top:52px;left:50%;transform:translateX(-50%);margin:0;max-width:calc(100% - 32px);padding:5px 12px;border-radius:3px;background:#0d1d1fcc;color:#e9f2ea;font-size:12px;letter-spacing:.02em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-left:4px solid #c9d2cc;pointer-events:none;z-index:2}.stop-forecast[data-grade=good]{border-left-color:#6fe08f}.stop-forecast[data-grade=short]{border-left-color:#f0c050}.stop-forecast[data-grade=over]{border-left-color:#f06a4a}
@media(max-width:740px){.stop-forecast{top:38px;font-size:10px;padding:4px 8px}}
.driving-view .stop-forecast{top:36px;font-size:11px}
