/* ==========================================================================
   ParkQueueHub — "Nocturne Transit & Vintage Ticket" Design System
   ========================================================================== */

:root {
  --bg: #060911;
  --bg-subtle: #0a101d;
  --surface: #0e1627;
  --surface-hover: #141f36;
  --surface-glass: rgba(14, 22, 39, 0.72);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #f3f6fb;
  --text-soft: #cbd5e1;
  --muted: #8292ab;

  /* Tactile Vintage Ticket Surface */
  --ticket-bg: #f6efe2;
  --ticket-ink: #0c1322;
  --ticket-muted: #5b667a;
  --ticket-dash: rgba(12, 19, 34, 0.22);

  /* Brand & Semantic 5-Tier Wait Scale */
  --accent: #38bdf8;
  --amber-brand: #f59e0b;
  --coral-brand: #fb7185;
  --quietest: #10b981;
  --quieter: #84cc16;
  --typical: #f59e0b;
  --busier: #f97316;
  --busiest: #f43f5e;
  --closed: #64748b;

  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 18px;
  --shadow-card: 0 1px 0 rgba(255,255,255,0.05) inset, 0 10px 30px rgba(0, 0, 0, 0.28);
  --shadow-ticket: 0 24px 60px rgba(0, 0, 0, 0.48), 0 2px 6px rgba(0,0,0,0.22);
}

[data-theme="light"] {
  --bg: #f4f1ea;
  --bg-subtle: #ece7dc;
  --surface: #ffffff;
  --surface-hover: #fbfaf7;
  --surface-glass: rgba(255, 255, 255, 0.85);
  --border: rgba(12, 19, 34, 0.09);
  --border-strong: rgba(12, 19, 34, 0.18);
  --text: #0c1322;
  --text-soft: #334155;
  --muted: #64748b;
  --ticket-bg: #11192b;
  --ticket-ink: #f8fafc;
  --ticket-muted: #94a3b8;
  --ticket-dash: rgba(255, 255, 255, 0.2);
  --shadow-card: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.06);
  --shadow-ticket: 0 20px 50px rgba(15, 23, 42, 0.18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: clip;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}

a { color: inherit; text-decoration: none; }
button, input, select { font-family: inherit; }
.hidden { display: none !important; }
.mono { font-family: var(--font-mono); }
.muted { color: var(--muted); }
.container { max-width: 1220px; margin: 0 auto; padding: 0 24px; }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  --header-accent: #ff9b38;
  background: rgba(10, 16, 27, 0.97);
  border-bottom: 1px solid var(--border);
}
[data-theme="light"] .topbar { --header-accent: #a94d00; background: #fbfaf7; }
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 72px; gap: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0; }
.brand-logo {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; flex: 0 0 40px;
}
.brand-logo[hidden] { display: none; }
.brand-logo img { display: block; width: 52px; height: 52px; max-width: none; flex-shrink: 0; object-fit: contain; }
.brand-wordmark {
  font-family: var(--font-display);
  font-weight: 700; font-size: 18px; line-height: 24px; letter-spacing: 0;
  white-space: nowrap;
}
.header-menu { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 16px; flex: 1; min-width: 0; }
.nav { display: flex; align-items: center; gap: 4px; min-width: 0; flex-shrink: 0; }
.nav-link, .nav-more-toggle {
  position: relative; display: inline-flex; align-items: center; gap: 4px;
  height: 36px; padding: 0 8px; border-radius: 6px;
  font-size: 14px; line-height: 20px; font-weight: 500; white-space: nowrap;
  background: transparent; border: 0; color: var(--text-soft); cursor: pointer;
  transition: color 0.16s, background-color 0.16s;
}
.nav-link:hover, .nav-more-toggle:hover { color: var(--text); background: rgba(148, 163, 184, 0.08); }
.nav-link.active { color: var(--header-accent); }
.nav > .nav-link.active::after {
  content: ''; position: absolute; left: 8px; right: 8px; bottom: 0;
  height: 2px; background: var(--header-accent); border-radius: 2px;
}
.nav-more { position: relative; }
.nav-more-toggle svg { transition: transform 0.16s; }
.nav-more-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav-more-toggle.is-current { color: var(--header-accent); }
.nav-more-panel {
  z-index: 2;
  display: none; position: absolute; top: calc(100% + 12px); right: 0; left: auto;
  min-width: 180px; padding: 8px; background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.18);
}
.nav-more.is-open .nav-more-panel { display: grid; gap: 4px; }
.nav-more-panel .nav-link { height: 40px; padding: 0 12px; }
.nav-more-panel .nav-link.active { background: rgba(148, 163, 184, 0.08); }

