/* ===== Design tokens ===== */
:root {
  --marque: #047857;
  --marque-clair: #ecfdf5;
  --accent: #f97316;
  --accent-clair: #fff7ed;
  --fond: #f8fafc;
  --surface: #ffffff;
  --texte: #0f172a;
  --texte-mute: #64748b;
  --ligne: #e2e8f0;

  --font-display: "Space Grotesk", sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "Inter", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  font-family: var(--font-body);
  line-height: 1.6;
}

.entete {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ligne);
  padding: 1.1rem 1.5rem;
}

.entete-contenu {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.logo-site {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--texte);
  text-decoration: none;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-site::before {
  content: "";
  display: inline-block;
  width: 28px;
  height: 28px;
  background: var(--marque);
  border-radius: 8px;
}

.logo-site em {
  font-style: normal;
  color: var(--marque);
}

.sous-titre-site {
  font-size: 0.8rem;
  color: var(--texte-mute);
  font-weight: 500;
}

.nav-entete {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav-entete > a {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--texte-mute);
  text-decoration: none;
  transition: color 0.15s ease;
}

.nav-entete > a:hover {
  color: var(--marque);
}

.btn-gite {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  background: var(--accent);
  padding: 0.55rem 1.1rem;
  border-radius: 0.65rem;
  text-decoration: none;
  transition: background 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.btn-gite:hover {
  background: #ea580c;
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.conteneur {
  max-width: 960px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.titre-page {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
  color: var(--texte);
}

.chapo-page {
  font-family: var(--font-body);
  font-size: 1.02rem;
  color: var(--texte-mute);
  max-width: 42ch;
  margin: 0;
}

.section-que-faire {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.que-faire-texte {
  flex: 1;
  min-width: 260px;
}

.que-faire-texte .titre-page {
  margin-bottom: 0.75rem;
}

.que-faire-image {
  flex: 1;
  min-width: 260px;
  max-width: 380px;
  height: 240px;
  object-fit: cover;
  border-radius: 1.25rem;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
}

@media (max-width: 700px) {
  .section-que-faire { flex-direction: column; }
  .que-faire-image { max-width: 100%; width: 100%; }
}

/* ===== Bandeau court (date/heure/fete + qualite air) ===== */
.bandeau-court {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 1rem;
  padding: 1rem 1.5rem;
  margin-bottom: 1rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.bandeau-court-date {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  flex-wrap: wrap;
}

.bandeau-court-jour {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--texte-mute);
}

.bandeau-court-heure {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--texte);
}

.bandeau-court-saint {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
}

.bandeau-court-air {
  font-size: 0.85rem;
  color: var(--texte-mute);
}

.bandeau-court-lien {
  font-weight: 600;
  color: var(--marque);
  text-decoration: none;
}

.bandeau-court-lien:hover {
  text-decoration: underline;
}

/* ===== Grille de 4 cartes resumees ===== */
.grille-infos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.carte-info {
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 1rem;
  padding: 0;
  overflow: hidden;
  position: relative;
  min-height: 108px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.2s ease;
}

.carte-info:hover {
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

.carte-info-vignette {
  width: 100%;
  height: 84px;
  object-fit: cover;
  display: block;
}

.carte-info-corps {
  padding: 1.1rem 1.25rem 2.3rem;
}

.carte-info-titre {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--texte-mute);
  margin: 0 0 0.55rem;
}

.carte-info-forte {
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.carte-info-contenu {
  font-size: 0.85rem;
  color: var(--texte-mute);
  margin: 0;
}

.liste-courte {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.85rem;
}

.liste-courte li {
  padding: 0.1rem 0;
  color: var(--texte);
}

.liste-courte-detail {
  color: var(--texte-mute);
  font-size: 0.78rem;
}

.previsions-semaine {
  display: flex;
  gap: 0.6rem;
}

.previsions-jour {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  font-size: 0.7rem;
  color: var(--texte-mute);
  text-transform: capitalize;
}

.lien-plus {
  position: absolute;
  bottom: 0.8rem;
  right: 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--marque);
  text-decoration: none;
}

.lien-plus:hover {
  text-decoration: underline;
}

.liens-carte {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: 0.6rem;
}

.lien-carte {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--marque);
  text-decoration: none;
}

.lien-carte:hover {
  text-decoration: underline;
}

.aqi-bon { color: var(--marque); }
.aqi-moyen { color: var(--accent); }
.aqi-degrade { color: #ea580c; }
.aqi-mauvais { color: #dc2626; }
.aqi-tres-mauvais { color: #991b1b; }


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

.grille-alaune {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.carte-alaune {
  display: block;
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 1rem;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.carte-alaune:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.1);
}

.carte-alaune-image {
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.4rem;
}

.carte-alaune-corps {
  padding: 0.9rem 1.1rem 1.1rem;
}

.carte-alaune-date {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin: 0 0 0.3rem;
}

.carte-alaune-titre {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--texte);
  margin: 0;
  line-height: 1.3;
}

.filtres-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}

.filtre-chip {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.5rem 1.1rem;
  border-radius: 100px;
  border: 1px solid var(--ligne);
  background: var(--surface);
  color: var(--texte-mute);
  cursor: pointer;
  transition: all 0.15s ease;
}

.filtre-chip:hover {
  border-color: var(--marque);
  color: var(--marque);
}

.filtre-chip-actif,
.filtre-chip-actif:hover {
  background: var(--texte);
  border-color: var(--texte);
  color: #fff;
}

.carte-evenement {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 1rem;
  padding: 1.5rem 1.25rem 1.25rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}

.carte-evenement::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--couleur-carte, var(--marque));
}

.carte-evenement:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.1);
}

