/* ==========================================================
   VEM Saint-Pierre — feuille de style
   Palette tirée du logo (vert île) + basalte réunionnais
   ========================================================== */

:root {
  --vert-nuit: #0b3b24;     /* fonds profonds, pied de page */
  --vert-vem: #1e7a3c;      /* vert du logo */
  --vert-feuille: #3fa35b;  /* survols, accents vivants */
  --vert-plaque: #17643a;   /* plaques numérotées du cimetière */
  --brume: #eef3ec;         /* blanc teinté de vert */
  --blanc: #ffffff;
  --basalte: #1d2420;       /* texte */
  --basalte-doux: #4b5650;
  --laiton: #b48a3c;        /* calligraphie, détails */
  --filet: #d5e0d3;

  --f-titre: "Archivo", system-ui, sans-serif;
  --f-texte: "Archivo", system-ui, sans-serif;
  --f-arabe: "Amiri", "Traditional Arabic", serif;

  /* échelle typographique (quarte augmentée ~1.333) */
  --t-xs: 0.8125rem;
  --t-s: 0.9375rem;
  --t-m: 1.0625rem;
  --t-l: 1.375rem;
  --t-xl: 1.875rem;
  --t-2xl: 2.5rem;
  --t-3xl: clamp(2.2rem, 5.4vw, 4.5rem);

  --gouttiere: clamp(16px, 4vw, 48px);
  --max: 1240px;
  --rayon-s: 6px;
  --rayon-l: 22px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--blanc);
  color: var(--basalte);
  font-family: var(--f-texte);
  font-size: var(--t-m);
  line-height: 1.6;
  font-variation-settings: "wdth" 100;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--vert-vem); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--vert-nuit); }
:focus-visible { outline: 3px solid var(--laiton); outline-offset: 3px; border-radius: 3px; }
::selection { background: var(--vert-vem); color: var(--blanc); }

