/* ============================================================
   D23 Stats by DLP Welcome — app.css
   Thèmes : dark / light  |  Modes : mobile / pc / tv
   ============================================================ */

/* ── Variables dark (défaut) ── */
:root {
  --bg:          #0d0f18;
  --bg2:         #161927;
  --bg3:         #1e2235;
  --bg4:         #252a40;
  --border:      #2a2f4a;
  --text:        #e2e8f0;
  --text-muted:  #7c87a6;
  --accent:      #6366f1;
  --accent-h:    #818cf8;
  --high:        #ef4444;
  --low:         #22c55e;
  --amber:       #f59e0b;
  --radius:      8px;
  --radius-sm:   4px;
  --font:        'Segoe UI', system-ui, -apple-system, sans-serif;
  --shadow:      0 2px 12px rgba(0,0,0,.4);
  --home-card-bg: #081429;
  --yt-card-bg:  #170A0E;
}

[data-theme="light"] {
  --bg:          #f0f2f8;
  --bg2:         #ffffff;
  --bg3:         #f8fafc;
  --bg4:         #eef0f6;
  --border:      #dde1ee;
  --text:        #1e293b;
  --text-muted:  #64748b;
  --shadow:      0 2px 12px rgba(0,0,0,.1);
  --home-card-bg: #ffffff;
  --yt-card-bg:  #ffffff;
}

/* ── Couleurs Resorts ── */
:root {
  /* Disneyland Paris (DLP) */
  --dlp-primary:  #0D1B2A;
  --dlp-secondary: #1B263B;
  --dlp-accent:   #E0B84C;

  /* Disneyland Resort California (DLR) */
  --dlr-primary:  #7B2D00;
  --dlr-secondary: #BC6C25;
  --dlr-accent:   #F77F00;

  /* Walt Disney World (WDW) */
  --wdw-primary:  #1D3557;
  --wdw-secondary: #457B9D;
  --wdw-accent:   #E63946;

  /* Tokyo Disney Resort (TDR) */
  --tdr-primary:  #2A2D34;
  --tdr-secondary: #6C757D;
  --tdr-accent:   #A8DADC;

  /* Shanghai Disney Resort (SDR) */
  --sdr-primary:  #14213D;
  --sdr-secondary: #4CC9F0;
  --sdr-accent:   #7209B7;

  /* Hong Kong Disneyland (HKDL) */
  --hkdl-primary: #1B4332;
  --hkdl-secondary: #2D6A4F;
  --hkdl-accent:  #95D5B2;
}

/* ── Couleurs Parcs (Accents) ── */
:root {
  /* DLP Parks */
  --park-dlp-accent: #E0B84C;
  --park-wds-accent: #6C8EBF;

  /* DLR Parks */
  --park-dl-accent:  #F77F00;
  --park-dca-accent: #F4A261;

  /* WDW Parks */
  --park-mk-accent:  #3A86FF;
  --park-ep-accent:  #8338EC;
  --park-hs-accent:  #E63946;
  --park-ak-accent:  #2D6A4F;

  /* TDR Parks */
  --park-tdl-accent: #90E0EF;
  --park-tds-accent: #0077B6;

  /* SDR Parks */
  --park-sdl-accent: #7209B7;

  /* HKDL Parks */
  --park-hkdl-accent: #52B788;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-h); }
button { cursor: pointer; border: none; background: none; font: inherit; color: inherit; }
table { border-collapse: collapse; width: 100%; }

/* ── Header ── */
.site-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: .65rem 1.25rem;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 100;
  box-shadow: var(--shadow);
}

[data-mode="pc"] .site-header {
  position: static;
}

.logo {
  font-size: .9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  cursor: pointer;
  transition: opacity .15s;
  color: var(--text);
  text-decoration: none;
  padding: 0 .5rem;
  white-space: nowrap;
}
.logo:hover { opacity: 0.8; }
.logo-img {
  display: block;
  width: auto; height: auto;
  max-height: 30px;
  max-width: min(220px, 42vw); /* adaptatif : ne casse pas le header sur mobile */
  object-fit: contain;
}
/* Logo blanc → version sombre sur thème clair */
[data-theme="light"] .logo-img { filter: invert(1) hue-rotate(180deg); }

/* Navigation */
.header-nav {
  flex: 1;
  display: flex;
  align-items: center;
  gap: .5rem;
  font-size: 1.05rem;
  min-width: 0; /* flex shrink */
}
.header-nav a,
.header-nav button {
  color: var(--text);
  text-decoration: none;
  transition: opacity .15s;
}
.header-nav a:hover,
.header-nav button:hover {
  opacity: 0.7;
}
.nav-sep {
  color: var(--text-muted);
  margin: 0 .25rem;
}
.nav-item {
  white-space: nowrap;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font: inherit;
}
.nav-home,
.nav-resort {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: .25rem;
}
.nav-dropdown-toggle {
  padding: 0;
  background: none;
  border: none;
  font-size: .8rem;
  cursor: pointer;
  color: var(--text-muted);
  transition: color .15s;
  flex-shrink: 0;
}
.nav-dropdown-toggle:hover {
  color: var(--accent-h);
}
.nav-attraction {
  color: var(--text-muted);
  cursor: default;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 300px;
}

/* Mobile (default): show acronyms only */
.nav-acronym { display: inline; }
.nav-name { display: none; }
.dropdown-acronym { display: inline; }
.dropdown-name { display: none; }

/* PC : noms complets dans la nav */
[data-mode="pc"] .nav-acronym    { display: none; }
[data-mode="pc"] .nav-name       { display: inline; }
[data-mode="pc"] .dropdown-acronym { display: none; }
[data-mode="pc"] .dropdown-name  { display: inline; }

/* Park dropdown */
.park-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-top: .25rem;
  min-width: max-content;
  box-shadow: var(--shadow);
  z-index: 200;
}
.park-option {
  display: block;
  padding: .5rem .75rem;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: background .15s;
  font-size: .85rem;
  white-space: nowrap;
}
.park-option:last-child {
  border-bottom: none;
}
.park-option:hover {
  background: var(--bg4);
}
.park-option.active {
  background: var(--bg4);
  font-weight: 600;
}
.btn-options {
  font-size: 1.2rem;
  padding: .3rem .55rem;
  border-radius: var(--radius-sm);
  background: var(--bg3);
  border: 1px solid var(--border);
  transition: background .15s;
  flex-shrink: 0;
}
.btn-options:hover { background: var(--bg4); }
.header-options {
  display: none;
  margin-left: auto;
  gap: 1rem;
  align-items: center;
}
.header-select {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .95rem;
  color: var(--text);
  cursor: pointer;
}
.header-select select {
  padding: .4rem .55rem;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: .95rem;
  cursor: pointer;
}
.header-select select:hover {
  border-color: var(--accent);
}

/* PC : options inline dans le header */
[data-mode="pc"] .header-options { display: flex; }
[data-mode="pc"] .btn-options    { display: none; }

/* ── Options Panel ── */
.options-panel {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(2px);
}
.options-panel[hidden] { display: none; }
.options-inner {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  width: min(90vw, 320px);
  display: flex;
  flex-direction: column;
  gap: .9rem;
  box-shadow: var(--shadow);
}
.options-inner h3 { font-size: 1rem; font-weight: 700; }
.options-inner label {
  display: flex; flex-direction: column; gap: .3rem;
  font-size: .82rem; color: var(--text-muted);
}
.options-inner select {
  background: var(--bg3); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: .4rem .5rem; font: inherit;
}
#btnCloseOptions {
  background: var(--accent); color: #fff;
  padding: .5rem 1rem; border-radius: var(--radius);
  align-self: flex-end; font-weight: 600;
  transition: background .15s;
}
#btnCloseOptions:hover { background: var(--accent-h); }

