/* KTÜ Farabi Yön — hastane yönlendirme tabelası dili:
   üniversite hastanesi lacivert/mavi kimliği, blok renkleri hat renkleri gibi,
   kat göstergeleri asansör panelleri gibi,
   sıkışık (condensed) tabela tipografisi + sade gövde metni. */

:root {
  --paper: #ECF0F3;
  --panel: #FFFFFF;
  --panel-2: #F6F8FA;
  --ink: #0E2233;
  --ink-soft: #375063;
  --muted: #627B8D;
  --line: #CBD7DF;
  --line-soft: #E2E9EE;
  --focus: #0A5C8F;
  --brand: #00426A;
  --brand-soft: #0F72AE;

  --block-a: #0A5C8F;
  --block-b: #C94E1B;
  --block-c: #0C7D64;
  --block-p: #B81F3A;
  --block-t: #5F43A8;

  --route: #0E2233;
  --here: #0E2233;
  --warn: #8A5300;

  --sign: 'Barlow Condensed', 'Barlow', system-ui, sans-serif;
  --body: 'Barlow', system-ui, -apple-system, sans-serif;

  --r: 3px;
  --gap: 14px;
  --maxw: 600px;
  --topbar-h: 58px;
  --tabbar-h: 60px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0A141C;
    --panel: #11212D;
    --panel-2: #162835;
    --ink: #E7EFF5;
    --ink-soft: #B9CBD8;
    --muted: #8BA3B3;
    --line: #263F4F;
    --line-soft: #1C303E;
    --block-a: #4FA7DE;
    --block-b: #E8803F;
    --block-c: #2EAC8C;
    --block-p: #E85A74;
    --block-t: #9578E0;
    --route: #F2F7FA;
    --here: #F2F7FA;
    --warn: #E0A64C;
    --brand: #002D49;
    --brand-soft: #3390CE;
  }
}
:root[data-theme="dark"] {
  --paper: #0A141C;
  --panel: #11212D;
  --panel-2: #162835;
  --ink: #E7EFF5;
  --ink-soft: #B9CBD8;
  --muted: #8BA3B3;
  --line: #263F4F;
  --line-soft: #1C303E;
  --block-a: #4FA7DE;
  --block-b: #E8803F;
  --block-c: #2EAC8C;
  --block-p: #E85A74;
  --block-t: #9578E0;
  --route: #F2F7FA;
  --here: #F2F7FA;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.5 var(--body);
  -webkit-text-size-adjust: 100%;
  padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
}

h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.01em; }

a { color: inherit; }

.skip {
  position: absolute; left: -999px; top: 0; z-index: 50;
  background: var(--ink); color: var(--panel); padding: 10px 14px;
}
.skip:focus { left: 8px; top: 8px; }

:where(a, button, input, [tabindex]):focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.campus-note {
  margin: -4px 0 10px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
}
.campus-note__demo { display: block; font-size: 12px; opacity: .85; }

/* Tarayici varsayilan stilindeki [hidden] { display: none } kurali, yazar stilinde
   verilen herhangi bir display bildirimine yenilir. .sheet (grid) ve .locbar (flex)
   gibi paneller bu yuzden hidden = true iken bile ekranda kalirdi. */
[hidden] { display: none !important; }

/* ---------- Üst çubuk ---------- */

.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  height: var(--topbar-h);
  padding: 0 14px;
  background: var(--brand);
  color: #fff;
}

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; }

.brand-logo {
  height: 34px; width: auto; flex: none;
  padding-right: 11px;
  border-right: 1px solid rgba(255, 255, 255, .28);
}

.brand-floor {
  font: 700 15px/1 var(--sign);
  letter-spacing: 0.08em;
  border: 2px solid rgba(255, 255, 255, .62);
  padding: 7px 7px 5px;
  border-radius: 2px;
  white-space: nowrap;
}