h1, h2, h3, h4 {
  font-family: var(--f-titre);
  line-height: 1.08;
  margin: 0 0 .5em;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 { font-size: var(--t-3xl); font-weight: 850; font-variation-settings: "wdth" 112; }
h2 { font-size: clamp(1.9rem, 4vw, var(--t-2xl)); font-weight: 800; font-variation-settings: "wdth" 110; }
h3 { font-size: var(--t-l); font-weight: 700; font-variation-settings: "wdth" 104; line-height: 1.2; }
p { margin: 0 0 1em; max-width: 68ch; text-wrap: pretty; }
.arabe { font-family: var(--f-arabe); direction: rtl; unicode-bidi: isolate; }
.conteneur { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gouttiere); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.a-completer { background: #fff4d6; color: #6b4e00; padding: 0 .3em; border-radius: 3px; font-size: .92em; }

/* ---------- Boutons ---------- */
.btn {
  --bg: var(--vert-vem); --fg: var(--blanc);
  display: inline-flex; align-items: center; gap: .6em;
  padding: .85em 1.4em;
  background: var(--bg); color: var(--fg);
  border: 2px solid var(--bg); border-radius: 999px;
  font: 700 var(--t-s)/1 var(--f-titre); font-variation-settings: "wdth" 108;
  text-decoration: none; cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), transform .25s var(--ease);
}
.btn:hover { --bg: var(--vert-nuit); color: var(--fg); transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn--clair { --bg: var(--blanc); --fg: var(--vert-nuit); }
.btn--clair:hover { --bg: var(--brume); --fg: var(--vert-nuit); }
.btn--contour { background: transparent; color: var(--vert-vem); }
.btn--contour:hover { background: var(--vert-vem); color: var(--blanc); }
.btn--contour-clair { background: transparent; color: var(--blanc); border-color: rgba(255,255,255,.6); }
.btn--contour-clair:hover { background: var(--blanc); color: var(--vert-nuit); border-color: var(--blanc); }
.btn svg { width: 1.1em; height: 1.1em; }

/* ==========================================================
   EN-TÊTE ET MENU
   ========================================================== */
.bandeau-info {
  background: var(--vert-nuit); color: #cfe3d4;
  font-size: var(--t-xs);
}
.bandeau-info .conteneur { display: flex; gap: 1.5rem; justify-content: space-between; align-items: center; min-height: 36px; flex-wrap: wrap; }
.bandeau-info a { color: var(--blanc); text-decoration: none; }
.bandeau-info .horaires { display: flex; gap: .5rem; align-items: center; }
.bandeau-info .pastille { width: 8px; height: 8px; border-radius: 50%; background: var(--vert-feuille); box-shadow: 0 0 0 0 rgba(63,163,91,.6); animation: pouls 2.4s infinite; }
.bandeau-info .pastille.ferme { background: #c6a35a; animation: none; }
@keyframes pouls { 70% { box-shadow: 0 0 0 8px rgba(63,163,91,0); } 100% { box-shadow: 0 0 0 0 rgba(63,163,91,0); } }

.entete {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.entete.defile { border-color: var(--filet); box-shadow: 0 6px 24px -18px rgba(11,59,36,.5); }
.entete .conteneur { display: flex; align-items: center; gap: 2rem; min-height: 76px; }
.marque { display: flex; align-items: center; gap: .8rem; text-decoration: none; color: var(--basalte); flex-shrink: 0; }
.marque img { height: 52px; width: auto; transition: transform .5s var(--ease); }
.marque:hover img { transform: rotate(-6deg) scale(1.04); }
.marque span { display: grid; line-height: 1.05; }
.marque b { font: 900 1.05rem var(--f-titre); font-variation-settings: "wdth" 118; letter-spacing: .01em; }
.marque small { font-size: var(--t-xs); color: var(--basalte-doux); }

.nav { margin-left: auto; }
.nav > ul { list-style: none; display: flex; gap: .25rem; margin: 0; padding: 0; align-items: center; }
.nav > ul > li { position: relative; }
.nav a.lien, .nav button.lien {
  display: inline-flex; align-items: center; gap: .35em;
  padding: .6em .8em; border: 0; background: none; cursor: pointer;
  font: 600 var(--t-s) var(--f-titre); font-variation-settings: "wdth" 104;
  color: var(--basalte); text-decoration: none; border-radius: var(--rayon-s);
  position: relative;
}
.nav a.lien::after, .nav button.lien::after {
  content: ""; position: absolute; left: .8em; right: .8em; bottom: .3em; height: 2px;
  background: var(--vert-vem); transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
}
.nav a.lien:hover::after, .nav button.lien:hover::after,
.nav a.lien[aria-current="page"]::after, .nav li.ouvert > button.lien::after { transform: scaleX(1); }
.nav a.lien[aria-current="page"] { color: var(--vert-vem); }
.nav .chevron { width: 10px; height: 10px; transition: transform .3s var(--ease); }
.nav li.ouvert .chevron { transform: rotate(180deg); }

/* Sous-menu en panneau */
.panneau {
  position: absolute; top: calc(100% + 10px); left: 50%;
  width: min(560px, 90vw);
  translate: -50% 0;
  background: var(--blanc); border: 1px solid var(--filet); border-radius: 16px;
  box-shadow: 0 30px 60px -30px rgba(11,59,36,.45);
  padding: .6rem;
  display: grid; grid-template-columns: 1fr 1fr; gap: .25rem;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .25s var(--ease), transform .3s var(--ease), visibility .25s;
}
li.ouvert > .panneau { opacity: 1; visibility: visible; transform: translateY(0); }
.panneau a {
  display: grid; grid-template-columns: 40px 1fr; gap: .1rem .8rem; align-items: center;
  padding: .7rem .8rem; border-radius: 10px; text-decoration: none; color: var(--basalte);
  transition: background .2s;
}
.panneau a:hover { background: var(--brume); }
.panneau .glyphe {
  grid-row: span 2; width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center; background: var(--brume); color: var(--vert-vem);
  font: 700 1.1rem var(--f-arabe);
}
.panneau a:hover .glyphe { background: var(--vert-vem); color: var(--blanc); }
.panneau b { font-weight: 700; font-size: var(--t-s); }
.panneau small { color: var(--basalte-doux); font-size: var(--t-xs); line-height: 1.35; }
.panneau .pied-panneau {
  grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center;
  margin-top: .3rem; padding: .8rem; background: var(--vert-nuit); color: #d8e8dc; border-radius: 10px; font-size: var(--t-xs);
}
.panneau .pied-panneau a { display: inline; padding: 0; color: var(--blanc); font-weight: 700; }
.panneau .pied-panneau a:hover { background: none; text-decoration: underline; }

.entete .btn { padding: .7em 1.15em; }
.burger { display: none; }

@media (max-width: 1060px) {
  .nav, .entete .btn-don-entete { display: none; }
  .burger {
    display: grid; place-items: center; margin-left: auto;
    width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer;
    background: var(--vert-vem); color: var(--blanc);
  }
  .burger span, .burger span::before, .burger span::after {
    display: block; width: 20px; height: 2px; background: currentColor; position: relative; transition: transform .35s var(--ease), background .2s;
  }
  .burger span::before, .burger span::after { content: ""; position: absolute; left: 0; }
  .burger span::before { top: -6px; } .burger span::after { top: 6px; }
  .menu-ouvert .burger span { background: transparent; }
  .menu-ouvert .burger span::before { transform: translateY(6px) rotate(45deg); }
  .menu-ouvert .burger span::after { transform: translateY(-6px) rotate(-45deg); }
}

/* Menu mobile plein écran */
.tiroir {
  position: fixed; inset: 0; z-index: 40;
  background: var(--vert-nuit); color: var(--blanc);
  padding: 160px var(--gouttiere) 40px;
  overflow-y: auto;
  clip-path: circle(0 at calc(100% - 44px) 74px);
  transition: clip-path .7s var(--ease);
  visibility: hidden;
}
.menu-ouvert .tiroir { clip-path: circle(150% at calc(100% - 44px) 74px); visibility: visible; }
.menu-ouvert { overflow: hidden; }
.tiroir ul { list-style: none; margin: 0; padding: 0; }
.tiroir > ul > li { border-bottom: 1px solid rgba(255,255,255,.12); }
.tiroir > ul > li > a {
  display: block; padding: .7rem 0; color: var(--blanc); text-decoration: none;
  font: 800 clamp(1.6rem, 7vw, 2.4rem)/1.1 var(--f-titre); font-variation-settings: "wdth" 115;
  opacity: 0; transform: translateY(14px);
  transition: opacity .4s, transform .5s var(--ease), color .2s;
}
.tiroir > ul > li > a:hover { color: #9fd7ae; }
.menu-ouvert .tiroir > ul > li > a { opacity: 1; transform: none; }
.menu-ouvert .tiroir > ul > li:nth-child(2) > a { transition-delay: .05s; }
.menu-ouvert .tiroir > ul > li:nth-child(3) > a { transition-delay: .1s; }
.menu-ouvert .tiroir > ul > li:nth-child(4) > a { transition-delay: .15s; }
.menu-ouvert .tiroir > ul > li:nth-child(5) > a { transition-delay: .2s; }
.menu-ouvert .tiroir > ul > li:nth-child(6) > a { transition-delay: .25s; }
.tiroir .sous { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 0 1rem; }
.tiroir .sous a { color: #cfe3d4; font-size: var(--t-s); padding: .35em .8em; border: 1px solid rgba(255,255,255,.25); border-radius: 999px; text-decoration: none; }
.tiroir .tiroir-pied { margin-top: 2rem; color: #bcd3c2; font-size: var(--t-s); }

/* ==========================================================
   HÉROS — l'île comme fenêtre
   ========================================================== */
.heros {
  position: relative;
  padding: clamp(2rem, 5vw, 4.5rem) 0 clamp(3rem, 6vw, 6rem);
  overflow: hidden;
}
.heros .conteneur { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(1.5rem, 4vw, 4rem); align-items: center; }
.heros .verset {
  font-size: clamp(1.6rem, 3.2vw, 2.4rem); color: var(--laiton); line-height: 1.7; margin: 0 0 .6rem;
}
.heros h1 { margin-bottom: .4em; }
.heros h1 .ligne { display: block; overflow: hidden; }
.heros h1 .ligne > span { display: block; white-space: nowrap; animation: monte .9s var(--ease) both; }
.heros h1 .ligne:nth-child(2) > span { animation-delay: .08s; }
.heros h1 .ligne:nth-child(3) > span { animation-delay: .16s; }
@keyframes monte { from { transform: translateY(105%); } }
.heros .source { font-size: var(--t-s); color: var(--basalte-doux); margin-bottom: 1.6rem; }
.heros .chapo { font-size: var(--t-l); line-height: 1.5; max-width: 34ch; color: var(--basalte); }
.heros .actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }

.ile {
  position: relative;
  aspect-ratio: 461 / 407;
  width: 100%; max-width: 560px; justify-self: end;
}
.ile .fenetre {
  position: absolute; inset: 0;
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
  animation: ile-apparait 1.6s var(--ease) .2s both;
}
.ile .fenetre img {
  width: 100%; height: 100%; object-fit: cover;
  animation: lent-zoom 24s ease-in-out infinite alternate;
}
.ile .fenetre::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(160deg, rgba(30,122,60,.0) 40%, rgba(11,59,36,.55));
}
.ile .ombre {
  position: absolute; inset: 0; translate: 14px 16px;
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
  background: var(--vert-vem);
  animation: ile-apparait 1.6s var(--ease) .05s both;
}
@keyframes ile-apparait { from { -webkit-mask-size: 0%; mask-size: 0%; opacity: 0; } 30% { opacity: 1; } }
@keyframes lent-zoom { from { transform: scale(1.12) translate(-2%, 1%); } to { transform: scale(1.02) translate(1%, -1%); } }
.ile .repere {
  position: absolute; left: 33%; bottom: 13%;
  display: flex; align-items: center; gap: .5rem;
  background: var(--blanc); color: var(--vert-nuit);
  padding: .45rem .8rem .45rem .5rem; border-radius: 999px;
  font: 700 var(--t-xs) var(--f-titre);
  box-shadow: 0 10px 30px -10px rgba(0,0,0,.4);
  animation: pose .8s var(--ease) 1.4s both;
}
.ile .repere i { width: 12px; height: 12px; border-radius: 50%; background: var(--vert-feuille); box-shadow: 0 0 0 4px rgba(63,163,91,.25); }
@keyframes pose { from { opacity: 0; transform: translateY(12px) scale(.9); } }

/* ==========================================================
   SECTIONS
   ========================================================== */
.section { padding: clamp(3.5rem, 8vw, 7rem) 0; }
.section--brume { background: var(--brume); }
.section--nuit { background: var(--vert-nuit); color: #e3efe6; }
.section--nuit h2, .section--nuit h3 { color: var(--blanc); }
.section--nuit a:not(.btn) { color: #9fd7ae; }
.entete-section { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2rem; align-items: end; margin-bottom: clamp(2rem, 4vw, 3.5rem); }
.entete-section p { color: var(--basalte-doux); font-size: var(--t-l); line-height: 1.5; margin: 0; }
.section--nuit .entete-section p { color: #bcd3c2; }
@media (max-width: 800px) { .entete-section { grid-template-columns: 1fr; } }

/* bande chiffre-clé : une ligne de faits, pas des tuiles */
.faits {
  display: flex; flex-wrap: wrap; gap: 0;
  border-top: 2px solid var(--basalte); border-bottom: 1px solid var(--filet);
}
.faits > div { flex: 1 1 200px; padding: 1.4rem 1.4rem 1.4rem 0; }
.faits > div + div { padding-left: 1.4rem; border-left: 1px solid var(--filet); }
.faits b { display: block; font: 850 2.2rem/1 var(--f-titre); font-variation-settings: "wdth" 120; color: var(--vert-vem); margin-bottom: .35rem; }
.faits span { font-size: var(--t-s); color: var(--basalte-doux); }
@media (max-width: 640px) { .faits > div + div { padding-left: 0; border-left: 0; border-top: 1px solid var(--filet); } }

/* Missions : liste éditoriale en deux colonnes, pas de cartes identiques */
.missions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(2rem, 5vw, 5rem); }
.mission {
  display: grid; grid-template-columns: 56px 1fr; gap: 1.2rem; padding: 1.8rem 0;
  border-top: 1px solid var(--filet);
}
.mission .ico {
  width: 56px; height: 56px; border-radius: 50%;
  display: grid; place-items: center; background: var(--brume); color: var(--vert-vem);
  transition: background .3s, color .3s, transform .5s var(--ease);
}
.mission:hover .ico { background: var(--vert-vem); color: var(--blanc); transform: rotate(-8deg); }
.mission .ico svg { width: 26px; height: 26px; }
.mission h3 { margin-bottom: .35em; }
.mission p { color: var(--basalte-doux); margin: 0; }
@media (max-width: 800px) { .missions { grid-template-columns: 1fr; } }

/* Bloc kabrestane d'accueil */
.bloc-kabr { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.bloc-kabr figure { margin: 0; position: relative; }
.bloc-kabr figure img { border-radius: var(--rayon-l); aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.bloc-kabr figcaption { font-size: var(--t-xs); color: #a9c3b0; margin-top: .6rem; }
.recherche-rapide { display: flex; gap: .5rem; margin-top: 1.5rem; background: var(--blanc); padding: .4rem; border-radius: 999px; max-width: 520px; }
.recherche-rapide input { flex: 1; min-width: 0; border: 0; background: transparent; padding: .7rem 1rem; font: 500 var(--t-m) var(--f-texte); color: var(--basalte); }
.recherche-rapide input:focus { outline: none; }
.recherche-rapide:focus-within { box-shadow: 0 0 0 3px var(--laiton); }
@media (max-width: 860px) { .bloc-kabr { grid-template-columns: 1fr; } }

/* Plaque : réplique des plaques vertes numérotées du cimetière */
.plaque {
  display: inline-grid; place-items: center;
  min-width: 3.4em; padding: .35em .6em;
  background: var(--vert-plaque); color: var(--blanc);
  border-radius: 4px; border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--vert-plaque), 0 6px 14px -8px rgba(0,0,0,.5);
  font: 800 1rem/1 var(--f-titre); font-variation-settings: "wdth" 85; font-variant-numeric: tabular-nums;
}

/* Fonds de don : rubans horizontaux */
.fonds { display: grid; gap: .6rem; }
.fonds a {
  display: grid; grid-template-columns: 4.5rem 1fr auto; gap: 1.2rem; align-items: center;
  padding: 1.1rem 1.4rem; border-radius: 14px; text-decoration: none; color: var(--basalte);
  background: var(--blanc); border: 1px solid var(--filet);
  transition: background .3s var(--ease), color .3s, padding .4s var(--ease);
}
.fonds a:hover { background: var(--vert-vem); color: var(--blanc); padding-left: 2rem; }
.fonds .ar { font: 700 1.9rem/1 var(--f-arabe); color: var(--laiton); text-align: center; }
.fonds a:hover .ar { color: #f2deb0; }
.fonds b { font: 800 var(--t-l) var(--f-titre); font-variation-settings: "wdth" 108; display: block; }
.fonds small { color: var(--basalte-doux); font-size: var(--t-s); }
.fonds a:hover small { color: #d4eadb; }
.fonds .fleche { width: 22px; height: 22px; transition: transform .3s var(--ease); }
.fonds a:hover .fleche { transform: translateX(4px); }

/* Citation */
.citation { text-align: center; padding: clamp(4rem, 9vw, 8rem) 0; position: relative; overflow: hidden; }
.citation .arabe { font-size: clamp(1.8rem, 4.4vw, 3.4rem); color: var(--vert-vem); line-height: 1.8; display: block; }
.citation blockquote { margin: 1rem auto 0; max-width: 46ch; font: 500 var(--t-l)/1.5 var(--f-texte); }
.citation cite { display: block; margin-top: .8rem; font-style: normal; color: var(--basalte-doux); font-size: var(--t-s); }

/* Galerie défilante (photos du cimetière) */
.galerie { display: flex; gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 1rem; scrollbar-width: thin; scrollbar-color: var(--vert-vem) transparent; }
.galerie figure { flex: 0 0 clamp(240px, 32vw, 420px); margin: 0; scroll-snap-align: start; }
.galerie img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 14px; }
.galerie figcaption { font-size: var(--t-xs); color: var(--basalte-doux); margin-top: .5rem; }

/* Révélation douce (un seul type, pour quelques éléments) */
.revele { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .9s var(--ease); }
.revele.vu { opacity: 1; transform: none; }

/* ==========================================================
   PAGE INTÉRIEURE — titre de page
   ========================================================== */
.titre-page { padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(2rem, 4vw, 3rem); position: relative; overflow: hidden; }
.titre-page .conteneur { position: relative; z-index: 1; }
.titre-page h1 { max-width: 16ch; }
.titre-page p.chapo { font-size: var(--t-l); line-height: 1.5; color: var(--basalte-doux); max-width: 52ch; }
.titre-page .fil { font-size: var(--t-s); color: var(--basalte-doux); margin-bottom: 1.2rem; }
.titre-page .fil a { color: var(--basalte-doux); }
.titre-page .ile-deco {
  position: absolute; right: -6%; top: 50%; translate: 0 -50%;
  width: min(46vw, 520px); aspect-ratio: 461/407;
  background: var(--brume);
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
  z-index: 0;
}
.titre-page .ile-deco .arabe { display: none; }

/* ==========================================================
   PAGE DONS
   ========================================================== */
.onglets-fonds { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.onglets-fonds button {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .7rem 1.1rem; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--filet); background: var(--blanc); color: var(--basalte);
  font: 700 var(--t-s) var(--f-titre); font-variation-settings: "wdth" 104;
  transition: background .25s, color .25s, border-color .25s;
}
.onglets-fonds button .ar { font: 700 1.15rem/1 var(--f-arabe); color: var(--laiton); }
.onglets-fonds button[aria-selected="true"] { background: var(--vert-vem); color: var(--blanc); border-color: var(--vert-vem); }
.onglets-fonds button[aria-selected="true"] .ar { color: #f2deb0; }

.fiche-fonds { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.fiche-fonds[hidden] { display: none; }
.fiche-fonds .grand-ar { font: 700 clamp(3rem, 8vw, 5.5rem)/1 var(--f-arabe); color: var(--laiton); margin-bottom: .8rem; }
.fiche-fonds ul.usage { padding: 0; list-style: none; margin: 1.2rem 0; }
.fiche-fonds ul.usage li { padding: .55rem 0 .55rem 1.8rem; border-bottom: 1px solid var(--filet); position: relative; }
.fiche-fonds ul.usage li::before { content: ""; position: absolute; left: 0; top: 1.05rem; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--vert-vem); }
.fiche-fonds .note { font-size: var(--t-s); color: var(--basalte-doux); background: var(--brume); padding: 1rem 1.2rem; border-radius: 12px; border-left: 3px solid var(--laiton); }
.fiche-fonds { animation: fondu .5s var(--ease); }
@keyframes fondu { from { opacity: 0; transform: translateY(8px); } }

/* Carte RIB */
.rib {
  position: sticky; top: 100px;
  background: var(--vert-nuit); color: var(--blanc);
  border-radius: var(--rayon-l); padding: 1.6rem;
  overflow: hidden; isolation: isolate;
}
.rib::before {
  content: ""; position: absolute; right: -60px; bottom: -70px; width: 260px; aspect-ratio: 461/407; z-index: -1;
  background: rgba(255,255,255,.06);
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
}
.rib .rib-tete { display: flex; justify-content: space-between; align-items: start; gap: 1rem; margin-bottom: 1.4rem; }
.rib .rib-tete b { font: 800 var(--t-l) var(--f-titre); font-variation-settings: "wdth" 110; display: block; }
.rib .rib-tete small { color: #a9c3b0; font-size: var(--t-xs); }
.rib .cadenas { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.1); display: grid; place-items: center; flex-shrink: 0; }
.rib .cadenas svg { width: 18px; height: 18px; }
.rib dl { margin: 0; display: grid; gap: .9rem; }
.rib dt { font-size: var(--t-xs); color: #a9c3b0; margin-bottom: .2rem; }
.rib dd { margin: 0; display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.rib .valeur { font: 600 1.06rem/1.3 var(--f-titre); font-variation-settings: "wdth" 92; font-variant-numeric: tabular-nums; letter-spacing: .02em; word-break: break-word; }
.rib .masque { filter: blur(5px); user-select: none; transition: filter .6s var(--ease); }
.rib.devoile .masque { filter: none; user-select: text; }
.rib .copier {
  flex-shrink: 0; border: 1px solid rgba(255,255,255,.3); background: transparent; color: var(--blanc);
  border-radius: 999px; padding: .35em .8em; font: 600 var(--t-xs) var(--f-texte); cursor: pointer;
  transition: background .2s, color .2s;
}
.rib .copier:hover { background: var(--blanc); color: var(--vert-nuit); }
.rib .copier[disabled] { opacity: .35; cursor: not-allowed; }
.rib .copier.ok { background: var(--vert-feuille); border-color: var(--vert-feuille); color: var(--blanc); }
.rib .libelle { margin-top: 1.2rem; padding: .9rem 1rem; border: 1px dashed rgba(255,255,255,.35); border-radius: 12px; font-size: var(--t-s); }
.rib .libelle code { font: 700 1rem var(--f-titre); color: #f2deb0; }
.rib .rib-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.2rem; }
.rib .verif { margin-top: 1.2rem; font-size: var(--t-xs); color: #a9c3b0; line-height: 1.5; }
@media (max-width: 900px) { .fiche-fonds { grid-template-columns: 1fr; } .rib { position: static; } }

/* Calculateur zakaat */
.calcul { background: var(--blanc); border: 1px solid var(--filet); border-radius: var(--rayon-l); padding: clamp(1.4rem, 3vw, 2.2rem); }
.calcul .ligne { display: grid; grid-template-columns: 1fr 180px; gap: 1rem; align-items: center; padding: .7rem 0; border-bottom: 1px solid var(--filet); }
.calcul label { font-weight: 600; }
.calcul label small { display: block; font-weight: 400; color: var(--basalte-doux); font-size: var(--t-xs); }
.calcul input { width: 100%; padding: .7rem .9rem; border-radius: 10px; border: 1px solid var(--filet); font: 600 var(--t-m) var(--f-texte); text-align: right; font-variant-numeric: tabular-nums; }
.calcul input:focus { outline: none; border-color: var(--vert-vem); box-shadow: 0 0 0 3px rgba(30,122,60,.15); }
.calcul .resultat { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding-top: 1.2rem; flex-wrap: wrap; }
.calcul .resultat b { font: 850 2.4rem/1 var(--f-titre); font-variation-settings: "wdth" 115; color: var(--vert-vem); font-variant-numeric: tabular-nums; }
.calcul .avert { font-size: var(--t-xs); color: var(--basalte-doux); margin-top: 1rem; }
@media (max-width: 560px) { .calcul .ligne { grid-template-columns: 1fr; } }

/* ==========================================================
   PAGE KABRESTANE
   ========================================================== */
.kabr-app { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 1.5rem; align-items: start; }
@media (max-width: 960px) { .kabr-app { grid-template-columns: 1fr; } }
.kabr-recherche { position: sticky; top: 96px; display: grid; gap: 1rem; }
@media (max-width: 960px) { .kabr-recherche { position: static; } }
.champ-recherche { position: relative; }
.champ-recherche svg { position: absolute; left: 1rem; top: 50%; translate: 0 -50%; width: 20px; height: 20px; color: var(--basalte-doux); pointer-events: none; }
.champ-recherche input {
  width: 100%; padding: 1rem 1rem 1rem 2.9rem; border-radius: 14px;
  border: 2px solid var(--filet); background: var(--blanc);
  font: 600 var(--t-m) var(--f-texte); color: var(--basalte);
  transition: border-color .2s, box-shadow .2s;
}
.champ-recherche input:focus { outline: none; border-color: var(--vert-vem); box-shadow: 0 0 0 4px rgba(30,122,60,.12); }
.filtres { display: flex; flex-wrap: wrap; gap: .35rem; }
.filtres button {
  border: 1px solid var(--filet); background: var(--blanc); border-radius: 999px; padding: .35em .85em; cursor: pointer;
  font: 600 var(--t-xs) var(--f-texte); color: var(--basalte);
}
.filtres button[aria-pressed="true"] { background: var(--basalte); color: var(--blanc); border-color: var(--basalte); }
.compteur { font-size: var(--t-xs); color: var(--basalte-doux); }
.resultats { list-style: none; margin: 0; padding: 0; max-height: 58vh; overflow-y: auto; border-top: 1px solid var(--filet); scrollbar-width: thin; }
@media (max-width: 960px) { .resultats { max-height: 320px; } }
.resultats li button {
  width: 100%; display: grid; grid-template-columns: auto 1fr auto; gap: .9rem; align-items: center;
  padding: .75rem .4rem; border: 0; border-bottom: 1px solid var(--filet); background: transparent; cursor: pointer; text-align: left;
  font: inherit; color: inherit; transition: background .2s, padding .3s var(--ease);
}
.resultats li button:hover { background: var(--brume); padding-left: .8rem; }
.resultats li button[aria-current="true"] { background: var(--brume); box-shadow: inset 3px 0 0 var(--vert-vem); }
.resultats .nom { font-weight: 700; line-height: 1.25; }
.resultats .nom mark { background: #fff0c2; color: inherit; border-radius: 2px; }
.resultats .meta { display: block; font-size: var(--t-xs); color: var(--basalte-doux); font-weight: 400; }
.resultats .emplacement { font-size: var(--t-xs); color: var(--vert-vem); font-weight: 700; white-space: nowrap; }
.vide { padding: 1.4rem 0; color: var(--basalte-doux); font-size: var(--t-s); }

.plan-cadre {
  position: relative; background: #f5f8f3; border: 1px solid var(--filet); border-radius: var(--rayon-l);
  overflow: hidden; aspect-ratio: 1000 / 700; min-height: 340px;
  touch-action: none;
}
.plan-cadre svg { width: 100%; height: 100%; display: block; cursor: grab; }
.plan-cadre svg.glisse { cursor: grabbing; }
.plan-outils { position: absolute; right: 12px; top: 12px; display: grid; gap: 6px; z-index: 2; }
.plan-outils button {
  width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--filet); background: var(--blanc); cursor: pointer;
  font: 700 1.2rem var(--f-titre); color: var(--basalte); display: grid; place-items: center;
}
.plan-outils button:hover { background: var(--brume); }
.plan-legende { position: absolute; left: 12px; bottom: 12px; z-index: 2; display: flex; gap: .8rem; flex-wrap: wrap; background: rgba(255,255,255,.9); padding: .45rem .7rem; border-radius: 10px; font-size: var(--t-xs); }
.plan-legende span { display: inline-flex; align-items: center; gap: .35rem; }
.plan-legende i { width: 10px; height: 14px; border-radius: 2px; display: inline-block; }
.demo-badge { position: absolute; left: 12px; top: 12px; z-index: 2; background: #fff4d6; color: #6b4e00; font-size: var(--t-xs); font-weight: 700; padding: .35rem .7rem; border-radius: 999px; }

/* éléments SVG du plan */
.t { fill: #c9d8c6; stroke: #fff; stroke-width: 1; transition: fill .25s; cursor: pointer; }
.t.libre { fill: #ebf0e9; stroke: #d7e1d4; cursor: default; }
.t:hover { fill: var(--vert-feuille); }
.t.trouve { fill: var(--vert-vem); }
.t.cible { fill: var(--laiton); stroke: var(--vert-nuit); stroke-width: 1.5; }
.carre-fond { fill: #e2ebdf; }
.carre-nom { font: 800 22px var(--f-titre); fill: var(--vert-vem); opacity: .55; }
.allee { fill: #fbfcfa; stroke: #dfe7dc; }
.mur { fill: none; stroke: var(--basalte); stroke-width: 6; }
.portail { fill: var(--laiton); }
.etiquette-plan { font: 600 13px var(--f-texte); fill: var(--basalte-doux); }
.chemin { fill: none; stroke: var(--laiton); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 8 8; }
.halo { fill: none; stroke: var(--laiton); stroke-width: 2; animation: halo 1.8s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes halo { from { transform: scale(.6); opacity: 1; } to { transform: scale(2.6); opacity: 0; } }
.arbre { fill: #b9d3b4; opacity: .7; }

/* Fiche défunt */
.fiche-defunt {
  display: grid; grid-template-columns: auto 1fr auto; gap: 1.2rem; align-items: center;
  background: var(--vert-nuit); color: var(--blanc); padding: 1.2rem 1.4rem; border-radius: 16px; margin-top: 1rem;
  animation: fondu .5s var(--ease);
}
.fiche-defunt[hidden] { display: none; }
.fiche-defunt .plaque { font-size: 1.5rem; }
.fiche-defunt b { font: 800 var(--t-l) var(--f-titre); font-variation-settings: "wdth" 106; display: block; }
.fiche-defunt small { color: #bcd3c2; }
.fiche-defunt .dua { font: 400 1.2rem var(--f-arabe); color: #f2deb0; display: block; margin-top: .2rem; }
@media (max-width: 600px) { .fiche-defunt { grid-template-columns: auto 1fr; } .fiche-defunt .btn { grid-column: 1 / -1; justify-content: center; } }

/* Règlement / infos pratiques */
.infos-pratiques { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.infos-pratiques > div { border-top: 2px solid var(--vert-vem); padding-top: 1rem; }
@media (max-width: 800px) { .infos-pratiques { grid-template-columns: 1fr; } }

/* ==========================================================
   PAGE AIDE — démarches + formulaire
   ========================================================== */
.types-aide { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 0; border-top: 1px solid var(--filet); border-left: 1px solid var(--filet); }
.type-aide { padding: 1.6rem; border-right: 1px solid var(--filet); border-bottom: 1px solid var(--filet); background: var(--blanc); }
.type-aide h3 { display: flex; gap: .7rem; align-items: center; }
.type-aide h3 svg { width: 26px; height: 26px; color: var(--vert-vem); flex-shrink: 0; }
.type-aide p { color: var(--basalte-doux); font-size: var(--t-s); }
.type-aide details { margin-top: .8rem; }
.type-aide summary { cursor: pointer; font-weight: 700; font-size: var(--t-s); color: var(--vert-vem); list-style: none; display: inline-flex; gap: .4rem; align-items: center; }
.type-aide summary::-webkit-details-marker { display: none; }
.type-aide summary::before { content: "+"; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid currentColor; font-size: .9rem; line-height: 1; transition: transform .3s var(--ease); }
.type-aide details[open] summary::before { transform: rotate(45deg); }
.type-aide details ul { margin: .7rem 0 0; padding-left: 1.1rem; font-size: var(--t-s); }
.type-aide details li { margin-bottom: .3rem; }

.etapes { counter-reset: e; list-style: none; padding: 0; margin: 0; display: grid; gap: 0; }
.etapes li { counter-increment: e; display: grid; grid-template-columns: 64px 1fr; gap: 1.2rem; padding: 1.4rem 0; border-top: 1px solid rgba(255,255,255,.15); }
.etapes li::before {
  content: counter(e); width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center; border: 2px solid #9fd7ae; color: #9fd7ae;
  font: 800 1.3rem var(--f-titre);
}
.etapes h3 { margin-bottom: .3em; }
.etapes p { margin: 0; color: #bcd3c2; }
.section--brume .etapes li { border-top-color: var(--filet); }
.section--brume .etapes li::before { border-color: var(--vert-vem); color: var(--vert-vem); }
.section--brume .etapes p { color: var(--basalte-doux); }

.form-aide { background: var(--blanc); border: 1px solid var(--filet); border-radius: var(--rayon-l); overflow: hidden; }
.form-progression { display: flex; border-bottom: 1px solid var(--filet); }
.form-progression span {
  flex: 1; padding: 1rem; font: 700 var(--t-xs) var(--f-titre); color: var(--basalte-doux);
  border-bottom: 3px solid transparent; text-align: center; transition: color .3s, border-color .3s;
}
.form-progression span.actif { color: var(--vert-vem); border-color: var(--vert-vem); }
.form-progression span.fait { color: var(--vert-nuit); border-color: var(--vert-feuille); }
@media (max-width: 600px) { .form-progression span { font-size: 0; padding: .6rem; } .form-progression span::first-letter { font-size: var(--t-xs); } }
.form-etape { padding: clamp(1.4rem, 3vw, 2.4rem); display: none; }
.form-etape.actif { display: block; animation: fondu .45s var(--ease); }
.form-etape h3 { margin-bottom: 1.2rem; }
.grille-champs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.2rem; }
.grille-champs .plein { grid-column: 1 / -1; }
@media (max-width: 640px) { .grille-champs { grid-template-columns: 1fr; } }
.champ label, .champ legend { display: block; font-weight: 600; font-size: var(--t-s); margin-bottom: .35rem; }
.champ .aide-champ { font-size: var(--t-xs); color: var(--basalte-doux); margin-top: .3rem; }
.champ input[type="text"], .champ input[type="email"], .champ input[type="tel"], .champ input[type="number"], .champ input[type="date"], .champ select, .champ textarea {
  width: 100%; padding: .75rem .9rem; border: 1px solid #c9d6c6; border-radius: 10px; background: var(--blanc);
  font: 500 var(--t-m) var(--f-texte); color: var(--basalte);
}
.champ textarea { min-height: 130px; resize: vertical; }
.champ input:focus, .champ select:focus, .champ textarea:focus { outline: none; border-color: var(--vert-vem); box-shadow: 0 0 0 3px rgba(30,122,60,.15); }
.champ input:user-invalid, .champ select:user-invalid, .champ textarea:user-invalid { border-color: #b3261e; }
.champ fieldset { border: 0; padding: 0; margin: 0; }
.choix { display: flex; flex-wrap: wrap; gap: .5rem; }
.choix label {
  display: inline-flex; align-items: center; gap: .5rem; margin: 0; cursor: pointer; font-weight: 500;
  padding: .55rem .9rem; border: 1px solid #c9d6c6; border-radius: 999px; transition: background .2s, border-color .2s;
}
.choix input { accent-color: var(--vert-vem); }
.choix label:has(input:checked) { background: var(--brume); border-color: var(--vert-vem); color: var(--vert-nuit); }
.depot {
  border: 2px dashed #c9d6c6; border-radius: 14px; padding: 1.4rem; text-align: center; color: var(--basalte-doux); font-size: var(--t-s);
  transition: border-color .2s, background .2s;
}
.depot:hover, .depot.survol { border-color: var(--vert-vem); background: var(--brume); }
.depot input { display: block; margin: .8rem auto 0; font-size: var(--t-xs); }
.liste-fichiers { list-style: none; padding: 0; margin: .6rem 0 0; font-size: var(--t-xs); text-align: left; }
.form-nav { display: flex; justify-content: space-between; gap: 1rem; padding: 1.2rem clamp(1.4rem, 3vw, 2.4rem); border-top: 1px solid var(--filet); background: #fafcf9; }
.consentement { display: flex; gap: .7rem; align-items: start; font-size: var(--t-s); margin-top: 1rem; }
.consentement input { margin-top: .3rem; accent-color: var(--vert-vem); width: 18px; height: 18px; flex-shrink: 0; }
.erreur-form { color: #b3261e; font-size: var(--t-s); font-weight: 600; margin-top: 1rem; }
.recap { background: var(--brume); border-radius: 14px; padding: 1.2rem 1.4rem; font-size: var(--t-s); }
.recap dl { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1.2rem; margin: 0; }
.recap dt { color: var(--basalte-doux); }
.recap dd { margin: 0; font-weight: 600; }
.confirmation { text-align: center; padding: 3rem 1.5rem; }
.confirmation .coche { width: 72px; height: 72px; margin: 0 auto 1.2rem; border-radius: 50%; background: var(--vert-vem); display: grid; place-items: center; color: var(--blanc); }
.confirmation .coche svg { width: 34px; height: 34px; stroke-dasharray: 40; stroke-dashoffset: 40; animation: trace .6s var(--ease) .2s forwards; }
@keyframes trace { to { stroke-dashoffset: 0; } }

/* ==========================================================
   PAGE ASSOCIATION
   ========================================================== */
.frise { position: relative; padding-left: 2rem; border-left: 2px solid var(--filet); display: grid; gap: 2.2rem; }
.frise > div { position: relative; }
.frise > div::before { content: ""; position: absolute; left: calc(-2rem - 8px); top: .35rem; width: 14px; height: 14px; border-radius: 50%; background: var(--blanc); border: 3px solid var(--vert-vem); }
.frise time { font: 850 1.6rem var(--f-titre); font-variation-settings: "wdth" 118; color: var(--vert-vem); display: block; }
.objets { columns: 2 320px; column-gap: 3rem; padding: 0; list-style: none; margin: 0; }
.objets li { break-inside: avoid; padding: .8rem 0; border-top: 1px solid var(--filet); }
.objets li b { display: block; }
.deux-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.deux-col img { border-radius: var(--rayon-l); width: 100%; aspect-ratio: 4/3; object-fit: cover; }
@media (max-width: 860px) { .deux-col { grid-template-columns: 1fr; } }

/* ==========================================================
   PIED DE PAGE
   ========================================================== */
.pied { background: var(--vert-nuit); color: #cfe3d4; padding: clamp(3rem, 6vw, 5rem) 0 2rem; position: relative; overflow: hidden; }
.pied::before {
  content: ""; position: absolute; right: -80px; top: -40px; width: 420px; aspect-ratio: 461/407;
  background: rgba(255,255,255,.04);
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
}
.pied a { color: var(--blanc); text-decoration: none; }
.pied a:hover { text-decoration: underline; }
.pied .grille { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; position: relative; }
.pied h4 { color: var(--blanc); font-size: var(--t-s); margin-bottom: 1rem; font-variation-settings: "wdth" 108; }
.pied ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .45rem; font-size: var(--t-s); }
.pied .marque-pied img { height: 70px; width: auto; filter: brightness(0) invert(1); opacity: .95; margin-bottom: 1rem; }
.pied .marque-pied p { font-size: var(--t-s); max-width: 34ch; }
.pied .bas { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,.12); margin-top: 3rem; padding-top: 1.4rem; font-size: var(--t-xs); color: #a9c3b0; position: relative; }
@media (max-width: 900px) { .pied .grille { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .pied .grille { grid-template-columns: 1fr; } }

/* ==========================================================
   Accessibilité / mouvement réduit / impression
   ========================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .revele { opacity: 1; transform: none; }
}
@media print {
  .bandeau-info, .entete, .tiroir, .pied, .form-nav, .form-progression, .no-print { display: none !important; }
  .form-etape { display: block !important; }
  body { font-size: 11pt; }
}

@media (max-width: 860px) {
  .heros .conteneur { grid-template-columns: 1fr; }
  .ile { max-width: 380px; justify-self: center; order: -1; }
  .titre-page .ile-deco { opacity: .6; width: 70vw; right: -30%; }
}

/* ==========================================================
   GALERIE
   ========================================================== */
.mosaique { columns: 3 280px; column-gap: 1rem; }
.mosaique figure { break-inside: avoid; margin: 0 0 1.4rem; }
.mosaique button { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 14px; overflow: hidden; }
.mosaique img { width: 100%; height: auto; transition: transform .8s var(--ease), filter .4s; }
.mosaique button:hover img { transform: scale(1.04); }
.mosaique figcaption { margin-top: .6rem; font-size: var(--t-s); line-height: 1.4; }
.mosaique figcaption b { display: block; font-weight: 600; }
.mosaique figcaption span { color: var(--basalte-doux); font-size: var(--t-xs); }
.visionneuse { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.visionneuse::backdrop { background: rgba(8, 30, 19, .94); }
.visionneuse[open] { display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; animation: fondu .35s var(--ease); }
.visionneuse figure { margin: 0; display: grid; justify-items: center; gap: .8rem; padding: 1rem 0; }
.visionneuse img { max-width: 100%; max-height: 82vh; border-radius: 8px; object-fit: contain; }
.visionneuse figcaption { color: #dcebe0; font-size: var(--t-s); text-align: center; }
.visionneuse button { background: rgba(255,255,255,.1); border: 0; color: #fff; cursor: pointer; border-radius: 50%; width: 48px; height: 48px; font-size: 1.8rem; line-height: 1; justify-self: center; }
.visionneuse button:hover { background: rgba(255,255,255,.22); }
.visionneuse .v-fermer { position: fixed; top: 16px; right: 16px; }
@media (max-width: 600px) { .visionneuse[open] { grid-template-columns: 44px 1fr 44px; } .visionneuse button.v-nav { width: 38px; height: 38px; } }

/* Pages libres (gérées dans l'espace gestion) */
.prose { max-width: 72ch; }
.prose h2 { font-size: var(--t-xl); margin-top: 2.4rem; }
.prose h3 { margin-top: 1.8rem; }
.prose ul, .prose ol { padding-left: 1.2rem; }
.prose li { margin-bottom: .4rem; }
.prose img { border-radius: 14px; margin: 1.6rem 0; }
.prose blockquote { margin: 1.6rem 0; padding-left: 1.2rem; border-left: 3px solid var(--laiton); color: var(--basalte-doux); }

/* grille des types d'aide : 3 colonnes, la dernière carte comble la ligne */
.types-aide { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.types-aide .type-aide:last-child:nth-child(3n+2) { grid-column: span 2; }
.types-aide .type-aide:last-child:nth-child(3n+1) { grid-column: span 3; }
@media (max-width: 900px) {
  .types-aide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .types-aide .type-aide:last-child:nth-child(n) { grid-column: auto; }
  .types-aide .type-aide:last-child:nth-child(odd) { grid-column: span 2; }
}
@media (max-width: 600px) { .types-aide { grid-template-columns: 1fr; } .types-aide .type-aide:last-child:nth-child(odd) { grid-column: auto; } }

/* ==========================================================
   CENTRE FUNÉRAIRE
   ========================================================== */
.cf-visuel { margin: 0; position: relative; }
.cf-visuel img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: var(--rayon-l); }
.cf-visuel::before {
  content: ""; position: absolute; left: -28px; bottom: -28px; width: 120px; aspect-ratio: 461/407; z-index: -1;
  background: var(--vert-vem);
  -webkit-mask: url("../img/ile-masque.png") center / contain no-repeat;
          mask: url("../img/ile-masque.png") center / contain no-repeat;
}
.jauge { border-top: 2px solid var(--basalte); padding-top: 1.2rem; }
.jauge-txt { display: flex; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.jauge-txt b { font: 850 clamp(2.2rem, 5vw, 3.4rem)/1 var(--f-titre); font-variation-settings: "wdth" 118; color: var(--vert-vem); font-variant-numeric: tabular-nums; }
.jauge-txt span { color: var(--basalte-doux); }
.jauge-barre { height: 14px; background: var(--brume); border-radius: 999px; margin-top: 1rem; overflow: hidden; }
.jauge-barre i { display: block; height: 100%; width: var(--pc); background: var(--vert-vem); border-radius: inherit; animation: remplit 1.6s var(--ease) .3s both; }
@keyframes remplit { from { width: 0; } }
.usage-liste { list-style: none; padding: 0; margin: 1rem 0 0; }
.usage-liste li { padding: .9rem 0 .9rem 1.8rem; border-top: 1px solid var(--filet); position: relative; }
.usage-liste li::before { content: ""; position: absolute; left: 0; top: 1.35rem; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--vert-vem); }
.chantier { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; position: relative; }
.chantier li { position: relative; }
.chantier figure { margin: 0 0 1rem; }
.chantier img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 14px; }
.chantier time { display: block; font: 850 1.5rem var(--f-titre); font-variation-settings: "wdth" 115; color: var(--vert-vem); padding-top: .8rem; border-top: 2px solid var(--vert-vem); }
.chantier li:last-child time { color: var(--laiton); border-color: var(--laiton); }
.chantier p { color: var(--basalte-doux); margin-top: .3rem; }
@media (max-width: 760px) { .chantier { grid-template-columns: 1fr; } }
.besoins { list-style: none; padding: 0; margin: 1.4rem 0 0; display: grid; gap: 0; }
.besoins li { padding: .75rem 0; border-top: 1px solid rgba(255,255,255,.15); }
.scenarios { display: grid; gap: .6rem; margin-top: 1.2rem; }
.scenarios div { background: rgba(255,255,255,.07); border-radius: 14px; padding: 1rem 1.2rem; }
.scenarios b { display: block; font: 800 var(--t-l) var(--f-titre); color: var(--blanc); font-variation-settings: "wdth" 110; }
.scenarios span { color: #bcd3c2; font-size: var(--t-s); }
