/* ==========================================================================
   YoMetro PWA — App Styles
   Imports shared styles from the main site, then adds app-only layout.
   ========================================================================== */

/* ── Reset & base ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

:root {
  --ym-purple:       #5D4DA8;
  --ym-purple-dark:  #4a3d87;
  --ym-purple-light: #ece9f7;
  --ym-bg:           #f3f6f5;
  --ym-nav-h:        60px;   /* top navbar height */
  --ym-tab-h:        62px;   /* bottom tab bar height */
  --safe-bottom:     env(safe-area-inset-bottom, 0px);
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;           /* app doesn't scroll — screens do */
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--ym-bg);
  -webkit-tap-highlight-color: transparent;
}


/* ── Splash screen ────────────────────────────────────────────────────────── */
#splash {
  position: fixed;
  inset: 0;
  background: var(--ym-purple);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  z-index: 9999;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}
#splash.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
#splash img {
  width: 160px;
  filter: brightness(0) invert(1); /* force white logo on purple bg */
}
#splash .splash-tagline {
  color: rgba(255,255,255,0.75);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
#splash .splash-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }


/* ── App shell layout ─────────────────────────────────────────────────────── */
#app {
  display: flex;
  flex-direction: column;
  height: 100dvh;             /* dynamic viewport height — respects mobile chrome */
  overflow: hidden;
}


/* ── Top navbar ───────────────────────────────────────────────────────────── */
#app-navbar {
  height: var(--ym-nav-h);
  background: #fff;
  border-bottom: 1px solid #ece9f7;
  display: flex;
  align-items: center;
  padding: 0 1rem;
  gap: 0.75rem;
  flex-shrink: 0;
  z-index: 100;
}
#app-navbar .navbar-logo img {
  height: 34px;
  width: auto;
}
#app-navbar .navbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
#app-navbar .nav-icon-btn {
  background: none;
  border: none;
  padding: 6px 8px;
  border-radius: 8px;
  color: #374151;
  font-size: 1.35rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  position: relative;
  transition: background 0.15s;
}
#app-navbar .nav-icon-btn:hover { background: var(--ym-purple-light); }
#app-navbar .nav-icon-btn .badge-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  background: #ef4444;
  border-radius: 50%;
  border: 1.5px solid #fff;
  display: none;
}
#app-navbar .nav-icon-btn .badge-dot.visible { display: block; }

/* Network pill in navbar */
#network-pill {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--ym-purple-light);
  color: var(--ym-purple);
  border: none;
  border-radius: 20px;
  padding: 4px 10px 4px 8px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: background 0.15s;
  margin-left: auto;  /* push to right edge of navbar */
}
#network-pill:hover { background: #ddd8f5; }
#network-pill i { font-size: 0.9rem; flex-shrink: 0; }

/* Refresh button in navbar */
#refresh-btn {
  background: none;
  border: none;
  padding: 6px 8px;
  border-radius: 8px;
  color: #6b7280;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
#refresh-btn:hover { background: var(--ym-purple-light); color: var(--ym-purple); }


/* ── Screen container ─────────────────────────────────────────────────────── */
#screens {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.screen {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: calc(var(--safe-bottom) + 8px);
  display: none;
  background: var(--ym-bg);
}
.screen.active { display: block; }

/* Scrollbar styling inside screens */
.screen::-webkit-scrollbar       { width: 4px; }
.screen::-webkit-scrollbar-thumb { background: #d1d5db; border-radius: 4px; }


/* ── Bottom tab bar ───────────────────────────────────────────────────────── */
#tab-bar {
  height: calc(var(--ym-tab-h) + var(--safe-bottom));
  background: #fff;
  border-top: 1px solid #e9ecef;
  display: flex;
  align-items: stretch;
  flex-shrink: 0;
  z-index: 100;
  padding-bottom: var(--safe-bottom);
}

.tab-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: none;
  background: none;
  color: #9ca3af;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 6px 0;
  transition: color 0.15s;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}
