*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html, body {
  min-height: 100%;
  overscroll-behavior-y: contain;
}
body {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
button, a, input, select, textarea {
  touch-action: manipulation;
}

/* Tokens : voir tokens.css (chargé avant style.css). Fallbacks si tokens absents. */
:root {
  --bg:           var(--mz-bg, #f2f2f7);
  --sidebar-bg:   var(--mz-sidebar, #161A22);
  --sidebar-hover:var(--mz-sidebar-hover, #161922);
  --card:         var(--mz-surface, #ffffff);
  --border:       var(--mz-border, rgba(15,17,23,0.08));
  --border-strong:var(--mz-border-strong, rgba(15,17,23,0.14));
  --text:         var(--mz-ink, #161A22);
  --muted:        var(--mz-muted, #636366);
  --hint:         var(--mz-hint, #5C6575);
  --accent:       var(--mz-accent, #ff6a00);
  --accent-light: var(--mz-accent-soft, rgba(255, 106, 0, 0.12));
  --accent-dark:  var(--mz-accent-dark, #b85205);
  --blue:         var(--accent);
  --blue-light:   var(--accent-light);
  --blue-dark:    var(--accent-dark);
  --green:        var(--mz-green, #34c759);
  --green-light:  var(--mz-green-soft, rgba(52, 199, 89, 0.12));
  --amber:        var(--mz-warning, #ff9f0a);
  --amber-light:  var(--mz-warning-soft, rgba(255, 159, 10, 0.14));
  --red:          var(--mz-red, #ff3b30);
  --red-light:    var(--mz-red-soft, rgba(255, 59, 48, 0.12));
  --font:         var(--mz-font, 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif);
  --font-display: var(--mz-font-display, 'Outfit', 'Plus Jakarta Sans', sans-serif);
  --radius:       var(--mz-radius, 16px);
  --radius-sm:    var(--mz-radius-sm, 12px);
  --radius-xs:    var(--mz-radius-xs, 8px);
  --shadow:       var(--mz-shadow, 0 1px 2px rgba(0,0,0,0.04));
  --shadow-md:    var(--mz-shadow-md, 0 4px 16px rgba(0,0,0,0.06));
  --shadow-lg:    var(--mz-shadow-lg, 0 12px 32px rgba(0,0,0,0.10));
}

html, body { height: 100%; font-family: var(--font); }
h1, h2, h3, .brand-name, .welcome h2 { font-family: var(--font-display); }
body { background: var(--bg); color: var(--text); line-height: 1.5; font-size: 14px; }

/* ── Skip link & focus ─────────────────────────────────────────────── */
.skip-link {
  position: absolute; top: -100px; left: 16px; z-index: 2000;
  padding: 10px 16px; border-radius: var(--radius-xs);
  background: var(--blue); color: var(--mz-on-accent, #161A22); font-weight: 600; font-size: 13px;
  text-decoration: none; box-shadow: var(--shadow-lg);
  transition: top .2s;
}
.skip-link:focus { top: 12px; outline: none; }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
:root.dark :focus-visible { outline-color: #ffb787; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── Layout ──────────────────────────────────────────────────────────── */
.layout { display: flex; height: 100vh; overflow: hidden; }
/* /app : le shell 100vh clipait les cartes résultats sous le formulaire. */
body.app-shell {
  height: auto !important;
  max-height: none !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
}
body.app-shell .layout,
body.app-shell .layout.mz-app-frame {
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}
body.app-shell .sidebar,
body.app-shell .sidebar-scroll,
body.app-shell .main,
body.app-shell #mainContent {
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}
body.app-shell.has-results .main,
body.app-shell.has-results #mainContent {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  min-height: 58vh !important;
}
/* Mobile only : le chip replie le formulaire. Sur desktop le dock/CTA
   restait dans un overflow:hidden plus large que le bouton — Playwright
   et les clics tombaient alors sur #sidebarDock au lieu de #daySearchBtn. */
@media (max-width: 700px) {
  body.app-shell.has-results:not(.search-form-open) .sidebar,
  body.app-shell.has-results:not(.search-form-open) .sidebar-scroll {
    max-height: none !important;
    overflow: visible !important;
  }
}

/* ── Sidebar ─────────────────────────────────────────────────────────── */
.sidebar {
  width: 300px; min-width: 300px;
  background: var(--sidebar-bg);
  color: #e5e7eb;
  display: flex; flex-direction: column;
  overflow: hidden;
  border-right: 1px solid rgba(255,255,255,0.06);
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
}

/* Brand / compte : restent visibles en scrollant */
.sidebar-header {
  flex: 0 0 auto;
  z-index: 3;
  padding: 16px 16px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(12, 14, 20, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.sidebar-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  padding: 4px 0 12px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.18) transparent;
}

.sidebar-block {
  margin: 8px 12px;
  padding: 12px 12px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.035);
  border: 1px solid rgba(255,255,255,0.06);
}

.sidebar-block + .sidebar-block { margin-top: 10px; }

/* CTA recherche + alerte : ancrés en bas */
.sidebar-dock {
  flex: 0 0 auto;
  z-index: 3;
  padding: 10px 12px calc(12px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(255,255,255,0.08);
  background: rgba(12, 14, 20, 0.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 -8px 24px rgba(0,0,0,0.25);
}
/* Mobile maquette : le dock ne doit jamais rester quasi-noir (bande sous les CTA). */
@media (max-width: 700px) {
  body.app-shell .sidebar-dock {
    background: var(--mz-surface, #fff) !important;
    border-top-color: var(--mz-border-strong, rgba(22,26,34,.14));
    box-shadow: none;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}
.sidebar-dock .day-search-hint {
  margin: 0 0 8px;
  font-size: 11px;
  color: #C4A990;
  line-height: 1.35;
}
.sidebar-dock .day-search-btn {
  width: 100%;
  margin: 0;
}
.sidebar-dock-row {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.sidebar-dock-row .alert-create-btn {
  flex: 1;
  margin: 0;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 12px; text-decoration: none; color: inherit;
}
.brand-mark {
  display: block;
  width: 32px; height: 32px; flex-shrink: 0;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 2px 10px rgba(255, 106, 0, 0.35);
}
.brand-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.brand-name { font-size: 15px; font-weight: 700; color: #f5f5f7; letter-spacing: -.02em; line-height: 1.15; }
.brand-sub { font-size: 11px; color: #8e8e93; font-weight: 500; letter-spacing: 0; }

.browser-status {
  display: inline-flex; align-items: center; gap: 4px;
  margin-top: 10px; padding: 3px 9px; border-radius: 99px;
  font-size: 10px; font-weight: 600; letter-spacing: .02em;
  border: 1px solid transparent; cursor: pointer;
  transition: opacity .15s, transform .1s;
}
.browser-status:hover { opacity: .85; transform: scale(1.02); }
.browser-status.ready  { background: rgba(22,163,74,.15); color: #86efac; border-color: rgba(22,163,74,.35); }
.browser-status.pending { background: rgba(217,119,6,.12); color: #fcd34d; border-color: rgba(217,119,6,.25); }
.browser-status.error  { background: rgba(220,38,38,.12); color: #fca5a5; border-color: rgba(220,38,38,.25); }

.section-label {
  font-size: 11px; font-weight: 700;
  letter-spacing: -0.01em; color: rgba(243,244,246,0.55);
  padding: 12px 16px 6px;
  text-transform: none;
}
.sidebar-block > .section-label:first-child {
  padding: 0 0 8px;
  color: #f5f5f7;
  font-size: 13px;
}


.gare-group {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-height: none;
  overflow: visible;
}
.city-btn, .gare-btn {
  border-radius: 12px;
  border: 1px solid transparent;
  background: rgba(255,255,255,0.04);
}
.city-btn:hover, .gare-btn:hover {
  background: rgba(255,255,255,0.08);
}
.city-btn.orig, .city-btn.dest, .gare-btn.selected {
  border-color: rgba(255,106,0,0.45);
  background: rgba(255,106,0,0.16);
}

.city-btn {
  min-height: 44px;
  padding: 8px 12px;
}
.more-cities .all-stations-list {
  max-height: 240px;
}

/* ── Station search / autocomplete ───────────────────────────────── */
.station-search-wrap {
  position: relative;
  padding: 0 0 8px;
}
.sidebar-block .station-search-wrap { padding: 0 0 8px; }
.sidebar-scroll > .station-search-wrap,
.sidebar-block + .station-search-wrap { padding-left: 16px; padding-right: 16px; }
#sidebarRouteBlock .station-search-wrap { padding-left: 0; padding-right: 0; }
#sidebarRouteBlock .gare-group { padding: 0; }
#sidebarRouteBlock .section-label { padding-left: 0; padding-right: 0; }

.station-search-input {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(0,0,0,0.25);
  color: #e5e7eb;
  font-size: 12.5px;
  outline: none;
}
.place-search-bar .place-search-field {
  position: relative;
  display: flex;
  align-items: center;
}
.place-search-bar .station-search-input {
  padding-right: 44px;
  border-radius: 999px;
  font-size: 13.5px;
  padding-top: 11px;
  padding-bottom: 11px;
}
.place-search-go {
  position: absolute;
  right: 5px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #1C1008);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.place-search-go:hover { filter: brightness(1.08); }
.place-geo-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 8px 2px 2px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--mz-accent-text, #B34700);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.place-geo-btn:disabled { opacity: 0.55; cursor: wait; }
.place-geo-btn svg { flex-shrink: 0; }

.station-suggest-item.has-thumb {
  flex-direction: row;
  align-items: center;
  gap: 10px;
}
.station-suggest-item .suggest-thumb {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  overflow: hidden;
  background: #1f2937;
}
.station-suggest-item .suggest-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.station-suggest-item .suggest-thumb-fallback {
  background: linear-gradient(135deg, #374151, #111827);
}
.station-suggest-item .suggest-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.station-suggest-item .suggest-kind {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--mz-muted, #5B6578);
  text-transform: uppercase;
  margin-bottom: 1px;
}
.station-suggest-item.is-place strong { font-weight: 600; }

.station-search-input:focus {
  border-color: transparent;
  box-shadow: none;
  outline: none;
}
.station-search-input::placeholder { color: var(--mz-placeholder, #5C6575); opacity: 1; }
.station-suggest {
  position: absolute;
  z-index: 40;
  left: 0;
  right: 0;
  top: 100%;
  margin-top: 4px;
  max-height: min(50dvh, 420px);
  overflow-y: auto;
  background: var(--mz-surface, #fff);
  border: 1px solid var(--mz-border, rgba(15, 23, 42, 0.16));
  border-radius: var(--radius-sm);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
}
.station-suggest.hidden { display: none; }
.station-suggest-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  text-align: left;
  padding: 9px 11px;
  border: 0;
  background: transparent;
  color: var(--mz-ink, #0F172A);
  cursor: pointer;
  border-bottom: 1px solid var(--mz-border, rgba(15, 23, 42, 0.08));
}
.station-suggest-item:last-child { border-bottom: 0; }
.station-suggest-item:hover,
.station-suggest-item:focus {
  background: color-mix(in srgb, var(--mz-accent, #FF6A00) 14%, var(--mz-surface, #fff));
  color: var(--mz-ink, #0F172A);
}
.station-suggest-item strong { font-size: 14px; font-weight: 600; color: var(--mz-ink, #0F172A); }
.station-suggest-item small { font-size: 12px; color: var(--mz-muted, #5B6578); }
.station-suggest-item.muted {
  cursor: default;
  color: var(--mz-muted, #5B6578);
  font-size: 12px;
}
.station-suggest-item.muted:hover { background: transparent; color: var(--mz-muted, #5B6578); }
.gare-group .city-btn[data-city^="STN_"] .gare-icon { filter: grayscale(0.2); }


.city-group { display: flex; flex-direction: column; gap: 1px; margin-bottom: 2px; }
.city-label {
  font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .09em;
  color: #374151; padding: 7px 11px 3px; user-select: none;
}

/* ── City buttons (replaces individual station buttons) ──────────────── */
.city-btn {
  display: flex; align-items: center; gap: 11px;
  width: 100%; min-height: 44px; padding: 8px 12px; border-radius: var(--radius-sm);
  border: 1px solid transparent; background: transparent;
  cursor: pointer; color: #D0B79E; text-align: left;
  transition: background .15s, color .15s, border-color .15s;
}
.city-btn:hover { background: rgba(255,255,255,0.06); color: #f3f4f6; }
.city-btn.orig {
  background: rgba(255,106,0,0.15); border-color: rgba(255,106,0,0.40); color: #ffb787;
}
.city-btn.dest {
  background: rgba(22,163,74,0.15); border-color: rgba(22,163,74,0.40); color: #86efac;
}
.city-btn.same-as-other { opacity: .25; pointer-events: none; }
.city-btn .gare-text strong { font-size: 13px; font-weight: 600; }
.city-btn .gare-text small  { font-size: 10px; color: #C4A990; }
.city-btn.orig .gare-text small,
.city-btn.dest .gare-text small { color: inherit; opacity: .65; }

.gare-btn {
  display: flex; align-items: center; gap: 10px;
  width: 100%; padding: 9px 11px; border-radius: var(--radius-sm);
  border: 1px solid transparent; background: transparent;
  cursor: pointer; color: #D0B79E; text-align: left;
  transition: background .15s, color .15s, border-color .15s;
}
.gare-btn:hover { background: rgba(255,255,255,0.05); color: #f3f4f6; }
.gare-btn.orig {
  background: rgba(255,106,0,0.15);
  border-color: rgba(255,106,0,0.40);
  color: #ffb787;
}
.gare-btn.dest {
  background: rgba(22,163,74,0.15);
  border-color: rgba(22,163,74,0.40);
  color: #86efac;
}
.gare-btn.same-as-other { opacity: .25; pointer-events: none; }
.gare-icon { font-size: 15px; flex-shrink: 0; width: 20px; text-align: center; }
.gare-text { display: flex; flex-direction: column; gap: 1px; }
.gare-text strong { font-size: 12px; font-weight: 500; line-height: 1.2; }
.gare-text small  { font-size: 10px; color: #C4A990; }
.gare-btn.orig .gare-text small,
.gare-btn.dest .gare-text small { color: inherit; opacity: .65; }

.swap-row { display: flex; align-items: center; gap: 8px; padding: 8px 18px; }
.swap-line { flex: 1; border: none; border-top: 1px solid rgba(255,255,255,0.05); }
.swap-btn {
  width: 44px; height: 44px; min-width: 44px; min-height: 44px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.09);
  background: rgba(255,255,255,0.04); color: #6b7280;
  cursor: pointer; font-size: 15px;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s, transform .2s;
}
.swap-btn:hover { background: rgba(255,255,255,0.09); color: #f9fafb; transform: rotate(180deg); }

.sidebar-footer { margin-top: 8px; padding: 0; }
.sidebar-advanced {
  margin: 8px 12px 4px;
  padding: 0 4px;
  border: none;
  background: transparent;
}
.sidebar-advanced summary {
  font-size: 12px;
  color: rgba(243,244,246,0.5);
  cursor: pointer;
  list-style: none;
}
.sidebar-advanced summary::-webkit-details-marker { display: none; }
.sidebar-legal {
  margin: 10px 4px 4px;
  font-size: 11px;
  line-height: 1.45;
  color: #C4A990; /* AA sur sidebar sombre */
}
.sidebar-legal a { color: #FFB787; text-decoration: underline; text-underline-offset: 2px; }
.sidebar-legal a:hover { color: #FFF8F3; }

/* ── Day search (sidebar) ───────────────────────────────────────────── */
.day-search {
  /* hérite de .sidebar-block — plus de double cadre */
  padding: 12px;
  margin: 8px 12px;
}
.day-search .section-label {
  color: #f5f5f7;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: none;
  margin: 0 0 10px;
  padding: 0;
}
.trip-type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 0 0 6px;
}
.trip-type-btn {
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 10px 8px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.08);
  color: rgba(243,244,246,0.7);
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.trip-type-btn:hover {
  color: #fff;
  border-color: rgba(255,255,255,0.28);
}
.trip-type-btn.active {
  color: #fff;
  background: rgba(255,106,0,0.32);
  border-color: rgba(255,106,0,0.65);
  box-shadow: 0 0 0 1px rgba(255,106,0,0.25);
}
.trip-type-hint {
  font-size: 10px;
  color: rgba(243,244,246,0.42);
  margin: 0 0 10px;
  line-height: 1.35;
}
.time-window-toggle {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 5px;
  margin: 0 0 10px;
}
.time-window-btn {
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 8px 4px;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,0.16);
  background: rgba(255,255,255,0.07);
  color: rgba(243,244,246,0.72);
  cursor: pointer;
}
.time-window-btn.active {
  color: #fff;
  background: rgba(255,106,0,0.28);
  border-color: rgba(255,106,0,0.6);
}
.results-freshness {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--muted, #5a6572);
}
#resultsFreshness.mz-freshness,
#calendarFreshness.mz-freshness {
  margin: 0 0 12px;
}
.smc-often {
  display: block;
  font-size: 9px;
  font-weight: 700;
  color: #0f766e;
  letter-spacing: -0.01em;
}
.lg-often {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #0f766e;
  margin-right: 4px;
}
.freshness-banner.is-stale,
.freshness-banner[data-stale="1"] {
  background: rgba(245, 158, 11, .14);
  color: #92400e;
}
.date-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 0 0 6px;
}
.date-preset-btn {
  font: inherit;
  font-size: 10px;
  font-weight: 700;
  padding: 5px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255,106,0,0.4);
  background: rgba(255,106,0,0.14);
  color: #ffb070;
  cursor: pointer;
  white-space: nowrap;
}
.date-preset-btn:hover { background: rgba(255,106,0,0.28); color: var(--mz-on-accent, #1C1008); }
.date-preset-btn.accent {
  border-color: rgba(214, 254, 80, 0.55);
  background: rgba(214, 254, 80, 0.18);
  color: #e8ff8a;
}
.date-preset-btn.accent:hover {
  background: rgba(214, 254, 80, 0.32);
  color: var(--mz-on-accent, #1C1008);
}
.date-preset-btn.ghost {
  border-color: rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.06);
  color: rgba(243,244,246,0.65);
}
.date-leg-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 0 0 8px;
}
.date-leg-toggle[hidden] { display: none !important; }
.date-leg-btn {
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 8px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.16);
  background: rgba(255,255,255,0.06);
  color: rgba(243,244,246,0.65);
  cursor: pointer;
}
.date-leg-btn.active {
  color: #fff;
  background: rgba(255,106,0,0.32);
  border-color: rgba(255,106,0,0.65);
}
.date-leg-btn#dateLegRetBtn.active {
  background: rgba(56,189,248,0.28);
  border-color: rgba(56,189,248,0.65);
}
.date-pick-hint {
  font-size: 10px;
  color: rgba(243,244,246,0.45);
  margin: 0 0 8px;
  line-height: 1.35;
}
.day-chips-label {
  flex: 0 0 100%;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: rgba(255,176,112,0.9);
  margin: 2px 0;
}
.day-chips-label.return { color: rgba(125,211,252,0.95); }
.via-block {
  padding: 8px 0 0;
  margin: 0;
  border: none;
  background: transparent;
}
.sidebar-block .via-block { padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.06); margin-top: 10px; }

.via-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.via-add-btn {
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,106,0,0.45);
  background: rgba(255,106,0,0.18);
  color: #ffb37a;
  cursor: pointer;
  white-space: nowrap;
}
.via-add-btn:hover { background: rgba(255,106,0,0.28); color: var(--mz-on-accent, #1C1008); }
.via-hint {
  font-size: 11px;
  color: #C4A990;
  margin: 0 0 8px;
  line-height: 1.35;
}
.via-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 6px;
  min-height: 0;
}
.via-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 8px 5px 10px;
  border-radius: 999px;
  background: rgba(56,189,248,0.14);
  border: 1px solid rgba(56,189,248,0.4);
  color: #7dd3fc;
}
.via-chip-n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  font-size: 10px;
  font-weight: 800;
  background: rgba(56,189,248,0.28);
  color: #e0f2fe;
}
.via-chip-remove {
  font: inherit;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  padding: 0 2px;
  opacity: 0.75;
  line-height: 1;
}
.via-chip-remove:hover { opacity: 1; }
.via-search-wrap { margin-top: 4px; }
.day-leg-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(243,244,246,0.55);
  margin: 2px 0 6px;
}
.return-date-block { margin-top: 4px; }
.day-search-input {
  width: 100%; padding: 9px 11px; border-radius: var(--radius-xs);
  border: 1px solid rgba(255,255,255,0.12); background: rgba(255,255,255,0.06);
  color: #f3f4f6; font-size: 13px; font-family: inherit; margin-bottom: 7px;
}
.day-search-input:focus { outline: none; border-color: rgba(255,106,0,0.5); }
.day-search-btn {
  width: 100%; padding: 9px 12px; border-radius: var(--radius-xs); border: none;
  background: rgba(255,106,0,0.85); color: var(--mz-on-accent, #1C1008); font-size: 12px; font-weight: 600;
  cursor: pointer; font-family: inherit; transition: background .15s;
}
.day-search-btn:hover:not(:disabled) { background: var(--blue); }
.day-search-btn:disabled { opacity: 1; color: var(--mz-ink, #1C1008); background: rgba(255,106,0,.22); cursor: wait; }
.day-search-hint, .sidebar .day-search-hint { font-size: 11px; color: #C4A990 !important; margin-top: 6px; line-height: 1.4; }
.sidebar-dock .day-search-hint { font-size: 12px; color: #5C6575 !important; margin-top: 6px; line-height: 1.4; }
.day-search-hint.is-blocking,
.sidebar-dock .day-search-hint.is-blocking {
  color: var(--mz-ink, #1C1008) !important;
  font-weight: 650;
}
.day-search-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.day-search-cta-actions[hidden] { display: none !important; }
.day-search-cta-actions .mz-btn {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}
.day-chip.return-chip { border-color: rgba(56,189,248,0.45); background: rgba(56,189,248,0.12); }
.cal-day.return-picked { box-shadow: inset 0 0 0 2px rgba(56,189,248,0.55); }
.smc-day.return-picked { box-shadow: inset 0 0 0 2px rgba(56,189,248,0.55); }
.leg-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  margin-left: 8px;
  vertical-align: middle;
}
.leg-badge.out { background: rgba(255,106,0,0.15); color: var(--accent, #ff6a00); }
.leg-badge.return { background: rgba(56,189,248,0.15); color: #0284c7; }

.load-row { display: flex; gap: 7px; align-items: stretch; }

.load-btn {
  flex: 1;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 16px;
  background: var(--blue); color: var(--mz-on-accent, #161A22);
  border: none; border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: background .15s, transform .1s, box-shadow .15s;
  box-shadow: 0 2px 8px rgba(255,106,0,.3);
}
.load-btn:hover:not(:disabled) { background: var(--mz-accent-press, #E55F00); box-shadow: 0 4px 12px rgba(255,106,0,.4); }
.load-btn:active:not(:disabled) { transform: scale(.98); }
.load-btn:disabled { opacity: 1; color: var(--mz-ink, #1C1008); background: rgba(255,106,0,.22); cursor: not-allowed; box-shadow: none; }
.load-btn.loading { background: #1e2535; box-shadow: none; }
.load-icon { font-size: 14px; }

.alert-create-btn {
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.10);
  color: #9ca3af; border-radius: var(--radius-sm); padding: 0 14px;
  font-size: 17px; cursor: pointer; flex-shrink: 0; transition: background .15s, color .15s;
}
.alert-create-btn:hover { background: rgba(255,255,255,0.12); color: #f3f4f6; }

.progress-wrap { padding: 12px 2px 0; }
.progress-track-row { display: flex; align-items: center; gap: 8px; }
.progress-track {
  flex: 1; height: 4px;
  background: rgba(255,255,255,0.08); border-radius: 2px; overflow: hidden;
}
.progress-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--blue), #ff8a3d);
  border-radius: 2px; transition: width .3s ease;
}
.progress-pct {
  font-size: 11px; font-weight: 600; color: #4b5563;
  min-width: 30px; text-align: right; font-variant-numeric: tabular-nums;
}
.progress-info-row {
  display: flex; align-items: center; justify-content: space-between; margin-top: 6px;
}
.progress-label {
  font-size: 10px; color: #4b5563;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 190px;
}
.cancel-btn {
  background: none; border: none; color: #374151; font-size: 13px;
  padding: 1px 4px; cursor: pointer; border-radius: 3px;
  transition: color .12s, background .12s; display: none; flex-shrink: 0;
}
.cancel-btn:hover { color: #d1d5db; background: rgba(255,255,255,0.06); }

.quota-bar {
  margin-top: 10px;
  padding: 10px 10px 8px;
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
}
.quota-bar-top, .quota-bar-bottom {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
  color: #6b7280;
}
.quota-bar-title { font-weight: 600; color: #D0B79E; }
.quota-bar-meta { font-variant-numeric: tabular-nums; }
.quota-track {
  margin: 6px 0;
  height: 5px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  overflow: hidden;
}
.quota-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ff6a00, #f59e0b);
  transition: width .35s ease, background .2s;
}
.quota-fill.warn { background: linear-gradient(90deg, #ea580c, #ef4444); }
.quota-fill.crit { background: linear-gradient(90deg, #dc2626, #b91c1c); }
.quota-bar-bottom { margin-top: 2px; font-variant-numeric: tabular-nums; }
.plan-usage-reset {
  margin-top: 6px;
  font-size: 0.75rem;
  color: #9ca3af;
  font-variant-numeric: tabular-nums;
}

/* ── Main ────────────────────────────────────────────────────────────── */
.main { flex: 1; overflow-y: auto; padding: 28px 28px 80px; scroll-behavior: smooth; }

/* ── Welcome ─────────────────────────────────────────────────────────── */
.welcome { max-width: 520px; margin: 80px auto; text-align: center; }
.welcome-icon { font-size: 48px; margin-bottom: 18px; }
.welcome h2 { font-size: 22px; font-weight: 700; margin-bottom: 8px; letter-spacing: -.02em; }
.welcome p { color: var(--muted); font-size: 14px; line-height: 1.65; margin-bottom: 30px; }
.welcome kbd {
  display: inline-block; padding: 2px 7px; border-radius: 5px;
  background: var(--card); border: 1px solid var(--border-strong);
  font-size: 12px; font-family: inherit; font-weight: 600;
}
.welcome-status {
  display: inline-block; margin-bottom: 24px; padding: 6px 14px;
  border-radius: 99px; font-size: 12px; font-weight: 600;
}
.welcome-status.ready { background: var(--green-light); color: #166534; }
.welcome-status.pending { background: var(--amber-light); color: #92400e; }
.welcome-status.error { background: var(--red-light); color: #991b1b; }
.welcome-status-hint {
  font-size: 12px; color: var(--muted); line-height: 1.55;
  max-width: 420px; margin: -12px auto 24px; padding: 0 8px;
}
.welcome-status-hint code {
  font-size: 11px; background: rgba(0,0,0,.06); padding: 1px 5px; border-radius: 4px;
}
:root.dark .welcome-status-hint code { background: rgba(255,255,255,.08); }
:root.dark .welcome-status.ready { background: #14352a; color: #86efac; }
:root.dark .welcome-status.pending { background: #422006; color: #fcd34d; }
:root.dark .welcome-status.error { background: #3b1010; color: #fca5a5; }
.feature-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; text-align: left; }
.feature-card {
  display: flex; align-items: flex-start; gap: 11px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px 15px;
  font-size: 12px; color: var(--muted); line-height: 1.5;
  box-shadow: var(--shadow);
  transition: box-shadow .15s, border-color .15s;
}
.feature-card:hover { box-shadow: var(--shadow-md); border-color: rgba(0,0,0,.12); }
.feature-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.feature-card strong { color: var(--text); display: block; margin-bottom: 2px; font-weight: 600; font-size: 13px; }
.feature-card small { font-size: 11px; }

/* ── Route header ────────────────────────────────────────────────────── */
.route-header {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 20px;
  margin-bottom: 18px; box-shadow: var(--shadow);
}
.rh-orig  { font-weight: 700; color: var(--blue); font-size: 15px; }
.rh-dest  { font-weight: 700; color: var(--green); font-size: 15px; }
.rh-arrow { color: var(--hint); font-size: 18px; }
.rh-badges { margin-left: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.rh-badge {
  padding: 3px 10px; border-radius: 20px;
  font-size: 11px; font-weight: 600;
}
.rh-badge.direct  { background: var(--green-light);  color: var(--green); }
.rh-badge.corresp { background: var(--amber-light);  color: var(--amber); }
.rh-badge.cached  { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
.rh-badge.multi   { background: var(--mz-accent-soft, rgba(255,106,0,.12)); color: var(--mz-ink); }

/* ── Metrics ─────────────────────────────────────────────────────────── */
.metrics { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; margin-bottom: 18px; }
.metric {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 15px 17px;
  box-shadow: var(--shadow);
}
.metric-label { font-size: 11px; color: var(--muted); margin-bottom: 7px; font-weight: 500; }
.metric-value { font-size: 24px; font-weight: 800; line-height: 1; letter-spacing: -.02em; }
.metric-denom { font-size: 14px; font-weight: 400; color: var(--hint); }
.metric-best { font-size: 18px; }
.metric-day-name { font-size: 12px; font-weight: 400; color: var(--hint); }
.metrics-placeholder {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px 18px;
  margin-bottom: 18px; text-align: center;
}
.metrics-hint { font-size: 12px; color: var(--hint); }

/* ── Pair tabs (multi-station options within a city pair) ────────────── */
.pair-tabs {
  display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px;
}
.pair-tab {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 13px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--card);
  cursor: pointer; font-size: 12px; font-weight: 500; color: var(--muted);
  transition: border-color .15s, background .15s, color .15s;
  box-shadow: var(--shadow);
}
.pair-tab:hover { border-color: var(--blue); color: var(--text); }
.pair-tab.active {
  border-color: var(--blue); background: var(--blue-light);
  color: var(--blue); font-weight: 600;
}
.pt-stations { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
.pt-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.pt-dot.loaded { background: var(--green); }

.pair-subtitle {
  font-size: 12px; color: var(--muted); margin: -10px 0 14px;
  padding: 0 2px;
}

/* ── Calendar ────────────────────────────────────────────────────────── */
.cal-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
  margin-bottom: 18px; box-shadow: var(--shadow);
}
.cal-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 12px; flex-wrap: wrap; }
.cal-title { font-size: 13px; font-weight: 700; letter-spacing: -.01em; }
.cal-legend { display: flex; gap: 14px; font-size: 11px; color: var(--muted); align-items: center; flex-wrap: wrap; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 4px; vertical-align: middle; }

.cal-grid { display: grid; grid-template-columns: repeat(7,1fr); gap: 5px; }
.cal-hdr {
  font-size: 10px; font-weight: 700; color: var(--hint);
  text-align: center; padding: 4px 0; text-transform: uppercase; letter-spacing: .06em;
}
.cal-hdr.sat { color: #3b82f6; }
.cal-hdr.sun { color: #ef4444; }

.cal-day {
  min-height: 62px; border: 1px solid var(--border);
  border-radius: var(--radius-xs); padding: 6px 7px;
  cursor: pointer; background: var(--mz-surface, #fff);
  color: var(--mz-ink);
  transition: border-color .15s, box-shadow .15s, transform .1s, background .15s;
  user-select: none;
}
.cal-day:hover:not(.empty):not(.unavailable):not(.not-loaded) {
  border-color: var(--blue); transform: translateY(-2px); box-shadow: var(--shadow-md);
}
.cal-day.empty      { background: none; border: none; cursor: default; }
.cal-day.selected   { border: 2px solid var(--blue) !important; box-shadow: 0 0 0 3px rgba(255,106,0,.12); }
.cal-day.unavailable{ opacity: .35; cursor: default; }
.cal-day.not-loaded { cursor: default; }
.cal-day .d-num  { font-size: 10px; color: var(--mz-ink-2, #374151); font-weight: 700; display: flex; align-items: baseline; gap: 3px; }
.cal-day .d-wday { font-size: 9px; color: var(--mz-muted, #5C6575); font-weight: 400; }
.cal-day .d-places { font-size: 16px; font-weight: 800; line-height: 1.3; margin-top: 4px; letter-spacing: -.02em; color: inherit; }
.cal-day .d-trains  { font-size: 10px; color: var(--muted); }
.cal-day .d-zero    { font-size: 12px; color: var(--mz-hint, #8B93A1); margin-top: 6px; }
.cal-day .d-empty   { font-size: 12px; color: var(--mz-hint, #8B93A1); margin-top: 7px; }
.cal-day.skeleton {
  background: linear-gradient(90deg, var(--mz-skeleton-base, #f3f4f6) 25%, var(--mz-skeleton-shine, #eaebee) 50%, var(--mz-skeleton-base, #f3f4f6) 75%);
  background-size: 200% 100%;
  border-color: transparent; cursor: default;
  animation: shimmer 1.6s ease-in-out infinite;
}
.cal-day.skeleton:hover { transform: none; box-shadow: none; border-color: transparent; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.cal-no-data { text-align: center; padding: 28px; color: var(--hint); font-size: 12px; margin-top: 4px; }

/* ── Day detail ──────────────────────────────────────────────────────── */
.detail-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  margin-bottom: 18px; box-shadow: var(--shadow);
  animation: slideDown .15s ease;
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

.detail-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 18px; background: var(--bg);
  border-bottom: 1px solid var(--border); gap: 8px;
}
.detail-title { font-size: 13px; font-weight: 600; flex: 1; letter-spacing: -.01em; }
.close-btn {
  background: none; border: none; cursor: pointer;
  color: var(--hint); font-size: 16px; line-height: 1;
  padding: 3px 7px; border-radius: 5px;
  transition: color .12s, background .12s; flex-shrink: 0;
}
.close-btn:hover { color: var(--text); background: rgba(0,0,0,0.06); }

.train-row {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 18px; border-bottom: 1px solid var(--border);
  font-size: 13px; transition: background .1s;
}
.train-row:last-child { border-bottom: none; }
.train-row:hover { background: #fafafa; }
.t-time { display: flex; align-items: center; gap: 7px; min-width: 115px; }
.t-dep   { font-weight: 800; font-size: 16px; color: var(--text); letter-spacing: -.02em; }
.t-arrow { color: var(--hint); font-size: 11px; }
.t-arr   { font-weight: 500; font-size: 15px; color: var(--muted); }
.t-dur   { font-size: 11px; color: var(--hint); background: #f3f4f6; padding: 2px 8px; border-radius: 5px; white-space: nowrap; }
.t-type  { padding: 3px 9px; border-radius: 10px; font-size: 11px; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }
.type-inoui, .type-tgv-inoui { background: var(--blue-light); color: var(--blue); }
.type-ouigo { background: var(--green-light); color: var(--green); }
.type-tgv   { background: var(--blue-light); color: var(--blue); }
.type-intn  { background: #1e1b4b; color: #a5b4fc; }
.t-num   { font-size: 11px; color: var(--hint); white-space: nowrap; }
.t-places { padding: 3px 11px; border-radius: 10px; font-size: 12px; font-weight: 700; white-space: nowrap; margin-left: auto; }
.t-pair-label {
  font-size: 11px; color: var(--muted); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; max-width: 180px; flex: 1;
}

/* ── Correspondance options strip (in unified day detail) ────────────── */
.corresp-options {
  border-top: 1px solid var(--border); padding: 10px 14px;
  display: flex; flex-direction: column; gap: 6px;
}
.corresp-option-row {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px; padding: 6px 4px;
}
.co-icon  { font-size: 15px; flex-shrink: 0; }
.co-label { flex: 1; color: var(--text); font-weight: 500; }
.co-badge {
  font-size: 10px; font-weight: 600; padding: 2px 8px;
  border-radius: 99px; background: var(--amber-light); color: var(--amber);
}

/* ── Correspondence ──────────────────────────────────────────────────── */
.corresp-banner {
  background: var(--amber-light); border: 1px solid rgba(217,119,6,.18);
  border-radius: var(--radius); padding: 14px 18px; margin-bottom: 18px;
  display: flex; align-items: flex-start; gap: 13px;
}
.corresp-banner-icon { font-size: 19px; flex-shrink: 0; margin-top: 1px; }
.corresp-banner h3 { font-size: 13px; font-weight: 700; color: #92400e; margin-bottom: 3px; }
.corresp-banner p  { font-size: 12px; color: #c25200; line-height: 1.6; }

.steps-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px;
  margin-bottom: 18px; box-shadow: var(--shadow);
}
.steps-title { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--hint); margin-bottom: 16px; }

.step { display: flex; align-items: flex-start; gap: 13px; position: relative; padding-bottom: 16px; }
.step:last-child { padding-bottom: 0; }
.step::after {
  content: ''; position: absolute; left: 19px; top: 40px; bottom: 0;
  width: 1px; background: var(--border);
}
.step:last-child::after { display: none; }
.step-circle {
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; flex-shrink: 0;
}
.step-tgv      { background: var(--blue-light); }
.step-walk     { background: #f3f4f6; }
.step-stop     { background: #fefce8; }
.step-ter      { background: #f9fafb; border: 1px dashed #d1d5db; }
.step-transfer { background: #f0fdf4; }
.step-night    { background: #1e1b4b; }
.ter-warn      { color: var(--amber); font-weight: 600; }
.seg-night-badge { font-size: 10px; background: #1e1b4b; color: #a5b4fc; padding: 2px 7px; border-radius: 10px; font-weight: 600; vertical-align: middle; }
.step-info { padding-top: 3px; }
.step-label { font-size: 13px; font-weight: 500; line-height: 1.3; color: var(--text); }
.step-sub   { font-size: 11px; color: var(--muted); margin-top: 2px; }

.seg-header { display: flex; align-items: center; gap: 9px; margin: 13px 0 11px; }
.seg-num-badge {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--blue); color: var(--mz-on-accent, #161A22);
  font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.seg-header-text { font-size: 13px; font-weight: 600; }

/* ── Variant tabs ────────────────────────────────────────────────────── */
.variant-tabs { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.variant-tab {
  flex: 1; min-width: 140px;
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px;
  padding: 13px 15px; border-radius: var(--radius-sm);
  background: var(--card); border: 1px solid var(--border);
  cursor: pointer; text-align: left;
  transition: border-color .15s, box-shadow .15s;
  box-shadow: var(--shadow);
}
.variant-tab:hover { border-color: var(--blue); box-shadow: var(--shadow-md); }
.variant-tab.active {
  border: 2px solid var(--blue);
  background: var(--blue-light);
  box-shadow: 0 0 0 3px rgba(255,106,0,.08);
}
.vt-icon  { font-size: 18px; margin-bottom: 2px; }
.vt-label { font-size: 13px; font-weight: 700; color: var(--text); letter-spacing: -.01em; }
.vt-sub   { font-size: 11px; color: var(--muted); }
.variant-tab.active .vt-label { color: var(--blue); }

.loading-dots { color: var(--hint); }

/* ── No route ────────────────────────────────────────────────────────── */
.no-route { text-align: center; padding: 70px 20px; color: var(--hint); }
.no-route-icon { font-size: 38px; margin-bottom: 12px; }
.no-route h3 { font-size: 15px; color: var(--muted); font-weight: 500; margin-bottom: 7px; }
.no-route p  { font-size: 13px; }

/* ── Spinner ─────────────────────────────────────────────────────────── */
.spinner {
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,.25);
  border-top-color: white; border-radius: 50%;
  animation: spin .6s linear infinite; flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Toast ───────────────────────────────────────────────────────────── */
#toastContainer {
  position: fixed;
  left: 50%;
  right: auto;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  z-index: 70;
  pointer-events: none;
  width: min(92vw, 420px);
}
@media (max-width: 1023px) {
  #toastContainer {
    bottom: calc(var(--mz-bottom-nav-h, 68px) + 16px + env(safe-area-inset-bottom, 0px));
    z-index: 125;
  }
  body.has-cookie-banner #toastContainer,
  body.app-shell.has-cookie-banner #toastContainer {
    bottom: calc(var(--mz-bottom-nav-h, 68px) + 148px + env(safe-area-inset-bottom, 0px));
  }
}
.toast {
  padding: 10px 18px; border-radius: 99px;
  font-size: 13px; font-weight: 500; line-height: 1.4;
  max-width: min(92vw, 420px); white-space: normal; text-align: center;
  box-shadow: var(--shadow-lg);
  opacity: 0; transform: translateY(8px);
  transition: opacity .25s, transform .25s;
  pointer-events: auto;
}
.toast.show { opacity: 1; transform: none; }
.toast-action {
  display: flex; align-items: center; gap: 12px;
  border-radius: var(--radius-sm); padding: 10px 14px;
  max-width: min(92vw, 480px);
}
.toast-action-btn {
  flex-shrink: 0; border: none; border-radius: 99px;
  padding: 5px 12px; font-size: 12px; font-weight: 700;
  background: rgba(255,255,255,0.2); color: inherit;
  cursor: pointer; font-family: inherit;
}
.toast-action-btn:hover { background: rgba(255,255,255,0.35); }
.toast-success.toast-action .toast-action-btn { background: rgba(255,255,255,0.25); color: #bbf7d0; }
.toast-info    { background: #1C1008; color: #f1f5f9; }
.toast-success { background: #14532d; color: #bbf7d0; }
.toast-error   { background: #7f1d1d; color: #fecaca; }
.toast-error.toast-action .toast-action-btn {
  background: var(--mz-accent, #FF6A00); color: var(--mz-on-accent, #1C1008);
}
.toast-error.toast-action .toast-action-btn:hover { filter: brightness(1.08); background: var(--mz-accent, #FF6A00); }

.mz-seat-feedback {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(88px + env(safe-area-inset-bottom, 0px));
  z-index: 80;
  max-width: 440px;
  margin: 0 auto;
  padding: 14px 16px;
  border-radius: 16px;
  background: #fff;
  color: #161A22;
  border: 1px solid rgba(22, 26, 34, 0.12);
  box-shadow: 0 12px 32px rgba(22, 26, 34, 0.16);
}
.mz-seat-feedback-title {
  font-weight: 800;
  font-size: 1rem;
  margin: 0 0 4px;
}
.mz-seat-feedback-note,
.mz-seat-feedback-thanks {
  margin: 0 0 10px;
  font-size: 0.82rem;
  color: #5b6270;
}
.mz-seat-feedback-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
@media (min-width: 861px) {
  .mz-seat-feedback { bottom: 24px; }
}

/* ── Scrollbar ───────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 3px; }

/* ── Notifications toast ─────────────────────────────────────────────── */
.notif-toast {
  position: fixed; top: 20px; right: 20px; z-index: 1000;
  background: #1C1008; color: #e5e7eb;
  border-left: 4px solid var(--amber); border-radius: var(--radius-sm);
  padding: 15px 20px; max-width: 380px;
  box-shadow: var(--shadow-lg); font-size: 13px; line-height: 1.55;
  transition: opacity .3s, transform .3s;
}
.notif-toast.hidden { opacity: 0; pointer-events: none; transform: translateY(-10px); }
.notif-toast-title { font-weight: 700; margin-bottom: 7px; color: var(--amber); font-size: 13px; }
.notif-toast.notif-availability { border-color: rgba(22,163,74,.45); box-shadow: 0 8px 32px rgba(22,163,74,.18); }
.notif-toast.notif-availability .notif-toast-title { color: var(--green); }
.notif-action-btn {
  margin-top: 10px; padding: 8px 12px; border-radius: var(--radius-xs); border: none;
  background: var(--blue); color: var(--mz-on-accent, #161A22); font-weight: 700; font-size: 12px; cursor: pointer; font-family: inherit;
}
.notif-action-btn:hover { filter: brightness(1.05); }

.modal-optional { font-weight: 400; opacity: 0.65; font-size: 0.9em; }
.modal-hint { font-size: 12px; color: var(--muted); margin: -6px 0 12px; line-height: 1.4; }
.modal-check-row { display: flex; align-items: center; gap: 8px; font-size: 13px; margin-bottom: 14px; }
.alert-tag.mode { background: #ecfdf5; color: #047857; border: 1px solid rgba(22,163,74,.25); }
.notif-toast-row { display: flex; gap: 6px; align-items: baseline; margin-top: 2px; }
.notif-added   { color: #4ade80; }
.notif-removed { color: #f87171; }
.notif-close { float: right; cursor: pointer; margin-left: 14px; opacity: .5; font-size: 16px; line-height: 1; }
.notif-close:hover { opacity: 1; }

/* ── Alerts FAB ──────────────────────────────────────────────────────── */
.alerts-fab {
  position: fixed; bottom: 24px; right: 24px; z-index: 900;
  background: var(--blue); color: var(--mz-on-accent, #161A22);
  border: none; border-radius: 50px; padding: 13px 20px;
  font-size: 18px; cursor: pointer; box-shadow: var(--shadow-lg);
  transition: background .15s, transform .15s;
  display: flex; align-items: center; gap: 6px;
}
.alerts-fab:hover { background: var(--mz-accent-press, #E55F00); transform: scale(1.04); }
.alerts-badge {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--red); color: #fff;
  font-size: 10px; font-weight: 800; border-radius: 99px;
  min-width: 18px; height: 18px; padding: 0 5px;
}
.alerts-badge.hidden { display: none; }

/* ── Alerts panel ────────────────────────────────────────────────────── */
.alerts-panel {
  position: fixed; bottom: 82px; right: 24px; z-index: 950;
  width: 370px; background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); border: 1px solid var(--border);
  display: flex; flex-direction: column; max-height: 520px;
  transition: opacity .2s, transform .2s;
}
.alerts-panel.hidden { opacity: 0; pointer-events: none; transform: translateY(10px); }
.alerts-panel-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px; border-bottom: 1px solid var(--border);
  font-weight: 700; font-size: 14px; letter-spacing: -.01em;
}
.alerts-panel-header button {
  background: none; border: none; cursor: pointer; font-size: 17px; color: var(--hint);
  transition: color .12s;
}
.alerts-panel-header button:hover { color: var(--text); }
.alerts-list { overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.alert-item {
  background: var(--bg); border-radius: var(--radius-sm); padding: 13px 15px;
  border: 1px solid var(--border); font-size: 12px;
}
.alert-item-route { font-weight: 700; font-size: 13px; margin-bottom: 4px; letter-spacing: -.01em; }
.alert-item-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.alert-item-top .alert-item-route { margin-bottom: 0; }
.alert-status {
  flex-shrink: 0; font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 99px;
}
.alert-status.on { background: rgba(22,163,74,.14); color: #15803d; }
.alert-status.off { background: rgba(100,116,139,.14); color: #64748b; }
.alert-item.is-paused { opacity: .72; }
.alert-item-places { font-size: 12px; font-weight: 650; color: #15803d; margin-bottom: 6px; }
.alert-trip-open {
  margin: 8px 0 10px;
  padding: 12px;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  background: #f0fdf4;
}
.alert-trip-open-title { margin: 0 0 4px; font-size: 13px; font-weight: 700; }
.alert-trip-open-meta { margin: 0 0 8px; font-size: 13px; }
.notif-toast-date { font-size: 12px; color: var(--muted); margin: -4px 0 8px; font-weight: 600; }
.alerts-howto-steps { margin: 6px 0 0; padding-left: 18px; }
.alerts-howto-steps li { margin: 4px 0; }
.alert-item-meta  { color: var(--muted); margin-bottom: 7px; font-size: 11px; }
.alert-item-tags  { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 9px; }
.alert-tag {
  background: var(--blue-light); color: var(--blue);
  border-radius: 99px; padding: 2px 9px; font-size: 11px; font-weight: 600;
}
.alert-tag.email    { background: #fef3c7; color: #92400e; }
.alert-tag.webhook  { background: #f3e8ff; color: #6b21a8; }
.alert-tag.inactive { background: var(--red-light); color: var(--red); }
.alert-row-actions {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 4px;
}
.alert-row-actions .alert-action-btn.is-inline {
  flex: 0 0 auto; min-height: 44px; padding: 0 16px;
  font-size: 14px; font-weight: 700;
}
.alert-item-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.alert-action-btn {
  flex: 1; padding: 6px 8px; border-radius: var(--radius-xs);
  border: 1px solid var(--border); background: #fff; cursor: pointer;
  font-size: 11px; color: var(--text); transition: background .12s;
  font-weight: 500;
}
.alert-action-btn:hover { background: var(--bg); }
.alert-action-btn.danger { color: var(--red); border-color: #fecaca; }
.alert-action-btn.danger:hover { background: var(--red-light); }
.alert-checked { color: var(--hint); font-size: 10px; margin-top: 5px; }
.alerts-empty { padding: 28px 20px; text-align: center; color: var(--muted); font-size: 13px; line-height: 1.6; }
.alert-health {
  background: var(--card, #fff);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px 16px;
  margin-bottom: 14px;
}
.alert-health-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.alert-heartbeat {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 99px;
  background: rgba(22,163,74,.14); color: #15803d;
}
.alert-heartbeat::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor;
}
.alert-heartbeat.ok { background: rgba(22,163,74,.14); color: #15803d; }
.alert-heartbeat.stale { background: rgba(245,158,11,.16); color: #b45309; }
.alert-heartbeat.never { background: rgba(79,70,229,.12); color: #4338ca; }
.alert-heartbeat.error { background: rgba(220,38,38,.12); color: #b91c1c; }
.alert-heartbeat.paused, .alert-heartbeat.empty { background: rgba(100,116,139,.14); color: #64748b; }
.alert-health-meta { font-size: 11px; font-weight: 650; color: var(--muted); }
.alert-health-check { margin: 8px 0 4px; font-size: 13px; color: var(--text); }
.alert-health-sla { margin: 0; font-size: 12px; font-weight: 650; color: var(--text); }
.alert-health-copy { margin: 6px 0 0; font-size: 12px; line-height: 1.45; color: var(--muted); }
.alert-heartbeat-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 4px 0 8px; }
.alert-ping-list { margin: 6px 0 8px; padding-left: 16px; font-size: 11px; color: var(--muted); }
.alert-ping-list li { margin: 2px 0; }
.alert-error { margin: 6px 0; padding: 8px 10px; border-radius: 10px; background: rgba(220,38,38,.08); color: #991b1b; font-size: 12px; }
.alert-favorites-nudge { margin: 10px 0; padding: 10px 12px; border-radius: 12px; background: rgba(79,70,229,.08); color: var(--text); font-size: 13px; }

/* ── Modal ───────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(0,0,0,0.5); display: flex;
  align-items: center; justify-content: center;
  transition: opacity .2s;
}
.modal-overlay.hidden { display: none !important; opacity: 0; pointer-events: none; visibility: hidden; }
.modal {
  background: #fff; border-radius: var(--radius); width: 430px; max-width: 95vw;
  max-height: min(90dvh, 720px);
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column;
  overflow: hidden;
}
.modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 22px; border-bottom: 1px solid var(--border);
  font-weight: 700; font-size: 15px; letter-spacing: -.01em;
}
.modal-header h2,
.modal-title {
  margin: 0;
  font-size: inherit;
  font-weight: inherit;
  line-height: 1.3;
  letter-spacing: inherit;
}
.modal-header button {
  background: none; border: none; cursor: pointer; font-size: 20px; color: var(--hint);
  transition: color .12s; min-width: 44px; min-height: 44px;
}
.modal-header button:hover { color: var(--text); }
.modal-body {
  padding: 22px; display: flex; flex-direction: column; gap: 13px;
  overflow-y: auto; min-height: 0; -webkit-overflow-scrolling: touch;
}
.modal-route {
  background: var(--blue-light); color: var(--blue); border-radius: var(--radius-sm);
  padding: 11px 15px; font-weight: 700; font-size: 13px; letter-spacing: -.01em;
}
.modal-label { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.modal-input {
  width: 100%; padding: 10px 13px; border: 1px solid var(--border-strong);
  border-radius: var(--radius-xs); font-size: 13px; color: var(--text);
  background: #fff; outline: none; transition: border-color .15s;
  font-family: inherit;
}
.modal-input::placeholder {
  color: var(--mz-placeholder, #5C6575);
  opacity: 1;
}
.modal-input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(255,106,0,.1); }
.time-row { display: flex; gap: 8px; align-items: center; }
.time-row .modal-input { flex: 1; }
.time-sep { color: var(--hint); font-size: 18px; flex-shrink: 0; }
.modal-details {
  border: 1px solid var(--border); border-radius: var(--radius-xs); overflow: hidden;
}
.modal-details summary {
  padding: 11px 15px; cursor: pointer; font-size: 13px; font-weight: 500;
  user-select: none; background: var(--bg); transition: background .12s;
}
.modal-details summary:hover { background: #eceae5; }
.modal-details-body { padding: 13px 15px; display: flex; flex-direction: column; gap: 9px; }
.modal-footer {
  padding: 16px 22px; border-top: 1px solid var(--border);
  display: flex; justify-content: flex-end; gap: 10px;
}
.modal-cancel {
  padding: 10px 20px; border-radius: var(--radius-xs); border: 1px solid var(--border);
  background: #fff; cursor: pointer; font-size: 13px; color: var(--text); font-family: inherit;
  transition: background .12s;
}
.modal-cancel:hover { background: var(--bg); }
.modal-submit {
  padding: 10px 22px; border-radius: var(--radius-xs); border: none;
  background: var(--blue); color: var(--mz-on-accent, #161A22); cursor: pointer; font-size: 13px; font-weight: 700;
  transition: background .15s; font-family: inherit;
  box-shadow: 0 2px 8px rgba(255,106,0,.3);
}
.modal-submit:hover { background: var(--mz-accent-press, #E55F00); }
.modal-submit:disabled { opacity: 1; color: var(--mz-ink, #1C1008); background: rgba(255,106,0,.22); cursor: not-allowed; }

/* ── Dark mode — navy 2026 (plus de thème brun) ──────────── */
:root.dark {
  --bg:           #0B0F17;
  --card:         #151B26;
  --border:       rgba(244,246,250,0.18);
  --border-strong:rgba(244,246,250,0.40);
  --text:         #F4F6FA;
  --muted:        #C5D0E0;
  --hint:         #B4C0D0;
  --blue-light:   rgba(61, 90, 254, 0.22);
  --green-light:  rgba(22, 163, 106, 0.18);
  --amber-light:  rgba(245, 158, 11, 0.18);
  --red-light:    rgba(220, 60, 77, 0.18);
  --accent-light: rgba(255, 106, 0, 0.22);
  --mz-bg: #0B0F17;
  --mz-bg-deep: #070A10;
  --mz-surface: #151B26;
  --mz-ink: #F4F6FA;
  --mz-ink-2: #E2E8F0;
  --mz-muted: #C5D0E0;
  --mz-hint: #B4C0D0;
  --mz-on-accent: #161A22;
  --mz-accent-text: #FFB787;
  --mz-placeholder: #B4C0D0;
  --mz-border: rgba(244,246,250,0.18);
  --mz-border-strong: rgba(244,246,250,0.40);
}
:root.dark .rel-verified { background: rgba(22, 163, 106, 0.28); color: #86EFAC; }
:root.dark .rel-check { background: rgba(245, 158, 11, 0.28); color: #FDE68A; }
:root.dark .rel-opendata { background: rgba(148, 163, 184, 0.28); color: #E2E8F0; }
:root.dark .rel-unknown { background: rgba(148, 163, 184, 0.24); color: #E2E8F0; }
:root.dark .type-tgv,
:root.dark .type-inoui,
:root.dark .type-tgv-inoui {
  background: rgba(129, 140, 248, 0.32);
  color: #E0E7FF;
}
:root.dark .type-ouigo { background: rgba(22, 163, 106, 0.28); color: #86EFAC; }
:root.dark .j-opt-tag { background: rgba(255, 106, 0, 0.24); color: #FFD7B5; }
:root.dark .j-tier-recommand { background: rgba(22, 163, 106, 0.28); color: #86EFAC; }
:root.dark .j-tier-alternatif { background: rgba(96, 165, 250, 0.28); color: #DBEAFE; }
:root.dark .j-tier-dernierrecours { background: rgba(245, 158, 11, 0.28); color: #FDE68A; }
:root.dark .j-conn-wait.is-tight { color: #FDE68A; }
:root.dark .j-shortest-tag { background: #166534; color: #ECFDF5; }
:root.dark .sidebar        { background: #101623; border-right-color: rgba(244,246,250,0.08); }
:root.dark .sidebar-header { background: linear-gradient(160deg, #1A2233 0%, #101623 100%); }
:root.dark .cal-day        { background: #151B26; }
:root.dark .cal-day:hover:not(.empty):not(.unavailable):not(.not-loaded) { background: #1A2233; }
:root.dark .train-row:hover { background: #1A2233; }
:root.dark .detail-header  { background: #101623; }
:root.dark .modal          { background: #151B26; }
:root.dark .modal-input    { background: #0B0F17; color: var(--text); border-color: rgba(244,246,250,0.16); }
:root.dark .modal-details summary { background: #0B0F17; }
:root.dark .modal-cancel   { background: #0B0F17; color: var(--text); }
:root.dark .feature-card   { background: #151B26; }
:root.dark .alert-item     { background: #0B0F17; }
:root.dark .alert-action-btn { background: #151B26; color: var(--text); }
:root.dark .gare-btn.orig  { background: rgba(255,106,0,0.22); }
:root.dark .gare-btn.dest  { background: rgba(22,163,106,0.22); }
:root.dark .variant-tab    { background: #151B26; }
:root.dark .variant-tab.active { background: #1A2233; }
:root.dark .steps-card, :root.dark .cal-card, :root.dark .detail-card,
:root.dark .route-header, :root.dark .metric { background: #151B26; }

/* ── Dark mode toggle button ─────────────────────────────────────────── */

/* ── Share button ────────────────────────────────────────────────────── */
.share-btn {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 99px;
  border: 1px solid var(--border); background: var(--card);
  font-size: 11px; font-weight: 500; color: var(--muted);
  cursor: pointer; transition: background .12s, color .12s;
}
.share-btn:hover { background: var(--blue-light); color: var(--blue); border-color: var(--blue); }

/* ── Route overview panel ─────────────────────────────────────────────── */
.route-overview {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px 18px;
  margin-bottom: 16px; box-shadow: var(--shadow);
}
.ro-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 12px;
}
.ro-title { font-size: 14px; font-weight: 700; color: var(--text); }
.ro-sub { font-size: 12px; font-weight: 500; color: var(--muted); }
.ro-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.ro-filter {
  padding: 5px 12px; border-radius: 99px; border: 1px solid var(--border);
  background: var(--bg); font-size: 11px; font-weight: 600; color: var(--muted);
  cursor: pointer; transition: all .15s;
}
.ro-filter:hover { border-color: var(--blue); color: var(--blue); }
.ro-filter.active {
  background: var(--blue-light); border-color: var(--blue); color: var(--mz-accent-press, #E55F00);
}
.ro-hint {
  font-size: 12px; color: var(--muted); margin-bottom: 10px;
  padding: 8px 12px; background: var(--amber-light); border-radius: var(--radius-xs);
}
.ro-clear {
  background: none; border: none; color: var(--blue); font-weight: 600;
  cursor: pointer; text-decoration: underline; font-size: inherit;
}
.ro-list {
  display: flex; flex-direction: column; gap: 6px;
}
.ro-row {
  display: flex; flex-direction: column; gap: 6px;
  text-align: left; width: 100%;
  padding: 10px 12px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--bg);
  cursor: pointer; transition: border-color .15s, background .15s, box-shadow .15s;
  font-family: inherit; color: inherit;
}
.ro-row:hover { border-color: rgba(255,106,0,.45); }
.ro-row.active {
  border-color: var(--accent, #ff6a00);
  background: rgba(255,106,0,.08);
  box-shadow: 0 0 0 3px rgba(255,106,0,.12);
}
.ro-row-main {
  display: grid;
  grid-template-columns: minmax(7.5rem, auto) 1fr auto;
  gap: 10px 12px; align-items: center;
}
.ro-kind {
  font-size: 12px; font-weight: 800; letter-spacing: -.01em;
  color: var(--text); white-space: nowrap;
}
.ro-kind.direct { color: #15803d; }
.ro-kind.corr { color: var(--text); }
.ro-kind.night { color: var(--mz-accent, #FF6A00); }
.ro-row .ro-path {
  font-size: 12px; color: var(--muted); line-height: 1.35;
  margin: 0; word-break: break-word;
}
.ro-row .ro-est {
  font-size: 11px; font-weight: 700; color: var(--accent-dark, #c2410c);
  background: rgba(255,106,0,.1); border: none;
  border-radius: 99px; padding: 4px 9px; white-space: nowrap;
}
.ro-row.active .ro-est { background: rgba(255,106,0,.18); }
.ro-row .ro-badges { margin-top: 0; }
.ro-row .ro-steps {
  margin: 2px 0 0; padding-top: 8px;
  border-top: 1px dashed var(--border);
}
.ro-more {
  margin-top: 10px; width: 100%;
  padding: 10px 12px; border-radius: 10px;
  border: 1px dashed var(--border); background: transparent;
  color: var(--muted); font: inherit; font-size: 12px; font-weight: 650;
  cursor: pointer;
}
.ro-more:hover { border-color: var(--accent, #ff6a00); color: var(--accent-dark, #c2410c); }
.ro-steps { margin-bottom: 8px; }
@media (max-width: 640px) {
  .ro-row-main { grid-template-columns: 1fr auto; }
  .ro-kind { grid-column: 1 / -1; }
}
.ro-step {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 10px; line-height: 1.35; color: var(--text);
  padding: 3px 0;
}
.ro-step-n {
  flex-shrink: 0; width: 16px; height: 16px; border-radius: 50%;
  background: var(--blue-light); color: var(--mz-accent-press, #E55F00);
  font-size: 9px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.ro-step-xfer .ro-step-n { background: var(--amber-light); color: #92400e; font-size: 10px; }
.ro-step-ter .ro-step-body { color: #854d0e; }
.ro-step-walk .ro-step-body { color: var(--muted); }
.ro-step-tag {
  font-size: 8px; font-weight: 700; text-transform: uppercase;
  background: var(--mz-accent-soft, rgba(255,106,0,.12)); color: var(--mz-ink); padding: 1px 5px; border-radius: 99px; margin-left: 4px;
}
.ro-daynote {
  font-size: 11px; color: var(--muted); margin-bottom: 10px;
  padding: 6px 10px; background: var(--bg); border-radius: var(--radius-xs);
  border-left: 3px solid var(--blue);
}
.ro-loadhint {
  font-size: 11px; color: var(--muted); margin-bottom: 10px;
  padding: 6px 10px; background: var(--amber-light); border-radius: var(--radius-xs);
}
.load-scope-hint {
  font-size: 10px; color: var(--hint); margin-top: 6px; line-height: 1.35;
  min-height: 14px;
}
.ro-badges { display: flex; flex-wrap: wrap; gap: 4px; }
.ro-badge {
  font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  padding: 2px 7px; border-radius: 99px;
}
.ro-badge.fastest { background: #fef3c7; color: #92400e; }
.ro-badge.direct  { background: var(--green-light); color: var(--green); }
.ro-badge.ter     { background: #fef9c3; color: #854d0e; }

.ro-badge.gare {
  background: #ecfdf5; color: #047857; border: 1px solid rgba(4,120,87,.25);
}
.ro-badge.tc {
  background: #eff6ff; color: #1d4ed8; border: 1px solid rgba(29,78,216,.25);
}
.ro-badge.night   { background: var(--mz-accent-soft, rgba(255,106,0,.12)); color: var(--mz-ink); }
.ro-badge.max     { background: var(--blue-light); color: var(--mz-accent-press, #E55F00); }
.ro-empty { grid-column: 1 / -1; text-align: center; color: var(--hint); padding: 20px; font-size: 13px; }
:root.dark .route-overview { background: #2A1A10; border-color: #2a2d36; }
:root.dark .ro-row { background: #1C1008; border-color: #2a2d36; }
:root.dark .ro-row.active { background: #3d2410; border-color: #ff6a00; }
:root.dark .ro-filter { background: #1C1008; border-color: #2a2d36; }
:root.dark .ro-filter.active { background: #3d2410; }
:root.dark .ro-hint { background: #422006; color: #fcd34d; }

/* ── Route paths strip (legacy) ─────────────────────────────────────── */
.route-paths {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-bottom: 12px;
}
.rp-item {
  background: var(--blue-light); color: var(--mz-accent-press, #E55F00);
  border-radius: 99px; padding: 4px 12px;
  font-size: 11px; font-weight: 500;
}
:root.dark .rp-item { background: #3d2410; color: #ffb787; }

/* ── Journey cards ───────────────────────────────────────────────────── */
.journeys-list { display: flex; flex-direction: column; gap: 0; }

.journey-card {
  border-bottom: 1px solid var(--border);
  padding: 12px 18px;
}
.journey-card:last-child { border-bottom: none; }
.journey-card.direct .j-summary { padding-bottom: 4px; }
.j-legs-direct {
  border-left: none; margin-left: 0; padding-left: 0;
  margin-top: 4px;
}
.j-legs-direct .j-leg { padding: 4px 0; }

.j-summary {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding-bottom: 8px;
}
.j-date-badge {
  display: inline-flex; align-items: center;
  font-size: 13px; font-weight: 800; letter-spacing: -0.01em;
  color: var(--mz-accent-press, #E55F00);
  background: var(--mz-accent-soft, rgba(255,106,0,.14));
  border: 1px solid rgba(255,106,0,.35);
  border-radius: 10px;
  padding: 5px 11px;
  text-transform: capitalize;
  white-space: nowrap;
  flex-shrink: 0;
}
:root.dark .j-date-badge {
  color: #ffb787;
  background: #3d2410;
  border-color: rgba(255,183,135,.35);
}
.detail-title-wrap {
  display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0;
}
.detail-day-label {
  font-size: 17px; font-weight: 800; letter-spacing: -0.02em;
  color: var(--text); text-transform: capitalize; line-height: 1.2;
}
.detail-title-wrap .detail-title {
  font-size: 12px; font-weight: 550; color: var(--muted);
}
.j-times { display: flex; align-items: center; gap: 6px; }
.j-dep  { font-size: 18px; font-weight: 700; color: var(--text); letter-spacing: -0.5px; }
.j-arr  { font-size: 18px; font-weight: 700; color: var(--text); letter-spacing: -0.5px; }
.j-arrow { color: var(--muted); font-size: 14px; }
.j-dur  { font-size: 12px; color: var(--muted); background: var(--bg);
  border: 1px solid var(--border); border-radius: 99px; padding: 2px 8px; }
.j-nextday { font-size: 10px; font-weight: 600; color: var(--mz-accent, #FF6A00); white-space: nowrap; }
:root.dark .j-nextday { color: #c4b5fd; }
.j-shortest-tag { font-size: 11px; color: #fff; background: var(--green, #16a34a);
  border-radius: 99px; padding: 2px 8px; font-weight: 700; }
.j-opt-tag { font-size: 11px; color: var(--blue); background: var(--blue-light);
  border-radius: 99px; padding: 2px 8px; font-weight: 500; }
.j-tier-tag { font-size: 11px; border-radius: 99px; padding: 2px 8px; font-weight: 700; }
.j-tier-recommand { background: rgba(22, 163, 74, .14); color: #15803d; }
.j-tier-alternatif { background: rgba(37, 99, 235, .12); color: #1d4ed8; }
.j-tier-dernierrecours { background: rgba(180, 83, 9, .14); color: #b45309; }
.j-separate-tickets { color: var(--text); background: var(--mz-accent-soft, rgba(255,106,0,.08));
  border-radius: 8px; padding: 8px 10px; }
.j-conn-waits { margin: 6px 0 2px; padding-left: 18px; font-size: 12px; color: var(--muted); }
.j-conn-wait.is-tight { color: #b45309; }
.mz-deep-search { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0 4px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; cursor: pointer; }
.mz-deep-search.is-on { border-color: var(--mz-accent, #ff6a00); background: var(--mz-accent-soft, rgba(255,106,0,.06)); }
.mz-deep-search-text { display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.mz-deep-search-text small { color: var(--muted); font-size: 11.5px; line-height: 1.35; }
#alertWatchMultilegLabel { display: flex; gap: 8px; align-items: flex-start; margin-top: 10px;
  font-size: 13px; line-height: 1.4; }
.j-night-tag { font-size: 11px; color: var(--mz-accent, #FF6A00); background: var(--mz-accent-soft, rgba(255,106,0,.12));
  border-radius: 99px; padding: 2px 8px; font-weight: 500; }
:root.dark .j-night-tag { background: #2e1065; color: #c4b5fd; }
/* Trajet parti mais pas encore arrivé (recherche le jour même) */
.j-ongoing-tag { font-size: 11px; color: #0f766e; background: rgba(13, 148, 136, .14);
  border-radius: 99px; padding: 2px 8px; font-weight: 700; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 5px; }
.j-ongoing-tag::before { content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: #0d9488; animation: jOngoingPulse 1.6s ease-in-out infinite; }
:root.dark .j-ongoing-tag { background: rgba(45, 212, 191, .16); color: #5eead4; }
:root.dark .j-ongoing-tag::before { background: #2dd4bf; }
@keyframes jOngoingPulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
/* Note trajets du jour masqués (heure d'arrivée dépassée) */
.j-past-note { font-size: 12px; color: var(--muted); background: var(--bg);
  border: 1px dashed var(--border); border-radius: 10px;
  padding: 8px 12px; margin-top: 8px; text-align: center; }
.j-places { margin-left: auto; font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 99px; }

/* Detailed legs */
.j-legs {
  border-left: 2px solid var(--border);
  margin-left: 8px; padding-left: 12px;
  display: flex; flex-direction: column; gap: 0;
}
.j-leg {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 0; flex-wrap: wrap;
}
.j-leg-icon { font-size: 14px; width: 20px; text-align: center; }
.j-leg-times { display: flex; gap: 4px; font-size: 13px; font-weight: 600;
  color: var(--text); min-width: 100px; }
.j-leg-arr { color: var(--muted); font-weight: 400; }
.j-leg-info { display: flex; align-items: center; gap: 6px; flex: 1; flex-wrap: wrap; }
.j-leg-seg { font-size: 12px; color: var(--muted); }
.j-leg-num { font-size: 10px; }
.j-leg-sub { font-size: 11px; color: var(--hint); }
.j-leg-places { font-size: 11px; padding: 2px 7px; border-radius: 99px; margin-left: auto; }
.j-trains-preview { margin: 8px 0 4px; display: flex; flex-direction: column; gap: 6px; }
.j-train-preview-row { display: flex; gap: 8px; align-items: flex-start; font-size: 12.5px; color: var(--text); line-height: 1.35; }
.j-train-idx { flex: 0 0 18px; width: 18px; height: 18px; border-radius: 6px; background: var(--accent, #B34700); color: #fff; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; }
.j-transfer-note { margin: 6px 0 2px; font-size: 12px; color: var(--muted); }
.j-leg.j-leg-ter { opacity: .85; }

.j-connector {
  display: flex; align-items: center; gap: 6px;
  padding: 4px 0; font-size: 11px; color: var(--muted);
}
.j-connector.j-conn-live {
  color: var(--text, #1a1a1a);
}
.j-connector.j-conn-live .j-conn-time {
  color: var(--accent, #0b6e4f);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}
.j-leg-pt-live .j-leg-sub { color: var(--text, #1a1a1a); }
.j-conn-icon { font-size: 13px; }
.j-conn-label { font-weight: 500; }
.j-conn-time { color: var(--hint); }

.route-filter-bar {
  display: flex; gap: 6px; padding: 10px 16px 4px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.route-filter-btn {
  display: flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: 99px; font-size: 12px; font-weight: 500;
  border: 1px solid var(--border); background: transparent;
  color: var(--hint); cursor: pointer; transition: all .15s;
}
.route-filter-btn:hover { background: rgba(0,0,0,0.04); color: var(--text); }
:root.dark .route-filter-btn:hover { background: rgba(255,255,255,0.05); color: var(--text); }
.route-filter-btn.active {
  background: rgba(255,106,0,0.15); border-color: rgba(255,106,0,0.4);
  color: #ffb787;
}
.rf-count {
  background: rgba(255,255,255,0.10); border-radius: 99px;
  padding: 0 5px; font-size: 10px; font-weight: 600;
}
.route-filter-btn.active .rf-count { background: rgba(255,106,0,0.25); }

.journey-empty {
  padding: 18px; color: var(--hint); font-size: 13px; line-height: 1.5;
}
.journey-empty strong { display: block; color: var(--text); font-size: 14px; margin-bottom: 6px; }
.journey-empty p { margin: 0; }
.journey-empty-done {
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  background: rgba(0,0,0,0.02);
}
:root.dark .journey-empty-done { background: rgba(255,255,255,0.03); }

.journey-card.hors-ville {
  border-left: 3px solid var(--amber);
}

.j-hors-ville-badge {
  font-size: 10px; font-weight: 700;
  background: var(--amber-light); color: #92400e;
  border: 1px solid rgba(217,119,6,.3); border-radius: 99px; padding: 2px 8px;
}
:root.dark .j-hors-ville-badge { background: #422006; color: #fcd34d; border-color: rgba(217,119,6,.2); }

.j-warn-hors-ville {
  font-size: 12px; color: #92400e;
  background: var(--amber-light); border: 1px solid rgba(217,119,6,.2);
  border-radius: var(--radius-xs); padding: 7px 12px; margin-bottom: 8px; line-height: 1.5;
}
:root.dark .j-warn-hors-ville { background: #422006; color: #fcd34d; border-color: rgba(217,119,6,.15); }

:root.dark .journey-card { border-color: #2a2d36; }
:root.dark .j-legs { border-color: #2a2d36; }

/* ── Route picker (sidebar) ─────────────────────────────────────────── */
.route-picker { padding: 0 12px 8px; }
.route-pick-btn {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 7px 10px; border-radius: var(--radius-xs); border: 1px solid transparent;
  background: transparent; color: rgba(255,255,255,0.55); cursor: pointer;
  text-align: left; font-family: inherit; transition: all .15s; margin-bottom: 3px;
}
.route-pick-btn:hover { background: #1a1d27; color: rgba(255,255,255,0.85); }
.route-pick-btn.active {
  background: rgba(255,106,0,0.15); border-color: rgba(255,106,0,0.4);
  color: #ffb787;
}
.rp-icon { font-size: 14px; flex-shrink: 0; }
.rp-body { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.rp-label { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rp-sub   { font-size: 10px; opacity: .65; }

.smtp-server-note, .smtp-hint {
  font-size: 12px; color: var(--muted); line-height: 1.5; margin-bottom: 8px;
}
.smtp-hint code { font-size: 11px; background: rgba(0,0,0,.06); padding: 1px 5px; border-radius: 4px; }
:root.dark .smtp-hint code { background: rgba(255,255,255,.08); }

.notif-changed { color: var(--amber); }

.u-hidden { display: none !important; }

.sidebar-toggle {
  display: none;
  position: fixed; top: 12px; left: 12px; z-index: 850;
  background: #ffffff;
  color: #161A22;
  border: 1.5px solid rgba(22, 26, 34, 0.16);
  border-radius: 12px;
  padding: 8px 14px; font-size: 13px; font-weight: 700; cursor: pointer;
  box-shadow: 0 4px 14px rgba(22, 26, 34, 0.12);
}

.sidebar-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 880;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0; transition: opacity .25s ease;
  pointer-events: none;
}

/* ── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 700px) {
  .sidebar-toggle {
    /* Mobile : pas de pastille noire — bottom nav suffit */
    display: none !important;
  }
  .sidebar-overlay.visible { display: block; opacity: 1; pointer-events: auto; }
  .layout {
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    min-height: 100dvh;
    overflow: hidden;
  }
  body.app-shell .layout,
  body.app-shell .layout.mz-app-frame {
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
    overflow: visible !important;
  }
  .sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; z-index: 900;
    width: min(300px, 88vw); transform: translateX(-105%);
    transition: transform .25s ease; box-shadow: var(--shadow-lg);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .sidebar.open { transform: translateX(0); }
  .main {
    flex: 1; width: 100%;
    padding: calc(56px + env(safe-area-inset-top, 0px)) 16px calc(100px + env(safe-area-inset-bottom, 0px));
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    overflow-y: auto;
  }
  /* iOS : évite le zoom auto sur focus (inputs < 16px) */
  .station-search-input,
  .modal-input,
  .day-search-input,
  input[type="email"],
  input[type="password"],
  input[type="text"],
  input[type="search"],
  input[type="url"],
  input[type="date"],
  input[type="time"],
  select.modal-input,
  textarea {
    font-size: 16px !important;
  }
  .metrics { grid-template-columns: repeat(2,1fr); }
  .feature-grid { grid-template-columns: 1fr; }
  .route-header { flex-wrap: wrap; }
  .rh-badges { margin-left: 0; }
  .alerts-panel {
    width: calc(100vw - 32px);
    right: max(16px, env(safe-area-inset-right));
    bottom: calc(94px + env(safe-area-inset-bottom, 0px));
  }
  .notif-toast { left: 16px; right: 16px; max-width: none; }
  .welcome { margin: 40px auto; padding: 0 8px; }
  .modal {
    width: 100%;
    max-width: 100vw;
    max-height: calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
    border-radius: 16px 16px 0 0 !important;
    margin-top: auto;
  }
  .modal-overlay {
    align-items: flex-end;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .account-panel {
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .main-tabs {
    display: none !important; /* bottom-nav mobile uniquement — pas la barre sticky desktop */
    top: env(safe-area-inset-top, 0px);
  }
  .day-search-btn, .load-btn, .alert-create-btn {
    min-height: 48px;
  }
}

@media (max-width: 480px) {
  .cal-grid { gap: 3px; }
  .cal-day { min-height: 52px; padding: 4px 5px; }
  .cal-day .d-places { font-size: 14px; }
  .j-dep, .j-arr { font-size: 16px; }
}

/* ── Multi-day chips (sidebar) ──────────────────────────────────────── */
.day-add-row { display: flex; gap: 6px; align-items: stretch; }
.day-add-row .day-search-input { flex: 1; margin-bottom: 0; }
.day-add-btn {
  width: 38px; border-radius: var(--radius-xs); border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06); color: #d1d5db; font-size: 17px; font-weight: 700;
  cursor: pointer; transition: background .15s, color .15s;
}
.day-add-btn:hover { background: rgba(255,106,0,0.35); color: var(--mz-on-accent, #1C1008); }
.day-chips { display: flex; flex-wrap: wrap; gap: 5px; margin: 7px 0; }
.day-chips:empty { margin: 4px 0 3px; }
.day-chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 6px 3px 9px; border-radius: 999px;
  background: rgba(255,106,0,0.22); border: 1px solid rgba(255,106,0,0.45);
  color: #bfdbfe; font-size: 11px; font-weight: 600;
}
.day-chip-x {
  border: none; background: transparent; color: #ffb787; cursor: pointer;
  font-size: 10px; padding: 2px 3px; border-radius: 50%; line-height: 1;
}
.day-chip-x:hover { background: rgba(255,255,255,0.15); color: #fff; }

.quick-dates {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 6px;
  margin-bottom: 6px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.quick-dates::-webkit-scrollbar { display: none; }
.quick-date {
  flex: 0 0 auto;
  width: 56px;
  min-height: 64px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  border: none;
  border-radius: 12px;
  background: rgba(255,255,255,0.08);
  color: #e5e7eb;
  cursor: pointer;
  padding: 8px 4px;
  transition: background .15s, color .15s, transform .1s;
}
.quick-date:hover { background: rgba(255,255,255,0.12); }
.quick-date.selected {
  background: linear-gradient(135deg, #ff8a2a, var(--accent, #ff6a00));
  color: #fff;
}
.qd-dow { font-size: 10px; font-weight: 600; opacity: .8; text-transform: lowercase; }
.qd-num { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.qd-est { font-size: 9px; font-weight: 700; opacity: .9; }
.quick-date.qd-cal {
  color: #ffb070;
  background: rgba(255,106,0,0.12);
}
.quick-date.qd-cal.selected {
  background: rgba(255,106,0,0.28);
  color: #fff;
}
.qd-cal-icon .svg-icon { width: 16px; height: 16px; }
.sidebar-mini-cal-wrap {
  margin: 4px 0 10px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(255,255,255,0.06);
}
.sidebar-mini-cal { margin: 0; }
.smc-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.smc-month {
  font-size: 12px;
  font-weight: 700;
  color: #f3f4f6;
  text-transform: capitalize;
}
.smc-count {
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,176,112,0.9);
  font-variant-numeric: tabular-nums;
}
.smc-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 4px;
}
.smc-wd {
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  color: rgba(243,244,246,0.45);
}
.smc-grid {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.smc-grid > [role="row"] {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.smc-empty { min-height: 34px; }
.smc-day {
  border: 1px solid rgba(255,255,255,0.08); border-radius: 8px;
  background: rgba(255,255,255,0.04); color: #d1d5db;
  font-size: 12px; font-weight: 700; padding: 6px 0; cursor: pointer;
  min-height: 34px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 1px;
  transition: background .15s, border-color .15s, color .15s;
}
.smc-est { font-size: 8px; font-weight: 700; opacity: .85; line-height: 1; }
.smc-day:hover:not(:disabled) { background: rgba(255,106,0,0.25); color: var(--mz-on-accent, #1C1008); }
.smc-day.picked {
  background: rgba(255,106,0,0.5); border-color: rgba(255,106,0,0.85); color: var(--mz-on-accent, #1C1008);
  box-shadow: 0 0 0 1px rgba(255,106,0,0.25);
}
.smc-day.return-picked {
  background: rgba(56,189,248,0.45); border-color: rgba(56,189,248,0.85); color: #fff;
  box-shadow: 0 0 0 1px rgba(56,189,248,0.25);
}
.smc-day.other-leg {
  box-shadow: inset 0 0 0 1.5px rgba(255,176,112,0.55);
}
.smc-day.is-today:not(.picked):not(.return-picked) {
  border-color: rgba(255,106,0,0.55);
}
.smc-day.disabled,
.smc-day:disabled {
  opacity: .35;
  cursor: not-allowed;
}

.cal-day.picked {
  box-shadow: inset 0 0 0 2px rgba(255,106,0,0.55);
}
.cal-day.picked.selected {
  box-shadow: 0 0 0 3px rgba(255,106,0,.12), inset 0 0 0 2px rgba(255,106,0,0.55);
}

/* ── Historique des recherches (sidebar) ────────────────────────────── */
.history-section { padding: 4px 12px 8px; margin: 4px 0 0; border: none; background: transparent; }
.history-label { display: flex; align-items: center; justify-content: space-between; }
.history-clear {
  border: none; background: transparent; color: #6b7280; cursor: pointer;
  font-size: 12px; padding: 2px 5px; border-radius: var(--radius-xs);
}
.history-clear:hover { background: rgba(255,255,255,0.08); color: #f87171; }
.history-list { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.history-empty { font-size: 11px; color: #C4A990; padding: 6px 2px; }
.history-item {
  position: relative; padding: 8px 96px 8px 10px; border-radius: var(--radius-xs);
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.07);
  transition: background .15s, border-color .15s;
}
.hi-open {
  display: block; width: 100%; margin: 0; padding: 0; border: 0;
  background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer;
}
.history-item:hover { background: rgba(255,255,255,0.09); border-color: rgba(255,106,0,0.5); }
.hi-route { font-size: 12px; font-weight: 600; color: #e5e7eb; line-height: 1.35; }
.hi-arrow { color: #6b7280; }
.hi-meta { font-size: 10.5px; color: #9ca3af; margin-top: 2px; line-height: 1.4; }
.hi-time { font-size: 12px; color: #4b5563; margin-top: 2px; }
.hi-del {
  position: absolute; top: 4px; right: 4px;
  border: none; background: transparent; color: #6b7280; cursor: pointer;
  font-size: 14px; padding: 0; border-radius: 50%; line-height: 1;
  min-width: 44px; min-height: 44px; display: grid; place-items: center;
}
.hi-del:hover { background: rgba(255,255,255,0.12); color: #f87171; }

/* ── Navigation principale (onglets) ─────────────────────────────────── */
.main-tabs {
  display: flex; gap: 6px; margin-bottom: 20px;
  padding: 5px; background: var(--card);
  border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); position: sticky; top: 0; z-index: 10;
}
.main-tab {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 12px; border-radius: var(--radius-sm); border: none;
  background: transparent; color: var(--muted); font-size: 13px; font-weight: 600;
  cursor: pointer; font-family: inherit; transition: background .15s, color .15s, box-shadow .15s;
  position: relative;
}
.main-tab:hover { background: var(--bg); color: var(--text); }
.main-tab.active {
  background: var(--blue-light);
  color: var(--text); /* encre — pas orange (contraste icônes AA) */
  box-shadow: inset 0 0 0 1px rgba(255,106,0,.25);
}
:root.dark .main-tab.active { background: #3d2410; color: #FFF8F3; }
.mt-icon { font-size: 15px; }
.main-tab-badge {
  position: absolute; top: 4px; right: 8px;
  min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--amber); color: #fff; font-size: 10px; font-weight: 800;
  border-radius: 99px; display: flex; align-items: center; justify-content: center;
}
.main-tab-badge.hidden { display: none; }

/* ── Marque sur pages fixes (Trajets / Alertes / Compte) ─────────────── */
.mz-page-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 720px;
  margin: 0 auto 12px;
  padding: 4px 0 2px;
}
.mz-page-brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  object-fit: cover;
  flex-shrink: 0;
}
.mz-page-brand-name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: var(--mz-ink, var(--text));
  line-height: 1;
}
/* Sidebar déjà brandée sur Recherche — éviter le double logo */
body.app-shell.tab-planner .mz-page-brand { display: none; }

/* ── Pages Historique / Panier ───────────────────────────────────────── */
.page-panel { max-width: 720px; margin: 0 auto; color: var(--mz-ink); }
.page-panel h1, .page-panel h2, .page-panel h3 { color: var(--mz-ink); }
.page-panel p, .page-panel li, .page-panel small { color: inherit; }
.page-panel .muted, .page-panel .hint { color: var(--mz-muted); }
.page-header { margin-bottom: 18px; }
.page-header h2 { font-size: 20px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 4px; }
.page-header p { font-size: 13px; color: var(--muted); line-height: 1.5; }
.page-empty {
  text-align: center; padding: 48px 24px; color: var(--hint);
  background: var(--card); border: 1px dashed var(--border);
  border-radius: var(--radius); font-size: 14px; line-height: 1.6;
}
.page-clear-btn {
  margin-top: 16px; width: 100%; padding: 10px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: transparent; color: var(--muted); font-size: 12px; font-weight: 600;
  cursor: pointer; font-family: inherit;
}
.page-clear-btn:hover { border-color: var(--red); color: var(--red); background: var(--red-light); }

.sncf-connect-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; margin-bottom: 16px;
  background: linear-gradient(135deg, #161A22, #1a1f2b);
  color: #f9fafb; border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 600; text-decoration: none;
  box-shadow: var(--shadow-md); transition: transform .1s, box-shadow .15s;
}
.sncf-connect-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); }

.hist-list, .cart-list { display: flex; flex-direction: column; gap: 10px; }
.hist-card, .cart-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow);
  transition: border-color .15s, box-shadow .15s;
}
.hist-card:hover, .cart-card:hover { border-color: rgba(255,106,0,.3); box-shadow: var(--shadow-md); }
.hist-card-top, .cart-card-top {
  display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 6px;
}
.hist-route, .cart-route { font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
.hist-time { font-size: 11px; color: var(--hint); white-space: nowrap; }
.hist-meta { font-size: 12px; color: var(--muted); margin-bottom: 12px; line-height: 1.45; }
.hist-actions, .cart-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.hist-btn, .cart-btn {
  padding: 7px 14px; border-radius: var(--radius-xs); font-size: 12px; font-weight: 600;
  border: 1px solid var(--border); background: var(--bg); color: var(--text);
  cursor: pointer; font-family: inherit; transition: background .12s, border-color .12s;
}
a.cart-btn, a.j-book-btn, a.mz-prediction-sncf {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}
.hist-btn.primary, .cart-btn.primary {
  background: var(--blue); border-color: var(--blue); color: var(--mz-on-accent, #161A22);
}
.hist-btn.primary:hover, .cart-btn.primary:hover { background: var(--mz-accent-press, #E55F00); }
.hist-btn:hover, .cart-btn:hover { border-color: var(--blue); color: var(--blue); }

.cart-date { font-size: 12px; font-weight: 700; color: var(--blue); }
.cart-places {
  font-size: 11px; font-weight: 700; color: var(--green);
  background: var(--green-light); padding: 2px 8px; border-radius: 99px;
}
.cart-times { font-size: 14px; margin: 6px 0 12px; color: var(--text); }
.cart-num { font-size: 11px; color: var(--muted); margin-left: 8px; }
.cart-footer { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.cart-btn.large { padding: 12px 18px; font-size: 14px; }
.cart-hint {
  margin-top: 14px; font-size: 12px; color: var(--hint); line-height: 1.55;
  padding: 12px 14px; background: var(--amber-light); border-radius: var(--radius-sm);
  border: 1px solid rgba(217,119,6,.15);
}
:root.dark .cart-hint { background: #422006; color: #fcd34d; border-color: rgba(217,119,6,.2); }

.cart-progress {
  height: 8px; background: var(--border); border-radius: 99px; overflow: hidden; margin: 12px 0 14px;
}
.cart-progress-bar {
  height: 100%; background: linear-gradient(90deg, var(--green), #34d399);
  border-radius: 99px; transition: width .35s ease;
}
.cart-next-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 14px; margin-bottom: 12px;
  background: rgba(255,106,0,.08); border: 1px solid rgba(255,106,0,.25);
  border-radius: var(--radius-sm);
}
.cart-next-banner strong { display: block; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.cart-next-banner span { font-size: 13px; font-weight: 700; }
.cart-card.next { border-color: rgba(255,106,0,.45); box-shadow: 0 0 0 2px rgba(255,106,0,.12); }
.cart-card:not(.reserved)[role="button"] { cursor: pointer; }
.cart-card:not(.reserved)[role="button"]:active { transform: scale(0.995); }
.journey-card[role="button"] { cursor: pointer; }
.journey-card[role="button"]:active { background: rgba(255,106,0,.04); }
.cart-card.reserved { opacity: .72; }
.cart-card.reserved .cart-route { text-decoration: line-through; color: var(--muted); }
.cart-badge-reserved { font-size: 11px; font-weight: 700; color: var(--green); }
.cart-badge-next { font-size: 11px; font-weight: 700; color: var(--blue); }
.cart-btn.success {
  background: var(--green-light); border-color: rgba(22,163,74,.35); color: #166534;
}
.cart-btn.success:hover { background: #bbf7d0; border-color: var(--green); }

.cart-btn.auto {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border-color: transparent; color: var(--mz-on-accent, #1C1008); font-weight: 700;
}
.cart-btn.auto:hover { filter: brightness(1.06); color: var(--mz-on-accent, #1C1008); border-color: transparent; }

/* ── Navigateur SNCF intégré (web) ─────────────────────────────────── */
.booking-overlay {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: stretch; justify-content: center;
}
.booking-overlay.hidden { display: none; }
.booking-overlay-backdrop {
  position: absolute; inset: 0; background: rgba(15,17,23,.55);
  backdrop-filter: blur(4px);
}
.booking-overlay-panel {
  position: relative; z-index: 1; margin: auto;
  width: min(960px, 96vw); height: min(88vh, 900px);
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden;
}
.booking-overlay-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.booking-overlay-close {
  border: none; background: transparent; font-size: 18px; cursor: pointer; color: var(--muted);
  width: 32px; height: 32px; border-radius: 8px;
}
.booking-overlay-close:hover { background: var(--border); color: var(--text); }
.booking-overlay-frame { flex: 1; width: 100%; border: none; background: #fff; min-height: 45vh; }
.booking-overlay-frame.hidden { display: none; }
.booking-checkout-steps {
  padding: 12px 16px; border-top: 1px solid var(--border); background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.checkout-leg-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.checkout-leg-chip {
  border: 1px solid var(--border);
  background: var(--bg-elevated, #fff);
  color: var(--text);
  font: 600 12px/1.2 var(--font-ui, system-ui);
  padding: 6px 10px;
  border-radius: 999px;
  cursor: pointer;
}
.checkout-leg-chip.is-active {
  border-color: var(--mz-accent, #ff6a00);
  color: var(--mz-accent, #ff6a00);
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 10%, transparent);
}
.checkout-progress { height: 6px; background: var(--border); border-radius: 99px; overflow: hidden; margin-bottom: 10px; }
.checkout-progress-bar { height: 100%; background: var(--green); transition: width .25s ease; }
.checkout-step-title { margin: 0 0 6px; font-size: 15px; }
.checkout-step-text { margin: 0 0 10px; font-size: 13px; color: var(--muted); line-height: 1.45; }
.checkout-step-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.checkout-prefs-hint { margin: 8px 0 0; font-size: 11px; color: var(--hint); }
.booking-overlay-footer {
  padding: 10px 14px; border-top: 1px solid var(--border); background: var(--bg);
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.booking-overlay-footer p { margin: 0; font-size: 12px; color: var(--muted); flex: 1; min-width: 200px; }
body.booking-open { overflow: hidden; }

@media (max-width: 700px) {
  .booking-overlay-panel { width: 100vw; height: 100vh; border-radius: 0; }
  .cart-next-banner { flex-direction: column; align-items: stretch; }
}

/* ── Boutons réservation sur les trajets ─────────────────────────────── */
.j-booking {
  display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; align-items: center;
  margin-top: 10px; padding-top: 10px;
  border-top: 1px dashed var(--border);
}
.j-places-slot {
  margin-left: auto; display: flex; align-items: center; justify-content: center; min-width: 72px;
}
.j-places-unknown {
  font-size: 12px; font-weight: 600; color: var(--muted);
  padding: 3px 10px; border-radius: 99px; background: var(--bg); border: 1px solid var(--border);
}
.j-book-btn {
  padding: 6px 12px; border-radius: var(--radius-xs); font-size: 11px; font-weight: 700;
  border: 1px solid var(--border); cursor: pointer; font-family: inherit;
  transition: background .12s, transform .08s;
}
.j-book-btn:active { transform: scale(.97); }
.j-book-btn.verify { background: #f3f4f6; color: #374151; border-color: rgba(55,65,81,.25); }
.j-book-btn.verify:hover { background: #e5e7eb; }
.j-book-btn.j-places-verify {
  margin: 0; min-width: 72px; text-align: center; border-radius: 99px;
  padding: 4px 12px; font-size: 12px;
}
.j-book-btn.j-places-verify.verified {
  background: var(--blue-light); color: var(--mz-accent-press, #E55F00); border-color: rgba(255,106,0,.35);
  pointer-events: none;
}
:root.dark .j-book-btn.verify { background: #1f2430; color: #d1d5db; }
:root.dark .j-book-btn.j-places-verify.verified { background: #1e3a5f; color: #93c5fd; }

/* Barre d’avancement pendant « Vérifier les places depuis SNCF » */
.mz-verify-progress {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 160px;
  max-width: 260px;
  padding: 6px 2px;
}
.mz-verify-progress-label {
  font-size: 11px;
  font-weight: 650;
  color: var(--text-muted, #6b7280);
  line-height: 1.25;
}
.mz-verify-progress-track {
  height: 6px;
  border-radius: 99px;
  background: var(--border, #e5e7eb);
  overflow: hidden;
}
.mz-verify-progress-bar {
  height: 100%;
  width: 8%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--mz-accent, #ff6a00), var(--mz-accent-press, #e55f00));
  transition: width .28s ease;
}
:root.dark .mz-verify-progress-label { color: #9ca3af; }
:root.dark .mz-verify-progress-track { background: #2a2f3a; }
.j-book-btn.cart { background: var(--green-light); color: var(--green); border-color: rgba(22,163,74,.3); }
.j-book-btn.cart:hover { background: #dcfce7; }
.j-book-btn.sncf { background: var(--blue-light); color: var(--blue); border-color: rgba(255,106,0,.3); }
.j-book-btn.sncf:hover { background: var(--mz-accent-soft, rgba(255,106,0,.12)); }
.j-book-btn.sms { background: #eef2ff; color: #3730a3; border-color: rgba(55,48,163,.28); }
.j-book-btn.sms:hover { background: #e0e7ff; }
.j-book-btn.max { background: linear-gradient(135deg, #fffbeb, #fef3c7); color: #92400e; border-color: rgba(217,119,6,.35); }
.j-book-btn.max:hover { background: #fde68a; }
:root.dark .j-book-btn.cart { background: #14352a; color: #86efac; }
:root.dark .j-book-btn.sncf { background: #3d2410; color: #ffb787; }
:root.dark .j-book-btn.sms { background: #1e1b4b; color: #c7d2fe; }
:root.dark .j-book-btn.max { background: #422006; color: #fcd34d; }

/* ── Welcome ajusté avec onglets ─────────────────────────────────────── */
.welcome { max-width: 560px; margin: 24px auto 80px; text-align: center; }

@media (max-width: 700px) {
  .main-tab span:not(.mt-icon):not(.main-tab-badge) { display: none; }
  .main-tab { padding: 10px 8px; }
  .main-tab-badge { top: 2px; right: 2px; }
}

/* Favoris gares */
.favorites-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 8px; align-items: center; }
.favorites-row.hidden { display: none; }
.fav-chip {
  border: 1px solid rgba(232, 95, 0, 0.35);
  background: rgba(232, 95, 0, 0.1);
  color: #fdba74;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.fav-chip.active {
  border-color: var(--accent, #e85f00);
  background: color-mix(in srgb, var(--accent, #e85f00) 28%, transparent);
  color: #fff;
}
.fav-x { margin-left: 4px; opacity: 0.55; }
.station-suggest-row { display: flex; align-items: stretch; gap: 2px; }
.station-suggest-row.is-fav .station-suggest-item strong {
  color: var(--mz-ink, #0F172A);
  opacity: 1;
}
.station-suggest-row .station-suggest-item { flex: 1; }
.station-fav-btn {
  border: none;
  background: transparent;
  font-size: 18px;
  padding: 0;
  margin: 0;
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  flex: 0 0 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #e85f00;
}
.city-btn.is-fav {
  border-color: rgba(232, 95, 0, 0.45);
  background: rgba(232, 95, 0, 0.08);
}
.all-stations-row.is-fav { background: rgba(232, 95, 0, 0.06); }

/* Mes trajets en tête du planificateur */
.planner-saved-routes {
  margin: 0 0 14px;
  padding: 10px 0 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.planner-saved-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.planner-saved-hint {
  font-size: 11px;
  color: #9ca3af;
  margin: 0 0 8px;
  line-height: 1.35;
}
.planner-saved-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.planner-route-chip {
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.04);
  color: #e5e7eb;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}
.planner-route-chip:hover { background: rgba(255,255,255,0.08); }
.planner-route-chip.active {
  border-color: rgba(232, 95, 0, 0.55);
  background: rgba(232, 95, 0, 0.18);
  color: #fdba74;
}
.planner-save-route-btn {
  border: 1px dashed rgba(232, 95, 0, 0.45);
  background: transparent;
  color: #fdba74;
  border-radius: 8px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
}
.planner-save-route-btn.compact {
  width: auto;
  padding: 4px 8px;
  font-size: 11px;
  border-style: solid;
}
.planner-save-route-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Catalogue toutes les gares */
.all-stations {
  margin: 4px 9px 10px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  background: rgba(255,255,255,0.03);
  overflow: hidden;
}
.all-stations-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 12px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: #cbd5e1;
  list-style: none;
  user-select: none;
}
.all-stations-summary::-webkit-details-marker { display: none; }
.all-stations-summary::before {
  content: '▸';
  color: #6b7280;
  font-size: 10px;
  margin-right: 2px;
  transition: transform .15s ease;
}
.all-stations[open] > .all-stations-summary::before { transform: rotate(90deg); display: inline-block; }
.all-stations-count {
  font-size: 10px;
  font-weight: 700;
  color: #9ca3af;
  background: rgba(255,255,255,0.06);
  border-radius: 999px;
  padding: 2px 7px;
}
.all-stations-list {
  max-height: 220px;
  overflow-y: auto;
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 4px 0;
}
.all-stations-row {
  display: flex;
  align-items: stretch;
  gap: 2px;
}
.all-stations-row.active .all-stations-pick {
  background: rgba(232,93,4,0.14);
  color: #fdba74;
}
.all-stations-pick {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  text-align: left;
  border: 0;
  background: transparent;
  color: #e5e7eb;
  padding: 7px 12px;
  cursor: pointer;
}
.all-stations-pick:hover { background: rgba(255,255,255,0.05); }
.all-stations-pick strong { font-size: 12px; font-weight: 600; }
.all-stations-pick small { font-size: 10px; color: #6b7280; }

/* ── Pro polish v2 ── */
body {
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(255,106,0,.07), transparent 55%),
    radial-gradient(900px 500px at -10% 20%, rgba(255,106,0,.05), transparent 50%),
    var(--bg);
}
.sidebar-header {
  background: linear-gradient(165deg, #222833 0%, #161A22 55%, #161A22 100%);
}
.sidebar-theme-btn {
  margin-top: 10px; padding: 6px 10px; border-radius: 8px; border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.04); color: #cbd5e1; font-size: 11px; font-weight: 600; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
}
.sidebar-theme-btn:hover { background: rgba(255,255,255,.08); }
.load-btn { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); border: none; }
.load-btn:hover { filter: brightness(1.05); }
.day-search-btn { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); border: none; }

.welcome { max-width: 640px; margin: 48px auto 80px; text-align: center; padding: 0 16px; }
.welcome-hero {
  display: inline-flex; align-items: center; justify-content: center;
  width: 72px; height: 72px; border-radius: 20px; margin-bottom: 20px;
  background: linear-gradient(145deg, var(--accent-light), #fff);
  border: 1px solid rgba(255,106,0,.15);
  box-shadow: var(--shadow-md);
}
.welcome-hero svg { width: 36px; height: 36px; color: var(--accent); }
.welcome h2 { font-size: clamp(24px, 4vw, 30px); font-weight: 800; letter-spacing: -.03em; margin-bottom: 10px; }
.welcome-lead { color: var(--muted); font-size: 15px; line-height: 1.7; margin-bottom: 24px; max-width: 460px; margin-left: auto; margin-right: auto; }
.welcome-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; text-align: left; margin-top: 28px; }
.welcome-step {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow);
}
.welcome-step-num {
  display: inline-flex; width: 24px; height: 24px; align-items: center; justify-content: center;
  border-radius: 8px; background: var(--accent-light); color: var(--accent-dark);
  font-size: 12px; font-weight: 800; margin-bottom: 8px;
}
.welcome-step strong { display: block; font-size: 13px; margin-bottom: 4px; }
.welcome-step small { font-size: 12px; color: var(--muted); line-height: 1.45; }
.welcome-icon { display: none; }
.feature-grid { display: none; }

@media (max-width: 720px) {
  .welcome-steps { grid-template-columns: 1fr; }
  }

/* ── Résultats intelligents + partage ── */
.journey-section { margin-top: 18px; }
.journey-section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 10px; margin-bottom: 10px; padding: 0 2px;
}
.journey-section-head h3 {
  font-size: 13px; font-weight: 800; letter-spacing: -.01em; margin: 0;
}
.journey-section-head span { font-size: 11px; color: var(--muted); }
.journey-card.is-best {
  border-color: color-mix(in srgb, var(--accent, #ff6a00) 45%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent, #ff6a00) 20%, transparent), var(--shadow-md);
}
.j-best-tag, .j-top-tag {
  font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase;
  padding: 2px 7px; border-radius: 99px;
}
.j-best-tag { background: var(--accent, #ff6a00); color: var(--mz-on-accent, #1C1008); }
.j-top-tag { background: var(--accent-light, #fff4eb); color: var(--accent-dark, #c25200); }
.detail-actions { display: flex; align-items: center; gap: 8px; }
.share-btn.compact { padding: 5px 10px; font-size: 12px; }
.shared-banner {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 14px 16px; margin-bottom: 16px; border-radius: var(--radius);
  background: linear-gradient(135deg, var(--accent-light, #fff4eb), #fff);
  border: 1px solid color-mix(in srgb, var(--accent, #ff6a00) 25%, transparent);
}
.shared-banner p { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.shared-results { max-width: 720px; }
.shared-day-chip {
  margin-top: 8px; font-size: 11px; color: var(--muted); font-weight: 600;
}

/* Résultats trajets (vue pro) */
.results-panel { max-width: 720px; margin: 0 0 28px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.results-panel.shared { border-color: rgba(255,106,0,.25); }
.results-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 16px; flex-wrap: wrap; }
.results-head h3 { font-size: 18px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 4px; }
.results-route { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.results-digest { font-size: 13px; color: var(--text); line-height: 1.5; }
.results-actions { display: flex; gap: 8px; }
.share-btn.primary { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); color: var(--mz-on-accent, #1C1008); border: none; }
.results-grid { display: grid; gap: 10px; }
.result-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 16px; background: var(--bg); }
.result-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.result-times { display: flex; align-items: baseline; gap: 8px; font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.result-arrow { font-size: 14px; color: var(--muted); font-weight: 600; }
.result-places { font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 99px; }
.result-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; font-size: 12px; color: var(--muted); align-items: center; }
.result-tag { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--accent-light); color: var(--accent-dark); }
.result-tag.direct { background: var(--green-light); color: #166534; }
.result-day { margin-left: auto; }
.results-more { margin-top: 12px; font-size: 12px; color: var(--muted); text-align: center; }

.result-od { margin-top: 8px; font-size: 12px; font-weight: 600; color: var(--muted); }
.result-via { margin-top: 4px; font-size: 12px; font-weight: 600; color: var(--accent-dark); }
.result-legs { margin-top: 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: var(--bg); }
.result-leg { display: flex; gap: 10px; padding: 10px 12px; align-items: flex-start; border-top: 1px solid var(--border); }
.result-leg:first-child { border-top: none; }
.result-leg.connector { background: var(--accent-light); align-items: center; }
.result-leg-icon { font-weight: 800; color: var(--accent-dark); }
.result-leg-times { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 800; width: 42px; flex-shrink: 0; }
.result-leg-info strong { display: block; font-size: 12px; margin-bottom: 2px; }
.result-leg-info small { font-size: 11px; color: var(--muted); }
.result-leg.connector strong { font-size: 12px; display: block; }
.result-leg.connector small { font-size: 11px; color: var(--muted); }

.acct-trial {
  margin: 14px 0 12px;
  background: var(--mz-amber-soft, rgba(245, 158, 11, 0.14));
  border: 1px solid rgba(180, 83, 9, 0.22);
  border-radius: var(--mz-radius-sm, 12px);
  padding: 14px 16px;
  color: var(--mz-ink);
}
.acct-trial-kicker {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--mz-amber-ink, #B45309);
}
.acct-trial-title {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 700;
  color: var(--mz-ink, #1C1008);
}
.acct-trial-steps {
  margin: 0 0 12px;
  padding: 0 0 0 1.15em;
  font-size: 13px;
  color: var(--mz-ink-2, #3D2A1A);
}
.acct-trial-steps li { margin: 0 0 6px; }
.acct-trial-steps li:last-child { margin-bottom: 0; }
.acct-trial .acct-upgrade-btn { margin-top: 0; }
.acct-trial .acct-upsell-hint { margin-top: 10px; }
.account-plan-badge.plan-promo {
  background: rgba(255, 106, 0, 0.22);
  color: #ffb36b;
  margin-left: 6px;
  text-transform: none;
}
.account-plan-badge.plan-trial {
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #1C1008);
}
/* ── Compte / freemium / paywall ─────────────────────────────────────── */
.account-chip {
  display: flex; align-items: center; gap: 8px;
  width: 100%; margin-top: 10px; padding: 9px 11px;
  border-radius: 12px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: #e5e7eb;
  font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
  text-align: left; transition: background .15s, border-color .15s;
}
.account-chip:hover { background: rgba(255,255,255,0.09); }
.account-chip.logged { border-color: rgba(255,106,0,0.35); }
.account-chip-icon { opacity: .8; }
.account-plan-badge {
  margin-left: auto; font-size: 10px; font-weight: 800;
  letter-spacing: .04em; text-transform: uppercase;
  padding: 2px 7px; border-radius: 99px;
  background: rgba(255,255,255,0.1); color: #d1d5db;
}
.account-plan-badge.plan-pro,
.account-plan-badge.plan-standard { background: var(--mz-accent, #FF6A00); color: var(--mz-on-accent, #1C1008); }
.account-plan-badge.plan-auto,
.account-plan-badge.plan-premium { background: var(--mz-accent, #FF6A00); color: var(--mz-on-accent, #1C1008); }
.account-plan-badge.plan-admin { background: var(--mz-accent, #FF6A00); color: var(--mz-on-accent, #1C1008); }
.account-plan-badge.plan-free { background: rgba(255,255,255,0.12); }
.account-plan-badge.plan-lifetime { background: #16a34a; color: #fff; margin-left: 6px; }
.account-plan-badge.plan-beta { background: #7c3aed; color: #fff; margin-left: 6px; }

.acct-promo {
  display: flex; gap: 8px; margin-top: 10px;
}
.acct-promo .modal-input { flex: 1; min-width: 0; text-transform: uppercase; }
.acct-promo .acct-secondary-btn { width: auto; margin: 0; padding: 8px 14px; }
.pw-promo { margin: 0 0 14px; }
.admin-nav {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px;
}
.admin-nav[hidden] { display: none !important; }
.admin-nav-btn {
  display: inline-flex; align-items: center; min-height: 32px;
  padding: 4px 10px; border-radius: 8px;
  font-size: 11px; font-weight: 700;
  color: #1C1008; text-decoration: none;
  background: #FFB787; border: 1px solid #FF9A55;
}
.admin-nav-btn:hover { background: #FF6A00; color: #1C1008; }
:root.dark .admin-nav-btn {
  color: #1C1008;
  background: #FFB787;
  border-color: #FF9A55;
}
:root.dark .admin-nav-btn:hover {
  background: #FF6A00;
  color: #1C1008;
}
.admin-nav-btn[hidden] { display: none !important; }
.admin-nav-btn[hidden] { display: none; }

.plan-usage-bar {
  margin-top: 10px; padding: 12px;
  border-radius: 12px; background: linear-gradient(135deg, rgba(255,106,0,0.12), rgba(255,106,0,0.04));
  border: 1px solid rgba(255,106,0,0.28);
  box-shadow: 0 4px 14px rgba(255,106,0,0.08);
}
.plan-usage-bar--guest {
  background: linear-gradient(135deg, rgba(59,130,246,0.10), rgba(59,130,246,0.03));
  border-color: rgba(59,130,246,0.28);
  box-shadow: 0 4px 14px rgba(59,130,246,0.06);
}
.plan-usage-account {
  margin: 4px 0 8px;
  font-size: 11.5px;
  color: var(--mz-muted, #6b7280);
  line-height: 1.35;
}
.__PLAN_UPGRADE_MINI__ {
  margin-top: 10px; width: 100%;
  border: none; border-radius: 10px; padding: 9px 10px;
  background: linear-gradient(135deg, #ff6a00, #f59e0b); color: var(--mz-on-accent, #161A22); font: inherit; font-size: 12px;
  font-weight: 700; cursor: pointer;
  letter-spacing: 0.01em;
}
.__PLAN_UPGRADE_MINI__:hover { filter: brightness(1.08); }
.__PLAN_UPGRADE_MINI__.urgent {
  animation: planPulse 1.6s ease-in-out infinite;
  box-shadow: 0 0 0 0 rgba(255,106,0,0.45);
}
@keyframes planPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,106,0,0.35); }
  50% { box-shadow: 0 0 0 6px rgba(255,106,0,0); }
}

.auth-modal-overlay:not(.hidden) {
  z-index: 14000;
  isolation: isolate;
  background: #0f1218;
}
.auth-modal {
  position: relative;
  isolation: isolate;
  width: min(420px, 95vw);
  max-height: min(92dvh, 860px);
  overflow: hidden;
  background:
    radial-gradient(120% 80% at 100% -10%, rgba(255,106,0,0.18), transparent 55%),
    radial-gradient(90% 60% at -10% 0%, rgba(255,140,51,0.12), transparent 50%),
    #ffffff;
}
.auth-modal-glow {
  position: absolute;
  inset: 0 0 auto 0;
  height: 160px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255,106,0,0.1), transparent);
  z-index: 0;
}
.auth-modal > *:not(.auth-modal-glow) { position: relative; z-index: 1; }
.auth-modal-header {
  border-bottom: none;
  padding: 16px 20px 4px;
  background: transparent;
}
.auth-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}
.auth-brand-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--mz-accent, #FF6A00);
  box-shadow: 0 0 0 4px var(--mz-accent-soft, rgba(255,106,0,0.12));
}
.auth-brand-name {
  font-family: var(--mz-font-display, inherit);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mz-ink, #161A22);
}
.auth-close {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--mz-muted, #5C6575) !important;
}
.auth-close:hover {
  background: var(--mz-accent-soft, rgba(255,106,0,0.12));
  color: var(--mz-accent-text, #B34700) !important;
}
.auth-hero {
  padding: 4px 20px 12px;
}
.auth-hero-title {
  margin: 0;
  font-family: var(--mz-font-display, inherit);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--mz-ink, #161A22);
}
.auth-hero-sub {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--mz-muted, #5C6575);
  max-width: 34ch;
}
.auth-modal .modal-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  overflow-y: auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.auth-modal .modal-input {
  min-height: 48px;
  padding: 12px 14px;
  font-size: 16px;
  border-radius: 14px;
  border-color: var(--mz-border-strong, rgba(22,26,34,0.14));
  background: var(--mz-surface, #fff);
}
.auth-modal .modal-input:focus {
  border-color: var(--mz-accent, #FF6A00);
  box-shadow: 0 0 0 3px var(--mz-accent-soft, rgba(255,106,0,0.18));
}
.auth-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 0 18px 4px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(22, 26, 34, 0.05);
  border: 1px solid var(--mz-border, rgba(22,26,34,0.08));
  flex-shrink: 0;
}
.auth-tab {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--mz-muted, #5C6575);
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  padding: 11px 8px;
  border-radius: 11px;
  cursor: pointer;
  transition: background .15s, color .15s, box-shadow .15s;
  min-width: 0;
  line-height: 1.25;
}
.auth-tab:hover { color: var(--mz-ink, #161A22); }
.auth-tab.active {
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #161A22);
  box-shadow: 0 4px 14px rgba(255, 106, 0, 0.28);
}
:root.dark .auth-modal {
  background:
    radial-gradient(120% 80% at 100% -10%, rgba(255,106,0,0.22), transparent 55%),
    radial-gradient(90% 60% at -10% 0%, rgba(255,140,51,0.1), transparent 50%),
    #1a1410;
}
:root.dark .auth-brand-name,
:root.dark .auth-hero-title { color: #f8fafc; }
:root.dark .auth-hero-sub { color: var(--mz-muted, #C5D0E0); }
:root.dark .auth-mode-tabs { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.1); }
:root.dark .auth-tab.active {
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #161A22);
}
.auth-pwd-wrap { position: relative; display: flex; align-items: center; }
.auth-pwd-wrap .modal-input { padding-right: 88px; }
.auth-pwd-toggle {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  border: none; background: none; color: var(--muted); font: inherit;
  font-size: 12px; font-weight: 600; cursor: pointer; padding: 6px 8px;
}
.auth-pwd-toggle:hover { color: var(--accent, #ff6a00); }
.auth-reason { margin: 0; font-size: 13px; color: var(--accent, #ff6a00); }
.auth-error-box { margin: 0; }
.auth-error-box.is-on {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--mz-danger, #DC3C4D) 42%, transparent);
  background: var(--mz-danger-soft, rgba(220, 60, 77, 0.12));
  color: var(--mz-danger, #DC3C4D);
}
.auth-error { margin: 0; min-height: 0; font-size: 14px; font-weight: 700; line-height: 1.4; color: inherit; }
.auth-error:empty { display: none; }
.auth-error-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.auth-error-actions[hidden] { display: none !important; }
.auth-error-action {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px;
  border-radius: 999px; border: 1px solid color-mix(in srgb, var(--mz-danger, #DC3C4D) 50%, transparent);
  background: var(--mz-surface, #fff); color: var(--mz-danger, #DC3C4D);
  font: 700 14px/1 var(--mz-font, inherit); cursor: pointer;
}
.auth-error-box .auth-duplicate-actions { margin-top: 8px; }
.auth-submit { width: 100%; margin-top: 6px; }
.auth-switch {
  background: none; border: none; color: var(--muted); font: inherit;
  font-size: 12px; cursor: pointer; padding: 8px 0 0; text-align: center;
}
.auth-switch:hover { color: var(--accent, #ff6a00); }

.paywall-modal-overlay:not(.hidden) { z-index: 14000; }
.paywall-modal {
  position: relative;
  container-type: inline-size;
  container-name: paywall;
  max-width: min(560px, 96vw);
  width: min(560px, 96vw);
  max-height: min(92dvh, 920px);
  overflow: hidden;
  background:
    radial-gradient(120% 80% at 100% -10%, rgba(255,106,0,0.18), transparent 55%),
    radial-gradient(90% 60% at -10% 0%, rgba(255,140,51,0.10), transparent 50%),
    var(--mz-surface, #fff);
}
.pw-glow {
  position: absolute;
  inset: 0 0 auto 0;
  height: 180px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255,106,0,0.10), transparent);
  z-index: 0;
}
.paywall-modal > *:not(.pw-glow) { position: relative; z-index: 1; }
.paywall-modal-header {
  border-bottom: none;
  padding: 16px 20px 4px;
  background: transparent;
}
.pw-brand { display: flex; align-items: center; gap: 8px; }
.pw-brand-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--mz-accent, #FF6A00);
  box-shadow: 0 0 0 4px var(--mz-accent-soft, rgba(255,106,0,0.12));
}
.pw-brand-name {
  font-family: var(--mz-font-display, inherit);
  font-weight: 800; font-size: 13px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--mz-ink, #161A22);
}
.pw-close {
  width: 36px; height: 36px; border-radius: 10px;
  display: grid; place-items: center;
  color: var(--mz-muted, #5C6575) !important;
}
.pw-close:hover {
  background: var(--mz-accent-soft, rgba(255,106,0,0.12));
  color: var(--mz-accent-text, #B34700) !important;
}
.pw-hero { padding: 4px 20px 10px; }
.pw-hero-title {
  margin: 0;
  font-family: var(--mz-font-display, inherit);
  font-size: 26px; font-weight: 800;
  letter-spacing: -0.03em; line-height: 1.15;
  color: var(--mz-ink, #161A22);
}
.pw-hero-sub {
  margin: 8px 0 0;
  font-size: 14px; line-height: 1.45;
  color: var(--mz-muted, #5C6575);
  max-width: 40ch;
}
.paywall-modal .modal-body {
  overflow-y: auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
  gap: 12px;
}
.pw-value-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 4px;
}
.pw-value {
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 11px;
  border-radius: 12px;
  background: var(--mz-surface, #fff);
  border: 1px solid var(--mz-border, rgba(22,26,34,0.08));
  min-width: 0;
}
.pw-value strong {
  font-size: 12px; font-weight: 800;
  color: var(--mz-ink, #161A22);
}
.pw-value span {
  font-size: 11px; line-height: 1.3;
  color: var(--mz-muted, #5C6575);
}
.pw-message {
  margin: 0 0 6px;
  color: var(--mz-ink-2, #2C3340);
  font-size: 14px;
  line-height: 1.45;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--mz-bg, #f8fafc);
  border: 1px solid var(--mz-border, #e2e8f0);
}
.pw-message[hidden] { display: none !important; }
.pw-message.pw-message-limit {
  background: linear-gradient(135deg, #fff7ed, #fff);
  border-color: rgba(255,106,0,0.35);
  color: #9a3412;
  font-weight: 650;
}
.paywall-modal--soft {
  max-width: min(420px, 96vw);
}
.paywall-modal--soft .pw-hero-title { font-size: 22px; }
.pw-soft-preview {
  margin: 0 0 8px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--mz-ink-2, #2C3340);
}
.pw-soft-stack { display: flex; flex-direction: column; gap: 10px; }
.pw-soft-plus { margin: 0; }
.pw-soft-pro {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--mz-muted, #5C6575);
  text-align: center;
}
@media (max-width: 820px) {
  .paywall-modal--soft {
    max-width: 100vw;
  }
}
.pw-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
}
.pw-grid-plans {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: stretch;
}
/* 3 colonnes seulement si le modal lui-même est assez large.
   Le viewport ≥ 720 px laissait 3 cartes dans un dialog de 560 px :
   badges tronqués et prix qui se chevauchent. */
@container paywall (min-width: 860px) {
  .pw-grid-plans {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }
  .pw-grid-plans .pw-card { min-height: 100%; }
  .pw-grid-plans .pw-card h3 { font-size: 1rem; }
  .pw-grid-plans .pw-price { font-size: 1.2rem; }
  .pw-grid-plans .pw-benefits { font-size: 12px; }
}
/* Filet viewport : un @media (min-width: 720px) historique, ou une
   container query qui mesure le viewport, ne doit jamais remettre
   3 colonnes dans un dialog ~560–720 px. */
@media (max-width: 900px) {
  .pw-grid-plans {
    grid-template-columns: 1fr !important;
  }
  .pw-grid-plans .pw-recommended { order: -1; }
}
.pw-periods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  width: 100%;
  margin: 8px 0 4px;
}
.pw-cycle {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
  min-height: 64px;
  width: 100%;
  margin: 0;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1.5px solid #d5dbe3;
  background: #fff;
  color: #161A22;
  cursor: pointer;
  text-align: left;
  font: inherit;
  box-shadow: none;
}
.pw-cycle-year,
.pw-cycle.is-selected {
  border-color: var(--mz-accent, #FF6A00);
  background: linear-gradient(180deg, #fff7ed, #fff);
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.18);
}
.mz-locked-preview {
  position: relative;
  margin: 12px 0;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid #eadfd4;
  background: #fff;
  overflow: hidden;
}
.mz-locked-preview-ghost {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
  filter: blur(6px);
  user-select: none;
  pointer-events: none;
}
.mz-locked-preview-ghost span {
  display: block;
  height: 18px;
  border-radius: 8px;
  background: linear-gradient(90deg, #f3e6d8, #d9c4b0 40%, #f7f1ea);
}
.mz-locked-preview-ghost span:nth-child(2) { width: 72%; }
.mz-locked-preview-ghost span:nth-child(3) { width: 48%; }
.mz-locked-preview-label { margin: 0 0 12px; font-weight: 700; }
.mz-locked-horizon { margin: 12px 0 20px; }
.mz-locked-horizon-count { font-weight: 700; margin: 0 0 12px; }
.mz-locked-horizon-cards { display: grid; gap: 8px; margin: 0 0 12px; }
.mz-locked-card {
  filter: blur(6px);
  pointer-events: none;
  user-select: none;
  border-radius: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.08);
}
.mz-locked-card span {
  display: block;
  height: 10px;
  margin: 6px 0;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.35);
}
.mz-locked-card span:first-child { width: 70%; }
.mz-locked-prices { margin: 0 0 12px; }
.offers-rating, .offers-quote { margin: 8px 0; }
.pw-cycle-k {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #5C6575;
}
.pw-cycle-p {
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1.15;
  color: #161A22;
}
.pw-cycle-u {
  display: block;
  margin-top: 1px;
  font-size: 12px;
  font-weight: 650;
  color: #5C6575;
}
.pw-cycle:hover,
.pw-cycle:focus-visible {
  border-color: var(--mz-accent, #FF6A00);
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.18);
}
.pw-card-top .pw-periods { margin-top: 6px; }
.pw-checkout-error {
  margin: 12px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(220, 38, 38, 0.1);
  border: 1px solid rgba(220, 38, 38, 0.45);
  color: #991b1b;
  font-size: 0.88rem;
  line-height: 1.4;
}
.pw-checkout-error[hidden] { display: none !important; }
.pw-compare-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-top: 14px;
  max-width: 100%;
}
.pw-compare {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 12px;
}
.pw-compare th,
.pw-compare td {
  padding: 6px 8px;
  text-align: left;
  border-bottom: 1px solid var(--border, #e5e7eb);
  white-space: nowrap;
  color: var(--mz-ink, #161A22);
}
.pw-compare th:first-child {
  position: sticky;
  left: 0;
  background: var(--card, #fff);
  z-index: 1;
}
@supports not (container-type: inline-size) {
  @media (min-width: 1024px) {
    .paywall-modal:not(.paywall-modal--soft) .pw-grid-plans {
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 10px;
    }
  }
}
@media (min-width: 1024px) {
  .paywall-modal-overlay .paywall-modal:not(.paywall-modal--soft) {
    max-width: min(1040px, 94vw);
    width: min(1040px, 94vw);
  }
}
.pw-cta-ghost {
  background: transparent !important;
  color: var(--mz-ink, #161A22) !important;
  border: 1.5px solid var(--border, #e5e7eb) !important;
  box-shadow: none !important;
}
.pw-cta-ghost:hover { background: rgba(22,26,34,0.04) !important; filter: none; }
.pw-trial-chip-urgent {
  background: linear-gradient(135deg, rgba(255,106,0,0.22), rgba(255,106,0,0.10));
  border-color: rgba(255,106,0,0.45);
  font-weight: 750;
}
.acct-trial-urgent {
  border-color: rgba(255,106,0,0.45);
  background: linear-gradient(135deg, rgba(255,106,0,0.12), rgba(255,106,0,0.04));
}
.pw-trial-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--mz-accent-soft, rgba(255,106,0,0.12));
  border: 1px solid rgba(255,106,0,0.28);
  color: var(--mz-ink, #161A22);
  font-size: 13px; font-weight: 650;
}
.pw-free-note {
  font-size: 12.5px; line-height: 1.45;
  color: var(--mz-muted, #5C6575);
  padding: 2px 2px 4px;
}
.pw-card-top {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 2px;
  margin-bottom: 2px;
  min-width: 0;
}
.pw-price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  flex-wrap: wrap;
  max-width: 100%;
}
.pw-period { font-size: 13px; font-weight: 650; color: var(--mz-muted, #5C6575); }
.pw-benefits li {
  position: relative;
  padding-left: 1.35em;
}
.pw-benefits li::before {
  content: "✓";
  position: absolute; left: 0; top: 0;
  color: var(--mz-accent, #FF6A00);
  font-weight: 800;
}
@media (max-width: 820px) {
  .paywall-modal-overlay:not(.hidden) {
    align-items: flex-end;
    background: rgba(22, 26, 34, 0.55);
  }
  .paywall-modal {
    max-width: 100vw; width: 100%;
    margin-top: auto;
    border-radius: 22px 22px 0 0 !important;
    max-height: calc(100dvh - env(safe-area-inset-top, 0px) - 8px);
    box-shadow: 0 -12px 40px rgba(22, 26, 34, 0.18);
  }
  .paywall-modal::before {
    content: "";
    display: block;
    width: 36px; height: 4px; border-radius: 999px;
    background: rgba(22, 26, 34, 0.18);
    margin: 10px auto 0;
  }
  .pw-hero-title { font-size: 24px; }
  .pw-value span { font-size: 10.5px; }
  .pw-cta { min-height: 52px; font-size: 16px; }
}

/* ── Tablette / petit desktop (701–1100) : sidebar plus fine, contenu aéré ── */
@media (min-width: 701px) and (max-width: 1100px) {
  .sidebar {
    width: 220px;
    min-width: 220px;
  }
  .main,
  #mainContent {
    padding-left: 16px;
    padding-right: 16px;
  }
}

.pw-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 16px;
  padding-top: 18px;
  border-radius: 16px;
  border: 1px solid var(--border, #e5e7eb);
  background: var(--card, #fff);
  color: var(--mz-ink);
  min-width: 0;
  overflow: visible;
  transition: transform .15s ease, box-shadow .15s ease;
}
.pw-card.pw-recommended {
  transform: none;
  box-shadow: 0 12px 32px rgba(255,106,0,0.22);
  z-index: 1;
  border-width: 2px;
}
.pw-card.pw-free {
  background: color-mix(in srgb, var(--card, #fff) 92%, #161A22 8%);
}
.pw-card.pw-pro {
  border-color: #ff6a00;
  box-shadow: 0 0 0 1px rgba(255,106,0,0.2);
  background: linear-gradient(180deg, #fff7ed, #fff);
  color: #161A22;
}
.pw-ribbon-muted { background: #161A22 !important; color: #fff !important; }
.pw-ribbon {
  position: static;
  align-self: flex-start;
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 8px;
  font-size: 10px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.02em; line-height: 1.25;
  background: var(--mz-accent, #FF6A00); color: var(--mz-on-accent, #1C1008);
  padding: 3px 8px; border-radius: 99px;
  white-space: normal; overflow: visible; text-overflow: unset;
}
.pw-card h3 {
  margin: 0;
  font-size: 1.05rem;
  color: inherit;
  min-width: 0;
  padding-right: 0;
}
.pw-price { font-size: 1.35rem; font-weight: 800; color: inherit; }
.pw-tag { margin: 4px 0 10px; font-size: 12px; color: var(--mz-muted); line-height: 1.35; }
.pw-card ul {
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
  color: var(--mz-ink-2, #2C3340);
  flex: 1 1 auto;
}
.pw-card ul.pw-benefits {
  list-style: none;
  margin: 0;
  padding-left: 0;
}
.pw-benefits li {
  list-style: none;
}
.pw-card li { margin: 4px 0; }
.pw-cta {
  position: relative;
  z-index: 1;
  box-shadow: 0 8px 20px rgba(255, 106, 0, 0.28);
  margin-top: auto;
  width: 100%;
  border: none;
  border-radius: 10px;
  padding: 11px 12px;
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #1C1008);
  font: inherit;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  cursor: pointer;
  pointer-events: auto;
}
.pw-cta:hover { filter: brightness(1.06); }
.pw-cta-secondary {
  background: #161A22 !important;
  background-color: #161A22 !important;
  background-image: none !important;
  /* --mz-on-accent est l’encre #161A22 : sur ce fond, le libellé disparaissait. */
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  box-shadow: 0 8px 20px rgba(22, 26, 34, 0.18);
}
button.pw-cta.pw-cta-secondary,
.pw-card .pw-cta.pw-cta-secondary,
.pw-card.pw-auto .pw-cta.pw-cta-secondary,
.pw-card.pw-recommended .pw-cta.pw-cta-secondary,
.pw-card.pw-recommended button.pw-cta.pw-cta-secondary {
  background: #161A22 !important;
  background-color: #161A22 !important;
  background-image: none !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  opacity: 1;
}
.pw-cta-secondary:hover,
button.pw-cta.pw-cta-secondary:hover,
.pw-card .pw-cta.pw-cta-secondary:hover {
  filter: brightness(1.08);
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}
.pw-card.pw-auto {
  border-color: var(--mz-accent, #FF6A00);
  box-shadow: 0 0 0 1px rgba(255,106,0,0.22);
  background: linear-gradient(180deg, #fff7ed, #fff);
  color: #161A22;
}
.pw-card.pw-auto .pw-ribbon { background: var(--mz-accent, #FF6A00); }
.pw-card.pw-recommended .pw-cta:not(.pw-cta-secondary) {
  background: linear-gradient(135deg, var(--mz-accent, #FF6A00), var(--mz-accent-press, #E55F00));
}
.pw-card.pw-auto .pw-cta:not(.pw-cta-secondary) {
  background: linear-gradient(135deg, var(--mz-accent, #FF6A00), var(--mz-accent-press, #E55F00));
}
/* Cartes Plus/Pro : fond clair fixe → encre foncée fixe */
.pw-card.pw-pro h3, .pw-card.pw-auto h3 { color: #161A22; }
.pw-card.pw-pro .pw-price, .pw-card.pw-auto .pw-price { color: #161A22; }
.pw-card.pw-pro .pw-tag, .pw-card.pw-auto .pw-tag { color: #4B5563; }
.pw-card.pw-pro ul, .pw-card.pw-auto ul,
.pw-card.pw-pro li, .pw-card.pw-auto li { color: #374151; }
.pw-current {
  margin-top: auto;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--green, #16a34a);
  padding-top: 14px;
}
.pw-spacer { margin-top: auto; min-height: 1px; }
.pw-channels {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--mz-muted, #6b7280);
  text-align: center;
}
.pw-promo {
  margin: 0 0 14px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
}
.pw-promo-label {
  font-size: 13px;
  font-weight: 750;
  color: var(--mz-ink, #161A22);
}
.pw-promo-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.pw-promo .modal-input { flex: 1 1 180px; min-width: 0; }
.pw-recap .pw-promo { margin: 10px 0 12px; }
:root.dark .pw-message {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
  color: #e5e7eb;
}
:root.dark .pw-message.pw-message-limit {
  background: linear-gradient(135deg, #422006, #3b1010);
  border-color: rgba(255,106,0,0.4);
  color: #fdba74;
}
:root.dark .pw-card.pw-free {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
  color: #f3f4f6;
}
:root.dark .pw-card.pw-free .pw-tag,
:root.dark .pw-card.pw-free ul,
:root.dark .pw-card.pw-free li { color: #d1d5db; }
:root.dark .pw-channels { color: #9ca3af; }

.pw-manage {
  margin: 12px 0 4px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pw-manage-title {
  margin: 0;
  font-size: 13px;
  color: var(--mz-ink-2, #2C3340);
  line-height: 1.4;
}
.pw-manage .acct-secondary-btn {
  width: 100%;
  justify-content: center;
}


.account-panel {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(380px, 94vw);
  background: var(--mz-sidebar, #1C1008); color: #FFF8F3; z-index: 80;
  box-shadow: -12px 0 40px rgba(0,0,0,0.35);
  display: flex; flex-direction: column;
}
.account-panel.hidden { display: none; }
.account-panel-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 18px; border-bottom: 1px solid rgba(255,255,255,0.08);
  font-weight: 700;
}
.account-panel-header button {
  background: none; border: none; color: #9ca3af; font-size: 18px; cursor: pointer;
}
.account-panel-body { padding: 18px; overflow: auto; }
.acct-hero { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; }
.acct-avatar {
  width: 48px; height: 48px; border-radius: 14px;
  display: grid; place-items: center; font-weight: 800; font-size: 1.2rem;
  background: linear-gradient(135deg, #ff6a00, #f59e0b); color: var(--mz-on-accent, #1C1008);
  overflow: hidden; position: relative;
}
.acct-avatar img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.acct-avatar.has-photo { background: #1C1008; padding: 0; }
.acct-avatar--lg { width: 4.5rem; height: 4.5rem; font-size: 1.6rem; }
.acct-avatar-upload { cursor: pointer; }
.acct-avatar-edit {
  position: absolute; inset: auto 0 0; font-size: 0.58rem; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase; text-align: center;
  background: rgba(28, 16, 8, 0.72); color: #FFF8F3; padding: 2px 0;
}
.acct-avatar-row { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.mz-forecast-disclaimer {
  margin: 8px 0 0; font-size: 0.78rem; line-height: 1.4; color: var(--mz-ink-2, #6b5344);
}
.trends-banner.is-teaser { border-style: dashed; }
.trends-score.is-teaser { font-size: 1.1rem; }
.trends-pro-cta { margin-top: 10px; }
.acct-name { font-weight: 700; }
.account-panel .acct-email { font-size: 12px; color: #C4A990; margin: 2px 0 6px; }
.account-panel .acct-usage {
  padding: 12px; border-radius: 12px; background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08); margin-bottom: 14px;
}
.account-page .acct-usage {
  padding: 12px; border-radius: 12px; background: var(--mz-bg);
  border: 1px solid var(--mz-border); margin-bottom: 14px; color: var(--mz-ink);
}
.acct-usage-top { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 6px; }
.account-panel .acct-usage-meta { margin-top: 6px; font-size: 11px; color: #C4A990; }
.account-panel .acct-section {
  margin: 16px 0;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
}
.account-page .acct-section {
  margin: 16px 0;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--mz-border);
  background: var(--mz-surface);
  color: var(--mz-ink);
}
.acct-section-title {
  margin: 0 0 10px;
  font-size: 0.95rem;
  font-weight: 700;
}
.account-panel .acct-usage-details {
  margin: 10px 0 0;
  padding: 0 0 0 1.1rem;
  font-size: 0.8rem;
  color: #C4A990;
  line-height: 1.45;
}
.acct-sub-card {
  font-size: 0.88rem;
  line-height: 1.5;
  margin-bottom: 10px;
}
.acct-sub-card p { margin: 0 0 6px; }
.acct-success {
  margin: 0 0 14px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
}
.pw-recap {
  grid-column: 1 / -1;
  max-width: 480px;
  margin: 0 auto;
}
.pw-recap-list {
  margin: 12px 0;
  padding-left: 1.1rem;
  font-size: 0.9rem;
  line-height: 1.45;
}
.pw-disclaimer {
  margin: 10px 0;
  font-size: 0.8rem;
  color: var(--mz-muted, #5C6575);
  line-height: 1.4;
}
.acct-alerts-paused {
  margin: 12px 0;
  padding: 12px;
  border-radius: 12px;
  background: rgba(251, 146, 60, 0.12);
  border: 1px solid rgba(251, 146, 60, 0.35);
  font-size: 0.88rem;
}
.acct-features { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.account-panel .acct-feat { font-size: 13px; color: #E8EAEE; }
.account-page .acct-feat { font-size: 13px; color: var(--mz-ink-2); }
.acct-upgrade-btn, .acct-secondary-btn, .acct-logout {
  width: 100%; border-radius: 10px; padding: 11px; font: inherit; font-weight: 700;
  cursor: pointer; margin-top: 8px;
}
.acct-upgrade-btn {
  border: none;
  background: linear-gradient(135deg, #ff6a00, #f59e0b);
  color: var(--mz-on-accent, #1C1008);
}
.acct-upgrade-btn.acct-upgrade-premium {
  background: linear-gradient(135deg, var(--mz-accent, #FF6A00), var(--mz-accent-press, #E55F00));
}
.acct-upsell-card {
  margin-top: 10px; padding: 14px; border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,106,0,0.18), rgba(245,158,11,0.08));
  border: 1px solid rgba(255,106,0,0.35);
}
.acct-upsell-card.acct-upsell-premium {
  background: var(--mz-accent-soft);
  border: 1px solid rgba(255, 106, 0, 0.22);
  color: var(--mz-ink);
}
.acct-upsell-card strong { display: block; margin-bottom: 4px; font-size: 15px; }
.account-panel .acct-upsell-card p { margin: 0 0 4px; font-size: 12px; color: #E8EAEE; line-height: 1.4; }
.account-page .acct-upsell-card p { margin: 0 0 4px; font-size: 12px; color: var(--mz-ink-2); line-height: 1.4; }
.account-panel .acct-upsell-hint { margin: 8px 0 0; font-size: 11px; color: #C4A990; line-height: 1.4; }
.account-page .acct-upsell-hint, .acct-upsell-hint { margin: 8px 0 0; font-size: 11px; color: var(--mz-muted); line-height: 1.4; }
.account-panel .acct-secondary-btn {
  border: 1px solid rgba(255,255,255,0.15); background: transparent; color: #FFF8F3;
}
.account-page .acct-secondary-btn {
  border: 1px solid var(--mz-border-strong); background: transparent; color: var(--mz-ink);
}
.account-panel .acct-admin-link {
  display: inline-block; margin-top: 8px; color: #c4b4a8; font-size: 12px; font-weight: 500;
  text-decoration: underline; text-underline-offset: 2px;
}
.account-page .acct-admin-link {
  display: inline-block; margin-top: 4px; color: var(--mz-muted, #6b6560); font-size: 12px; font-weight: 500;
  text-decoration: underline; text-underline-offset: 2px;
}
.account-panel .acct-logout {
  border: 1px solid rgba(239,68,68,0.35); background: transparent; color: #fca5a5;
}

.quota-fill.unlimited { background: linear-gradient(90deg, #10b981, #34d399); }


/* Tendances / proba trajet */
.trends-banner {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(14, 116, 144, 0.08), rgba(15, 118, 110, 0.06));
  border: 1px solid rgba(14, 116, 144, 0.18);
}
.trends-banner[hidden] { display: none !important; }
.trends-banner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}
.trends-kicker {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #0e7490;
}
.trends-score {
  font-size: 18px;
  font-weight: 700;
  color: #0f766e;
  font-variant-numeric: tabular-nums;
}
.trends-score.is-low { color: #c25200; }
.trends-score.is-mid { color: #0e7490; }
.trends-score.is-high { color: #047857; }
.trends-score.is-empty { color: #6b7280; font-size: 14px; }
.trends-label {
  margin: 0;
  font-size: 12.5px;
  font-weight: 600;
  color: #134e4a;
}
.trends-advice {
  margin: 4px 0 0;
  font-size: 11px;
  color: #6b7280;
  line-height: 1.35;
}
.station-suggest-group {
  padding: 6px 10px 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--mz-muted, #5B6578);
}
.station-suggest-item .suggest-kind { display: none; }


.acct-sub-status { margin: 10px 0 0; font-size: 12px; color: var(--muted, #6b7280); }
.acct-legal { margin: 12px 0 0; font-size: 11px; color: var(--muted, #6b7280); }
.acct-legal a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }


.trends-banner {
  margin-top: 10px;
  padding: 12px 12px 10px;
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(245, 158, 11, 0.1), rgba(14, 116, 144, 0.08));
  border: 1px solid rgba(245, 158, 11, 0.28);
}
.trends-route {
  margin: 0 0 2px;
  font-size: 12.5px;
  font-weight: 700;
  color: #0f172a;
}
.trends-date {
  margin: 0 0 4px;
  font-size: 11px;
  color: #0e7490;
  font-weight: 600;
  text-transform: none !important;
}
.trends-disclaimer {
  margin: 8px 0 0;
  padding: 8px 8px 0;
  border-top: 1px dashed rgba(15, 23, 42, 0.12);
  font-size: 11px;
  line-height: 1.4;
  color: #92400e;
  font-weight: 700;
}
.trends-horizon {
  margin: 6px 0 0;
  font-size: 12.5px;
  font-weight: 750;
  line-height: 1.35;
  color: #134e4a;
}
.trends-best-days {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.trends-day-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid rgba(14, 116, 144, 0.22);
  background: rgba(14, 116, 144, 0.08);
  color: #134e4a;
  font-size: 11px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  font-family: inherit;
}
.trends-day-chip.is-best {
  background: rgba(4, 120, 87, 0.12);
  border-color: rgba(4, 120, 87, 0.35);
  color: #047857;
  box-shadow: 0 0 0 2px rgba(4, 120, 87, 0.16);
}
.trends-day-chip.is-listed {
  background: rgba(4, 120, 87, 0.14);
  color: #047857;
}
.trends-day-chip.is-low { color: #c25200; background: rgba(194, 82, 0, 0.08); }
.trends-day-chip.is-mid { color: #0e7490; }
.smc-day.is-best-forecast,
.cal-day.is-best-forecast {
  box-shadow: inset 0 0 0 2px rgba(4, 120, 87, 0.45);
}
.smc-est.is-best,
.d-est.is-best { color: #047857; }
.mz-forecast-horizon {
  margin: 8px 0 0;
  font-size: 13px;
  font-weight: 750;
  color: #134e4a;
}
.day-chip-proba {
  margin-left: 4px;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.18);
  color: #c25200;
  font-size: 10px;
  font-weight: 700;
}
.d-est {
  font-size: 12px;
  font-weight: 700;
  color: #c25200;
  font-variant-numeric: tabular-nums;
}
.d-est.soft { opacity: 0.85; }

/* Sélecteur MAX Jeune / MAX Senior */
.product-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 10px 0 4px;
}
.product-btn {
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 9px 10px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255,255,255,0.7);
  color: #64748b;
  cursor: pointer;
}
.product-btn.active {
  color: #0f172a;
  background: #fef3c7;
  border-color: #f59e0b;
  box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.25);
}
.product-hint {
  margin: 0 0 8px;
  font-size: 0.72rem;
  color: #64748b;
  line-height: 1.35;
}
.traveler-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0 2px;
}
.traveler-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: #0f172a;
}
.traveler-stepper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.traveler-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255,255,255,0.85);
  font: inherit;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  color: #0f172a;
}
.traveler-btn:disabled {
  opacity: 0.4;
  cursor: default;
}
.traveler-count {
  min-width: 1.4rem;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  font-size: 0.95rem;
}

#trendsProductTag {
  font-weight: 800;
  opacity: 0.85;
}

/* ═══════════════════════════════════════════════════════════════════════
   iOS-aligned polish (2026-07-18) — look & feel proche de l’app iPhone
   ═══════════════════════════════════════════════════════════════════════ */

:root.dark body { background: var(--bg); }
:root.dark .main {
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(255,106,0,0.08), transparent 55%),
    var(--bg);
}

.sidebar-header {
  padding: 20px 16px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: transparent;
}
:root.dark .sidebar-header { background: transparent; }

.account-chip {
  display: flex; align-items: center; gap: 8px;
  width: 100%; margin-top: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
  color: #e5e5ea;
  font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background .15s, border-color .15s;
}
.account-chip:hover {
  background: rgba(255,255,255,0.07);
  border-color: rgba(255,106,0,0.35);
}
.account-chip-icon { opacity: .7; font-size: 12px; }

.sidebar-theme-btn {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 8px; padding: 6px 10px;
  border-radius: 99px;
  border: 1px solid rgba(255,255,255,0.08);
  background: transparent;
  color: #8e8e93; font-size: 11px; font-weight: 600;
  cursor: pointer;
}
.sidebar-theme-btn:hover { color: #f5f5f7; border-color: rgba(255,255,255,0.16); }

.day-search-btn,
.load-btn {
  border-radius: var(--radius-sm) !important;
  font-weight: 700 !important;
  letter-spacing: -.01em;
}
.day-search-btn {
  background: var(--accent) !important;
  box-shadow: 0 4px 14px rgba(255,106,0,0.28);
}
.load-btn {
  background: linear-gradient(135deg, #f59e0b, var(--accent)) !important;
  box-shadow: 0 4px 16px rgba(255,106,0,0.32);
}
.load-btn .load-icon {
  display: inline-block; width: 8px; height: 8px;
  border-radius: 50%; background: rgba(255,255,255,0.85);
  margin-right: 2px;
}

.alert-create-btn {
  min-width: 64px;
  padding: 0 12px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  border-radius: var(--radius-sm) !important;
  background: rgba(255,255,255,0.06) !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  color: #e5e5ea !important;
}

.main { padding: 20px 22px 96px; }
@media (min-width: 900px) {
  .main { padding: 28px 32px 100px; }
}

.welcome {
  max-width: 440px;
  margin: 64px auto;
  padding: 28px 24px;
  text-align: left;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}
:root.dark .welcome {
  background: var(--card);
  border-color: rgba(255,255,255,0.08);
}
.welcome-icon { display: none; }
.welcome h2 {
  font-size: 22px; font-weight: 750; letter-spacing: -.03em;
  margin-bottom: 8px;
}
.welcome p, .welcome-lead {
  color: var(--muted); font-size: 14px; line-height: 1.55;
  margin-bottom: 0;
}
.welcome-status {
  margin-top: 18px;
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.journey-card {
  margin: 0 0 10px;
  padding: 14px 16px;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius) !important;
  background: var(--card);
  box-shadow: var(--shadow);
  transition: border-color .15s, transform .15s;
}
.journey-card:last-child { border-bottom: 1px solid var(--border) !important; }
.journeys-list { gap: 0; }
:root.dark .journey-card {
  background: var(--card);
  border-color: rgba(255,255,255,0.08) !important;
}
.journey-card:hover {
  border-color: rgba(255,106,0,0.35) !important;
}
.j-dep, .j-arr {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: -.03em;
}
.j-places {
  background: var(--accent-light);
  color: var(--accent);
  border-radius: 99px;
}

.cal-card, .detail-card, .route-header, .route-overview, .steps-card {
  border-radius: var(--radius) !important;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
:root.dark .cal-card,
:root.dark .detail-card,
:root.dark .route-header,
:root.dark .route-overview,
:root.dark .steps-card {
  background: var(--card) !important;
  border-color: rgba(255,255,255,0.08);
}

.main-tabs {
  background: rgba(120,120,128,0.12);
  border-radius: 12px;
  padding: 3px;
  border: none;
}
:root.dark .main-tabs { background: rgba(120,120,128,0.24); }
.main-tab {
  border-radius: 10px !important;
  border: none !important;
  font-weight: 600;
}
.main-tab.active {
  background: var(--card);
  color: var(--text);
  box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}
:root.dark .main-tab.active {
  background: #2c2c2e !important;
  color: #f5f5f7 !important;
}

.city-btn {
  border-radius: var(--radius-sm);
}
.city-btn.orig {
  background: rgba(255,106,0,0.16);
  border-color: rgba(255,106,0,0.4);
  color: #ffb787;
}
.city-btn.dest {
  background: rgba(52,199,89,0.14);
  border-color: rgba(52,199,89,0.35);
  color: #86efac;
}

.product-toggle {
  display: flex; gap: 4px;
  padding: 4px;
  margin-top: 10px;
  border-radius: 12px;
  background: rgba(255,255,255,0.05);
}
.product-btn {
  flex: 1;
  border-radius: 9px !important;
  border: none !important;
  font-weight: 700;
  font-size: 12px;
}
.product-btn.active {
  background: var(--accent) !important;
  color: var(--mz-on-accent, #161A22) !important;
}

.modal {
  border-radius: 20px !important;
  border: 1px solid var(--border);
  overflow: hidden;
}
:root.dark .modal {
  background: #1c1c1e !important;
  box-shadow: 0 24px 64px rgba(0,0,0,0.55);
}

.sidebar-toggle {
  border-radius: 12px;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  background: #ffffff !important;
  color: #161A22 !important;
  border: 1.5px solid rgba(22, 26, 34, 0.16) !important;
}
:root.dark .sidebar-toggle {
  background: #ffffff !important;
  color: #161A22 !important;
}

@media (max-width: 700px) {
  .welcome { margin: 28px 8px 48px; }
  .journey-card { margin-bottom: 8px; }
}

.welcome-kicker {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 8px;
}
.welcome-steps {
  display: flex; flex-direction: column; gap: 10px;
  margin-top: 22px;
}
.welcome-step {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: rgba(120,120,128,0.08);
}
:root.dark .welcome-step { background: rgba(120,120,128,0.16); }
.welcome-step-num {
  display: grid; place-items: center;
  width: 24px; height: 24px; flex-shrink: 0;
  border-radius: 50%;
  background: var(--accent); color: var(--mz-on-accent, #161A22);
  font-size: 12px; font-weight: 800;
}
.welcome-step strong { display: block; font-size: 13px; font-weight: 700; }
.welcome-step small { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.welcome-hero {
  width: 40px; height: 40px; margin-bottom: 14px; color: var(--accent);
}
.welcome-hero svg { width: 100%; height: 100%; }

/* ── Icônes SVG filaires ─────────────────────────────────────────── */
.svg-icon {
  width: 1.15em; height: 1.15em;
  display: inline-block; vertical-align: -0.22em;
  flex-shrink: 0;
}
.gare-icon .svg-icon { width: 16px; height: 16px; vertical-align: middle; color: var(--muted); }
.city-btn:hover .gare-icon .svg-icon, .city-btn.active .gare-icon .svg-icon { color: currentColor; }
.mt-icon .svg-icon { width: 16px; height: 16px; vertical-align: -0.18em; }
.ro-icon .svg-icon, .rp-icon .svg-icon { width: 16px; height: 16px; vertical-align: middle; }
.j-leg-icon .svg-icon, .j-conn-icon .svg-icon { width: 15px; height: 15px; vertical-align: middle; }
.feature-icon .svg-icon { width: 20px; height: 20px; color: var(--accent); }
.account-chip-icon .svg-icon { width: 14px; height: 14px; vertical-align: -0.15em; }
.history-clear .svg-icon { width: 14px; height: 14px; vertical-align: middle; }
.alerts-fab .fab-icon { width: 21px; height: 21px; vertical-align: middle; }
.alerts-panel-header .svg-icon { width: 16px; height: 16px; vertical-align: -0.2em; }
.modal-details summary .svg-icon { width: 15px; height: 15px; vertical-align: -0.18em; margin-right: 2px; }
.j-warn-hors-ville .svg-icon { width: 14px; height: 14px; vertical-align: -0.15em; }


.acct-danger-zone {
  margin-top: 1.1rem;
  padding-top: .9rem;
  border-top: 1px dashed rgba(220, 38, 38, .35);
}
.acct-danger-copy {
  font-size: 11px;
  color: #9b1c1c;
  margin: 0 0 .55rem;
  line-height: 1.35;
}
.acct-delete-btn {
  width: 100%;
  border: 1px solid rgba(220, 38, 38, .45);
  background: transparent;
  color: #b91c1c;
  border-radius: 10px;
  padding: .65rem .8rem;
  font-weight: 600;
  cursor: pointer;
}
.acct-delete-btn:hover { background: rgba(220, 38, 38, .08); }

.freshness-banner {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem .75rem;
  align-items: baseline;
  margin: 0 0 .85rem;
  padding: .55rem .75rem;
  border-radius: 10px;
  background: rgba(12, 15, 20, .04);
  font-size: 12px;
  color: var(--muted, #5a6572);
}
.freshness-banner strong { color: var(--ink, #0c0f14); font-weight: 700; }
.freshness-banner[data-stale="1"] { background: rgba(245, 158, 11, .12); color: #92400e; }

.advanced-search {
  margin-top: .65rem;
  border-top: 1px solid rgba(12,15,20,.08);
  padding-top: .45rem;
}
.advanced-search > summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--muted, #5a6572);
  font-weight: 600;
  list-style: none;
}
.advanced-search > summary::-webkit-details-marker { display: none; }
.advanced-search[open] > summary { margin-bottom: .45rem; }


/* ── Améliorations UX (2026-07-19) ───────────────────────────── */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.offline-banner {
  margin: 0 0 10px; padding: 10px 14px; border-radius: 10px;
  background: rgba(239, 68, 68, .12); color: #991b1b; font-size: 13px; font-weight: 600;
}
.captive-network-tip {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
  padding: 10px 14px;
  background: #fff7ed;
  color: #9a3412;
  border-bottom: 1px solid color-mix(in srgb, #ea580c 28%, transparent);
  font-size: 13px;
  line-height: 1.45;
  z-index: 30;
}
.captive-network-tip[hidden] { display: none !important; }
.captive-network-tip-body { flex: 1; min-width: 0; }
.captive-network-tip-body strong { display: block; margin-bottom: 2px; font-size: 13px; }
.captive-network-tip-body p { margin: 0 0 6px; font-weight: 500; }
.captive-network-tip-body ul {
  margin: 0;
  padding-left: 1.15em;
}
.captive-network-tip-body a { color: inherit; font-weight: 700; text-decoration: underline; }
.captive-network-tip-dismiss {
  flex: 0 0 auto;
  margin-top: 2px;
  padding: 6px 10px;
  border: 1px solid color-mix(in srgb, #ea580c 35%, transparent);
  border-radius: 8px;
  background: #fff;
  color: #9a3412;
  font: 700 12px/1 system-ui, sans-serif;
  cursor: pointer;
}
:root.dark .captive-network-tip {
  background: #3d2a0a;
  color: #fdba74;
  border-bottom-color: rgba(251, 146, 60, .35);
}
:root.dark .captive-network-tip-dismiss {
  background: #1c1408;
  color: #fdba74;
  border-color: rgba(251, 146, 60, .4);
}
:root.dark .offline-banner { background: rgba(239, 68, 68, .2); color: #fecaca; }
/* Promo abonnement SNCF MAX (accueil non connecté) */
.sncf-max-promo {
  margin: 20px auto 0;
  max-width: 460px;
  padding: 16px 18px;
  text-align: left;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, transparent);
  background: linear-gradient(
    145deg,
    color-mix(in srgb, var(--accent) 10%, var(--surface, #fff)) 0%,
    var(--surface, #fff) 70%
  );
}
.sncf-max-promo-kicker {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}
.sncf-max-promo-title {
  display: block;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 8px;
  color: var(--text);
}
.sncf-max-promo-lead {
  margin: 0 0 14px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}
.sncf-max-promo-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.sncf-max-promo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 700;
  text-decoration: none;
  color: #fff;
  background: var(--accent);
  border: 1px solid transparent;
}
.sncf-max-promo-btn:hover { filter: brightness(1.06); }
.sncf-max-promo-btn-alt {
  color: var(--accent-dark, var(--accent));
  background: transparent;
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
}
.sncf-max-promo-note {
  margin: 10px 0 0;
  font-size: 11px;
  color: var(--muted);
}
.auth-sncf-hint {
  margin: 14px 0 0;
  padding-top: 12px;
  border-top: 1px solid var(--border, rgba(0,0,0,.08));
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
  text-align: center;
}
.auth-sncf-hint a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
:root.dark .sncf-max-promo {
  background: linear-gradient(
    145deg,
    color-mix(in srgb, var(--accent) 16%, #1c1c1e) 0%,
    #1c1c1e 70%
  );
}
:root.dark .sncf-max-promo-btn-alt {
  color: var(--accent);
}
@media (max-width: 480px) {
  .sncf-max-promo-actions { flex-direction: column; }
  .sncf-max-promo-btn { width: 100%; }
}

.welcome-demo-row { margin: 14px 0 8px; }
.welcome-demo-btn {
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff; border-radius: 999px; padding: 10px 18px; font-weight: 700; cursor: pointer; min-height: 44px;
  box-shadow: 0 4px 14px rgba(255,106,0,.28);
}
.welcome-demo-btn:hover { filter: brightness(1.05); }
.auth-forgot {
  display: block; width: 100%; margin: 8px 0 0; border: none; background: transparent;
  color: var(--muted, #667); font-size: 13px; cursor: pointer; text-align: center; min-height: 44px;
}
.auth-duplicate-actions {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 8px;
}
.auth-duplicate-actions[hidden] { display: none !important; }
.auth-duplicate-btn {
  flex: 1 1 140px; min-height: 44px; padding: 8px 14px;
  border-radius: 999px; border: 1px solid var(--accent, #ff6a00);
  background: transparent; color: var(--accent, #ff6a00);
  font-weight: 700; font-size: 14px; cursor: pointer;
}
.auth-duplicate-btn:hover { background: rgba(255, 106, 0, 0.08); }
.auth-forgot[hidden], .auth-switch[hidden], .auth-mode-tabs[hidden],
#authNameRow[hidden], #authPassword2Row[hidden], #authPromoRow[hidden],
#authTermsRow[hidden], #authMarketingRow[hidden], #authTurnstileRow[hidden],
#authPasswordRow[hidden] { display: none !important; }
.auth-forgot:hover { color: var(--accent, #ff6a00); }
.auth-error.auth-ok { color: #15803d; }
.auth-error-box.is-ok {
  border-color: color-mix(in srgb, #15803d 40%, transparent);
  background: color-mix(in srgb, #15803d 10%, var(--mz-surface, #fff));
  color: #15803d;
}
.acct-pwd-details { margin: 12px 0; border: 1px solid var(--border, #e5e7eb); border-radius: 12px; padding: 8px 12px; }
.acct-pwd-details summary { cursor: pointer; font-weight: 600; min-height: 44px; display: flex; align-items: center; }
.acct-pwd-form { display: grid; gap: 8px; margin-top: 10px; }
.acct-pwd-error { color: #b91c1c; font-size: 13px; min-height: 1.2em; }
.history-item.pinned { border-color: rgba(255,106,0,.45); }
.hi-pin {
  position: absolute; top: 4px; right: 48px; border: none; background: transparent;
  cursor: pointer; font-size: 14px; opacity: .7; min-width: 44px; min-height: 44px;
  display: grid; place-items: center;
}
.hi-pin:hover { opacity: 1; }
.cart-checklist {
  margin: 0 0 14px; padding: 12px 14px; border-radius: 12px;
  background: rgba(255,106,0,.08); border: 1px solid rgba(255,106,0,.2); font-size: 13px;
}
.cart-checklist ul { margin: 8px 0 0; padding-left: 1.1rem; }
.cart-checklist li { margin: 4px 0; }


/* ── Combos AR + fiabilité ───────────────────────────────────────────── */
.combo-panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin: 0 0 18px;
  box-shadow: var(--shadow);
}
.combo-head { margin-bottom: 12px; }
.combo-head strong { font-size: 15px; font-weight: 800; }
.combo-sub { margin: 4px 0 0; font-size: 12px; color: var(--muted); }
.combo-grid { display: grid; gap: 10px; }
@media (min-width: 900px) {
  .combo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.combo-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  background: rgba(15, 23, 42, 0.02);
}
.combo-card-top {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px; font-size: 12px; font-weight: 700;
}
.combo-rank { color: var(--accent, #ff6a00); }
.combo-leg {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px;
  font-size: 12px; margin: 6px 0;
}
.combo-leg .leg-badge { margin-left: 0; }
.combo-dur { color: var(--muted); }
.combo-actions { display: flex; gap: 8px; margin-top: 10px; }
.combo-btn {
  font: inherit; font-size: 12px; font-weight: 700;
  padding: 8px 12px; border-radius: 10px; cursor: pointer;
  border: 1px solid var(--border); background: var(--mz-surface, #fff); color: var(--mz-ink, #0f172a);
}
.combo-btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--mz-accent-press, #e85d00));
  border: none; color: var(--mz-on-accent, #161A22);
}

.rel-badge {
  display: inline-flex; align-items: center;
  font-size: 10px; font-weight: 800; letter-spacing: 0.02em;
  padding: 2px 7px; border-radius: 999px; white-space: nowrap;
}
.rel-verified { background: rgba(22, 163, 74, 0.15); color: #15803d; }
.rel-check { background: rgba(245, 158, 11, 0.18); color: #b45309; }
.rel-opendata { background: rgba(100, 116, 139, 0.14); color: #475569; }
.rel-unknown { background: rgba(148, 163, 184, 0.2); color: #64748b; }
.j-rel-wrap { display: inline-flex; flex-direction: column; align-items: flex-end; gap: 4px; }

.cart-badge-combo {
  font-size: 11px; font-weight: 800;
  padding: 3px 8px; border-radius: 999px;
  background: var(--accent-light); color: var(--accent-dark);
}
.cart-combo-leg {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; margin: 6px 0;
}
.cart-combo-leg .leg-badge { margin-left: 0; }
.combo-cart { border-color: rgba(255, 106, 0, 0.35); }

/* ── Design system UX (2026-07-20) ─────────────────────────────────── */
.welcome-kicker {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 800; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--accent);
  margin: 0 0 10px;
}
.welcome h1, .welcome h2 {
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 30px); font-weight: 800;
  letter-spacing: -.03em; margin-bottom: 10px; line-height: 1.15;
}
.welcome-secondary-btn {
  border: 1px solid var(--border-strong); background: var(--card);
  color: var(--text); border-radius: 999px; padding: 10px 18px;
  font-weight: 650; cursor: pointer; min-height: 44px; font: inherit;
}
.welcome-secondary-btn:hover { border-color: var(--accent); color: var(--accent-dark); }
.welcome-demo-row {
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
  margin: 16px 0 8px;
}
.welcome-steps { margin-top: 28px; }
.page-empty {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.page-empty .empty-title {
  font-size: 16px; font-weight: 800; color: var(--text); letter-spacing: -.01em;
}
.page-empty .empty-cta {
  margin-top: 8px; display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 10px 18px; border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff; font-weight: 700; font-size: 13px; border: none; cursor: pointer;
  font-family: inherit; text-decoration: none;
}
.page-empty .empty-cta:hover { filter: brightness(1.05); }

.main-tabs { backdrop-filter: blur(8px); }
.main-tab { min-height: 44px; }
.main-tab[aria-selected="true"],
.main-tab.active { font-weight: 700; }

.section-label { color: #D0B79E; }

.day-search-btn, .load-btn, .modal-submit, .welcome-demo-btn {
  min-height: 44px;
}
.j-book-btn { min-height: 36px; padding: 8px 12px; }
.mz-sncf-outbound {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 100%;
}
.mz-partner-link {
  display: inline;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 600;
  color: var(--mz-muted, #5c6570);
}

.train-row {
  flex-wrap: wrap;
}
@media (max-width: 700px) {
  .train-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px 10px;
    padding: 12px 14px;
  }
  .t-time { min-width: 0; }
  .t-places { margin-left: 0; justify-self: end; }
  .t-pair-label { grid-column: 1 / -1; max-width: none; }
  .welcome-demo-row { flex-direction: column; align-items: stretch; }
  .welcome-demo-btn, .welcome-secondary-btn { width: 100%; }
  .results-panel { padding: 14px; }
  .result-times { font-size: 17px; }
  .hist-actions, .cart-actions { flex-direction: column; }
  .hist-btn, .cart-btn { width: 100%; justify-content: center; text-align: center; }
  .hist-card-top, .cart-card-top { flex-direction: column; align-items: flex-start; gap: 4px; }
  .hist-route, .cart-route { word-break: break-word; overflow-wrap: anywhere; max-width: 100%; }
  .hist-time { white-space: normal; }
  .page-panel { max-width: 100%; padding: 0 4px; }
  .favorites-row { flex-wrap: wrap; gap: 8px; }
  .fav-chip {
    color: var(--mz-ink);
    background: var(--mz-accent-soft, rgba(255,106,0,.12));
    border: 1px solid var(--mz-border-strong, rgba(22,26,34,.14));
    max-width: 100%;
  }
  .alerts-fab { bottom: calc(16px + env(safe-area-inset-bottom)); }
  .freshness-banner { font-size: 12px; padding: 10px 12px; }
}

.modal-overlay:not(.hidden) {
  animation: mzFadeIn .18s var(--mz-ease, ease);
}
@keyframes mzFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .modal-overlay:not(.hidden) { animation: none; }
}

body.modal-open { overflow: hidden; }

.auth-reason {
  background: var(--accent-light); color: var(--accent-dark);
  border: 1px solid rgba(255,106,0,.25); border-radius: 10px;
  padding: 10px 12px; margin-bottom: 12px; font-size: 13px; line-height: 1.45;
}
:root.dark .auth-reason { background: #3d2410; color: #ffb787; border-color: rgba(255,106,0,.3); }

.no-route {
  max-width: 420px; margin: 48px auto; padding: 32px 24px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.no-route-icon { color: var(--accent); }
.no-route .empty-cta { margin-top: 16px; }

.route-header .share-btn {
  min-height: 36px;
}
.rh-badge.cached { background: var(--green-light); color: #166534; border: 1px solid rgba(22,163,74,.25); }
.rh-badge.multi { background: var(--accent-light); color: var(--accent-dark); }

.account-chip #accountChipLabel {
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 120px;
}

.skeleton-block {
  height: 14px; margin: 8px 0; border-radius: 6px;
  background: linear-gradient(90deg, #ececf1 25%, #f5f5f8 50%, #ececf1 75%);
  background-size: 200% 100%;
  animation: mz-shimmer 1.4s ease-in-out infinite;
}
.skeleton-block.lg { height: 72px; }
:root.dark .skeleton-block {
  background: linear-gradient(90deg, #1a1d27 25%, #242836 50%, #1a1d27 75%);
  background-size: 200% 100%;
}

.more-cities-filter { padding: 6px 9px 8px; }
.more-cities-filter .more-city-filter { font-size: 12px; }
.more-cities .all-stations-row[hidden] { display: none; }

:root.dark .welcome-secondary-btn {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.14);
  color: #e5e7eb;
}
:root.dark .welcome-secondary-btn:hover {
  border-color: rgba(255,106,0,.5);
  color: #ffb787;
}

.alerts-list .page-empty {
  margin: 12px;
  border-style: dashed;
}
.alerts-list .empty-cta { margin-top: 10px; }


.alert-explainer {
  background: rgba(255,106,0,0.08);
  border: 1px solid rgba(255,106,0,0.28);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 4px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--muted, #6b7280);
}
.alert-explainer strong { color: var(--text, #111); display: block; margin-bottom: 6px; font-size: 13px; }
.alert-explainer ul { margin: 8px 0 6px; padding-left: 1.1rem; }
.alert-explainer li { margin: 3px 0; }
.alert-explainer-cadence { margin: 6px 0 0; font-size: 11px; opacity: .85; }
.alerts-howto {
  background: rgba(56,189,248,0.1);
  border: 1px solid rgba(56,189,248,0.28);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 10px;
  font-size: 12px;
  line-height: 1.4;
  color: #334155;
}
.alerts-howto strong { display: block; margin-bottom: 4px; }
:root.dark .alerts-howto { color: #e2e8f0; }
:root.dark .alert-explainer { color: #cbd5e1; }
:root.dark .alert-explainer strong { color: #f8fafc; }

/* ── Web version update banner — barre haute slim, jamais sur la nav / CTAs ─ */
.app-update-banner {
  position: sticky;
  top: var(--mz-topbar-offset, 64px);
  flex: 0 0 auto;
  z-index: 91;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin: 0;
  padding: 8px 16px;
  border-radius: 0;
  background: #161A22;
  color: #f3f4f6;
  box-shadow: none;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.app-update-banner[hidden] { display: none !important; }
.app-update-banner[data-force="1"] {
  background: #1C1008;
  border-bottom-color: rgba(255, 106, 0, 0.35);
}
.app-update-body { flex: 1 1 180px; min-width: 0; }
.app-update-body strong {
  display: block;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 0;
}
.app-update-body p {
  margin: 0;
  font-size: 12px;
  line-height: 1.35;
  color: #9ca3af;
}
.app-update-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.app-update-btn {
  min-height: 36px;
  padding: 6px 14px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
}
.app-update-dismiss {
  min-height: 36px;
  padding: 6px 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #e5e7eb;
  font: inherit;
  font-weight: 650;
  font-size: 13px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
body.mz-force-update { overflow: auto; }

/* Mobile : une ligne, jamais en bas (ne mange pas la bottom-nav ni les CTAs). */
@media (max-width: 700px) {
  .app-update-banner {
    position: sticky;
    top: var(--mz-topbar-offset, 64px);
    bottom: auto;
    left: auto;
    right: auto;
    z-index: 95;
    flex-wrap: nowrap;
    gap: 8px;
    padding: 6px 10px 6px 12px;
    min-height: 44px;
  }
  .app-update-body p { display: none; }
  .app-update-body strong {
    font-size: 12px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .app-update-actions { flex-wrap: nowrap; flex: 0 0 auto; }
  .app-update-btn {
    min-height: 36px;
    padding: 4px 12px;
    font-size: 12px;
  }
  .app-update-dismiss {
    min-height: 36px;
    min-width: 36px;
    padding: 4px 8px;
  }
  body.has-app-update .mz-bottom-nav {
    z-index: 120;
  }
}
@media (prefers-reduced-motion: reduce) {
  .app-update-banner,
  .app-update-btn,
  .app-update-dismiss {
    animation: none !important;
    transition: none !important;
  }
}

/* ── PWA install banner + standalone ─────────────────────────────── */
.pwa-install-banner {
  position: fixed;
  left: max(12px, env(safe-area-inset-left));
  right: max(12px, env(safe-area-inset-right));
  /* Au-dessus du FAB alertes sur mobile */
  bottom: calc(86px + env(safe-area-inset-bottom, 0px));
  z-index: 1200;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(12, 14, 20, 0.96);
  color: #f3f4f6;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.pwa-install-banner[hidden] { display: none !important; }
.pwa-install-body { flex: 1 1 180px; min-width: 0; }
.pwa-install-body strong {
  display: block;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 2px;
}
.pwa-install-body p {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: #9ca3af;
}
.pwa-install-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.pwa-install-btn {
  min-height: 40px;
  padding: 8px 16px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
}
.pwa-install-dismiss {
  min-height: 40px;
  padding: 8px 12px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: #9ca3af;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.pwa-install-dismiss:hover { color: #e5e7eb; }

@media (display-mode: standalone), (display-mode: fullscreen) {
  body.app-shell {
    /* Évite le bounce Safari en mode installé */
    overscroll-behavior: none;
  }
  .sidebar-toggle {
    top: calc(10px + env(safe-area-inset-top, 0px));
  }
}

@supports (-webkit-touch-callout: none) {
  /* Safari iOS : hauteur viewport fiable */
  @media (max-width: 700px) {
    .layout {
      height: -webkit-fill-available;
      min-height: -webkit-fill-available;
    }
  }
}


.cart-journey-steps {
  list-style: none; margin: 0 0 12px; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px;
}
.cart-journey-steps li {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 600; line-height: 1.25;
  color: var(--muted); padding: 8px 10px;
  border-radius: 10px; background: rgba(0,0,0,0.04);
  border: 1px solid var(--border);
}
.cart-journey-steps li span {
  flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; background: var(--border); color: var(--text);
}
.cart-journey-steps li.active { border-color: rgba(255,106,0,0.45); color: var(--text); background: rgba(255,106,0,0.08); }
.cart-journey-steps li.active span { background: var(--accent, #ff6a00); color: #fff; }
.cart-journey-steps li.done { border-color: rgba(22,163,74,0.35); color: var(--text); }
.cart-journey-steps li.done span { background: var(--green, #16a34a); color: #fff; }
@media (max-width: 700px) {
  .cart-journey-steps { grid-template-columns: 1fr; }
}


/* ── Sidebar chrome sticky (desktop + mobile) ───────────────────────── */
.layout { height: 100vh; height: 100dvh; }
body.app-shell .layout { height: auto !important; max-height: none !important; }
.sidebar-header .brand { margin-bottom: 10px; }
.sidebar-header .account-chip { width: 100%; justify-content: flex-start; }
.sidebar-dock .sidebar-legal {
  margin-top: 8px;
  font-size: 11px;
  line-height: 1.45;
  color: #C4A990;
}
.sidebar-dock .sidebar-legal a { color: #FFB787; }
.sidebar-dock .progress-wrap {
  padding: 8px 0 0;
}
.sidebar-dock .progress-wrap:not(.visible):not(.active) {
  display: none !important; /* sinon bande noire / piste 0% sous les CTA */
}
.trends-banner {
  margin-top: 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(0,0,0,0.2);
  padding: 10px;
}
.sidebar-mini-cal-wrap {
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.18);
}
.history-list { max-height: 180px; }


/* Honeypot anti-bot — masqué des humains, visible aux bots naïfs */
.auth-hp {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
  pointer-events: none;
}
.auth-turnstile { margin: 4px 0 2px; min-height: 65px; }


/* Home / Mes trajets / confirmations */
.home-section { margin: 22px 0 0; }
.home-section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px; margin-bottom: 10px;
}
.home-section-head h2 {
  font-family: var(--font-display);
  font-size: 1.05rem; font-weight: 750; margin: 0; letter-spacing: -.02em;
}
.home-link {
  border: 0; background: transparent; color: var(--accent);
  font-weight: 650; font-size: 0.85rem; cursor: pointer; padding: 0;
}
.home-link:disabled { opacity: .4; cursor: default; }
.home-empty { color: var(--muted); font-size: 0.92rem; line-height: 1.5; margin: 0 0 12px; }
.home-cards { display: grid; gap: 8px; }
.home-cards-routes { grid-template-columns: 1fr; }
.home-card {
  display: grid; gap: 4px; text-align: left;
  padding: 12px 14px; border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
  background: color-mix(in srgb, var(--surface, #fff) 92%, var(--accent) 8%);
}
.home-card-route {
  display: flex; align-items: stretch; gap: 0; padding: 0; overflow: hidden;
}
.home-route-main {
  flex: 1; border: 0; background: transparent; text-align: left;
  padding: 12px 14px; cursor: pointer; display: grid; gap: 2px;
}
.home-route-del {
  width: 44px; border: 0; background: transparent; color: var(--muted);
  font-size: 1.25rem; cursor: pointer;
}
.home-route-del:hover { color: var(--red, #b91c1c); background: color-mix(in srgb, #b91c1c 8%, transparent); }
.home-card-meta { font-size: 0.82rem; color: var(--muted); }
.home-card-cta {
  margin-top: 6px; justify-self: start;
  border: 0; border-radius: 999px; padding: 6px 12px;
  background: var(--accent); color: var(--mz-on-accent, #161A22); font-weight: 650; font-size: 0.82rem; cursor: pointer;
}
.home-demo-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 8px; }

.heat-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.heat-chip {
  font-size: 0.72rem; font-weight: 650; padding: 4px 8px; border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 8%, transparent); color: var(--muted);
}
.heat-chip.is-listed {
  background: color-mix(in srgb, #047857 16%, transparent); color: #047857;
}
.heat-chip.is-soft {
  background: color-mix(in srgb, var(--accent) 14%, transparent); color: #9a3f00;
}
.trends-conf {
  font-weight: 600; font-size: 0.78em; text-transform: none; letter-spacing: 0;
  color: var(--muted);
}
.trends-conf.is-listed { color: #047857; }
.trends-conf.is-soft { color: #9a3f00; }
.trends-score.is-listed { color: #047857; font-size: 15px; letter-spacing: 0.01em; }
.day-chip-proba.is-listed { color: #047857; }
.day-chip-proba.is-soft { opacity: 0.85; }
.welcome-secondary-btn.is-on {
  outline: 2px solid var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent);
}
.home-max-status .home-demo-row { flex-wrap: wrap; }

.traveler-profiles-host { margin-top: 8px; }
.traveler-profiles-list { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.traveler-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 8px; border-radius: 999px; font-size: 0.78rem; font-weight: 650;
  background: color-mix(in srgb, var(--ink) 6%, transparent);
}
.traveler-chip button { border: 0; background: transparent; cursor: pointer; color: var(--muted); }
.traveler-profiles-add { display: flex; gap: 6px; }
.traveler-profiles-add input {
  flex: 1; border-radius: 8px; border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  padding: 6px 8px; font: inherit;
}
.traveler-profiles-add button {
  width: 36px; border-radius: 8px; border: 0; background: var(--accent); color: #fff; font-weight: 700; cursor: pointer;
}

/* ── Carte Leaflet + adresse BAN ─────────────────────────────────────────── */
.place-mode-toggle {
  display: inline-flex;
  gap: 2px;
  padding: 2px;
  margin: 0 0 8px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--ink) 6%, transparent);
}
.place-mode-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  padding: 5px 10px;
  border-radius: 8px;
  cursor: pointer;
}
.place-mode-btn.active {
  background: var(--surface, #fff);
  color: var(--ink);
  box-shadow: 0 1px 2px color-mix(in srgb, var(--ink) 12%, transparent);
}
:root.dark .place-mode-btn.active { background: color-mix(in srgb, var(--ink) 14%, #1a1d26); }
.address-search-wrap { position: relative; margin-bottom: 8px; }
.address-search-wrap.hidden,
.station-search-wrap.hidden { display: none !important; }
.nearest-stations {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 8px 0 4px;
}
.nearest-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 2px;
}
.nearest-station-btn {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  text-align: left;
  border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
  background: var(--surface, #fff);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
}
.nearest-station-btn.best {
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}
.nearest-rank {
  font-size: 0.68rem;
  font-weight: 750;
  color: var(--accent);
  text-transform: uppercase;
}
.nearest-name { font-size: 0.86rem; font-weight: 650; }
.nearest-dist { font-size: 0.78rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.nearest-loading, .nearest-empty { font-size: 0.82rem; color: var(--muted); padding: 6px 2px; }

.map-page {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: calc(100vh - 120px);
  padding: 0 0 16px;
}
.map-page-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 60;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 0;
  gap: 0;
  background: var(--mz-bg, #F5F6F8);
}
.map-page-fullscreen .map-toolbar {
  padding: 10px 12px calc(8px + env(safe-area-inset-top, 0px));
  background: var(--mz-surface, #fff);
  border-bottom: 1px solid var(--mz-border, rgba(22,26,34,.08));
  flex-shrink: 0;
}
.map-fs-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.map-back-btn {
  border: 1px solid var(--mz-border-strong, rgba(22,26,34,.16));
  background: var(--mz-surface, #fff);
  color: var(--mz-ink);
  font: inherit;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 8px 12px;
  border-radius: 10px;
  cursor: pointer;
  min-height: 40px;
}
.map-back-btn:hover { border-color: var(--mz-accent); color: var(--mz-accent-text, #B34700); }
.map-fs-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--mz-ink);
}
.map-page-fullscreen .map-canvas {
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  border-radius: 0;
  border: 0;
}
.map-page-fullscreen .map-legend {
  flex-shrink: 0;
  padding: 8px 12px calc(10px + env(safe-area-inset-bottom));
  background: var(--mz-surface, #fff);
  border-top: 1px solid var(--mz-border, rgba(22,26,34,.08));
}
.map-toolbar {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  padding: 4px 2px;
}
.map-toolbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
}
.map-search-wrap { position: relative; width: 100%; }
.map-search-input {
  width: 100%;
  border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  background: var(--surface, #fff);
  color: var(--ink);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.92rem;
}
.map-suggest {
  position: absolute;
  z-index: 20;
  left: 0; right: 0; top: calc(100% + 4px);
  max-height: 240px;
  overflow: auto;
  background: var(--surface, #fff);
  border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  border-radius: 10px;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--ink) 16%, transparent);
}
.map-suggest.hidden { display: none; }
.map-suggest-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  padding: 9px 12px;
  cursor: pointer;
  font: inherit;
}
.map-suggest-item:hover { background: color-mix(in srgb, var(--accent, #ff6a00) 10%, transparent); }
.map-suggest-item strong { font-size: 0.9rem; }
.map-suggest-item small { font-size: 0.72rem; color: var(--muted); }
.map-suggest-item.muted { color: var(--muted); cursor: default; }
.map-selection { display: flex; flex-direction: column; gap: 4px; }
.map-sel-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 4px 2px;
}
.map-sel-line strong { width: 2.4rem; color: var(--muted); font-weight: 650; }
.map-sel-value { font-weight: 650; }
.map-sel-value.muted { font-weight: 500; color: var(--muted); }
.map-sel-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}
.map-sel-dot.orig { background: #0f7a52; }
.map-sel-dot.dest { background: var(--mz-accent, #FF6A00); }
.map-plan-btn {
  border: 0;
  background: var(--accent, #ff6a00);
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 10px 14px;
  border-radius: 10px;
  cursor: pointer;
}
.map-plan-btn.hidden { display: none; }
.map-plan-btn:hover { filter: brightness(1.05); }
.map-role-toggle {
  display: inline-flex;
  gap: 2px;
  padding: 2px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--ink) 6%, transparent);
}
.map-role-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 650;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
}
.map-role-btn.active {
  background: var(--surface, #fff);
  color: var(--ink);
  box-shadow: 0 1px 2px color-mix(in srgb, var(--ink) 12%, transparent);
}
.map-hint {
  margin: 0;
  flex: 1;
  font-size: 0.82rem;
  color: var(--muted);
}
.map-fit-btn {
  border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  background: var(--surface, #fff);
  color: var(--ink);
  border-radius: 8px;
  padding: 6px 10px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}
.map-canvas {
  flex: 1;
  min-height: 420px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
  background: color-mix(in srgb, var(--ink) 4%, transparent);
}
.map-error {
  padding: 24px;
  color: var(--muted);
  text-align: center;
}
.map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  font-size: 0.78rem;
  color: var(--muted);
}
.map-legend span { display: inline-flex; align-items: center; gap: 6px; }
.map-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1.5px solid #fff;
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--ink) 20%, transparent);
}
.map-dot-default { background: #64748b; }
.map-dot-orig { background: #0f7a52; }
.map-dot-dest { background: var(--mz-accent, #FF6A00); }
.map-dot-reach { background: #0b8f6a; }
.via-plan-row { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin: 6px 0 4px; font-size: 0.82rem; }
.via-plan-note { margin: 4px 0 8px; font-size: 0.78rem; color: var(--muted, #5a6070); }
.explore-fallback { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0 12px; }
.explore-book { margin-left: 8px; font-size: 0.75rem; }
.map-dot-via { background: #3b82f6; }

@media (max-width: 860px) {
  .map-page { min-height: calc(100vh - 160px); }
  .map-canvas { min-height: 360px; border-radius: 12px; }
  .main-tab span:not(.mt-icon):not(.main-tab-badge) { display: none; }
}


/* Essai bientôt expiré */
.trial-expiry-banner {
  background: linear-gradient(135deg, rgba(255,106,0,.18), rgba(255,106,0,.08));
  border-bottom: 1px solid rgba(255,106,0,.35);
  padding: 10px 14px;
}
.trial-expiry-banner[hidden] { display: none !important; }
.trial-expiry-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  max-width: 1100px;
  margin: 0 auto;
}
.trial-expiry-inner strong { font-size: 0.95rem; }
.trial-expiry-inner span { font-size: 0.85rem; color: var(--muted, #64748b); flex: 1; }
.trial-expiry-actions { display: flex; align-items: center; gap: 8px; }
.trial-expiry-dismiss {
  border: 0; background: transparent; font-size: 1.25rem; cursor: pointer;
  color: var(--muted, #64748b); line-height: 1; padding: 4px 8px;
}


/* Libellés gares sur la carte (zoom proche) */
.leaflet-tooltip.map-station-tooltip {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
  color: #0f172a;
  font-size: 11px;
  font-weight: 650;
  padding: 3px 8px;
  white-space: nowrap;
}
.leaflet-tooltip.map-station-tooltip.permanent {
  pointer-events: none;
}
.leaflet-tooltip.map-station-tooltip::before { display: none; }
.map-station-label { display: inline-block; max-width: 140px; overflow: hidden; text-overflow: ellipsis; }
:root.dark .leaflet-tooltip.map-station-tooltip {
  background: rgba(15, 23, 42, 0.92);
  border-color: rgba(255, 255, 255, 0.14);
  color: #f8fafc;
}


/* ── Onboarding 1er trajet ───────────────────────────────────────────── */
.onboarding-overlay {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 20px 16px 28px;
  background: rgba(8, 10, 16, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: onboardingFade 0.28s ease;
}
@media (min-width: 720px) {
  .onboarding-overlay { align-items: center; }
}
@keyframes onboardingFade {
  from { opacity: 0; }
  to { opacity: 1; }
}
.onboarding-card {
  width: min(420px, 100%);
  background: var(--panel, #12151e);
  color: var(--text, #f1f5f9);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  padding: 22px 20px 18px;
  box-shadow: 0 18px 48px rgba(0,0,0,0.35);
  animation: onboardingUp 0.32s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes onboardingUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}
.onboarding-kicker {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--amber, #f59e0b);
}
.onboarding-card h2 {
  margin: 0 0 8px;
  font-size: 1.35rem;
  line-height: 1.25;
}
.onboarding-copy {
  margin: 0 0 16px;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--muted, #94a3b8);
}
.onboarding-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}


/* Agenda unique — carte 30 j + actions collées à la grille */
.sidebar-mini-cal-wrap.agenda-card {
  margin: 8px 0 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.agenda-card-head { margin-bottom: 8px; }
.agenda-card-titles { display: flex; flex-direction: column; gap: 2px; }
.agenda-title {
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #fff;
  line-height: 1.2;
}
.agenda-card .date-pick-hint {
  margin: 0;
  font-size: 11px;
  line-height: 1.35;
  color: rgba(243, 244, 246, 0.5);
}
.agenda-card .smc-head { margin-bottom: 6px; }
.agenda-card .smc-month {
  font-size: 12px;
  font-weight: 700;
  text-transform: capitalize;
  color: rgba(255, 176, 112, 0.95);
}
.agenda-card .smc-grid { gap: 5px; }
.agenda-card .smc-empty { min-height: 42px; }

.agenda-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin: 8px 0 0;
  justify-content: center;
}
.agenda-leg {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 600;
  color: rgba(243, 244, 246, 0.55);
}
.agenda-leg-swatch {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
}
.agenda-selected-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 8px 0 4px;
  padding: 8px 10px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--mz-accent, #FF6A00) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--mz-accent, #FF6A00) 28%, transparent);
}
.agenda-selected-bar[hidden] { display: none !important; }
.agenda-selected-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  flex: 1;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  color: inherit;
}
.agenda-selected-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.agenda-selected-count {
  font-size: 11px;
  font-weight: 700;
  opacity: 0.85;
}
.agenda-selected-clear {
  flex-shrink: 0;
  margin: 0;
  padding: 2px 8px;
  border: 1px solid color-mix(in srgb, var(--mz-accent, #FF6A00) 35%, transparent);
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  opacity: 0.9;
}
.agenda-selected-clear:hover {
  background: color-mix(in srgb, var(--mz-accent, #FF6A00) 14%, transparent);
  opacity: 1;
}
.agenda-selected-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.agenda-selected-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--mz-accent, #FF6A00) 40%, transparent);
  background: color-mix(in srgb, var(--mz-accent, #FF6A00) 16%, transparent);
  color: inherit;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}
.agenda-selected-chip:hover {
  filter: brightness(0.97);
}
.agenda-selected-chip-x {
  opacity: 0.7;
  font-size: 13px;
  line-height: 1;
}
.agenda-selected-go {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  border-radius: 999px;
  padding: 7px 12px;
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #1C1008);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.agenda-selected-go:hover { filter: brightness(1.06); }
.agenda-selected-leg {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.agenda-selected-leg-title {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.72;
}
.agenda-selected-leg-title.is-return { color: #38bdf8; }
.agenda-selected-chip.is-return {
  border-color: color-mix(in srgb, #38bdf8 50%, transparent);
  background: color-mix(in srgb, #38bdf8 18%, transparent);
}
.agenda-selected-empty {
  font-size: 11px;
  font-weight: 600;
  opacity: 0.7;
}


.agenda-leg-swatch.heat { background: color-mix(in srgb, var(--green, #16a34a) 55%, transparent); }
.agenda-leg-swatch.trips { background: color-mix(in srgb, var(--mz-accent, #FF6A00) 55%, transparent); }
.agenda-leg-swatch.pick { background: rgba(255, 106, 0, 0.75); }
.agenda-leg-swatch.ret { background: rgba(56, 189, 248, 0.7); }

.agenda-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.agenda-scan-btn {
  width: 100%;
  min-height: 46px;
  font-size: 13px;
  font-weight: 800;
  border-radius: 12px;
}
.agenda-actions .load-scope-hint {
  margin: 0;
  font-size: 10px;
  line-height: 1.35;
  color: rgba(243, 244, 246, 0.42);
  text-align: center;
}

.smc-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  min-height: 42px;
  font-size: 13px;
}
.smc-day .smc-num { line-height: 1.1; }
.smc-day .smc-places {
  font-size: 9px;
  font-weight: 800;
  color: var(--green, #16a34a);
  line-height: 1;
}
.smc-day .smc-trips {
  font-size: 8px;
  font-weight: 700;
  color: var(--mz-accent, #FF6A00);
  line-height: 1;
  opacity: 0.95;
}
.smc-day .smc-places.zero { color: var(--muted, #94a3b8); font-weight: 600; }
.smc-day.heat-hi:not(.picked):not(.return-picked) { background: color-mix(in srgb, var(--green, #16a34a) 28%, transparent); }
.smc-day.heat-mid:not(.picked):not(.return-picked) { background: color-mix(in srgb, var(--green, #16a34a) 16%, transparent); }
.smc-day.heat-lo:not(.picked):not(.return-picked) { background: color-mix(in srgb, var(--green, #16a34a) 8%, transparent); }
.smc-day.picked .smc-places,
.smc-day.return-picked .smc-places,
.smc-day.picked .smc-trips,
.smc-day.return-picked .smc-trips { color: rgba(255,255,255,0.95); }


/* UX refonte 2026-07 */
.j-transfer-note {
  margin: 8px 0 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.mz-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 12px 0;
  padding: 10px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.mz-filter-count { font-size: 13px; font-weight: 700; margin-right: auto; }
.mz-select {
  min-height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  padding: 0 10px;
  background: var(--card);
  color: var(--text);
  font: inherit;
}
.day-search-btn:disabled { opacity: 1; color: var(--mz-ink, #1C1008); background: rgba(255,106,0,.22); cursor: wait; }
.sidebar .mz-btn-primary.day-search-btn,
.day-search-btn.mz-btn-primary { width: 100%; }
.alert-create-btn.mz-btn-secondary { flex: 1; }
.trips-page-wrap .page-panel { margin-top: 12px; }
.trips-section { margin-top: 16px; }


/* UX REFONTE VISIBLE — contraste onboarding + tabs */
.main-tabs {
  max-width: 560px;
  margin: 12px auto 20px;
}
.main-tab {
  min-height: 44px;
  font-size: 13px !important;
}
.mz-onboarding .mz-empty-actions { margin-top: 8px; }
.day-search-btn.mz-btn-primary {
  font-size: 15px !important;
  letter-spacing: -0.01em;
}


/* ─── Page Mon compte (onglet) ─────────────────────────────────────────────── */
.account-page-host { max-width: 920px; margin: 0 auto; padding-bottom: 5rem; color: var(--mz-ink); }
.account-page { display: flex; flex-direction: column; gap: 1.25rem; color: var(--mz-ink); }
.account-page h1 { font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.2; margin: 0 0 .35rem; font-family: var(--mz-font-display, inherit); }
.acct-kicker { text-transform: uppercase; letter-spacing: .06em; font-size: .75rem; color: var(--mz-muted); margin: 0 0 .5rem; }
.acct-lead { margin: 0; color: var(--mz-ink-2); max-width: 38rem; }
.account-page .acct-email { margin: .25rem 0 .5rem; font-size: .9rem; color: var(--mz-muted); opacity: 1; }
.acct-reassure, .acct-hint { font-size: .9rem; color: var(--mz-muted); margin: .75rem 0 0; }
.acct-cta-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1rem; }
.acct-guest-hero { padding: .5rem 0 1rem; }
.acct-benefit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; }
.acct-benefit-grid article { padding: 1rem 0; border-top: 1px solid color-mix(in srgb, var(--text, #111) 12%, transparent); }
.acct-benefit-grid h2 { font-size: 1rem; margin: 0 0 .35rem; }
.acct-benefit-grid p { margin: 0; font-size: .92rem; color: var(--mz-muted); }
.acct-preview { padding: 1rem 0; border-top: 1px solid color-mix(in srgb, var(--text, #111) 12%, transparent); }
.acct-preview-note { font-size: .85rem; color: var(--mz-muted); }
.acct-preview-list { list-style: none; padding: 0; margin: .75rem 0 0; display: grid; gap: .5rem; }
.acct-preview-list li { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .65rem 0; border-bottom: 1px solid color-mix(in srgb, var(--text, #111) 8%, transparent); }
.acct-preview-list em { font-style: normal; color: var(--mz-muted); font-size: .9rem; }
.acct-trust { font-size: .85rem; color: var(--mz-muted); padding: 1rem 0 2rem; border-top: 1px solid color-mix(in srgb, var(--text, #111) 10%, transparent); }
.acct-hero { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 1rem 1.25rem; padding: .25rem 0 1rem; }
.acct-avatar { width: 3.25rem; height: 3.25rem; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: var(--mz-ink, #1C1008); color: var(--mz-bg, #FFF8F3); flex-shrink: 0; overflow: hidden; position: relative; }
.acct-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
button.acct-avatar { border: 0; padding: 0; margin: 0; font: inherit; cursor: pointer; appearance: none; }
button.acct-avatar:focus-visible { outline: 2px solid var(--mz-accent, #FF6A00); outline-offset: 3px; }
.acct-avatar-dialog {
  width: min(420px, calc(100vw - 24px));
  max-height: min(92vh, 740px);
  overflow: auto;
  border: 1px solid var(--mz-border, rgba(15, 23, 42, 0.12));
  border-radius: 16px;
  background: var(--mz-surface, #fff);
  color: var(--mz-ink, #0F172A);
  padding: 1.1rem 1.15rem 1.2rem;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.28);
}
.acct-avatar-dialog::backdrop { background: rgba(15, 23, 42, 0.72); }
:root.dark .acct-avatar-dialog {
  background: #151B26;
  color: #F4F6FA;
  border-color: rgba(244, 246, 250, 0.16);
}
.acct-avatar-dialog h2 { margin: 0 0 .35rem; font-size: 1.2rem; line-height: 1.25; }
.acct-avatar-dialog p { margin: 0; color: var(--mz-ink-2, #3d4a5c); }
:root.dark .acct-avatar-dialog p { color: #E2E8F0; }
.acct-crop-frame {
  width: min(280px, 72vw);
  margin: .85rem auto;
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background: #1C1008;
  box-shadow: inset 0 0 0 2px var(--mz-border, rgba(15, 23, 42, 0.2));
}
.acct-crop-frame canvas {
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
  cursor: grab;
}
.acct-crop-frame canvas:focus-visible {
  outline: 2px solid var(--mz-accent, #FF6A00);
  outline-offset: 3px;
}
.acct-crop-frame canvas:active { cursor: grabbing; }
.acct-crop-zoom { display: grid; gap: .35rem; font-size: .9rem; margin: 0 0 .35rem; }
.acct-crop-zoom input[type="range"] { width: 100%; min-height: 44px; accent-color: var(--mz-accent, #FF6A00); }
@media (max-width: 700px) {
  .acct-avatar-row { flex-direction: column; align-items: flex-start; }
  .acct-avatar-dialog .acct-cta-row { flex-direction: column; }
  .acct-avatar-dialog .mz-btn { width: 100%; }
}
.acct-hero-text { flex: 1 1 14rem; min-width: 0; }
.acct-hero-actions { margin-left: auto; }
.acct-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; }
@media (max-width: 720px) { .acct-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); } .acct-hero-actions { width: 100%; } .acct-hero-actions .mz-btn { width: 100%; } }
.acct-metric { padding: .85rem 0; border-top: 1px solid color-mix(in srgb, var(--text, #111) 12%, transparent); }
.acct-metric-label { display: block; font-size: .78rem; color: var(--mz-muted); margin-bottom: .25rem; }
.acct-metric strong { font-size: 1.05rem; }
.acct-optin-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 1rem 0 1.25rem; padding: 1rem 1.1rem; border-radius: 14px; border: 1px solid color-mix(in srgb, var(--mz-accent, #4f46e5) 35%, transparent); background: color-mix(in srgb, var(--mz-accent, #4f46e5) 7%, transparent); }
.acct-optin-text { min-width: 0; }
.acct-optin-title { margin: 0 0 .2rem; font-size: 1.02rem; font-weight: 700; }
.acct-optin-hint { margin: 0; font-size: .88rem; color: var(--mz-muted); }
.acct-optin-switch { position: relative; display: inline-flex; align-items: center; gap: .55rem; flex: 0 0 auto; cursor: pointer; min-height: 44px; }
.acct-optin-switch input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.acct-optin-track { width: 46px; height: 26px; border-radius: 999px; background: color-mix(in srgb, var(--text, #111) 28%, transparent); position: relative; transition: background .15s; }
.acct-optin-thumb { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .15s; }
.acct-optin-switch input:checked + .acct-optin-track { background: var(--mz-accent, #4f46e5); }
.acct-optin-switch input:checked + .acct-optin-track .acct-optin-thumb { transform: translateX(20px); }
.acct-optin-switch input:focus-visible + .acct-optin-track { outline: 2px solid var(--mz-accent, #4f46e5); outline-offset: 3px; }
.acct-optin-switch input:disabled + .acct-optin-track { opacity: .6; }
.acct-optin-state { font-weight: 650; font-size: .92rem; min-width: 2.2em; }
@media (prefers-reduced-motion: reduce) { .acct-optin-track, .acct-optin-thumb { transition: none; } }
.acct-sections { display: flex; flex-direction: column; gap: .35rem; }
.acct-fold { border-top: 1px solid color-mix(in srgb, var(--text, #111) 12%, transparent); padding: .15rem 0; }
.acct-fold > summary { cursor: pointer; font-weight: 650; font-size: 1.05rem; padding: .85rem 0; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.acct-fold > summary::-webkit-details-marker { display: none; }
.acct-fold > summary::after { content: ''; width: .55rem; height: .55rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); opacity: .55; transition: transform .15s; }
.acct-fold[open] > summary::after { transform: rotate(-135deg); }
.acct-fold-body { padding: 0 0 1.1rem; }
.acct-subfold { margin-top: .75rem; }
.acct-subfold > summary { cursor: pointer; font-size: .95rem; opacity: .9; }
.acct-banner { padding: 1rem; border-radius: 12px; border: 1px solid color-mix(in srgb, var(--text, #111) 14%, transparent); display: flex; flex-direction: column; gap: .5rem; align-items: flex-start; }
.acct-banner--warn { border-color: color-mix(in srgb, #d97706 50%, transparent); background: color-mix(in srgb, #d97706 10%, transparent); }
.acct-banner--danger { border-color: color-mix(in srgb, #dc2626 50%, transparent); background: color-mix(in srgb, #dc2626 10%, transparent); }
.acct-banner--info { border-color: color-mix(in srgb, var(--mz-accent, #ff6a00) 35%, transparent); background: color-mix(in srgb, var(--mz-accent, #ff6a00) 8%, transparent); }
.acct-usage-primary { font-size: 1.15rem; margin: 0 0 .5rem; }
.acct-usage-details, .acct-feat-list, .acct-mini-list { margin: .5rem 0; padding-left: 1.1rem; }
.acct-mini-list { list-style: none; padding-left: 0; }
.acct-mini-list li { padding: .45rem 0; border-bottom: 1px solid color-mix(in srgb, var(--text, #111) 8%, transparent); display: flex; flex-wrap: wrap; gap: .5rem; align-items: baseline; justify-content: space-between; }
.acct-empty { padding: .5rem 0 1rem; }
.acct-empty h3 { margin: 0 0 .35rem; font-size: 1.05rem; }
.acct-form { display: flex; flex-direction: column; gap: .65rem; max-width: 28rem; }
.acct-check {
  display: flex;
  gap: .55rem;
  align-items: flex-start;
  font-size: .92rem;
  line-height: 1.45;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}
.acct-check input {
  margin-top: .2rem;
  flex: 0 0 auto;
  width: 1.05rem;
  height: 1.05rem;
}
.acct-check-text {
  flex: 1 1 auto;
  min-width: 0;
  display: block;
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: auto;
}
.acct-check-text a {
  display: inline;
  white-space: normal;
  word-break: normal;
  overflow-wrap: anywhere;
}
.acct-inline-row { display: flex; gap: .5rem; flex-wrap: wrap; }
.acct-inline-row .modal-input { flex: 1 1 12rem; }
.acct-link-btn { background: none; border: none; color: var(--mz-ink); cursor: pointer; padding: 0; font: inherit; text-decoration: underline; }
.acct-link-btn:focus-visible { outline: 2px solid var(--mz-accent, #ff6a00); outline-offset: 2px; }
.acct-logout-wrap { padding: 1rem 0; }
.acct-logout { background: transparent; border: 1px solid color-mix(in srgb, var(--text, #111) 20%, transparent); border-radius: 10px; padding: .65rem 1rem; cursor: pointer; font: inherit; opacity: .85; }
.acct-logout:hover { opacity: 1; }
.acct-danger-zone { margin-top: 1.25rem; padding: 1rem; border: 1px solid color-mix(in srgb, #dc2626 40%, transparent); border-radius: 12px; }
.acct-delete-btn { margin-top: .75rem; background: transparent; color: #dc2626; border: 1px solid color-mix(in srgb, #dc2626 50%, transparent); border-radius: 10px; padding: .6rem 1rem; cursor: pointer; font: inherit; }
.acct-msg { font-size: .9rem; }
.acct-msg--ok { color: #15803d; }
.acct-error { color: #b91c1c; font-size: .9rem; }
.acct-skel { border-radius: 10px; background: linear-gradient(90deg, color-mix(in srgb, var(--text,#111) 6%, transparent), color-mix(in srgb, var(--text,#111) 12%, transparent), color-mix(in srgb, var(--text,#111) 6%, transparent)); background-size: 200% 100%; animation: acctSkel 1.2s ease-in-out infinite; }
.acct-skel--hero { height: 5.5rem; }
.acct-skel--metric { height: 3.5rem; }
.acct-skel--block { height: 4.5rem; margin-top: .5rem; }
.acct-loading-label { font-size: .9rem; opacity: .65; }
@keyframes acctSkel { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) { .acct-skel { animation: none; } }
.acct-attn-badge { background: #dc2626 !important; }
.account-panel--legacy { /* fallback only */ }
.auth-terms-check { margin: .5rem 0; width: 100%; }
.auth-pwd-wrap { position: relative; display: flex; align-items: center; gap: .35rem; }
.auth-pwd-wrap .modal-input { flex: 1; }
.auth-pwd-toggle { flex-shrink: 0; font-size: .85rem; }


/* Paywall modal — dark overrides */
:root.dark .paywall-modal.modal,
:root.dark .modal.paywall-modal {
  background:
    radial-gradient(120% 80% at 100% -10%, rgba(255,106,0,0.22), transparent 55%),
    radial-gradient(90% 60% at -10% 0%, rgba(255,140,51,0.1), transparent 50%),
    #1a1410 !important;
}
:root.dark .pw-brand-name,
:root.dark .pw-hero-title { color: #f8fafc; }
:root.dark .pw-hero-sub { color: var(--mz-muted, #C5D0E0); }
:root.dark .pw-value {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.1);
}
:root.dark .pw-value strong { color: #f8fafc; }
:root.dark .pw-free-note { color: #9ca3af; }
:root.dark .pw-trial-chip { color: #ffd7b5; }
:root.dark .pw-compare th,
:root.dark .pw-compare td { color: #F4F6FA; border-color: rgba(255,255,255,0.12); }
:root.dark .pw-compare th:first-child { background: #1a1410; }
:root.dark .pw-promo-label { color: #F4F6FA; }
:root.dark .pw-checkout-error { color: #fecaca; }

/* Auth modal — dark overrides after .modal dark rules */
:root.dark .auth-modal.modal,
:root.dark .modal.auth-modal {
  background:
    radial-gradient(120% 80% at 100% -10%, rgba(255,106,0,0.22), transparent 55%),
    radial-gradient(90% 60% at -10% 0%, rgba(255,140,51,0.1), transparent 50%),
    #1a1410 !important;
}
:root.dark .auth-brand-name,
:root.dark .auth-hero-title { color: #f8fafc; }
:root.dark .auth-hero-sub { color: var(--mz-muted, #C5D0E0); }
:root.dark .auth-mode-tabs { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.1); }
:root.dark .auth-tab.active {
  background: var(--mz-accent, #FF6A00);
  color: var(--mz-on-accent, #161A22);
  box-shadow: 0 4px 14px rgba(255, 106, 0, 0.35);
}

/* Auth modal — mobile / clavier */
@media (max-width: 700px) {
  .auth-modal-overlay:not(.hidden) {
    align-items: flex-end;
    isolation: isolate;
    background: #0f1218;
  }
  .auth-modal {
    width: 100%;
    max-width: 100vw;
    height: calc(100dvh - env(safe-area-inset-top, 0px) - 8px);
    max-height: calc(100dvh - env(safe-area-inset-top, 0px) - 8px);
    min-height: calc(100dvh - env(safe-area-inset-top, 0px) - 8px);
    border-radius: 22px 22px 0 0 !important;
    margin-top: auto;
    box-shadow: 0 -12px 40px rgba(22, 26, 34, 0.18);
    display: flex;
    flex-direction: column;
  }
  .auth-modal .modal-body {
    flex: 1 1 auto;
    min-height: 0;
  }
  .auth-modal::before {
    content: "";
    display: block;
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: rgba(22, 26, 34, 0.18);
    margin: 10px auto 0;
  }
  .auth-modal-header {
    padding: 10px 16px 0;
  }
  .auth-hero {
    padding: 2px 16px 10px;
  }
  .auth-hero-title {
    font-size: 24px;
  }
  .auth-mode-tabs {
    margin: 0 14px 2px;
  }
  .auth-tab {
    font-size: 12.5px;
    padding: 12px 6px;
    min-height: 44px;
  }
  .auth-modal .modal-body {
    padding: 14px 14px calc(18px + env(safe-area-inset-bottom, 0px));
    gap: 11px;
  }
  .auth-submit {
    min-height: 52px;
    margin-top: 6px;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 700;
    box-shadow: 0 8px 20px rgba(255, 106, 0, 0.28);
  }
  .auth-forgot {
    color: var(--mz-accent-text, #B34700);
    font-weight: 600;
  }
  .acct-check {
    font-size: .88rem;
  }
  #authPassword2Row .modal-input {
    min-height: 48px;
  }
}


/* Préférences compte → suggestions destinations */
.mz-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.45rem;
}
.mz-chip {
  border: 1px solid color-mix(in srgb, var(--mz-accent, #e8a317) 35%, transparent);
  background: color-mix(in srgb, var(--mz-accent, #e8a317) 10%, transparent);
  color: inherit;
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  font: inherit;
  font-size: 0.82rem;
  cursor: pointer;
}
.mz-chip:hover { background: color-mix(in srgb, var(--mz-accent, #e8a317) 18%, transparent); }


/* Exploration one-sided / n’importe où */
.explore-anywhere {
  max-width: 560px;
  margin: 0 auto;
  padding: 20px 16px 40px;
}
.explore-anywhere h1 {
  font-size: 1.45rem;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}
.explore-dest-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 18px;
}
.explore-dest-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  border: 1px solid color-mix(in srgb, var(--border, #d8dbe3) 80%, transparent);
  background: var(--surface, #fff);
  border-radius: 14px;
  padding: 12px 14px;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition: border-color .15s ease, background .15s ease;
}
.explore-dest-item:hover {
  border-color: var(--mz-accent, #ff6a00);
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 6%, transparent);
}
.explore-dest-thumb {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 12%, transparent);
}
.explore-dest-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.explore-dest-thumb-fallback {
  background: linear-gradient(135deg, color-mix(in srgb, var(--mz-accent, #ff6a00) 35%, #fff), color-mix(in srgb, var(--mz-accent, #ff6a00) 8%, #fff));
}
.explore-dest-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.explore-dest-body strong {
  font-size: 0.98rem;
  font-weight: 650;
}
.explore-dest-body small {
  color: var(--muted, #5a6070);
  font-size: 0.78rem;
}
.explore-dest-chevron {
  color: var(--muted, #5a6070);
  font-size: 1.25rem;
  line-height: 1;
}
.station-suggest-item.is-anywhere strong {
  color: var(--mz-accent, #ff6a00);
}
.explore-origin-chip {
  display: inline-flex;
  align-items: center;
  margin-top: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px dashed color-mix(in srgb, var(--mz-accent, #ff6a00) 55%, var(--border, #d8dbe3));
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 8%, transparent);
  color: var(--mz-ink, #12151c);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}
.explore-origin-chip:hover {
  border-style: solid;
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 14%, transparent);
}
.explore-places-badge {
  flex-shrink: 0;
  padding: 4px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--mz-confirmed, #1f8f4e) 16%, transparent);
  color: var(--mz-confirmed, #1f8f4e);
  font-size: 0.72rem;
  font-weight: 700;
}
.explore-scan-status,
.explore-scan-upsell {
  margin: 8px 0 0;
  font-size: 0.82rem;
  color: var(--muted, #5a6070);
}
.explore-scan-upsell {
  color: var(--mz-accent, #ff6a00);
  font-weight: 600;
}
.map-reachable-hints {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
  align-items: center;
}
.map-reachable-hints[hidden] { display: none !important; }
.map-hints-title {
  width: 100%;
  font-size: 0.72rem;
  font-weight: 650;
  color: var(--muted, #5a6070);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 2px;
}
.map-hint-chip {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  border: 1px solid color-mix(in srgb, var(--mz-accent, #ff6a00) 35%, transparent);
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 10%, transparent);
  border-radius: 12px;
  padding: 6px 10px;
  font: inherit;
  color: inherit;
  cursor: pointer;
}
.map-hint-chip strong { font-size: 0.82rem; font-weight: 650; }
.map-hint-chip small { font-size: 0.7rem; color: var(--muted, #5a6070); }
.map-hint-chip:hover {
  background: color-mix(in srgb, var(--mz-accent, #ff6a00) 18%, transparent);
}
:root.dark .explore-dest-item {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.1);
}


/* Sidebar desktop (toujours sombre) + dark mobile : placeholders/liens AA */
@media (min-width: 701px) {
  .sidebar .station-search-input::placeholder,
  .sidebar .place-search-field input::placeholder {
    color: #C4A990;
    opacity: 1;
  }
  .sidebar .place-geo-btn { color: #FFB787; }
  .sidebar .place-geo-btn:hover { color: #FFF8F3; }
}
:root.dark .sidebar .station-search-input::placeholder,
:root.dark .sidebar .place-search-field input::placeholder {
  color: #C4A990;
  opacity: 1;
}
:root.dark .sidebar .place-geo-btn { color: #FFB787; }

/* Bannière train suivant au retour */
.mz-next-leg-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 12000;
  background: #FFF4E5; border-bottom: 1px solid rgba(179,71,0,.25);
  padding: 10px 14px; box-shadow: 0 4px 16px rgba(0,0,0,.08);
}
.mz-next-leg-inner { max-width: 720px; margin: 0 auto; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.mz-next-leg-inner strong { display: block; font-size: 13px; color: var(--text,#111); }
.mz-next-leg-inner span { display: block; font-size: 12px; color: var(--muted,#666); margin-top: 2px; }
.mz-next-leg-actions { display: flex; gap: 8px; }
.share-brand-box {
  display: flex; gap: 14px; align-items: center; margin: 4px 0 16px;
  padding: 14px 16px; border: 1px solid var(--border); border-radius: 14px;
  background: linear-gradient(135deg, #fff7f0, var(--card, #fff));
}
.share-brand-mark {
  width: 48px; height: 48px; border-radius: 12px; object-fit: cover; flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(22, 26, 34, 0.08);
}
.share-brand-meta { min-width: 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.share-brand-meta strong { display: block; color: var(--text); margin-bottom: 4px; font-size: 14px; font-weight: 800; }
.share-brand-link {
  display: block; margin-top: 8px; font-size: 12.5px; font-weight: 600;
  color: var(--accent-dark, #b34700); text-decoration: none; word-break: break-all;
}
.share-brand-link:hover { text-decoration: underline; }
.result-book {
  display: flex; flex-direction: column; gap: 8px; margin-top: 14px;
  padding-top: 12px; border-top: 1px solid var(--border);
}
.result-book .j-book-btn { width: 100%; justify-content: center; }
.result-book-hint {
  margin: 2px 0 0; font-size: 12px; color: var(--muted); line-height: 1.4;
}
.result-card.shared-featured {
  border-color: rgba(255, 106, 0, 0.45);
  box-shadow: 0 0 0 1px rgba(255, 106, 0, 0.12), var(--shadow);
}
.share-brand-hint { display: block; margin-top: 6px; font-size: 12.5px; color: var(--text); }
.results-panel.shared { max-width: min(720px, 100%); padding: clamp(14px, 3vw, 20px); }
.results-panel.shared .results-actions { flex-wrap: wrap; }
.results-panel.shared .results-actions .share-btn { flex: 1 1 auto; min-height: 40px; }
@media (max-width: 560px) {
  .share-brand-box { align-items: flex-start; padding: 12px; }
  .share-brand-mark { width: 40px; height: 40px; border-radius: 10px; }
  .results-panel.shared .results-head { gap: 10px; }
  .results-panel.shared .results-actions { width: 100%; }
  .results-panel.shared .results-actions .share-btn { flex: 1 1 calc(50% - 4px); }
}
/* legacy QR (si encore présent) */
.share-qr-box { display: flex; gap: 14px; align-items: center; margin-top: 12px; padding: 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg); }
.share-qr-box img { width: 120px; height: 120px; border-radius: 8px; background: #fff; }
.share-qr-meta { font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.share-qr-meta strong { display: block; color: var(--text); margin-bottom: 4px; font-size: 13px; }
.share-expiry-badge {
  display: inline-block; margin-top: 4px; padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.01em;
  color: #7a3b00; background: #fff4e5; border: 1px solid rgba(179, 71, 0, 0.28);
}
[data-theme="dark"] .share-expiry-badge,
html.dark .share-expiry-badge {
  color: #ffd7a8; background: rgba(179, 71, 0, 0.22); border-color: rgba(255, 180, 100, 0.35);
}
.cart-leg-row { display: flex; justify-content: space-between; gap: 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--border); font-size: 12.5px; }
.cart-leg-status { font-weight: 700; font-size: 11.5px; }
.cart-leg-status.done { color: var(--confirmed, #1B7A4A); }
.cart-leg-status.todo { color: var(--accent, #B34700); }
.cart-leg-row .cart-leg-open {
  flex-shrink: 0;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

/* Trajet partagé mis en avant */
.result-card.shared-featured {
  border: 2px solid rgba(179, 71, 0, 0.55);
  box-shadow: 0 8px 24px rgba(179, 71, 0, 0.14);
  background: linear-gradient(180deg, #FFF8F0 0%, #FFFFFF 48%);
}
.result-tag.featured {
  background: #B34700;
  color: #fff;
  font-weight: 800;
}
[data-theme="dark"] .result-card.shared-featured,
html.dark .result-card.shared-featured,
:root.dark .result-card.shared-featured {
  background: linear-gradient(180deg, rgba(179, 71, 0, 0.18) 0%, var(--mz-surface, #2A1A10) 55%);
  border-color: rgba(255, 180, 100, 0.45);
}

/* ── Landing /share/:id — trajet + App Store ─────────────────────────── */
/* :has(.share-landing) : ne pas vider /app si share-view est collé sans landing. */
body.share-view:has(.share-landing) .sidebar,
body.share-view:has(.share-landing) .sidebar-toggle,
body.share-view:has(.share-landing) .sidebar-overlay,
body.share-view:has(.share-landing) .mz-bottom-nav,
body.share-view:has(.share-landing) .main-tabs,
body.share-view:has(.share-landing) .mz-page-brand { display: none !important; }
body.share-view:has(.share-landing) .layout { display: block; height: auto; min-height: 100dvh; }
body.share-view:has(.share-landing) .main,
body.share-view:has(.share-landing) #mainContent {
  width: 100%;
  max-width: none;
  min-height: 100dvh;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.share-landing {
  width: min(560px, calc(100% - 32px));
  margin: 24px auto;
  padding: clamp(24px, 5vw, 36px) clamp(16px, 4vw, 24px);
  text-align: center;
  border: 1px solid var(--border, rgba(28, 16, 8, 0.1));
  border-radius: 20px;
  background: var(--card, var(--mz-surface, #fff));
  box-shadow: 0 12px 40px rgba(28, 16, 8, 0.08);
}
.share-landing-mark {
  width: 48px; height: 48px; border-radius: 12px; object-fit: cover;
  box-shadow: 0 4px 14px rgba(28, 16, 8, 0.12);
}
.share-landing-brand {
  margin: 12px 0 0;
  font-family: var(--font-display, Outfit, sans-serif);
  font-size: 1.25rem; font-weight: 800; letter-spacing: -0.03em;
  color: var(--text);
}
.share-landing-kicker {
  margin: 6px 0 0;
  font-size: 13px; font-weight: 600;
  color: var(--muted);
}
.share-landing-route {
  margin: 18px 0 20px;
  font-family: var(--font-display, Outfit, sans-serif);
  font-size: clamp(1.25rem, 4.2vw, 1.6rem);
  font-weight: 800; line-height: 1.25; letter-spacing: -0.03em;
  color: var(--text);
}
.share-landing-route span { color: var(--accent, #FF6A00); margin: 0 0.15em; }
.share-landing-results {
  text-align: left;
  margin: 0 0 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.share-landing-results .result-card {
  margin: 0;
}
.share-landing-hint {
  margin: 14px 0 0;
  font-size: 13px; color: var(--muted); line-height: 1.4;
}
.share-landing-web {
  display: inline-block; margin-top: 18px;
  font-size: 13px; font-weight: 600;
  color: var(--accent-dark, #b34700); text-decoration: none;
}
.share-landing-web:hover { text-decoration: underline; }
.btn-appstore {
  display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 16px 0 14px; border-radius: 12px;
  background: #0b0d12; color: #fff; text-decoration: none;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 8px 24px rgba(11, 13, 18, 0.22);
  transition: transform .15s ease, filter .15s ease;
}
.btn-appstore:hover { filter: brightness(1.08); color: #fff; }
.btn-appstore:active { transform: scale(0.98); }
.btn-appstore-block { width: 100%; justify-content: center; }
.btn-appstore-logo { flex-shrink: 0; }
.btn-appstore-copy {
  display: flex; flex-direction: column; line-height: 1.05; text-align: left;
}
.btn-appstore-copy em {
  font-style: normal; font-size: 0.68rem; font-weight: 500; opacity: 0.85;
}
.btn-appstore-copy strong {
  font-size: 1.05rem; font-weight: 700; letter-spacing: -0.02em;
}
[data-theme="dark"] .share-landing,
html.dark .share-landing {
  background: var(--mz-surface, #2A1A10);
  border-color: rgba(255, 180, 100, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}


/* ── Bandeau dates résultats (+ Dates / 30 jours) ───────────────────── */
.mz-results-days {
  margin: 10px 0 14px;
  padding: 12px;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 14px;
  background: var(--surface, #fff);
}
.mz-results-days-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.mz-results-days-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  flex: 1;
  min-width: 0;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
}
.mz-results-days-empty {
  font-size: 12px;
  color: var(--text-muted, #6b7280);
  white-space: nowrap;
}
.mz-results-days-note {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.35;
  color: var(--text-muted, #6b7280);
}
.mz-results-day-chip {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid var(--border-strong, #d1d5db);
  background: var(--surface, #fff);
  cursor: pointer;
  font-family: inherit;
  flex-shrink: 0;
}
.mz-results-day-chip.active {
  background: var(--mz-accent-soft, rgba(255,106,0,.12));
  border-color: rgba(255,106,0,.45);
}
.mz-results-day-chip.is-empty {
  opacity: 0.72;
  border-style: dashed;
}
.mz-results-day-chip.is-empty .mz-rdc-count {
  color: var(--text-muted, #9ca3af);
}
.mz-rdc-label {
  font-size: 12px;
  font-weight: 650;
  color: var(--text, #111);
}
.mz-rdc-count {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted, #6b7280);
}
.mz-rdc-pct {
  font-size: 10px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #c25200;
}
.mz-results-day-chip.is-best-forecast {
  border-color: rgba(4, 120, 87, 0.45);
}
.mz-results-days-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}
.mz-results-add-btn,
.mz-results-30-btn {
  padding: 8px 12px !important;
  font-size: 12px !important;
  white-space: nowrap;
}
.mz-results-add-panel {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border, #e5e7eb);
}
.mz-results-add-hint {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--text-muted, #6b7280);
  line-height: 1.4;
}
.mz-results-add-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 160px;
  overflow-y: auto;
  margin-bottom: 10px;
}
.mz-results-add-day {
  padding: 6px 10px;
  border-radius: 99px;
  border: 1px solid var(--border, #e5e7eb);
  background: var(--surface-2, #f9fafb);
  font-size: 11px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  color: var(--text, #111);
}
.mz-results-add-day.on {
  background: var(--mz-accent, #ff6a00);
  border-color: var(--mz-accent, #ff6a00);
  color: #fff;
}
.mz-results-add-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
:root.dark .mz-results-days { background: #1a1f2a; border-color: #2a2f3a; }
:root.dark .mz-results-day-chip { background: #12161f; border-color: #2a2f3a; }
:root.dark .mz-rdc-label { color: #e5e7eb; }
:root.dark .mz-results-add-day { background: #12161f; color: #e5e7eb; border-color: #2a2f3a; }


/* Créneaux alerte (multi Pro) */
.alert-daypart-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; }
.alert-daypart-chip {
  border: 1px solid var(--border, #d8dde6);
  background: var(--subtle-fill, #f3f5f8);
  color: var(--ink, #1a1f2c);
  font: 600 13px/1.2 inherit;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
}
.alert-daypart-chip[aria-pressed="true"] {
  background: var(--signal, #0b6bcb);
  border-color: transparent;
  color: var(--on-signal, #fff);
}
.alert-kind-toggle { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 8px; }
.alerts-section-title {
  margin: 18px 0 8px;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.alert-occ, .alert-history { margin: 8px 0; font-size: 13px; }
.alert-occ ul, .alert-history ol { margin: 6px 0 0; padding-left: 18px; }
button.linkish {
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

/* ══ Recherche simplifiée (OD compact + meta) ═══════════════════════════ */
.sidebar-od-card { padding-bottom: 10px; }
.od-field-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(243, 244, 246, 0.48);
  margin: 0 0 6px;
}
.od-stack .station-search-wrap { padding-bottom: 0; }
.od-swap {
  justify-content: center;
  padding: 2px 0;
  margin: -2px 0;
  position: relative;
  z-index: 2;
}
.od-swap .swap-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  background: rgba(255, 106, 0, 0.16);
  border-color: rgba(255, 106, 0, 0.4);
  color: #ffb070;
}
.od-swap .swap-btn:hover {
  background: rgba(255, 106, 0, 0.28);
  color: #fff;
}
.place-geo-btn.place-geo-icon {
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  width: 32px;
  height: 32px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: rgba(243, 244, 246, 0.55);
  z-index: 1;
}
.place-geo-btn.place-geo-icon:hover {
  color: #ffb070;
  background: rgba(255, 106, 0, 0.12);
}
.place-search-bar .place-search-field .station-search-input {
  padding-left: 40px;
  border-radius: 12px;
}
.place-aux-link.explore-origin-chip {
  display: inline-flex;
  margin: 10px 0 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #FFB787;
  font-size: 12px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.place-aux-link.explore-origin-chip:hover {
  color: #FFF8F3;
  background: transparent;
  border: 0;
}
.search-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}
.search-meta-row .product-toggle {
  flex: 1;
  margin: 0;
  min-width: 0;
}
.search-meta-row .traveler-row {
  margin: 0;
  flex-shrink: 0;
  gap: 6px;
  padding: 4px 6px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
}
.search-meta-row .traveler-label {
  color: rgba(243, 244, 246, 0.65);
  font-size: 11px;
  font-weight: 650;
}
.search-meta-row .traveler-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: #f5f5f7;
}
.search-meta-row .traveler-count {
  color: #f5f5f7;
  font-size: 0.88rem;
}
.day-search .product-hint {
  margin: 6px 0 0;
  color: rgba(243, 244, 246, 0.45);
}
.day-search .agenda-legend {
  margin-top: 6px;
  gap: 8px;
  opacity: 0.75;
}
.day-search .date-pick-hint {
  font-size: 11px;
  margin: 0;
  color: rgba(243, 244, 246, 0.42);
}
.day-search .date-plan-limit {
  font-size: 11px;
  margin: 2px 0 0;
  color: rgba(255, 183, 135, 0.85);
}
.sidebar-advanced[open] {
  padding: 8px 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.sidebar-advanced summary {
  font-weight: 650;
  color: rgba(243, 244, 246, 0.62);
  padding: 6px 0;
}
.sidebar-advanced summary::before {
  content: "▸ ";
  color: rgba(255, 106, 0, 0.8);
}
.sidebar-advanced[open] summary::before { content: "▾ "; }
.sidebar-advanced .via-block {
  margin: 8px 0 10px;
  padding: 0;
  border: 0;
}
.sidebar-advanced .date-presets-more { margin: 8px 0; }
.sidebar-advanced .mz-toggle-row { margin: 8px 0; }
.mz-sncf-note {
  margin: 4px 16px 12px;
  font-size: 11px;
  line-height: 1.4;
  color: rgba(243, 244, 246, 0.42);
}
.mz-sncf-note strong { color: rgba(255, 183, 135, 0.9); font-weight: 650; }
.sidebar-dock .day-search-hint {
  order: 3;
  margin: 6px 0 0;
  text-align: center;
  font-size: 12px;
  color: #5C6575 !important;
}
.sidebar-dock .day-search-hint.is-blocking {
  color: var(--mz-ink, #1C1008) !important;
  font-weight: 650;
}
.sidebar-dock .day-search-cta-actions {
  order: 4;
  justify-content: center;
}
.sidebar-dock {
  display: flex;
  flex-direction: column;
}

/* Loupe inline redondante avec le CTA Rechercher */
.place-search-bar .place-search-go { display: none !important; }
.place-search-bar .place-search-field .station-search-input {
  padding-right: 12px;
}
.planner-saved-routes.hidden { display: none !important; }
.planner-saved-routes:not(.hidden) {
  margin: 0 0 10px;
  padding: 0 0 10px;
}


/* ══ Recherche UX simplifiée (2026-08) ══════════════════════════════════ */
.mz-results-header {
  margin-bottom: 12px;
  padding: 12px 16px;
  gap: 12px;
}
.mz-results-header .rh-route {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex-wrap: wrap;
}
.mz-results-header .rh-orig,
.mz-results-header .rh-dest {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--mz-ink, #161A22);
}
.mz-results-header .rh-arrow {
  color: var(--mz-muted, #6b7280);
  font-size: 1rem;
}
.mz-results-summary {
  margin: 0 0 12px;
  padding: 0 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--mz-ink-2, #2C3340);
  line-height: 1.4;
}
.mz-results-trust {
  margin: 0 0 8px;
  padding: 0 2px;
  font-size: 12px;
  color: var(--mz-muted, #6b7280);
}
.route-filter-bar.mz-filter-bar {
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.j-booking {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: stretch;
  justify-content: flex-start;
}
.j-booking > .j-book-btn.sncf,
.j-booking > .mz-btn-primary {
  width: 100%;
  justify-content: center;
  min-height: 44px;
  font-size: 14px;
}
.j-booking-secondary {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.j-booking-secondary .j-book-btn {
  flex: 1 1 auto;
  min-width: 0;
}
.journey-card {
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
  margin-bottom: 10px;
  background: var(--card, #fff);
}
.journeys-list {
  gap: 0;
}
.journey-card:last-child { margin-bottom: 0; }
.date-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.date-preset-btn {
  font-size: 12px !important;
  padding: 8px 10px !important;
  min-height: 36px;
  border-radius: 10px;
}
.sidebar-dock .day-search-btn {
  min-height: 48px;
  font-size: 15px;
  font-weight: 800;
}
.sidebar-advanced .mz-btn-block,
.sidebar-advanced #loadBtn {
  width: 100%;
  margin-top: 8px;
}
.agenda-selected-bar {
  justify-content: flex-start;
}
.mz-results-days-actions .mz-results-30-btn {
  font-weight: 600;
}
@media (max-width: 700px) {
  .mz-results-header { margin-top: 4px; }
  .journey-card { padding: 12px 12px; }
}

/* ══ Recherche UX polish (2026-09) ══════════════════════════════════════ */
.od-empty-hint {
  margin: 10px 0 0;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--mz-ink-2, #1E293B);
}
.od-empty-hint[hidden] { display: none !important; }
.od-swap .swap-btn,
.swap-btn#odSwapBtn {
  width: auto;
  min-width: 44px;
  min-height: 44px;
  height: 44px;
  padding: 0 12px;
  border-radius: 999px;
  gap: 6px;
}
.swap-btn-icon { font-size: 16px; line-height: 1; }
.swap-btn-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.01em;
}
.od-swap .swap-btn:disabled,
.swap-btn#odSwapBtn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}
.place-geo-btn.place-geo-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
}
.place-search-bar .place-search-field .station-search-input {
  min-height: 44px;
  padding-left: 48px;
}
.trip-type-btn,
.date-leg-btn,
.time-window-btn,
.date-preset-btn,
.traveler-btn {
  min-height: 44px;
}
.date-preset-btn {
  padding: 8px 12px !important;
  font-size: 12px !important;
}
.smc-day {
  min-height: 44px;
}
.smc-day.picked,
.smc-day.return-picked {
  box-shadow: 0 0 0 2px rgba(255, 106, 0, 0.55);
  font-weight: 800;
}
.smc-day.return-picked {
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.65);
}
.smc-day .smc-places,
.smc-day .smc-trips,
.smc-often {
  font-size: 10px;
  font-weight: 800;
}
.agenda-selected-chip,
.agenda-selected-clear,
.agenda-selected-edit,
.agenda-selected-go {
  min-height: 44px;
}
.agenda-selected-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.agenda-selected-edit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.agenda-selected-edit.is-return {
  border-color: color-mix(in srgb, #38bdf8 50%, transparent);
  background: color-mix(in srgb, #38bdf8 16%, transparent);
}
.day-search-btn.is-blocked:disabled {
  cursor: not-allowed;
  opacity: 0.72;
  background: rgba(255, 106, 0, 0.28);
}
.mz-results-header {
  position: relative;
  top: auto;
  z-index: 1;
  flex-wrap: wrap;
}
.mz-query-summary {
  flex: 1 1 100%;
  margin: 4px 0 0;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.35;
  color: var(--mz-ink-2, #2C3340);
}
.j-times .j-dep,
.j-times .j-arr {
  font-variant-numeric: tabular-nums;
}
.j-dur {
  font-weight: 700;
  min-height: 28px;
  display: inline-flex;
  align-items: center;
}
.j-places-slot.j-seats {
  margin-left: auto;
}
.station-suggest-item.is-active,
.station-suggest-item[aria-selected="true"] {
  outline: 2px solid var(--mz-accent, #FF6A00);
  background: color-mix(in srgb, var(--mz-accent, #FF6A00) 16%, transparent);
}
.nearby-days-hint {
  margin-top: 12px;
}
.nearby-days-hint p {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
}
.nearby-day-chip { min-height: 44px; }
@media (max-width: 700px) {
  .mz-results-header {
    top: auto;
  }
  .sidebar,
  .sidebar-scroll,
  .main-content,
  #mainContent {
    overflow-x: clip;
    max-width: 100%;
  }
  .journey-card,
  .mz-results-header,
  .route-filter-bar {
    max-width: 100%;
  }
  .j-summary { gap: 8px; }
  .j-dep, .j-arr { font-size: 17px; }
}

/* Anti-écran vide /app : le moteur n’est plus un drawer hors écran (style.css hérité). */
@media (max-width: 700px) {
  body.app-shell .layout,
  body.app-shell .layout.mz-app-frame {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    flex-direction: column !important;
  }
  body.app-shell .sidebar,
  body.app-shell.tab-planner .sidebar {
    position: relative !important;
    transform: none !important;
    inset: auto !important;
    left: auto !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    display: block !important;
    visibility: visible !important;
  }
  body.app-shell .sidebar-scroll {
    overflow: visible !important;
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
  }
  body.app-shell .sidebar-dock,
  body.app-shell .sidebar-dock.mz-search-cta {
    position: relative !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;
    display: block !important;
    visibility: visible !important;
  }
  body.app-shell #mainContent,
  body.app-shell .main {
    display: block !important;
    visibility: visible !important;
    min-height: 80px;
  }
}

/* Mes billets (import confirmation + complémentaires 0 €) */
.mz-ticket-page { margin-bottom: 8px; }
.mz-ticket-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.mz-ticket-actions .mz-btn { min-height: 44px; }
.mz-ticket-form-grid { display: grid; gap: 10px; margin-top: 12px; }
.mz-ticket-field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--mz-ink); }
.mz-ticket-field-full { grid-column: 1 / -1; }
.mz-ticket-field input,
.mz-ticket-field textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--mz-border);
  border-radius: var(--mz-radius-xs, 8px);
  background: var(--mz-surface);
  color: var(--mz-ink);
  padding: 8px 12px;
  font: inherit;
  font-weight: 500;
}
.mz-ticket-field textarea { min-height: 120px; resize: vertical; }
.mz-ticket-file { position: relative; cursor: pointer; }
.mz-ticket-file input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.mz-ticket-card,
.mz-ticket-suggest,
.mz-ticket-draft {
  border: 1px solid var(--mz-border);
  border-radius: var(--mz-radius-sm, 12px);
  background: var(--mz-surface);
  padding: 12px;
  margin-top: 12px;
}
.mz-ticket-list { display: flex; flex-direction: column; gap: 12px; }
.mz-ticket-route { font-size: 16px; font-weight: 700; margin: 4px 0; }
.mz-ticket-meta { color: var(--mz-muted); font-size: 13px; font-weight: 500; }
.mz-ticket-warn { margin: 8px 0 0; padding-left: 18px; color: var(--mz-warning, #b45309); }
.mz-ticket-error { color: var(--mz-danger, #DC3C4D); margin-top: 8px; }
.mz-ticket-raw pre {
  white-space: pre-wrap;
  font-size: 12px;
  color: var(--mz-muted);
  margin-top: 8px;
}
.mz-ticket-cam video {
  width: 100%;
  max-height: 240px;
  background: #000;
  border-radius: var(--mz-radius-xs, 8px);
  margin-top: 8px;
}
.mz-ticket-suggest ul { margin: 6px 0 0; padding-left: 18px; }
@media (min-width: 720px) {
  .mz-ticket-form-grid { grid-template-columns: 1fr 1fr; }
}
.acct-referral-title { font-size: 1.15rem; margin: 0 0 .35rem; }
.acct-referral-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 1.35rem;
  letter-spacing: .08em;
  font-weight: 700;
  margin: .75rem 0;
}
.acct-referral .acct-cta-row { display: flex; flex-wrap: wrap; gap: .5rem; margin: .2rem 0 .8rem; }

.mz-email-verify-banner,
.mz-email-verify-confirm {
  box-sizing: border-box;
  width: auto;
  max-width: calc(100% - 32px);
  margin: 12px 16px 0;
  color: #161A22;
}
.mz-email-verify-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  padding: 12px 14px;
  border: 1px solid #FF6A00;
  border-radius: 12px;
  background: #FFF4EB;
}
.mz-email-verify-banner p {
  margin: 0;
  flex: 1 1 220px;
  min-width: 0;
  color: #161A22;
  line-height: 1.4;
}
.mz-email-verify-banner .mz-btn,
.mz-email-verify-actions .mz-btn,
.mz-email-verify-form .mz-btn,
.mz-email-verify-block .mz-btn,
.mz-email-verify-confirm-card .mz-btn {
  min-height: 44px;
  white-space: normal;
}
.mz-email-verify-block .empty-title { color: #161A22; }
.mz-email-verify-actions,
.mz-email-verify-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
}
.mz-email-verify-form { flex-direction: column; align-items: stretch; margin-top: 12px; }
.mz-email-verify-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: #161A22;
  font-size: 14px;
}
.mz-email-verify-field input {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid #E7E1D8;
  border-radius: 10px;
  background: #fff;
  color: #161A22;
}
.mz-email-verify-notice { color: #B34700; font-weight: 650; }
.mz-email-verify-masked { color: #5B6578; }
.mz-email-verify-confirm[hidden],
.mz-email-verify-banner[hidden] { display: none; }
.mz-email-verify-confirm:not([hidden]) {
  position: fixed;
  inset: 0;
  z-index: 1200;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 24px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #161A22;
  overflow: auto;
}
.mz-email-verify-confirm:not([hidden]) .mz-email-verify-confirm-card {
  width: 100%;
  margin: 0 auto;
}
.mz-email-verify-confirm-card {
  box-sizing: border-box;
  max-width: 520px;
  margin: 24px auto;
  padding: 28px 22px;
  border: 1px solid #FF6A00;
  border-radius: 16px;
  background: #FFF4EB;
  color: #161A22;
}
.mz-email-verify-confirm-card h1 {
  margin: 8px 0;
  font-size: 1.6rem;
  line-height: 1.2;
  color: #161A22;
}
.acct-banner .mz-email-verify-actions { margin-top: 8px; }

/* Inscription compacte (nov. 2026) : code promo replié, âge sur une ligne. */
.auth-promo-details { margin: 2px 0 4px; }
.auth-promo-summary {
  cursor: pointer;
  font-size: .9rem;
  font-weight: 600;
  color: #FF6A00;
  padding: 6px 0;
  list-style: none;
}
.auth-promo-summary::-webkit-details-marker { display: none; }
.auth-promo-summary::before { content: "+ "; }
.auth-promo-details[open] > .auth-promo-summary::before { content: "− "; }
.auth-age-row { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.auth-age-row .acct-check { margin: 0; }
#authTermsRow .acct-check { margin-top: 4px; margin-bottom: 4px; }
#authTermsRow .acct-check-text, #authMarketingRow .acct-check-text { font-size: .86rem; line-height: 1.35; }
/* Calendrier « Choisir une autre date » de l’alerte guidée. */
.first-alert-custom-date { margin-top: 10px; }
