:root {
  color-scheme: light;
  --page: #f1f5f6;
  --surface: #fff;
  --ink: #15242e;
  --muted: #566671;
  --line: #e0e7ea;
  --brand: #12665c;
  --brand-strong: #09493f;
  --brand-pale: #e7f4ed;
  --green: #176041;
  --green-bg: #dff4e8;
  --amber: #785012;
  --amber-bg: #fff0d3;
  --red: #a12935;
  --red-bg: #fce8e8;
  --gray: #536575;
  --gray-bg: #ebf0f3;
  --shadow: 0 12px 38px #16363b09, 0 2px 4px #16363b06;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  color: var(--ink);
  background: var(--page);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 300px; }
body { margin: 0; min-height: 100vh; }
button, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: 0.65; }
button:focus-visible, a:focus-visible, select:focus-visible, summary:focus-visible, input:focus-visible { outline: 3px solid #1b8f7d; outline-offset: 3px; }
.topbar svg, .demo-tools svg, .panel-header svg, .details-content svg,
.weather-warning svg, .incident-actions svg, .workspace-footer svg {
  display: block;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}
main p, main h1, main h2, main h3, main dl, main dd { margin: 0; }
a { color: inherit; text-decoration: none; }

.skip-link {
  position: absolute;
  transform: translateY(-200%);
  padding: 12px 16px;
  z-index: 10;
  background: white;
  border-radius: 8px;
}
.skip-link:focus { transform: none; }

.topbar { position: relative; z-index: 8; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar-inner {
  min-height: 74px;
  width: min(1352px, calc(100% - 72px));
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
}
.brand { display: inline-flex; align-items: center; gap: 12px; justify-self: start; white-space: nowrap; }
.brand-mark {
  width: 42px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  background: #166759;
  color: #fff;
  border-radius: 13px;
}
.brand-mark svg { width: 30px; height: 30px; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 16px; line-height: 1.18; letter-spacing: -0.025em; font-weight: 750; }
.brand small { margin-top: 4px; color: var(--muted); font-size: 11px; font-weight: 550; }
.mode-nav {
  display: flex;
  gap: 3px;
  padding: 4px;
  border: 1px solid #e8edef;
  border-radius: 12px;
  background: #f3f6f7;
}
.mode-button {
  min-height: 37px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
}
.mode-button svg, .city svg { width: 17px; height: 17px; }
.mode-button:hover { color: var(--brand); }
.mode-button[aria-pressed="true"] {
  border-color: var(--line);
  background: var(--surface);
  color: var(--brand-strong);
  box-shadow: 0 1px 2px #133c3d0c;
}
.city {
  display: inline-flex;
  justify-self: end;
  align-items: center;
  gap: 8px;
  color: #3f5960;
  font-size: 13px;
  font-weight: 650;
}
.header-account { display: flex; align-items: center; justify-self: end; gap: 12px; }
.account-settings { position: relative; }
.account-settings summary {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 41px;
  padding-inline: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--brand-strong);
  background: var(--surface);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  white-space: nowrap;
  list-style: none;
}
.account-settings summary::-webkit-details-marker { display: none; }
.account-settings summary:hover, .account-settings[open] summary { background: var(--brand-pale); }
.account-settings summary svg { width: 17px; height: 17px; }
.account-settings summary .account-chevron { width: 12px; height: 12px; }
.account-settings[open] .account-chevron { transform: rotate(180deg); }
.account-panel {
  position: absolute;
  inset: calc(100% + 9px) 0 auto auto;
  width: min(250px, calc(100vw - 24px));
  margin: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface);
  box-shadow: 0 12px 26px #16363b21;
}
.account-panel fieldset { min-inline-size: 0; margin: 0; padding: 0; border: 0; }
.account-panel legend {
  margin-bottom: 7px;
  padding-inline: 10px;
  font-size: 14px;
  font-weight: 720;
}
.map-provider-option {
  display: flex;
  align-items: start;
  gap: 9px;
  min-height: 41px;
  padding: 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.map-provider-option:hover, .map-provider-option:has(input:checked) { background: var(--brand-pale); }
.map-provider-option input { width: 16px; height: 16px; margin: 0; accent-color: var(--brand-strong); }
.map-provider-option small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; font-weight: 500; }

