:root {
  --bg: #f4f1ea;
  --card: #ffffff;
  --ink: #14213d;
  --ink-2: #4a5470;
  --ink-3: #8a91a5;
  --line: #e2ddd2;
  --navy: #14213d;
  --amber: #f5a524;
  --amber-ink: #3b2600;
  --live: #1f9d55;
  --late: #c2410c;
  --early: #2563eb;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(20, 33, 61, .06), 0 4px 16px rgba(20, 33, 61, .06);
  font-family: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d1424;
    --card: #172036;
    --ink: #eef1f7;
    --ink-2: #b4bcd0;
    --ink-3: #7c86a0;
    --line: #26314d;
    --live: #3ccf7a;
    --late: #fb8a4c;
    --early: #7aa7ff;
    --shadow: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { min-height: 100dvh; font-size: 17px; line-height: 1.4; -webkit-tap-highlight-color: transparent; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { fill: currentColor; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
[hidden] { display: none !important; }

/* ---------- header ---------- */
.top {
  background: var(--navy);
  color: #fff;
  padding: calc(env(safe-area-inset-top) + 14px) 16px 0;
  position: sticky; top: 0; z-index: 1000;
}
.brand { display: flex; align-items: center; gap: 10px; max-width: 960px; margin: 0 auto; }
.brand svg { width: 28px; height: 28px; color: var(--amber); }
.brand h1 { font-size: 22px; margin: 0; letter-spacing: -.01em; }
.tabs { display: flex; gap: 4px; max-width: 960px; margin: 12px auto 0; }
.tabs button {
  flex: 1; background: none; border: 0; color: rgba(255,255,255,.7);
  padding: 10px 6px 12px; font-weight: 700; border-bottom: 3px solid transparent;
}
.tabs button[aria-selected="true"] { color: #fff; border-bottom-color: var(--amber); }

main { max-width: 960px; margin: 0 auto; padding: 16px 16px calc(env(safe-area-inset-bottom) + 32px); }

/* ---------- search ---------- */
.search { position: relative; }
.search input {
  width: 100%; padding: 15px 16px 15px 46px; border-radius: var(--radius);
  border: 1.5px solid var(--line); background: var(--card); font-size: 18px; box-shadow: var(--shadow);
}
.search input:focus { outline: none; border-color: var(--amber); }
.search-ic { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); width: 22px; height: 22px; color: var(--ink-3); }
.near {
  margin-top: 10px; width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px; border-radius: var(--radius); border: 0; background: var(--amber); color: var(--amber-ink); font-weight: 700;
}
.near svg { width: 20px; height: 20px; }

.label { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); margin: 26px 4px 8px; }
.hint { color: var(--ink-3); font-size: 15px; margin: 6px 4px; }
.center { text-align: center; }

/* ---------- lists ---------- */
.list { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.list:empty { margin: 0; }
.stop-row {
  display: flex; align-items: center; gap: 12px; text-align: left; width: 100%;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 13px 14px; box-shadow: var(--shadow);
}
.stop-row .pin { width: 36px; height: 36px; border-radius: 10px; background: var(--bg); display: grid; place-items: center; flex: none; color: var(--ink-2); }
.stop-row .pin svg { width: 20px; height: 20px; }
.stop-row .meta { flex: 1; min-width: 0; }
.stop-row .nm { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stop-row .sub { color: var(--ink-3); font-size: 14px; }
.stop-row .chev { width: 18px; height: 18px; color: var(--ink-3); }
.msg { text-align: center; color: var(--ink-2); padding: 20px 10px; }

/* ---------- stop view ---------- */
.stop-head { display: flex; align-items: center; gap: 8px; }
.stop-title { flex: 1; min-width: 0; }
.stop-title h2 { margin: 0; font-size: 21px; line-height: 1.2; }
.code { color: var(--ink-3); font-size: 14px; }
.icon-btn { width: 44px; height: 44px; border-radius: 12px; border: 0; background: var(--card); display: grid; place-items: center; flex: none; box-shadow: var(--shadow); }
.icon-btn svg { width: 24px; height: 24px; }
.star svg { fill: none; stroke: var(--ink-3); stroke-width: 1.8; }
.star[aria-pressed="true"] svg { fill: var(--amber); stroke: var(--amber); }

.chips { display: flex; gap: 6px; overflow-x: auto; padding: 12px 0 2px; scrollbar-width: none; }
.chip { flex: none; border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 15px; }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

.arrivals { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.arr {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px;
  width: 100%; text-align: left; box-shadow: var(--shadow);
}
.arr.sel { border-color: var(--amber); box-shadow: 0 0 0 2px var(--amber); }
.badge {
  min-width: 58px; padding: 5px 8px 6px; border-radius: 10px; display: flex; flex-direction: column; align-items: center;
  font-weight: 700; background: var(--ink); color: var(--bg); line-height: 1.1;
}
.badge .eta { font-size: 12.5px; font-weight: 700; opacity: .9; font-variant-numeric: tabular-nums; letter-spacing: .01em;
  padding-bottom: 3px; margin-bottom: 3px; border-bottom: 1px solid currentColor; border-bottom-color: color-mix(in srgb, currentColor 35%, transparent); width: 100%; text-align: center; }
.badge .rt { font-size: 19px; }
.arr .hs { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arr .det { font-size: 14px; color: var(--ink-3); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.arr .busno { color: var(--ink-2); font-weight: 700; font-variant-numeric: tabular-nums; }
.arr .busno::before { content: '·'; margin-right: 6px; color: var(--ink-3); font-weight: 400; }
.arr .late { color: var(--late); font-weight: 700; }
.arr .early { color: var(--early); font-weight: 700; }
.live { display: inline-flex; align-items: center; gap: 5px; color: var(--live); font-weight: 700; }
.live::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; animation: pulse 1.6s infinite; }
@keyframes pulse { 0%{opacity:1} 50%{opacity:.25} 100%{opacity:1} }
.when { text-align: right; }
.when b { font-size: 26px; line-height: 1; display: block; letter-spacing: -.02em; }
.when small { color: var(--ink-3); font-size: 13px; }
.when.due b { color: var(--live); }

#map-wrap, #para-map-wrap { margin-top: 12px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--card); }
/* Landscape maps: wide rectangle on every screen */
#map, #para-map, #find-map, #near-map { width: 100%; aspect-ratio: 4 / 3; max-height: 72vh; min-height: 280px; }
@media (min-width: 640px) { #map, #para-map, #find-map, #near-map { aspect-ratio: 16 / 9; } }
#find-map-wrap, #near-map-wrap { margin-top: 12px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--card); position: relative; }
.map-full #near-map, .map-full #find-map { height: auto !important; flex: 1; aspect-ratio: auto; max-height: none; }
#map-wrap, #para-map-wrap { position: relative; }
.tabs button { font-size: 14px; padding-left: 2px; padding-right: 2px; }
@media (min-width: 480px) { .tabs button { font-size: 17px; } }
.map-full-btn {
  position: absolute; top: 10px; right: 10px; z-index: 1000; width: 40px; height: 40px; border-radius: 10px;
  border: 0; background: var(--card); color: var(--ink); box-shadow: 0 2px 8px rgba(0,0,0,.25); display: grid; place-items: center;
}
.map-full-btn svg { width: 22px; height: 22px; }
.map-full { position: fixed !important; inset: 0; z-index: 3000; margin: 0 !important; border-radius: 0 !important; border: 0 !important; display: flex; flex-direction: column; }
.map-full #map, .map-full #para-map { height: auto !important; flex: 1; aspect-ratio: auto; max-height: none; }
.map-full .map-full-btn { top: calc(env(safe-area-inset-top) + 12px); }
body.no-scroll { overflow: hidden; }
.map-note { margin: 0; padding: 8px 12px; font-size: 14px; color: var(--ink-2); }
.updated { text-align: center; color: var(--ink-3); font-size: 13px; margin-top: 14px; }

.bus-dot { background: none; border: 0; }
.bus-dot span {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: var(--amber); color: var(--amber-ink); font-weight: 700; font-size: 13px;
  border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.35);
}
.stop-dot span { display: block; width: 18px; height: 18px; border-radius: 50%; background: var(--navy); border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.4); }

/* ---------- para ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.para-form h2 { margin: 0 0 6px; font-size: 22px; }
.para-form label { display: block; font-weight: 700; margin-top: 14px; }
.para-form input:not([type=checkbox]) {
  display: block; width: 100%; margin-top: 6px; padding: 14px; font-size: 22px; letter-spacing: .04em;
  border-radius: 12px; border: 1.5px solid var(--line); background: var(--bg);
}
.para-form input:focus { outline: none; border-color: var(--amber); }
.check { display: flex !important; align-items: center; gap: 10px; font-weight: 400 !important; }
.check input { width: 22px; height: 22px; accent-color: var(--navy); }
.primary { margin-top: 18px; width: 100%; padding: 15px; border: 0; border-radius: 14px; background: var(--navy); color: #fff; font-weight: 700; font-size: 18px; }
@media (prefers-color-scheme: dark) { .primary { background: var(--amber); color: var(--amber-ink); } }
.ghost { display: block; margin: 18px auto 0; border: 0; background: none; color: var(--ink-2); text-decoration: underline; padding: 10px; }
.err { color: var(--late); font-weight: 700; min-height: 1.4em; margin: 12px 0 0; }

.ride { text-align: center; }
.ride-label { margin: 0; color: var(--ink-3); font-size: 15px; text-transform: uppercase; letter-spacing: .08em; }
.ride-big { font-size: 46px; font-weight: 700; margin: 4px 0; letter-spacing: -.02em; line-height: 1.1; }
.ride-sub { margin: 0; color: var(--ink-2); font-size: 18px; }
.steps { list-style: none; display: flex; padding: 0; margin: 20px 0 6px; counter-reset: s; }
.steps li { flex: 1; position: relative; padding-top: 26px; font-size: 14px; color: var(--ink-3); }
.steps li::before {
  content: ""; position: absolute; top: 4px; left: 50%; transform: translateX(-50%);
  width: 14px; height: 14px; border-radius: 50%; background: var(--line); z-index: 1;
}
.steps li + li::after { content: ""; position: absolute; top: 10px; right: 50%; width: 100%; height: 3px; background: var(--line); }
.steps li.on { color: var(--ink); font-weight: 700; }
.steps li.on::before, .steps li.on::after { background: var(--amber); }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 18px 0 0; border-top: 1px solid var(--line); padding-top: 14px; }
.facts dt { font-size: 13px; color: var(--ink-3); }
.facts dd { margin: 2px 0 0; font-weight: 700; font-size: 20px; }

.toast {
  position: fixed; left: 50%; bottom: calc(env(safe-area-inset-bottom) + 20px); transform: translate(-50%, 140%);
  background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 12px; font-weight: 700;
  transition: transform .25s, visibility .25s; z-index: 2000; max-width: calc(100% - 32px); visibility: hidden;
}
.toast.show { transform: translate(-50%, 0); visibility: visible; }

.skeleton { height: 66px; border-radius: 14px; background: linear-gradient(90deg, var(--card) 25%, var(--line) 50%, var(--card) 75%); background-size: 200% 100%; animation: sk 1.2s infinite; }
@keyframes sk { to { background-position: -200% 0; } }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ---------- find a bus ---------- */
#find .hint { margin-top: 10px; }
.bus-row { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; width: 100%; text-align: left;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; box-shadow: var(--shadow); }
.bus-row.sel { border-color: var(--amber); box-shadow: 0 0 0 2px var(--amber); }
.bus-row .busbig { font-weight: 700; font-size: 20px; font-variant-numeric: tabular-nums; }
.bus-row .sub { font-size: 14px; color: var(--ink-3); display: block; }
.bus-row .hs { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bus-row .age { font-size: 13px; color: var(--ink-3); text-align: right; }
.bus-row .badge { min-width: 52px; }

.bus-row .where { color: var(--ink-2); }
.leaflet-tooltip.bus-tip { font-family: inherit; font-size: 14px; line-height: 1.35; padding: 8px 10px; border-radius: 10px;
  border: 0; box-shadow: 0 4px 16px rgba(0,0,0,.25); background: #fff; color: #14213d; width: 250px; white-space: normal; }
.bus-tip .tip-title { font-weight: 700; font-size: 15px; margin-bottom: 2px; }
.leaflet-tooltip.bus-tip::before { display: none; }
.bus-tip .tip-muted { color: #8a91a5; font-size: 12.5px; margin-top: 2px; }

/* ---------- nearby ---------- */
#near .hint { margin-top: 10px; }
#near-map { cursor: crosshair; }
.center-dot { background: none; border: 0; }
.center-dot span { display: block; width: 16px; height: 16px; border-radius: 50%; background: #2563eb; border: 3px solid #fff; box-shadow: 0 0 0 2px rgba(37,99,235,.35), 0 1px 4px rgba(0,0,0,.4); }
.bus-row .dist { font-weight: 700; color: var(--ink); }

.lbl-sm { display: none; }
@media (max-width: 479px) { .lbl-lg { display: none; } .lbl-sm { display: inline; } }

/* ---------- Para Transpo link card ---------- */
.para-link { text-align: center; padding: 26px 20px; }
.para-link h2 { margin: 6px 0 8px; font-size: 22px; }
.para-link p { color: var(--ink-2); margin: 0 auto 4px; max-width: 460px; }
.para-link .pl-icon { width: 44px; height: 44px; color: var(--amber); }
.para-link .pl-btn { display: block; text-decoration: none; text-align: center; max-width: 420px; margin: 18px auto 0; }
.ghost-btn { display: block; max-width: 420px; margin: 10px auto 6px; padding: 13px; border-radius: 14px; border: 1.5px solid var(--line);
  color: var(--ink); text-decoration: none; font-weight: 700; background: var(--card); }
.para-link .hint { margin-top: 12px; }
.para-link .hint a { color: inherit; }

/* ======================= Ad panels ======================= */
.ad-panel { position: fixed; z-index: 900; overflow: hidden; background: var(--card, #fff); border: 1px solid var(--line, #e2ddd2); border-radius: 14px; }
.ad-panel[hidden], body.no-scroll .ad-panel { display: none !important; }
.ad-side { top: calc(var(--hdr, 72px) + 16px); bottom: 16px; width: clamp(140px, calc((100vw - 960px) / 2 - 28px), 320px); display: none; }
.ad-l { left: 14px; } .ad-r { right: 14px; }
.ad-banner { --adh: 67px; left: 0; right: 0; bottom: 0; height: calc(var(--adh) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); display: none;
  border-radius: 0; border-width: 1px 0 0; box-shadow: 0 -2px 10px rgba(0,0,0,.08); }
.ad-banner.ad-regular { --adh: 86px; }
.ad-banner > .ad-slide, .ad-banner .ad-slider, .ad-banner .ad-reel { height: var(--adh) !important; }
.ad-m-fade.ad-banner .ad-slide { bottom: env(safe-area-inset-bottom); }
@media (min-width: 1300px) { .ad-side.has-ads { display: block; } }
@media (max-width: 1299.98px) { .ad-banner.has-ads { display: block; } body.has-banner main { padding-bottom: calc(var(--adh-pad, 67px) + 16px + env(safe-area-inset-bottom)); } body.has-banner .toast { bottom: calc(var(--adh-pad, 67px) + 16px); } }
@media (min-width: 700px) { .ad-banner { left: 50%; right: auto; width: 680px; transform: translateX(-50%); border-width: 1px 1px 0; border-radius: 12px 12px 0 0; } }
/* compact card used on the phone strip for tall/square pictures */
.ad-card { justify-content: flex-start; gap: 10px; padding: 6px 36px 6px 8px; color: var(--ink, #14213d); }
.ad-thumb { flex: none; height: calc(var(--adh) - 12px); aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--bg, #f4f1ea); display: grid; place-items: center; }
.ad-thumb img, .ad-thumb canvas { width: 100%; height: 100%; max-width: none; max-height: none; object-fit: cover; }
.ad-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.ad-txt small { font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink3, #8a91a5); }
.ad-txt b { font-size: 17px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.15; }
.ad-go { flex: none; font-weight: 700; font-size: 16px; color: #14213d; background: var(--amber, #f5a524); padding: 8px 14px; border-radius: 99px; }
.ad-regular .ad-txt b { font-size: 19px; }
.ad-close { position: absolute; top: 50%; margin-top: -11px; right: 6px; z-index: 3; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(0,0,0,.55); color: #fff; font-size: 15px; line-height: 22px; cursor: pointer; padding: 0; opacity: .8; }
.ad-banner .ad-close { top: calc((var(--adh) - 22px) / 2); margin-top: 0; }
.ad-tag { position: absolute; bottom: 4px; left: 6px; z-index: 3; font-size: 10px; letter-spacing: .04em; text-transform: uppercase; color: #fff; background: rgba(0,0,0,.45); padding: 1px 5px; border-radius: 4px; pointer-events: none; }
.ad-slide { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; text-decoration: none; }
.ad-slide img, .ad-slide canvas { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
a.ad-slide { cursor: pointer; }
/* fade */
.ad-m-fade .ad-slide { position: absolute; inset: 0; opacity: 0; transition-property: opacity; transition-timing-function: ease; pointer-events: none; }
.ad-m-fade .ad-slide.on { opacity: 1; pointer-events: auto; z-index: 1; }
/* slide */
.ad-slider { display: flex; height: 100%; transition-property: transform; transition-timing-function: ease-in-out; }
.ad-slider .ad-slide { flex: 0 0 100%; }
/* continuous scroll */
.ad-m-scroll .ad-reel { display: flex; flex-direction: column; gap: 12px; padding: 6px; animation: ad-up linear infinite; }
.ad-m-scroll .ad-slide { height: auto; }
.ad-m-scroll .ad-slide img, .ad-m-scroll .ad-slide canvas { width: 100%; max-height: none; height: auto; }
.ad-m-scroll:hover .ad-reel { animation-play-state: paused; }
.ad-banner.ad-m-scroll .ad-reel { flex-direction: row; height: 100%; width: max-content; padding: 0 6px; animation-name: ad-left; }
.ad-banner.ad-m-scroll .ad-slide { height: 100%; width: auto; }
.ad-banner.ad-m-scroll .ad-card { width: 336px; padding-right: 8px; }
.ad-banner.ad-m-scroll .ad-slide img, .ad-banner.ad-m-scroll .ad-slide canvas { height: 100%; width: auto; max-width: none; }
@keyframes ad-up { from { transform: translateY(0); } to { transform: translateY(-50%); } }
@keyframes ad-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ad-m-scroll .ad-reel { animation: none; } .ad-m-fade .ad-slide, .ad-slider { transition: none !important; } }

/* ======================= Email sign-up popup ======================= */
.sub-back { position: fixed; inset: 0; z-index: 4000; background: rgba(13, 20, 36, .5); display: flex; align-items: center; justify-content: center; padding: 16px; opacity: 0; transition: opacity .25s; }
.sub-back.in { opacity: 1; }
.sub-card { position: relative; background: var(--card, #fff); color: var(--ink, #14213d); width: 100%; max-width: 400px; border-radius: 20px; padding: 26px 22px 16px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: 0 20px 60px rgba(0,0,0,.3); transform: translateY(16px); transition: transform .25s; max-height: calc(100vh - 32px); overflow-y: auto; }
.sub-back.in .sub-card { transform: none; }
.sub-card h2 { margin: 0; font-size: 22px; line-height: 1.2; text-align: center; }
.sub-txt { margin: 0 0 4px; text-align: center; color: var(--ink2, #4a5470); font-size: 15px; }
.sub-ic { width: 52px; height: 52px; border-radius: 50%; background: var(--amber, #f5a524); display: grid; place-items: center; margin: 0 auto 2px; }
.sub-ic svg { width: 28px; height: 28px; fill: #14213d; }
.sub-ic.ok { background: #1f9d55; } .sub-ic.ok svg { fill: #fff; }
.sub-card input[type=email], .sub-card input[type=text] { width: 100%; box-sizing: border-box; font: inherit; font-size: 17px; padding: 12px 14px; border: 1.5px solid var(--line, #e2ddd2); border-radius: 12px; background: var(--bg, #f4f1ea); color: inherit; }
.sub-card input:focus { outline: 2px solid var(--amber, #f5a524); outline-offset: 1px; }
.sub-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.sub-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.4; cursor: pointer; margin-top: 4px; }
.sub-consent input { width: 20px; height: 20px; flex: none; margin: 1px 0 0; accent-color: #14213d; }
.sub-sender { margin: 0 0 0 30px; font-size: 12px; color: var(--ink3, #8a91a5); }
.sub-err { margin: 0; min-height: 1.2em; color: #c2410c; font-weight: 700; font-size: 14px; }
.sub-card .primary { width: 100%; margin-top: 6px; }
.sub-later { background: none; border: 1.5px solid var(--line, #e2ddd2); border-radius: 12px; color: var(--ink2, #4a5470); font: inherit; font-size: 16px; font-weight: 700; padding: 11px; cursor: pointer; }
.sub-x { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--bg, #f4f1ea); color: inherit; font-size: 20px; line-height: 1; cursor: pointer; }
@media (max-width: 520px) {
  .sub-back { align-items: flex-end; padding: 0; }
  .sub-card { max-width: none; border-radius: 20px 20px 0 0; padding-bottom: calc(16px + env(safe-area-inset-bottom)); transform: translateY(100%); }
}
@media (prefers-reduced-motion: reduce) { .sub-back, .sub-card { transition: none; } }

/* ======================= Arrival alert bell ======================= */
.arr-wrap { display: flex; gap: 8px; align-items: stretch; }
.arr-wrap .arr { flex: 1; min-width: 0; }
.bell { flex: none; width: 52px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); box-shadow: var(--shadow); color: var(--ink-3);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; cursor: pointer; padding: 0; }
.bell svg { width: 22px; height: 22px; fill: currentColor; }
.bell small { font-size: 11px; font-weight: 700; line-height: 1; }
.bell:hover { color: var(--ink); }
.bell.on { background: var(--amber); border-color: var(--amber); color: #14213d; }
@media (max-width: 380px) { .bell { width: 44px; } }
.alert-card { text-align: center; }
.lead-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 4px; }
.lead-btn { border: 1.5px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 14px; padding: 14px 6px; cursor: pointer; font: inherit; display: flex; flex-direction: column; gap: 2px; align-items: center; }
.lead-btn b { font-size: 20px; } .lead-btn small { font-size: 12px; color: var(--ink-3); }
.lead-btn:not(:disabled):hover { border-color: var(--amber); }
.lead-btn:disabled { opacity: .4; cursor: default; }

/* ======================= City / agency picker ======================= */
body.picking .tabs { display: none; }
.brand { position: relative; }
.ag-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; max-width: 62%; background: none; color: #fff;
  border: 1px solid rgba(255,255,255,.35); border-radius: 99px; padding: 6px 12px; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.ag-chip span { overflow: hidden; text-overflow: ellipsis; }
.ag-chip svg { width: 14px; height: 14px; flex: none; fill: var(--amber); color: var(--amber); }
.ag-chip b { color: var(--amber); }
@media (max-width: 420px) { .ag-chip span { display: none; } }
.pick-h { font-size: 30px; line-height: 1.15; margin: 14px 4px 6px; }
.pick-sub { font-size: 17px; color: var(--ink-2); margin: 0 4px 16px; }
#pick .label { margin-top: 22px; }
.city-badge { width: 44px; height: 44px; border-radius: 12px; background: var(--navy, #14213d); color: var(--amber); display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 15px; flex: none; }
.city-badge svg { width: 26px; height: 26px; fill: currentColor; }
.city-row .sub { line-height: 1.35; }
.ghost-back { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; padding: 9px 14px 9px 8px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); font: inherit; font-size: 16px; font-weight: 700; cursor: pointer; }
.ghost-back svg { width: 20px; height: 20px; fill: currentColor; }
.credit { text-align: center; font-size: 13px; color: var(--ink-3); margin: 28px 0 0; }
body.picking .credit { display: none; }
.lang-btn { flex: none; background: none; color: #fff; border: 1px solid rgba(255,255,255,.35); border-radius: 99px; padding: 6px 10px; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.ag-chip + .lang-btn, .ag-chip[hidden] + .lang-btn { margin-left: 8px; }
.ag-chip[hidden] + .lang-btn { margin-left: auto; }
.sub-card h2 { padding: 0 34px; }
.home-btn { flex: none; width: 40px; height: 40px; margin-left: -6px; border: 0; border-radius: 12px; background: rgba(255,255,255,.1); color: #fff;
  display: grid; place-items: center; cursor: pointer; padding: 0; }
.home-btn:hover { background: rgba(255,255,255,.18); }
.home-btn svg { width: 22px !important; height: 22px !important; fill: currentColor; color: #fff !important; }
.brand h1 { cursor: pointer; }
@media (max-width: 380px) { .brand > svg { display: none; } }
.pick-label { display: block; font-weight: 700; font-size: 15px; margin: 22px 4px 8px; color: var(--ink-2); }
.pick-select-wrap { position: relative; }
.pick-select-wrap select { width: 100%; appearance: none; -webkit-appearance: none; font: inherit; font-size: 18px; font-weight: 700; color: var(--ink);
  background: var(--card); border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 48px 16px 16px; box-shadow: var(--shadow); cursor: pointer; }
.pick-select-wrap select:focus { outline: 2px solid var(--amber); outline-offset: 1px; }
.pick-select-wrap .chev { position: absolute; right: 16px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%) rotate(90deg); pointer-events: none; color: var(--ink-3); }

/* "Change city" drop-down */
.ag-menu { position: absolute; top: calc(100% + 8px); right: 0; z-index: 1100; width: min(300px, calc(100vw - 32px)); max-height: min(70vh, 480px); overflow-y: auto;
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 12px 32px rgba(20,33,61,.22); padding: 6px; }
.ag-menu-prov { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); padding: 10px 10px 2px; }
.ag-menu-city { font-size: 15px; font-weight: 700; padding: 8px 10px 2px; }
.ag-menu-item, .ag-menu-all { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; text-align: left; background: none; border: 0;
  border-radius: 10px; padding: 10px 10px 10px 22px; font: inherit; font-size: 15px; color: var(--ink); cursor: pointer; }
.ag-menu-item:hover, .ag-menu-all:hover, .ag-menu-item:focus-visible, .ag-menu-all:focus-visible { background: var(--line); outline: none; }
.ag-menu-item.on { font-weight: 700; }
.ag-menu-item svg { width: 18px; height: 18px; fill: var(--amber); flex: none; }
.ag-menu-all { margin-top: 6px; border-top: 1px solid var(--line); border-radius: 0 0 10px 10px; padding-left: 10px; font-weight: 700; color: var(--ink); }
