/* Troc en Stock - feuille de style unique, direction "Voisinage".

   Une seule famille, Plus Jakarta Sans en fonte variable, servie depuis
   static/fonts : aucune requete vers un tiers, aucun script externe. Les
   graisses 400 a 700 sortent toutes du meme fichier de 27 ko.

   Le parti pris : plus aucun filet. Les surfaces se distinguent par la
   teinte et par le rayon, pas par des traits. Chaque carte de la grille
   herite d'une teinte pastel via --teinte, ce qui donne de la couleur
   meme quand les photos sont ternes. */

@font-face {
  font-family: "Jakarta";
  src: url("../fonts/jakarta-latin.7660bd9909fb.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
                 U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F,
                 U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF,
                 U+FFFD;
}

@font-face {
  font-family: "Jakarta";
  src: url("../fonts/jakarta-latin-ext.341687eeeb6a.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F,
                 U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113,
                 U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --papier: #f2f5ef;
  --surface: #ffffff;
  --surface-creuse: #e9eee5;
  --encre: #1d2b1f;
  --encre-douce: #5c6b58;
  --encre-tres-douce: #66735c;
  --trait: #e0e7dc;

  --vert: #3e7d5a;
  --vert-fonce: #2c5c41;
  --vert-tres-fonce: #1f4530;
  --vert-pale: #dce9dd;
  --vert-encre: #25482f;

  --sable: #f5e6da;
  --sable-encre: #5c3a1c;
  --lavande: #e8e2f0;
  --lavande-encre: #3c2f55;
  --rouge: #a8443f;
  --rouge-pale: #f6e3e2;
  --rouge-encre: #6d2320;

  --sans: "Jakarta", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --rayon: 14px;
  --rayon-grand: 20px;
  --pilule: 999px;
  --gouttiere: 1.25rem;

  --teinte: var(--vert-pale);
  --teinte-encre: var(--vert-encre);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font: 1rem/1.65 var(--sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: -0.02em;
  margin: 0 0 0.6em;
}

h1 { font-size: 1.85rem; }
h2 { font-size: 1.3rem; margin-top: 2rem; }
h3 { font-size: 1.02rem; }

p { margin: 0 0 1rem; }

a { color: var(--vert-fonce); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--encre); }

:focus-visible {
  outline: 2px solid var(--vert);
  outline-offset: 3px;
  border-radius: 4px;
}

img { max-width: 100%; height: auto; display: block; }

.conteneur { width: min(100% - 2rem, 1180px); margin-inline: auto; }

.colonne-etroite { max-width: 34rem; }
.colonne-texte { max-width: 40rem; }
.colonne-texte p, .colonne-texte li { max-width: 68ch; }

.evitement { position: absolute; left: -9999px; }
.evitement:focus {
  position: static;
  display: inline-block;
  padding: 0.5rem 1.1rem;
  background: var(--vert-fonce);
  color: #fff;
  border-radius: var(--pilule);
}

/* ---------- Entete ---------- */

.entete { background: var(--papier); }

.entete-barre {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  padding: 1.1rem 0 0.9rem;
}

.marque {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-decoration: none;
  color: var(--encre);
  margin-right: auto;
  white-space: nowrap;
}
.marque-troc { color: var(--encre); }
.marque-en {
  font-size: 0.78em;
  font-weight: 500;
  color: var(--encre-tres-douce);
  margin: 0 0.24em;
}
.marque-stock { color: var(--vert); }

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.15rem;
  font-size: 0.94rem;
}
.nav a:not(.bouton) { color: var(--encre-douce); text-decoration: none; font-weight: 500; }
.nav a:not(.bouton):hover { color: var(--encre); }
.nav-form { margin: 0; }

/* Menu deroulant du profil. <details> natif : aucun script, aucun piege de
   focus a gerer, et le menu reste ouvrable au clavier. Le panneau est en
   position absolue pour ne pas pousser le reste de la barre. */
/* Barre d'action en tete de chaque section : l'action de la section, et le
   passage vers l'autre. Les deux moities du site doivent se voir depuis
   n'importe quelle page, sans quoi la moitie « recherches » reste ignoree. */
/* Vignette du registre : assez grande pour reconnaitre l'objet dans une
   ligne de tableau, assez petite pour ne pas casser la lecture. */
.vignette-registre {
  width: 56px;
  height: 42px;
  object-fit: cover;
  border-radius: 6px;
  vertical-align: middle;
  margin-right: 0.5rem;
}

/* Les trois portes d'une organisation. Grille souple : trois colonnes sur
   grand ecran, une seule sur telephone, sans point de rupture a maintenir. */
.portes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}
.porte {
  display: block;
  padding: 1.1rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--rayon);
  text-decoration: none;
  color: inherit;
}
a.porte:hover { border-color: var(--vert); }
.porte h2 { margin: 0 0 0.4rem; font-size: 1.02rem; }
.porte-chiffre {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 600;
  line-height: 1.1;
  color: var(--vert-fonce);
}
.porte p { margin: 0.2rem 0 0; }
/* Porte visible mais non franchissable : le registre existe, il est reserve
   aux membres. Le dire vaut mieux que le cacher, c'est une raison d'adherer. */