.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-text strong { font: 600 15px/1.15 var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-text span { font-size: 12px; color: rgba(255, 255, 255, .72); }

.btn {
  font: 600 15px/1 var(--body);
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 15px;
  border: 1px solid var(--ink);
  background: var(--ink); color: #fff;
  border-radius: var(--r);
  cursor: pointer;
}
.btn .icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.btn--scan {
  margin-left: auto;
  background: #fff; color: var(--ink); border-color: #fff;
  border-radius: 999px; padding: 10px 16px;
  white-space: nowrap;
}
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--block { width: 100%; justify-content: center; }
.btn--quiet { background: var(--panel); color: var(--ink); border-color: var(--line); }

/* ---------- Konum şeridi ---------- */

.locbar {
  position: sticky; top: var(--topbar-h); z-index: 19;
  display: flex; align-items: center; gap: 10px;
  padding: 9px 14px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.locbar strong { font-weight: 600; }
.locbar .locbar-change { margin-left: auto; font: 600 14px/1 var(--body); color: var(--focus); background: none; border: 0; padding: 4px; cursor: pointer; }

/* ---------- Yerleşim ---------- */

main { max-width: var(--maxw); margin: 0 auto; padding: var(--gap) 14px 28px; }
main:focus { outline: none; }

.panel {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 16px 16px 16px 20px;
  margin-bottom: var(--gap);
}
.panel::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px;
  background: var(--accent, var(--ink));
  border-radius: var(--r) 0 0 var(--r);
}
.panel--plain { padding-left: 16px; }
.panel--plain::before { display: none; }

.section-head {
  display: flex; align-items: baseline; gap: 10px;
  margin: 22px 0 10px;
}
.section-head h2 { font: 600 21px/1.1 var(--sign); text-transform: none; }
.section-head span { font-size: 13px; color: var(--muted); margin-left: auto; }

/* ---------- Buradasınız panosu (ana ekran kahramanı) ---------- */

.sign {
  position: relative; overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 6px solid var(--accent, var(--ink));
  border-radius: var(--r);
  padding: 15px 16px 16px;
  margin-bottom: var(--gap);
}
.sign-kicker {
  font: 700 12px/1 var(--body);
  letter-spacing: 0.17em;
  color: var(--muted);
  text-transform: uppercase;
}
.sign-main { display: flex; align-items: flex-start; gap: 14px; margin-top: 9px; }
.sign-title { font: 600 27px/1.05 var(--sign); flex: 1; min-width: 0; }
.sign-sub { margin-top: 6px; color: var(--ink-soft); font-size: 14px; }
.sign-none { color: var(--muted); font-size: 15px; margin-top: 8px; }

.floor-badge {
  flex: 0 0 auto;
  display: grid; place-items: center;
  width: 46px; height: 46px;
  background: var(--ink); color: var(--panel);
  font: 700 25px/1 var(--sign);
  border-radius: 2px;
}
.floor-badge small { display: block; font: 600 9px/1 var(--body); letter-spacing: .1em; opacity: .8; margin-top: 3px; }

/* ---------- Arama ---------- */

.search { margin-bottom: var(--gap); }
.search-row { display: flex; gap: 8px; }
.search input {
  flex: 1; min-width: 0;
  font: 400 17px/1 var(--body);
  padding: 14px 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  color: var(--ink);
}
.search input::placeholder { color: var(--muted); }

.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.chip {
  font: 500 14px/1 var(--body);
  padding: 9px 12px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
}
.chip--on { background: var(--ink); color: var(--panel); border-color: var(--ink); }

/* ---------- Sonuç listesi ---------- */

.results { list-style: none; margin: 0; padding: 0; }
.results li { border-bottom: 1px solid var(--line-soft); }
.results li:last-child { border-bottom: 0; }

.result {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 12px;
  width: 100%;
  text-align: left;
  padding: 13px 2px;
  background: none; border: 0; color: inherit;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
}
.result-title { font: 600 17px/1.2 var(--body); }
.result-sub { grid-column: 1; font-size: 13.5px; color: var(--muted); }
.result-meta { grid-column: 1; font-size: 13px; color: var(--ink-soft); }
.result-side { grid-row: 1 / span 2; align-self: center; text-align: right; }

.tag {
  display: inline-flex; align-items: center; gap: 6px;
  font: 600 12px/1 var(--body); letter-spacing: .02em;
  color: var(--ink-soft);
}
.tag::before { content: ""; width: 9px; height: 9px; border-radius: 2px; background: var(--accent, var(--muted)); }

.locator { font: 600 17px/1 var(--sign); color: var(--ink); white-space: nowrap; }
.locator small { font: 600 11px/1 var(--body); color: var(--muted); display: block; margin-top: 4px; }

.empty { color: var(--muted); padding: 18px 2px; font-size: 15px; }

/* ---------- Hedef kartı ---------- */

.dest-head { display: flex; gap: 14px; align-items: flex-start; }
.dest-head h1 { font: 600 25px/1.1 var(--sign); flex: 1; }
.facts { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 7px; }
.facts li { display: flex; gap: 10px; font-size: 14.5px; }
.facts b { font-weight: 600; min-width: 92px; color: var(--muted); }
.actions { display: grid; gap: 8px; margin-top: 16px; }

.notice {
  margin-top: 13px; padding: 11px 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--warn);
  background: var(--panel-2);
  font-size: 14px; color: var(--ink-soft);
  border-radius: 2px;
}

