/* ============================================================
   Kairo — feuille de style unique
   Direction : « le dossier de preuve » (spec validée 06/07)
   Fonds clairs ivoire · encre profonde · UN accent cuivre
   Serif éditoriale (Fraunces) titres · Public Sans corps
   ⛔ AUCUNE animation d'apparition (scroll-reveal, fade-in)
   ✅ compteurs de chiffres + micro-interactions uniquement
   ============================================================ */

:root {
  --papier: #FFFDF8;        /* fond cartes / bandeaux */
  --ivoire: #F7F2E9;        /* fond global */
  --ivoire-fonce: #EFE7D8;  /* aplats discrets */
  --encre: #1A2742;         /* bleu encre profond : texte, titres */
  --encre-2: #4A5670;       /* texte secondaire */
  --cuivre: #A5672D;        /* L'accent unique */
  --cuivre-fonce: #8A5525;
  --ligne: rgba(26, 39, 66, 0.16);
  --ligne-forte: rgba(26, 39, 66, 0.32);

  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Public Sans", "Helvetica Neue", Arial, sans-serif;

  --mesure: 68ch;
  --gouttiere: clamp(1.25rem, 4vw, 3rem);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

body {
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--encre);
  background-color: var(--ivoire);
  /* grain de papier, quasi subliminal */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.025'/%3E%3C/svg%3E");
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--cuivre); color: var(--papier); }

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

/* ---------- typographie ---------- */
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 560;
  line-height: 1.12;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.3rem, 5.4vw, 4.1rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); }

p, li { max-width: var(--mesure); }

a { color: inherit; }

.kicker {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cuivre);
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}
.kicker::before {
  content: "";
  width: 2.2rem;
  height: 1px;
  background: var(--cuivre);
}

.sous-titre {
  color: var(--encre-2);
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
  margin-top: 1.2rem;
}

/* ---------- structure ---------- */
.cadre {
  max-width: 76rem;
  margin-inline: auto;
  padding-inline: var(--gouttiere);
}

.section { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.section + .section { border-top: 1px solid var(--ligne); }
.section--papier { background: var(--papier); border-block: 1px solid var(--ligne); }
.section--encre {
  background: var(--encre);
  color: var(--papier);
  border: 0;
}
.section--encre .kicker { color: var(--cuivre-clair, #C89058); }
.section--encre .sous-titre { color: rgba(255, 253, 248, 0.75); }

/* ---------- en-tête ---------- */
.entete {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--ivoire) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--ligne);
}
.entete__barre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0.9rem;
}
.marque {
  font-family: var(--serif);
  font-weight: 620;
  font-size: 1.28rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
}
.marque em {
  font-style: normal;
  color: var(--cuivre);
}
.nav {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 2.4vw, 2rem);
}
.nav a {
  font-size: 0.92rem;
  font-weight: 550;
  text-decoration: none;
  color: var(--encre-2);
  position: relative;
  padding-block: 0.35rem;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%;
  bottom: 0;
  height: 2px;
  background: var(--cuivre);
  transition: right 0.22s ease;
}
.nav a:hover::after,
.nav a[aria-current="page"]::after { right: 0; }
.nav a[aria-current="page"] { color: var(--encre); }

@media (max-width: 720px) {
  .entete__barre { flex-wrap: wrap; row-gap: 0.15rem; padding-block: 0.7rem; }
  .nav { width: 100%; flex-wrap: wrap; gap: 0.35rem 1.15rem; }
  .nav .btn { display: none; } /* le CTA compte-rendu vit déjà dans chaque section */
}

/* ---------- boutons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 650;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.85rem 1.6rem;
  background: var(--encre);
  color: var(--papier);
  border: 1px solid var(--encre);
  border-radius: 2px;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.12s ease;
}
.btn:hover { background: var(--cuivre-fonce); border-color: var(--cuivre-fonce); }
.btn:active { transform: translateY(1px); }
.btn--contour {
  background: transparent;
  color: var(--encre);
}
.btn--contour:hover { background: var(--encre); color: var(--papier); }
.section--encre .btn {
  background: var(--cuivre);
  border-color: var(--cuivre);
}
.section--encre .btn:hover { background: var(--papier); border-color: var(--papier); color: var(--encre); }

/* ---------- héro ---------- */
.hero { padding-block: clamp(4rem, 10vw, 7.5rem) clamp(3rem, 7vw, 5.5rem); }
.hero__grille {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: end;
}
@media (max-width: 900px) {
  .hero__grille { grid-template-columns: 1fr; }
}

