/* géosolidarité - feuille de style unique.
   Charte graphique : docs/charte-graphique.md (chaleureuse et naturelle, 29/10/2026).
     fond crème #FDFBF7, cartes blanches, primaire terracotta, secondaire sauge,
     textes charcoal chaud, titres Nunito (arrondie), corps Open Sans,
     arrondis généreux, ombres douces ; teintes de texte assez soutenues pour WCAG AA.
   Pas de mode sombre. */

@font-face {
  /* Nunito variable (licence OFL, static/fonts/OFL.txt) : titres. */
  font-family: "Nunito";
  src: url("fonts/nunito-latin-wght-normal.woff2") format("woff2-variations"),
       url("fonts/nunito-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}

@font-face {
  /* Open Sans variable (licence OFL, static/fonts/OFL.txt) : font-stretch 75 % = condensee. */
  font-family: "Open Sans";
  src: url("fonts/open-sans-latin-wdth-normal.woff2") format("woff2-variations"),
       url("fonts/open-sans-latin-wdth-normal.woff2") format("woff2");
  font-weight: 300 800;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}

:root {
  --fond: #fdfbf7;
  --surface: #ffffff;
  --texte: #4a4e5e;
  --texte-fort: #2b2d42;
  --texte-doux: #5b5f73;
  --bordure: #ece5dc;
  --titre: #c8553d;
  --lien: #b8472f;
  --primaire: #b8472f;
  --primaire-fonce: #a8432a;
  --primaire-decor: #e07a5f;
  --primaire-clair: #fceee9;
  --accent: #1f7a6f;
  --accent-fonce: #18645b;
  --accent-decor: #2a9d8f;
  --accent-clair: #e6f3f1;
  --logo-vert: #2a9d8f;
  --erreur: #b3261e;
  --erreur-fond: #fbe9e7;
  --alerte-fond: #fff4dc;
  --rayon: 20px;
  --rayon-champ: 12px;
  --ombre: 0 1px 2px rgba(124, 45, 18, .04), 0 6px 20px rgba(124, 45, 18, .06);
  --ombre-forte: 0 2px 4px rgba(124, 45, 18, .06), 0 10px 28px rgba(124, 45, 18, .10);
  --police-titre: "Nunito", "Quicksand", "Segoe UI", Arial, sans-serif;
  --police-texte: "Open Sans", "Segoe UI", Arial, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  font: 16px/1.5 Arial, Helvetica, sans-serif;
}
a { color: var(--lien); text-decoration: underline dashed; text-underline-offset: 3px; }
a:hover { text-decoration-style: solid; }
h1, h2, h3, legend {
  font-family: var(--police-titre);
  font-stretch: 75%;
  font-weight: 700;
  line-height: 1.15;
}
h1 { color: var(--titre); font-size: clamp(2rem, 4vw, 2.6rem); margin: 0 0 .6rem; }
h2 { color: var(--texte); font-size: clamp(1.45rem, 3vw, 1.9rem); margin: 0 0 .75rem; }
.intro h1 { font-size: clamp(2.3rem, 6vw, 3.75rem); } /* 60 px de la charte, sur la page d'accueil */
strong { color: var(--texte-fort); }

/* --- En-tete, pied --------------------------------------------------- */
.entete {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: .6rem 1.25rem; background: var(--surface); border-bottom: 3px solid var(--titre);
}
.marque { display: flex; align-items: center; gap: .6rem; text-decoration: none; }
.marque-repere { width: 2.6rem; height: 3rem; flex: none; }
.marque-texte { display: flex; flex-direction: column; line-height: 1.05; }
.marque-nom {
  font-family: var(--police-titre); font-stretch: 85%; font-weight: 800; font-size: 1.9rem;
  color: #1e293b; letter-spacing: -.01em;
}
.marque-nom span { color: var(--logo-vert); }
.marque-slogan { font-size: .78rem; color: var(--texte); letter-spacing: .02em; }
.compte { display: flex; align-items: center; gap: .75rem; }
.compte-nom { display: flex; flex-direction: column; text-align: right; line-height: 1.2; }
.compte-nom small { color: var(--texte-doux); }
.page { max-width: 1480px; margin: 0 auto; padding: 1.5rem 1.5rem 3rem; }
/* Les formulaires restent a une largeur confortable a lire ; les listes profitent de tout l'ecran. */
.formulaire-large { max-width: 1180px; }
.pied { text-align: center; color: var(--texte-doux); font-size: .85rem; padding: 1rem; }

/* --- Blocs ------------------------------------------------------------ */
.carte {
  background: var(--surface); border: 1px solid var(--bordure); border-radius: var(--rayon);
  padding: 1.5rem; margin-bottom: 1.25rem;
}
.carte-etroite { max-width: 520px; margin: 1rem auto; }
.intro { text-align: center; max-width: 720px; margin: .5rem auto 1.75rem; }
.intro p { color: var(--texte-doux); }
.accueil-grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.25rem; }
.choix-inscription { display: grid; gap: .75rem; }
.tuile {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: .9rem;
  align-items: center; padding: 1rem; border: 1px solid var(--bordure); border-radius: var(--rayon);
  text-decoration: none; color: var(--texte); background: var(--fond);
}
.tuile:hover, .tuile:focus-visible { border-color: var(--accent); background: var(--accent-clair); }
.tuile .icone { grid-row: span 2; color: var(--accent); }
.tuile span { color: var(--texte-doux); font-size: .9rem; }

/* --- Icones (Lucide, inserees en SVG) --------------------------------- */
.icone { width: 1.25em; height: 1.25em; flex: none; vertical-align: -.25em; }
.icone-grande { width: 2.25rem; height: 2.25rem; }

/* --- Formulaires ------------------------------------------------------ */
.formulaire { display: grid; gap: 1rem; }
.formulaire-large { gap: 1.25rem; }
.bloc {
  border: 1px solid var(--bordure); border-radius: var(--rayon); background: var(--surface);
  padding: 1rem 1.25rem 1.25rem; margin: 0; min-width: 0;
}
.bloc > legend { padding: 0 .4rem; font-size: 1.45rem; color: var(--texte); }
.grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: .9rem 1.25rem; margin-bottom: .9rem; }
.champ-large { grid-column: 1 / -1; }
.champ { display: flex; flex-direction: column; gap: .3rem; border: 0; padding: 0; margin: 0; min-width: 0; }
.champ > span, .champ > legend { font-weight: 600; padding: 0; color: var(--texte-fort); }
.champ > legend { font-family: inherit; font-stretch: normal; font-size: 1rem; line-height: 1.5; }
input, select, textarea {
  font: inherit; color: var(--texte); background: var(--surface);
  border: 1px solid var(--bordure); border-radius: 8px; padding: .55rem .7rem; width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
input[type="checkbox"], input[type="radio"] { width: auto; accent-color: var(--accent); }
.champ-erreur input, .champ-erreur select, .champ-erreur textarea { border-color: var(--erreur); }
.erreur { color: var(--erreur); font-weight: 500; }
.aide { color: var(--texte-doux); font-size: .88rem; margin: 0 0 .5rem; }
.champ .aide { margin: 0; }
.requis { color: var(--erreur); font-style: normal; }
.radios { display: flex; gap: 1.5rem; }
.radios label { display: flex; align-items: center; gap: .4rem; }
.champ-avec-bouton { display: grid; grid-template-columns: 1fr auto; gap: .3rem .5rem; align-items: start; }
.champ-avec-bouton > .bouton { margin-top: 1.85rem; }
.champ-avec-bouton > [data-siret-message] { grid-column: 1 / -1; }
/* Champs de longueur fixe : largeur proportionnee au contenu (et non a toute la colonne). */
input[type="date"] { width: 11.5rem; }
input[data-siret] { width: 12.5rem; }
input[name="code_postal"] { width: 7rem; }
input[name="code_interne"] { width: 9.5rem; text-transform: uppercase; }
input[type="tel"] { width: 12.5rem; }
input[name="kg_max"], input[name="km_max"] { width: 8rem; }
input[type="date"], input[data-siret], input[name="code_postal"], input[name="code_interne"], input[type="tel"],
input[name="kg_max"], input[name="km_max"] { max-width: 100%; font-variant-numeric: tabular-nums; }
.champ-avec-bouton { grid-template-columns: 12.5rem auto; justify-content: start; }
@media (min-width: 760px) { .grille > .champ-avec-bouton { grid-column: span 2; } }
.mdp { position: relative; display: block; }
.mdp input { padding-right: 2.75rem; }
.mdp-voir {
  position: absolute; right: .35rem; top: 50%; transform: translateY(-50%);
  border: 0; background: none; color: var(--texte-doux); cursor: pointer; padding: .3rem; display: flex;
}
.avec-infobulle { position: relative; }
.champ > .infobulle {
  position: absolute; left: 0; top: 100%; z-index: 10; margin-top: .35rem; width: max-content; max-width: 280px;
  padding: .55rem .75rem; border-radius: 8px; background: var(--texte-fort); color: #fff;
  font-size: .85rem; font-weight: 400; line-height: 1.4; box-shadow: 0 4px 14px rgba(0, 0, 0, .18);
  visibility: hidden; opacity: 0; transition: opacity .15s;
}
.avec-infobulle:hover .infobulle, .avec-infobulle:focus-within .infobulle { visibility: visible; opacity: 1; }
.consentement label { display: flex; gap: .6rem; align-items: flex-start; }
.consentement input { margin-top: .3rem; }
.texte-long { max-width: 860px; margin: 0 auto; }
.texte-long h2 { margin-top: 1.75rem; }
.texte-long li { margin-bottom: .35rem; }
.tableau { width: 100%; border-collapse: collapse; margin: .5rem 0 1rem; }
.tableau th, .tableau td { text-align: left; vertical-align: top; padding: .55rem .7rem; border-bottom: 1px solid var(--bordure); }
.tableau thead th { color: var(--texte-fort); border-bottom: 2px solid var(--bordure); }
.tableau tbody th { color: var(--texte-fort); font-weight: 600; width: 30%; }
.piege { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }

.cases-categories { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .5rem; }
.case-categorie {
  display: flex; align-items: center; gap: .55rem; padding: .55rem .7rem; cursor: pointer;
  border: 1px solid var(--bordure); border-radius: 8px; background: var(--fond);
}
.case-categorie .icone { color: var(--accent); }
.case-categorie:has(input:checked) { border-color: var(--accent); background: var(--accent-clair); }

.dispos { border-collapse: collapse; }
.dispos th, .dispos td { padding: .35rem .9rem; border-bottom: 1px solid var(--bordure); text-align: center; }
.dispos tbody th { text-align: left; font-weight: 500; }
.dispos input { width: 1.2rem; height: 1.2rem; }

/* --- Boutons ---------------------------------------------------------- */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  font: inherit; font-weight: 500; padding: .55rem 1.1rem; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--bordure); background: var(--surface); color: var(--texte); text-decoration: none;
}
.bouton:hover { border-color: var(--accent); }
.bouton-principal { background: var(--accent); border-color: var(--accent); color: #fff; }
.bouton-principal:hover { background: var(--accent-fonce); }
.bouton-discret { padding: .35rem .75rem; font-size: .9rem; }
.lien-icone { display: inline-flex; align-items: center; gap: .4rem; }

/* --- Messages --------------------------------------------------------- */
.messages { display: grid; gap: .5rem; margin-bottom: 1rem; }
.msg { padding: .75rem 1rem; border-radius: 8px; border-left: 4px solid; }
.msg-ok { background: var(--accent-clair); border-color: var(--accent); }
.msg-error { background: var(--erreur-fond); border-color: var(--erreur); }
.msg-warning { background: var(--alerte-fond); border-color: #c98a00; }

.badge { display: inline-block; padding: .1rem .55rem; border-radius: 999px; background: var(--accent-clair); color: var(--accent-fonce); font-size: .85rem; }
.menu {
  display: flex; flex-wrap: wrap; gap: .25rem; padding: .4rem 1.25rem; background: var(--surface);
  border-bottom: 1px solid var(--bordure);
}
.menu a, .menu span { padding: .4rem .75rem; border-radius: 6px; text-decoration: none; font-weight: 600; font-size: .95rem; }
.menu a { color: var(--texte-fort); }
.menu a:hover { background: var(--accent-clair); }
.menu a[aria-current="page"] { background: var(--accent-clair); color: var(--accent-fonce); }
.menu-a-venir { color: #9a9da1; font-weight: 400 !important; cursor: default; }
.liste-menu { columns: 2 240px; padding-left: 1.2rem; }
.liste-menu li { margin-bottom: .35rem; }

/* --- Listes et fiches de gestion -------------------------------------- */
.entete-page { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.entete-page h1 { margin: 0; }
.fil { font-size: .9rem; margin-bottom: .5rem; }
.tableau-defilant { overflow-x: auto; position: relative; }
.tableau td.nombre, .tableau th.nombre { text-align: right; white-space: nowrap; }
.tableau tbody tr:hover { background: var(--fond); }
.code { font-family: Consolas, "Courier New", monospace; font-weight: 700; color: var(--texte-fort); }
.cp-liste { font-family: Consolas, "Courier New", monospace; font-size: .85rem; max-width: 340px; overflow-wrap: anywhere; }
.etat { display: inline-block; padding: .1rem .55rem; border-radius: 999px; font-size: .82rem; font-weight: 600; }
.etat-actif { background: var(--accent-clair); color: var(--accent-fonce); }
.etat-en_attente { background: var(--alerte-fond); color: #8a5a00; }
.etat-desactive { background: #ececea; color: #6b6e72; }
.actions-ligne { display: flex; gap: .4rem; flex-wrap: wrap; }
.actions-ligne form { margin: 0; }
.alerte-impacts { background: var(--alerte-fond); border-left: 4px solid #c98a00; padding: 1rem 1.25rem; border-radius: 8px; }
textarea.cp { font-family: Consolas, "Courier New", monospace; min-height: 7rem; }
.vide { color: var(--texte-doux); font-style: italic; }

@media (max-width: 560px) {
  .page { padding: 1rem .75rem 2rem; }
  .carte, .bloc { padding: 1rem; }
  .compte-nom { display: none; }
  .dispos th, .dispos td { padding: .35rem .5rem; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); border: 0; }

/* --- Pre-inscriptions ------------------------------------------------- */
.badge-donateur { background: #fdebdc; color: #9a3412; }
.badge-association { background: var(--accent-clair); color: var(--accent-fonce); }
.bouton-danger { background: var(--erreur); border-color: var(--erreur); color: #fff; }
.bouton-danger:hover { background: #8c1d17; }
.bloc-validation { border: 2px solid var(--accent); }
.bloc-validation > legend { color: var(--accent-fonce); }
.champ .libelle { font-weight: 600; color: var(--texte-fort); }
.carte-position { height: 340px; border: 1px solid var(--bordure); border-radius: 8px; margin: .4rem 0; z-index: 0; }
.liste-liens { display: grid; gap: .35rem; max-height: 22rem; overflow-y: auto; padding: .25rem; border: 1px solid var(--bordure); border-radius: 8px; }
.case-lien { display: flex; gap: .6rem; align-items: flex-start; padding: .35rem .5rem; border-radius: 6px; cursor: pointer; }
.case-lien:hover { background: var(--fond); }
.case-lien input { margin-top: .3rem; }
.case-lien:has(input:checked) { background: var(--accent-clair); }

/* --- Organisations ---------------------------------------------------- */
.filtres { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: flex-end; margin-bottom: 1rem; }
.filtres .champ { min-width: 190px; }
.filtres .champ-date { min-width: 0; }
.roles-ligne { display: flex; flex-wrap: wrap; gap: .3rem .75rem; align-items: center; }
.roles-ligne label { display: flex; gap: .3rem; align-items: center; white-space: nowrap; }
.zone-statut { margin-top: 1.25rem; }

/* --- Categories -------------------------------------------------------- */
.choix-pictos { display: grid; grid-template-columns: repeat(auto-fill, minmax(3.4rem, 1fr)); gap: .4rem; }
.choix-picto { display: flex; align-items: center; justify-content: center; padding: .55rem; cursor: pointer;
  border: 1px solid var(--bordure); border-radius: 8px; color: var(--accent); background: var(--fond); }
.choix-picto input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choix-picto:has(input:checked) { border: 2px solid var(--accent); background: var(--accent-clair); }
.choix-picto:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.tableau tr.inactive td { color: #9a9da1; }

/* --- Paniers ----------------------------------------------------------- */
.bouton-grand { padding: .75rem 1.4rem; font-size: 1.05rem; }
.lignes-panier { display: grid; gap: .6rem; margin-bottom: 1rem; }
.ligne-panier {
  display: grid; grid-template-columns: minmax(150px, 1fr) 110px minmax(140px, 2fr) minmax(0, auto); gap: .5rem 1rem;
  align-items: end; padding: .75rem; border: 1px solid var(--bordure); border-radius: 8px; background: var(--fond);
}
.ligne-panier[hidden] { display: none; }
.ligne-entete { display: flex; align-items: center; gap: .6rem; color: var(--texte-fort); align-self: center; }
.ligne-entete .icone { color: var(--accent); }
.champ-dlc { min-width: 0; }
.champ-dlc .radios { align-items: center; flex-wrap: wrap; gap: .75rem; }
.kg-dlc input { width: 9rem; }
.total-panier { font-size: 1.05rem; }
.creneau { display: grid; grid-template-columns: 7rem repeat(3, minmax(120px, 1fr)); gap: .5rem 1rem; align-items: end; margin-bottom: .75rem; }
.creneau-numero { font-weight: 600; color: var(--texte-fort); align-self: center; }
.creneau .erreur { grid-column: 2 / -1; }
.resultat-eligibilite { border-left: 6px solid; }
.resultat-ok { border-left-color: var(--accent); background: var(--accent-clair); }
.resultat-ko { border-left-color: var(--erreur); background: var(--erreur-fond); }
.nombre-associations { font-size: 1.15rem; margin-top: 0; }
.statut { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .85rem; font-weight: 600; }
.statut-propose, .statut-relance { background: #e0f2fe; color: #075985; }
.statut-attribue { background: var(--accent-clair); color: var(--accent-fonce); }
.statut-obsolete, .statut-annule { background: #ececea; color: #6b6e72; }
.fiche-lecture { display: grid; grid-template-columns: minmax(150px, max-content) 1fr; gap: .45rem 1.25rem; margin: 0; }
.fiche-lecture dt { font-weight: 600; color: var(--texte-fort); }
.fiche-lecture dd { margin: 0; }
.cartes-associations { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .9rem; }
.carte-association { border: 1px solid var(--bordure); border-radius: 8px; padding: .9rem 1rem; background: var(--fond); }
.carte-association h3 { margin: 0 0 .4rem; font-family: var(--police-titre); font-stretch: 75%; font-size: 1.3rem; color: var(--texte-fort); }
.carte-association p { margin: .35rem 0; }
.chiffres { display: flex; gap: 1rem; font-weight: 600; color: var(--accent-fonce); }
@media (max-width: 900px) {
  .ligne-panier { grid-template-columns: 1fr 1fr; }
  .ligne-entete, .champ-description, .champ-dlc { grid-column: 1 / -1; }
  .creneau { grid-template-columns: 1fr 1fr; }
  .creneau-numero, .creneau .champ:first-of-type { grid-column: 1 / -1; }
}
[hidden] { display: none !important; }

.tableau-serre th, .tableau-serre td { padding: .45rem .5rem; font-size: .92rem; }
.commentaire-court { max-width: 14rem; color: var(--texte-doux); }

/* --- Evaluations -------------------------------------------------------- */
.sous-question { margin: .25rem 0 1rem 1.25rem; padding-left: 1rem; border-left: 3px solid var(--bordure); display: grid; gap: .75rem; }
.champ-quantite { max-width: 9rem; }
.valeur-corrigee { color: var(--titre); font-weight: 700; }
.encart-evaluation { border-left: 6px solid var(--erreur); background: var(--erreur-fond); }

.evaluations { white-space: nowrap; }
.pouce { display: inline-flex; vertical-align: middle; margin-right: .2rem; }
.pouce-donateur { color: #15803d; }
.pouce-association { color: #b91c1c; }
/* Pouces pleins (couleur a l'interieur) ; trait blanc pour garder le dessin (manchette, contour) lisible. */
.pouce svg { fill: currentColor; stroke: #fff; stroke-width: 1.5; }
.legende { margin-top: 0; }

/* --- Liens exclusifs ---------------------------------------------------- */
.liens-exclusifs { border: 1px solid var(--bordure); border-radius: 8px; padding: .9rem 1rem; background: var(--surface); max-width: 640px; }
.liens-entete { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; margin-bottom: .5rem; }
.liens-compte { color: var(--titre); font-weight: 600; }
.colonne-action { width: 4.5rem; text-align: center !important; }
.bouton-icone { border: 0; background: none; cursor: pointer; color: var(--texte-fort); padding: .25rem; border-radius: 6px; display: inline-flex; }
.bouton-icone:hover { background: var(--erreur-fond); color: var(--erreur); }
.liens-pied { display: flex; justify-content: flex-end; margin-top: .5rem; }
.bouton-plus { background: var(--titre); border-color: var(--titre); color: #fff; padding: .45rem .8rem; }
.bouton-plus:hover { background: #b53c0c; }
.ajout-lien { margin-top: .75rem; }
.suggestions-liens { list-style: none; margin: .25rem 0 0; padding: 0; border: 1px solid var(--bordure); border-radius: 8px; max-height: 16rem; overflow-y: auto; }
.suggestions-liens:empty { display: none; }
.suggestions-liens button { display: block; width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--bordure);
  background: var(--surface); padding: .5rem .75rem; cursor: pointer; font: inherit; color: var(--texte); }
.suggestions-liens li:last-child button { border-bottom: 0; }
.suggestions-liens button:hover, .suggestions-liens button:focus { background: var(--accent-clair); outline: none; }
.suppression-definitive { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--bordure); display: grid; gap: .5rem; justify-items: start; }

/* Colonnes de noms : pas de retour a la ligne pour quelques mots */
.tableau-serre td:nth-child(2), .tableau-serre td:nth-child(3) { min-width: 11rem; }
.tableau-serre td:nth-child(8), .tableau-serre td:nth-child(9) { min-width: 8rem; }
.tableau td.nombre, .tableau td.code, .tableau .code { white-space: nowrap; }
.creneau [data-creneau-message] { grid-column: 2 / -1; }
.creneau [data-creneau-message]:empty { display: none; }

/* --- Tableaux de bord --------------------------------------------------- */
.tableau-stats { width: auto; min-width: 100%; }
.tableau-stats th, .tableau-stats td { white-space: nowrap; padding: .45rem .6rem; }
.tableau-stats tbody th, .tableau-stats thead tr:first-child th:first-child {
  position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; box-shadow: 1px 0 0 var(--bordure);
}
.tableau-stats .total { background: var(--fond); font-weight: 700; color: var(--texte-fort); }
.tableau-stats .groupe { text-align: center; border-left: 1px solid var(--bordure); }
.tableau-stats .debut-groupe { border-left: 1px solid var(--bordure); }
.tableau-stats .pourcentage, .tableau-stats .ligne-pourcentage td { color: var(--accent-fonce); font-weight: 600; }
.tableau-etroit { min-width: 0; }
.carte .entete-page h2 { margin: 0; }

/* --- Graphiques en secteurs ------------------------------------------- */
.graphiques { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 1.5rem; margin-top: 1.5rem; }
.graphique-secteurs { margin: 0; border: 1px solid var(--bordure); border-radius: 8px; padding: 1rem; }
.graphique-secteurs figcaption { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .75rem; color: var(--texte-fort); }
.secteurs-corps { display: grid; grid-template-columns: minmax(160px, 220px) 1fr; gap: 1rem; align-items: center; }
.secteurs-corps svg { width: 100%; height: auto; }
.secteurs-corps path { cursor: pointer; outline: none; transition: opacity .15s; }
.secteurs-corps svg:hover path:not(:hover), .secteurs-corps svg:focus-within path:not(:focus) { opacity: .45; }
.legende-secteurs { list-style: none; margin: 0; padding: 0; display: grid; gap: .3rem; font-size: .9rem; }
.legende-secteurs li { display: grid; grid-template-columns: .85rem 1fr auto auto; gap: .5rem; align-items: center; }
.pastille { width: .85rem; height: .85rem; border-radius: 3px; }
.legende-valeur { font-weight: 700; color: var(--texte-fort); text-align: right; }
.infobulle-graphique { position: fixed; z-index: 20; pointer-events: none; background: #2e3033; color: #fff; padding: .4rem .65rem;
  border-radius: 6px; font-size: .85rem; box-shadow: 0 4px 14px rgba(0,0,0,.2); white-space: nowrap; }
@media (max-width: 560px) { .graphiques { grid-template-columns: 1fr; } .secteurs-corps { grid-template-columns: 1fr; } }
.infobulle-graphique strong { color: #fff; }
.actions-tableau { display: flex; justify-content: flex-end; margin-bottom: .5rem; }
.icone-bon { color: var(--titre); }
.bandeau-test { background: #f59f00; color: #1f2937; font-weight: 700; text-align: center; padding: .35rem 1rem; }
/* Menu a sous-menus (Parametrage du national) */
.menu-groupe { position: relative; }
.menu-groupe summary { list-style: none; cursor: pointer; padding: .4rem .75rem; border-radius: 6px; font-weight: 600;
  font-size: .95rem; color: var(--texte-fort); }
.menu-groupe summary::-webkit-details-marker { display: none; }
.menu-groupe summary::after { content: " \25BE"; font-size: .8em; }
.menu-groupe summary:hover, .menu-groupe[open] summary, .menu-groupe summary[aria-current="page"] { background: var(--accent-clair); }
.menu-sous { position: absolute; top: 100%; left: 0; z-index: 20; min-width: 14rem; margin-top: .2rem; padding: .3rem;
  display: flex; flex-direction: column; gap: .1rem; background: var(--surface); border: 1px solid var(--bordure);
  border-radius: 8px; box-shadow: 0 6px 18px rgba(0, 0, 0, .12); }
.bandeau-incarnation { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .5rem 1rem;
  background: #1e3a8a; color: #fff; padding: .4rem 1rem; }
.bandeau-incarnation form { margin: 0; }
.bandeau-incarnation strong { color: #fff; }
.bandeau-incarnation .bouton { background: #fff; }
/* Pieces jointes des paniers */
.trombone { display: inline-flex; vertical-align: middle; color: var(--titre); }
.trombone svg { width: 1rem; height: 1rem; }
.liste-pieces { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .4rem; }
.liste-pieces li { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .8rem; }
.liste-pieces form.en-ligne { display: inline; margin: 0; }
.ajout-pieces { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .75rem; }
.pleine-largeur { flex-basis: 100%; }
/* Colonnes triables (ecran Paniers) */
.colonne-triable a { display: inline-flex; align-items: center; gap: .3rem; color: inherit; text-decoration: none; white-space: nowrap; }
.colonne-triable a:hover { color: var(--lien); }
.tri-icone { display: inline-flex; color: var(--texte-doux); }
.tri-icone svg { width: .95rem; height: .95rem; }
.tri-icone.tri-actif { color: var(--titre); }
.confirmation-siret { display: flex; gap: .5rem; align-items: flex-start; flex-basis: 100%; margin-top: .4rem; font-weight: 600; }

/* ===================================================================== */
/* Charte graphique 2026 (docs/charte-graphique.md) : surcharges          */
/* ===================================================================== */
body { font-family: var(--police-texte); font-stretch: 100%; }
h1, h2, h3, legend, .marque-nom { font-family: var(--police-titre); font-stretch: normal; letter-spacing: -.01em; }
h1 { font-weight: 800; }
h2, h3, legend { font-weight: 700; color: var(--texte-fort); }
.marque-nom { color: var(--texte-fort); font-weight: 800; }
.icone, .entete svg, .menu svg { stroke-width: 1.75; }

/* En-tête et menu */
.entete { border-bottom: 0; box-shadow: var(--ombre); position: relative; z-index: 5; }
.menu { background: transparent; border-bottom: 1px solid var(--bordure); padding: .5rem 1.25rem; }
.menu a, .menu span, .menu-groupe summary { border-radius: 999px; }
.menu a[aria-current="page"], .menu-groupe summary[aria-current="page"] { background: var(--accent-clair); color: var(--accent-fonce); }

/* Cartes, blocs */
.carte, .bloc { border-color: transparent; border-radius: var(--rayon); box-shadow: var(--ombre); }
.carte-etroite { border-radius: var(--rayon); }

/* Champs */
input, select, textarea { border-radius: var(--rayon-champ); border-color: #e3dbd0; background: #fffefc; }
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(42, 157, 143, .25); outline-offset: 0; border-color: var(--accent-decor); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--primaire); }

/* Boutons : principal terracotta en pilule, secondaires bordés */
.bouton { border-radius: 999px; font-weight: 600; padding: .6rem 1.25rem; border-color: #e3dbd0; transition: background .15s, border-color .15s, box-shadow .15s; }
.bouton:hover { border-color: var(--accent-decor); }
.bouton-principal { background: var(--primaire); border-color: var(--primaire); color: #fff; box-shadow: 0 4px 14px rgba(184, 71, 47, .25); }
.bouton-principal:hover { background: var(--primaire-fonce); border-color: var(--primaire-fonce); }
.bouton-contour { background: var(--surface); border: 2px solid var(--accent-decor); color: var(--accent-fonce); }
.bouton-contour:hover { background: var(--accent-clair); }
.bouton-discret { padding: .38rem .9rem; }

/* Messages, badges, états */
.msg { border-radius: 14px; border-left-width: 0; box-shadow: var(--ombre); }
.msg-ok { background: var(--accent-clair); }
.msg-warning { background: #fff6e5; }
.badge-donateur { background: var(--primaire-clair); color: #8f3a26; }
.tableau thead th { border-bottom-color: var(--bordure); }
.tableau tbody tr:hover { background: #fffaf5; }
.bloc-validation { border: 2px solid var(--accent-decor); }

/* Page d'accueil : tient sur un écran sans défilement (2 colonnes : présentation | connexion) */
.accueil { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, 1fr); gap: 2rem; align-items: center;
  max-width: 1180px; margin: 0 auto; }
.hero { text-align: left; }
.hero h1 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); line-height: 1.1; margin: .55rem 0 .6rem; }
.hero-texte { font-size: 1.02rem; color: var(--texte); margin: 0 0 1rem; }
.hero-pastille {
  display: inline-flex; align-items: center; gap: .4rem; margin: 0;
  padding: .25rem .8rem; border-radius: 999px; background: var(--accent-clair); color: var(--accent-fonce);
  font-weight: 600; font-size: .82rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .55rem; margin-bottom: .45rem; }
.bouton-hero { padding: .6rem 1.15rem; font-size: .98rem; }
.hero .aide { font-size: .85rem; margin: 0 0 1rem; }
.conseils { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; }
.conseil { display: flex; flex-direction: column; gap: .45rem; padding: .8rem .9rem; border-radius: 18px;
  background: linear-gradient(160deg, #fff 0%, #fff8f3 100%); box-shadow: var(--ombre); }
.conseil p { margin: .15rem 0 0; color: var(--texte); font-size: .86rem; line-height: 1.4; }
.conseil strong { color: var(--texte-fort); font-family: var(--police-titre); font-size: .98rem; }
.conseil-pastille { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 2.2rem; height: 2.2rem; border-radius: 999px; }
.conseil-pastille .icone { width: 1.15rem; height: 1.15rem; }
.conseil-terracotta { background: var(--primaire-clair); color: var(--primaire); }
.conseil-sauge { background: var(--accent-clair); color: var(--accent); }
.carte-connexion { margin: 0; padding: 1.4rem 1.5rem; }
.carte-connexion h2 { margin-bottom: .6rem; }
.carte-connexion .formulaire { gap: .75rem; }
.page:has(> .accueil) { padding-top: 1rem; padding-bottom: 1rem; }
@media (max-width: 900px) {
  .accueil { grid-template-columns: 1fr; }
  .conseils { grid-template-columns: 1fr; }
}