.topbar-actions { display: flex; align-items: center; gap: 4px; flex-shrink: 0; padding-left: 12px; border-left: 1px solid var(--border); }
.search-trigger {
  display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 8px 0 12px; border-radius: 8px;
  background: var(--surface); border: 1px solid var(--border-strong);
  color: var(--text-soft); font-size: 14px; cursor: pointer;
  white-space: nowrap; flex-shrink: 0;
  transition: border-color 0.16s, color 0.16s;
}
.search-trigger:hover { border-color: var(--border-strong); color: var(--text); }
.search-trigger kbd {
  font-family: var(--font-mono); font-size: 11px;
  padding: 0 4px; border-radius: 4px;
  background: rgba(148, 163, 184, 0.08); color: var(--muted);
}
.icon-pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 8px; border-radius: 8px;
  background: transparent; border: 1px solid transparent;
  color: var(--text-soft); font-size: 13px; font-weight: 500; cursor: pointer;
  white-space: nowrap; flex-shrink: 0;
  transition: color 0.16s, background-color 0.16s;
}
.icon-pill:hover { background: rgba(148, 163, 184, 0.08); color: var(--text); }
.count-dot {
  display: inline-grid; place-items: center; min-width: 16px; height: 16px;
  font-size: 11px; line-height: 16px; font-weight: 600;
  padding: 0 4px; border-radius: 4px;
  background: rgba(148, 163, 184, 0.12); color: var(--text-soft);
}
.count-dot.is-empty { display: none; }
.icon-square {
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text-soft); display: grid; place-items: center; cursor: pointer;
  flex-shrink: 0; transition: border-color 0.16s;
}
.icon-square:hover { border-color: var(--border-strong); color: var(--text); }
.topbar .icon-square {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 36px; height: 36px; border-radius: 8px;
  background: transparent; border-color: transparent;
}
.topbar .icon-square:hover { background: rgba(148, 163, 184, 0.08); }
.topbar svg { flex-shrink: 0; width: 18px; height: 18px; stroke-width: 1.8; }
.mobile-tool-label { display: none; }
.nav-menu-toggle { display: none; }
.topbar :focus-visible { outline-color: var(--header-accent); }

@media (max-width: 1199px) {
  .topbar-inner { min-height: 64px; gap: 12px; }
  .topbar .brand { margin-right: auto; }
  .header-menu {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    padding: 16px 24px 20px; background: var(--bg-subtle);
    border-bottom: 1px solid var(--border-strong);
    box-shadow: 0 16px 24px rgba(0, 0, 0, 0.16);
    max-height: calc(100dvh - 64px); overflow-y: auto; overscroll-behavior: contain;
  }
  .header-menu.is-open { display: grid; gap: 16px; }
  .nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 12px; }
  .nav > .nav-link, .nav-more-panel .nav-link {
    height: 44px; padding: 0 12px; font-size: 14px; border-radius: 8px;
  }
  .nav-link.active { background: rgba(148, 163, 184, 0.08); }
  .nav > .nav-link.active::after { left: 0; right: auto; bottom: 14px; width: 2px; height: 16px; }
  .nav-more, .nav-more-panel, .nav-more.is-open .nav-more-panel { display: contents; }
  .nav-more-toggle { display: none; }
  .topbar-actions { flex-wrap: wrap; gap: 8px; padding: 16px 0 0; border-left: 0; border-top: 1px solid var(--border); }
  .topbar-actions .icon-pill, .topbar-actions .icon-square {
    min-height: 44px; padding: 0 12px; width: auto;
    border: 1px solid var(--border); background: var(--surface);
  }
  .mobile-tool-label { display: inline; }
  .search-trigger { height: 40px; }
  .nav-menu-toggle {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    height: 40px; padding: 0 12px; border: 1px solid var(--border-strong);
    border-radius: 8px; color: var(--text); background: transparent;
    font-size: 13px; font-weight: 500; cursor: pointer; flex-shrink: 0;
  }
  .nav-menu-toggle:hover, .nav-menu-toggle[aria-expanded="true"] { background: var(--surface); }
  .nav-menu-toggle .menu-close-icon { display: none; }
  .nav-menu-toggle[aria-expanded="true"] .menu-open-icon { display: none; }
  .nav-menu-toggle[aria-expanded="true"] .menu-close-icon { display: block; }
}
@media (max-width: 600px) {
  .topbar-inner { gap: 8px; }
  .topbar .brand-wordmark { font-size: 17px; }
  .brand-logo { width: 36px; height: 36px; flex-basis: 36px; }
  .brand-logo img { width: 48px; height: 48px; }
  .header-menu { padding: 12px 16px 16px; }
  .search-trigger { width: 40px; padding: 0; justify-content: center; }
  .search-trigger-text, .search-trigger kbd { display: none; }
}
@media (max-width: 380px) {
  .topbar .brand-wordmark { font-size: 16px; }
  .nav-menu-toggle { width: 40px; padding: 0; }
  #navMenuLabel { display: none; }
  .topbar-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .topbar-actions .icon-pill, .topbar-actions .icon-square { justify-content: flex-start; }
}

/* ---------- Atmospheric Editorial Hero ---------- */
.hero-banner {
  position: relative; overflow: hidden;
  padding: 58px 0 46px;
  border-bottom: 1px solid var(--border);
  background-color: #060911;
  color: #f3f6fb;
}
.hero-banner.park-hero { padding: 38px 0 34px; }
.hero-bg-img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 42%;
  opacity: 0.44; filter: saturate(1.1) contrast(1.06);
  pointer-events: none;
}
.hero-scrim {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(6, 9, 17, 0.94) 0%, rgba(6, 9, 17, 0.72) 52%, rgba(6, 9, 17, 0.48) 100%),
    linear-gradient(180deg, rgba(6, 9, 17, 0.35) 0%, rgba(6, 9, 17, 0.96) 100%);
}
.hero-content { position: relative; z-index: 2; }