/* ── Footer ── */
.site-footer {
  margin-top: auto;
  padding: .75rem 1.25rem;
  font-size: .75rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
.footer-main {
  display: flex;
  gap: .75rem;
  justify-content: center;
  align-items: center;
  color: var(--text-muted);
  opacity: 0.5;
}
.footer-disclaimer {
  font-size: .75rem;
  line-height: 1.4;
  color: var(--text-muted);
  opacity: 0.5;
}
.footer-disclaimer p {
  margin: 0;
}
.sep { opacity: 1; }
.footer-link {
  color: inherit;
  text-decoration: none;
  opacity: 1;
  transition: opacity .15s;
}
.footer-link:hover {
  opacity: 1;
  text-decoration: underline;
}
.footer-main:hover {
  opacity: 0.7;
}

/* ── Legal page ── */
.page-legal {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.legal-content {
  max-width: 900px;
  margin: 0 auto;
  line-height: 1.6;
}
.legal-content h1 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}
.legal-content h2 {
  font-size: 1.1rem;
  margin-top: 1.5rem;
  margin-bottom: .75rem;
  color: var(--accent);
}
.legal-content section {
  margin-bottom: 1.5rem;
}
.legal-content p {
  margin: .5rem 0;
}
.legal-content ul {
  list-style: none;
  padding-left: 1.25rem;
}
.legal-content li {
  margin: .5rem 0;
}
.legal-content li:before {
  content: "• ";
  color: var(--accent);
  margin-right: .5rem;
}
.legal-content a {
  color: var(--accent);
  text-decoration: none;
  transition: opacity .15s;
}
.legal-content a:hover {
  opacity: 0.7;
  text-decoration: underline;
}

/* ── Main layout ── */
main { flex: 1; padding: 1.25rem; width: 100%; max-width: 1600px; margin: 0 auto; }

/* ── Shared cards / sections ── */
.card-section {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}
.card-section h2 {
  font-size: .82rem; font-weight: 600;
  color: var(--text-muted); text-transform: uppercase;
  letter-spacing: .06em; margin-bottom: .9rem;
}

/* ── Grids (home / dest) ── */
.dest-grid, .park-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(225px, 1fr));
  gap: .9rem;
  margin-top: 1.25rem;
  align-items: start;
}
.dest-card, .park-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .35rem; padding: 1.25rem .75rem;
  background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius);
  text-align: center; transition: border-color .15s, transform .1s, background .15s;
  color: var(--text);
  min-height: 120px;
}