/* la scène, posée comme une pièce du dossier */
.scene {
  border-left: 2px solid var(--cuivre);
  padding: 0.4rem 0 0.4rem 1.4rem;
  font-family: var(--serif);
  font-size: clamp(1.05rem, 1.7vw, 1.22rem);
  line-height: 1.55;
  font-style: italic;
  color: var(--encre-2);
}
.scene strong { color: var(--encre); font-weight: 620; }

/* ---------- la signature : le constat chiffré ---------- */
.constat-chiffre {
  border-top: 2px solid var(--encre);
  padding-top: 1.1rem;
}
.constat-chiffre .valeur {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: lining-nums;
  color: var(--encre);
}
.constat-chiffre .valeur .unite {
  font-size: 0.45em;
  color: var(--cuivre);
  margin-left: 0.08em;
}
.constat-chiffre .legende {
  margin-top: 0.55rem;
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--encre-2);
  max-width: 26ch;
}
.constat-chiffre .source-inline {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cuivre);
}
.bande-chiffres {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
}
.section--encre .constat-chiffre { border-top-color: var(--papier); }
.section--encre .constat-chiffre .valeur { color: var(--papier); }
.section--encre .constat-chiffre .legende { color: rgba(255, 253, 248, 0.72); }

/* ---------- constats numérotés (pièces versées) ---------- */
.pieces {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1px;
  background: var(--ligne);
  border: 1px solid var(--ligne);
}
.piece {
  background: var(--papier);
  padding: clamp(1.5rem, 3vw, 2.4rem);
  transition: background 0.2s ease;
}
.piece:hover { background: var(--ivoire); }
.piece .numero {
  font-family: var(--serif);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--cuivre);
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: 0.9rem;
}
.piece h3 { margin-bottom: 0.7rem; }
.piece p { font-size: 0.97rem; color: var(--encre-2); }

/* ---------- étapes méthode ---------- */
.etape {
  display: grid;
  grid-template-columns: minmax(4.5rem, 8rem) 1fr;
  gap: clamp(1.2rem, 3vw, 2.5rem);
  padding-block: clamp(1.8rem, 4vw, 2.8rem);
  border-top: 1px solid var(--ligne);
}
.etape:last-of-type { border-bottom: 1px solid var(--ligne); }
.etape .numero {
  font-family: var(--serif);
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  font-weight: 480;
  color: var(--cuivre);
  line-height: 1;
}
.etape h3 { margin-bottom: 0.6rem; }
.etape p { color: var(--encre-2); }
.etape p + p { margin-top: 0.6rem; }

/* ---------- offre ---------- */
.grille-prix {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: clamp(1.2rem, 2.5vw, 2rem);
  align-items: stretch;
}
.carte-prix {
  background: var(--papier);
  border: 1px solid var(--ligne);
  padding: clamp(1.6rem, 3vw, 2.4rem);
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  transition: border-color 0.2s ease, transform 0.15s ease;
}
.carte-prix:hover { border-color: var(--cuivre); transform: translateY(-2px); }
.carte-prix--pivot { border-top: 3px solid var(--cuivre); }
.carte-prix .designation {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cuivre);
}
.carte-prix .prix {
  font-family: var(--serif);
  font-size: clamp(2.1rem, 4vw, 2.9rem);
  font-weight: 520;
  line-height: 1;
}
.carte-prix .prix .unite { font-size: 0.42em; color: var(--encre-2); font-family: var(--sans); font-weight: 500; }
.carte-prix ul { list-style: none; display: grid; gap: 0.55rem; }
.carte-prix li {
  font-size: 0.94rem;
  color: var(--encre-2);
  padding-left: 1.3rem;
  position: relative;
}
.carte-prix li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.55rem;
  height: 1px;
  background: var(--cuivre);
}
.carte-prix .note-carte { font-size: 0.83rem; color: var(--encre-2); margin-top: auto; padding-top: 0.6rem; border-top: 1px dashed var(--ligne); }