.billet-date {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 4rem;
  height: 4rem;
  border-radius: 0.85rem;
  margin-top: 0.5rem;
  margin-bottom: 0.6rem;
  overflow: visible;
}

.billet-emoji-fond {
  font-size: 2.1rem;
  line-height: 1;
}

.billet-badge-date {
  position: absolute;
  bottom: -0.5rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--texte);
  color: #fff;
  border-radius: 0.5rem;
  padding: 0.2rem 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.1;
  white-space: nowrap;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.2);
}

/* Evenement long (plusieurs jours) : badge un peu plus large pour le prefixe */
.billet-date-long .billet-badge-date {
  padding: 0.25rem 0.6rem;
}

.billet-badge-jourmois {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.billet-badge-prefixe {
  font-size: 0.5rem;
  text-transform: uppercase;
  opacity: 0.75;
}

.carte-titre {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 1rem 0 0.6rem;
}

.carte-titre a {
  color: var(--texte);
  text-decoration: none;
}

.carte-titre a:hover {
  color: var(--marque);
}

.carte-meta {
  font-size: 0.85rem;
  color: var(--texte-mute);
  margin: 0.2rem 0;
}

.carte-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.etiquette {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  background: var(--marque-clair);
  color: var(--marque);
  border-radius: 100px;
}

.etiquette.prix {
  background: var(--accent-clair);
  color: var(--accent);
}

.fil-retour {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--texte-mute);
  text-decoration: none;
  margin-bottom: 1.5rem;
}

.fil-retour:hover { color: var(--marque); }

.badge-categorie {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.35rem 0.9rem;
  border-radius: 100px;
  color: var(--texte);
  margin: 0.5rem 0 1rem;
}

.article-titre {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 4vw, 2.5rem);
  line-height: 1.15;
  margin: 0 0 1.5rem;
}

.article-corps {
  font-size: 1.05rem;
  max-width: 68ch;
}

.article-corps h2 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  margin-top: 2rem;
  color: var(--texte);
}

.article-corps h3 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent);
  margin-top: 2rem;
}

.article-corps table {
  border-collapse: collapse;
  width: 100%;
  margin: 1.25rem 0 2rem;
  font-size: 0.95rem;
  background: var(--surface);
  border-radius: 0.75rem;
  overflow: hidden;
  border: 1px solid var(--ligne);
}

.article-corps th,
.article-corps td {
  text-align: left;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--ligne);
}

.article-corps th {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--texte-mute);
  background: var(--fond);
  width: 30%;
}

.article-source {
  font-size: 0.85rem;
  color: var(--texte-mute);
  border-top: 1px solid var(--ligne);
  padding-top: 1rem;
  margin-top: 2rem;
}

.article-source a { color: var(--marque); }

.pied-site {
  border-top: 1px solid var(--ligne);
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--texte-mute);
}

.pied-site p {
  margin: 0.3rem 0;
}

.pied-nav {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin: 0.75rem 0;
}

.pied-nav a {
  color: var(--texte-mute);
  text-decoration: none;
  font-size: 0.82rem;
}