.live-telemetry-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 12px; border-radius: 999px;
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: 0.05em;
  background: rgba(16, 185, 129, 0.14); color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
  text-transform: uppercase;
}
.pulse-dot {
  width: 7px; height: 7px; border-radius: 50%; background: #10b981;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulseRing 2s infinite;
}
@keyframes pulseRing {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.65); }
  70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 5.2vw, 58px);
  font-weight: 700; line-height: 1.03; letter-spacing: -0.03em;
  margin: 16px 0 12px; color: #ffffff;
}
.hero-title .accent { color: #fb923c; }
.hero-lead {
  font-size: 16.5px; color: #b8c5da; max-width: 610px; margin: 0 0 28px;
}

/* ---------- Home park chooser ---------- */
.home-park-picker {
  --picker-orange: #ff9b38;
  padding: 22px 24px 16px;
  border: 1px solid rgba(190, 207, 231, 0.2);
  border-radius: 16px;
  background: rgba(10, 17, 29, 0.94);
  color: #f3f6fb;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.2);
  min-width: 0;
}
.home-picker-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px 24px; }
.home-picker-title { margin: 0; font: 700 21px/1.3 var(--font-display); letter-spacing: -0.02em; }
.home-mode-tabs { display: flex; gap: 4px; padding: 4px; border: 1px solid rgba(190, 207, 231, 0.16); border-radius: 10px; background: #070d18; }
.home-mode-tab {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 44px; padding: 9px 14px; border: 0; border-radius: 6px;
  background: transparent; color: #c4cfe0; font-size: 14px; font-weight: 600; line-height: 1.35; cursor: pointer;
}
.home-mode-tab:hover { background: #1a2638; color: #fff; }
.home-mode-tab[aria-pressed="true"] { background: var(--picker-orange); color: #111827; }
.home-mode-icon { display: inline-flex; flex-shrink: 0; }
.home-mode-icon svg { width: 17px; height: 17px; }
.home-picker-hint { margin: 10px 0 14px; color: #afbdd1; font-size: 14px; line-height: 1.5; }
.home-region-filters { display: flex; flex-wrap: wrap; gap: 2px 18px; margin-bottom: 16px; border-bottom: 1px solid rgba(190, 207, 231, 0.14); }
.home-region-filter {
  min-height: 44px; padding: 8px 1px 10px; border: 0; border-bottom: 2px solid transparent;
  background: transparent; color: #b8c5d8; font-size: 14px; font-weight: 500; cursor: pointer;
}
.home-region-filter:hover { color: #fff; }
.home-region-filter[aria-pressed="true"] { color: var(--picker-orange); border-bottom-color: var(--picker-orange); }
.home-park-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-content: start; gap: 9px; min-width: 0; }
.home-park-choices.is-expanded { max-height: 340px; overflow-y: auto; overscroll-behavior-y: contain; padding: 3px 8px 3px 3px; margin: -3px 0 -3px -3px; scrollbar-color: #52627a #0a111d; scrollbar-width: thin; }
.home-park-choice {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; min-width: 0; min-height: 78px; padding: 13px 15px;
  border: 1px solid rgba(190, 207, 231, 0.19); border-radius: 9px;
  text-align: left; background: #111c2d; color: #f3f6fb; cursor: pointer;
  transition: background 120ms, border-color 120ms;
}
.home-park-choice:hover { background: #1a293d; border-color: var(--picker-orange); }
.home-park-choice.has-photo {
  display: grid; grid-template-rows: auto 1fr; align-items: stretch; justify-content: stretch;
  gap: 0; padding: 0; overflow: hidden;
}
.home-park-choice-media { display: block; width: 100%; aspect-ratio: 2 / 1; overflow: hidden; background: #18283b; }
.home-park-choice-image { display: block; width: 100%; height: 100%; object-fit: cover; }
[data-park-slug="magic-kingdom-park"] .home-park-choice-image { object-position: center top; }
[data-park-slug="disneyland-park"] .home-park-choice-image { object-fit: contain; }
[data-park-slug="disneyland-park-734055"] .home-park-choice-image { object-position: center 25%; }
[data-park-slug="chimelong-spaceship"] .home-park-choice-image { object-position: left center; }
.home-park-choice-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; overflow-wrap: anywhere; }
.home-park-choice.has-photo .home-park-choice-text { justify-content: center; min-height: 74px; padding: 11px 14px 12px; }
.home-park-choice-name { font-size: 15px; font-weight: 600; line-height: 1.35; }
.home-park-choice-place { color: #aebdd2; font-size: 14px; line-height: 1.4; }
.home-park-choices.is-expanded .home-park-choice.has-photo { display: flex; justify-content: flex-start; align-items: center; gap: 12px; padding: 10px; }
.home-park-choices.is-expanded .home-park-choice-media { flex: 0 0 64px; width: 64px; height: 54px; aspect-ratio: auto; border-radius: 4px; }
.home-park-choices.is-expanded .home-park-choice.has-photo .home-park-choice-text { min-height: 0; padding: 0; }
.home-park-picker button:focus-visible { outline: 2px solid var(--picker-orange); outline-offset: 3px; }
.home-park-picker .home-park-choice:focus-visible { outline-offset: -4px; }
.home-picker-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 16px; padding-top: 12px; }
.home-picker-count { color: #aebdd2; font-size: 14px; }
.home-show-all { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 0; border: 0; background: transparent; color: var(--picker-orange); font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }
.home-show-all:hover { color: #ffb66b; }
.home-photo-credits { display: table; margin-top: 2px; padding: 4px 0; color: #aebdd2; font-size: 12px; line-height: 1.5; text-decoration: underline; text-underline-offset: 3px; }
.home-photo-credits:hover { color: #fff; }
.home-photo-credits:focus-visible { outline: 2px solid var(--picker-orange); outline-offset: 3px; }
.home-picker-empty { grid-column: 1 / -1; padding: 12px 0; margin: 0; color: #c4cfe0; font-size: 14px; }
.home-nearby { margin: 18px 0 20px; padding: 18px 0; border-top: 1px solid rgba(190, 207, 231, 0.14); border-bottom: 1px solid rgba(190, 207, 231, 0.14); }
.home-nearby-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.home-nearby h3 { margin: 0; color: #f3f6fb; font-size: 17px; line-height: 1.4; }
.home-nearby-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; }
.nearby-locate, .nearby-retry, .nearby-browse { min-height: 44px; border: 0; font-size: 14px; line-height: 1.4; cursor: pointer; }
.nearby-locate { padding: 9px 13px; border-radius: 6px; background: #ff9b38; color: #111827; font-weight: 600; }
.nearby-locate:hover { background: #ffb366; }
.nearby-retry, .nearby-browse { padding: 8px 0; background: transparent; color: #b8c5d8; text-decoration: underline; text-underline-offset: 3px; }
.nearby-retry:hover, .nearby-browse:hover { color: #fff; }
.home-nearby button:disabled { opacity: .6; cursor: wait; }
.home-nearby-status { margin: 10px 0; max-width: 900px; color: #aebdd2; font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.home-nearby-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.home-nearby-choices:empty { display: none; }
.nearby-park-choice, .nearby-park-choice.has-photo { display: flex; justify-content: flex-start; align-items: center; gap: 10px; padding: 10px; }
.nearby-park-choice .home-park-choice-media { flex: 0 0 64px; width: 64px; height: 68px; aspect-ratio: auto; border-radius: 4px; }
.nearby-park-choice.has-photo .home-park-choice-text { min-height: 0; padding: 0; }
.nearby-distance { color: #ffc080; font-size: 13px; line-height: 1.4; }
.nearby-browse { margin-top: 2px; }
@media (max-width: 900px) {
  .home-picker-head { align-items: flex-start; }
  .home-park-choices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-nearby-choices { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .home-park-picker { padding: 18px 16px 12px; }
  .home-picker-title { font-size: 20px; }
  .home-mode-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; }
  .home-mode-tab { min-height: 44px; padding: 8px 4px; }
  .home-mode-icon { display: none; }
  .home-region-filters { gap: 0 14px; margin-bottom: 12px; }
  .home-park-choice { min-height: 88px; gap: 7px; padding: 10px; }
  .home-park-choice.has-photo .home-park-choice-text { min-height: 83px; padding: 9px 10px 10px; }
  .home-park-choices.is-expanded .home-park-choice.has-photo { gap: 7px; }
  .home-park-choices.is-expanded .home-park-choice-media { flex-basis: 44px; width: 44px; height: 48px; }
  .home-park-choice-name { font-size: 14px; }
  .home-park-choices.is-expanded { max-height: min(52vh, 420px); }
  .home-picker-foot { align-items: flex-start; gap: 0 12px; }
  .home-picker-count { padding-top: 10px; }
  .home-nearby { margin: 16px 0; padding: 16px 0; }
  .home-nearby-actions { gap: 2px 12px; }
  .nearby-park-choice.has-photo .home-park-choice-text { min-height: 0; padding: 0; }
}

/* ---------- Tactile Vintage Ticket-Stub Widget ---------- */
.ticket-stub {
  position: relative;
  background: var(--ticket-bg);
  color: var(--ticket-ink);
  border-radius: 16px;
  padding: 14px 22px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px;
  box-shadow: var(--shadow-ticket);
}
/* Semicircular punch notches on left & right */
.ticket-stub::before,
.ticket-stub::after {
  content: '';
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; border-radius: 50%;
  background: #060911;
}
[data-theme="light"] .section .ticket-stub::before,
[data-theme="light"] .section .ticket-stub::after {
  background: var(--bg);
}
.ticket-stub::before { left: -9px; }
.ticket-stub::after { right: -9px; }

.ticket-segment {
  flex: 1 1 210px;
  display: flex; flex-direction: column; gap: 3px;
  padding-right: 18px;
  border-right: 2px dashed var(--ticket-dash);
  position: relative;
}
.ticket-segment.compact { flex: 0 1 210px; }
.ticket-segment.no-border { border-right: none; padding-right: 0; }
.ticket-kicker {
  font-family: var(--font-mono);
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--ticket-muted);
}
.ticket-input, .ticket-select {
  width: 100%; border: none; background: transparent; outline: none;
  color: var(--ticket-ink); font-size: 15.5px; font-weight: 600;
  padding: 3px 0;
}
.ticket-input::placeholder { color: var(--ticket-muted); font-weight: 500; }
.ticket-select option { color: #0f172a; background: #ffffff; }

.ticket-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: #0c1322; color: #f8fafc;
  border: none; border-radius: 11px;
  padding: 13px 22px; font-size: 14.5px; font-weight: 700;
  cursor: pointer; transition: transform 0.14s, background 0.14s;
  white-space: nowrap;
}
[data-theme="light"] .section .ticket-cta { background: #f59e0b; color: #0c1322; }
.ticket-cta:hover { transform: translateY(-1px); background: #1e293b; }

.ticket-check {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 13.5px; font-weight: 600; color: var(--ticket-ink);
  cursor: pointer; user-select: none;
}
.ticket-check input { width: 16px; height: 16px; accent-color: #10b981; cursor: pointer; }

/* Autocomplete */
.autocomplete {
  position: absolute; top: calc(100% + 12px); left: -6px; right: -6px; z-index: 60;
  background: #ffffff; color: #0c1322;
  border-radius: 12px; border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.35);
  max-height: 280px; overflow-y: auto;
}
.ac-item {
  padding: 10px 14px; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06); font-size: 13.5px;
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover { background: #f1f5f9; }
.ac-name { font-weight: 600; }
.ac-meta { font-size: 12px; color: #64748b; }

/* Hero Quick Chips */
.hero-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; align-items: center; }
.hero-chip-label { font-size: 12px; color: #94a3b8; margin-right: 4px; font-weight: 500; }
.hero-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 500;
  background: rgba(255, 255, 255, 0.07); color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px); transition: 0.16s;
}
.hero-chip:hover { background: rgba(255, 255, 255, 0.14); border-color: rgba(255, 255, 255, 0.28); }

/* ---------- Semantic Pills & Badges ---------- */
.tier-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 9px; border-radius: 999px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  white-space: nowrap;
}
.tier-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tier-quietest { background: rgba(16, 185, 129, 0.15); color: var(--quietest); border: 1px solid rgba(16, 185, 129, 0.28); }
.tier-quieter  { background: rgba(132, 204, 22, 0.15); color: var(--quieter);  border: 1px solid rgba(132, 204, 22, 0.28); }
.tier-typical  { background: rgba(245, 158, 11, 0.15); color: var(--typical);  border: 1px solid rgba(245, 158, 11, 0.28); }
.tier-busier   { background: rgba(249, 115, 22, 0.15); color: var(--busier);   border: 1px solid rgba(249, 115, 22, 0.28); }
.tier-busiest  { background: rgba(244, 63, 94, 0.16);  color: var(--busiest);  border: 1px solid rgba(244, 63, 94, 0.3); }
.tier-closed   { background: rgba(100, 116, 139, 0.16); color: var(--muted);   border: 1px solid rgba(100, 116, 139, 0.25); }

.source-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  padding: 3px 8px; border-radius: 6px;
  background: rgba(56, 189, 248, 0.12); color: var(--accent);
  border: 1px solid rgba(56, 189, 248, 0.25);
}
.source-badge.est {
  background: rgba(245, 158, 11, 0.12); color: var(--typical);
  border-color: rgba(245, 158, 11, 0.25);
}

/* ---------- Sections & Segmented Controls ---------- */
.section { padding: 38px 0; }
.section-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  flex-wrap: wrap; gap: 14px; margin-bottom: 20px;
}
.section-kicker {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--amber-brand);
  margin-bottom: 4px;
}
.section-title {
  font-family: var(--font-display); font-size: 24px; font-weight: 700;
  letter-spacing: -0.02em; margin: 0;
}

.seg-group {
  display: inline-flex; padding: 3px; border-radius: 10px;
  background: var(--bg-subtle); border: 1px solid var(--border);
  gap: 2px; flex-wrap: wrap;
}
.seg-btn {
  padding: 6px 12px; border-radius: 7px; border: none; background: transparent;
  color: var(--muted); font-size: 13px; font-weight: 500; cursor: pointer; transition: 0.15s;
}
.seg-btn:hover { color: var(--text); }
.seg-btn.active {
  background: var(--surface); color: var(--text); font-weight: 600;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

/* ---------- Featured Park Cards ---------- */
.park-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.park-card {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 20px;
  box-shadow: var(--shadow-card);
  display: flex; flex-direction: column; justify-content: space-between; gap: 14px;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.park-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--card-accent, var(--closed));
}
.park-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.34);
}
.park-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.featured-park-media { width: calc(100% + 40px); margin: -18px -20px 0; aspect-ratio: 2.4 / 1; }
.park-card-name { font-family: var(--font-display); font-size: 17.5px; font-weight: 700; line-height: 1.25; }
.park-card-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.park-card-spark { height: 34px; width: 100%; display: block; opacity: 0.9; }
.park-card-metrics {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  padding-top: 12px; border-top: 1px solid var(--border);
}
.metric-k { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.metric-v { font-family: var(--font-mono); font-size: 15px; font-weight: 700; margin-top: 2px; }

/* ---------- Structured Directory Table ---------- */
.dir-box {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
}
.dir-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.dir-row {
  padding: 12px 16px; border-bottom: 1px solid var(--border); border-right: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  transition: background 0.14s;
}
.dir-row:hover { background: var(--surface-hover); }
.park-directory-thumb { flex: 0 0 52px; width: 52px; height: 48px; aspect-ratio: auto; border-radius: 4px; }
.dir-name { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 13.5px; font-weight: 600; }
.dir-region { font-family: var(--font-mono); font-size: 11px; color: var(--muted); }

/* ---------- Park Detail: Sub-Nav, Closed Banner & Bento ---------- */
.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: #94a3b8; margin-bottom: 12px;
}
.breadcrumb a:hover { color: #ffffff; }

.park-header-row {
  display: flex; justify-content: space-between; align-items: flex-end;
  flex-wrap: wrap; gap: 20px;
}
.park-clock-row {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  font-size: 13.5px; color: #cbd5e1; margin-top: 8px;
}
.park-clock-item { display: inline-flex; align-items: center; gap: 6px; }

.park-actions-row { display: flex; gap: 8px; flex-wrap: wrap; }
.btn-ghost-hero {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: 10px; font-size: 13px; font-weight: 600;
  background: rgba(255, 255, 255, 0.08); color: #f8fafc;
  border: 1px solid rgba(255, 255, 255, 0.16);
  cursor: pointer; transition: 0.15s;
}
.btn-ghost-hero:hover { background: rgba(255, 255, 255, 0.15); border-color: rgba(255, 255, 255, 0.3); }

.closed-notice {
  margin-top: 20px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.32);
  border-radius: 12px; padding: 13px 16px;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  color: #fde68a; font-size: 13.5px;
}
.closed-notice-left { display: flex; align-items: center; gap: 10px; }

/* Bento Telemetry Strip */
.bento-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
  margin-top: 22px;
}
@media (max-width: 900px) { .bento-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .bento-grid { grid-template-columns: 1fr; } }

.bento-tile {
  background: rgba(14, 22, 39, 0.82);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius); padding: 16px 18px;
  color: #f8fafc;
}
.bento-tile.surface-solid {
  background: var(--surface); border-color: var(--border); color: var(--text);
}
.bento-kicker {
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; color: #94a3b8;
}
.bento-value {
  font-family: var(--font-display); font-size: 28px; font-weight: 700;
  margin: 6px 0 4px; display: flex; align-items: center; gap: 10px; line-height: 1.1;
}
.bento-sub { font-size: 12px; color: #94a3b8; }
.meter-bar {
  height: 6px; border-radius: 999px; background: rgba(148, 163, 184, 0.2);
  overflow: hidden; margin-top: 10px;
}
.meter-fill { height: 100%; border-radius: 999px; transition: width 0.4s ease; }

/* ---------- Interactive Hourly Chart ---------- */
.chart-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px 22px;
  box-shadow: var(--shadow-card); margin-bottom: 24px;
}
.chart-header {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px; margin-bottom: 14px;
}
.chart-legend { display: flex; align-items: center; gap: 16px; font-size: 12px; color: var(--muted); }
.leg-item { display: inline-flex; align-items: center; gap: 6px; }
.leg-line { width: 16px; height: 2px; display: inline-block; }
.leg-line.solid { background: var(--quietest); height: 3px; }
.leg-line.dashed { border-top: 2px dashed #94a3b8; }
.chart-wrap { position: relative; width: 100%; }
.chart-tooltip {
  position: absolute; pointer-events: none; z-index: 10;
  background: #0c1322; color: #f8fafc; border: 1px solid rgba(255,255,255,0.16);
  border-radius: 9px; padding: 8px 11px; font-size: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.4); white-space: nowrap;
}

/* ---------- Ride Board & Cards ---------- */
.toolbar {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px; margin-bottom: 16px;
}
.toolbar-left, .toolbar-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.input-field {
  height: 38px; padding: 0 12px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text); font-size: 13.5px; outline: none; transition: border-color 0.15s;
}
.input-field:focus { border-color: var(--accent); }
.input-search-wrap { position: relative; display: flex; align-items: center; }
.input-search-wrap svg { position: absolute; left: 11px; color: var(--muted); pointer-events: none; }
.input-search-wrap .input-field { padding-left: 34px; width: 240px; }

.rides-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr)); gap: 12px; }
.ride-card {
  position: relative;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 13px; padding: 15px 16px;
  display: flex; justify-content: space-between; align-items: center; gap: 14px;
  cursor: pointer; transition: border-color 0.16s, transform 0.14s;
}
.ride-card:hover {
  border-color: var(--border-strong); background: var(--surface-hover); transform: translateY(-1px);
}
.ride-card-left { min-width: 0; flex: 1; }
.ride-title {
  font-weight: 600; font-size: 14.5px; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ride-sub-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: 5px; font-size: 12px; color: var(--muted);
}
.trend-chip { display: inline-flex; align-items: center; gap: 3px; font-weight: 600; font-size: 11.5px; }
.trend-chip.down { color: var(--quietest); }
.trend-chip.up { color: var(--busiest); }

.ride-card-right { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.wait-block { text-align: right; min-width: 64px; }
.wait-big {
  font-family: var(--font-mono); font-size: 22px; font-weight: 700; line-height: 1;
}
.wait-unit { font-size: 10.5px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; margin-top: 3px; display: block; }
.wait-closed-box { text-align: right; }
.wait-usual-num { font-family: var(--font-mono); font-size: 14px; font-weight: 700; color: var(--text-soft); }

.ride-actions { display: flex; gap: 5px; }
.act-btn {
  width: 32px; height: 32px; border-radius: 9px;
  border: 1px solid var(--border); background: transparent;
  color: var(--muted); display: grid; place-items: center;
  cursor: pointer; transition: 0.14s;
}
.act-btn:hover { color: var(--text); border-color: var(--border-strong); background: rgba(148,163,184,0.1); }
.act-btn.active { background: rgba(16, 185, 129, 0.16); border-color: rgba(16, 185, 129, 0.45); color: var(--quietest); }
.act-btn.planned { background: rgba(56, 189, 248, 0.16); border-color: rgba(56, 189, 248, 0.45); color: var(--accent); }

/* ---------- True 7-Column Mon–Sun Crowd Calendar ---------- */
.cal-summary-strip {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; margin-bottom: 22px;
}
@media (max-width: 820px) { .cal-summary-strip { grid-template-columns: 1fr; } }
.cal-legend-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 18px; font-size: 12px;
}

.cal-weekdays {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px;
  margin-bottom: 8px;
}
.cal-wd {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--muted); text-align: center; padding: 6px 0;
}
.cal-wd.wknd { color: var(--amber-brand); }

.cal-week-grid {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px;
}
@media (max-width: 900px) {
  .cal-weekdays { display: none; }
  .cal-week-grid { grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)); }
}
.cal-cell-empty {
  background: transparent; border: 1px dashed var(--border);
  border-radius: 12px; min-height: 118px; opacity: 0.35;
}
.cal-cell {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 11px 12px; min-height: 124px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 6px;
  cursor: pointer; transition: transform 0.15s, border-color 0.15s;
}
.cal-cell.wknd { background: rgba(245, 158, 11, 0.03); }
.cal-cell::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--cell-color, var(--closed));
}
.cal-cell:hover, .cal-cell.selected {
  border-color: var(--cell-color, var(--accent));
  transform: translateY(-2px);
}
.cal-cell.best-rank { box-shadow: 0 0 0 1px var(--quietest), 0 8px 20px rgba(16, 185, 129, 0.16); }
.cal-cell-head { display: flex; justify-content: space-between; align-items: center; }
.cal-date-num { font-family: var(--font-mono); font-size: 12px; font-weight: 700; color: var(--text-soft); }
.cal-score-big { font-family: var(--font-display); font-size: 24px; font-weight: 700; line-height: 1.05; }
.cal-meta-row {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 11.5px; color: var(--muted);
}
.cal-wx { display: inline-flex; align-items: center; gap: 4px; }
.cal-hol-tag {
  font-size: 10.5px; font-weight: 600; color: var(--amber-brand);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* ---------- Answer-First Best Day Card ---------- */
.answer-hero {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.14) 0%, var(--surface) 60%);
  border: 1px solid rgba(16, 185, 129, 0.42);
  border-radius: var(--radius-lg); padding: 26px 28px;
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 24px; align-items: center;
  margin: 22px 0;
}
@media (max-width: 820px) { .answer-hero { grid-template-columns: 1fr; } }
.answer-date {
  font-family: var(--font-display); font-size: clamp(26px, 3.6vw, 38px);
  font-weight: 700; letter-spacing: -0.02em; margin: 10px 0 6px;
}
.reason-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.reason-item {
  display: flex; align-items: flex-start; gap: 9px; font-size: 13.5px; color: var(--text-soft);
}
.reason-icon { color: var(--quietest); flex-shrink: 0; margin-top: 2px; }