/* ---------- prose (articles ressources) ---------- */
.prose { max-width: var(--mesure); }
.prose > * + * { margin-top: 1.15rem; }
.prose h2 { margin-top: 2.6rem; }
.prose h3 { margin-top: 2rem; }
.prose ul, .prose ol { padding-left: 1.3rem; }
.prose li + li { margin-top: 0.45rem; }
.prose blockquote {
  border-left: 2px solid var(--cuivre);
  padding-left: 1.2rem;
  color: var(--encre-2);
  font-style: italic;
}
.prose .source {
  font-size: 0.82rem;
  color: var(--encre-2);
  border-top: 1px dashed var(--ligne);
  padding-top: 0.7rem;
}
.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
}
.prose th, .prose td {
  text-align: left;
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--ligne);
}
.prose th {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cuivre);
}

.fil-ariane {
  font-size: 0.8rem;
  color: var(--encre-2);
  margin-bottom: 2rem;
}
.fil-ariane a { color: var(--cuivre); text-decoration: none; }
.fil-ariane a:hover { text-decoration: underline; }

/* ---------- cartes ressources ---------- */
.grille-ressources {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: clamp(1.2rem, 2.5vw, 2rem);
}
.carte-ressource {
  background: var(--papier);
  border: 1px solid var(--ligne);
  padding: clamp(1.5rem, 3vw, 2.2rem);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  transition: border-color 0.2s ease, transform 0.15s ease;
}
.carte-ressource:hover { border-color: var(--cuivre); transform: translateY(-2px); }
.carte-ressource .famille {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cuivre);
}
.carte-ressource p { font-size: 0.94rem; color: var(--encre-2); }
.carte-ressource .lire {
  margin-top: auto;
  padding-top: 0.8rem;
  font-size: 0.88rem;
  font-weight: 650;
  color: var(--encre);
}
.carte-ressource:hover .lire { color: var(--cuivre-fonce); }

/* ---------- bloc CTA récurrent ---------- */
.bloc-cr {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
@media (max-width: 860px) { .bloc-cr { grid-template-columns: 1fr; } }
.bloc-cr .modalites {
  font-size: 0.9rem;
  color: rgba(255, 253, 248, 0.72);
  margin-top: 1rem;
}

/* ---------- pied de page ---------- */
.pied {
  background: var(--papier);
  border-top: 1px solid var(--ligne);
  padding-block: clamp(2.5rem, 6vw, 4rem);
  font-size: 0.9rem;
  color: var(--encre-2);
}
.pied__grille {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 3fr);
  gap: clamp(1.5rem, 4vw, 3rem);
}
@media (max-width: 820px) { .pied__grille { grid-template-columns: 1fr; } }
.pied .marque { font-size: 1.1rem; }
.pied .ligne-gc {
  margin-top: 0.9rem;
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.98rem;
  color: var(--encre-2);
  max-width: 46ch;
}
.pied h4 {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cuivre);
  margin-bottom: 0.9rem;
}
.pied ul { list-style: none; display: grid; gap: 0.5rem; }
.pied a { text-decoration: none; }
.pied a:hover { color: var(--cuivre-fonce); text-decoration: underline; }
.mentions {
  margin-top: clamp(2rem, 5vw, 3rem);
  padding-top: 1.2rem;
  border-top: 1px dashed var(--ligne);
  font-size: 0.78rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  justify-content: space-between;
}

/* ---------- divers ---------- */
.filet-cuivre {
  width: 3.5rem;
  height: 2px;
  background: var(--cuivre);
  border: 0;
  margin-block: 1.6rem;
}
.note-honnete {
  font-size: 0.85rem;
  color: var(--encre-2);
  background: var(--ivoire-fonce);
  border-left: 2px solid var(--cuivre);
  padding: 0.8rem 1.1rem;
  max-width: var(--mesure);
}