.porte-fermee { background: var(--papier); }
.porte-fermee .porte-chiffre { color: var(--encre-douce); }

.fiche-organisation {
  padding: 1.1rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--rayon);
}
.fiche-organisation h3 { margin: 0 0 0.2rem; }
.liens-organisation {
  list-style: none;
  margin: 0.6rem 0;
  padding: 0;
  display: grid;
  gap: 0.3rem;
}

.barre-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin: 1rem 0 0;
}

.menu { position: relative; }
.menu > summary {
  cursor: pointer;
  list-style: none;
  color: var(--encre-douce);
  font-weight: 500;
}
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary::after { content: " \25BE"; }
.menu > summary:hover { color: var(--encre); }
.menu-panneau {
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  z-index: 20;
  min-width: 12rem;
  display: grid;
  gap: 0.15rem;
  padding: 0.5rem;
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--rayon);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.menu-panneau a,
.menu-panneau button {
  display: block;
  width: 100%;
  padding: 0.4rem 0.5rem;
  text-align: left;
  border-radius: var(--rayon);
}
.menu-panneau a:hover,
.menu-panneau button:hover { background: var(--papier); }

/* Sur petit ecran la barre passe a la ligne : un panneau flottant y devient
   plus genant qu'utile, il se deroule donc dans le flux. */
@media (max-width: 40rem) {
  .menu-panneau { position: static; box-shadow: none; }
}

.pastille {
  display: inline-block;
  min-width: 1.5em;
  padding: 0.05em 0.4em;
  background: var(--vert-fonce);
  color: #fff;
  border-radius: var(--pilule);
  font-size: 0.76rem;
  font-weight: 600;
  text-align: center;
}

/* ---------- Boutons ---------- */

.bouton {
  display: inline-block;
  padding: 0.62rem 1.25rem;
  border: 0;
  border-radius: var(--pilule);
  background: var(--surface);
  color: var(--vert-fonce);
  font: inherit;
  font-size: 0.94rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 120ms ease;
}
.bouton:hover { background: var(--vert-pale); color: var(--vert-encre); }

