/*
  Feuille de style DGPE — reprise à l'identique de la maquette validée
  (maquette/index.html), puis étendue pour les pages intérieures.
  Elle fait foi pour le design : couleurs du drapeau, polices, bande tricolore.
*/
:root {
  --vert: #009e60;
  --jaune: #fcd116;
  --bleu: #3a75c4;
  --bleu-nuit: #0d2c54;
  --encre: #161616;
  --gris: #666;
  --gris-clair: #f6f6f6;
  --lavande: #eef2fb;
  --blanc: #ffffff;
  --radius: 12px;
  --maxw: 1200px;
  --font-display: 'Archivo', system-ui, sans-serif;
  --font-body: 'Figtree', system-ui, sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-body); color: var(--encre); background: var(--blanc); line-height: 1.6; }
img { max-width: 100%; display: block; }
a { color: var(--bleu-nuit); }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

::selection { background: var(--jaune); color: var(--encre); }

/* Barre de progression de lecture — tricolore, fixée en haut */
.barre-progression {
  position: fixed; top: 0; left: 0; height: 5px; width: 0%; z-index: 300;
  background: linear-gradient(to right, var(--vert) 33%, var(--jaune) 33% 66%, var(--bleu) 66%);
  pointer-events: none;
}

/* Bouton retour en haut */
.haut-page {
  position: fixed; bottom: 22px; right: 22px; z-index: 150;
  width: 46px; height: 46px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--bleu-nuit); color: #fff; font-size: 1.15rem; font-weight: 700;
  box-shadow: 0 8px 22px rgba(13,44,84,.32);
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity .25s ease, transform .25s ease, filter .15s;
}
.haut-page.visible { opacity: 1; transform: none; pointer-events: auto; }
.haut-page:hover { filter: brightness(1.25); }

/* Kicker : petite étiquette au-dessus des titres de section */
.kicker {
  display: block; font-size: .78rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  color: #006d43; /* vert assombri : contraste AA sur blanc et gris clair */
  margin-bottom: 10px;
}

/* Accessibilité : focus visibles + lien d'évitement */
:focus-visible { outline: 3px solid var(--bleu); outline-offset: 2px; border-radius: 2px; }
.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--bleu-nuit); color: #fff; padding: 10px 16px; border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; }

/* ---------- Bande tricolore signature ---------- */
.tricolore { height: 5px; display: flex; }
.tricolore span { flex: 1; }
.tricolore .v { background: var(--vert); }
.tricolore .j { background: var(--jaune); }
.tricolore .b { background: var(--bleu); }