/* ── Couleurs des resorts ── */
[data-acronym="dlp"] .dest-card {
  background: rgba(13, 27, 42, 0.15);
  border-color: rgba(224, 184, 76, 0.3);
}
[data-acronym="dlp"] .acronym { color: #E0B84C; }
[data-acronym="dlp"] .dest-card:hover { border-color: #E0B84C; background: rgba(13, 27, 42, 0.25); }

[data-acronym="dlr"] .dest-card {
  background: rgba(0, 50, 120, 0.15);
  border-color: rgba(255, 184, 28, 0.3);
}
[data-acronym="dlr"] .acronym { color: #FFB81C; }
[data-acronym="dlr"] .dest-card:hover { border-color: #FFB81C; background: rgba(0, 50, 120, 0.25); }

[data-acronym="wdw"] .dest-card {
  background: rgba(29, 53, 87, 0.15);
  border-color: rgba(230, 57, 70, 0.3);
}
[data-acronym="wdw"] .acronym { color: #E63946; }
[data-acronym="wdw"] .dest-card:hover { border-color: #E63946; background: rgba(29, 53, 87, 0.25); }

[data-acronym="tdr"] .dest-card {
  background: rgba(42, 45, 52, 0.15);
  border-color: rgba(168, 218, 220, 0.3);
}
[data-acronym="tdr"] .acronym { color: #A8DADC; }
[data-acronym="tdr"] .dest-card:hover { border-color: #A8DADC; background: rgba(42, 45, 52, 0.25); }

[data-acronym="sdl"] .dest-card {
  background: rgba(20, 33, 61, 0.15);
  border-color: rgba(114, 9, 183, 0.3);
}
[data-acronym="sdl"] .acronym { color: #7209B7; }
[data-acronym="sdl"] .dest-card:hover { border-color: #7209B7; background: rgba(20, 33, 61, 0.25); }

[data-acronym="hkdl"] .dest-card {
  background: rgba(27, 67, 50, 0.15);
  border-color: rgba(149, 213, 178, 0.3);
}
[data-acronym="hkdl"] .acronym { color: #95D5B2; }
[data-acronym="hkdl"] .dest-card:hover { border-color: #95D5B2; background: rgba(27, 67, 50, 0.25); }

.dest-card:hover, .park-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.dest-card .acronym, .park-card .acronym {
  font-size: .75rem; font-weight: 600;
  color: var(--text-muted);
  height: auto; line-height: 1.2;
  order: 2; /* afficher après le nom */
}
.dest-name, .park-name {
  font-size: 1.1rem;
  color: var(--text);
  font-weight: 700;
  order: 1; /* afficher avant l'acronyme */
}
/* Home page : grande carte — nom complet centré, initiales en haut à gauche, heure en bas à droite */
.page-home .dest-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .6rem; }
.page-home .dest-card {
  position: relative;
  align-items: center; justify-content: center;
  min-height: 150px; padding: 1.1rem .85rem;
  background: var(--home-card-bg);
}
.page-home .dest-card .acronym {
  position: absolute; top: .55rem; left: .7rem;
  font-size: .85rem; font-weight: 800; line-height: 1;
}
.page-home .dest-name {
  font-size: 1.55rem; font-weight: 800; color: var(--text);
  order: auto; text-align: center; line-height: 1.2;
}
.page-home .dest-time {
  position: absolute; bottom: .55rem; right: .7rem;
  order: auto; margin: 0; color: var(--text-muted); font-size: .72rem;
}
.dest-time { font-size: .75rem; color: var(--text-muted); margin-top: .25rem; font-weight: 500; }
.empty { color: var(--text-muted); font-style: italic; padding: .75rem 0; }
.sub { font-weight: 400; color: var(--text-muted); }
.dest-card-wrap {
  display: flex; flex-direction: column; gap: .5rem;
}

/* ── Home page hero ── */
.home-hero {
  text-align: center; padding: 1.5rem 0 0;
}
/* Rapprocher la première section ("ALL RESORTS") du logo */
.home-hero + .home-section { margin-top: .5rem; }
.home-logo {
  display: block; margin: 0 auto;
  width: auto; max-width: min(560px, 85%); height: auto;
}
/* Logo blanc → version sombre sur thème clair (inverse la luminosité, garde les teintes) */
[data-theme="light"] .home-logo {
  filter: invert(1) hue-rotate(180deg);
}
.home-title {
  font-size: clamp(2rem, 6vw, 3.5rem); font-weight: 900; letter-spacing: .05em;
  text-transform: uppercase; color: var(--text); margin: 0;
}
.home-subtitle {
  font-size: .9rem; color: var(--text-muted); font-style: italic;
  letter-spacing: .08em; margin-top: .25rem;
}

/* ── Home sections ── */
.home-section { margin-top: 2rem; }
.section-title {
  font-size: clamp(1.1rem, 3vw, 1.4rem); font-weight: 900;
  text-transform: uppercase; letter-spacing: .08em; color: var(--text);
  border-bottom: 1px solid var(--border); padding-bottom: .5rem; margin-bottom: 1rem;
}
.section-title-accent { color: var(--accent); }

/* ── Extra Medias ── */
.extra-medias-grid {
  display: flex; gap: 1rem; align-items: stretch; flex-wrap: wrap;
}
.yt-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .55rem; padding: 1.5rem 1.5rem; background: var(--yt-card-bg);
  border: 1px solid #FF0000; border-radius: var(--radius);
  flex-shrink: 0; width: 195px; min-height: 140px; transition: border-color .15s, background .15s;
  text-decoration: none;
}
.yt-card:hover { border-color: #FF0000; background: var(--yt-card-bg); }
.yt-icon { font-size: 2.5rem; color: #FF0000; font-weight: bold; line-height: 1; }
.yt-label { font-size: clamp(1.1rem, 3vw, 1.4rem); font-weight: 800; color: var(--text); line-height: 1; }
.yt-handle { font-size: .8rem; color: var(--text-muted); }
.extra-badges {
  display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: 1fr;
  gap: .6rem; flex: 1; min-width: 280px;
}
.extra-badge {
  display: flex; align-items: center; justify-content: center;
  padding: .4rem .7rem; border-radius: var(--radius-sm);
  font-size: .85rem; font-weight: 600; border: 1px solid #A82121; text-decoration: none;
  color: var(--text); text-align: center;
  transition: opacity .15s;
}
.extra-badge:hover { opacity: .8; }

/* Badge playlist à deux liens : playlist (principal) + dernière vidéo (secondaire).
   Même style que les autres badges, en texte uniquement. */
.extra-badge--dual {
  flex-direction: column; gap: .2rem; line-height: 1.2;
}
.extra-badge--dual:hover { opacity: 1; }   /* le survol vit sur chaque lien, pas le bloc */
.eb-main {
  font-size: .85rem; font-weight: 600; color: var(--text); text-decoration: none;
}
.eb-main:hover { text-decoration: underline; }
.eb-sub {
  display: flex; flex-direction: column; gap: .05rem;
  text-decoration: none;
}
.eb-sub:hover .eb-vtitle { text-decoration: underline; }
.eb-latest {
  font-size: .68rem; font-weight: 700; color: #ff5252;
  text-transform: uppercase; letter-spacing: .04em;
}
.eb-vtitle {
  font-size: .72rem; font-weight: 500; color: var(--text-muted); line-height: 1.15;
}

/* Layout dest : attractions + horaires côte à côte */
.dest-main-layout {
  display: flex; gap: 1.25rem; align-items: flex-start;
}
.dest-main-layout > .table-wrap {
  flex: 1; min-width: 0;
}
.parks-hours-wrap {
  flex: 0 0 280px;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1rem;
}
.parks-hours-wrap h3 {
  font-size: .82rem; font-weight: 600;
  color: var(--text-muted); text-transform: uppercase;
  letter-spacing: .06em; margin-bottom: .75rem;
}
.parks-schedule-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.parks-hours-table {
  width: 100%; border-collapse: collapse;
  font-size: .75rem;
}
.parks-hours-table th {
  background: var(--bg3); padding: .4rem .3rem;
  font-weight: 600; text-align: center;
  border-right: 1px solid var(--border);
}
.parks-hours-table th.park-name-col { text-align: left; }
.parks-hours-table th small { display: block; font-weight: 400; color: var(--text-muted); }
.parks-hours-table td {
  padding: .4rem .3rem; text-align: center;
  border-right: 1px solid var(--border);
}
.parks-hours-table .park-name {
  text-align: left; width: 50px;
}
.parks-hours-table .park-name .park-badge {
  padding: .15rem .35rem; font-size: .7rem;
}
.parks-hours-table .park-day-hours {
  color: var(--text);
  line-height: 1.3;
}
.parks-hours-table .open { color: var(--low); font-weight: 600; }
.parks-hours-table .closed { color: var(--high); }
.parks-hours-table .unknown { color: var(--text-muted); }
.extras-list {
  margin-top: .2rem; font-size: .65rem;
}
.extra-line { color: var(--text-muted); opacity: .8; }

/* Schedule days layout (new design) */
/* ── Table horaires (lignes = jours, colonnes = parcs) ── */
.sched-grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  min-width: 680px; /* évite l'écrasement → scroll horizontal sur petit écran */
}
.sched-grid th,
.sched-grid td {
  text-align: center;
  vertical-align: middle;
  padding: .9rem .6rem;
  border: none;
}
/* Séparateurs verticaux entre colonnes de parcs */
.sched-th-park, .sched-td-park { border-left: 1px solid var(--border); }

/* Colonne date */
.sched-th-date, .sched-td-date {
  width: 92px; text-align: left; white-space: nowrap;
}
.sched-dayname { display: block; font-weight: 800; color: var(--text); font-size: 1.05rem; line-height: 1.15; }
/* Jour court par défaut, jour complet en PC */
.sched-dayname-full  { display: none; }
.sched-dayname-short { display: block; }
html[data-mode="pc"] .sched-dayname-full  { display: block; }
html[data-mode="pc"] .sched-dayname-short { display: none; }
html[data-mode="pc"] .sched-th-date,
html[data-mode="pc"] .sched-td-date { width: 130px; }
.sched-daynum  { display: block; font-weight: 500; font-size: .82rem; color: var(--text-muted); margin-top: .1rem; }

/* En-têtes parcs */
.sched-grid thead th { padding-bottom: .55rem; }
.sched-park-link {
  display: block; text-align: center;
  font-weight: 800; font-size: .9rem; line-height: 1.25;
  text-decoration: none; text-transform: none; letter-spacing: 0;
}
.sched-park-link:hover { text-decoration: underline; }

/* Lignes : zébrage + séparateur net entre jours */
.sched-day-row { border-bottom: 2px solid var(--border); }
.sched-day-row:last-child { border-bottom: none; }
.sched-day-row:nth-child(even) { background: rgba(127,127,127,.07); }

/* Cellules horaires */
.sched-td-park { line-height: 1.4; }
.sched-line {
  display: flex; align-items: center; justify-content: center;
  gap: .35rem; white-space: nowrap;
}
.sched-time { font-weight: 700; color: var(--text); font-size: 1.05rem; }
.sched-time-extra { font-weight: 500; color: var(--text-muted); font-size: .8rem; }

/* ── Cellule horaires : horaire principal en évidence + créneaux spéciaux ── */
.sched-main-hours-cell {
  font-weight: 700; font-size: 1rem; color: var(--text);
  text-align: center; white-space: nowrap;
}
.sched-extra-row {
  display: flex; align-items: baseline; gap: .3rem;
  margin-top: .2rem; font-size: .72rem; line-height: 1.25;
  justify-content: center; flex-wrap: wrap;
}
.sched-extra-ic { font-size: .7rem; flex-shrink: 0; }
.sched-extra-name { font-weight: 600; color: var(--exc); }
.sched-extra-time { color: var(--text-muted); white-space: nowrap; }

/* ── Infobulles explicatives ── */
[data-tip] { cursor: help; }
.app-tooltip {
  position: absolute; z-index: 9999; max-width: 260px;
  background: var(--bg4); color: var(--text);
  border: 1px solid var(--border); border-radius: 8px;
  padding: .5rem .65rem; font-size: .8rem; line-height: 1.35;
  box-shadow: 0 8px 24px rgba(0,0,0,.35);
  pointer-events: none; text-align: left; font-weight: 400;
}
.app-tooltip[hidden] { display: none; }

/* Aujourd'hui : surbrillance + barre d'accent */
.sched-today { background: rgba(99,102,241,.14) !important; }
.sched-today .sched-td-date { box-shadow: inset 4px 0 0 var(--accent); }
.sched-today .sched-dayname { color: var(--accent); }


.park-badge {
  font-size: .7rem; padding: .2rem .4rem;
}

.emh-badge-small {
  display: inline-flex; align-items: center; justify-content: center;
  font-size: .7rem; padding: .12rem .35rem;
  background: rgba(99, 102, 241, 0.2); color: #6366f1;
  border-radius: 2px; font-weight: 700; line-height: 1;
  flex-shrink: 0;
}

.schedule-park-left {
  display: flex; flex-direction: column; gap: .25rem;
  align-items: flex-start; width: 65px;
}

.schedule-park-right {
  display: flex; flex-direction: column; gap: .08rem;
  flex: 1; text-align: right;
}

.sched-main-hours {
  display: flex; flex-direction: column; gap: 0;
}

.sched-time {
  font-weight: 600; color: var(--text); font-size: .85rem; line-height: 1.2; white-space: nowrap;
}

.sched-time-extra {
  color: var(--text-muted); opacity: .75; font-size: .85rem; font-weight: 500;
}

.sched-closed, .sched-unknown {
  color: var(--text-muted); font-size: .8rem;
}


/* Attractions et horaires côte à côte sur PC */
.attractions-schedule-layout {
  display: flex; gap: 1.25rem;
}
.attractions-section {
  flex: 2.5; min-width: 0;
}
.schedule-section {
  flex: 1.5; min-width: 0;
}

@media (max-width: 1200px) {
  .attractions-schedule-layout { flex-direction: column; }
  .attractions-section, .schedule-section { flex: 1; }
}

/* Shows et restaurants côte à côte */
.shows-rests-layout {
  display: flex; gap: 1.25rem;
}
.shows-section, .rests-section {
  flex: 1; min-width: 0;
}

@media (max-width: 1200px) {
  .shows-rests-layout { flex-direction: column; }
  .shows-section, .rests-section { flex: 1; }
}
.dest-card {
  min-height: 160px;
}
.dest-parks {
  display: flex; flex-direction: column; gap: .3rem;
  padding: .5rem 0 0;
  border-top: 1px solid var(--border);
}
.dest-parks .park-badge {
  padding: .25rem .6rem; font-size: .75rem;
  border-radius: 999px; border: 1px solid;
  transition: all .15s;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  text-align: center;
}
/* Par défaut (desktop) : nom complet */
.park-text { display: inline; }
.park-acro { display: none; }
/* Mode onglets (mobile / < 2560px) : acronyme seulement */
html.tabbed .park-text { display: none; }
html.tabbed .park-acro { display: inline; }
/* PC en mode tabbed : noms complets */
html.tabbed[data-mode="pc"] .park-text { display: inline; }
html.tabbed[data-mode="pc"] .park-acro { display: none; }
.dest-parks .park-badge:hover { transform: scale(1.08); }

/* PC: empiler en colonne */
@media (min-width: 768px) {
  .dest-parks {
    flex-direction: column;
    gap: .6rem;
  }
  .dest-parks .park-badge {
    padding: .5rem .85rem;
    font-size: .87rem;
    width: 100%;
    justify-content: flex-start;
    min-height: 36px;
    align-items: center;
    font-weight: 500;
  }
}

/* ── Couleurs des parcs ── */
/* DLP Parks */
[data-resort="dlp"][data-park="dlp"] .park-card { background: rgba(224, 184, 76, 0.15); border-color: rgba(224, 184, 76, 0.4); }
[data-resort="dlp"][data-park="dlp"] .acronym { color: #E0B84C; }
[data-resort="dlp"][data-park="dlp"] .park-card:hover { border-color: #E0B84C; background: rgba(224, 184, 76, 0.25); }

[data-resort="dlp"][data-park="daw"] .park-card { background: rgba(108, 142, 191, 0.15); border-color: rgba(108, 142, 191, 0.4); }
[data-resort="dlp"][data-park="daw"] .acronym { color: #6C8EBF; }
[data-resort="dlp"][data-park="daw"] .park-card:hover { border-color: #6C8EBF; background: rgba(108, 142, 191, 0.25); }

/* DLR Parks */
[data-resort="dlr"][data-park="dl"] .park-card { background: rgba(247, 127, 0, 0.15); border-color: rgba(247, 127, 0, 0.4); }
[data-resort="dlr"][data-park="dl"] .acronym { color: #F77F00; }
[data-resort="dlr"][data-park="dl"] .park-card:hover { border-color: #F77F00; background: rgba(247, 127, 0, 0.25); }

[data-resort="dlr"][data-park="dca"] .park-card { background: rgba(244, 162, 97, 0.15); border-color: rgba(244, 162, 97, 0.4); }
[data-resort="dlr"][data-park="dca"] .acronym { color: #F4A261; }
[data-resort="dlr"][data-park="dca"] .park-card:hover { border-color: #F4A261; background: rgba(244, 162, 97, 0.25); }

/* WDW Parks */
[data-resort="wdw"][data-park="mk"] .park-card { background: rgba(58, 134, 255, 0.15); border-color: rgba(58, 134, 255, 0.4); }
[data-resort="wdw"][data-park="mk"] .acronym { color: #3A86FF; }
[data-resort="wdw"][data-park="mk"] .park-card:hover { border-color: #3A86FF; background: rgba(58, 134, 255, 0.25); }

[data-resort="wdw"][data-park="ep"] .park-card { background: rgba(131, 56, 236, 0.15); border-color: rgba(131, 56, 236, 0.4); }
[data-resort="wdw"][data-park="ep"] .acronym { color: #8338EC; }
[data-resort="wdw"][data-park="ep"] .park-card:hover { border-color: #8338EC; background: rgba(131, 56, 236, 0.25); }

[data-resort="wdw"][data-park="hs"] .park-card { background: rgba(230, 57, 70, 0.15); border-color: rgba(230, 57, 70, 0.4); }
[data-resort="wdw"][data-park="hs"] .acronym { color: #E63946; }
[data-resort="wdw"][data-park="hs"] .park-card:hover { border-color: #E63946; background: rgba(230, 57, 70, 0.25); }

[data-resort="wdw"][data-park="ak"] .park-card { background: rgba(45, 106, 79, 0.15); border-color: rgba(45, 106, 79, 0.4); }
[data-resort="wdw"][data-park="ak"] .acronym { color: #2D6A4F; }
[data-resort="wdw"][data-park="ak"] .park-card:hover { border-color: #2D6A4F; background: rgba(45, 106, 79, 0.25); }

/* TDR Parks */
[data-resort="tdr"][data-park="tdl"] .park-card { background: rgba(144, 224, 239, 0.15); border-color: rgba(144, 224, 239, 0.4); }
[data-resort="tdr"][data-park="tdl"] .acronym { color: #90E0EF; }
[data-resort="tdr"][data-park="tdl"] .park-card:hover { border-color: #90E0EF; background: rgba(144, 224, 239, 0.25); }

[data-resort="tdr"][data-park="tds"] .park-card { background: rgba(0, 119, 182, 0.15); border-color: rgba(0, 119, 182, 0.4); }
[data-resort="tdr"][data-park="tds"] .acronym { color: #0077B6; }
[data-resort="tdr"][data-park="tds"] .park-card:hover { border-color: #0077B6; background: rgba(0, 119, 182, 0.25); }

/* Shanghai Parks */
[data-resort="sdl"][data-park="sdl"] .park-card { background: rgba(114, 9, 183, 0.15); border-color: rgba(114, 9, 183, 0.4); }
[data-resort="sdl"][data-park="sdl"] .acronym { color: #7209B7; }
[data-resort="sdl"][data-park="sdl"] .park-card:hover { border-color: #7209B7; background: rgba(114, 9, 183, 0.25); }

/* HK Parks */
[data-resort="hkdl"][data-park="hkdl"] .park-card { background: rgba(82, 183, 136, 0.15); border-color: rgba(82, 183, 136, 0.4); }
[data-resort="hkdl"][data-park="hkdl"] .acronym { color: #52B788; }
[data-resort="hkdl"][data-park="hkdl"] .park-card:hover { border-color: #52B788; background: rgba(82, 183, 136, 0.25); }

/* ── Park page ── */
.closed-banner {
  background: rgba(107,114,128,.2); color: #d1d5db;
  padding: .6rem 1rem; border-radius: var(--radius);
  margin-bottom: 1rem; font-size: .9rem;
  border: 1px solid rgba(107,114,128,.3);
}
.park-header {
  display: flex; align-items: baseline; flex-wrap: wrap;
  gap: .75rem; margin-bottom: 1rem;
}
.park-header h1 { font-size: 1.4rem; }
.park-fullname { font-weight: 400; color: var(--text-muted); }
.park-status {
  display: inline-block;
  margin-left: .75rem;
  padding: .25rem .6rem;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}
.park-status.status-open { background: rgba(34, 197, 94, 0.15); border-color: rgba(34, 197, 94, 0.3); color: #22c55e; }
.park-status.status-closing { background: rgba(245, 158, 11, 0.15); border-color: rgba(245, 158, 11, 0.3); color: #f59e0b; }
.park-status.status-opening { background: rgba(245, 158, 11, 0.15); border-color: rgba(245, 158, 11, 0.3); color: #f59e0b; }
.park-status.status-closed { background: rgba(239, 68, 68, 0.15); border-color: rgba(239, 68, 68, 0.3); color: #ef4444; }
.park-status.status-emh-upcoming { background: rgba(168, 85, 247, 0.15); border-color: rgba(168, 85, 247, 0.3); color: #a855f7; }
.park-status.status-emh-ongoing { background: rgba(168, 85, 247, 0.25); border-color: rgba(168, 85, 247, 0.4); color: #c084fc; font-weight: 800; }
.emh-badge { display: inline-block; padding: .15rem .4rem; border-radius: 4px; font-size: .7rem; font-weight: 700; margin-bottom: .25rem; }
.emh-badge.emh-upcoming { background: rgba(168, 85, 247, 0.15); color: #a855f7; }
.emh-badge.emh-ongoing { background: rgba(168, 85, 247, 0.25); color: #c084fc; }
.park-hours { font-size: .85rem; color: var(--text-muted); }
.last-update { font-size: .72rem; color: var(--text-muted); margin-left: auto; }
.park-closed .data-table { opacity: .5; pointer-events: none; }

/* ── Mobile tabs ── */
.tabs {
  display: none; /* caché sur PC */
  gap: .4rem;
  margin-bottom: 1rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .35rem;
  flex-wrap: wrap;
}
.tab-btn {
  flex: 1 1 auto; padding: .45rem .5rem;
  border-radius: calc(var(--radius) - 2px);
  font-size: .82rem; font-weight: 600;
  color: var(--text-muted);
  transition: all .15s;
  min-width: 80px;
}
.tab-btn.active { background: var(--accent); color: #fff; }

/* Boutons-filtres par parc (vue resort) */
.park-filters { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.park-filter-btn {
  background: none; border: none; padding: 0; cursor: pointer;
  transition: opacity .15s, filter .15s;
}
.park-filter-btn:not(.active) { opacity: .35; filter: grayscale(1); }
.park-filter-btn .park-badge {
  font-size: 1.4rem; padding: .4rem .85rem;
}

/* Bandeau "horaires du jour" (vue resort) */
.today-hours {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: .6rem;
  margin: .25rem 0 1rem;
}
.today-card {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: .6rem .75rem .65rem;
  display: flex; flex-direction: column; gap: .15rem;
  font: inherit; text-align: left; color: var(--text); width: 100%;
}
/* Cartes cliquables = filtres par parc */
.today-hours-filter .today-card {
  cursor: pointer;
  transition: opacity .15s, filter .15s, border-color .15s, transform .1s;
}
.today-hours-filter .today-card:hover { transform: translateY(-1px); }
.today-hours-filter .today-card:not(.active) { opacity: .4; filter: grayscale(1); }
.today-park {
  font-weight: 800; font-size: .9rem; text-decoration: none;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.today-main {
  font-size: 1.15rem; font-weight: 800; color: var(--text); line-height: 1.25;
}
.today-main.is-closed { color: var(--text-muted); font-weight: 700; }
.today-extra {
  font-size: .72rem; color: var(--text-muted); line-height: 1.3;
}
.today-extra-label { font-weight: 700; }

/* ── Météo 3 jours, en ligne à côté de l'heure locale (DLP) ── */
.header-weather {
  display: inline-flex; align-items: center; gap: .75rem;
  margin-left: .5rem; vertical-align: middle;
  flex-wrap: wrap; /* évite le débordement si la place manque */
}
.hw-day {
  display: inline-flex; align-items: baseline; gap: .25rem;
  font-size: .8rem; font-weight: 600; color: var(--text-muted); white-space: nowrap;
}
.hw-dow { opacity: .85; }
.hw-ic { font-size: 1rem; }
.hw-temp { color: var(--text); font-weight: 700; }
.hw-tmin { color: var(--text-muted); font-weight: 500; }
.hw-now { padding-right: .75rem; border-right: 1px solid var(--border); }
.hw-now .hw-temp { font-size: .95rem; }

/* Bascule onglets pilotée par JS (classe .tabbed sur <html>) */
html.tabbed .tabs { display: flex; }
html.tabbed .tab-content { display: none; }
html.tabbed .tab-content.tab-active { display: block; }
html:not(.tabbed) .tab-content { display: block; }

/* ── Park sections PC layout ── */
.park-section { margin-bottom: 1.5rem; }
.section-header { display: flex; align-items: center; gap: 1rem; margin-bottom: .75rem; flex-wrap: wrap; }
.pc-only { /* visible sur PC, caché sur mobile si onglets actifs */ }
.mobile-only { display: none; } /* caché par défaut, montré seulement sur mobile */

/* PC : shows + restaurants côte à côte */
.bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-top: 0;
}

/* ── Quick filters ── */
.quick-filters { display: flex; gap: .4rem; flex-wrap: wrap; }
.filter-btn {
  padding: .3rem .8rem; border-radius: 999px;
  font-size: .78rem; font-weight: 600;
  color: var(--text-muted);
  background: var(--bg3); border: 1px solid var(--border);
  transition: all .15s;
}
.filter-btn.active, .filter-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ── Tables ── */
.table-wrap { overflow-x: auto; }
.data-table thead th {
  padding: .45rem .75rem;
  text-align: left;
  border-bottom: 2px solid var(--border);
  font-size: .72rem; font-weight: 700;
  color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em;
  white-space: nowrap;
}
/* En-têtes triables : curseur + indicateur de sens (croissant/décroissant) */
.data-table thead th.sortable { cursor: pointer; user-select: none; }
.data-table thead th.sortable:hover { color: var(--text); }
.data-table thead th.sortable::after {
  content: '↕'; margin-left: .3rem; font-size: .85em;
  opacity: .35; transition: opacity .15s;
}
.data-table thead th.sortable:hover::after { opacity: .6; }
.data-table thead th.sortable.sorted { color: var(--accent-h); }
.data-table thead th.sortable.sorted::after { opacity: 1; }
.data-table thead th.sortable.sorted[data-sort-dir="asc"]::after  { content: '↑'; }
.data-table thead th.sortable.sorted[data-sort-dir="desc"]::after { content: '↓'; }
.data-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background .1s;
}
.data-table tbody tr:last-child { border-bottom: none; }
.data-table tbody tr:hover { background: var(--bg3); }
.data-table td { padding: .5rem .75rem; vertical-align: middle; font-size: .88rem; }

.attr-row { cursor: pointer; }
.col-name { width: 50%; }
.col-wait { width: 100px; }
.col-status { min-width: 120px; }
.col-hours { text-align: right; min-width: 150px; }

/* Attente — pas de couleur, uniquement le poids */
.attr-row.status-rehab { opacity: .65; }
.wait-val { font-weight: 600; }
.wait-na, .wait-down { color: var(--text-muted); }
.wait-down { font-size: 1.1rem; }

.trend { font-size: 1.15rem; font-weight: 700; line-height: 1; margin-left: .25rem; vertical-align: middle; }
.trend.up { color: var(--high); }
.trend.dn { color: var(--low);  }

.closes-at { font-size: .78rem; color: var(--amber); margin-left: .25rem; }
.down-since { font-size: .72rem; color: var(--text-muted); margin-left: .35rem; white-space: nowrap; }

/* ── Status pills ── */
.status-pill {
  display: inline-block; padding: .15rem .55rem;
  border-radius: 999px; font-size: .7rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em; white-space: nowrap;
}
.s0 { background: rgba(34,197,94,.15);  color: #22c55e; }
.s1 { background: rgba(239,68,68,.15);  color: #ef4444; }
.s2 { background: rgba(107,114,128,.15);color: #9ca3af; }
.s3 { background: rgba(245,158,11,.15); color: #f59e0b; }
.s4 { background: rgba(156,163,175,.1); color: #9ca3af; }

.badge-rehab {
  display: inline-block; margin-left: .4rem;
  padding: .1rem .4rem; background: rgba(245,158,11,.2);
  color: var(--amber); border-radius: var(--radius-sm);
  font-size: .68rem; font-weight: 700; vertical-align: middle;
}

/* ── Shows table ── */
.show-row.show-allpast { opacity: .45; }
.show-slots { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.show-slot {
  display: inline-flex; align-items: center; gap: .25rem;
  padding: .18rem .5rem; border-radius: var(--radius-sm);
  font-size: .82rem; font-weight: 600; white-space: nowrap;
}
.slot-future { background: var(--bg4); color: var(--text); }
.slot-past   { background: transparent; color: var(--text-muted); text-decoration: line-through; }
.slot-live   { background: rgba(34,197,94,.15); color: #22c55e; border: 1px solid rgba(34,197,94,.3); }
.slot-soon   { background: rgba(245,158,11,.15); color: #f59e0b; border: 1px solid rgba(245,158,11,.4); }
.badge-live  {
  display: inline-block; padding: .08rem .35rem;
  background: #22c55e; color: #000;
  border-radius: 999px; font-size: .62rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .05em;
  animation: pulse 1.5s infinite;
}
.badge-soon  {
  display: inline-block; padding: .08rem .35rem;
  background: #f59e0b; color: #000;
  border-radius: 999px; font-size: .62rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .05em; white-space: nowrap;
  animation: pulse 1.5s infinite;
}
@keyframes pulse { 0%,100% { opacity:1; } 50% { opacity:.6; } }
.slot-empty { color: var(--text-muted); }

/* ── Attraction page ── */
.attr-header { margin-bottom: 1.5rem; }
.attr-titlerow { display: flex; align-items: center; gap: .65rem; flex-wrap: wrap; }
.attr-header h1 { font-size: 1.35rem; line-height: 1.2; }
.attr-meta {
  display: flex; align-items: center; gap: .45rem;
  margin-top: .3rem; font-size: .82rem; color: var(--text-muted);
}
.attr-park { color: var(--text-muted); }
.meta-dot { opacity: .55; }
.park-localtime { display: inline-flex; align-items: center; gap: .3rem; }

/* Desktop : titre/méta à gauche, sélecteur de date à droite (remplit l'espace) */
@media (min-width: 680px) {
  .attr-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
  .attr-head-left { min-width: 0; }
  .attr-header .cal-section { margin-top: 0; }
  .attr-header .cal-popover { left: auto; right: 0; }
}

.chart-wrap { height: 260px; }

/* Légende statut (sous le graphe) */
.timeline-legend { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .75rem; margin-top: .9rem; }
.leg { display: flex; align-items: center; gap: .3rem; color: var(--text-muted); }
.leg::before { content:''; display:inline-block; width:10px; height:10px; border-radius:2px; background:var(--c); }

/* Pannes */
.downs-list {
  list-style: none; margin: 0; padding: 0;
  columns: 190px; column-gap: .4rem;   /* flux vertical : haut→bas puis colonne suivante */
}
.down-item {
  padding: .5rem .75rem; background: var(--bg3);
  border-radius: var(--radius-sm); font-size: .87rem;
  margin-bottom: .4rem; break-inside: avoid;  /* ne pas couper un item entre 2 colonnes */
}
.down-item.ongoing { border-left: 3px solid var(--high); }

/* ── Icônes SVG inline ── */
.ico { width: 1em; height: 1em; display: inline-block; vertical-align: -.125em; flex: none; }

/* ── Barre de stats « hero » ── */
.stats-label {
  font-size: .82rem; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .06em; margin-bottom: .6rem;
}
.attr-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: .75rem; margin-bottom: 1.25rem;
}
.stat-tile {
  display: flex; align-items: center; gap: .7rem;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: .85rem 1rem;
}
.stat-ico {
  display: grid; place-items: center; flex: none;
  width: 2.1rem; height: 2.1rem; border-radius: 9px;
  font-size: 1.1rem; background: var(--bg4); color: var(--text-muted);
}
.stat-body { display: flex; flex-direction: column; min-width: 0; }
.stat-val { font-size: 1.35rem; font-weight: 800; line-height: 1.1; color: var(--text); white-space: nowrap; }
.stat-lab {
  font-size: .68rem; text-transform: uppercase; letter-spacing: .05em;
  color: var(--text-muted); margin-top: .15rem;
}
.stat-tile.tone-now   { border-color: rgba(99,102,241,.35); }
.stat-tile.tone-now   .stat-ico { background: rgba(99,102,241,.16); color: var(--accent-h); }
.stat-tile.tone-high  .stat-ico { background: rgba(245,158,11,.16); color: var(--amber); }
.stat-tile.tone-low   .stat-ico { background: rgba(34,197,94,.16);  color: var(--low); }
.stat-tile.tone-avail .stat-ico { background: rgba(34,197,94,.16);  color: var(--low); }
.stat-tile.tone-mute  .stat-ico { background: var(--bg4); color: var(--text-muted); }

/* ── Rangée du bas : horaires | pannes (2 colonnes desktop) ── */
.attr-bottom {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem; align-items: start;
}
.attr-bottom .card-section { margin-bottom: 0; }
/* Pannes à gauche, horaires du parc à droite */
.bottom-outages { order: 1; }
.bottom-hours   { order: 2; }

.hours-info { display: flex; flex-direction: column; gap: .5rem; }
.hr-row { display: flex; align-items: center; gap: .55rem; font-size: .9rem; }
.hr-ico {
  display: grid; place-items: center; flex: none;
  width: 1.6rem; height: 1.6rem; border-radius: 6px;
  font-size: .95rem; background: var(--bg3); color: var(--text-muted);
}
.hr-ico.tone-low    { color: var(--low);      background: rgba(34,197,94,.14); }
.hr-ico.tone-accent { color: var(--accent-h); background: rgba(99,102,241,.16); }
.hr-name { font-weight: 600; color: var(--text); }
.hr-time { margin-left: auto; color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* Pannes : pastille au lieu d'emoji */
.down-item { display: flex; align-items: center; gap: .55rem; }
.down-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--text-muted); flex: none; }
.down-dot.ongoing { background: var(--high); animation: pulse 1.5s infinite; }

@media (max-width: 560px) {
  .attr-stats { grid-template-columns: repeat(2, 1fr); }
}

/* État fermé / avant ouverture */
.closed-card { display: flex; align-items: center; gap: .9rem; }
.closed-ico {
  display: grid; place-items: center; flex: none;
  width: 2.4rem; height: 2.4rem; border-radius: 10px;
  font-size: 1.2rem; background: var(--bg4); color: var(--text-muted);
}
.closed-title { font-weight: 700; color: var(--text); }
.closed-sub { font-size: .9rem; color: var(--text-muted); margin-top: .15rem; }
.closed-sub strong { color: var(--text); }

/* Show slots detail (attraction page) */
.show-slots-detail { display: flex; flex-direction: column; gap: .5rem; }
.slot-detail {
  display: flex; align-items: center; gap: .6rem;
  padding: .5rem .75rem; border-radius: var(--radius-sm);
  background: var(--bg3); font-size: .9rem;
}
.slot-detail.slot-past { opacity: .5; text-decoration: line-through; }
.slot-detail.slot-live { background: rgba(34,197,94,.1); border: 1px solid rgba(34,197,94,.25); }
.slot-time { font-weight: 700; font-size: 1rem; }
.slot-sep  { color: var(--text-muted); }
.slot-done { color: var(--low); }

/* ── Restaurant schedules ── */
.restaurant-schedules { display: flex; flex-direction: column; gap: .5rem; }
.sched-day {
  display: flex; align-items: center; gap: .8rem;
  padding: .5rem .75rem; border-radius: var(--radius-sm);
  background: var(--bg3); font-size: .9rem;
}
.sched-date { min-width: 60px; font-weight: 600; font-size: .75rem; color: var(--text-muted); line-height: 1.3; }
.sched-date small { font-size: .7rem; opacity: .7; }
.sched-hours { font-weight: 600; color: var(--low); }
.sched-closed { font-style: italic; color: var(--high); opacity: .8; }

/* ── Park restaurants table ── */
.rest-row { align-items: center; }
.rest-row.rest-open { opacity: 1; }
.rest-row.rest-closed { opacity: .6; }
.rest-row.rest-opening { opacity: 1; }
.rest-row.rest-closing { opacity: .8; }
.rest-row.rest-unknown { opacity: .5; }

/* ── Park food carts table (same styling as restaurants) ── */
.cart-row { align-items: center; }
.cart-row.rest-open { opacity: 1; }
.cart-row.rest-closed { opacity: .6; }
.cart-row.rest-opening { opacity: 1; }
.cart-row.rest-closing { opacity: .8; }
.cart-row.rest-unknown { opacity: .5; }

.data-table .col-schedule {
  display: flex; align-items: center; gap: .6rem;
}

.rest-time {
  font-weight: 600; font-size: .9rem;
  color: var(--text); /* Même couleur que les noms */
  white-space: nowrap;
}
.rest-status {
  color: var(--text-muted);
  font-style: italic;
  font-size: .85rem;
  white-space: nowrap;
}

/* Restaurant status badges — like show-slot style */
.badge-rest-open,
.badge-rest-closed,
.badge-rest-opening,
.badge-rest-closing,
.badge-rest-unknown {
  display: inline-block; padding: .12rem .35rem;
  border-radius: 999px;
  font-size: .65rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em;
  white-space: nowrap;
  flex-shrink: 0;
}
.badge-rest-open {
  background: rgba(34,197,94,.15); color: #22c55e;
  border: 1px solid rgba(34,197,94,.3);
}
.badge-rest-closed {
  background: rgba(239,68,68,.15); color: #ef4444;
  border: 1px solid rgba(239,68,68,.3);
}
.badge-rest-opening {
  background: rgba(59,130,246,.15); color: #3b82f6;
  border: 1px solid rgba(59,130,246,.3);
}
.badge-rest-closing {
  background: rgba(245,158,11,.15); color: #f59e0b;
  border: 1px solid rgba(245,158,11,.3);
}
.badge-rest-unknown {
  background: rgba(107,114,128,.15); color: var(--text-muted);
  border: 1px solid rgba(107,114,128,.2);
}

/* ── Error page ── */
.page-error { display: flex; justify-content: center; align-items: center; flex: 1; }
.error-box { text-align: center; display: flex; flex-direction: column; gap: 1rem; }
.error-icon { font-size: 3rem; }
.error-box h1 { font-size: 1.3rem; }

/* ══════════════════════════════════════
   MODES
══════════════════════════════════════ */

/* (Affichage onglets/sections : géré par la classe .tabbed pilotée par JS, voir plus haut) */

/* ── Mobile (cosmétique : grilles, masquages, marges) ── */
[data-mode="mobile"] .pc-only { display: none; }
[data-mode="mobile"] .mobile-only { display: block; }
[data-mode="mobile"] main { padding: .75rem; }
[data-mode="mobile"] .dest-grid, [data-mode="mobile"] .park-grid { grid-template-columns: repeat(2,1fr); }
[data-mode="mobile"] .col-status { min-width: 0; }

/* Auto-mobile sur petits écrans (cosmétique uniquement ; onglets gérés par .tabbed) */
@media (max-width: 640px) {
  [data-mode="auto"] .pc-only { display: none; }
  [data-mode="auto"] .mobile-only { display: block; }
  [data-mode="auto"] main { padding: .75rem; }

  /* Logo header plus compact sur mobile (évite de casser la barre) */
  .logo { padding: 0 .25rem; }
  .logo-img { max-height: 24px; max-width: 38vw; }

  /* Météo : sur sa propre ligne sous le titre, sans déborder */
  .header-weather {
    display: flex; flex-wrap: wrap; width: 100%;
    margin-left: 0; margin-top: .4rem; gap: .4rem .8rem;
  }
  .hw-day { font-size: .75rem; }
  .hw-now { padding-right: .6rem; }

  /* Bottom grid : 1 colonne sur mobile */
  .bottom-grid { grid-template-columns: 1fr; }

  /* Table sur mobile : réduire tout */
  .data-table { font-size: .75rem; table-layout: fixed; width: 100%; }
  .data-table td { padding: .2rem .15rem; }
  .data-table th { padding: .35rem .15rem; }
  .col-park { width: 32px; padding: .2rem .15rem .2rem 0 !important; }
  .col-wait { width: 55px; }
  .col-status { min-width: 0; width: 70px; }
  .status-pill { padding: .1rem .3rem; font-size: .6rem; letter-spacing: 0; }
  .data-table .col-name { word-wrap: break-word; overflow-wrap: break-word; }
  .data-table .col-schedule { display: table-cell; }

  /* show-slots: readable avec wrapping pleine largeur */
  .show-slots {
    gap: .2rem .35rem;
    flex-wrap: wrap;
  }
  .show-slot {
    padding: .1rem .35rem;
    font-size: .78rem;
    font-weight: 500;
  }
  .badge-live {
    padding: .03rem .15rem;
    font-size: .5rem;
  }
}


/* ── v3 additions ── */
.park-localtime-inline {
  color: var(--text-muted); font-weight: 400;
}
.unknown-separator td {
  padding: .4rem .75rem; font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--text-muted); background: var(--bg3);
  border-top: 2px solid var(--border);
}
.row-dimmed { opacity: .45; }
.row-dimmed:hover { opacity: .65; }

/* ── Park badge (vue resort) ── */
.park-badge {
  display: inline-block; padding: .1rem .45rem;
  border-radius: var(--radius-sm); font-size: .72rem;
  font-weight: 800; border: 1px solid; white-space: nowrap; letter-spacing: .03em;
}
a .park-badge { cursor: pointer; transition: opacity .15s; }
a:hover .park-badge { opacity: .8; }
.col-park { width: 60px; white-space: nowrap; }
.resort-parks-list { display: flex; gap: .4rem; flex-wrap: wrap; margin-top: .4rem; }
.resort-parks-list a { text-decoration: none; }
.resort-link {
  display: inline-flex; align-items: center; gap: .4rem;
  margin: .75rem 0 1rem; padding: .45rem .9rem;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); font-size: .88rem;
  color: var(--accent); transition: border-color .15s;
}
.resort-link:hover { border-color: var(--accent); }
.show-allpast { opacity: .45; }
.slot-past { opacity: .5; }

/* ── Breadcrumb plus visible ── */
.site-header { padding: .75rem 1.5rem; }
.breadcrumb {
  font-size: .9rem;
  color: var(--text);
  font-weight: 500;
}
.breadcrumb a {
  color: var(--accent-h);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.breadcrumb a:hover { color: var(--text); }

/* ── PC layout avec sidebar horaires ── */
.park-pc-layout {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}
.park-main-col { flex: 1; min-width: 0; }
.park-schedule-col {
  width: 260px;
  flex-shrink: 0;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  position: sticky;
  top: 60px;
}
.park-schedule-col h2 {
  font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--text-muted); margin-bottom: .75rem;
}

/* Semaine horaires */
.week-schedule { display: flex; flex-direction: column; gap: 1px; background: var(--border); }
.sched-row {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: .6rem .5rem; border-radius: 0;
  font-size: .82rem;
}
.sched-row:nth-child(odd) {
  background: rgba(99, 102, 241, 0.08);
}
.sched-row:nth-child(even) {
  background: transparent;
}
.sched-row:nth-child(odd).sched-today {
  background: rgba(99, 102, 241, 0.15);
}
.sched-row:nth-child(even).sched-today {
  background: rgba(99, 102, 241, 0.15);
}
.sched-today {
  background: rgba(99,102,241,.15);
  border: 1px solid rgba(99,102,241,.3);
  font-weight: 700;
}
.sched-day { display: flex; flex-direction: column; min-width: 45px; gap: .1rem; }
.sched-dayname { font-weight: 600; font-size: .78rem; line-height: 1; }
.sched-date { font-size: .7rem; color: var(--text-muted); line-height: 1; }
.sched-hours-col { display: flex; flex-direction: column; gap: .15rem; align-items: flex-end; flex: 1; text-align: right; }
.sched-hours { display: flex; gap: .15rem; align-items: center; font-size: .82rem; flex-wrap: wrap; justify-content: flex-end; }
.sched-extra-time { opacity: .7; }
.sched-event-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 24px; height: 24px; padding: 0 .4rem;
  background: rgba(99, 102, 241, .2); color: var(--accent-h);
  border: 1px solid rgba(99, 102, 241, .4);
  border-radius: 999px;
  font-size: .7rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .05em;
}
.sched-extra { display: flex; gap: .25rem; align-items: center; flex-wrap: wrap; font-size: .72rem; }
.sched-extra-badge {
  padding: .08rem .35rem; border-radius: 999px;
  font-weight: 700; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap;
}
.sched-extra-extra-hours { background: rgba(99,102,241,.15); color: var(--accent-h); }
.sched-extra-ticketed-event { background: rgba(245,158,11,.15); color: var(--amber); }
.sched-extra-hours { color: inherit; font-weight: 500; }
.sched-extra-desc { color: var(--text-muted); font-style: italic; }
.sched-open  { color: var(--low); font-weight: 600; }
.sched-close { color: var(--text); }
.sched-sep   { color: var(--text-muted); }
.sched-closed { color: var(--high); font-size: .78rem; }
.sched-unknown { color: var(--text-muted); }

/* Badge relâche */
.badge-relache {
  display: inline-block; padding: .12rem .45rem;
  background: rgba(107,114,128,.15); color: var(--text-muted);
  border-radius: 999px; font-size: .7rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em;
}

/* Mobile : masquer sidebar horaires, intégrer comme onglet */
[data-mode="mobile"] .park-pc-layout { flex-direction: column; }
[data-mode="mobile"] .park-schedule-col { width: 100%; position: static; }

[data-mode="auto"] .park-pc-layout { flex-direction: row; }

@media (max-width: 768px) {
  [data-mode="auto"] .park-pc-layout { flex-direction: column; }
  [data-mode="auto"] .park-schedule-col { width: 100%; position: static; }
}

/* Large desktop: wider sidebar */
@media (min-width: 1400px) {
  .park-schedule-col { width: 300px; }
  [data-mode="auto"] .park-schedule-col { width: 300px; }
}


/* Date selector */
/* ── Calendrier archives (popover) ── */
.cal-section {
  position: relative;
  display: flex; align-items: center; gap: .75rem;
  margin-bottom: 1.25rem;
}
/* Dans le header attraction : calendrier sous le titre, en parallèle des stats */
.attr-header .cal-section { margin-top: .6rem; margin-bottom: 0; }
.cal-trigger {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .5rem .85rem;
  background: var(--bg2); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: .9rem; cursor: pointer;
  transition: border-color .15s;
}
.cal-trigger:hover { border-color: var(--accent); }
.cal-caret { color: var(--text-muted); font-size: .7rem; }
/* Navigation jour précédent / suivant autour du sélecteur de date */
.cal-daynav {
  flex: none; display: grid; place-items: center;
  width: 2.15rem; align-self: stretch;
  background: var(--bg2); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 1.3rem; line-height: 1; cursor: pointer;
  transition: border-color .15s, background .15s, color .15s;
}
.cal-daynav:hover:not(:disabled) { border-color: var(--accent); background: var(--bg3); }
.cal-daynav:disabled { opacity: .3; cursor: default; }
.cal-popover {
  position: absolute; top: calc(100% + 6px); left: 0; z-index: 50;
  width: 320px; max-width: 92vw;
  padding: .85rem;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.cal-widget { width: 100%; }
.cal-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: .6rem;
}
.cal-title { font-size: .95rem; font-weight: 600; color: var(--text); }
.cal-nav {
  width: 2rem; height: 2rem; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg3); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 1.1rem; line-height: 1; cursor: pointer;
  transition: background .15s, border-color .15s;
}
.cal-nav:hover:not(:disabled) { border-color: var(--accent); background: var(--bg4); }
.cal-nav:disabled { opacity: .3; cursor: default; }
.cal-grid {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px;
}
.cal-dow {
  text-align: center; font-size: .7rem; font-weight: 600;
  color: var(--text-muted); padding-bottom: .25rem;
}
.cal-day {
  aspect-ratio: 1 / 1;
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem; color: var(--text);
  background: var(--bg3); border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer; padding: 0;
  transition: background .15s, border-color .15s;
}
button.cal-day:hover { border-color: var(--accent); background: var(--bg4); }
.cal-day.cal-empty { background: none; }
.cal-day.cal-disabled {
  color: var(--text-muted); opacity: .35;
  background: none; cursor: default;
}
.cal-day.cal-today { font-weight: 700; outline: 1px dashed var(--text-muted); }
.cal-day.cal-selected {
  background: var(--accent); color: #fff; font-weight: 700;
  border-color: var(--accent);
}
.btn-today {
  padding: .5rem .85rem;
  background: var(--bg2); color: var(--text-muted);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: .9rem; font-weight: 500;
  cursor: pointer; white-space: nowrap;
  transition: border-color .15s, color .15s;
}
.btn-today:hover { border-color: var(--accent); color: var(--text); }
.historical-date {
  font-size: .8rem; color: var(--text-muted);
  font-weight: 400; white-space: nowrap;
}

/* ────────────────────────────────────────── Countdown Pages ────────────────────────────────────────── */

/* Test Countdown Page — Show Selection */
.page-test-countdown {
  padding: 2rem 1rem;
  max-width: 1200px; margin: 0 auto;
}

.page-test-countdown h1 {
  margin-bottom: 2rem; font-size: 1.8rem; font-weight: 700;
  color: var(--text);
}

.shows-list {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.show-card {
  display: flex; flex-direction: column; gap: 1rem;
  padding: 1.5rem; background: var(--bg2);
  border: 1px solid var(--border); border-radius: var(--radius);
  text-decoration: none; color: inherit;
  transition: transform .2s, box-shadow .2s;
  cursor: pointer;
}

.show-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(99, 102, 241, .2);
}

.show-info h3 {
  font-size: 1.1rem; font-weight: 700;
  color: var(--text); margin-bottom: .5rem;
}

.show-park {
  font-size: .85rem; font-weight: 600;
}

.show-times {
  display: flex; flex-wrap: wrap; gap: .5rem;
}

.time-badge {
  display: inline-block;
  padding: .35rem .75rem;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: .8rem; font-weight: 600;
  color: var(--accent);
}

/* Show Countdown Page — Display */
.page-show-countdown {
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh; padding: 1rem;
}

.countdown-container {
  width: 100%; max-width: 600px;
  padding: 3rem 2rem;
  border-radius: var(--radius);
  border: 2px solid var(--border);
  text-align: center;
}

.countdown-header {
  margin-bottom: 3rem;
}

.countdown-header h1 {
  font-size: 2.2rem; font-weight: 700;
  color: var(--text); margin-bottom: .75rem;
}

.countdown-park {
  font-size: 1.1rem; font-weight: 600;
}

.countdown-display {
  display: flex; flex-direction: column;
  align-items: center; gap: 1.5rem;
}

.countdown-timer {
  width: 100%; padding: 2rem;
  background: var(--bg3);
  border-radius: var(--radius);
  border: 2px solid var(--border);
}

.timer-value {
  display: block;
  font-size: 4rem; font-weight: 700;
  font-family: 'Courier New', monospace;
  color: var(--accent);
  letter-spacing: .1em;
}

.timer-value.timer-expired {
  color: var(--high); font-size: 2rem;
}

.countdown-show-time {
  font-size: 1.1rem; color: var(--text-muted);
}

.show-time {
  display: inline-block;
  font-size: 1.3rem; font-weight: 700;
  color: var(--accent); margin-left: .5rem;
  font-family: 'Courier New', monospace;
}

/* Mobile: Responsive countdown */
@media (max-width: 768px) {
  .page-test-countdown {
    padding: 1.5rem .75rem;
  }

  .page-test-countdown h1 {
    font-size: 1.4rem; margin-bottom: 1.5rem;
  }

  .shows-list {
    grid-template-columns: 1fr;
  }

  .countdown-container {
    padding: 2rem 1.5rem;
  }

  .countdown-header h1 {
    font-size: 1.8rem;
  }

  .timer-value {
    font-size: 2.5rem;
  }

  .countdown-show-time {
    font-size: .95rem;
  }

  .show-time {
    font-size: 1.1rem;
  }
}


/* ── Points d'intérêt (POI sans temps d'attente : château, monuments, galeries…) ── */
.poi-block { margin-top: 1.5rem; }
.poi-title {
  font-size: .95rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin: 0 0 .5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}
.poi-table .col-name { color: var(--text-muted); }
/* POI : non cliquable (pas de page dédiée) */
.poi-row { cursor: default; }