.tab-btn i {
  font-size: 1rem;
  line-height: 1;
  transition: transform 0.15s;
}
.tab-btn.active {
  color: var(--ym-purple);
}
.tab-btn.active i {
  transform: translateY(-1px);
}
/* Active indicator line at top */
.tab-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2.5px;
  background: var(--ym-purple);
  border-radius: 0 0 3px 3px;
  opacity: 0;
  transition: opacity 0.15s;
}
.tab-btn.active::before { opacity: 1; }


/* ── Notification dropdown ────────────────────────────────────────────────── */
#notif-dropdown {
  position: fixed;
  top: calc(var(--ym-nav-h) + 4px);
  right: 8px;
  width: min(320px, calc(100vw - 16px));
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  z-index: 500;
  display: none;
  overflow: hidden;
}
#notif-dropdown.open { display: block; }
#notif-dropdown .notif-header {
  padding: 12px 16px;
  font-weight: 600;
  font-size: 0.9rem;
  border-bottom: 1px solid #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#notif-dropdown .notif-list { max-height: 300px; overflow-y: auto; }
#notif-dropdown .notif-item,
#notif-screen-list .notif-item {
  padding: 14px 1rem;
  border-bottom: 1px solid #f3f4f6;
  font-size: 0.83rem;
  background: #fff;
}
#notif-dropdown .notif-item:last-child,
#notif-screen-list .notif-item:last-child { border-bottom: none; }
#notif-dropdown .notif-empty {
  padding: 20px;
  text-align: center;
  color: #9ca3af;
  font-size: 0.83rem;
}


/* ── Network picker bottom sheet ──────────────────────────────────────────── */
#network-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 400;
  display: none;
  animation: fadeIn 0.2s ease;
}
#network-sheet-backdrop.open { display: block; }

#network-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  border-radius: 20px 20px 0 0;
  z-index: 401;
  padding: 0 0 calc(16px + var(--safe-bottom));
  max-height: 75vh;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}
#network-sheet.open { transform: translateY(0); }

#network-sheet .sheet-handle {
  width: 36px;
  height: 4px;
  background: #e5e7eb;
  border-radius: 2px;
  margin: 10px auto 0;
  flex-shrink: 0;
}
#network-sheet .sheet-title {
  padding: 14px 20px 10px;
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
  border-bottom: 1px solid #f3f4f6;
}
#network-sheet .sheet-list {
  overflow-y: auto;
  flex: 1;
  padding: 8px 0;
}
.network-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  cursor: pointer;
  transition: background 0.12s;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}
.network-item:hover, .network-item:active { background: var(--ym-purple-light); }
.network-item.selected { background: var(--ym-purple-light); }
.network-item .network-icon {
  width: 36px;
  height: 36px;
  background: var(--ym-purple);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1rem;
  flex-shrink: 0;
}
.network-item.selected .network-icon { background: var(--ym-purple-dark); }
.network-item .network-name {
  font-size: 0.92rem;
  font-weight: 500;
  color: #1f2937;
}
.network-item.selected .network-name { color: var(--ym-purple); font-weight: 700; }
.network-item .check-icon {
  margin-left: auto;
  color: var(--ym-purple);
  font-size: 1.1rem;
  display: none;
}
.network-item.selected .check-icon { display: block; }


/* ── HOME screen ──────────────────────────────────────────────────────────── */
.home-hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 60%, #2D2365 100%);
  padding: 1.5rem 1rem 2rem;
  color: #fff;
}
.home-hero h1 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 0 0.3rem;
}
.home-hero p {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.7);
  margin: 0;
}
.home-quick-search {
  margin: -1rem 1rem 0;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 24px rgba(93,77,168,0.13);
  padding: 1rem;
  position: relative;
  z-index: 1;
}

