@font-face {
  font-family: 'CapitalistProxima';
  src: url('assets/fonts/ProximaNova-Regular.woff2') format('woff2');
  font-display: swap;
}
@font-face {
  font-family: 'MoscowMapPTHeader';
  src: url('assets/fonts/MoscowMap-PT-Header-Bold.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'RobotoCondensed';
  src: url('assets/fonts/RobotoCondensed-Regular.ttf') format('truetype');
  font-display: swap;
}
* { box-sizing: border-box; }
:root { color-scheme: light; font-family: Arial, Helvetica, sans-serif; --border:#e6e6e6; --muted:#999; --blue:#196dff; --text:#222; }
html, body { width:100%; height:100%; margin:0; overflow:hidden; color:var(--text); background:#fff; }
body { display:flex; flex-direction:column; }
button, input { font:inherit; }
button { border:0; background:none; cursor:pointer; }
.site-header, .site-footer { flex:0 0 50px; display:flex; align-items:center; justify-content:space-between; padding:0 16px; color:#fff; background:#333 url('assets/nametro-header-texture.png') repeat; font-family:'RobotoCondensed', Arial, sans-serif; }
.site-header { position:relative; z-index:20; }
.site-header-brand { display:flex; align-items:center; gap:14px; height:50px; color:#fff; text-decoration:none; }
.site-header-logo { display:block; width:53.24px; height:36.3px; background-color:#507BE8; -webkit-mask:url('assets/metro-header-logo.webp?v=2') center / contain no-repeat; mask:url('assets/metro-header-logo.webp?v=2') center / contain no-repeat; }
.site-header-title { font-size:24px; line-height:24px; font-weight:400; }
.site-footer { font-size:16px; line-height:19px; border-top:1px solid rgba(255,255,255,.08); }
.site-footer a { color:#fff; text-decoration:underline; }
.site-footer a:hover { color:#e8e8e8; }
.app-shell { display:flex; flex:1 1 auto; width:100vw; min-height:0; height:auto; }
.sidebar { --sidebar-width:378px; position:relative; z-index:5; width:var(--sidebar-width); flex:0 0 var(--sidebar-width); min-height:0; overflow-y:auto; background:#fff; border-right:1px solid var(--border); display:flex; flex-direction:column; }
.panel-body { padding:12px 18px 0; font-family:'CapitalistProxima', Arial, sans-serif; }
h1 { margin:0 0 17px; font-size:22px; line-height:29px; font-weight:400; }
.route-form { position:relative; display:flex; flex-direction:column; gap:11px; }
.input-row { display:flex; align-items:center; gap:14px; min-height:43px; }
.route-dot { width:12px; height:12px; flex:0 0 12px; border-radius:50%; background:#d6d6d6; }
.route-dot-from { border:1px solid #2D2D46; background:#fff; }
.route-dot-to { border:1px solid #2D2D46; background:#fff; }
.route-dot-selected { border:0; background:var(--route-dot-color); }
.autocomplete { position:relative; min-width:0; flex:1; margin-right:42px; }
.autocomplete input { width:100%; height:43px; padding:0 38px 0 14px; border:1px solid #2D2D46; border-radius:4px; outline:none; font-size:19px; color:#333; background:#fff; }
.autocomplete input:focus { border-color:#8ab0ff; box-shadow:0 0 0 1px #dce7ff; }
.autocomplete input[aria-invalid="true"] { border-color:#d9232e; box-shadow:0 0 0 1px #f5c2c7; }
.autocomplete input::placeholder { color:#2D2D46; }
.field-error { margin:4px 0 0; color:#b42318; font-family:Arial, sans-serif; font-size:13px; line-height:16px; }
.field-error[hidden] { display:none !important; }
.field-clear { position:absolute; top:50%; right:5px; z-index:2; width:24px; height:24px; padding:0; transform:translateY(-50%); color:#2D2D46; font-size:24px; line-height:20px; font-family:Arial, sans-serif; }
.field-clear:hover { color:#2D2D46; }
.swap-button { position:absolute; right:-5px; top:38px; width:34px; height:34px; padding:0; display:flex; align-items:center; justify-content:center; color:#507BE8; line-height:0; border:1px solid #507BE8; border-radius:50%; }
.swap-icon { display:block; width:24px; height:24px; }
.swap-button:hover { color:#507BE8; border-color:#507BE8; }
.reset-button { width:170px; height:43px; margin-top:11px; margin-left:26px; align-self:flex-start; display:flex; align-items:center; justify-content:center; border:1px solid #2D5CC1; border-radius:3px; background:#fff; color:#2D5CC1; font-size:19px; text-align:center; }
.reset-button:hover { background:#EAF1FF; }
.suggestions { display:none; position:absolute; left:0; right:0; top:48px; z-index:10; max-height:396px; overflow:auto; border:1px solid #ddd; border-radius:5px; background:#fff; box-shadow:0 4px 14px rgba(0,0,0,.12); }
.suggestions.open { display:block; }
.suggestion { display:flex; align-items:center; gap:14px; width:100%; padding:12px 14px; text-align:left; font-size:19px; color:#333; }
.suggestion { cursor:pointer; }
.suggestion:hover, .suggestion:focus, .suggestion[aria-selected="true"] { background:#e6eeff; outline:none; }
.line-badge { width:29px; height:29px; border-radius:50%; color:#fff; font-size:18px; font-weight:700; display:inline-flex; align-items:center; justify-content:center; flex:0 0 29px; }
.suggestion .line-badge { width:16.24px; height:16.24px; flex:0 0 16.24px; }
.route-summary { position:relative; margin:22px -18px 0; padding:0; border-top:1px solid #eee; border-bottom:0; background:#F8FAFF; }
.route-summary-actions { display:grid; grid-auto-rows:1fr; }
.summary-topline { width:100%; }
.summary-topline .summary-time-button { font-family:'CapitalistProxima', Arial, sans-serif; font-size:19.8px; line-height:26.1px; font-weight:400; }
.summary-time-button strong { font-weight:400; }
.summary-time-label { min-width:0; }
.summary-time-button:disabled { cursor:default; }
.summary-time-button:disabled .useful-info-icon { visibility:hidden; }
.summary-time-separator { margin:0 4px; }
.summary-time { margin:0; font-family:inherit; font-size:19.8px; line-height:26.1px; font-weight:400; letter-spacing:0; white-space:nowrap; }
.summary-meta, .summary-lines, .summary-transfers { margin-top:7px; color:#4F5865; font-size:18px; line-height:25px; }
.summary-meta { margin:0 0 12px; }
.summary-reverse-link { display:block; margin-top:14px; color:#196dff; font-size:16px; line-height:22px; text-decoration:none; }
.summary-reverse-link:hover { text-decoration:underline; }
#summaryLines[hidden], #summaryTransfers[hidden] { display:none !important; }
.summary-lines { display:flex; gap:4px; flex-wrap:wrap; align-items:center; }
.summary-transfers { color:#333; }
.summary-stations { list-style:none; margin:0; padding:10px 18px 34px; border-top:1px solid #eee; background:#fff; }
.useful-info { margin:0; padding:0; background:#F8FAFF; }
.useful-info .useful-info-button { box-shadow:inset 0 1px 0 #eee; }
.useful-info-title { height:100%; display:flex; align-items:center; min-height:42px; margin:0; font-family:'CapitalistProxima', Arial, sans-serif; font-size:19.8px; line-height:26.1px; font-weight:400; }
.useful-info-button { height:100%; display:flex; align-items:center; justify-content:space-between; gap:14px; width:100%; min-height:78px; padding:18px; color:inherit; background:transparent; font:inherit; text-align:left; }
.useful-info-button:not(:disabled):hover { background:#eef3fc; }
.useful-info-button:focus-visible { outline:2px solid #2D5CC1; outline-offset:-3px; }
.useful-info-icon { width:20px; height:20px; flex:0 0 20px; fill:none; stroke:#666; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
@media (hover:hover) and (pointer:fine) and (prefers-reduced-motion:no-preference) {
  .useful-info-icon { transition:transform .22s ease; }
  .useful-info-button:not(:disabled):hover .useful-info-icon { transform:translateX(4px); }
}
@media (min-width:761px) {
  .homepage .homepage-info-actions { gap:6px; margin:22px 0 0; background:transparent; }
  .route-page .route-summary { margin-top:16px; background:transparent; }
  .route-page .route-summary-actions { gap:6px; padding:8px 18px 10px; }
  .route-page .route-summary-actions .useful-info { background:transparent; }
  .homepage .homepage-info-actions > .useful-info-button,
  .route-page .route-summary-actions .useful-info-button {
    min-height:52px; padding:8px 14px; gap:10px; border:1px solid #dce7ff; border-radius:8px;
    background:#f2f6ff; color:#2d2d46; box-shadow:none;
    font:400 18px/1.2 CapitalistProxima,Arial,sans-serif;
  }
  .homepage .homepage-info-actions > .useful-info-button { height:auto; }
  .route-page .route-summary-actions .summary-time { font:inherit; }
  .route-page .route-summary-actions .summary-time-separator { margin:0; }
}
@media (min-width:761px) and (hover:hover) and (pointer:fine) {
  .homepage .homepage-info-actions > .useful-info-button:not(:disabled):hover,
  .route-page .route-summary-actions .useful-info-button:not(:disabled):hover { background:#eef3fc; }
}
.useful-info-dialog { width:calc(100% - 32px); max-width:520px; max-height:calc(100dvh - 32px); margin:auto; padding:24px; overflow-y:auto; overscroll-behavior:contain; border:1px solid var(--border); border-radius:12px; background:#fff; color:var(--text); font-family:'CapitalistProxima', Arial, sans-serif; box-shadow:0 16px 60px rgba(0,0,0,.25); }
.useful-info-dialog::backdrop { background:rgba(0,0,0,.45); }
.useful-info-dialog-header { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:16px; }
.useful-info-dialog-header h2 { margin:0; font-size:19.8px; line-height:26.1px; font-weight:400; }
.useful-info-close { display:flex; align-items:center; justify-content:center; width:42px; height:42px; flex:0 0 42px; padding:0; border:1px solid #eee; border-radius:50%; color:#666; background:#EEF3FC; font-family:Arial, sans-serif; font-size:28px; line-height:1; }
.useful-info-close:focus-visible { outline:2px solid #2D5CC1; outline-offset:2px; }
.useful-info-dialog-header > [tabindex="-1"][autofocus]:focus { outline:none; }
.useful-info-description { margin:0; color:#4F5865; font-size:18px; line-height:1.5; }
html.useful-info-open, html.useful-info-open body { overflow:hidden; }
.route-summary:has(#summaryStations[hidden]) .useful-info { display:none; }
.summary-stop { display:flex; align-items:center; gap:10px; min-height:29px; margin:4px 0; font-size:18px; line-height:22px; }
.summary-stop-marker { width:15px; height:15px; flex:0 0 15px; border-radius:50%; background:var(--summary-line-color,#777); }
.summary-stop-name { min-width:0; }
.summary-transfer { display:flex; align-items:center; min-height:20px; margin:1px 0; }
.summary-transfer-icon { display:block; width:18px; height:18px; flex:0 0 18px; margin-left:-1px; background:url('assets/transfer-walk.svg') center / contain no-repeat; opacity:.5; }
.summary-transfer-name, .summary-transfer-lines { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
.map-panel { position:relative; flex:1; min-width:0; background:#fff; overflow:hidden; }
.map-viewport { position:absolute; inset:0; overflow:hidden; display:flex; justify-content:center; align-items:center; cursor:grab; user-select:none; touch-action:none; }
.map-viewport.dragging { cursor:grabbing; }
.map-viewport.dragging .map-frame { transition:none; }
.map-viewport.pinch-zooming .map-frame { transition:none; }
.map-viewport.dragging .map-frame, .map-viewport.pinch-zooming .map-frame { will-change:transform; }
.map-frame { position:relative; width:min(930px, 88%); aspect-ratio:1750 / 1800; transform:scale(1); transform-origin:center center; transition:transform .18s ease; }
.source-map, .source-map svg, .interaction-layer { position:absolute; inset:0; width:100%; height:100%; }
.source-map { pointer-events:none; }
.map-panel.route-active .source-map { filter:grayscale(1); opacity:.2; transition:filter .18s ease, opacity .18s ease; }
.interchange-enhancement { pointer-events:none; }
.interchange-connector { fill:none; stroke-linecap:round; stroke-linejoin:round; }
.interchange-connector { stroke-width:10.5; }
.interchange-marker { stroke-width:5; }
.interchange-double-connector,
.interchange-double-connector-white {
  fill:none;
  stroke-linecap:butt;
  stroke-linejoin:miter;
}
.interchange-double-connector { stroke-width:8.894; }
.interchange-double-connector-white { stroke:#fff; stroke-width:2.541; }
.interchange-double-marker { stroke-width:5.082; }
.source-map .interchange-double-source > circle { display:none; }
.interchange-triple-connector,
.interchange-triple-connector-white {
  fill:none;
  stroke-linecap:butt;
  stroke-linejoin:round;
}
.interchange-triple-branch { stroke-width:8.894; }
.interchange-triple-connector { stroke-width:8.894; }
.interchange-triple-connector-white { stroke:#fff; stroke-width:2.541; stroke-linecap:round; }
.interchange-triple-marker { stroke-width:5.082; }
.interchange-triple-void { fill:#fff; stroke:none; }
.source-map .interchange-triple-source > circle { display:none; }
.source-map .scheme-objects-view__label text,
.source-map .scheme-objects-view__label tspan { font-family:'CapitalistProxima', Arial, sans-serif; }
.source-map .scheme-objects-view__decorations text,
.source-map .scheme-objects-view__decorations tspan {
  font-family:'MoscowMapPTHeader', Arial, sans-serif;
  font-size:22.15px !important;
  font-weight:700;
}
.source-map .scheme-objects-view__label { pointer-events:all; cursor:pointer; transition:none; }
.map-panel.route-active .source-map .scheme-objects-view__label.route-source-label-hidden { visibility:hidden; }
.interaction-layer { overflow:visible; }
.station-hit { fill:transparent; stroke:transparent; stroke-width:0; cursor:pointer; pointer-events:all; }
.station-label-hit { fill:transparent; stroke:none; cursor:pointer; pointer-events:all; }
.station-hit:focus, .station-label-hit:focus { outline:none; }
.station-focus { fill:#fff; stroke:#196dff; stroke-width:4; opacity:0; pointer-events:none; transition:opacity .12s; }
.station-hit:focus-visible + .station-focus { opacity:.95; }
.route-overlay { pointer-events:none; }
.station-pulse-overlay { pointer-events:none; }
.station-menu-layer { position:absolute; inset:0; z-index:12; overflow:visible; pointer-events:none; }
.station-menu-host { position:absolute; width:185px; overflow:visible; pointer-events:auto; }
.station-menu-shell { width:185px; min-height:66px; padding:8.4px; border:1px solid var(--station-menu-soft,#e1e1e1); border-radius:5px; background:#fff; box-shadow:0 2px 8px rgba(0,0,0,.18); color:#222; font-family:Arial, Helvetica, sans-serif; }
.station-menu-title { margin-bottom:7.2px; font-size:15.6px; line-height:18px; white-space:normal; }
.station-menu-actions { display:flex; gap:7.2px; }
.station-menu-action { appearance:none; display:inline-grid; place-items:center; box-sizing:border-box; min-height:34px; padding:8px; border-radius:5px; background:var(--station-menu-soft,#f0f0f0); color:#222; font-size:14.4px; line-height:18px; text-align:center; }
.station-menu-action:hover, .station-menu-action:focus-visible { background:var(--station-menu-hover,#e1e1e1); outline:none; }
.station-selection-pulse, .station-selection-pulse-ring { opacity:.9; transform-box:fill-box; transform-origin:center; }
.station-selection-pulse { stroke-width:1px; }
.station-selection-pulse { animation:station-selection-pulse 1.15s ease-in-out infinite; }
.station-selection-pulse-ring { fill:none; stroke-width:2px; animation:station-selection-ring-pulse 1.15s ease-in-out infinite; }
@keyframes station-selection-pulse {
  0%, 100% { transform:scale(.82); opacity:.9; }
  50% { transform:scale(1.66); opacity:.28; }
}
@keyframes station-selection-ring-pulse {
  0%, 100% { transform:scale(.82); opacity:.9; }
  50% { transform:scale(1.28); opacity:.28; }
}
@media (prefers-reduced-motion: reduce) {
  .station-selection-pulse, .station-selection-pulse-ring { animation:none; opacity:.9; }
}
.route-segment-casing, .route-segment { fill:none; stroke-linecap:round; stroke-linejoin:round; pointer-events:none; }
.route-segment-casing { stroke:#fff; stroke-width:7.14px; opacity:.95; }
.route-segment { stroke-width:7.14px; }
.route-transition { fill:none; stroke-width:7.14px; stroke-linecap:round; stroke-linejoin:round; pointer-events:none; }
.route-station { fill:currentColor; stroke:#fff; stroke-width:2.5px; pointer-events:none; }
.route-endpoint { stroke-width:3px; pointer-events:none; }
.route-label, .route-label-fallback { pointer-events:none; }
.route-label text, .route-label tspan, .route-label-fallback { fill:#1f2937 !important; stroke:none !important; opacity:1 !important; font-family:'CapitalistProxima', Arial, sans-serif; font-weight:400 !important; }
.route-label text { font-size:20px; }
.route-label-fallback { font-size:20px; }
.map-panel.route-active .station-focus { opacity:0; }
.zoom-controls { position:absolute; right:8px; top:50%; transform:translateY(-50%); display:flex; flex-direction:column; border:1px solid #ddd; border-radius:6px; overflow:hidden; background:#fff; box-shadow:0 1px 3px rgba(0,0,0,.08); }
.zoom-controls button { width:27px; height:29px; color:#333; font-size:20px; line-height:25px; }
.zoom-controls button + button { border-top:1px solid #e5e5e5; }
.zoom-controls button:hover { background:#f5f5f5; }
.toast { position:fixed; left:50%; bottom:24px; transform:translate(-50%, 12px); opacity:0; padding:9px 13px; border-radius:6px; color:#fff; background:rgba(30,30,30,.88); font-size:12px; pointer-events:none; transition:opacity .18s, transform .18s; z-index:20; }
.toast.visible { opacity:1; transform:translate(-50%,0); }
@media (max-width:760px) {
  html, body { overflow:auto; }
  .site-header, .site-footer { flex-basis:50px; }
  .site-header { padding:0 12px; }
  .site-header-brand { gap:10px; }
  .site-header-title { font-size:20px; line-height:22px; }
  .site-header-logo { width:45.98px; height:33.88px; }
  .site-footer { padding:0 12px; font-size:13px; }
  .app-shell { display:block; flex:0 0 auto; height:auto; min-height:calc(100vh - 100px); }
  .sidebar { width:100%; height:auto; min-height:223px; overflow:visible; scrollbar-gutter:auto; z-index:10; border-right:0; border-bottom:0; }
  .panel-body { padding:12px 18px 0; }
  .route-page .panel-body { padding:9.6px 18px 0; }
  h1 { margin-bottom:14px; font-size:24.2px; line-height:32px; letter-spacing:-.2px; white-space:normal; overflow-wrap:anywhere; }
  .reset-button:hover, .reset-button:active, .reset-button:focus { background:#fff; }
  .route-form { max-width:420px; }
  .route-page .site-header { display:none !important; }
  .route-page .route-form { display:none !important; }
  .suggestions { max-height:min(280px, 35dvh); overscroll-behavior:contain; }
  .site-footer { display:none !important; }
  .route-page .site-footer { display:none !important; }
  .route-page .app-shell { min-height:calc(100vh - 50px); }
  .route-page .app-shell { display:flex; flex-direction:column; flex:1 1 auto; height:auto; min-height:0; }
  .route-page .app-shell { min-height:100vh; }
  .route-page .sidebar { min-height:0; flex:0 0 auto; }
  .route-page .map-panel { flex:1 1 auto; height:auto; min-height:430px; }
  .route-page .reset-button { position:fixed; left:50%; bottom:20px; z-index:31; margin:0; transform:translateX(-50%); }
  body:not(.route-page) .app-shell { display:flex; flex-direction:column; flex:1 1 auto; height:auto; min-height:0; }
  body:not(.route-page) .sidebar { min-height:0; flex:0 0 auto; }
  body:not(.route-page) .map-panel { flex:1 1 auto; height:auto; min-height:430px; }
  .map-panel { position:relative; z-index:0; height:calc(100vh - 323px); min-height:430px; }
  .route-page .map-panel { height:calc(100vh - 223px); }
  .route-page .route-summary { margin:5px -18px 0; }
  .route-page .useful-info-button { min-height:65.04px; padding:11.52px 18px; }
  .useful-info-dialog { padding:18px; }
  .map-frame { width:720px; min-width:720px; max-width:none; flex:0 0 720px; }
  .map-viewport { align-items:center; overflow:auto; justify-content:center; scrollbar-width:none; }
  .map-viewport::-webkit-scrollbar { display:none; }
  .zoom-controls { right:12px; top:auto; bottom:16px; z-index:4; transform:none; gap:12px; border:0; border-radius:0; overflow:visible; background:transparent; box-shadow:none; }
  .map-panel.route-active .zoom-controls { position:fixed; right:12px; bottom:16px; z-index:30; }
  .zoom-controls button { position:relative; width:52px; height:52px; padding:0; display:flex; align-items:center; justify-content:center; border:1px solid #eee; border-radius:50%; background:#fff; box-shadow:0 2px 8px rgba(0,0,0,.12); color:transparent; font-size:0; line-height:1; transition:transform .12s ease, box-shadow .12s ease; -webkit-tap-highlight-color:transparent; }
  .zoom-controls button::before, .zoom-controls button:first-child::after { content:""; position:absolute; left:50%; top:50%; display:block; background:#666; border-radius:1px; transform:translate(-50%,-50%); }
  .zoom-controls button::before { width:30px; height:1.5px; }
  .zoom-controls button:first-child::after { width:1.5px; height:30px; }
  .zoom-controls button:hover, .zoom-controls button:active, .zoom-controls button:focus { background:#fff; }
  .zoom-controls button:active { transform:scale(.9); box-shadow:0 1px 3px rgba(0,0,0,.18); }
  .zoom-controls button + button { border-top:1px solid #eee; }
}