/* ---------- Rota ---------- */

.route-summary {
  display: flex; gap: 16px; flex-wrap: wrap;
  padding: 13px 16px;
  background: var(--ink); color: #fff;
  border-radius: var(--r);
  margin-bottom: 10px;
}
.route-summary div { display: flex; flex-direction: column; }
.route-summary b { font: 700 24px/1 var(--sign); }
.route-summary span { font-size: 12px; color: rgba(255, 255, 255, .72); }

.floor-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 10px; }
.floor-tab {
  flex: 0 0 auto;
  font: 600 14px/1 var(--sign); letter-spacing: .04em;
  padding: 9px 12px;
  background: var(--panel); color: var(--ink);
  border: 1px solid var(--line); border-top: 3px solid var(--accent, var(--line));
  border-radius: 2px; cursor: pointer;
}
.floor-tab[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); border-top-color: var(--accent, #fff); }
.floor-tab small { display: block; font: 500 11px/1 var(--body); opacity: .75; margin-top: 3px; }

.plan-wrap {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  touch-action: none;
}
.plan-stage { height: min(58vh, 460px); overflow: hidden; cursor: grab; }
.plan-stage.dragging { cursor: grabbing; }
.plan-stage > svg { width: 100%; height: 100%; display: block; }
.plan-tools { position: absolute; right: 8px; bottom: 8px; display: grid; gap: 6px; }
.plan-tools button {
  width: 38px; height: 38px;
  font: 600 19px/1 var(--body);
  background: var(--panel); color: var(--ink);
  border: 1px solid var(--line); border-radius: 2px; cursor: pointer;
}
.plan-caption { padding: 9px 12px; border-top: 1px solid var(--line-soft); font-size: 13px; color: var(--muted); display: flex; gap: 10px; align-items: center; }

/* Kroki içi */
.plan-shell { fill: var(--panel-2); stroke: var(--line); stroke-width: .5; }
.corridor { fill: var(--panel); stroke: var(--line-soft); stroke-width: .25; }
.room { stroke: var(--line); stroke-width: .22; }
.room--target { stroke: var(--route); stroke-width: .9; }
.room-no { font: 600 1.7px var(--sign); fill: var(--ink-soft); text-anchor: middle; opacity: .85; }
.unit-label { font: 600 2.3px var(--body); fill: var(--ink); text-anchor: middle; opacity: .62; }
.core { fill: var(--panel-2); stroke: var(--ink-soft); stroke-width: .35; }
.core--elevator { fill: color-mix(in srgb, var(--focus) 16%, var(--panel)); }
.core--stairs { fill: color-mix(in srgb, var(--ink) 9%, var(--panel)); }
.core-glyph { font: 600 3.4px var(--body); fill: var(--ink); text-anchor: middle; dominant-baseline: middle; }
.core-label { font: 600 1.9px var(--sign); fill: var(--ink-soft); text-anchor: middle; }

.route-casing { fill: none; stroke: var(--panel); stroke-width: 2.6; stroke-linejoin: round; stroke-linecap: round; opacity: .9; }
.route-core {
  fill: none; stroke: var(--route); stroke-width: 1.5;
  stroke-linejoin: round; stroke-linecap: round;
  stroke-dasharray: 3.4 2.2;
  animation: route-draw 1.1s ease-out 1 both;
}
@keyframes route-draw { from { stroke-dashoffset: 120; } to { stroke-dashoffset: 0; } }

.mark-here { fill: var(--here); }
.mark-here-pulse { fill: var(--here); opacity: .22; animation: pulse 2.4s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
@keyframes pulse { 0%, 100% { opacity: .1; transform: scale(.8); } 50% { opacity: .3; transform: scale(1.35); } }
.mark-dest { fill: var(--accent, var(--block-a)); }
.mark-dest-halo { fill: var(--accent, var(--block-a)); opacity: .22; }
.mark-transition { fill: var(--panel); stroke: var(--route); stroke-width: .6; }
.mark-active { fill: none; stroke: var(--focus); stroke-width: .8; }
.mark-text {
  font: 600 2.6px var(--body); fill: var(--ink); text-anchor: middle;
  paint-order: stroke; stroke: var(--panel); stroke-width: .9; stroke-linejoin: round;
}
.mark-text--dest { font-weight: 700; }

/* Adım merdiveni */
.steps { list-style: none; margin: 14px 0 0; padding: 0; }
.steps li { position: relative; padding-left: 46px; padding-bottom: 14px; }
.steps li::before {
  content: ""; position: absolute; left: 16px; top: 32px; bottom: 0; width: 2px;
  background: var(--line);
}
.steps li:last-child::before { display: none; }
.step {
  display: grid; grid-template-columns: 1fr auto; gap: 3px 10px;
  width: 100%; text-align: left; font: inherit;
  background: none; border: 0; color: inherit; padding: 4px 0; cursor: pointer;
}
.step-icon {
  position: absolute; left: 0; top: 0;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 1.5px solid var(--ink); border-radius: 2px;
  background: var(--panel);
}
.step-icon svg { width: 20px; height: 20px; fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: square; stroke-linejoin: miter; }
.step--vertical .step-icon { background: var(--ink); }
.step--vertical .step-icon svg { stroke: var(--panel); }
.step--arrive .step-icon { background: var(--accent, var(--block-a)); border-color: var(--accent, var(--block-a)); }
.step--arrive .step-icon svg { stroke: #fff; }
.step-text { font: 500 16.5px/1.3 var(--body); }
.step-note { grid-column: 1; font-size: 13.5px; color: var(--muted); }
.step-dist { grid-row: 1; font: 600 18px/1 var(--sign); color: var(--ink-soft); white-space: nowrap; }
.step-dist small { font: 500 11px/1 var(--body); }
.step[aria-current="true"] .step-text { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }

.floor-break {
  display: flex; align-items: center; gap: 10px;
  margin: 2px 0 14px 46px;
  padding: 8px 12px;
  background: var(--panel-2); border: 1px solid var(--line-soft); border-radius: 2px;
  font-size: 13.5px; color: var(--ink-soft);
}
.floor-break b { font: 700 17px/1 var(--sign); }

/* ---------- Rehber / listeler ---------- */

.grid-blocks { display: grid; gap: 10px; }
.block-card {
  position: relative;
  display: grid; grid-template-columns: 1fr auto; align-items: center;
  padding: 14px 14px 14px 18px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
  text-decoration: none;
}
.block-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--accent); }
.block-card h3 { font: 600 20px/1.05 var(--sign); }
.block-card p { margin: 3px 0 0; font-size: 13.5px; color: var(--muted); }
.block-card .floors { display: flex; gap: 5px; }
.block-card .floors span {
  width: 27px; height: 27px; display: grid; place-items: center;
  font: 600 14px/1 var(--sign);
  border: 1px solid var(--line); border-radius: 2px; color: var(--ink-soft);
}

.legend { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 10px; font-size: 13px; color: var(--ink-soft); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 13px; height: 13px; border: 1px solid var(--line); border-radius: 2px; display: inline-block; }

/* ---------- QR noktaları ---------- */

.qr-list { display: grid; gap: 10px; }
.qr-item {
  display: grid; grid-template-columns: 76px 1fr; gap: 12px; align-items: center;
  padding: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
}
.qr-item svg { width: 76px; height: 76px; display: block; border-radius: 2px; }
.qr-item h3 { font: 600 17px/1.15 var(--body); }
.qr-item p { margin: 3px 0 0; font-size: 13px; color: var(--muted); }
.qr-code { font: 600 15px/1 var(--sign); letter-spacing: .06em; color: var(--ink-soft); margin-top: 5px; display: block; }

/* ---------- Tarayıcı sayfası (sheet) ---------- */

.sheet { position: fixed; inset: 0; z-index: 40; background: rgba(8, 18, 26, .72); display: grid; place-items: end stretch; }
.sheet-panel {
  background: var(--panel); border-radius: var(--r) var(--r) 0 0;
  padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
  max-width: var(--maxw); width: 100%; margin: 0 auto;
  max-height: 94vh; overflow: auto;
}

/* Genis ekranda kamera solda, hazir QR kodlari sagda */
@media (min-width: 780px) {
  .sheet { place-items: center; }
  .sheet-panel {
    max-width: 920px; border-radius: var(--r);
    display: grid; align-content: start;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
    grid-template-areas: "head head" "stage demo" "manual demo";
    column-gap: 18px;
  }
  .sheet-head { grid-area: head; }
  .scanner-stage { grid-area: stage; }
  .qr-demo { grid-area: demo; margin-top: 0; }
  .manual { grid-area: manual; }
}
.sheet-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.sheet-head h2 { font: 600 20px/1.1 var(--sign); flex: 1; }
.scanner-stage { position: relative; background: #08121A; border-radius: 2px; overflow: hidden; aspect-ratio: 4 / 3; }
.scanner-stage video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scanner-frame {
  position: absolute; inset: 18%;
  border: 2px solid rgba(255, 255, 255, .85);
  border-radius: 2px;
  box-shadow: 0 0 0 100vmax rgba(8, 18, 26, .35);
}
.scanner-hint { position: absolute; left: 0; right: 0; bottom: 8px; margin: 0; text-align: center; color: #fff; font-size: 13.5px; }
/* Demo: hazir QR kodlari (kamera yoksa tiklayarak konum ayarlama) */
.qr-demo { margin-top: 14px; }
.qr-demo h3 { font: 600 17px/1.2 var(--sign); margin: 0 0 2px; }
.qr-demo-note { margin: 0 0 9px; font-size: 12.5px; color: var(--muted); }
.qr-demo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.qr-demo-item {
  display: grid; justify-items: start; gap: 2px;
  padding: 8px; text-align: left; cursor: pointer;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--r);
  font: inherit; color: var(--ink);
}
.qr-demo-item:hover, .qr-demo-item:focus-visible { border-color: var(--brand-soft); background: var(--panel); }
.qr-demo-item svg { width: 100%; height: auto; display: block; border-radius: 2px; margin-bottom: 4px; }
.qr-demo-label { font: 600 13.5px/1.25 var(--body); }
.qr-demo-where { font-size: 11.5px; color: var(--muted); }
.qr-demo-code { font: 600 12.5px/1 var(--sign); letter-spacing: .06em; color: var(--ink-soft); margin-top: 2px; }

.manual { margin-top: 14px; }
.manual label { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 6px; }
.manual-row { display: flex; gap: 8px; }
.manual-row input {
  flex: 1; min-width: 0; font: 600 16px/1 var(--sign); letter-spacing: .06em; text-transform: uppercase;
  padding: 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink);
}
.manual-note { margin: 7px 0 0; font-size: 12.5px; color: var(--muted); }

/* ---------- Alt sekmeler ---------- */

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--panel);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabbar a {
  display: grid; justify-items: center; gap: 3px;
  padding: 9px 2px 10px;
  font: 500 11.5px/1 var(--body);
  color: var(--muted); text-decoration: none;
}
.tabbar svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.tabbar a[aria-current="page"] { color: var(--ink); }
.tabbar a[aria-current="page"] svg { stroke-width: 2.3; }

