/* Un bloc caché le reste, même quand sa classe lui donne un display (bandeau, grille de résultats). */
[hidden] { display: none !important; }

:root {
  --fond: #f6f7f9;
  --surface: #ffffff;
  --texte: #1a1d23;
  --doux: #5b6270;
  --trait: #dfe3ea;
  --accent: #1f5eff;
  --sur-accent: #ffffff;
  --accent-fond: #eef3ff;
  --top: #0e7a43;
  --top-fond: #e3f5ea;
  --alerte: #a33a00;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fond: #111318;
    --surface: #1b1e25;
    --texte: #eceef2;
    --doux: #9aa2b1;
    --trait: #2d323c;
    --accent: #7aa2ff;
    --sur-accent: #0b1020;
    --accent-fond: #1c2a4d;
    --top: #6fdc9e;
    --top-fond: #133322;
    --alerte: #ffab70;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --fond: #111318; --surface: #1b1e25; --texte: #eceef2; --doux: #9aa2b1; --trait: #2d323c;
  --accent: #7aa2ff; --sur-accent: #0b1020; --accent-fond: #1c2a4d; --top: #6fdc9e; --top-fond: #133322; --alerte: #ffab70;
  color-scheme: dark;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.45;
}
main { padding-block: var(--pt-e-5, 24px) var(--pt-e-7, 48px); display: grid; gap: var(--pt-e-5, 24px); }
h1 { margin: 0; font-size: var(--pt-t-3, 1.8rem); letter-spacing: -0.02em; }
h2 { margin: 0 0 .3em; font-size: var(--pt-t-1, 1.2rem); }
.sous, .aide { color: var(--doux); margin: .2em 0; }
.aide { font-size: var(--pt-t--1, .85rem); }

.carte {
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: 14px;
  padding: var(--pt-e-4, 16px);
  min-width: 0;
}
form { display: grid; gap: var(--pt-e-3, 12px); }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { font-weight: 600; margin-bottom: .3em; }
.ligne { display: flex; flex-wrap: wrap; gap: var(--pt-e-3, 12px); align-items: end; }
.ligne > label { flex: 1 1 8rem; }
label { display: grid; gap: .25em; font-weight: 600; }
.ligne > span { align-self: center; color: var(--doux); }
input, select, button {
  font: inherit;
  min-height: 44px;
  padding: .4em .6em;
  border: 1px solid var(--trait);
  border-radius: 10px;
  background: var(--fond);
  color: var(--texte);
  min-width: 0;
}
input[type="date"] { flex: 1 1 9rem; }
#depart, #arrivee { text-transform: uppercase; }
button {
  background: var(--accent);
  color: var(--sur-accent);
  border: 0;
  font-weight: 700;
  cursor: pointer;
}
button:disabled { opacity: .6; cursor: progress; }
.puces { display: flex; flex-wrap: wrap; gap: 8px; }
.puces label {
  display: flex; align-items: center; gap: .4em;
  min-height: 44px; padding: 0 .8em;
  border: 1px solid var(--trait); border-radius: 999px; font-weight: 500;
}
.puces input { min-height: auto; width: 22px; height: 22px; margin: 0; }
.puces label { cursor: pointer; }
progress { width: 100%; height: 10px; accent-color: var(--accent); }
#erreurs { color: var(--alerte); }

.defile { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
th, td { padding: 0; text-align: center; border: 1px solid var(--trait); }
th { padding: .45em .3em; font-size: var(--pt-t--1, .85rem); color: var(--doux); font-weight: 600; }
td button {
  width: 100%; min-height: 44px; border-radius: 0;
  background: transparent; color: var(--texte); font-weight: 500; padding: .3em; white-space: nowrap;
}
td button[aria-pressed="true"] { outline: 2px solid var(--accent); outline-offset: -2px; font-weight: 800; }
td.top button { background: var(--top-fond); color: var(--top); font-weight: 800; }
td.vide { color: var(--doux); }

#vols { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--pt-e-3, 12px); }
.vol { border: 1px solid var(--trait); border-radius: 12px; padding: var(--pt-e-3, 12px); display: grid; gap: .4em; }
.vol-tete { display: flex; justify-content: space-between; gap: 1em; flex-wrap: wrap; align-items: baseline; }
.vol-prix { font-size: var(--pt-t-2, 1.4rem); font-weight: 800; }
.vol-seg { color: var(--doux); font-size: var(--pt-t--1, .85rem); }
.economie { color: var(--top); font-weight: 700; }
.reserver {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; margin: 4px 0 8px;
  border-radius: 8px; background: var(--accent); color: var(--sur-accent); font-weight: 700; text-decoration: none;
}
.sejour-lien {
  display: inline-flex; align-items: center; min-height: 44px; color: var(--texte); font-weight: 700;
}
.par-pays { display: flex; flex-wrap: wrap; gap: 6px; }
.par-pays a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 .7em;
  border: 1px solid var(--trait); border-radius: 10px;
  color: var(--texte); text-decoration: none; font-size: var(--pt-t--1, .85rem);
}
.par-pays a.moins-cher { border-color: var(--top); color: var(--top); font-weight: 700; }

/* ── Menu Vols / Séjour ── */
.menu { background: var(--surface); color: var(--texte); border-top: 1px solid var(--trait); }
.menu a {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
  color: var(--doux); text-decoration: none; font-weight: 500;
}
.menu a[aria-current="page"] { color: var(--texte); font-weight: 700; }
.menu-marque { display: none; font-weight: 700; margin-right: var(--pt-e-4, 16px); }
@media (max-width: 599.98px) {
  .menu a { flex-direction: column; gap: 2px; font-size: .75rem; flex: 1; justify-content: center; }
}
@media (min-width: 600px) {
  .menu { border-top: 0; border-bottom: 1px solid var(--trait); gap: var(--pt-e-5, 24px); }
  .menu-marque { display: inline; }
  .menu a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--texte); }
}

/* Mes recherches (d20) */
.historique ul { list-style: none; margin: .4em 0 0; padding: 0; display: grid; gap: 8px; }
.ligne-recherche {
  width: 100%; min-height: 44px; display: flex; justify-content: space-between; align-items: center; gap: 12px;
  text-align: left; background: var(--fond); color: var(--texte); border: 1px solid var(--trait); font-weight: 600;
}
.ligne-recherche small { color: var(--doux); font-weight: 500; white-space: nowrap; }
/* Mes alertes (d30) */
.alerte { border: 1px solid var(--trait); border-radius: 8px; padding: 10px 12px; display: grid; gap: 6px; }
.alerte-tete { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.alerte p { margin: 0; }
.alerte .arreter { justify-self: start; min-height: 44px; background: var(--fond); color: var(--texte); border: 1px solid var(--trait); }
.courbe { color: var(--texte); flex: none; }
.surveiller { margin: 0 0 12px; }
.surveiller button { min-height: 44px; display: inline-flex; align-items: center; gap: 8px; }
.surveiller p { margin: .4em 0 0; }
.bandeau { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.bandeau p { margin: 0; }