.compare-box {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 20px; margin-bottom: 22px;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px;
}
.compare-box .tier-pill { max-width: 100%; white-space: normal; }

/* ---------- Slide-Over Drawer ---------- */
.drawer-backdrop {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(2, 6, 14, 0.68); backdrop-filter: blur(4px);
}
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 90;
  width: min(500px, 100vw);
  background: var(--bg-subtle); border-left: 1px solid var(--border-strong);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.5);
  display: flex; flex-direction: column; overflow: hidden;
}
.drawer-head {
  padding: 20px 22px; border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
}
.drawer-body { padding: 20px 22px; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 18px; }
.four-answers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.qa-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 13px 14px;
}
.qa-q { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-family: var(--font-mono); }
.qa-a { font-family: var(--font-display); font-size: 20px; font-weight: 700; margin: 4px 0 2px; }
.qa-note { font-size: 12px; color: var(--muted); }

.slider-box {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 15px 16px;
}
.slider-row { display: flex; align-items: center; gap: 12px; margin: 10px 0 12px; }
.slider-row input[type="range"] { flex: 1; accent-color: var(--quietest); }
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 16px; border-radius: 10px; border: none;
  background: var(--quietest); color: #04130f; font-weight: 700; font-size: 13.5px;
  cursor: pointer; transition: 0.15s;
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 9px 14px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border-strong);
  color: var(--text); font-weight: 600; font-size: 13px; cursor: pointer;
}