.workspace { width: min(1352px, calc(100% - 72px)); margin-inline: auto; padding: 40px 0 24px; }
.page-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 25px;
}
.page-heading h1 { max-width: 20ch; font-size: clamp(30px, 4vw, 49px); line-height: 1.06; letter-spacing: -0.057em; font-weight: 760; }
.page-heading p { margin-top: 10px; color: var(--muted); font-size: 15px; line-height: 1.5; }
.demo-tools {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 2px 3px #16363b04;
}
.scenario-field { display: block; max-width: 215px; padding: 3px 6px 3px 7px; }
.demo-tag { display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 9px; letter-spacing: .035em; font-weight: 700; white-space: nowrap; }
.demo-tag > span { width: 6px; height: 6px; border-radius: 50%; background: #c98332; }
.scenario-field select {
  max-width: 100%;
  margin: 2px 0 0 -3px;
  color: #253c47;
  border: 0;
  background: transparent;
  font-size: 12px;
  font-weight: 730;
  cursor: pointer;
}
.demo-buttons { display: flex; align-items: center; gap: 4px; border-left: 1px solid var(--line); padding-left: 7px; }
.icon-button {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 9px;
  color: #354e59;
  background: #f0f4f5;
}
.icon-button:hover, .icon-button[aria-pressed="true"] { background: var(--brand-pale); color: var(--brand-strong); }
.icon-button svg { width: 16px; height: 16px; }
.notification, .load-error {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 11px;
  font-size: 14px;
  font-weight: 600;
}
.notification { background: var(--brand-pale); border: 1px solid #c4e3d2; color: var(--brand-strong); }
.load-error { display: flex; align-items: center; gap: 12px; background: var(--amber-bg); border: 1px solid #f2dfa6; color: var(--amber); }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(335px, 370px); align-items: start; gap: 20px; }
.dispatcher-grid { grid-template-columns: minmax(0, 1fr) minmax(367px, 415px); }
.panel {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 19px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px; }
.section-heading { display: flex; align-items: center; gap: 11px; min-width: 0; }
.section-heading > div { min-width: 0; }
.section-heading h2 { font-size: 17px; letter-spacing: -0.024em; line-height: 1.2; }
.section-heading p { color: var(--muted); line-height: 1.35; font-size: 12px; margin-top: 4px; }
.section-icon {
  width: 37px;
  height: 37px;
  display: grid;
  place-items: center;
  flex: 0 0 37px;
  border-radius: 11px;
  color: var(--brand);
  background: var(--brand-pale);
}
.section-icon svg { width: 19px; height: 19px; }
.route-badge {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  padding: 6px 9px;
  background: var(--brand-pale);
  color: var(--brand-strong);
  font-size: 13px;
  font-weight: 800;
  border-radius: 9px;
  white-space: nowrap;
}
.route-badge svg { width: 16px; height: 16px; }
.map-stage {
  position: relative;
  isolation: isolate;
  min-height: 458px;
  height: min(55vh, 570px);
  border-block: 1px solid var(--line);
  background: #e7eef0;
  overflow: hidden;
}
#route-map { position: absolute; inset: 0; }
.map-overlay {
  position: absolute;
  z-index: 4;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 14px;
  pointer-events: none;
}
.map-footer { min-height: 43px; display: flex; align-items: center; gap: 17px; padding: 9px 20px; flex-wrap: wrap; }
.map-footer > span { display: flex; gap: 7px; align-items: center; color: var(--muted); font-size: 11px; white-space: nowrap; }
.map-footer i { display: inline-block; }
.map-footer .map-source { margin-left: auto; }
.map-source a { color: inherit; }
.legend-line { width: 17px; height: 3px; border-radius: 3px; background: var(--brand); }
.legend-stop { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--brand); background: #fff; }
.legend-bus { width: 10px; height: 10px; border-radius: 3px; background: #d08426; }

.details-panel { min-width: 0; }
.details-header { padding-bottom: 14px; }
.details-content { display: grid; gap: 13px; padding: 0 17px 17px; }
.field { display: block; min-width: 0; }
.field > span:first-child { display: block; margin: 0 0 5px 1px; color: #43545e; font-size: 11px; font-weight: 715; }
.select-wrap { position: relative; display: block; }
.select-wrap > svg { position: absolute; top: 11px; left: 10px; width: 17px; height: 17px; color: var(--brand); pointer-events: none; }
.select-wrap select {
  width: 100%;
  min-height: 40px;
  display: block;
  padding: 0 25px 0 34px;
  border: 1px solid #dbe5e7;
  border-radius: 9px;
  color: #243b46;
  background: #f6f9f9;
  font-size: 13px;
  font-weight: 680;
  cursor: pointer;
}
.arrival-cards { display: grid; gap: 8px; }
.arrival-card { border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.arrival-recommended { border-color: #b8dac7; background: #fbfefc; }
.arrival-line { display: flex; align-items: center; justify-content: space-between; gap: 9px; }
.arrival-vehicle { display: flex; align-items: center; gap: 9px; }
.vehicle-symbol {
  width: 33px;
  height: 33px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #38645f;
  background: #edf4f2;
  flex: 0 0 33px;
}
.vehicle-symbol svg { width: 18px; height: 18px; }
.arrival-vehicle h3 { font-size: 14px; font-weight: 760; line-height: 1.2; }
.arrival-vehicle p { margin-top: 3px; color: var(--muted); font-size: 11px; }
.eta { color: #536874; font-size: 12px; font-weight: 690; white-space: nowrap; }
.eta strong { margin-right: 1px; color: var(--ink); font-size: 27px; letter-spacing: -0.05em; line-height: 1; font-variant-numeric: tabular-nums; }
.arrival-snapshot { display: flex; align-items: center; gap: 7px; margin-top: 9px; flex-wrap: wrap; }
.status-badge { display: inline-flex; align-items: center; gap: 6px; min-width: 0; padding: 5px 8px; border-radius: 6px; font-size: 11px; font-weight: 750; line-height: 1.1; white-space: nowrap; }
.status-badge i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .85; }
.tone-green { --tone: var(--green); --tone-bg: var(--green-bg); }
.tone-amber { --tone: var(--amber); --tone-bg: var(--amber-bg); }
.tone-red { --tone: var(--red); --tone-bg: var(--red-bg); }
.tone-gray { --tone: var(--gray); --tone-bg: var(--gray-bg); }
.status-badge[class*="tone-"] { color: var(--tone); background: var(--tone-bg); }
.quality-note { color: var(--muted); font-size: 11px; }
.recommendation {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-radius: 11px;
  background: #e9f6ed;
  color: #155745;
}
.recommendation-icon {
  display: grid;
  place-items: center;
  width: 29px;
  height: 29px;
  flex: 0 0 29px;
  border-radius: 50%;
  background: #cfeadb;
}
.recommendation-icon svg { width: 15px; height: 15px; transform: rotate(-34deg); }
.recommendation h3, .weather-warning h3 { font-size: 13px; line-height: 1.28; letter-spacing: -0.011em; }
.recommendation p { margin-top: 3px; color: #346857; font-size: 11px; line-height: 1.35; }
.weather-warning {
  display: flex;
  align-items: flex-start;
  margin-top: 12px;
  padding: 14px 16px;
  gap: 10px;
  background: #eef6ff;
  border-color: #d7e8fb;
  color: #26476c;
}
.weather-icon { width: 29px; height: 29px; display: grid; place-items: center; flex: 0 0 29px; border-radius: 8px; color: #225486; background: #dcecff; }
.weather-icon svg { width: 18px; height: 18px; }
.weather-warning p { margin: 3px 0 6px; font-size: 12px; line-height: 1.45; }
.text-button { display: inline-flex; align-items: center; gap: 5px; min-height: 25px; padding: 2px 0; border: 0; background: none; color: var(--brand-strong); font-size: 12px; font-weight: 750; text-align: left; }
.text-button:hover { text-decoration: underline; }
.text-button svg { width: 14px; height: 14px; }
.warm-button { color: #164b81; }
.empty { color: var(--muted); font-size: 13px; line-height: 1.45; }
.skeleton { min-height: 81px; border-radius: 11px; background: linear-gradient(110deg, #f0f4f5 20%, #f7f9fa 45%, #f0f4f5 72%); }

.dispatch-fields { display: grid; grid-template-columns: 1.12fr 1fr; gap: 9px; }
.forecast { padding-top: 2px; }
.forecast-summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.forecast-summary > div > span { color: var(--muted); font-size: 12px; font-weight: 650; }
.forecast-summary p { margin-top: 2px; color: var(--muted); font-size: 12px; font-weight: 650; }
.forecast-summary strong { margin-right: 3px; font-size: 37px; line-height: 1; letter-spacing: -.058em; color: var(--ink); }
.progress { height: 6px; margin-top: 9px; border-radius: 6px; background: var(--gray-bg); overflow: hidden; }
.progress > span { height: 100%; display: block; border-radius: inherit; }
.fill-green { background: #43a578; }
.fill-amber { background: #c08325; }
.fill-red { background: #cb5861; }
.fill-gray { background: #899aa6; }
.capacity-note { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 3px 9px; margin-top: 7px; color: var(--muted); font-size: 11px; }
.calculation { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 15px; }
.calculation-part { position: relative; padding: 8px 4px; text-align: center; background: #eef3f5; border-radius: 8px; color: #415867; }
.calculation-part:last-child { background: var(--brand-pale); color: var(--brand-strong); }
.calculation-part > span:not(.operator), .calculation-part strong { display: block; }
.calculation-part > span:not(.operator) { font-size: 10px; font-weight: 630; }
.calculation-part strong { margin-top: 2px; font-size: 18px; font-weight: 760; }
.operator { position: absolute; top: 50%; left: -8px; z-index: 1; transform: translateY(-50%); width: 11px; background: #fff; color: #415867; border: 1px solid var(--line); border-radius: 3px; font-size: 9px; }
.forecast-details { display: grid; gap: 7px; margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--line); }
.forecast-details > div { display: flex; align-items: start; justify-content: space-between; gap: 6px; font-size: 11px; line-height: 1.5; }
.forecast-details dt { color: var(--muted); }
.forecast-details dd { color: #253b43; font-weight: 680; text-align: end; }
.timeline-panel, .dispatch-bottom-grid { margin-top: 20px; }
.timeline { display: grid; grid-auto-columns: minmax(70px, 1fr); grid-auto-flow: column; overflow: auto; padding: 0 20px 15px; }
.timeline-stop { display: grid; place-content: center stretch; gap: 7px; min-height: 68px; padding: 7px 0; text-align: center; background: transparent; border: 0; color: #4a5c64; font-size: 11px; font-weight: 650; }
.timeline-stop:hover, .timeline-stop[aria-pressed="true"] { background: #f2f8f5; color: var(--brand-strong); border-radius: 7px; }
.timeline-stop > span:last-child { padding: 0 6px; }
.timeline-value { color: var(--tone); font-size: 12px; font-weight: 770; }
.timeline-track { position: relative; display: block; height: 6px; background: var(--tone-bg); }
.timeline-track::before { position: absolute; content: ""; inset: 0 auto 0 calc(50% - 3px); width: 6px; border-radius: 50%; background: var(--tone); }
.dispatch-bottom-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 12px; text-align: left; line-height: 1.5; }
thead { background: #f3f6f6; color: #4b6069; font-size: 10px; }
th, td { padding: 8px 11px; border-bottom: 1px solid var(--line); }
thead th:nth-child(2), thead th:nth-child(3) { white-space: nowrap; }
tbody th { font-weight: 690; }
tbody td:last-child { color: var(--muted); }
tr > :first-child { padding-left: 20px; }
tr > :last-child { padding-right: 20px; }
.table-footnote { padding: 9px 20px 13px; color: var(--muted); font-size: 10px; }
.section-empty { padding: 0 20px 16px; }
.incident-list { display: grid; gap: 8px; padding: 0 15px 15px; }
.incident { padding: 11px 11px 9px; border: 1px solid var(--line); border-radius: 10px; }
.incident-label, .incident-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: space-between; }
.incident-label > span:last-child { color: var(--muted); font-size: 11px; }
.incident h3 { font-size: 14px; line-height: 1.35; margin-top: 7px; }
.incident p { font-size: 12px; line-height: 1.45; color: var(--muted); margin: 3px 0 7px; }
.button { min-height: 29px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 7px; font-size: 11px; font-weight: 730; white-space: nowrap; }
.button-outline { background: #fff; color: var(--brand-strong); border-color: #bcd7cd; }
.button-outline:hover { background: var(--brand-pale); }
.ticket { display: inline-flex; align-items: center; gap: 4px; color: var(--green); font-size: 11px; font-weight: 730; }
.ticket svg { width: 14px; height: 14px; }
.workspace-footer { display: flex; justify-content: space-between; gap: 8px 13px; flex-wrap: wrap; padding: 13px 1px 0; color: var(--muted); font-size: 11px; }
.workspace-footer > span { display: inline-flex; align-items: center; gap: 5px; }
.workspace-footer svg { height: 14px; width: 14px; }
.embedded-view .topbar, .embedded-view .workspace-footer { display: none; }
.embedded-view .workspace { padding-top: 20px; }
.mobile-passenger { display: none; }
.dispatch-advice { display: grid; gap: 5px; margin-top: 14px; padding: 11px; border-radius: 9px; background: #eff5f3; font-size: 12px; line-height: 1.45; }
.dispatch-advice strong { color: var(--brand-strong); }
.dispatch-advice p { color: var(--muted); }

@media (max-width: 1000px) {
  .topbar-inner, .workspace { width: calc(100% - 42px); }
  .workspace-grid { grid-template-columns: minmax(0, 1fr) minmax(300px, 325px); gap: 13px; }
  .dispatcher-grid { grid-template-columns: minmax(0, 1fr) minmax(310px, 350px); }
  .map-stage { min-height: 415px; }
  .dispatch-bottom-grid { gap: 13px; }
}
@media (max-width: 760px) {
  .topbar-inner, .workspace { width: calc(100% - 32px); }
  .topbar-inner { min-height: 62px; gap: 10px; }
  .brand { gap: 7px; }
  .brand-mark { width: 34px; border-radius: 10px; }
  .brand-mark svg { width: 23px; height: 23px; }
  .brand strong { font-size: 14px; }
  .brand small { font-size: 9px; }
  .city { display: none; }
  .account-settings summary { min-height: 38px; padding-inline: 8px; }
  .mode-button { padding: 0 8px; font-size: 11px; min-height: 34px; gap: 5px; }
  .mode-button svg { width: 14px; height: 14px; }
  .workspace { padding: 24px 0 18px; }
  .page-heading { margin-bottom: 16px; align-items: start; }
  .page-heading h1 { font-size: clamp(28px, 6.3vw, 39px); }
  .page-heading p { margin-top: 6px; font-size: 13px; }
  .workspace-grid, .dispatcher-grid, .dispatch-bottom-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .panel { border-radius: 14px; }
  .panel-header { padding: 12px 13px; }
  .section-heading h2 { font-size: 16px; }
  .section-icon { width: 33px; height: 33px; flex-basis: 33px; border-radius: 9px; }
  .section-icon svg { width: 17px; height: 17px; }
  .map-stage { height: min(52vh, 420px); min-height: 300px; }
  .map-footer { min-height: 36px; padding: 7px 11px; gap: 9px; }
  .map-footer > span { gap: 4px; font-size: 10px; }
  .details-content { padding: 0 12px 12px; }
  .weather-warning { margin-top: 10px; }
  .timeline-panel, .dispatch-bottom-grid { margin-top: 12px; }
  .timeline { padding: 0 8px 9px; }
}
@media (max-width: 500px) {
  .topbar-inner { grid-template-columns: 1fr auto; gap: 7px; width: calc(100% - 24px); padding-block: 7px; }
  .header-account { grid-area: 1 / 2; }
  .mode-nav { grid-row: 2; grid-column: 1 / -1; padding: 3px; gap: 1px; }
  .mode-button { flex: 1; padding-inline: 7px; }
  .workspace { width: calc(100% - 24px); padding-top: 20px; }
  .page-heading { display: grid; gap: 10px; }
  .demo-tools { justify-self: start; padding: 3px 4px; }
  .icon-button { width: 30px; height: 30px; }
  .scenario-field { max-width: 185px; }
  .map-stage { height: 39vh; min-height: 250px; }
  .map-footer { gap: 7px; }
  .map-footer > span { font-size: 9px; }
}
@media (max-width: 350px) {
  .mode-button svg { display: none; }
  .brand strong { font-size: 13px; }
}

@media (max-width: 760px) {
  .passenger-view {
    --mobile-safe: env(safe-area-inset-bottom, 0px);
    --mobile-top: calc(13px + env(safe-area-inset-top, 0px));
    --mobile-sheet-height: calc(81px + var(--mobile-safe));
    --mobile-violet: #8f60f4;
    --mobile-neutral: #eaeaea;
    overflow: hidden;
  }
  .passenger-view.mobile-sheet-expanded { --mobile-sheet-height: calc(min(43dvh, 390px) + var(--mobile-safe)); }
  .passenger-view .workspace { width: 100%; padding: 0; }
  .passenger-view .page-heading,
  .passenger-view .map-header,
  .passenger-view .details-panel,
  .passenger-view .workspace-footer { display: none; }
  .passenger-view .map-panel { border: 0; border-radius: 0; overflow: visible; }
  .passenger-view .map-stage { height: 100vh; height: 100dvh; min-height: 0; border: 0; }
  .passenger-view .map-footer {
    position: fixed; z-index: 2; bottom: calc(var(--mobile-sheet-height) + 4px); left: 4px;
    min-height: 0; padding: 2px 5px; border-radius: 4px; background: #ffffffe5;
  }
  .passenger-view .map-footer > span:not(.map-source) { display: none; }
  .passenger-view .map-footer .map-source { margin: 0; color: #4c4c4c; font-size: 9px; }
  .passenger-view .topbar { position: fixed; top: var(--mobile-top); right: 13px; border: 0; background: none; }
  .passenger-view:has(.mobile-map-alert:not([hidden])) .topbar { top: calc(var(--mobile-top) + 87px); }
  .passenger-view .topbar-inner { display: flex; align-items: center; gap: 7px; min-height: 0; width: auto; padding: 0; }
  .passenger-view .brand, .passenger-view .mode-button[data-mode="passenger"] { display: none; }
  .passenger-view .mode-nav { background: none; padding: 0; border: 0; }
  .passenger-view .mode-button[data-mode="dispatcher"], .passenger-view .account-settings summary {
    display: grid; place-items: center; width: 42px; min-height: 42px; padding: 0;
    color: #222; background: #fffffff2; border: 0; border-radius: 13px;
    box-shadow: 0 2px 9px #0002;
  }
  .passenger-view .mode-button[data-mode="dispatcher"] span,
  .passenger-view .account-settings summary .account-chevron { display: none; }
  .passenger-view .account-settings summary { display: flex; justify-content: center; gap: 0; font-size: 0; }
  .passenger-view .mode-button[data-mode="dispatcher"] svg,
  .passenger-view .account-settings summary svg { display: block; width: 20px; height: 20px; }
  .passenger-view .load-error {
    position: fixed; z-index: 7; top: calc(var(--mobile-top) + 50px); right: 12px; left: 12px;
    justify-content: space-between; margin: 0;
  }
  .passenger-view .mobile-passenger { display: contents; }
  .mobile-map-alert {
    position: fixed; z-index: 6; top: var(--mobile-top); left: 13px; right: 13px; max-width: 440px;
    display: grid; grid-template-columns: 40px 1fr; align-items: center; gap: 11px;
    min-height: 60px; padding: 10px 13px; border-radius: 28px;
    background: #fffffff0; color: #202020; box-shadow: 0 2px 12px #0002;
    backdrop-filter: blur(12px); font-size: 14px; line-height: 1.28; font-weight: 570;
  }
  .mobile-warning-icon {
    width: 40px; height: 40px; background: #e33e3e;
    mask: url('/assets/warning.png') center / contain no-repeat;
  }
  .mobile-map-alert button { display: block; padding: 3px 0; border: 0; background: none; color: #5f31b7; font-size: 13px; text-align: start; }
  .mobile-sheet {
    position: fixed; z-index: 5; inset: auto 0 0;
    display: flex; flex-direction: column;
    height: var(--mobile-sheet-height); padding: 0 14px calc(10px + var(--mobile-safe));
    background: #ffffffdf; box-shadow: 0 -2px 16px #0002; backdrop-filter: blur(13px);
    border-radius: 22px 22px 0 0;
    color: #262626;
  }
  .mobile-sheet-handle {
    display: grid; place-items: center; align-self: stretch; flex: 0 0 25px;
    background: transparent; border: 0; border-radius: 14px; touch-action: none;
  }
  .mobile-sheet-handle span { width: 40px; height: 5px; border-radius: 8px; background: var(--mobile-neutral); }
  .mobile-sheet-handle:focus-visible { outline-offset: -3px; }
  .mobile-sheet-bar { display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 8px; }
  .mobile-search { display: flex; align-items: center; gap: 9px; min-width: 0; height: 40px; padding-inline: 13px 8px; background: var(--mobile-neutral); border-radius: 12px; }
  .mobile-search img { flex: none; }
  .mobile-search input { width: 100%; min-width: 0; padding: 3px 0; border: 0; outline: none; background: transparent; color: inherit; font: inherit; font-size: 16px; }
  .mobile-search input::placeholder { color: #666; font-size: 13px; }
  .mobile-search:focus-within { outline: 2px solid var(--mobile-violet); }
  .mobile-search input:focus-visible { outline: none; }
  .mobile-favorites, .mobile-chip { display: inline-flex; align-items: center; justify-content: center; border: 0; background: var(--mobile-neutral); color: #525252; }
  .mobile-favorites { width: 40px; height: 40px; border-radius: 12px; padding: 0; }
  .mobile-favorites > span { width: 24px; height: 24px; background: #6e6e6e; mask: url('/assets/favorite.png') center / contain no-repeat; }
  .mobile-favorites[aria-pressed="true"], .mobile-chip.is-selected { color: #fff; background: var(--mobile-violet); }
  .mobile-favorites[aria-pressed="true"] > span { background: #fff; }
  .mobile-sheet-body { flex: 1; overflow: auto; min-height: 0; overscroll-behavior: contain; margin-top: 13px; padding-bottom: 4px; scrollbar-width: thin; }
  .mobile-sheet-switches { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 6px; }
  .mobile-chip { gap: 4px; min-height: 33px; padding: 4px 9px; border-radius: 14px; font-size: 13px; white-space: nowrap; }
  .mobile-chip.mobile-save[aria-pressed="true"] { color: #6035b1; background: #eee5ff; }
  .mobile-route-name { margin-top: 10px; text-align: center; font-size: 14px; line-height: 1.35; font-weight: 680; }
  .mobile-route-name small { display: block; margin-top: 1px; color: #555; font-size: 12px; font-weight: 500; }
  .mobile-arrivals { display: grid; gap: 3px; margin-top: 12px; }
  .mobile-arrival {
    display: grid; grid-template-columns: max-content minmax(0, 1fr) max-content; align-items: center; gap: 7px;
    width: 100%; padding: 4px 2px; border-radius: 10px; border: 0; background: transparent;
    color: #464646; font: inherit; font-size: 13px; text-align: start;
  }
  .mobile-arrival[aria-pressed="true"] { background: #f0e7ff; }
  .mobile-tone-green { --mobile-tone: #16a34a; }
  .mobile-tone-amber { --mobile-tone: #f0b90d; }
  .mobile-tone-red { --mobile-tone: #e33e3e; }
  .mobile-tone-gray { --mobile-tone: #737373; }
  .mobile-bus-pill {
    display: inline-flex; align-items: center; justify-content: center; gap: 3px; min-width: 56px; height: 32px;
    padding-inline: 6px; color: #fff; background: var(--mobile-tone); border-radius: 11px; font-size: 15px;
  }
  .mobile-tone-amber .mobile-bus-pill { color: #262626; }
  .mobile-bus-icon { display: inline-block; flex: none; width: 18px; height: 18px; background: currentColor; mask: url('/assets/bus.png') center / contain no-repeat; }
  .mobile-arrival-copy { min-width: 0; }
  .mobile-arrival-copy small { display: block; margin-top: 2px; color: #5b5b5b; line-height: 1.25; font-size: 11px; }
  .mobile-arrival-eta { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
  .mobile-arrival-eta i { display: inline-block; width: 6px; height: 6px; background: var(--mobile-tone); border-radius: 50%; }
  .mobile-empty { color: #595959; padding: 14px 1px; font-size: 13px; }
  .mobile-search-results { display: grid; gap: 2px; margin-top: 7px; }
  .mobile-search-results button {
    display: flex; align-items: center; gap: 10px; padding: 6px 4px; min-height: 39px;
    border: 0; border-radius: 8px; background: transparent; color: #303030; text-align: start; font-size: 13px;
  }
  .mobile-search-results button small { display: block; color: #555; font-size: 11px; }
  .mobile-search-results button svg { flex: none; width: 19px; height: 19px; stroke: currentColor; stroke-width: 1.6; }
  .mobile-conversation { display: grid; gap: 12px; margin-top: 9px; font-size: 14px; line-height: 1.26; }
  .mobile-sparkle { display: inline-block; width: 34px; height: 34px; background: var(--mobile-violet); mask: url('/assets/sparkle.png') center / contain no-repeat; }
  .mobile-search-results .mobile-sparkle { width: 19px; height: 19px; }
  .mobile-question { justify-self: end; max-width: 100%; padding: 7px 10px; border-radius: 12px; background: var(--mobile-violet); color: #fff; overflow-wrap: anywhere; }
  .mobile-reply { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 7px; align-items: start; }
  .mobile-reply p { padding: 8px 9px; border-radius: 12px; background: var(--mobile-neutral); overflow-wrap: anywhere; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; }
}