.bouton-primaire { background: var(--vert-fonce); color: #fff; }
.bouton-primaire:hover { background: var(--vert-tres-fonce); color: #fff; }

/* Deux environnements, deux teintes. Donner est vert, comme le reste du
   site ; chercher prend le sable, deja present dans la palette. La couleur
   n'est jamais seule a porter l'information : chaque section garde son titre
   et son libelle, faute de quoi elle ne dirait rien a qui ne la distingue
   pas. */
.bouton-don { background: var(--vert-fonce); color: #fff; }
.bouton-don:hover { background: var(--vert-tres-fonce); color: #fff; }
/* Le bouton de recherche est pastel : publier une recherche est un geste
   secondaire, il ne doit pas rivaliser visuellement avec le don, qui est ce
   que le site cherche a provoquer. */
.bouton-recherche {
  background: var(--sable);
  color: var(--sable-encre);
  border: 1px solid #e6d2c0;
}
.bouton-recherche:hover { background: #efdac9; color: var(--sable-encre); }

.nav-don { box-shadow: inset 0 -2px 0 var(--vert); }
.nav-recherche { box-shadow: inset 0 -2px 0 var(--sable-encre); }

/* Sur les pages d'une section, la teinte passe aux elements principaux :
   liseré de tete, boutons primaires, onglets actifs. */
.env-don { --accent: var(--vert-fonce); --accent-fort: var(--vert-tres-fonce); }
.env-recherche { --accent: var(--sable-encre); --accent-fort: #4a2e15; }

.menu-trait {
  margin: 0.35rem 0;
  border: 0;
  border-top: 1px solid var(--trait);
}

.env-don .bouton-primaire,
.env-recherche .bouton-primaire { background: var(--accent); }
.env-don .bouton-primaire:hover,
.env-recherche .bouton-primaire:hover { background: var(--accent-fort); }

.env-don .categories a.actif,
.env-recherche .categories a.actif { border-color: var(--accent); }

.env-don main::before,
.env-recherche main::before {
  content: "";
  display: block;
  height: 3px;
  margin-bottom: 1.25rem;
  border-radius: 2px;
  background: var(--accent);
}

.bouton-danger { background: var(--rouge); color: #fff; }
.bouton-danger:hover { background: #8e3733; color: #fff; }

.bouton-large { display: block; width: 100%; text-align: center; }

.lien-bouton {
  padding: 0;
  border: 0;
  background: none;
  color: var(--encre-douce);
  font: inherit;
  font-size: 0.94rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
}
.lien-bouton:hover { color: var(--encre); text-decoration: underline; }

/* ---------- Alertes ---------- */

.alertes { list-style: none; margin: 1rem 0 0; padding: 0; }
.alerte {
  padding: 0.85rem 1.1rem;
  margin-bottom: 0.5rem;
  background: var(--vert-pale);
  color: var(--vert-encre);
  border-radius: var(--rayon);
  font-size: 0.95rem;
}
.alerte-error, .alerte-warning {
  background: var(--rouge-pale);
  color: var(--rouge-encre);
}

/* ---------- Accroche ---------- */

.accroche { padding: 2rem 0 1.25rem; max-width: 36rem; }
.accroche h1 {
  font-size: clamp(1.9rem, 5.5vw, 2.7rem);
  font-weight: 700;
  letter-spacing: -0.035em;
}
.accroche p { color: var(--encre-douce); max-width: 52ch; font-size: 1.05rem; }

/* ---------- Recherche et categories ---------- */

.recherche {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem;
  padding: 1.1rem 1.25rem;
  margin: 1rem 0 1.5rem;
  background: var(--surface);
  border-radius: var(--rayon-grand);
}
.recherche-champ { display: flex; flex-direction: column; gap: 0.3rem; flex: 1 1 10rem; }
.recherche-champ span {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--encre-tres-douce);
}
.recherche input, .recherche select { background: var(--surface-creuse); }

.categories, .sous-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.25rem 0 0.75rem;
  font-size: 0.9rem;
}
.categories a, .sous-categories a {
  color: var(--encre-douce);
  text-decoration: none;
  padding: 0.45rem 0.95rem;
  background: var(--surface);
  border-radius: var(--pilule);
  font-weight: 500;
  transition: background 120ms ease;
}
.categories a:hover, .sous-categories a:hover {
  background: var(--vert-pale);
  color: var(--vert-encre);
}
.categories .actif, .sous-categories .actif {
  background: var(--vert-fonce);
  color: #fff;
}
.categories .actif:hover, .sous-categories .actif:hover {
  background: var(--vert-tres-fonce);
  color: #fff;
}
.sous-categories { font-size: 0.86rem; padding-top: 0; }
.sous-categories a { background: var(--surface-creuse); padding: 0.35rem 0.8rem; }

.titre-section { margin-top: 1.5rem; }

/* ---------- Grille d'annonces ---------- */

.grille {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
  gap: var(--gouttiere);
  margin: 1.5rem 0 2.5rem;
}

/* La teinte tourne sur six valeurs : les cartes voisines ne se ressemblent
   jamais, et rien n'est a calculer cote gabarit. */
.grille > *:nth-child(6n+2) { --teinte: var(--lavande); --teinte-encre: var(--lavande-encre); }
.grille > *:nth-child(6n+3) { --teinte: var(--sable); --teinte-encre: var(--sable-encre); }
.grille > *:nth-child(6n+4) { --teinte: #dfe9f2; --teinte-encre: #22415c; }
.grille > *:nth-child(6n+5) { --teinte: #f3e4e7; --teinte-encre: #5b2836; }
.grille > *:nth-child(6n+6) { --teinte: #e8eedc; --teinte-encre: #3f4c21; }

.carte {
  background: var(--surface);
  border-radius: var(--rayon-grand);
  padding: 0.55rem 0.55rem 0.85rem;
  transition: transform 140ms ease;
}
.carte:hover { transform: translateY(-2px); }
.carte-lien { text-decoration: none; color: inherit; display: block; }

.carte-image {
  aspect-ratio: 4 / 3;
  background: var(--teinte);
  border-radius: var(--rayon);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.carte-image img { width: 100%; height: 100%; object-fit: cover; }
.carte-sans-image {
  color: var(--teinte-encre);
  font-size: 0.82rem;
  font-weight: 500;
  opacity: 0.75;
}

.carte-titre {
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 0.8rem 0.4rem 0.55rem;
}
.carte-lien:hover .carte-titre { text-decoration: underline; }

.carte-auteur {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0.4rem 0.4rem;
  font-size: 0.82rem;
  color: var(--encre-tres-douce);
}
.carte-initiales {
  flex: none;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 50%;
  background: var(--teinte);
  color: var(--teinte-encre);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  justify-content: center;
  text-transform: uppercase;
}
.carte-lieu {
  margin: 0 0.4rem;
  font-size: 0.84rem;
  color: var(--encre-douce);
}
.carte-cp { color: var(--encre-tres-douce); }

.carte-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.5rem 0.4rem 0.2rem;
  font-size: 0.78rem;
  color: var(--encre-tres-douce);
}

.puce {
  display: inline-block;
  padding: 0.15rem 0.6rem;
  border-radius: var(--pilule);
  font-size: 0.72rem;
  font-weight: 600;
}
.puce-reparer { background: var(--sable); color: var(--sable-encre); }

/* ---------- Fiche annonce ---------- */

.fil-ariane {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.75rem 0 0.25rem;
  font-size: 0.84rem;
  color: var(--encre-tres-douce);
}
.fil-ariane a { color: var(--encre-tres-douce); text-decoration: none; }
.fil-ariane a:hover { text-decoration: underline; }
.fil-ariane a + a::before { content: "/ "; }

.annonce { display: grid; gap: 2rem; margin-bottom: 2rem; }
@media (min-width: 56rem) {
  .annonce { grid-template-columns: 1.3fr 1fr; align-items: start; }
}

.annonce-visuel { display: grid; gap: 0.75rem; }
.annonce-visuel img {
  width: 100%;
  border-radius: var(--rayon-grand);
  background: var(--surface-creuse);
}

.annonce-corps h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.annonce-faits {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1.25rem;
  margin: 0 0 1.5rem;
  padding: 1.1rem 1.25rem;
  background: var(--surface);
  border-radius: var(--rayon);
  font-size: 0.92rem;
}
.annonce-faits dt { color: var(--encre-tres-douce); }
.annonce-faits dd { margin: 0; font-weight: 500; }

.annonce-description { margin-bottom: 1.5rem; }
.annonce-description p { max-width: 62ch; }

.encart {
  padding: 0.95rem 1.15rem;
  margin-bottom: 1rem;
  background: var(--vert-pale);
  color: var(--vert-encre);
  border-radius: var(--rayon);
}
.encart-attention { background: var(--sable); color: var(--sable-encre); }
.encart a { color: inherit; }

.avis {
  margin-top: 1.25rem;
  font-size: 0.86rem;
  color: var(--encre-tres-douce);
  max-width: 60ch;
}
.discret { color: var(--encre-tres-douce); font-size: 0.86rem; }
.chapo { font-size: 1.08rem; color: var(--encre-douce); max-width: 56ch; }

/* ---------- Formulaires ---------- */

.formulaire { max-width: 34rem; margin-bottom: 2rem; }

.champ { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1.15rem; }
.champ label { font-size: 0.88rem; font-weight: 600; }

input[type="text"], input[type="email"], input[type="password"],
input[type="search"], input[type="url"], input[type="date"],
input[type="tel"], input[type="number"], select, textarea {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 1.5px solid transparent;
  border-radius: var(--rayon);
  background: var(--surface);
  color: var(--encre);
  font: inherit;
  font-size: 0.95rem;
}
textarea { resize: vertical; min-height: 7rem; }
input:focus, select:focus, textarea:focus {
  border-color: var(--vert);
  outline: none;
}
::placeholder { color: var(--encre-tres-douce); opacity: 1; }

input[type="checkbox"] { width: auto; margin-right: 0.45rem; accent-color: var(--vert); }
.champ:has(input[type="checkbox"]) {
  flex-direction: row-reverse;
  justify-content: flex-end;
  align-items: center;
}

.aide { font-size: 0.82rem; color: var(--encre-tres-douce); }
.erreur { font-size: 0.85rem; color: var(--rouge); font-weight: 500; }
.champ-erreur input, .champ-erreur textarea, .champ-erreur select {
  border-color: var(--rouge);
}

fieldset {
  border: 0;
  padding: 1.1rem 1.25rem;
  background: var(--surface);
  border-radius: var(--rayon);
  margin: 0 0 1.5rem;
}
legend {
  padding: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--encre-douce);
}

.miniatures { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.miniature { text-align: center; }
.miniature img { border-radius: var(--rayon); margin-bottom: 0.3rem; }

/* ---------- Depot de photos ---------- */

.depot { margin: -0.5rem 0 1.5rem; }
.depot-liste {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.depot-liste:empty { display: none; }

.depot-element {
  position: relative;
  border-radius: var(--rayon);
  overflow: hidden;
  background: var(--surface-creuse);
  line-height: 0;
}
.depot-element img { width: 120px; height: 90px; object-fit: cover; }

.depot-retrait {
  position: absolute;
  inset: auto 0 0 0;
  padding: 0.3rem;
  border: 0;
  background: rgba(29, 43, 31, 0.78);
  color: #fff;
  font: inherit;
  font-size: 0.74rem;
  font-weight: 500;
  line-height: 1.3;
  text-align: center;
  cursor: pointer;
}
.depot-retrait:hover { background: rgba(29, 43, 31, 0.92); }
.depot-retrait[disabled] { opacity: 0.6; cursor: default; }

.depot-etat { display: block; margin: 0.5rem 0 0; min-height: 1.2em; }
.depot-etat:empty { min-height: 0; }
.depot-erreur { color: var(--rouge); font-weight: 500; }

/* ---------- Tableaux ---------- */

.tableau {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--surface);
  border-radius: var(--rayon-grand);
  overflow: hidden;
  font-size: 0.92rem;
  margin-bottom: 2rem;
}
.tableau th, .tableau td {
  padding: 0.85rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--trait);
  vertical-align: top;
}
.tableau th {
  font-size: 0.78rem;
  color: var(--encre-tres-douce);
  font-weight: 600;
  background: var(--surface-creuse);
  border-bottom: 0;
}
.tableau tr:last-child td { border-bottom: 0; }
.tableau td .discret { display: block; }

.actions { display: flex; flex-wrap: wrap; gap: 0.5rem 0.9rem; align-items: center; }
.actions form { margin: 0; }

.statut { font-size: 0.78rem; font-weight: 600; }
.statut-en_ligne { color: var(--vert); }
.statut-attente, .statut-reservee { color: var(--sable-encre); }
.statut-expiree, .statut-refusee { color: var(--rouge); }
.statut-satisfaite { color: var(--vert); }
.statut-close { color: var(--sable-encre); }
.statut-disponible, .statut-rendu { color: var(--vert); }
.statut-prete, .statut-en_cours, .statut-demande { color: var(--sable-encre); }
.statut-retire, .statut-annule { color: var(--encre-douce); }

/* Cartes de recherche : pas de photo, donc pas de zone d'image, et une
   bordure de gauche qui les distingue au premier coup d'oeil dans une
   grille partagee avec des annonces. */
.carte-demande { border-left: 4px solid var(--vert); }
.carte-demande .carte-titre { margin-top: 0; }
.carte-categorie { margin: 0 0 0.4rem; }

/* ---------- Messagerie ---------- */

.liste-fils { list-style: none; margin: 0 0 2rem; padding: 0; }
.liste-fils li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
  padding: 1rem 1.15rem;
  background: var(--surface);
  border-radius: var(--rayon);
  margin-bottom: 0.6rem;
}
.liste-fils a:not(.bouton) { text-decoration: none; margin-right: auto; color: var(--encre); }
.liste-fils a:hover strong { text-decoration: underline; }

.fil { display: grid; gap: 0.6rem; margin-bottom: 1.5rem; }
.bulle {
  padding: 0.85rem 1.15rem;
  background: var(--surface);
  border-radius: var(--rayon-grand);
  border-bottom-left-radius: 6px;
  max-width: 40rem;
}
.bulle-moi {
  background: var(--vert-pale);
  color: var(--vert-encre);
  margin-left: auto;
  border-bottom-left-radius: var(--rayon-grand);
  border-bottom-right-radius: 6px;
}
.bulle-entete {
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--encre-tres-douce);
}
.bulle-moi .bulle-entete { color: var(--vert-encre); opacity: 0.75; }
.bulle p:last-child { margin-bottom: 0; }

/* ---------- Etat vide et pagination ---------- */

.vide {
  padding: 3.5rem 1.5rem;
  margin: 2rem 0;
  text-align: center;
  background: var(--surface);
  border-radius: var(--rayon-grand);
}
.vide p { color: var(--encre-douce); max-width: 44ch; margin-inline: auto; }

.pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0 2rem;
  font-size: 0.92rem;
}
.pagination a:not(.bouton) {
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1.1rem;
  background: var(--surface);
  border-radius: var(--pilule);
  color: var(--vert-fonce);
}
.pagination a:not(.bouton):hover { background: var(--vert-pale); }
.pagination span { color: var(--encre-tres-douce); }

/* ---------- Pied ---------- */

.pied {
  margin-top: 3rem;
  padding: 2.5rem 0;
  background: var(--surface);
  font-size: 0.88rem;
}
.pied-grille { display: grid; gap: 1.25rem; }
.pied-signature { color: var(--encre-douce); max-width: 46ch; margin: 0; }
.pied nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; }
.pied a:not(.bouton) { color: var(--encre-douce); text-decoration: none; }
.pied a:not(.bouton):hover { color: var(--encre); text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .carte:hover { transform: none; }
}

/* ---------- Bilan de dons ---------- */

.bilan {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  margin-bottom: 1.25rem;
  background: var(--vert-pale);
  color: var(--vert-encre);
  border-radius: var(--rayon);
  font-size: 0.92rem;
}
.bilan strong { font-size: 1.15rem; }

.puce-actif { background: var(--sable); color: var(--sable-encre); }

/* ---------- Organisations ---------- */

.puce-pro { background: var(--lavande); color: var(--lavande-encre); }

.filtres-type {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.5rem;
}
.filtres-type a {
  padding: 0.3rem 0.9rem;
  border: 1px solid var(--trait);
  border-radius: var(--pilule);
  font-size: 0.85rem;
  text-decoration: none;
  color: var(--encre-douce);
}
.filtres-type a.actif {
  background: var(--vert-pale);
  border-color: var(--vert-pale);
  color: var(--vert-encre);
}

.grille-organisations {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  list-style: none;
  padding: 0;
}
.carte-organisation {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1rem;
  background: var(--surface);
  border-radius: var(--rayon);
}
.carte-organisation a { text-decoration: none; color: inherit; }
.carte-organisation img { border-radius: var(--rayon); object-fit: contain; }

.entete-organisation {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.entete-organisation img { border-radius: var(--rayon); object-fit: contain; }
.entete-organisation h1 { margin: 0; }

.liste-demandes,
.liste-membres {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}
.liste-demandes li,
.liste-membres li {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0.6rem 0.9rem;
  background: var(--surface);
  border-radius: var(--rayon);
}

.encadre {
  padding: 1.1rem 1.3rem;
  margin: 1.25rem 0;
  background: var(--surface-creuse);
  border-radius: var(--rayon);
}
.encadre h2 { margin-top: 0; font-size: 1rem; }
.encadre ul { margin-bottom: 0.5rem; }

/* Tableau d'impact des structures.

   Les barres de proportion sont dessinees avec une largeur en pourcentage
   calculee cote serveur : pas de bibliotheque de trace, rien a charger, et
   le tableau reste lisible tel quel quand les styles ne s'appliquent pas. */
.chiffres {
  display: flex;
  flex-wrap: wrap;
  gap: 1.75rem;
  margin: 1.5rem 0 2rem;
}

.chiffres p {
  margin: 0;
  color: var(--encre-douce);
}

.chiffres strong {
  display: block;
  font-size: 1.7rem;
  line-height: 1.2;
  color: var(--vert-encre);
}

.barre {
  width: 38%;
  min-width: 5rem;
}

.barre span {
  display: block;
  height: 0.65rem;
  min-width: 2px;
  background: var(--vert);
  border-radius: 999px;
}

/* Suggestions de commune. Un bloc discret sous le champ, qui n'apparait que
   lorsqu'un code postal couvre plusieurs communes. */
.suggestions-commune {
  margin: 0.4rem 0 0;
  font-size: 0.9rem;
  color: var(--encre-douce);
}

.suggestions-commune .suggestion {
  margin: 0.2rem 0.3rem 0 0;
  padding: 0.2rem 0.6rem;
  border: 0;
  border-radius: 999px;
  background: var(--vert-pale);
  color: var(--vert-encre);
  font: inherit;
  cursor: pointer;
}

.suggestions-commune .suggestion:hover {
  background: var(--vert);
  color: #fff;
}