/* ---------- Command Search Modal ---------- */
.cmd-modal {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(2, 6, 14, 0.72); backdrop-filter: blur(6px);
  display: flex; align-items: flex-start; justify-content: center; padding-top: 11vh;
}
.cmd-card {
  width: min(600px, 92vw); background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: 16px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.55); overflow: hidden;
}
.cmd-head {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px;
  border-bottom: 1px solid var(--border); color: var(--muted);
}
.cmd-input {
  flex: 1; border: none; background: transparent; color: var(--text);
  font-size: 15.5px; outline: none;
}
.kbd-btn {
  font-family: var(--font-mono); font-size: 11px; padding: 4px 8px;
  border-radius: 6px; border: 1px solid var(--border);
  background: var(--bg-subtle); color: var(--muted); cursor: pointer;
}
.cmd-list { max-height: 360px; overflow-y: auto; }
.cmd-row {
  padding: 11px 16px; display: flex; justify-content: space-between; align-items: center;
  border-bottom: 1px solid var(--border); cursor: pointer; transition: 0.12s;
}
.cmd-row:hover { background: var(--surface-hover); }

/* ---------- Footer & Toast ---------- */
.footer {
  border-top: 1px solid var(--border); padding: 40px 0 52px; margin-top: 56px;
  background: var(--bg-subtle); font-size: 13px;
}
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1.4fr; gap: 28px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-desc { color: var(--muted); max-width: 380px; margin: 10px 0 0; }
.footer-head { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 10px; font-weight: 700; }
.footer-col { display: flex; flex-direction: column; gap: 7px; }
.footer-col a { color: var(--text-soft); }
.footer-col a:hover { color: var(--accent); }
.footer-attr { margin: 0; color: var(--muted); }
.footer-attr a { color: var(--accent); text-decoration: underline; }