/* Full search card embedded in Home screen (replaces quick-search) */
.home-search-card {
  margin: -1rem 1rem 0;
  position: relative;
  z-index: 1;
}
.home-quick-search .qs-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ym-purple);
  margin-bottom: 0.6rem;
}
.qs-field {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  margin-bottom: 8px;
}
.qs-field:last-of-type { margin-bottom: 0; }
.qs-field:hover { border-color: var(--ym-purple); background: #fff; }
.qs-field i { color: #94a3b8; font-size: 1rem; }
.qs-field span {
  font-size: 0.88rem;
  color: #94a3b8;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.qs-field span.has-value { color: #1f2937; font-weight: 500; }
.qs-divider {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  margin: -4px 0;
  position: relative;
  z-index: 1;
}
.qs-swap-btn,
.metro-swap-btn {
  background: #fff;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ym-purple);
  font-size: 0.9rem;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  transition: background 0.15s, border-color 0.15s;
  flex-shrink: 0;
}
.qs-swap-btn:hover,
.metro-swap-btn:hover { background: var(--ym-purple-light); border-color: var(--ym-purple); }
.qs-find-btn {
  width: 100%;
  background: var(--ym-purple);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 12px;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.15s;
}
.qs-find-btn:hover { background: var(--ym-purple-dark); }

.section-title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b7280;
  padding: 1.25rem 1rem 0.5rem;
}

/* Recent routes */
.recent-route-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 1rem;
  border-bottom: 1px solid #f3f4f6;
  cursor: pointer;
  transition: background 0.12s;
  background: #fff;
}
.recent-route-item:first-child { border-top: 1px solid #f3f4f6; }
.recent-route-item:hover { background: #f9fafb; }
.recent-route-icon {
  width: 34px;
  height: 34px;
  background: var(--ym-purple-light);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ym-purple);
  font-size: 0.9rem;
  flex-shrink: 0;
}
.recent-route-text { flex: 1; min-width: 0; }
.recent-route-text .from-to {
  font-size: 0.85rem;
  font-weight: 500;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.recent-route-text .network {
  font-size: 0.73rem;
  color: #9ca3af;
  margin-top: 1px;
}
.recent-route-item .go-icon { color: #d1d5db; font-size: 0.9rem; }

.empty-state {
  text-align: center;
  padding: 2rem 1rem;
  color: #9ca3af;
}
.empty-state i { font-size: 2.5rem; margin-bottom: 0.5rem; display: block; opacity: 0.4; }
.empty-state p { font-size: 0.85rem; margin: 0; }


/* ── SEARCH screen ────────────────────────────────────────────────────────── */
.search-header {
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 60%, #2D2365 100%);
  padding: 1rem;
}

/* Reuse metro-search-card styles from custom.css — scoped to #screen-search */
#screen-search .metro-search-card {
  margin: 0;
  border-radius: 14px;
  box-shadow: 0 8px 32px rgba(93,77,168,0.13);
}
#screen-search .metro-card-header { padding: 1rem 1.25rem 0.4rem; }
#screen-search .metro-card-body   { padding: 0.6rem 1.25rem 1rem; }
#screen-search .metro-card-footer {
  padding: 0.75rem 1.25rem 1rem;
  border-top: 1px solid #f1f5f9;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}
.metro-info-item {
  font-size: 0.75rem;
  color: #6b7280;
  display: flex;
  align-items: center;
  gap: 4px;
}
.metro-return-link {
  font-size: 0.78rem;
  color: var(--ym-purple);
  text-decoration: none;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}
.btn-metro-find {
  background: var(--ym-purple);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 0.88rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-metro-find:hover { background: var(--ym-purple-dark); color: #fff; }

/* Route result */
#route-result:not(:empty) {
  padding: 0.75rem 0;
}

/* Reuse route-step styles from custom.css */
.route-container { padding: 0 1rem; }
.route-step {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 6px 0;
  border-left: 3px solid #e5e7eb;
  padding-left: 14px;
  margin-left: 6px;
  position: relative;
}
.route-icon {
  position: absolute;
  left: -7px;
  top: 10px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #e5e7eb;
  border: 2px solid #fff;
  flex-shrink: 0;
}
.route-title a {
  font-size: 0.88rem;
  color: #1f2937;
  text-decoration: none;
  font-weight: 500;
}
.route-title a:hover { color: var(--ym-purple); }

/* Fare & timing strip */
.fare-strip {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 0 1rem 1rem;
}
.fare-chip {
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.78rem;
}
.fare-chip .label { color: #9ca3af; display: flex; align-items: center; gap: 4px; margin-bottom: 2px; }
.fare-chip .value { font-weight: 700; font-size: 0.95rem; color: #1f2937; }

/* Route info badges */
.route-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 1rem 0.75rem;
}
.route-badge {
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 0.73rem;
  color: #6b7280;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Section card inside route result */
.result-section {
  background: #fff;
  border-radius: 0;
  margin-bottom: 8px;
}
.result-section-header {
  padding: 10px 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b7280;
  border-bottom: 1px solid #f3f4f6;
}

/* Instruction / change-here boxes */
.route-instruction {
  background: #f8fafc;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 8px 12px;
  margin: 4px 1rem;
  font-size: 0.78rem;
  color: #374151;
}
.route-instruction .label {
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}


/* ── NEARBY screen ────────────────────────────────────────────────────────── */
.nearby-header {
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 60%, #2D2365 100%);
  padding: 1rem;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nearby-header h2 { font-size: 1rem; font-weight: 700; margin: 0; }
.btn-locate {
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.3);
  color: #fff;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.btn-locate:hover { background: rgba(255,255,255,0.25); }

.nearby-station-card {
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
  padding: 12px 1rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  transition: background 0.12s;
}
.nearby-station-card:hover { background: #f9fafb; }
.nearby-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-top: 4px;
  flex-shrink: 0;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1.5px currentColor;
}
.nearby-station-info { flex: 1; min-width: 0; }
.nearby-station-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 2px;
}
.nearby-station-meta { font-size: 0.75rem; color: #9ca3af; }
.nearby-dist {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ym-purple);
  background: var(--ym-purple-light);
  border-radius: 20px;
  padding: 2px 8px;
  white-space: nowrap;
  flex-shrink: 0;
}
.nearby-set-from {
  font-size: 0.68rem;
  color: var(--ym-purple);
  font-weight: 600;
  opacity: 0.75;
  white-space: nowrap;
}

.location-prompt {
  text-align: center;
  padding: 2rem 2rem;
}
.location-prompt i {
  font-size: 2rem;
  color: var(--ym-purple);
  opacity: 0.5;
  display: block;
}
.location-prompt p {
  font-size: 0.88rem;
  color: #6b7280;
  margin-bottom: 1.25rem;
}
.btn-primary-app {
  background: var(--ym-purple);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.btn-primary-app:hover { background: var(--ym-purple-dark); }


/* ── MORE screen ──────────────────────────────────────────────────────────── */
.more-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 1rem;
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
  cursor: pointer;
  transition: background 0.12s;
  text-decoration: none;
  color: inherit;
}
.more-list-item:hover { background: #f9fafb; }
.more-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.more-list-item .more-label { font-size: 0.92rem; font-weight: 500; color: #1f2937; flex: 1; }
.more-list-item .more-arrow { color: #d1d5db; font-size: 0.85rem; }
.more-section-gap { height: 10px; background: var(--ym-bg); }

/* Static page content */
#static-content {
  padding: 1rem;
  font-size: 0.9rem;
  line-height: 1.7;
  color: #374151;
}
#static-content h1, #static-content h2 { color: #1f2937; }

/* Back button */
.screen-back-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 1rem;
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
  position: sticky;
  top: 0;
  z-index: 10;
}
.btn-back {
  background: none;
  border: none;
  padding: 4px 6px;
  border-radius: 8px;
  color: var(--ym-purple);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
}
.screen-back-title {
  font-size: 0.92rem;
  font-weight: 600;
  color: #1f2937;
}


/* ── Loading skeleton ─────────────────────────────────────────────────────── */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.3s infinite;
  border-radius: 6px;
}
@keyframes shimmer { to { background-position: -200% 0; } }

.skeleton-line {
  height: 14px;
  margin-bottom: 8px;
}
.skeleton-line.short { width: 60%; }
.skeleton-line.medium { width: 80%; }


/* ── About section (home screen — first-time users) ───────────────────────── */
.about-section {
  margin: 1rem;
  background: #fff;
  border-radius: 14px;
  padding: 1.25rem;
  box-shadow: 0 2px 12px rgba(93,77,168,0.08);
}
.about-title {
  font-size: 1rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 0.5rem;
}
.about-section > p {
  font-size: 0.83rem;
  color: #6b7280;
  margin-bottom: 1rem;
  line-height: 1.55;
}
.feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 1rem;
}
.feature-item {
  background: var(--ym-bg);
  border-radius: 10px;
  padding: 12px 10px;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
}
.feature-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.feature-text { flex: 1; min-width: 0; }
.feature-item .feature-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: #1f2937;
}
/* .feature-sub and .feature-desc are both used — support both */
.feature-item .feature-sub,
.feature-item .feature-desc {
  font-size: 0.72rem;
  color: #9ca3af;
  line-height: 1.4;
  margin-top: 2px;
}
.start-search-btn {
  width: 100%;
  background: var(--ym-purple);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.start-search-btn:hover { background: var(--ym-purple-dark); }


/* ── Recent routes header ─────────────────────────────────────────────────── */
.recent-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1rem 0.4rem;
}
.recent-header span {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b7280;
}
.clear-recent-btn {
  background: none;
  border: none;
  font-size: 0.75rem;
  color: var(--ym-purple);
  font-weight: 600;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  transition: background 0.12s;
}
.clear-recent-btn:hover { background: var(--ym-purple-light); }


/* ── AdSense slot above tab bar ───────────────────────────────────────────── */
#ad-slot-bar {
  flex-shrink: 0;
  background: #fff;
  border-top: 1px solid #f3f4f6;
  overflow: hidden;
  height: 100px;
  max-height: 100px;
  line-height: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}
#ad-slot-bar ins.adsbygoogle {
  display: block !important;
  width: 320px !important;
  height: 100px !important;
  max-height: 100px !important;
  overflow: hidden !important;
}


/* ── Choices.js remove/cross button fix ───────────────────────────────────── */
.choices__button {
  border-left: 1px solid rgba(255,255,255,0.35) !important;
  padding: 0 6px !important;
  margin-left: 4px !important;
  background-color: transparent !important;
  background-image: none !important;
  color: inherit !important;
  font-size: 0.75rem !important;
  line-height: 1 !important;
  opacity: 0.75;
  cursor: pointer !important;
  border-radius: 0 !important;
}
.choices__button:hover { opacity: 1; }
.choices__item--selectable .choices__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}


/* ── Utility ──────────────────────────────────────────────────────────────── */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.text-purple { color: var(--ym-purple); }
.fw-600 { font-weight: 600; }
.small-text { font-size: 0.8rem; }

/* Hide elements only relevant on the full website */
.website-only { display: none !important; }

/* ── ixigo Banner (Tickets screen) ─────────────────────────────────────────── */
/* Mobile default: show 320x100, hide 728x90 */
.ixigo-banner-mobile  { display: block; border-radius: 8px; max-width: 100%; }
.ixigo-banner-desktop { display: none;  border-radius: 8px; max-width: 100%; }

/* Tablet / desktop (≥768px): show 728x90, hide 320x100 */
@media (min-width: 768px) {
  .ixigo-banner-mobile  { display: none;  }
  .ixigo-banner-desktop { display: block; }
}
