/* ==========================================================================
   ONAHA — Office National des Aménagements Hydro-Agricoles (Niger)
   Charte : eau profonde (fleuve Niger), canal, rizière, jeune riz, or de récolte.
   Titres : Archivo (largeur condensée), texte : Public Sans.
   ========================================================================== */

:root {
    /* bleu et vert du logo, orange et vert du drapeau du Niger */
    --eau: #1E3A7B;
    --eau-2: #142A5C;
    --canal: #3B55A9;
    --canal-clair: #E3E8F6;
    --riz: #2F7D32;
    --riz-fonce: #22602A;
    --jeune: #6BB949;
    --jeune-clair: #EAF5E2;
    --niger-orange: #E05206;
    --niger-vert: #0DB02B;
    --or: #E8C468;
    --or-fonce: #A87A12;
    --sol: #C9B98F;
    --papier: #F3F6F2;
    --encre: #10242F;
    --texte: #2A3B44;
    --doux: #5D6F78;
    --trait: #D8E1DC;
    --rouge: #9A4B3C;
    --ombre: 0 18px 40px -26px rgba(30, 58, 123, .45);
    --r: 10px;
    --wrap: 1200px;
    --titres: 'Archivo', 'Arial Narrow', sans-serif;
    --corps: 'Public Sans', system-ui, sans-serif;
    --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 1.0625rem/1.65 var(--corps); color: var(--texte); background: #fff; }
img, svg { display: block; max-width: 100%; }
a { color: var(--eau); text-underline-offset: .18em; }
a:hover { color: var(--canal); }
:focus-visible { outline: 3px solid var(--or); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { font-family: var(--titres); font-stretch: 78%; color: var(--encre); line-height: 1.12; margin: 0 0 .6rem; letter-spacing: -.005em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 2.8vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.22rem; font-weight: 700; font-stretch: 85%; }
p { margin: 0 0 1rem; }
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: .5rem; z-index: 100; background: var(--or); color: var(--encre); padding: .6rem 1rem; border-radius: 6px; font-weight: 700; }
.skip:focus { left: .5rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg.icon, .icon { width: 1.1em; height: 1.1em; flex-shrink: 0; }

/* ---------- Boutons et liens ---------- */
.btn { display: inline-flex; align-items: center; gap: .55rem; padding: .78rem 1.25rem; border-radius: 8px; border: 2px solid transparent; font: 700 .98rem/1.1 var(--corps); text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s; }
.btn svg { width: 18px; height: 18px; }
.btn:active { transform: translateY(1px); }
.btn-riz, .btn-green, .btn-primary { background: var(--riz); color: #fff; }
.btn-riz:hover, .btn-green:hover, .btn-primary:hover { background: var(--riz-fonce); color: #fff; }
.btn-eau { background: var(--eau); color: #fff; }
.btn-eau:hover, .btn-eau[aria-current] { background: var(--canal); color: #fff; }
.btn-clair { background: #fff; color: var(--eau); }
.btn-clair:hover { background: var(--canal-clair); color: var(--eau); }
.btn-ligne, .btn-line { border-color: var(--trait); color: var(--eau); background: #fff; }
.btn-ligne:hover, .btn-line:hover { border-color: var(--eau); color: var(--eau); }
.btn-ligne-clair { border-color: rgba(255, 255, 255, .45); color: #fff; }
.btn-ligne-clair:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .08); }
.pastille { display: inline-grid; place-items: center; min-width: 1.5rem; height: 1.5rem; padding: 0 .4rem; border-radius: 999px; background: var(--or); color: var(--encre); font-size: .8rem; }
.lien { font-weight: 700; }

/* ---------- Bandeau supérieur et en-tête ---------- */
.etat-lisere { display: grid; grid-template-columns: 1fr 1fr 1fr; height: 6px; }
.etat-lisere i:nth-child(1) { background: var(--niger-orange); }
.etat-lisere i:nth-child(2) { background: #fff; position: relative; }
.etat-lisere i:nth-child(2)::after { content: ""; position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; background: var(--niger-orange); }
.etat-lisere i:nth-child(3) { background: var(--niger-vert); }
.topbar { background: var(--eau-2); color: rgba(255, 255, 255, .8); font-size: .84rem; }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 38px; }
.topbar-etat { margin: 0; display: flex; align-items: baseline; gap: .8rem; }
.topbar-etat strong { color: #fff; font-weight: 700; letter-spacing: .02em; }
.topbar-etat span { font-style: italic; color: rgba(255, 255, 255, .72); }
.topbar a { color: inherit; text-decoration: none; display: inline-flex; align-items: center; gap: .35rem; }
.topbar a:hover { color: #fff; }
.topbar svg { width: 15px; height: 15px; }
.topbar-info { display: flex; gap: 1.2rem; align-items: center; }
.topbar-tutelle { padding-right: 1.2rem; border-right: 1px solid rgba(255, 255, 255, .25); }
.site-header { background: #fff; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 104px; }
.brand { display: inline-flex; align-items: center; gap: 1rem; text-decoration: none; color: var(--encre); min-width: 0; }
.brand-logo { height: 76px; width: auto; flex-shrink: 0; }
.brand-text { display: grid; line-height: 1.15; padding-left: 1rem; border-left: 3px solid var(--jeune); }
.brand-text b { font: 800 1.42rem/1.12 var(--titres); font-stretch: 88%; color: var(--eau); max-width: 32ch; hyphens: manual; }
.brand-text small { font-size: .82rem; color: var(--doux); font-weight: 600; margin-top: .3rem; }
.brand-clair .brand-text { border-left-color: var(--jeune); }
.brand-clair .brand-text b { color: #fff; }
.brand-clair .brand-text small { color: rgba(255, 255, 255, .7); }
.brand-clair .brand-logo { background: #fff; border-radius: 50%; padding: 4px; height: 64px; }
.header-actions { display: flex; gap: .7rem; flex-shrink: 0; }

/* barre de menu pleine largeur : toutes les rubriques visibles */
.barre-nav { position: sticky; top: 0; z-index: 50; background: var(--riz); box-shadow: 0 10px 24px -20px rgba(0, 0, 0, .6); border-bottom: 3px solid var(--niger-orange); }
.main-nav > ul { list-style: none; display: flex; align-items: stretch; justify-content: space-between; margin: 0; padding: 0; }
.main-nav > ul > li { position: relative; display: flex; }
.main-nav > ul > li > a, .sub-toggle { display: flex; align-items: center; gap: .35rem; padding: 0 .75rem; min-height: 52px; text-decoration: none; color: #fff; font: 600 .96rem var(--corps); white-space: nowrap; background: none; border: 0; cursor: pointer; }
.main-nav > ul > li > a:hover, .sub-toggle:hover, .has-sub.ouvert > .sub-toggle { background: rgba(0, 0, 0, .14); color: #fff; }
.main-nav > ul > li > a[aria-current="page"], .sub-toggle.actif { background: rgba(0, 0, 0, .18); box-shadow: inset 0 -4px 0 var(--niger-orange); }
.sub-toggle svg { width: 14px; height: 14px; transition: transform .2s; }
.has-sub.ouvert > .sub-toggle svg { transform: rotate(180deg); }
.sub { list-style: none; margin: 0; padding: .4rem; position: absolute; left: 0; top: 100%; min-width: 230px; background: #fff; border-radius: 0 0 6px 6px; border-top: 3px solid var(--niger-orange); box-shadow: 0 24px 40px -20px rgba(0, 0, 0, .45); display: none; z-index: 60; }
.has-sub.ouvert > .sub, .has-sub:hover > .sub, .has-sub:focus-within > .sub { display: block; }
.sub a { display: flex; align-items: center; gap: .6rem; padding: .7rem .8rem; border-radius: 4px; text-decoration: none; color: var(--encre); font-weight: 600; }
.sub a svg { width: 18px; height: 18px; color: var(--riz); }
.sub a:hover, .sub a[aria-current="page"] { background: var(--jeune-clair); color: var(--riz-fonce); }
.nav-toggle { display: none; align-items: center; gap: .4rem; background: var(--riz); color: #fff; border: 0; border-radius: 6px; padding: .55rem .8rem; cursor: pointer; font: 700 .95rem var(--corps); }
.nav-toggle svg { width: 22px; height: 22px; }
.nav-close { display: none; }
.nav-shade { display: none; }

/* ---------- Bandeau « En ce moment » ---------- */
.flashbar { background: var(--papier); border-bottom: 1px solid var(--trait); font-size: .92rem; }
.flashbar .wrap { display: flex; align-items: center; gap: 1rem; min-height: 44px; overflow: hidden; }
.flashbar-label { flex-shrink: 0; font-weight: 700; color: var(--eau); padding-right: 1rem; border-right: 2px solid var(--canal); }
.flashbar-track { overflow: hidden; flex: 1; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.flashbar-move { display: flex; gap: 2.6rem; width: max-content; animation: defile 55s linear infinite; }
.flashbar-track:hover .flashbar-move { animation-play-state: paused; }
.flashbar a { text-decoration: none; color: var(--texte); white-space: nowrap; }
.flashbar a:hover { color: var(--eau); text-decoration: underline; }
.flashbar em { font-style: normal; font-weight: 700; color: var(--riz); margin-right: .5rem; }
@keyframes defile { to { transform: translateX(-50%); } }

/* ---------- Héros : plan parcellaire ---------- */
.hero { position: relative; overflow: hidden; background: var(--sol); min-height: clamp(560px, 78vh, 760px); display: grid; align-items: center; }
.hero-plan { position: absolute; inset: 0; }
.hero-plan svg { width: 100%; height: 100%; }
.hero-plan::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(20, 42, 92, .72) 0%, rgba(20, 42, 92, .28) 48%, rgba(20, 42, 92, 0) 70%); }
.parcelles-hero .p { animation: pousse 1.1s var(--ease) both; animation-delay: calc(var(--i) * 45ms + 150ms); }
@keyframes pousse { from { fill: #C9B98F; opacity: .55; } }
.parcelles-hero .reflet { stroke-dasharray: 60 400; animation: reflet 9s linear infinite; }
@keyframes reflet { to { stroke-dashoffset: -460; } }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 3rem; align-items: center; padding-block: 4rem; }
.hero-plaque { background: var(--eau); color: #fff; padding: clamp(1.6rem, 3.5vw, 2.8rem); border-radius: 4px; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .7); max-width: 40rem; border-left: 6px solid var(--jeune); }
.hero-plaque h1 { color: #fff; font-stretch: 72%; font-size: clamp(2.3rem, 5vw, 4rem); line-height: 1.02; margin-bottom: 1rem; }
.hero-plaque p { color: rgba(255, 255, 255, .86); font-size: 1.12rem; max-width: 34rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.legende { justify-self: end; width: min(100%, 360px); background: rgba(255, 255, 255, .96); border: 1px solid rgba(16, 36, 47, .2); border-radius: 4px; padding: 1.2rem 1.3rem 1rem; box-shadow: 0 24px 50px -30px rgba(0, 0, 0, .6); }
.legende h2 { font-size: 1rem; font-stretch: 100%; font-weight: 800; color: var(--doux); border-bottom: 1px solid var(--trait); padding-bottom: .45rem; margin-bottom: .8rem; letter-spacing: .02em; }
.legende dl { margin: 0; display: grid; gap: .85rem; }
.legende dt { display: flex; align-items: center; gap: .6rem; font: 800 1.55rem/1 var(--titres); font-stretch: 80%; color: var(--encre); }
.legende dd { margin: .15rem 0 0 1.85rem; font-size: .9rem; color: var(--doux); line-height: 1.35; }
.sw { width: 1.2rem; height: 1.2rem; border-radius: 2px; flex-shrink: 0; border: 1px solid rgba(0, 0, 0, .12); }
.sw-riz { background: var(--riz); } .sw-jeune { background: var(--jeune); } .sw-eau { background: var(--canal); } .sw-or { background: var(--or); }
.legende-echelle { display: flex; align-items: center; gap: .5rem; margin: 1rem 0 0; font-size: .76rem; color: var(--doux); }
.legende-echelle span { width: 48px; height: 6px; background: linear-gradient(90deg, var(--encre) 50%, #fff 50%); border: 1px solid var(--encre); }

/* ---------- Sections ---------- */
.section { padding-block: clamp(3.5rem, 7vw, 5.5rem); }
.section-papier { background: var(--papier); }
.section-eau { background: var(--eau); color: rgba(255, 255, 255, .86); }
.section-eau h2 { color: #fff; }
.section-tete { max-width: 46rem; margin-bottom: 2.2rem; }
.section-tete p { color: var(--doux); font-size: 1.08rem; margin: 0; }
.section-eau .section-tete p { color: rgba(255, 255, 255, .78); }
.section-tete-ligne { max-width: none; display: flex; justify-content: space-between; align-items: flex-end; gap: 1.5rem; flex-wrap: wrap; }
.section-tete-ligne > div { max-width: 46rem; }
.empty { padding: 1.4rem 1.5rem; background: var(--papier); border-left: 4px solid var(--canal); border-radius: 4px; color: var(--doux); }
.section-papier .empty { background: #fff; }

/* ---------- Missions ---------- */
.missions { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 3rem; }
.missions li { border-top: 1px solid var(--trait); }
.missions a { display: flex; gap: 1.1rem; padding: 1.35rem 0; text-decoration: none; color: var(--texte); }
.missions a:hover strong { color: var(--canal); }
.missions-ico { width: 46px; height: 46px; border-radius: 50%; background: var(--canal-clair); color: var(--eau); display: grid; place-items: center; flex-shrink: 0; }
.missions-ico svg { width: 22px; height: 22px; }
.missions strong { display: block; font: 700 1.15rem/1.25 var(--titres); font-stretch: 85%; color: var(--encre); margin-bottom: .25rem; transition: color .2s; }
.missions a > span:last-child > span { color: var(--doux); font-size: .97rem; }

/* ---------- Carte ---------- */
.carte { width: 100%; border-radius: 6px; overflow: hidden; background: #cfe1e6; border: 1px solid rgba(255, 255, 255, .2); z-index: 0; }
.carte-legende { list-style: none; display: flex; flex-wrap: wrap; gap: 1.2rem; margin: .8rem 0 0; padding: 0; font-size: .88rem; }
.carte-legende i { display: inline-block; width: .85rem; height: .85rem; border-radius: 50%; margin-right: .35rem; vertical-align: -1px; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, .15); }
.ton-ok { background: var(--riz); } .ton-warn { background: #D99A1E; } .ton-off { background: var(--rouge); }
.carte-sans { padding: 2rem; text-align: center; }
.leaflet-popup-content { font: 400 .92rem/1.45 var(--corps); }
.leaflet-popup-content strong { font-family: var(--titres); font-size: 1.05rem; }
.leaflet-popup-content a { font-weight: 700; }

/* ---------- Production ---------- */
.production-accueil { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 3rem; align-items: center; }
.graphe { margin: 0; position: relative; min-height: 280px; }
.graphe canvas { width: 100% !important; }
.graphe figcaption { font-size: .86rem; color: var(--doux); margin-top: .6rem; }

/* ---------- Appels d'offres ---------- */
.avis-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.avis { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto; gap: 1.3rem; align-items: center; background: #fff; border: 1px solid var(--trait); border-left: 5px solid var(--canal); border-radius: 6px; padding: 1rem 1.2rem; }
.avis-clos { border-left-color: var(--trait); opacity: .85; }
.avis-echeance { text-align: center; border-right: 1px dashed var(--trait); padding-right: 1rem; }
.avis-echeance time { display: block; font-size: .85rem; color: var(--doux); line-height: 1.1; }
.avis-echeance time b { display: block; font: 900 2rem/1 var(--titres); color: var(--eau); }
.avis-echeance small { display: block; margin-top: .3rem; font-weight: 700; font-size: .78rem; color: var(--riz); }
.avis-clos .avis-echeance small { color: var(--doux); }
.avis-info { font-weight: 700; color: var(--doux); }
.avis-type { font-size: .82rem; font-weight: 700; color: var(--canal); }
.avis-corps h3 { margin: .1rem 0 .2rem; font-size: 1.12rem; }
.avis-corps h3 a { color: var(--encre); text-decoration: none; }
.avis-corps h3 a:hover { color: var(--eau); text-decoration: underline; }
.avis-ref { margin: 0; font-size: .86rem; color: var(--doux); }
.avis-dl { display: grid; justify-items: center; gap: .15rem; padding: .6rem .8rem; border-radius: 6px; color: var(--eau); text-decoration: none; font-size: .78rem; font-weight: 700; }
.avis-dl svg { width: 24px; height: 24px; }
.avis-dl:hover { background: var(--canal-clair); }

/* ---------- Projets ---------- */
.projets-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.6rem; }
.projet { display: flex; flex-direction: column; text-decoration: none; color: var(--texte); background: #fff; border: 1px solid var(--trait); border-radius: 6px; overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.projet:hover { border-color: var(--canal); box-shadow: var(--ombre); color: var(--texte); }
.projet-img { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--sol); }
.projet-img img, .projet-img svg { width: 100%; height: 100%; object-fit: cover; }
.etat { position: absolute; left: .8rem; top: .8rem; padding: .3rem .7rem; border-radius: 999px; font-size: .78rem; font-weight: 700; background: #fff; color: var(--encre); }
.etat::before { content: ""; display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; margin-right: .4rem; background: var(--doux); }
.etat-ok::before { background: var(--riz); } .etat-warn::before { background: #D99A1E; } .etat-done::before { background: var(--eau); }
.projet-corps { padding: 1.2rem 1.3rem 1.3rem; display: flex; flex-direction: column; gap: .3rem; flex: 1; }
.projet-cat { font-size: .82rem; font-weight: 700; color: var(--riz); }
.projet-corps h3 { margin: 0; }
.projet-corps p { color: var(--doux); font-size: .95rem; margin: .2rem 0 .4rem; }
.projet-infos { margin: auto 0 0; display: grid; gap: .2rem; font-size: .88rem; border-top: 1px solid var(--trait); padding-top: .7rem; }
.projet-infos div { display: flex; gap: .5rem; }
.projet-infos dt { color: var(--doux); min-width: 6rem; }
.projet-infos dd { margin: 0; font-weight: 600; color: var(--encre); }

/* ---------- Actualités ---------- */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.6rem; }
.post { display: flex; flex-direction: column; text-decoration: none; color: var(--texte); }
.post-img { aspect-ratio: 16 / 10; border-radius: 6px; overflow: hidden; background: var(--sol); }
.post-img img, .post-img svg { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.post:hover .post-img img, .post:hover .post-img svg { transform: scale(1.04); }
.post-body { padding-top: .9rem; }
.post-meta { display: flex; gap: .8rem; font-size: .86rem; color: var(--doux); margin: 0 0 .3rem; }
.post-meta span { color: var(--riz); font-weight: 700; }
.post-body h3 { margin-bottom: .35rem; transition: color .2s; }
.post:hover h3 { color: var(--eau); }
.post-body p:last-child { color: var(--doux); font-size: .96rem; }

/* ---------- Témoignages ---------- */
.temoignages { background: var(--jeune-clair); }
.quotes { position: relative; max-width: 52rem; margin-inline: auto; display: grid; }
.quote { grid-area: 1 / 1; margin: 0; opacity: 0; visibility: hidden; transition: opacity .6s, visibility .6s; }
.quote.on { opacity: 1; visibility: visible; }
.quote blockquote { margin: 0 0 1.4rem; font: 600 clamp(1.25rem, 2.4vw, 1.7rem)/1.4 var(--titres); font-stretch: 88%; color: var(--encre); }
.quote blockquote::before { content: "« "; color: var(--riz); }
.quote blockquote::after { content: " »"; color: var(--riz); }
.quote figcaption { display: flex; align-items: center; gap: .9rem; }
.quote figcaption img, .quote-initiale { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.quote-initiale { display: grid; place-items: center; background: var(--riz); color: #fff; font: 800 1.3rem var(--titres); }
.quote figcaption span { display: grid; color: var(--doux); font-size: .92rem; }
.quote figcaption strong { color: var(--encre); font-size: 1rem; }
.quote-nav { display: flex; gap: .5rem; margin-top: 1.6rem; }
.quote-nav button { width: 30px; height: 6px; border-radius: 3px; border: 0; background: rgba(60, 140, 47, .25); cursor: pointer; padding: 0; }
.quote-nav button.on { background: var(--riz); }

/* ---------- Partenaires ---------- */
.partenaires h2 { font-size: 1.3rem; font-stretch: 90%; color: var(--doux); font-weight: 700; margin-bottom: 1.4rem; }
.partenaires-liste { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); border-top: 1px solid var(--trait); border-left: 1px solid var(--trait); }
.partenaires-liste li { border-right: 1px solid var(--trait); border-bottom: 1px solid var(--trait); min-height: 96px; display: grid; }
.partenaires-liste a, .partenaires-liste li > span, .partenaires-liste li > img { display: grid; place-items: center; padding: 1rem; text-align: center; text-decoration: none; color: var(--eau); font: 700 1rem/1.25 var(--titres); font-stretch: 88%; }
.partenaires-liste img { max-height: 56px; width: auto; margin: auto; filter: grayscale(1); opacity: .8; transition: filter .2s, opacity .2s; }
.partenaires-liste a:hover img { filter: none; opacity: 1; }

/* ---------- En-tête des pages intérieures ---------- */
.page-head { position: relative; overflow: hidden; background: var(--eau); color: rgba(255, 255, 255, .85); padding: 2.6rem 0 2.8rem; }
.page-head-plan { position: absolute; inset: 0 0 0 auto; width: 46%; opacity: .55; mask-image: linear-gradient(90deg, transparent, #000 55%); -webkit-mask-image: linear-gradient(90deg, transparent, #000 55%); }
.page-head-plan svg { width: 100%; height: 100%; }
.page-head .wrap { position: relative; }
.page-head h1 { color: #fff; max-width: 48rem; font-size: clamp(2rem, 4vw, 3rem); margin: .5rem 0 .6rem; }
.page-head p { max-width: 44rem; font-size: 1.1rem; margin: 0; }
.page-head-article h1 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
.crumbs { display: flex; flex-wrap: wrap; gap: .45rem; font-size: .88rem; color: rgba(255, 255, 255, .7); }
.crumbs a { color: rgba(255, 255, 255, .9); text-decoration: none; }
.crumbs a:hover { color: #fff; text-decoration: underline; }

/* ---------- Mise en page de contenu ---------- */
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 3rem; align-items: start; }
.prose { max-width: 46rem; }
.prose p, .prose li { font-size: 1.07rem; }
.prose h2 { margin-top: 2rem; font-size: 1.6rem; }
.chip { display: inline-block; padding: .3rem .75rem; border-radius: 999px; background: var(--canal-clair); color: var(--eau); font-weight: 700; font-size: .85rem; margin-bottom: 1rem; }
.article-img { margin: 0 0 1.6rem; border-radius: 6px; overflow: hidden; }
.side-box { background: var(--papier); border-radius: 6px; padding: 1.3rem 1.4rem; position: sticky; top: 100px; }
.side-box + .side-box { margin-top: 1rem; position: static; }
.side-box h3 { font-size: 1.1rem; margin-bottom: .8rem; }
.side-box ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; }
.side-box li a { display: flex; justify-content: space-between; gap: .6rem; padding: .55rem 0; border-bottom: 1px solid var(--trait); text-decoration: none; color: var(--texte); font-weight: 600; font-size: .95rem; }
.side-box li a:hover { color: var(--eau); }
.side-box li a svg { width: 16px; height: 16px; margin-top: .25rem; color: var(--canal); }
.fiche-dl { display: grid; gap: 0; margin: 0; }
.fiche-dl div { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: .8rem; padding: .6rem 0; border-bottom: 1px solid var(--trait); font-size: .95rem; }
.fiche-dl dt { color: var(--doux); }
.fiche-dl dd { margin: 0; font-weight: 600; color: var(--encre); }

/* ---------- Filtres et onglets ---------- */
.filtres { display: flex; flex-wrap: wrap; gap: .8rem; align-items: flex-end; padding: 1.1rem 1.2rem; background: var(--papier); border-radius: 6px; margin-bottom: 1.8rem; }
.filtres label { display: grid; gap: .3rem; font-size: .85rem; font-weight: 700; color: var(--doux); }
.filtres select, .filtres input { min-width: 170px; height: 44px; padding: 0 .75rem; border: 1px solid var(--trait); border-radius: 6px; font: inherit; font-size: .95rem; background: #fff; color: var(--texte); }
.filtres .btn { height: 44px; padding: 0 1.1rem; }
.filtres-raz { font-size: .9rem; font-weight: 600; align-self: center; }
.onglets { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1.8rem; border-bottom: 2px solid var(--trait); }
.onglets a { padding: .7rem 1rem; text-decoration: none; font-weight: 700; color: var(--doux); margin-bottom: -2px; border-bottom: 3px solid transparent; }
.onglets a:hover { color: var(--eau); }
.onglets a.on { color: var(--eau); border-bottom-color: var(--canal); }
.onglets .nb { display: inline-grid; place-items: center; min-width: 1.5rem; height: 1.5rem; margin-left: .35rem; padding: 0 .4rem; border-radius: 999px; background: var(--papier); font-size: .8rem; }

/* ---------- Aménagements ---------- */
.aha-resume { display: flex; flex-wrap: wrap; gap: 2.4rem; margin: 0 0 1.4rem; }
.aha-resume div { display: grid; }
.aha-resume b { font: 800 1.9rem/1 var(--titres); font-stretch: 80%; color: var(--eau); }
.aha-resume span { font-size: .88rem; color: var(--doux); }
.aha-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.4rem; margin-top: 2rem; }
.aha { display: flex; flex-direction: column; text-decoration: none; color: var(--texte); border: 1px solid var(--trait); border-radius: 6px; overflow: hidden; background: #fff; transition: border-color .2s, box-shadow .2s; }
.aha:hover { border-color: var(--canal); box-shadow: var(--ombre); color: var(--texte); }
.aha-img { position: relative; aspect-ratio: 16 / 9; background: var(--sol); overflow: hidden; }
.aha-img img, .aha-img svg { width: 100%; height: 100%; object-fit: cover; }
.aha-corps { padding: 1rem 1.15rem 1.15rem; display: grid; gap: .35rem; }
.aha-corps h3 { margin: 0; }
.aha-lieu { font-size: .88rem; color: var(--doux); margin: 0; }
.aha-chiffres { display: flex; gap: 1.3rem; margin-top: .4rem; padding-top: .6rem; border-top: 1px solid var(--trait); font-size: .86rem; color: var(--doux); }
.aha-chiffres b { display: block; font: 800 1.15rem/1.1 var(--titres); color: var(--encre); }
.cultures { display: flex; flex-wrap: wrap; gap: .35rem; }
.cultures span { padding: .15rem .55rem; border-radius: 999px; background: var(--jeune-clair); color: var(--riz-fonce); font-size: .8rem; font-weight: 600; }
.regions-barres { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; }
.regions-barres li { display: grid; grid-template-columns: 7rem minmax(0, 1fr) auto; gap: .8rem; align-items: center; font-size: .92rem; }
.regions-barres .barre { height: 12px; background: var(--papier); border-radius: 6px; overflow: hidden; }
.regions-barres .barre i { display: block; height: 100%; background: linear-gradient(90deg, var(--canal), var(--riz)); border-radius: 6px; }
.regions-barres b { font-weight: 700; color: var(--encre); white-space: nowrap; }
.carte-bloc { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 2rem; align-items: start; }
.aha-tete { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 2.5rem; align-items: start; }
.aha-photo { border-radius: 6px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--sol); }
.aha-photo img, .aha-photo svg { width: 100%; height: 100%; object-fit: cover; }
.jauge { margin: 1.2rem 0 0; }
.jauge-txt { display: flex; justify-content: space-between; font-size: .9rem; color: var(--doux); margin-bottom: .35rem; }
.jauge-barre { height: 14px; border-radius: 7px; background: var(--papier); overflow: hidden; border: 1px solid var(--trait); }
.jauge-barre i { display: block; height: 100%; background: repeating-linear-gradient(135deg, var(--riz) 0 10px, #4E9F37 10px 20px); }
.statut { display: inline-flex; align-items: center; gap: .4rem; padding: .25rem .7rem; border-radius: 999px; font-size: .82rem; font-weight: 700; }
.statut::before { content: ""; width: .55rem; height: .55rem; border-radius: 50%; }
.statut-ok { background: var(--jeune-clair); color: var(--riz-fonce); } .statut-ok::before { background: var(--riz); }
.statut-warn { background: #FBF0D5; color: #7A5408; } .statut-warn::before { background: #D99A1E; }
.statut-off { background: #F4E4E0; color: var(--rouge); } .statut-off::before { background: var(--rouge); }
.aha-img .statut { position: absolute; left: .7rem; top: .7rem; }

/* ---------- Production ---------- */
.kpi-ligne { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 3px solid var(--eau); border-bottom: 1px solid var(--trait); margin-bottom: 2.5rem; }
.kpi-ligne div { padding: 1.2rem 1.2rem 1.2rem 0; }
.kpi-ligne div + div { padding-left: 1.2rem; border-left: 1px solid var(--trait); }
.kpi-ligne b { display: block; font: 800 2.1rem/1 var(--titres); font-stretch: 78%; color: var(--encre); }
.kpi-ligne span { font-size: .9rem; color: var(--doux); }
.kpi-ligne em { font-style: normal; font-weight: 700; font-size: .85rem; }
.kpi-ligne .hausse { color: var(--riz); } .kpi-ligne .baisse { color: var(--rouge); }
.graphes-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.5rem; margin-bottom: 3rem; }
.graphes-2 h2, .tableau-titre { font-size: 1.35rem; }
.tableau { width: 100%; border-collapse: collapse; font-size: .95rem; }
.tableau th, .tableau td { text-align: right; padding: .7rem .8rem; border-bottom: 1px solid var(--trait); }
.tableau th:first-child, .tableau td:first-child, .tableau th.g, .tableau td.g { text-align: left; }
.tableau thead th { font-weight: 700; color: var(--doux); border-bottom: 2px solid var(--eau); font-size: .88rem; }
.tableau tbody tr:hover td { background: var(--papier); }
.tableau td.fort { font-weight: 700; color: var(--encre); }
.tableau-defile { overflow-x: auto; }

/* ---------- L'Office ---------- */
.mot-dg { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 2.5rem; align-items: start; }
.mot-dg img, .mot-dg .initiales { width: 220px; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 4px; }
.initiales { display: grid; place-items: center; background: var(--eau); color: #fff; font: 900 3.6rem var(--titres); }
.mot-dg blockquote { margin: 0; font-size: 1.12rem; }
.mot-dg cite { display: block; font-style: normal; margin-top: 1rem; }
.mot-dg cite strong { display: block; color: var(--encre); }
.chrono { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0; position: relative; }
.chrono::before { content: ""; position: absolute; left: 0; right: 0; top: 1.15rem; height: 4px; background: var(--canal); border-radius: 2px; }
.chrono li { position: relative; padding: 2.6rem 1.4rem 0 0; }
.chrono li::before { content: ""; position: absolute; left: 0; top: .6rem; width: 1.2rem; height: 1.2rem; border-radius: 50%; background: #fff; border: 4px solid var(--eau); }
.chrono b { display: block; font: 900 1.8rem/1 var(--titres); color: var(--eau); margin-bottom: .4rem; }
.chrono p { font-size: .95rem; color: var(--texte); margin: 0; }
.organi { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.4rem; }
.organi h3 { font-size: 1.1rem; padding-bottom: .5rem; border-bottom: 3px solid var(--jeune); }
.organi ul { margin: 0; padding-left: 1.1rem; }
.organi li { margin-bottom: .3rem; font-size: .97rem; }
.equipe { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.2rem 2rem; }
.membre { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 1rem; align-items: center; padding: .9rem 0; border-top: 1px solid var(--trait); }
.membre img, .membre .initiales { width: 84px; height: 84px; aspect-ratio: 1; object-fit: cover; border-radius: 50%; font-size: 1.6rem; }
.membre h3 { margin: 0 0 .15rem; font-size: 1.1rem; }
.membre p { margin: 0; color: var(--doux); font-size: .92rem; line-height: 1.4; }
.implantations { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.implantations li { background: #fff; border: 1px solid var(--trait); border-top: 4px solid var(--canal); border-radius: 4px; padding: 1rem 1.1rem; font-size: .93rem; }
.implantations li.siege { border-top-color: var(--riz); }
.implantations h3 { font-size: 1.05rem; margin: .1rem 0 .4rem; }
.implantations .type { font-size: .8rem; font-weight: 700; color: var(--canal); }
.implantations p { margin: 0; color: var(--doux); }
.implantations a { font-weight: 600; }

/* ---------- Documentation ---------- */
.doc-groupe + .doc-groupe { margin-top: 2.6rem; }
.doc-groupe h2 { font-size: 1.4rem; display: flex; align-items: baseline; gap: .6rem; }
.doc-groupe h2 small { font: 600 .9rem var(--corps); color: var(--doux); }
.docs { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--trait); }
.doc { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 1rem; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--trait); }
.doc-ico { width: 48px; height: 56px; border-radius: 4px; background: var(--canal-clair); color: var(--eau); display: grid; place-items: center; font: 800 .72rem var(--titres); position: relative; }
.doc-ico::after { content: ""; position: absolute; right: 0; top: 0; border-width: 0 12px 12px 0; border-style: solid; border-color: #fff #fff var(--canal) var(--canal); }
.doc h3 { margin: 0 0 .15rem; font-size: 1.05rem; font-stretch: 90%; }
.doc p { margin: 0; color: var(--doux); font-size: .92rem; }
.doc .meta { font-size: .84rem; color: var(--doux); }

/* ---------- Services (missions) ---------- */
.svc-liste { display: grid; gap: 0; border-top: 1px solid var(--trait); }
.svc-ligne { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 1.3rem; align-items: start; padding: 1.6rem 0; border-bottom: 1px solid var(--trait); text-decoration: none; color: var(--texte); }
.svc-ligne:hover h2 { color: var(--canal); }
.svc-ligne .missions-ico { width: 56px; height: 56px; }
.svc-ligne h2 { font-size: 1.4rem; margin-bottom: .3rem; transition: color .2s; }
.svc-ligne p { margin: 0; color: var(--doux); max-width: 46rem; }
.svc-ligne > svg { width: 22px; height: 22px; color: var(--canal); margin-top: .5rem; }

/* ---------- Formulaires ---------- */
.contact-grid { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
.contact-cards { list-style: none; margin: 0 0 1.4rem; padding: 0; display: grid; gap: 1rem; }
.contact-cards li { display: flex; gap: 1rem; }
.contact-cards .ico { width: 44px; height: 44px; border-radius: 50%; background: var(--canal-clair); color: var(--eau); display: grid; place-items: center; flex-shrink: 0; }
.contact-cards .ico svg { width: 20px; height: 20px; }
.contact-cards b { display: block; color: var(--encre); }
.map { border-radius: 6px; overflow: hidden; border: 1px solid var(--trait); }
.map iframe { width: 100%; height: 300px; border: 0; display: block; }
.form-box { background: var(--papier); padding: clamp(1.4rem, 3vw, 2.2rem); border-radius: 6px; }
.form-box h2 { font-size: 1.6rem; }
.form { display: grid; gap: 1rem; }
.form .row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.field { display: grid; gap: .35rem; }
.field label, .field .lbl { font-weight: 700; font-size: .92rem; color: var(--encre); }
.field input, .field select, .field textarea { width: 100%; padding: .75rem .85rem; border: 1px solid #c4d1cb; border-radius: 6px; font: inherit; font-size: 1rem; background: #fff; color: var(--texte); }
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--canal); outline: 3px solid rgba(59, 85, 169, .2); }
.field .is-bad, .is-bad { border-color: #c62828 !important; }
.err { color: #b3261e; font-size: .88rem; font-weight: 600; }
.flash { padding: 1rem 1.2rem; border-radius: 6px; background: var(--jeune-clair); color: var(--riz-fonce); border-left: 4px solid var(--riz); font-weight: 600; margin-bottom: 1.4rem; }
.hp { position: absolute; left: -9999px; }

/* ---------- Recrutement (repris du socle commun) ---------- */
.onglets-recrut { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: 2rem; border-bottom: 2px solid var(--trait); }
.onglets-recrut a { display: inline-flex; align-items: center; gap: .5rem; padding: .7rem 1rem; font-weight: 700; text-decoration: none; color: var(--doux); margin-bottom: -2px; border-bottom: 3px solid transparent; }
.onglets-recrut a.on { color: var(--eau); border-bottom-color: var(--canal); }
.onglets-recrut .nb { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--papier); font-size: .8rem; }
.offres { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.6rem; }
.offre { display: flex; flex-direction: column; border: 1px solid var(--trait); border-radius: 6px; overflow: hidden; background: #fff; text-decoration: none; color: inherit; transition: border-color .2s, box-shadow .2s; }
.offre:hover { border-color: var(--canal); box-shadow: var(--ombre); }
.offre-affiche { position: relative; aspect-ratio: 4 / 3; background: var(--canal-clair); overflow: hidden; }
.offre-affiche img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.offre-affiche .vide { width: 100%; height: 100%; display: grid; place-items: center; color: var(--eau); }
.offre-affiche .vide svg { width: 64px; height: 64px; opacity: .5; }
.etat-offre { position: absolute; left: .8rem; top: .8rem; padding: .3rem .7rem; border-radius: 999px; background: var(--riz); color: #fff; font-size: .78rem; font-weight: 700; }
.etat-offre.clos { background: var(--doux); }
.offre-corps { padding: 1.2rem 1.3rem 1.4rem; display: grid; gap: .6rem; flex: 1; }
.offre-corps h3 { margin: 0; }
.offre-corps p { margin: 0; color: var(--doux); }
.offre-infos { display: flex; flex-wrap: wrap; gap: .4rem .9rem; font-size: .88rem; font-weight: 600; }
.offre-infos span { display: inline-flex; align-items: center; gap: .35rem; }
.offre-infos svg { width: 16px; height: 16px; color: var(--riz); }
.offre-lien { margin-top: auto; font-weight: 700; color: var(--eau); display: inline-flex; align-items: center; gap: .4rem; }
.offre-lien svg { width: 18px; height: 18px; }
.recrut-grid { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: 2.5rem; align-items: start; }
.recrut-affiche { position: sticky; top: 110px; display: grid; gap: 1.2rem; }
.recrut-affiche img { width: 100%; border-radius: 6px; box-shadow: var(--ombre); cursor: zoom-in; }
.recrut-desc { background: var(--papier); border-radius: 6px; padding: 1.3rem 1.4rem; }
.recrut-desc h3 { margin: 0 0 .6rem; font-size: 1.05rem; color: var(--eau); }
.recrut-desc ul { margin: .3rem 0 .6rem; padding-left: 1.2rem; }
.recrut-form h2 { margin: 0 0 .4rem; font-size: 1.55rem; }
.recrut-form .sous { margin: 0 0 1.4rem; color: var(--doux); }
.choix-ligne { display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; }
.choix-col { display: grid; gap: .45rem; }
.radio, .field label.radio { display: inline-flex; align-items: center; gap: .55rem; cursor: pointer; font-weight: 500; margin: 0; }
.radio input, .field .radio input { width: 18px; height: 18px; accent-color: var(--riz); margin: 0; padding: 0; }
.depot, .field label.depot { position: relative; display: grid; place-items: center; gap: .3rem; min-height: 170px; padding: 1.2rem; border: 2px dashed #c4d1cb; border-radius: 6px; text-align: center; background: #fff; cursor: pointer; transition: border-color .2s, background .2s; font-weight: 400; margin: 0; }
.depot:hover, .depot.survol, .depot.ok { border-color: var(--riz); background: var(--jeune-clair); }
.depot.ok { border-style: solid; }
.depot.is-bad { border-color: #c62828; }
.depot input, .field .depot input { position: absolute; inset: 0; opacity: 0; cursor: pointer; padding: 0; border: 0; height: 100%; }
.depot svg { width: 34px; height: 34px; color: var(--eau); }
.depot strong { font-size: .92rem; color: var(--encre); }
.depot small { color: var(--doux); font-size: .8rem; }
.depot .nom-fichier { font-weight: 700; color: var(--riz); word-break: break-all; }
.clos-box { padding: 1.6rem; border-radius: 6px; background: var(--papier); text-align: center; }
.clos-box svg { width: 44px; height: 44px; color: var(--doux); margin: 0 auto; }
.clos-box h2 { margin: .5rem 0; font-size: 1.35rem; }

/* ---------- Galerie et visionneuse ---------- */
.galerie-titre { margin-top: 2.6rem; font-size: 1.5rem; display: flex; align-items: baseline; gap: .7rem; }
.galerie-titre small { font: 600 .9rem var(--corps); color: var(--doux); }
.galerie { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: .8rem; }
.galerie-item { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; }
.galerie-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.galerie-item:hover img { transform: scale(1.06); }
.galerie-loupe { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(30, 58, 123, .45); color: #fff; opacity: 0; transition: opacity .3s; }
.galerie-loupe svg { width: 34px; height: 34px; }
.galerie-item:hover .galerie-loupe { opacity: 1; }
.visionneuse { position: fixed; inset: 0; z-index: 200; background: rgba(6, 25, 36, .92); display: none; place-items: center; padding: 3rem 4rem; }
.visionneuse.on { display: grid; }
.visionneuse img { max-height: 85vh; max-width: 100%; border-radius: 4px; }
.visionneuse button { position: absolute; background: rgba(255, 255, 255, .12); color: #fff; border: 0; width: 48px; height: 48px; border-radius: 50%; font-size: 1.8rem; cursor: pointer; }
.visionneuse .fermer { top: 1rem; right: 1rem; }
.visionneuse .prec { left: 1rem; top: 50%; }
.visionneuse .suiv { right: 1rem; top: 50%; }
.visionneuse .compteur { position: absolute; bottom: 1rem; color: #fff; font-weight: 600; }

/* ---------- Pagination ---------- */
.pager { display: flex; justify-content: center; align-items: center; gap: 1rem; margin-top: 2.5rem; }
.pager-item { padding: .6rem 1.1rem; border: 2px solid var(--trait); border-radius: 6px; text-decoration: none; font-weight: 700; color: var(--eau); }
.pager-item:hover { border-color: var(--eau); }
.pager-item.is-off { opacity: .45; }
.pager-info { color: var(--doux); font-size: .92rem; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--eau-2); color: rgba(255, 255, 255, .75); position: relative; }
.foot-canal { height: 10px; background: repeating-linear-gradient(90deg, var(--riz) 0 46px, var(--jeune) 46px 50px, #4E9F37 50px 94px, var(--jeune) 94px 98px); border-top: 4px solid var(--canal); }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr 1.2fr; gap: 2.5rem; padding-block: 3.5rem 2.5rem; }
.site-footer h2 { color: #fff; font-size: 1.1rem; font-stretch: 90%; margin-bottom: 1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; font-size: .94rem; }
.site-footer a { color: rgba(255, 255, 255, .82); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.foot-brand p { margin-top: 1rem; font-size: .94rem; }
.foot-contact li { display: flex; gap: .6rem; }
.foot-contact svg { width: 17px; height: 17px; margin-top: .3rem; color: var(--jeune); }
.foot-bottom { border-top: 1px solid rgba(255, 255, 255, .12); font-size: .86rem; }
.foot-bottom .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .6rem; padding-block: 1.1rem; }
.foot-bottom .credit { margin-left: 1.2rem; color: rgba(255, 255, 255, .6); }
.to-top { position: fixed; right: 1rem; bottom: 1rem; z-index: 40; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--eau); color: #fff; display: grid; place-items: center; cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .3s; }
.to-top svg { width: 20px; height: 20px; transform: rotate(-90deg); }
.to-top.on { opacity: 1; pointer-events: auto; }

/* ---------- Écrans moyens et petits ---------- */
@media (max-width: 1100px) {
    .header-row { min-height: 84px; }
    .brand-logo { height: 60px; }
    .brand-text b { font-size: 1.15rem; }
    .header-actions { display: none; }
    .nav-toggle { display: inline-flex; }
    .barre-nav { position: static; border-bottom-width: 4px; min-height: 0; }
    .barre-nav .wrap { width: auto; }
    .main-nav { position: fixed; top: 0; right: 0; bottom: 0; width: min(340px, 88vw); background: var(--riz); z-index: 70; transform: translateX(100%); transition: transform .3s var(--ease); padding: 4.2rem 0 2rem; overflow-y: auto; }
    .main-nav.open { transform: none; box-shadow: -20px 0 60px -20px rgba(0, 0, 0, .5); }
    .main-nav > ul { flex-direction: column; }
    .main-nav > ul > li { display: block; }
    .main-nav > ul > li > a, .sub-toggle { width: 100%; padding: 0 1.4rem; min-height: 50px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
    .main-nav > ul > li > a[aria-current="page"], .sub-toggle.actif { box-shadow: inset 5px 0 0 var(--niger-orange); }
    .sub { position: static; box-shadow: none; border: 0; border-radius: 0; background: rgba(0, 0, 0, .15); padding: 0; }
    .has-sub:hover > .sub { display: none; }
    .has-sub.ouvert > .sub, .has-sub:focus-within > .sub { display: block; }
    .sub a { color: #fff; padding: .8rem 1.4rem .8rem 2.2rem; border-radius: 0; }
    .sub a svg { color: var(--jeune); }
    .sub a:hover, .sub a[aria-current="page"] { background: rgba(0, 0, 0, .15); color: #fff; }
    .nav-close { display: inline-flex; position: absolute; top: 1rem; right: 1rem; background: rgba(0, 0, 0, .2); }
    .nav-shade.on { display: block; position: fixed; inset: 0; background: rgba(6, 20, 40, .55); z-index: 65; }
}
@media (max-width: 980px) {
    .hero-grid, .production-accueil, .two-col, .carte-bloc, .aha-tete, .recrut-grid, .contact-grid, .mot-dg { grid-template-columns: 1fr; }
    .legende { justify-self: start; }
    .hero-plan::after { background: rgba(20, 42, 92, .45); }
    .side-box, .recrut-affiche { position: static; }
    .foot-grid { grid-template-columns: 1fr 1fr; }
    .graphes-2 { grid-template-columns: 1fr; }
    .kpi-ligne { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .kpi-ligne div:nth-child(3) { padding-left: 0; border-left: 0; }
}
@media (max-width: 720px) {
    body { font-size: 1rem; }
    .topbar-tutelle, .topbar-info a:not([aria-label]) { display: none; }
    .topbar-etat span { display: none; }
    .brand-text small { display: none; }
    .brand-text { padding-left: .7rem; }
    .brand-text b { font-size: 1rem; }
    .brand-logo { height: 52px; }
    .nav-toggle span { display: none; }
    .missions { grid-template-columns: 1fr; }
    .avis { grid-template-columns: 78px minmax(0, 1fr); }
    .avis-dl { grid-column: 2; justify-self: start; display: inline-flex; gap: .4rem; padding: .3rem 0; }
    .form .row { grid-template-columns: 1fr; }
    .foot-grid { grid-template-columns: 1fr; }
    .page-head-plan { width: 100%; opacity: .2; }
    .fiche-dl div { grid-template-columns: 1fr; gap: .1rem; }
    .doc { grid-template-columns: 40px minmax(0, 1fr); }
    .doc > a.btn { grid-column: 2; justify-self: start; }
    .regions-barres li { grid-template-columns: 5.5rem minmax(0, 1fr) auto; }
    .chrono::before { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- Bandeau d'avertissement (site de démonstration) ---------- */
.bandeau-test { background: #FBF0D5; color: #6B4A06; text-align: center; font-size: .86rem; font-weight: 600; padding: .4rem 1rem; border-bottom: 1px solid #EBD6A0; }
.chapo { font-size: 1.18rem; line-height: 1.55; color: var(--encre); font-weight: 500; }
.prose .liste-titre { font-weight: 700; color: var(--encre); margin-bottom: .3rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .3rem; }
.graphe-zone { position: relative; height: 300px; }
.aha-chiffres b { white-space: nowrap; }
.avis-echeance small.avis-publie { color: var(--doux); }
.avis-info-ligne { border-left-color: var(--or); }

/* ---------- Ressources : galeries et vidéos ---------- */
.galeries-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.6rem; }
.galerie-carte { display: block; text-decoration: none; color: var(--texte); }
.galerie-couv { position: relative; aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; background: var(--sol); box-shadow: 10px 10px 0 -2px var(--jeune-clair), 10px 10px 0 0 var(--trait); }
.galerie-couv img, .galerie-couv svg { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.galerie-carte:hover .galerie-couv img, .galerie-carte:hover .galerie-couv svg { transform: scale(1.04); }
.galerie-nb { position: absolute; right: .7rem; bottom: .7rem; display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .7rem; border-radius: 999px; background: rgba(20, 42, 92, .85); color: #fff; font-size: .82rem; font-weight: 700; }
.galerie-nb svg { width: 15px; height: 15px; }
.galerie-txt { padding-top: 1.1rem; }
.galerie-txt h3 { margin-bottom: .2rem; }
.galerie-carte:hover h3 { color: var(--eau); }
.galerie-album { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; margin-top: 1rem; }
.doux { color: var(--doux); }
.videos-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 2rem 1.6rem; }
.video-ecran { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; padding: 0; border-radius: 6px; overflow: hidden; background: var(--eau-2); cursor: pointer; }
.video-ecran img, .video-ecran svg.parcelles { width: 100%; height: 100%; object-fit: cover; }
.video-play { position: absolute; left: 50%; top: 50%; width: 68px; height: 68px; margin: -34px 0 0 -34px; border-radius: 50%; background: var(--niger-orange); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .6); transition: transform .2s; }
.video-play svg { width: 30px; height: 30px; margin-left: 4px; }
.video-ecran:hover .video-play { transform: scale(1.08); }
.video-duree { position: absolute; right: .6rem; bottom: .6rem; padding: .15rem .5rem; border-radius: 4px; background: rgba(0, 0, 0, .75); color: #fff; font-size: .8rem; font-weight: 700; }
.video-attente { cursor: default; }
.video-attente svg.parcelles { filter: saturate(.4) brightness(.75); }
.video-bientot { position: absolute; inset: auto 0 0 0; padding: .7rem 1rem; background: linear-gradient(transparent, rgba(0, 0, 0, .7)); color: #fff; font-weight: 700; }
.video-iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 6px; display: block; background: #000; }
.video-txt { padding-top: .9rem; }
.video-txt h3 { margin-bottom: .25rem; }
.video-txt p { color: var(--doux); font-size: .96rem; margin-bottom: .4rem; }

/* =====================================================================
   Effets et animations (posés par public/js/animations.js)
   ===================================================================== */
@keyframes anim-monte { from { opacity: 0; transform: translate3d(0, 34px, 0); } }
@keyframes anim-gauche { from { opacity: 0; transform: translate3d(-48px, 0, 0); } }
@keyframes anim-droite { from { opacity: 0; transform: translate3d(48px, 0, 0); } }
@keyframes anim-zoom { from { opacity: 0; transform: scale(.94) translate3d(0, 20px, 0); } }
@keyframes anim-trait { from { transform: scaleX(0); } }
@keyframes anim-barre { from { transform: scaleX(0); } }
@keyframes anim-entree { from { opacity: 0; transform: translate3d(0, 26px, 0); } }
@keyframes anim-plaque { from { opacity: 0; transform: translate3d(-60px, 0, 0); clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes anim-legende { from { opacity: 0; transform: translate3d(60px, 0, 0) rotate(2deg); } }
@keyframes anim-flotte { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes anim-respire { 0%, 100% { box-shadow: 0 0 0 0 rgba(224, 82, 6, .55); } 70% { box-shadow: 0 0 0 12px rgba(224, 82, 6, 0); } }
@keyframes anim-derive { from { transform: scale(1.08) translate3d(-1.5%, 0, 0); } to { transform: scale(1.08) translate3d(1.5%, -1%, 0); } }
@keyframes anim-onde { from { transform: translate(-50%, -50%) scale(0); opacity: .45; } to { transform: translate(-50%, -50%) scale(1); opacity: 0; } }
@keyframes anim-brille { from { left: -60%; } to { left: 130%; } }
@keyframes anim-drapeau { from { background-position: 0 0; } to { background-position: 200% 0; } }
@keyframes anim-point { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.6); } }

/* Apparition au défilement : l'animation ne garde pas son état final, les effets de survol restent libres */
.anim-pret .anim { opacity: 0; }
.anim-pret .anim.vu { opacity: 1; animation: anim-monte .85s var(--ease) var(--anim-d, 0s) backwards; }
.anim-pret .anim-gauche.vu { animation-name: anim-gauche; }
.anim-pret .anim-droite.vu { animation-name: anim-droite; }
.anim-pret .anim-zoom.vu { animation-name: anim-zoom; animation-duration: 1s; }

/* Titres de section : trait vert-orange qui se dessine */
.section-tete h2, .partenaires > .wrap > h2, .production-accueil h2 { position: relative; padding-bottom: .55rem; }
.section-tete h2::after, .partenaires > .wrap > h2::after, .production-accueil h2::after {
    content: ""; position: absolute; left: 0; bottom: 0; width: 64px; height: 4px; border-radius: 2px;
    background: linear-gradient(90deg, var(--niger-orange) 0 33%, #fff 33% 40%, var(--niger-vert) 40%); transform-origin: left;
}
.section-eau .section-tete h2::after { background: linear-gradient(90deg, var(--niger-orange) 0 33%, transparent 33% 40%, var(--jeune) 40%); }
.anim-pret .vu h2::after, .anim-pret h2.vu::after { animation: anim-trait .9s var(--ease) calc(var(--anim-d, 0s) + .35s) backwards; }
.section-tete-ligne > div h2::after { display: block; }

/* Héros : plaque, légende et chiffres */
.hero-plan, .page-head-plan { top: -240px; will-change: transform; }
.parcelles-hero { animation: anim-derive 26s ease-in-out infinite alternate; }
.hero-plaque { animation: anim-plaque 1.1s var(--ease) .2s backwards; }
.hero-plaque h1 { animation: anim-entree .9s var(--ease) .55s backwards; }
.hero-plaque p { animation: anim-entree .9s var(--ease) .75s backwards; }
.hero-actions { animation: anim-entree .9s var(--ease) .95s backwards; }
.legende { animation: anim-legende 1.1s var(--ease) .5s backwards; }
.legende .sw { transition: transform .3s; }
.legende dl > div:hover .sw { transform: scale(1.35) rotate(45deg); }
.hero-actions .pastille { animation: anim-respire 2.2s ease-out infinite; }

/* En-têtes de pages intérieures */
.page-head .crumbs { animation: anim-entree .7s var(--ease) .1s backwards; }
.page-head h1 { animation: anim-entree .8s var(--ease) .2s backwards; }
.page-head p { animation: anim-entree .8s var(--ease) .35s backwards; }
.page-head-plan svg { animation: anim-derive 30s ease-in-out infinite alternate; }

/* Liseré aux couleurs du drapeau : lent reflet */
.etat-lisere { position: relative; overflow: hidden; }
.etat-lisere::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent) 0 0 / 50% 100% no-repeat; animation: anim-drapeau 6s linear infinite; }

/* Barre de lecture */
.lecture { position: fixed; left: 0; right: 0; top: 0; height: 4px; z-index: 100; transform-origin: left; transform: scaleX(0); pointer-events: none;
    background: linear-gradient(90deg, var(--niger-orange) 0 33.3%, #fff 33.3% 66.6%, var(--niger-vert) 66.6%); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); }

/* Menu : soulignement orange qui glisse, sous-menu qui se déplie */
.main-nav > ul > li > a, .sub-toggle { position: relative; transition: background .2s, color .2s; }
@media (min-width: 1101px) {
    .main-nav > ul > li > a::after, .sub-toggle::after { content: ""; position: absolute; left: .75rem; right: .75rem; bottom: 8px; height: 2px; background: var(--niger-orange); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
    .main-nav > ul > li > a:hover::after, .sub-toggle:hover::after { transform: scaleX(1); }
    .main-nav > ul > li > a[aria-current="page"]::after, .sub-toggle.actif::after { display: none; }
    .has-sub .sub { transform-origin: top; }
    .has-sub.ouvert .sub { animation: anim-zoom .3s var(--ease); }
    .has-sub .sub a { transition: background .2s, padding-left .25s var(--ease), color .2s; }
    .has-sub .sub a:hover { padding-left: 1.5rem; }
}
.brand-logo { transition: transform .5s var(--ease); }
.brand:hover .brand-logo { transform: rotate(-6deg) scale(1.06); }

/* Boutons : reflet au survol, léger soulèvement, onde au clic */
.btn { position: relative; overflow: hidden; isolation: isolate; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 22px -14px rgba(20, 42, 92, .7); }
.btn:active { transform: translateY(0); }
.btn::before { content: ""; position: absolute; top: 0; left: -60%; width: 45%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .35), transparent); transform: skewX(-20deg); pointer-events: none; z-index: -1; }
.btn:hover::before { animation: anim-brille .75s ease; }
.btn svg { transition: transform .25s var(--ease); }
.btn:hover svg { transform: translateX(3px) scale(1.08); }
.onde { position: absolute; width: 260px; height: 260px; border-radius: 50%; background: currentColor; pointer-events: none; animation: anim-onde .65s ease-out forwards; z-index: -1; }
.lien { background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat; transition: background-size .35s var(--ease); }
.lien:hover { background-size: 100% 2px; }

/* Missions : la ligne glisse, l'icône tourne */
.missions a { transition: transform .3s var(--ease), background .3s; border-radius: 6px; }
.missions a:hover { transform: translateX(8px); background: linear-gradient(90deg, var(--jeune-clair), transparent 85%); }
.missions-ico { transition: transform .5s var(--ease), background .3s, color .3s; }
.missions a:hover .missions-ico { transform: rotate(-8deg) scale(1.12); background: var(--riz); color: #fff; }

/* Cartes : soulèvement, image qui zoome, halo qui suit la souris */
.projet, .aha, .post, .galerie-carte, .video, .avis, .membre, .doc, .partenaires-liste li, .contact-cards > *, .side-box {
    transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s, background .3s;
}
.projet:hover, .aha:hover { transform: translateY(-8px); box-shadow: 0 26px 46px -28px rgba(20, 42, 92, .55); }
.post:hover, .galerie-carte:hover, .video:hover { transform: translateY(-6px); }
.projet-img img, .projet-img svg, .aha-img img, .aha-img svg { transition: transform .8s var(--ease), filter .6s; }
.projet:hover .projet-img img, .projet:hover .projet-img svg, .aha:hover .aha-img img, .aha:hover .aha-img svg, .post:hover .post-img img, .post:hover .post-img svg { transform: scale(1.08); filter: saturate(1.15); }
.projet-img, .aha-img, .post-img, .galerie-couv, .video-ecran { position: relative; }
.projet-img::after, .aha-img::after, .post-img::after, .galerie-couv::after, .video-ecran::after {
    content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s;
    background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .28), transparent 55%);
}
.projet:hover .projet-img::after, .aha:hover .aha-img::after, .post:hover .post-img::after, .galerie-carte:hover .galerie-couv::after, .video-ecran:hover::after { opacity: 1; }
.galerie-couv { transition: box-shadow .4s var(--ease); }
.galerie-carte:hover .galerie-couv { box-shadow: 14px 14px 0 -2px var(--jeune-clair), 14px 14px 0 0 var(--jeune); }
.galerie-item { overflow: hidden; border-radius: 6px; }
.galerie-item:hover img { transform: scale(1.1); }
.video-play { animation: anim-respire 2.4s ease-out infinite; }
.avis:hover { transform: translateX(6px); border-left-color: var(--niger-orange); box-shadow: var(--ombre); }
.avis-echeance time b { transition: color .3s; }
.avis:hover .avis-echeance time b { color: var(--niger-orange); }
.doc:hover { background: linear-gradient(90deg, var(--jeune-clair), transparent 70%); }
.doc-ico { transition: transform .4s var(--ease); }
.doc:hover .doc-ico { transform: translateY(-4px) rotate(-6deg); }
.partenaires-liste li:hover { background: var(--jeune-clair); transform: translateY(-4px); box-shadow: var(--ombre); }
.partenaires-liste img { filter: grayscale(1); opacity: .75; transition: filter .4s, opacity .4s; }
.partenaires-liste li:hover img { filter: none; opacity: 1; }
.membre:hover { transform: translateX(6px); }
.side-box:hover { box-shadow: var(--ombre); }
.statut, .pastille { transition: transform .3s var(--ease); }
.projet:hover .statut, .aha:hover .statut { transform: scale(1.06); }

/* Barres et jauges : remplissage */
.anim-barre { transform-origin: left; }
.anim-pret .anim-barre { transform: scaleX(0); }
.anim-pret .anim-barre.vu { transform: none; transition: transform 1.4s var(--ease) .2s; }

/* Témoignages : la citation entre en douceur */
.quote.on blockquote { animation: anim-entree .8s var(--ease) backwards; }
.quote.on figcaption { animation: anim-entree .8s var(--ease) .15s backwards; }
.quote-initiale { animation: anim-flotte 4s ease-in-out infinite; }

/* Carte : les points apparaissent */
.leaflet-overlay-pane path.leaflet-interactive { transition: stroke-width .2s; }
.leaflet-overlay-pane path.leaflet-interactive:hover { stroke-width: 6; }

/* Champs de formulaire */
.field input, .field select, .field textarea { transition: border-color .25s, box-shadow .25s; }
.field input:focus, .field select:focus, .field textarea:focus { box-shadow: 0 0 0 4px rgba(59, 85, 169, .15); }

/* Pied de page et bouton « haut de page » */
.site-footer a { transition: color .2s, padding-left .25s var(--ease); }
.site-footer ul a:hover { padding-left: .35rem; }
.to-top { transition: opacity .3s, transform .3s var(--ease), background .2s; }
.to-top:hover { transform: translateY(-4px); }
.topbar a { transition: color .2s, opacity .2s; }

@media (prefers-reduced-motion: reduce) {
    .anim-pret .anim, .anim-pret .anim-barre { opacity: 1 !important; transform: none !important; }
    .lecture { display: none; }
}
