/* ==========================================================
   Wasquehal en Transition – feuille de style unique
   Sommaire : 1 Variables · 2 Base · 3 Accessibilité · 4 En-tête
   · 5 Boutons · 6 Sections · 7 Pied de page · 8 Écrans larges
   ========================================================== */

/* 1. VARIABLES ------------------------------------------- */
:root {
  --vert: #2f5b40;      /* principal : en-tête, titres, pied de page */
  --jaune: #e0e448;     /* accent : titres sur fond vert, anneau de focus. JAMAIS en fond */
  --orange: #ff914d;    /* boutons d'action (texte foncé : contraste AA) */
  --texte: #1f2a24;     /* texte courant (≈ 14:1 sur blanc) */
  --fond: #ffffff;
  --fond-doux: #f4f6ef;
  --rayon: 0.5rem;
  --largeur: 68rem;
  --police: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* 2. BASE ------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--police);
  font-size: 1.125rem; /* 18 px */
  line-height: 1.6;
  color: var(--texte);
  background: var(--fond);
}
img, svg { max-width: 100%; height: auto; } /* les images ne sont jamais étirées : width reste auto */
h1, h2, h3 { color: var(--vert); line-height: 1.2; }
h1 { font-size: clamp(1.75rem, 5vw, 2.75rem); margin: 0 0 1rem; }
h2 { font-size: clamp(1.4rem, 3.5vw, 1.9rem); margin: 0 0 1rem; }
a { color: var(--vert); text-decoration: underline; text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 0.15em; }
.conteneur { width: min(100% - 2rem, var(--largeur)); margin-inline: auto; }

/* 3. ACCESSIBILITÉ --------------------------------------- */
:focus-visible { outline: 3px solid var(--texte); outline-offset: 3px; box-shadow: 0 0 0 6px var(--jaune); }
.lien-evitement {
  position: absolute; left: 0.5rem; top: -4rem; z-index: 100;
  padding: 0.75rem 1rem; background: #fff; color: var(--texte); border: 2px solid var(--texte); font-weight: 700;
}
.lien-evitement:focus { top: 0.5rem; }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* 4. EN-TÊTE ET NAVIGATION (menu mobile sans JavaScript) -- */
.entete { background: var(--vert); color: #fff; position: relative; }
.entete__barre { display: flex; align-items: center; justify-content: space-between; padding-block: 0.5rem; }
.entete__logo img { display: block; height: 3.5rem; width: auto; }
.menu-case { position: absolute; opacity: 0; width: 44px; height: 44px; right: 1rem; top: 0.9rem; margin: 0; cursor: pointer; z-index: 2; }
.menu-bouton {
  display: inline-flex; align-items: center; gap: 0.5rem; min-width: 44px; min-height: 44px;
  padding: 0.5rem 0.75rem; border: 2px solid #fff; border-radius: var(--rayon); font-weight: 700; cursor: pointer;
}
.menu-bouton::before { content: "\2630"; font-size: 1.4rem; line-height: 1; }
.menu-case:checked ~ .entete__barre .menu-bouton::before { content: "\2715"; }
.menu-case:focus-visible ~ .entete__barre .menu-bouton { outline: 3px solid var(--jaune); outline-offset: 3px; }
.nav { display: none; background: var(--vert); border-top: 1px solid rgba(255,255,255,.35); }
.menu-case:checked ~ .nav { display: block; }
.nav ul { list-style: none; margin: 0; padding: 0.5rem 0 1rem; }
.nav a {
  display: flex; align-items: center; min-height: 44px; padding: 0.5rem 0.25rem;
  color: #fff; font-weight: 600; text-decoration: none;
}
.nav a:hover { text-decoration: underline; }
.nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 0.2em; }