/* ---------- Bildirim ---------- */

.toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--tabbar-h) + 14px + env(safe-area-inset-bottom));
  z-index: 45;
  background: var(--ink); color: #fff;
  padding: 11px 16px; border-radius: 999px;
  font-size: 14.5px; max-width: calc(100% - 28px);
}

/* ---------- Geniş ekran ---------- */

@media (min-width: 900px) {
  :root { --maxw: 980px; }
  body { padding-bottom: 0; }
  .tabbar {
    position: sticky; top: var(--topbar-h);
    max-width: var(--maxw); margin: 0 auto;
    grid-template-columns: repeat(4, max-content);
    border: 0; background: transparent; gap: 4px; padding: 10px 14px 0;
  }
  .tabbar a { flex-direction: row; grid-auto-flow: column; padding: 9px 13px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); font-size: 13.5px; }
  .tabbar a[aria-current="page"] { background: var(--ink); color: #fff; border-color: var(--ink); }
  .route-layout { display: grid; grid-template-columns: 1.15fr .85fr; gap: 18px; align-items: start; }
  .plan-stage { height: min(70vh, 620px); }
  .toast { bottom: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .route-core { animation: none; }
  .mark-here-pulse { animation: none; opacity: .2; }
  * { scroll-behavior: auto; }
}

@media print {
  .topbar, .tabbar, .locbar, .btn, .plan-tools { display: none !important; }
  body { background: #fff; padding: 0; }
  .panel, .plan-wrap { border-color: #999; }
}