.toast {
  position: fixed; bottom: 22px; right: 22px; z-index: 120;
  background: #0c1322; color: #f8fafc;
  border: 1px solid rgba(16, 185, 129, 0.5);
  padding: 11px 16px; border-radius: 11px; font-size: 13px; font-weight: 500;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
}

/* Launch usability: preserve the ticket design on narrow screens. */
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 150; padding: 8px 14px; background: var(--surface); transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.cmd-row, .ac-item { width: 100%; text-align: left; color: var(--text); background: transparent; font: inherit; border: 0; border-bottom: 1px solid var(--border); }
.ac-item { color: var(--ticket-ink); }
.cmd-input { min-width: 0; }
.park-grid { grid-template-columns: repeat(auto-fill, minmax(min(290px, 100%), 1fr)); }
.dir-grid { grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); }
.tier-unknown { background: rgba(100,116,139,.16); color: var(--muted); border: 1px solid var(--border); }
.input-field, .ticket-select, .ticket-input { max-width: 100%; min-width: 0; }
.ticket-segment { min-width: 0; }
.toast { max-width: calc(100vw - 32px); }
.breadcrumb { flex-wrap: wrap; }
@media (max-width: 600px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .hero-banner { padding-top: 36px; }
  .ticket-stub { padding: 14px 16px; }
  .ticket-segment { flex-basis: 100%; padding-right: 0; border-right: 0; }
  .ticket-cta { width: 100%; }
  .ride-card { flex-wrap: wrap; }
  .ride-card-left { flex-basis: 100%; }
  .ride-card-right { width: 100%; justify-content: space-between; }
  .cal-cell-empty { display: none; }
  .cal-week-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chart-card, .answer-hero { padding: 16px; }
  .drawer-head, .drawer-body { padding: 16px; }
  .chart-legend { flex-wrap: wrap; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.language-menu { position: relative; }
.ride-title, .park-card-name, .home-park-choice-name, #app h1, #app h2 { overflow-wrap: anywhere; }
.language-menu summary { list-style: none; cursor: pointer; }
.language-menu summary::-webkit-details-marker { display: none; }
.language-menu summary::after { content: '⌄'; margin-left: 3px; font-size: 12px; }
.language-panel { position: absolute; top: calc(100% + 10px); right: 0; z-index: 100; min-width: 158px; padding: 7px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface, #111925); box-shadow: 0 16px 48px rgba(0,0,0,.3); }
.language-panel a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: 13px; white-space: nowrap; }
.language-panel a:hover, .language-panel a:focus-visible { background: rgba(148,163,184,.12); }
.language-panel a[aria-current] { color: var(--accent); font-weight: 700; background: rgba(56,189,248,.1); }
@media (max-width: 1199px) {
  .language-menu[open] { flex-basis: 100%; grid-column: 1 / -1; }
  .language-menu summary { width: max-content; }
  .language-panel { position: static; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); min-width: 0; margin-top: 8px; box-shadow: none; }
}