.pied-nav a:hover {
  color: var(--marque);
  text-decoration: underline;
}

.lien-credit {
  color: var(--marque);
  font-weight: 600;
  text-decoration: none;
}

.lien-credit:hover {
  text-decoration: underline;
}

.table-carburants {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1.5rem;
  font-size: 0.9rem;
  background: var(--surface);
  border-radius: 0.75rem;
  overflow: hidden;
  border: 1px solid var(--ligne);
}

.table-carburants th {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--texte-mute);
  text-align: left;
  padding: 0.7rem 0.8rem;
  background: var(--fond);
  border-bottom: 1px solid var(--ligne);
}

.table-carburants td {
  padding: 0.7rem 0.8rem;
  border-bottom: 1px solid var(--ligne);
}

.etiquette-tarif {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 100px;
  white-space: nowrap;
}

.tarif-economique { background: var(--marque-clair); color: var(--marque); }
.tarif-modere { background: var(--accent-clair); color: var(--accent); }
.tarif-eleve { background: #fee2e2; color: #dc2626; }
.tarif-variable { background: #e2e8f0; color: var(--texte-mute); }

.station-adresse {
  font-size: 0.78rem;
  color: var(--texte-mute);
}

.note-precision {
  font-size: 0.82rem;
  color: var(--texte-mute);
  border-left: 3px solid var(--ligne);
  padding-left: 0.8rem;
  margin: -1rem 0 2rem;
  max-width: 60ch;
}

.sous-titre-section {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
}

.sous-titre-section-majeur {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  border-top: 1px solid var(--ligne);
  padding-top: 1.5rem;
}

.liste-air {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ligne-air {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--ligne);
}

.ligne-air-phare {
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 0.75rem;
  padding: 0.9rem;
  margin-bottom: 0.5rem;
}

.air-ville {
  font-weight: 600;
}

.air-badge {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.2rem 0.7rem;
  border-radius: 100px;
  border: 1.5px solid currentColor;
}

.section-annuaire {
  margin-bottom: 2.5rem;
}

.liste-commerces {
  margin-top: 0.5rem;
}

.ligne-commerce {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--ligne);
  border-radius: 0.5rem;
  transition: background 0.15s ease;
}

.ligne-commerce:hover {
  background: var(--fond);
}

.ligne-commerce:first-child {
  border-top: 1px solid var(--ligne);
}

.ligne-commerce-principal {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.ligne-commerce-nom {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--texte);
  text-decoration: none;
}

a.ligne-commerce-nom:hover {
  color: var(--marque);
}

.ligne-commerce-commune {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--texte-mute);
}

.ligne-commerce-secondaire {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.ligne-commerce-tel {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--marque);
  text-decoration: none;
  white-space: nowrap;
}

.ligne-commerce-tel:hover {
  text-decoration: underline;
}

.ligne-commerce-empilee {
  flex-direction: column;
  align-items: flex-start;
}

.ligne-commerce-note {
  font-size: 0.78rem;
  color: var(--texte-mute);
  margin: 0.3rem 0 0;
}

.badge-ouvert,
.badge-ferme,
.badge-inconnu {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.65rem;
  border-radius: 100px;
}

.badge-ouvert {
  background: var(--marque-clair);
  color: var(--marque);
}

.badge-ferme {
  background: var(--accent-clair);
  color: var(--accent);
}

.badge-inconnu {
  background: #f1f5f9;
  color: var(--texte-mute);
}

.btn-toggle {
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--texte);
  color: #fff;
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: 0.6rem;
  cursor: pointer;
  margin-bottom: 2rem;
  transition: background 0.15s ease;
}

.btn-toggle:hover {
  background: var(--marque);
}

.encart-urgence {
  background: var(--texte);
  color: #fff;
  padding: 1.5rem;
  border-radius: 1rem;
  margin: 1.5rem 0 2.5rem;
}

.encart-urgence-numero {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.encart-urgence-texte {
  font-size: 0.92rem;
  margin: 0;
  max-width: 60ch;
  opacity: 0.85;
}

.encart-urgence-texte strong {
  color: #6ee7b7;
}

@media (max-width: 720px) {
  .grille-infos { grid-template-columns: 1fr 1fr; }
  .bandeau-court { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .grille-infos { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .conteneur { padding: 1.75rem 1.25rem 3rem; }
  .grille-evenements { grid-template-columns: 1fr; }
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .carte-evenement { transition: none; }
}