/* 5. BOUTONS --------------------------------------------- */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px;
  padding: 0.6rem 1.25rem; border-radius: var(--rayon); border: 2px solid var(--texte);
  font-weight: 700; text-decoration: none; background: var(--orange); color: var(--texte);
}
.bouton:hover { background: #e8782f; text-decoration: underline; }
.bouton--vert { background: var(--vert); color: #fff; border-color: var(--vert); }
.bouton--vert:hover { background: #24472f; }
.groupe-boutons { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.25rem; }

/* 6. SECTIONS (page d'accueil) --------------------------- */
.section { padding-block: 2.5rem; }
.section--doux { background: var(--fond-doux); }
.hero { padding-block: 2rem; background: var(--fond-doux); }
.hero h1 { margin: 0; }
.hero img { display: block; width: auto; max-width: 100%; height: auto; border-radius: var(--rayon); margin-inline: auto; }
.liste-raisons, .liste-valeurs { list-style: none; margin: 0; padding: 0; }
.liste-raisons li, .liste-valeurs li { padding-left: 2.25rem; position: relative; margin-bottom: 1rem; }
.liste-raisons li::before { content: "\1F331"; position: absolute; left: 0; }
.liste-valeurs li::before { content: "\27A1\FE0F"; position: absolute; left: 0; }
.objectif { font-size: 1.25rem; font-weight: 700; margin: 0 0 1.5rem; color: var(--texte); }
.objectif::before { content: "\1F3AF\00a0"; }
.cartes { display: grid; gap: 1rem; grid-template-columns: 1fr; }
.carte {
  display: flex; flex-direction: column; justify-content: space-between; gap: 1rem;
  padding: 1.5rem; background: #fff; border: 2px solid var(--vert); border-radius: var(--rayon);
}
.carte h3 { margin: 0; }

/* 7. PIED DE PAGE ---------------------------------------- */
.pied { background: var(--vert); color: #fff; padding-block: 2rem; }
.pied h2 { color: var(--jaune); font-size: 1.25rem; }
.pied a { color: #fff; }
.pied__colonnes { display: grid; gap: 1.5rem; }
.pied address { font-style: normal; }
.pied ul { list-style: none; padding: 0; margin: 0; }
.pied li a { display: inline-flex; align-items: center; min-height: 44px; }
.pied__legal { margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.35); font-size: 1rem; }

/* 8. ÉCRANS LARGES (mobile-first) ------------------------ */
@media (min-width: 48em) {
  .cartes { grid-template-columns: repeat(2, 1fr); }
  .pied__colonnes { grid-template-columns: repeat(3, 1fr); }
  .hero__grille { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: center; }
}
@media (min-width: 64em) {
  .menu-case, .menu-bouton { display: none; }
  .nav { display: block; background: none; border: 0; }
  .nav ul { display: flex; gap: 0.25rem; padding: 0; }
  .nav a { padding-inline: 0.75rem; }
  .entete__barre { padding-block: 0.75rem; }
}

/* 9. PAGES DE CONTENU ------------------------------------ */
.page { padding-block: 2rem 3rem; }
.conteneur--texte { width: min(100% - 2rem, 50rem); }
.page h2 { margin-top: 2.5rem; }
.page ul { padding-left: 1.25rem; }
.page li { margin-bottom: 0.75rem; }
.photo { display: block; width: auto; max-width: 100%; height: auto; border-radius: var(--rayon); margin: 1.5rem auto; } /* jamais agrandie au-delà de sa taille d'origine */
.photo--portrait { max-width: 24rem; margin-inline: auto; }
.liste-actions { list-style: none; padding-left: 0 !important; }
.liste-actions li { padding: 0.75rem 1rem; border-left: 4px solid var(--vert); background: var(--fond-doux); }
.partenaires { list-style: none; padding: 0 !important; display: grid; gap: 1rem; margin-top: 1.5rem; }
.partenaire { display: flex; flex-direction: column; align-items: center; gap: 1rem; margin: 0 !important; padding: 1.25rem; border: 2px solid var(--vert); border-radius: var(--rayon); background: #fff; text-align: center; }
.partenaire img { width: auto; max-width: 100%; height: auto; }
.partenaire p { margin: 0; }
@media (min-width: 48em) {
  .partenaire { flex-direction: row; text-align: left; }
  .partenaire img { flex: 0 0 auto; max-width: 12rem; }
}