/* ---------- Header ---------- */
.topbar { background: var(--bleu-nuit); color: #fff; font-size: .8rem; padding: 6px 0; }
.topbar .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.topbar a { color: #fff; text-decoration: none; opacity: .85; }
.topbar a:hover { opacity: 1; text-decoration: underline; }

header.site { border-bottom: 1px solid #e5e5e5; background: #fff; position: sticky; top: 0; z-index: 50; transition: box-shadow .25s ease; }
header.site.scrolled { box-shadow: 0 6px 24px rgba(13, 44, 84, .1); }
.brand-row { display: flex; align-items: center; gap: 20px; padding: 16px 0; }
.bloc-marque { display: flex; flex-direction: column; line-height: 1.15; border-left: 4px solid transparent; border-image: linear-gradient(to bottom, var(--vert) 33%, var(--jaune) 33% 66%, var(--bleu) 66%) 1; padding-left: 12px; }
.bloc-marque .rep { font-family: var(--font-display); font-weight: 800; font-size: .95rem; text-transform: uppercase; letter-spacing: .03em; }
.bloc-marque .devise { font-size: .68rem; font-style: italic; color: var(--gris); }
/* Marque DGPE : logo agrandi en tête de ligne, à gauche */
.brand-name { text-align: left; text-decoration: none; display: flex; align-items: center; gap: 16px; }
.brand-logo { width: 76px; height: auto; flex-shrink: 0; transition: transform .25s ease; }
.brand-name:hover .brand-logo { transform: scale(1.06) rotate(-2deg); }
.brand-name .sigle { display: block; font-family: var(--font-display); font-weight: 800; font-size: 1.6rem; line-height: 1.1; color: var(--bleu-nuit); letter-spacing: .01em; }
.brand-name .full { display: block; font-size: .82rem; color: var(--gris); max-width: 360px; }
.bloc-marque { margin-left: auto; }
nav.main { border-top: 1px solid #eee; }
nav.main ul { list-style: none; display: flex; flex-wrap: wrap; }
nav.main a { display: block; padding: 12px 18px; text-decoration: none; font-weight: 600; font-size: .92rem; color: var(--encre); border-bottom: 3px solid transparent; transition: .15s; }
nav.main a:hover, nav.main a.actif { color: var(--bleu-nuit); border-bottom-color: var(--vert); }

/* ---------- Hero ---------- */
.hero { position: relative; background: linear-gradient(135deg, var(--bleu-nuit) 0%, #123a6d 60%, #0e5a45 100%); color: #fff; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 85% 20%, rgba(252,209,22,.14), transparent 45%),
              radial-gradient(circle at 15% 90%, rgba(0,158,96,.18), transparent 40%); }
.hero .container { position: relative; z-index: 2; padding: 84px 24px; max-width: var(--maxw); }
.hero .eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; background: rgba(255,255,255,.12); padding: 6px 14px; border-radius: 99px; margin-bottom: 22px; }
.hero .eyebrow i { width: 10px; height: 10px; border-radius: 50%; background: var(--jaune); display: inline-block; animation: pulse-point 2.2s ease-in-out infinite; }
@keyframes pulse-point {
  0%, 100% { box-shadow: 0 0 0 0 rgba(252, 209, 22, .55); }
  50% { box-shadow: 0 0 0 7px rgba(252, 209, 22, 0); }
}
.hero h1 { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.9rem, 4.4vw, 3.3rem); line-height: 1.12; max-width: 820px; }
.hero h1 em { font-style: normal; color: var(--jaune); }
.hero p.lead { margin-top: 20px; max-width: 640px; font-size: 1.08rem; color: #dfe7f5; }
.hero .cta-row { margin-top: 32px; display: flex; gap: 14px; flex-wrap: wrap; }

/* En-tête plus compact pour les pages intérieures — titre serif institutionnel */
.hero.hero-page .container { padding: 60px 24px; }
.hero.hero-page h1 { font-family: 'Playfair Display', Georgia, serif; font-weight: 700; font-size: clamp(1.8rem, 3.8vw, 2.9rem); line-height: 1.2; }

.btn { display: inline-flex; align-items: center; gap: 8px; padding: 13px 26px; border-radius: 8px; font-weight: 700; text-decoration: none; font-size: .95rem; transition: .15s; border: 2px solid transparent; cursor: pointer; }
.btn::after { content: "→"; transition: transform .2s ease; }
.btn:hover::after { transform: translateX(4px); }
/* variante retour : flèche ← devant, pas de flèche → derrière */
.btn-retour::after { content: none; }
.btn-retour::before { content: "←"; transition: transform .2s ease; }
.btn-retour:hover::before { transform: translateX(-4px); }
.btn-jaune { background: var(--jaune); color: var(--encre); }
.btn-jaune:hover { filter: brightness(1.06); transform: translateY(-2px); }
.btn-ghost { border-color: rgba(255,255,255,.55); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); }
.btn-bleu { background: var(--bleu-nuit); color: #fff; }
.btn-bleu:hover { filter: brightness(1.15); }

/* ---------- Chiffres clés ---------- */
.chiffres { background: var(--lavande); padding: 52px 0; }
/* Sur l'accueil, les cartes chevauchent le bas du hero (effet flottant) */
.chiffres.chevauche { padding: 0 0 52px; }
.chiffres.chevauche .grid { margin-top: -58px; position: relative; z-index: 20; }
.chiffres .grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr)); gap: 24px; }
.chiffre { background: #fff; border-radius: var(--radius); padding: 30px 26px; border-top: 5px solid var(--vert); box-shadow: 0 14px 34px rgba(13,44,84,.12); transition: transform .2s ease, box-shadow .2s ease; }
.chiffre:hover { transform: translateY(-5px); box-shadow: 0 20px 44px rgba(13,44,84,.16); }
.chiffre:nth-child(2) { border-top-color: var(--jaune); }
.chiffre:nth-child(3) { border-top-color: var(--bleu); }
.chiffre:nth-child(4) { border-top-color: var(--bleu-nuit); }
.chiffre .num { font-family: var(--font-display); font-weight: 800; font-size: 2.7rem; color: var(--bleu-nuit); }
.chiffre .lab { font-size: .9rem; color: var(--gris); margin-top: 4px; }

/* Révélations en cascade dans les grilles */
.chiffres .grid > .reveal:nth-child(2), .missions-grid > .reveal:nth-child(2), .actus-grid > .reveal:nth-child(2),
.directions-grid > .reveal:nth-child(2), .demarches-grid > .reveal:nth-child(2), .provinces-grid > .reveal:nth-child(2) { transition-delay: .08s; }
.chiffres .grid > .reveal:nth-child(3), .missions-grid > .reveal:nth-child(3), .actus-grid > .reveal:nth-child(3),
.directions-grid > .reveal:nth-child(3), .demarches-grid > .reveal:nth-child(3), .provinces-grid > .reveal:nth-child(3) { transition-delay: .16s; }
.chiffres .grid > .reveal:nth-child(4), .missions-grid > .reveal:nth-child(4), .actus-grid > .reveal:nth-child(4),
.directions-grid > .reveal:nth-child(4), .demarches-grid > .reveal:nth-child(4), .provinces-grid > .reveal:nth-child(4) { transition-delay: .24s; }
.missions-grid > .reveal:nth-child(5), .demarches-grid > .reveal:nth-child(5), .provinces-grid > .reveal:nth-child(5) { transition-delay: .32s; }
.missions-grid > .reveal:nth-child(6), .provinces-grid > .reveal:nth-child(6) { transition-delay: .4s; }

/* ---------- Sections ---------- */
section.bloc { padding: 76px 0; }
.titre-section { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.5rem, 3vw, 2.2rem); margin-bottom: 14px; position: relative; display: inline-block; padding-bottom: 12px; }
.titre-section::after { content: ""; position: absolute; left: 0; bottom: 0; height: 5px; width: 88px; background: linear-gradient(to right, var(--vert) 33%, var(--jaune) 33% 66%, var(--bleu) 66%); }
.sous-titre { color: var(--gris); max-width: 700px; margin-bottom: 40px; }

/* ---------- Missions ---------- */
.missions-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 22px; }
.mission { background: #fff; border: 1px solid #e8e8e8; border-radius: var(--radius); padding: 26px; transition: .2s; position: relative; overflow: hidden; }
.mission::before { content: ""; position: absolute; top: 0; left: 0; width: 4px; height: 100%; background: var(--vert); transform: scaleY(0); transform-origin: top; transition: .25s; }
.mission:hover { box-shadow: 0 8px 24px rgba(13,44,84,.1); transform: translateY(-3px); }
.mission:hover::before { transform: scaleY(1); }
.mission .ico { width: 46px; height: 46px; border-radius: 10px; background: var(--lavande); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; margin-bottom: 16px; transition: transform .25s ease, background .25s ease; }
.mission:hover .ico { transform: scale(1.14) rotate(-5deg); background: #fdf3c4; }
.mission h3 { font-family: var(--font-display); font-size: 1.02rem; font-weight: 700; margin-bottom: 8px; color: var(--bleu-nuit); }
.mission p { font-size: .9rem; color: var(--gris); }

/* ---------- Direction (style "Les ministres") ---------- */
.dirigeants { background: var(--lavande); }
.carte-dir { background: #fff; border-radius: var(--radius); padding: 34px; display: flex; gap: 32px; flex-wrap: wrap; margin-bottom: 28px; box-shadow: 0 2px 12px rgba(13,44,84,.05); }
.carte-dir .photo { width: 200px; height: 240px; border-radius: 6px; background: linear-gradient(160deg, var(--bleu-nuit), #2a5da8); display: flex; align-items: center; justify-content: center; color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 3rem; flex-shrink: 0; overflow: hidden; }
.carte-dir .photo-reelle { background: var(--gris-clair); }
.carte-dir .photo img { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; }
.carte-dir .infos { flex: 1; min-width: 0; flex-basis: 260px; }
.carte-dir h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; display: inline-block; border-bottom: 3px solid var(--encre); padding-bottom: 4px; margin-bottom: 10px; }
.carte-dir .fonction { font-weight: 700; color: var(--bleu-nuit); margin-bottom: 18px; }
.tags { display: flex; gap: 10px; flex-wrap: wrap; padding-bottom: 18px; border-bottom: 1px solid #e5e5e5; margin-bottom: 18px; }
.tag { display: inline-flex; align-items: center; gap: 6px; background: var(--lavande); color: var(--bleu-nuit); font-weight: 600; font-size: .85rem; padding: 8px 16px; border-radius: 99px; text-decoration: none; transition: .15s; }
.tag:hover { background: #dbe4f7; }
.socials { display: flex; gap: 10px; flex-wrap: wrap; }

/* Organigramme */
.organigramme { max-width: 720px; margin: 0 auto; }
.org-noeud { max-width: 420px; margin: 0 auto; border-radius: var(--radius); padding: 20px; text-align: center; color: #fff; box-shadow: 0 2px 12px rgba(13,44,84,.15); }
.org-noeud.dg { background: var(--bleu-nuit); }
.org-noeud.dga { background: #0e5a45; }
.org-noeud strong { font-family: var(--font-display); display: block; }
.org-noeud span { font-size: .85rem; opacity: .8; }
.org-lien { width: 1px; height: 32px; background: #c9d2e8; margin: 0 auto; }
.org-services { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.org-service { border: 1px solid #e8e8e8; background: #fff; border-radius: var(--radius); padding: 20px; text-align: center; color: var(--encre); }
.org-service strong { font-family: var(--font-display); color: var(--bleu-nuit); }
.org-service span { display: block; font-size: .85rem; color: var(--gris); }

/* ---------- Actualités / cartes ---------- */
.actus-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 22px; }
.actu { border: 1px solid #e8e8e8; border-radius: var(--radius); overflow: hidden; background: #fff; transition: .2s; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.actu:hover { box-shadow: 0 12px 30px rgba(13,44,84,.14); transform: translateY(-4px); }
.actu .visuel { height: 150px; display: flex; align-items: center; justify-content: center; font-size: 2.4rem; background: linear-gradient(135deg, var(--vert), var(--bleu)); transition: transform .35s ease; }
.actu:hover .visuel { transform: scale(1.07); }
.actu .visuel.d-vert-bleu { background: linear-gradient(135deg, var(--vert), var(--bleu)); }
.actu .visuel.d-jaune-vert { background: linear-gradient(135deg, var(--jaune), var(--vert)); }
.actu .visuel.d-bleu-nuit { background: linear-gradient(135deg, var(--bleu), var(--bleu-nuit)); }
.actu .corps { padding: 20px; }
.actu .date { font-size: .78rem; color: var(--gris); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.actu h3 { font-family: var(--font-display); font-size: 1.02rem; font-weight: 700; margin: 8px 0 10px; color: var(--bleu-nuit); }
.actu p { font-size: .88rem; color: var(--gris); }

/* ---------- Article d'actualité ---------- */
.article { max-width: 760px; margin: 0 auto; padding: 0 24px; }
.article-corps { font-size: 1.02rem; line-height: 1.75; }
.article-corps h2 { font-family: var(--font-display); margin: 36px 0 12px; font-size: 1.35rem; color: var(--bleu-nuit); }
.article-corps p { margin-bottom: 16px; }
.article-corps ul { margin: 0 0 16px 24px; }
.badge-cat { display: inline-block; background: rgba(255,255,255,.15); padding: 6px 14px; border-radius: 99px; font-size: .85rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 12px; }

/* ---------- Textes de référence ---------- */
.texte-ref { background: #fff; border: 1px solid #e8e8e8; border-left: 5px solid var(--jaune); border-radius: var(--radius); padding: 22px 26px; margin-bottom: 16px; display: flex; justify-content: space-between; align-items: center; gap: 18px; flex-wrap: wrap; }
.texte-ref strong { font-family: var(--font-display); color: var(--bleu-nuit); }
.texte-ref span { display: block; font-size: .88rem; color: var(--gris); }

/* ---------- Illustration du patrimoine ---------- */
.bloc-illustration { padding-bottom: 40px; }
.illustration-patrimoine { max-width: 760px; margin: 0 auto; }
.illustration-patrimoine img {
  width: 100%; height: auto; border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(13, 44, 84, .18);
  border: 1px solid #e5e5e5;
}
.illustration-patrimoine figcaption {
  margin-top: 14px; text-align: center; font-size: .88rem; color: var(--gris); font-style: italic;
}

/* ---------- Provinces ---------- */
.provinces-grid { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 16px; }
.province { border: 1px solid #e8e8e8; background: #fff; border-radius: var(--radius); padding: 20px; }
.province .nom { font-family: var(--font-display); font-weight: 700; color: var(--bleu-nuit); display: block; }
.province .cl { font-size: .88rem; color: var(--gris); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 1fr 1.2fr; } }
.coord { list-style: none; display: flex; flex-direction: column; gap: 20px; }
.coord li { display: flex; gap: 16px; }
.coord .ico { width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px; background: var(--lavande); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; }
.coord strong { font-family: var(--font-display); color: var(--bleu-nuit); display: block; }
.coord p { color: var(--gris); }
.form-row { display: grid; gap: 16px; }
@media (min-width: 560px) { .form-row.deux { grid-template-columns: 1fr 1fr; } }
.champ { display: flex; flex-direction: column; margin-bottom: 16px; }
.champ label { font-weight: 600; margin-bottom: 4px; }
.champ input, .champ textarea { border: 1px solid #ccc; border-radius: 6px; padding: 10px 14px; font-family: inherit; font-size: 1rem; }
.champ input:focus, .champ textarea:focus { border-color: var(--bleu); outline: none; }

/* ---------- Newsletter / réseaux ---------- */
.abo { background: linear-gradient(160deg, var(--lavande), #e2eafa); padding: 56px 0; }
.abo .container { display: grid; grid-template-columns: 1fr 1px 1fr; gap: 40px; align-items: center; }
.abo .sep { background: #c9d2e8; height: 100%; min-height: 80px; }
.abo h3 { font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; margin-bottom: 18px; }
.rs-row { display: flex; gap: 22px; font-size: 1.5rem; list-style: none; }
.rs-row a { width: 48px; height: 48px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; text-decoration: none; transition: .15s; box-shadow: 0 2px 8px rgba(13,44,84,.08); }
.rs-row a:hover { transform: translateY(-3px); }

/* ---------- Footer ---------- */
footer { background: #fff; border-top: 2px solid var(--bleu-nuit); }
.foot-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 36px; padding: 52px 0; }
.foot-cols h4 { font-family: var(--font-display); font-size: .95rem; font-weight: 700; margin-bottom: 16px; }
.foot-cols ul { list-style: none; }
.foot-cols li { margin-bottom: 10px; }
.foot-cols a { text-decoration: none; font-size: .9rem; color: var(--encre); }
.foot-cols a:hover { text-decoration: underline; }
.ext::after { content: " ↗"; font-size: .8em; color: var(--gris); }
.foot-marque { border-top: 1px solid #e5e5e5; padding: 36px 0; display: flex; justify-content: space-between; align-items: center; gap: 28px; flex-wrap: wrap; }
.marque-gab { display: flex; flex-direction: column; gap: 4px; }
.marque-gab .drapeau { display: flex; width: 56px; height: 38px; border: 1px solid #ddd; margin-bottom: 6px; }
.marque-gab .drapeau span { flex: 1; }
.marque-gab .titre { font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; text-transform: uppercase; letter-spacing: .02em; }
.marque-gab .devise { font-size: .78rem; font-style: italic; color: var(--gris); line-height: 1.4; }
.foot-logo { width: 72px; height: auto; }
.foot-liens-officiels { display: flex; gap: 26px; flex-wrap: wrap; }
.foot-liens-officiels a { font-weight: 700; font-size: .92rem; text-decoration: none; }
.foot-liens-officiels a:hover { text-decoration: underline; }
.foot-legal { border-top: 1px solid #e5e5e5; padding: 22px 0 30px; font-size: .82rem; color: var(--gris); }
.foot-legal .row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.foot-legal .row a { color: var(--encre); text-decoration: none; }
.foot-legal .row a:hover { text-decoration: underline; }
.foot-legal .row span { color: #ccc; }

/* ---------- Utilitaires ---------- */
.bg-lavande { background: var(--lavande); }
.bg-gris-clair { background: var(--gris-clair); }
.mt-32 { margin-top: 32px; }
.center { text-align: center; }

/* ---------- Barre de liens rapides (inspirée aninf.ga) ---------- */
.liens-rapides { background: var(--bleu); padding: 10px 0; }
.liens-rapides .container { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.lr-pill { background: var(--jaune); color: var(--encre); font-weight: 700; font-size: .88rem; padding: 9px 18px; border-radius: 6px; text-decoration: none; transition: .15s; }
.lr-pill:hover { filter: brightness(1.06); transform: translateY(-1px); }
.lr-lien { color: #fff; font-weight: 600; font-size: .88rem; text-decoration: none; }
.lr-lien:hover { text-decoration: underline; }
.lr-lien span, .lr-pill span { color: inherit; opacity: .8; margin-left: 4px; }
.lr-socials { margin-left: auto; display: flex; gap: 14px; }
.lr-socials a { color: #fff; text-decoration: none; font-weight: 700; width: 30px; height: 30px; border: 1px solid rgba(255,255,255,.4); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .85rem; transition: .15s; }
.lr-socials a:hover { background: rgba(255,255,255,.15); }

/* ---------- Hero immersif animé (accueil) ---------- */
.hero-anime { min-height: 82vh; display: flex; align-items: center; }
.hero-anime .container { padding-top: 64px; padding-bottom: 120px; }
.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .35; }
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-layer { will-change: transform; transition: transform .25s ease-out; }
.hero-contenu { position: relative; z-index: 5; }

/* Aurore : le fond du hero dérive lentement */
.hero-anime::after { animation: aurore 16s ease-in-out infinite alternate; }
@keyframes aurore {
  from { transform: scale(1.05) rotate(0deg); opacity: .9; }
  to   { transform: scale(1.22) rotate(5deg); opacity: 1; }
}

/* Entrée en scène du contenu au chargement */
.hero-anime .eyebrow  { animation: monte-doux .7s ease backwards; }
.hero-anime h1        { animation: monte-doux .7s ease .12s backwards; }
.hero-anime p.lead    { animation: monte-doux .7s ease .26s backwards; }
.hero-anime .cta-row  { animation: monte-doux .7s ease .4s backwards; }
@keyframes monte-doux {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: none; }
}

/* Flèche d'invitation à descendre */
.hero-fleche {
  position: absolute; left: 50%; bottom: 48px; z-index: 6;
  width: 40px; height: 40px; margin-left: -20px;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid rgba(255,255,255,.5); border-radius: 50%;
  color: #fff; text-decoration: none; font-size: 1rem;
  animation: rebond 2.4s ease-in-out infinite;
  transition: .15s;
}
.hero-fleche:hover { background: rgba(255,255,255,.15); border-color: #fff; }
@keyframes rebond {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

/* Contenu du hero : centré et déployé sur toute la largeur (style immobilier-etat.gouv.fr) */
.hero-anime .hero-contenu { text-align: center; }
.hero h1.hero-titre-serif {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  letter-spacing: .015em;
  line-height: 1.24;
  margin: 0 auto 6px;
  max-width: 1100px;
  font-size: clamp(2.1rem, 5.2vw, 4rem);
}
.hero-anime .eyebrow { margin-bottom: 34px; }
.hero-anime p.lead {
  margin: 30px auto 0; line-height: 1.8; letter-spacing: .01em;
  max-width: 900px; font-size: 1.15rem;
}
.hero-anime .cta-row { margin-top: 42px; gap: 18px; justify-content: center; }

/* Skyline : bâtiments de l'État + terrain, en bas du hero */
.couche-skyline { position: absolute; left: 0; right: 0; bottom: -8px; z-index: 3; pointer-events: none; }
.couche-skyline svg { width: 100%; height: 220px; display: block; }
.sk-fond rect { fill: rgba(255,255,255,.05); }
.sk-avant, .sk-avant rect, .sk-avant polygon, g.sk-avant * { fill: rgba(7, 23, 44, .55); }

/* La flotte de l'État : hélicoptère jaune (patrimoine aérien) */
.couche-helico { position: absolute; top: 14%; left: 0; z-index: 4; pointer-events: none; color: rgba(252,209,22,.55); }
.helico { width: 130px; height: auto; animation: vol-helico 46s linear infinite; filter: drop-shadow(0 4px 10px rgba(0,0,0,.25)); }
.helico .rotor { transform-origin: 110px 22px; animation: rotor .18s linear infinite; }
@keyframes vol-helico {
  0%   { transform: translate(-160px, 12px); }
  50%  { transform: translate(55vw, -14px); }
  100% { transform: translate(105vw, 6px); }
}
@keyframes rotor {
  0% { transform: scaleX(1); opacity: .9; }
  50% { transform: scaleX(.18); opacity: .5; }
  100% { transform: scaleX(1); opacity: .9; }
}

/* Avion de l'État : traverse le ciel en sens inverse, plus haut et plus lent */
.couche-avion { position: absolute; top: 5%; left: 0; z-index: 2; pointer-events: none; color: rgba(255,255,255,.30); }
.avion { width: 170px; height: auto; animation: vol-avion 64s linear infinite; animation-delay: -22s; }
@keyframes vol-avion {
  0%   { transform: translate(105vw, 0) scaleX(-1); }
  50%  { transform: translate(45vw, 18px) scaleX(-1); }
  100% { transform: translate(-260px, 4px) scaleX(-1); }
}

/* Véhicules administratifs : roulent le long de l'esplanade */
.couche-vehicules { position: absolute; left: 0; right: 0; bottom: 34px; height: 40px; z-index: 4; pointer-events: none; color: rgba(255,255,255,.30); }
.vehicule { position: absolute; bottom: 0; width: 54px; height: auto; }
.vehicule.v1 { animation: roule 34s linear infinite; }
.vehicule.v2 { width: 62px; animation: roule 27s linear infinite reverse; animation-delay: -12s; color: rgba(252,209,22,.4); }
@keyframes roule {
  0%   { transform: translateX(-80px); }
  100% { transform: translateX(105vw); }
}
.vehicule.v2 { transform: scaleX(-1); }

/* Plan d'eau + vedette de patrouille au pied du hero */
.couche-eau { position: absolute; left: 0; right: 0; bottom: 0; height: 34px; z-index: 5; pointer-events: none;
  background: linear-gradient(to bottom, rgba(58,117,196,.30), rgba(7,23,44,.75)); color: rgba(255,255,255,.42); }
.bateau { position: absolute; bottom: 4px; width: 110px; height: auto; animation: navigue 58s linear infinite; animation-delay: -18s; }
@keyframes navigue {
  0%   { transform: translate(-140px, 0); }
  25%  { transform: translate(26vw, -3px); }
  50%  { transform: translate(52vw, 0); }
  75%  { transform: translate(78vw, -3px); }
  100% { transform: translate(105vw, 0); }
}

/* ---------- Directions & services ---------- */
.services-rattaches { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); gap: 14px; margin-top: 20px; }
.service-puce { background: #fff; border: 1px solid #e8e8e8; border-left: 4px solid var(--vert); border-radius: var(--radius); padding: 14px 18px; font-size: .92rem; font-weight: 600; color: var(--bleu-nuit); }
.directions-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 22px; margin-top: 28px; }
.direction-carte { background: #fff; border: 1px solid #e8e8e8; border-top: 5px solid var(--vert); border-radius: var(--radius); padding: 26px; transition: .2s; }
.direction-carte:nth-child(2) { border-top-color: var(--jaune); }
.direction-carte:nth-child(3) { border-top-color: var(--bleu); }
.direction-carte:nth-child(4) { border-top-color: var(--bleu-nuit); }
.direction-carte:hover { box-shadow: 0 8px 24px rgba(13,44,84,.1); transform: translateY(-3px); }
.direction-carte .entete { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.direction-carte .ico { width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px; background: var(--lavande); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; }
.direction-carte .sigle { display: inline-block; font-family: var(--font-display); font-weight: 800; font-size: .8rem; color: var(--bleu-nuit); background: var(--lavande); padding: 3px 10px; border-radius: 99px; margin-bottom: 4px; }
.direction-carte h3 { font-family: var(--font-display); font-size: 1.02rem; font-weight: 700; color: var(--bleu-nuit); line-height: 1.3; }
.direction-carte ul { list-style: none; margin-top: 6px; }
.direction-carte li { font-size: .9rem; color: var(--gris); padding: 8px 0 8px 22px; position: relative; border-top: 1px solid #f0f0f0; }
.direction-carte li::before { content: "→"; position: absolute; left: 0; color: var(--vert); font-weight: 700; }

/* ---------- Bandeau d'alerte officiel ---------- */
.bandeau-alerte { background: var(--jaune); border-bottom: 1px solid rgba(0,0,0,.08); }
.bandeau-alerte .container { display: flex; align-items: center; gap: 12px; padding-top: 9px; padding-bottom: 9px; }
.ba-badge { flex-shrink: 0; font-size: 1rem; }
.ba-texte { font-size: .9rem; font-weight: 600; color: var(--encre); }
.ba-texte a { color: var(--bleu-nuit); font-weight: 700; margin-left: 6px; }
.ba-fermer { margin-left: auto; background: none; border: 0; cursor: pointer; font-size: 1.3rem; line-height: 1; color: var(--encre); opacity: .6; padding: 4px 8px; }
.ba-fermer:hover { opacity: 1; }

/* ---------- Responsables de service ---------- */
.service-resp { display: block; font-size: .8rem; font-weight: 500; color: var(--gris); margin-top: 2px; }

/* ---------- Vos démarches ---------- */
.demarches-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 22px; }
.demarche { background: #fff; border: 1px solid #e8e8e8; border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 10px; transition: .2s; }
.demarche:hover { box-shadow: 0 8px 24px rgba(13,44,84,.1); }
.demarche .entete { display: flex; align-items: center; gap: 14px; margin-bottom: 4px; }
.demarche .ico { width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px; background: var(--lavande); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; }
.demarche h2 { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; color: var(--bleu-nuit); line-height: 1.3; }
.demarche p { font-size: .92rem; color: var(--encre); }
.demarche p strong { color: var(--bleu-nuit); }
.demarche ul { list-style: none; margin-bottom: 8px; }
.demarche li { font-size: .9rem; color: var(--gris); padding: 6px 0 6px 22px; position: relative; border-top: 1px solid #f0f0f0; }
.demarche li::before { content: "✓"; position: absolute; left: 0; color: var(--vert); font-weight: 700; }
.demarche .btn { align-self: flex-start; margin-top: auto; }

/* ---------- FAQ ---------- */
.faq-liste { max-width: 800px; }
.faq-item { background: #fff; border: 1px solid #e8e8e8; border-radius: var(--radius); margin-bottom: 12px; overflow: hidden; }
.faq-item summary {
  cursor: pointer; list-style: none; padding: 18px 48px 18px 22px; position: relative;
  font-family: var(--font-display); font-weight: 700; color: var(--bleu-nuit); font-size: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); font-size: 1.4rem; color: var(--vert); transition: .2s; }
.faq-item[open] summary::after { content: "–"; }
.faq-item[open] summary { border-bottom: 1px solid #f0f0f0; }
.faq-item p { padding: 16px 22px 20px; color: var(--gris); font-size: .95rem; }

/* ---------- Provinces dépliables ---------- */
.province { cursor: default; }
.province summary { cursor: pointer; list-style: none; position: relative; padding-right: 26px; }
.province summary::-webkit-details-marker { display: none; }
.province summary::after { content: "+"; position: absolute; right: 0; top: 0; font-size: 1.2rem; color: var(--vert); font-weight: 700; }
.province[open] summary::after { content: "–"; }
.province-detail { margin-top: 12px; border-top: 1px solid #f0f0f0; padding-top: 12px; }
.province-detail p { font-size: .88rem; color: var(--gris); margin-bottom: 6px; }
.province-todo { font-style: italic; }

/* ---------- Vitrine patrimoine (accueil) : image + cartes côte à côte ---------- */
.patrimoine-vitrine { display: grid; gap: 20px; align-items: center; }
@media (min-width: 920px) { .patrimoine-vitrine { grid-template-columns: 1.05fr 1fr; gap: 36px; } }
.apercu-patrimoine { position: relative; }
.apercu-patrimoine img { width: 100%; height: auto; border-radius: var(--radius); box-shadow: 0 18px 48px rgba(13,44,84,.2); border: 1px solid #e5e5e5; transition: .25s ease; }
.apercu-patrimoine a:hover img { transform: translateY(-5px) scale(1.01); box-shadow: 0 26px 60px rgba(13,44,84,.26); }
/* cadre tricolore décoratif derrière l'image */
.apercu-patrimoine::before {
  content: ""; position: absolute; inset: 18px -14px -14px 18px; z-index: -1;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--vert) 33%, var(--jaune) 33% 66%, var(--bleu) 66%);
  opacity: .25;
}
.patrimoine-vitrine .actus-grid { grid-template-columns: 1fr; gap: 16px; }

/* ---------- Bande d'appel « démarches » ---------- */
.bande-demarches { background: var(--bleu-nuit); color: #fff; padding: 44px 0; }
.bande-demarches .container { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.bande-demarches h2 { font-family: var(--font-display); font-weight: 800; font-size: 1.4rem; margin-bottom: 8px; }
.bande-demarches p { color: #dfe7f5; max-width: 640px; font-size: .95rem; }
.bande-demarches .btn { flex-shrink: 0; }

/* ---------- Bannière de bienvenue (style whitehouse.gov) ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.modal-fond {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(7, 23, 44, .65);
  display: flex; align-items: center; justify-content: flex-start; padding: 20px 20px 20px 48px;
  animation: modal-apparait .3s ease;
}
.modal-fond[hidden] { display: none; }
.modal-carte {
  position: relative; background: #fff; border-radius: 18px; max-width: 560px; width: 100%;
  max-height: calc(100vh - 40px); overflow: hidden auto;
  text-align: center; padding: 44px 36px 0; box-shadow: 0 30px 80px rgba(0,0,0,.35);
  animation: modal-glisse .4s ease;
}
@keyframes modal-apparait { from { opacity: 0; } to { opacity: 1; } }
@keyframes modal-glisse { from { opacity: 0; transform: translateX(-60px); } to { opacity: 1; transform: none; } }
@media (max-width: 700px) {
  .modal-fond { justify-content: center; padding: 20px; }
}

.modal-fermer {
  position: absolute; top: 16px; right: 18px; z-index: 2;
  background: none; border: 0; cursor: pointer;
  font-size: 1.9rem; line-height: 1; color: #b21;
  transition: .15s;
}
.modal-fermer:hover { transform: scale(1.15); }

.mb-marque { display: flex; flex-direction: column; align-items: center; gap: 3px; margin-bottom: 26px; }
.mb-logo { width: 84px; height: auto; margin-bottom: 10px; }
.mb-rep { font-family: var(--font-display); font-weight: 800; font-size: .82rem; text-transform: uppercase; letter-spacing: .14em; }
.mb-sigle { font-size: .72rem; letter-spacing: .3em; text-transform: uppercase; color: var(--gris); }

.mb-titre {
  font-family: 'Playfair Display', Georgia, serif; font-weight: 700;
  font-size: clamp(1.5rem, 4.5vw, 2.2rem); line-height: 1.25;
  color: var(--bleu-nuit); text-transform: uppercase; letter-spacing: .02em;
  margin-bottom: 22px;
}
.mb-texte { color: var(--encre); font-size: 1.02rem; line-height: 1.7; margin-bottom: 28px; }

.mb-form { display: flex; flex-direction: column; gap: 14px; max-width: 420px; margin: 0 auto; }
.mb-form input {
  border: 1px solid #c9c9c9; border-radius: 99px; padding: 14px 24px;
  font-family: inherit; font-size: 1rem; text-align: center;
}
.mb-form input:focus { border-color: var(--bleu); outline: none; }
.mb-bouton {
  background: var(--bleu-nuit); color: #fff; border: 0; border-radius: 99px;
  font-family: var(--font-display); font-weight: 800; font-size: .98rem;
  text-transform: uppercase; letter-spacing: .04em;
  padding: 15px 24px; cursor: pointer; transition: .15s;
}
.mb-bouton:hover { filter: brightness(1.2); transform: translateY(-1px); }

.mb-arc {
  position: relative; margin: 34px -36px 0; height: 120px; overflow: hidden;
  background: radial-gradient(120% 190% at 50% 100%, var(--bleu-nuit) 60%, transparent 60.5%);
}
.mb-helico {
  position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%);
  width: 110px; color: var(--jaune);
}
.mb-tricolore { position: absolute; bottom: 0; left: 0; right: 0; height: 5px; display: flex; }
.mb-tricolore span { flex: 1; }

@media (max-width: 560px) {
  .modal-carte { padding: 36px 22px 0; }
  .mb-arc { margin: 28px -22px 0; height: 90px; }
}

/* Pilule flottante de réouverture (mécanique whitehouse.gov) */
.pill-bienvenue {
  position: fixed; bottom: 22px; left: 22px; z-index: 150;
  display: inline-flex; align-items: center; gap: 1px;
  background: var(--jaune); border-radius: 99px; padding: 3px 14px 3px 6px;
  box-shadow: 0 6px 18px rgba(0,0,0,.28);
  animation: modal-glisse .4s ease;
  /* laisse la place au bouton retour-en-haut (fixe en bas à droite, z-index 150) */
  max-width: calc(100vw - 96px);
  z-index: 149;
}
.pill-bienvenue[hidden] { display: none; }
.pill-fermer {
  background: none; border: 0; cursor: pointer;
  font-size: 1.05rem; line-height: 1; color: var(--encre); opacity: .65;
  padding: 5px 6px;
}
.pill-fermer:hover { opacity: 1; }
.pill-ouvrir {
  background: none; border: 0; cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: .78rem;
  text-transform: uppercase; letter-spacing: .03em; color: var(--encre);
  padding: 7px 2px; white-space: nowrap;
}
.pill-ouvrir:hover { text-decoration: underline; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.vu { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
  }
  /* suppression explicite des animations décoratives (les pseudo-éléments et les
     délais ne sont pas couverts fiablement par la règle universelle) */
  .hero-anime::after { animation: none !important; }
  .hero-anime .eyebrow, .hero-anime h1, .hero-anime p.lead, .hero-anime .cta-row,
  .modal-fond, .modal-carte, .pill-bienvenue, .hero-fleche, .hero .eyebrow i,
  .helico, .helico .rotor, .avion, .bateau, .vehicule {
    animation: none !important; opacity: 1; transform: none;
  }
}
@media (max-width: 820px) {
  .abo .container { grid-template-columns: 1fr; gap: 28px; }
  .abo .sep { display: none; }
  /* en mobile : on garde le sceau + sigle DGPE à gauche, on masque le libellé long
     et le bloc République Gabonaise (déjà présent dans la topbar) */
  .brand-name .full { display: none; }
  .bloc-marque { display: none; }
  .brand-logo { width: 48px; }
  .brand-name .sigle { font-size: 1.3rem; }
  header.site { position: static; }
  .carte-dir .photo { width: 100%; height: 200px; }
}

/* Respiration réduite sur mobile */
@media (max-width: 768px) {
  section.bloc { padding: 52px 0; }
  .hero-anime { min-height: 64vh; }
}
@media (max-width: 480px) {
  .chiffres.chevauche .grid { margin-top: -28px; }
}
