:root {
  color-scheme: dark;
  --bg: #090B0F;
  --surface: rgba(255, 255, 255, 0.05);
  --surface-solid: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.075);
  --line: rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #F2F4F7;
  --text-2: #9AA3AF;
  --text-3: #6B7480;
  --text-3-readable: #7D8794;
  --accent: #9BE7D8;
  --accent-ink: #06110F;
  --radius-card: 12px;
  --radius-control: 10px;
  --radius-tag: 6px;
  --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "HarmonyOS Sans SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-serif: "Songti SC", "Noto Serif SC", "Source Han Serif SC", serif;
  --shadow-sheet: 0 -24px 60px rgba(0, 0, 0, 0.56);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
button:not(:disabled), a { cursor: pointer; }
button:disabled { cursor: default; opacity: 0.58; }
button:focus-visible, a:focus-visible, input:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
[hidden] { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.ambient-glow { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.ambient-glow span { position: absolute; width: 520px; height: 520px; border-radius: 50%; filter: blur(18px); }
.ambient-glow__one { top: -260px; left: -180px; background: radial-gradient(circle, rgba(39, 100, 113, 0.09) 0%, rgba(39, 100, 113, 0) 70%); }
.ambient-glow__two { right: -260px; bottom: -300px; background: radial-gradient(circle, rgba(42, 80, 102, 0.08) 0%, rgba(42, 80, 102, 0) 70%); }

.topbar {
  position: relative; z-index: 2; width: calc(100% - 32px); max-width: 1040px; height: 56px;
  margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { min-width: 0; display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.brand__name {
  display: inline-flex; align-items: baseline; letter-spacing: -0.04em;
  font-family: var(--font-sans); font-size: 21px; font-weight: 650; line-height: 1;
}
.brand__serif {
  padding: 0 1px; font-family: var(--font-serif); font-size: 28px;
  font-weight: 500; letter-spacing: 0;
}
.brand__meta {
  display: flex; flex-direction: column; justify-content: center; gap: 3px;
  color: var(--text-2); font-size: 9px; line-height: 1; white-space: nowrap;
}
.brand__meta span:first-child { letter-spacing: 0.18em; }
.brand__meta span:last-child { color: var(--text-3-readable); font-size: 10px; letter-spacing: 0.08em; }
.city-mark {
  flex: 0 0 44px; width: 44px; height: 44px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: var(--radius-control);
  color: var(--text-2); font-size: 12px; line-height: 1; letter-spacing: 0.10em; writing-mode: vertical-rl;
}
.page-shell {
  position: relative; z-index: 1; width: calc(100% - 32px); max-width: 1040px;
  margin: 0 auto; padding: 18px 0 36px;
}
.workspace { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; align-items: start; }
.sidebar { min-width: 0; }
.search-panel {
  position: relative; z-index: 5; padding: 16px; border: 1px solid var(--line);
  border-radius: var(--radius-card); background: rgba(20, 24, 30, 0.55);
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .search-panel { -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%); }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .search-panel { background: #12151B; }
}
.query-grid { display: grid; grid-template-columns: minmax(0, 1fr) 44px; gap: 12px; align-items: stretch; }
.place-stack { position: relative; z-index: 6; display: grid; gap: 12px; min-width: 0; }
.place-rail {
  position: absolute; top: 24px; bottom: 24px; left: 19px; width: 1px;
  background: var(--line-strong); pointer-events: none;
}
.place-node {
  position: absolute; left: 50%; width: 9px; height: 9px; border-radius: 50%;
  transform: translate(-50%, -50%); background: var(--bg);
}
.place-node--origin { top: 0; border: 1px solid var(--text-2); }
.place-node--destination { top: 100%; border: 1px solid var(--accent); background: var(--accent); }
.place-row {
  position: relative; height: 48px; border: 1px solid var(--line);
  border-radius: var(--radius-control); background: rgba(255, 255, 255, 0.035);
}
.place-row:focus-within { border-color: var(--line-strong); }
.place-input {
  width: 100%; height: 46px; padding: 0 48px 0 36px; border: 0; border-radius: inherit;
  background: transparent; color: var(--text); font-size: 16px; line-height: 1.2;
  outline: none; -webkit-appearance: none; appearance: none;
}
.place-row[data-field="destination"] .place-input { padding-right: 14px; }
.place-input::placeholder { color: var(--text-3); opacity: 1; }
.place-input::-webkit-search-cancel-button { display: none; }
.icon-button {
  width: 44px; height: 44px; display: inline-grid; place-items: center; padding: 0;
  border: 1px solid var(--line); border-radius: var(--radius-control);
  background: transparent; color: var(--text-2); transition: opacity 160ms ease, transform 160ms ease;
}
.icon-button:hover { color: var(--text); background: var(--surface-hover); }
.icon-button:active { transform: scale(0.97); }
.icon-button svg {
  width: 19px; height: 19px; fill: none; stroke: currentColor;
  stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.55;
}
.locate-button { position: absolute; top: 1px; right: 1px; border-color: transparent; }
.swap-button { align-self: center; grid-column: 2; grid-row: 1; }
.suggestion-panel {
  position: relative; z-index: 40; max-height: 40vh; margin-top: 10px;
  overflow-y: auto; padding: 5px; border: 1px solid var(--line);
  border-radius: var(--radius-control); background: #12151B;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.50); overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
}
.suggestion-option {
  width: 100%; min-height: 48px; padding: 8px 10px; border: 0;
  border-radius: var(--radius-tag); background: transparent; text-align: left;
}
.suggestion-option:hover, .suggestion-option:focus-visible, .suggestion-option.is-highlighted {
  background: rgba(255, 255, 255, 0.075);
  box-shadow: inset 0 0 0 1px var(--line);
}
.suggestion-option__name {
  display: block; overflow: hidden; color: var(--text); font-size: 14px;
  line-height: 1.3; text-overflow: ellipsis; white-space: nowrap;
}
.suggestion-option__meta {
  display: block; overflow: hidden; margin-top: 4px; color: var(--text-3);
  font-size: 11px; line-height: 1.3; text-overflow: ellipsis; white-space: nowrap;
}
.suggestion-empty, .suggestion-loading {
  min-height: 44px; display: flex; align-items: center; padding: 0 10px;
  color: var(--text-3); font-size: 12px;
}
.inline-warning {
  display: flex; align-items: center; gap: 8px; margin: 10px 0 0;
  color: var(--text-2); font-size: 12px; line-height: 1.5;
}
.inline-warning__mark {
  flex: 0 0 16px; width: 16px; height: 16px; display: grid; place-items: center;
  border: 1px solid var(--accent); border-radius: 50%; color: var(--accent);
  font-size: 10px; font-weight: 700;
}
.train-date-control { margin-top: 12px; }
.segmented {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; padding: 2px;
  border: 1px solid var(--line); border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.025);
}
.segmented__button {
  min-height: 40px; padding: 0 6px; border: 0; border-radius: 7px;
  background: transparent; color: var(--text-2); font-size: 12px;
}
.segmented__button[aria-pressed="true"] { background: rgba(255, 255, 255, 0.085); color: var(--text); }
.custom-date {
  width: 100%; min-height: 42px; margin-top: 8px; padding: 0 10px;
  border: 1px solid var(--line); border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.035); color: var(--text); color-scheme: dark; font-size: 14px;
}
.primary-button {
  width: 100%; min-height: 52px; margin-top: 16px; display: inline-flex;
  align-items: center; justify-content: center; gap: 9px; padding: 0 16px;
  border: 0; border-radius: var(--radius-control); background: var(--accent);
  color: var(--accent-ink); font-size: 16px; font-weight: 650;
  transition: opacity 160ms ease, transform 160ms ease;
}
.primary-button:not(:disabled):active { transform: scale(0.992); }
.primary-button__spinner {
  width: 14px; height: 14px; border: 2px solid rgba(6, 17, 15, 0.28);
  border-top-color: var(--accent-ink); border-radius: 50%; animation: spin 700ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.mode-tabs {
  position: relative; z-index: 4; display: flex; gap: 0; margin-top: 16px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.mode-tabs::-webkit-scrollbar { display: none; }
.mode-tab {
  flex: 1 0 56px; min-width: 56px; min-height: 44px; display: inline-flex;
  align-items: center; justify-content: center; gap: 5px; padding: 0 4px 2px;
  border: 0; border-bottom: 2px solid transparent; background: transparent;
  color: var(--text-2); font-size: 13px; line-height: 1; white-space: nowrap;
}
.mode-tab[aria-selected="true"] { border-bottom-color: var(--accent); color: var(--text); }
.mode-tab__count { color: var(--text-3); font-size: 11px; font-variant-numeric: tabular-nums; }
.mode-tab[aria-selected="true"] .mode-tab__count { color: var(--text-2); }
.results { min-width: 0; }
.result-meta {
  min-height: 22px; display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  color: var(--text-2); font-size: 13px; line-height: 1.5;
}
.result-meta__dot { color: var(--text-3); }
.result-panel { margin-top: 12px; }.empty-state {
  min-height: 220px; display: flex; flex-direction: column; align-items: flex-start;
  justify-content: center; padding: 26px 2px;
}
.empty-state__title { margin: 0; color: var(--text); font-size: 15px; font-weight: 550; line-height: 1.5; }
.empty-state__desc { max-width: 440px; margin: 8px 0 0; color: var(--text-3-readable); font-size: 12px; line-height: 1.7; }
.query-status {
  min-height: 148px; display: flex; align-items: center; padding: 24px 2px;
  color: var(--text-2); font-size: 14px;
}
.query-status--error { align-items: flex-start; gap: 10px; color: var(--text); }
.query-status__mark {
  flex: 0 0 18px; width: 18px; height: 18px; display: grid; place-items: center;
  margin-top: 1px; border: 1px solid var(--line-strong); border-radius: 50%;
  color: var(--text-2); font-size: 11px; font-weight: 700;
}
.query-status__body { min-width: 0; }
.query-status__body p { margin: 0; line-height: 1.65; }
.outline-button {
  min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 0 14px; border: 1px solid var(--line-strong); border-radius: var(--radius-control);
  background: transparent; color: var(--text); font-size: 13px; font-weight: 550;
  text-decoration: none; transition: opacity 160ms ease, transform 160ms ease;
}
.outline-button:hover { background: var(--surface-hover); }
.outline-button:active { transform: scale(0.985); }
.result-notices { display: grid; gap: 6px; margin-bottom: 12px; }
.result-notices p {
  margin: 0; padding: 9px 11px; border: 1px solid var(--line); border-radius: var(--radius-tag);
  background: rgba(255, 255, 255, 0.025); color: var(--text-2); font-size: 12px; line-height: 1.55;
}
.overview-card {
  margin-bottom: 12px; padding: 13px 14px; border: 1px solid var(--line);
  border-radius: var(--radius-card); background: var(--surface-solid);
}
.overview-card strong { display: block; color: var(--text); font-size: 13px; font-weight: 600; line-height: 1.5; }
.overview-card p { margin: 5px 0 0; color: var(--text-2); font-size: 12px; line-height: 1.6; }
.route-stack { display: grid; gap: 12px; }
.route-card {
  position: relative; overflow: hidden; border: 1px solid var(--line);
  border-radius: var(--radius-card); background: var(--surface-solid);
}
.route-card--recommended::before {
  position: absolute; top: 0; right: 0; left: 0; height: 2px;
  background: var(--accent); content: "";
}
.route-card__head {
  width: 100%; display: block; padding: 16px; border: 0; background: transparent; text-align: left;
}
.route-card__topline { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.route-card__duration {
  color: var(--text); font-size: 28px; font-weight: 650; line-height: 1.08;
  letter-spacing: -0.035em; white-space: nowrap;
}
.route-card__fare {
  flex: 0 0 auto; padding-top: 5px; color: var(--accent); font-size: 15px;
  font-weight: 600; line-height: 1.2; white-space: nowrap;
}
.route-card__title {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2;
  overflow: hidden; margin: 9px 0 0; color: var(--text); font-size: 15px;
  font-weight: 550; line-height: 1.45; overflow-wrap: anywhere; word-break: break-word;
}.route-metrics {
  display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 10px;
  color: var(--text-2); font-size: 13px; line-height: 1.4;
}
.route-metrics span { white-space: nowrap; }
.route-source {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
  margin-top: 10px; color: var(--text-3); font-size: 12px; line-height: 1.45;
}
.route-source__text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.route-expand {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 4px;
  min-height: 24px; color: var(--text-2); font-size: 12px; white-space: nowrap;
}
.route-expand svg {
  width: 13px; height: 13px; fill: none; stroke: currentColor;
  stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; transition: transform 180ms ease;
}
.route-card__head[aria-expanded="true"] .route-expand svg { transform: rotate(180deg); }
.taxi-inline { padding: 0 16px 14px; }
.taxi-inline .outline-button { width: 100%; }
.route-details { padding: 0 16px 16px; border-top: 1px solid var(--line); }
.route-details__service { margin: 14px 0 0; color: var(--text-2); font-size: 12px; line-height: 1.6; }
.route-details__divider { height: 1px; margin: 13px 0; background: var(--line); }
.step-list { position: relative; display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.step-list::before {
  position: absolute; top: 13px; bottom: 13px; left: 5px; width: 1px;
  background: var(--line); content: "";
}
.step {
  position: relative; display: grid; grid-template-columns: 12px minmax(0, 1fr);
  gap: 11px; padding: 0 0 16px;
}
.step:last-child { padding-bottom: 0; }
.step__dot {
  position: relative; z-index: 1; width: 11px; height: 11px; margin-top: 4px;
  border: 1px solid var(--text-2); border-radius: 50%; background: #101218;
}
.step__body { min-width: 0; }
.step__label {
  display: inline-flex; min-height: 20px; align-items: center; padding: 2px 6px;
  border-radius: var(--radius-tag); background: rgba(255, 255, 255, 0.075);
  color: var(--text-2); font-size: 10px; line-height: 1.2;
}
.step__title {
  margin: 6px 0 0; color: var(--text); font-size: 13px; font-weight: 550;
  line-height: 1.5; overflow-wrap: anywhere; word-break: break-word;
}
.step__desc, .step__meta {
  margin: 4px 0 0; color: var(--text-2); font-size: 12px; line-height: 1.6;
  overflow-wrap: anywhere; word-break: break-word;
}
.step__meta { color: var(--text-3-readable); }
.route-actions {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px; margin-top: 14px;
}
.route-actions .outline-button { width: 100%; min-width: 0; padding: 0 8px; white-space: nowrap; }.relay-card {
  position: relative; margin-bottom: 16px; padding: 16px; border: 1px solid var(--line);
  border-radius: var(--radius-card); background: var(--surface-solid);
}
.relay-card__eyebrow { margin: 0; color: var(--text-3); font-size: 10px; letter-spacing: 0.12em; }
.relay-card__title { margin: 7px 0 0; color: var(--text); font-size: 16px; font-weight: 600; line-height: 1.45; }
.relay-card__desc { margin: 6px 0 0; color: var(--text-2); font-size: 12px; line-height: 1.65; }
.relay-card__note { margin: 3px 0 0; color: var(--text-3); font-size: 12px; line-height: 1.6; }
.relay-list { position: relative; display: grid; gap: 0; margin: 16px 0 0; padding: 0; list-style: none; }
.relay-list::before {
  position: absolute; top: 20px; bottom: 20px; left: 5px; width: 1px;
  background: var(--line); content: "";
}
.relay-segment {
  position: relative; display: grid; grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 11px; align-items: start; padding: 0 0 15px;
}
.relay-segment:last-child { padding-bottom: 0; }
.relay-segment__dot {
  position: relative; z-index: 1; width: 11px; height: 11px; margin-top: 6px;
  border: 1px solid var(--text-2); border-radius: 50%; background: #101218;
}
.relay-segment__body { min-width: 0; padding-top: 1px; }
.relay-segment__tag {
  display: inline-flex; min-height: 20px; align-items: center; padding: 2px 6px;
  border-radius: var(--radius-tag); background: rgba(255, 255, 255, 0.075);
  color: var(--text-2); font-size: 10px;
}
.relay-segment__route {
  margin: 6px 0 0; color: var(--text); font-size: 13px; font-weight: 550;
  line-height: 1.45; overflow-wrap: anywhere;
}
.relay-segment__summary { margin: 4px 0 0; color: var(--text-3); font-size: 12px; line-height: 1.55; }
.relay-segment__button {
  min-height: 44px; padding: 0 12px; border: 1px solid var(--line-strong);
  border-radius: var(--radius-control); background: transparent; color: var(--text);
  font-size: 12px; white-space: nowrap;
}
.relay-segment__button:hover { background: var(--surface-hover); }
.relay-expanded { grid-column: 2 / 4; margin-top: 8px; }
.relay-expanded .route-card { background: rgba(255, 255, 255, 0.025); }
.relay-unavailable, .relay-manual, .relay-loading {
  padding: 12px; border: 1px solid var(--line); border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.025); color: var(--text-2); font-size: 12px; line-height: 1.65;
}
.relay-unavailable p, .relay-manual p, .relay-loading p { margin: 0; }
.relay-unavailable a {
  display: inline-flex; min-height: 44px; align-items: center; margin-top: 6px;
  color: var(--text); text-decoration: underline; text-underline-offset: 3px;
}
.relay-manual ol { display: grid; gap: 10px; margin: 10px 0 0; padding-left: 18px; }
.relay-manual li { padding-left: 3px; }
.relay-manual strong { color: var(--text); font-size: 12px; font-weight: 550; }
.taxi-alternative { margin-top: 24px; }
.section-label { margin: 0 0 9px; color: var(--text-2); font-size: 12px; line-height: 1.5; }
.manual-card { border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface-solid); }
.manual-card__head { width: 100%; padding: 16px; border: 0; background: transparent; text-align: left; }
.manual-card__eyebrow { margin: 0; color: var(--text-3); font-size: 10px; letter-spacing: 0.10em; }
.manual-card__title { margin: 7px 0 0; color: var(--text); font-size: 16px; font-weight: 600; line-height: 1.45; }
.manual-card__summary { margin: 7px 0 0; color: var(--text-2); font-size: 12px; line-height: 1.65; }
.manual-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; }
.manual-card__source { color: var(--text-3); font-size: 11px; }
.empty-filter { min-height: 150px; display: flex; flex-direction: column; justify-content: center; padding: 20px 2px; }
.empty-filter strong { color: var(--text); font-size: 14px; font-weight: 550; }
.empty-filter p { margin: 7px 0 0; color: var(--text-3); font-size: 12px; line-height: 1.65; }
.page-footer {
  margin-top: 28px; padding-top: 14px; border-top: 1px solid var(--line);
  color: var(--text-3-readable); font-size: 12px; line-height: 1.6;
}.sheet-backdrop { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.62); }
.bottom-sheet {
  position: fixed; right: 0; bottom: 0; left: 0; z-index: 91;
  width: 100%; max-width: 560px; max-height: 78vh; margin: 0 auto; overflow-y: auto;
  padding: 20px 18px; padding-bottom: calc(20px + env(safe-area-inset-bottom));
  border: 1px solid var(--line); border-bottom: 0; border-radius: 14px 14px 0 0;
  background: #12151B; box-shadow: var(--shadow-sheet); -webkit-overflow-scrolling: touch;
}
.bottom-sheet__handle {
  width: 34px; height: 3px; margin: -7px auto 16px; border-radius: 3px; background: var(--line-strong);
}
.bottom-sheet h2 { margin: 0; color: var(--text); font-size: 17px; font-weight: 600; line-height: 1.4; }
.bottom-sheet__desc { margin: 8px 0 0; color: var(--text-2); font-size: 13px; line-height: 1.65; }
.external-links { display: grid; gap: 8px; margin-top: 16px; }
.external-link {
  min-height: 58px; display: flex; align-items: center; justify-content: space-between;
  gap: 14px; padding: 10px 12px; border: 1px solid var(--line);
  border-radius: var(--radius-control); background: rgba(255, 255, 255, 0.025);
  color: var(--text); text-decoration: none;
}
.external-link:hover { background: var(--surface-hover); }
.external-link__copy { min-width: 0; }
.external-link strong { display: block; font-size: 13px; font-weight: 550; }
.external-link__copy > span { display: block; margin-top: 3px; color: var(--text-2); font-size: 11px; line-height: 1.45; }
.external-link__arrow { flex: 0 0 auto; color: var(--text-2); font-size: 16px; }
.sheet-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 16px; }
.sheet-actions button { min-height: 46px; border-radius: var(--radius-control); font-size: 14px; font-weight: 600; }
.sheet-copy { border: 0; background: var(--accent); color: var(--accent-ink); }
.sheet-close { border: 1px solid var(--line-strong); background: transparent; color: var(--text); }
.toast {
  position: fixed; right: 16px; bottom: calc(18px + env(safe-area-inset-bottom));
  left: 16px; z-index: 120; width: max-content; max-width: calc(100% - 32px);
  margin: 0 auto; padding: 10px 14px; border: 1px solid var(--line-strong);
  border-radius: var(--radius-control); background: #12151B; color: var(--text);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.42); font-size: 12px; line-height: 1.45;
}
@media (max-width: 389px) {
  .topbar, .page-shell { width: calc(100% - 24px); }
  .brand { gap: 7px; }
  .brand__name { font-size: 19px; }
  .brand__serif { font-size: 26px; }
  .brand__meta { font-size: 8px; }
  .page-shell { padding-top: 14px; }
  .query-grid { grid-template-columns: minmax(0, 1fr) 44px; gap: 8px; }
  .mode-tab { flex-basis: 55px; min-width: 55px; font-size: 12px; }
  .route-card__duration { font-size: 26px; }
}

@media (min-width: 900px) {
  .topbar { height: 56px; }
  .page-shell { padding-top: 24px; }
  .workspace { grid-template-columns: 360px minmax(0, 1fr); gap: 32px; }
  .sidebar { position: sticky; top: 24px; }
  .results { min-height: 520px; }
  .result-panel { margin-top: 14px; }
  .empty-state { min-height: 310px; padding-left: 12px; }
  .relay-segment__button { min-width: 92px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
.route-details__service a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.relay-train-results {
  display: grid;
  gap: 8px;
}

.train-option-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 16px 14px;
  color: var(--text-3);
  font-size: 11px;
}

.train-option-footer .outline-button {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 12px;
  font-size: 12px;
}