/* =================================================================
   norme-iso-42001.ch — Système de design "Institutionnel"
   Style suisse international : grille stricte, sobriété, précision.
   Marque DISTINCTE de TimeKraft (aucun violet/magenta).
   ================================================================= */

/* ---- Jetons (design tokens) ---- */
:root {
  /* Couleurs */
  --ink: #16181D;          /* encre quasi noire (navy) */
  --ink-soft: #2B2F38;     /* texte secondaire foncé */
  --paper: #FAFAF7;        /* papier ivoire */
  --paper-2: #F2F1EA;      /* ivoire plus dense (cartes alternées) */
  --accent: #2F4A6B;       /* bleu ardoise institutionnel */
  --accent-deep: #21364E;  /* accent au survol */
  --rule: #DAD6CB;         /* filet fin chaud */
  --rule-strong: #C4BFB1;  /* filet plus marqué */
  --muted: #6B6E73;        /* gris texte */
  --muted-2: #94918A;      /* gris léger */

  /* Typographie */
  --serif: "Spectral", Georgia, "Times New Roman", serif;
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --mono: "Spline Sans Mono", "SFMono-Regular", Menlo, monospace;

  /* Grille */
  --maxw: 1180px;
  --gutter: clamp(20px, 5vw, 64px);
  --rythm: 8px;
}

/* ---- Réinitialisation légère ---- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
::selection { background: var(--accent); color: var(--paper); }
[id] { scroll-margin-top: 88px; }

/* ---- Conteneur ---- */
.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-inline: var(--gutter);
}

/* ---- Typographie ---- */
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.01em; line-height: 1.12; margin: 0; }
h1 { font-size: clamp(2.4rem, 5.2vw, 3.9rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.22rem; line-height: 1.25; }
p { margin: 0 0 1rem; }

/* Étiquette en capitales espacées (registre administratif) */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--accent);
  display: inline-block;
}

.lead { font-size: 1.16rem; color: var(--ink-soft); line-height: 1.55; }
.muted { color: var(--muted); }

/* Numéro de section (réf. document normatif) */
.numref { font-family: var(--mono); font-variant-numeric: tabular-nums; color: var(--accent); }

/* ---- Liens texte ---- */
.link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-size: 0% 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size 0.3s ease;
  padding-bottom: 1px;
}
.link:hover { background-size: 100% 1px; }

/* ---- Boutons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  padding: 0.85em 1.5em;
  text-decoration: none;
  border: 1px solid var(--ink);
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}
.btn--primary { background: var(--ink); color: var(--paper); }
.btn--primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn--ghost:hover { border-color: var(--ink); }

/* =================================================================
   EN-TÊTE
   ================================================================= */
.topstrip {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}
.topstrip .wrap {
  display: flex; justify-content: flex-end;
  padding-block: 7px;
}
.topstrip span {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--muted-2);
  text-transform: uppercase;
}

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250,250,247,0.88);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--rule);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-block: 16px;
  gap: 24px;
}
.brand {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
}
.brand b { color: var(--accent); font-weight: 500; }
.nav { display: flex; gap: 26px; }
.nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 500;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.nav a:hover { color: var(--ink); border-color: var(--accent); }
.menu-toggle { display: none; }

/* =================================================================
   HÉRO
   ================================================================= */
.hero { position: relative; border-bottom: 1px solid var(--rule); overflow: hidden; }
/* Grille suisse en filigrane */
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(
    to right, transparent, transparent calc(25% - 1px),
    var(--rule) calc(25% - 1px), var(--rule) 25%);
  opacity: 0.45;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.5), transparent 70%);
          mask-image: linear-gradient(to bottom, rgba(0,0,0,0.5), transparent 70%);
  pointer-events: none;
}
.hero .wrap {
  position: relative;
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
  padding-block: clamp(56px, 9vw, 104px);
}
.hero h1 { margin-bottom: 1.4rem; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero .lead { max-width: 42ch; margin-bottom: 2.2rem; }
.hero-cta { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }

/* Carte "colonne vertébrale" de la norme */
.spine {
  background: var(--paper-2);
  border: 1px solid var(--rule-strong);
  padding: 26px 28px 22px;
}
.spine .eyebrow { margin-bottom: 0.9rem; }
.spine-title { font-family: var(--serif); font-size: 1.05rem; margin-bottom: 14px; }
.spine ol { list-style: none; margin: 0; padding: 0; }
.spine li {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 12px;
  align-items: baseline;
  padding: 9px 0;
  border-top: 1px solid var(--rule);
  font-size: 0.93rem;
}
.spine li:first-child { border-top: 0; }
.spine li .numref { font-size: 0.85rem; }
.spine-note { margin: 14px 0 0; font-size: 0.74rem; color: var(--muted-2); line-height: 1.4; }

/* =================================================================
   SECTIONS GÉNÉRIQUES
   ================================================================= */
.section { padding-block: clamp(56px, 8vw, 96px); border-bottom: 1px solid var(--rule); }
.section-head { max-width: 60ch; margin-bottom: 48px; }
.section-head h2 { margin-bottom: 1rem; }

/* ---- Piliers ---- */
.pillars { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border: 1px solid var(--rule-strong); }
.pillar {
  padding: 34px 32px 30px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  color: var(--ink);
  position: relative;
  transition: background 0.25s ease;
}
.pillar:nth-child(2n) { border-right: 0; }
.pillar:nth-last-child(-n+2) { border-bottom: 0; }
.pillar:hover { background: var(--paper-2); }
.pillar .numref { font-size: 1.05rem; display: block; margin-bottom: 18px; }
.pillar h3 { margin-bottom: 10px; }
.pillar p { font-size: 0.95rem; color: var(--muted); margin-bottom: 18px; }
.pillar .go { font-size: 0.86rem; font-weight: 600; color: var(--accent); letter-spacing: 0.02em; }
.pillar .go::after { content: " \2192"; transition: margin 0.2s ease; }
.pillar:hover .go::after { margin-left: 5px; }

/* ---- Valeur (3 colonnes) ---- */
.value-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.value-item { border-top: 2px solid var(--ink); padding-top: 18px; }
.value-item h3 { font-size: 1.1rem; margin-bottom: 8px; }
.value-item p { font-size: 0.95rem; color: var(--muted); margin: 0; }

/* ---- Glossaire (aperçu) ---- */
.glossary-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.term {
  border: 1px solid var(--rule);
  padding: 22px 22px 20px;
  background: var(--paper);
}
.term dt { font-family: var(--serif); font-size: 1.08rem; margin-bottom: 7px; }
.term dd { margin: 0; font-size: 0.9rem; color: var(--muted); line-height: 1.5; }
.term .code { font-family: var(--mono); font-size: 0.7rem; color: var(--accent); letter-spacing: 0.08em; display: block; margin-bottom: 11px; }

/* ---- Ressources / newsletter ---- */
.resources { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(32px, 6vw, 72px); align-items: start; }
.res-list { list-style: none; margin: 0; padding: 0; }
.res-list li {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding: 16px 0; border-top: 1px solid var(--rule);
}
.res-list li:last-child { border-bottom: 1px solid var(--rule); }
.res-list .res-name { font-weight: 500; }
.res-list .tag { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-2); border: 1px solid var(--rule-strong); padding: 3px 8px; white-space: nowrap; }
.signup { background: var(--ink); color: var(--paper); padding: 34px 32px; }
.signup h3 { color: var(--paper); margin-bottom: 10px; }
.signup p { color: #C9CBD0; font-size: 0.93rem; }
.signup form { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.signup input {
  flex: 1 1 200px;
  background: transparent;
  border: 1px solid #3A3F49;
  color: var(--paper);
  padding: 0.8em 1em;
  font-family: var(--sans); font-size: 0.95rem;
}
.signup input::placeholder { color: #7E828B; }
.signup input:focus { outline: none; border-color: var(--paper); }
.signup .btn--primary { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.signup .btn--primary:hover { background: var(--accent); color: var(--paper); border-color: var(--accent); }

/* ---- Auteur / E-E-A-T ---- */
.author { display: grid; grid-template-columns: 88px 1fr; gap: 28px; align-items: start; }
.author .mono-avatar {
  width: 88px; height: 88px;
  border: 1px solid var(--rule-strong);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 2rem; color: var(--accent);
  background: var(--paper-2);
}
.author h3 { margin-bottom: 4px; }
.author .role { font-family: var(--mono); font-size: 0.76rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.author p { font-size: 0.97rem; max-width: 62ch; }

/* =================================================================
   PIED DE PAGE
   ================================================================= */
.site-footer { background: var(--ink); color: #C9CBD0; padding-block: 56px 30px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 36px; }
.site-footer .brand { color: var(--paper); display: inline-block; margin-bottom: 14px; }
.site-footer .brand b { color: #7FA3C9; }
.footer-about { font-size: 0.88rem; line-height: 1.55; max-width: 34ch; }
.footer-credit { font-size: 0.82rem; color: var(--muted-2); margin-top: 14px; max-width: 34ch; }
.footer-credit a { color: #7FA3C9; text-decoration: none; border-bottom: 1px solid transparent; transition: border-color 0.2s ease; }
.footer-credit a:hover { border-color: #7FA3C9; }
.footer-col h4 { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); margin: 0 0 14px; font-weight: 500; }
.footer-col a { display: block; color: #C9CBD0; text-decoration: none; font-size: 0.9rem; padding: 5px 0; transition: color 0.2s ease; }
.footer-col a:hover { color: var(--paper); }
.disclaimer {
  margin-top: 44px; padding-top: 22px;
  border-top: 1px solid #2C313B;
  font-size: 0.76rem; color: #8A8E97; line-height: 1.6;
  display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.disclaimer p { margin: 0; max-width: 78ch; }
.disclaimer a { color: #C9CBD0; text-decoration: underline; text-underline-offset: 2px; }
.disclaimer a:hover { color: var(--paper); }

/* =================================================================
   PAGE DE CONTENU (gabarit d'article)
   ================================================================= */
.breadcrumb { padding-block: 18px; border-bottom: 1px solid var(--rule); }
.breadcrumb ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.04em; color: var(--muted); }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb li:not(:last-child)::after { content: "/"; margin-left: 8px; color: var(--rule-strong); }
.breadcrumb li[aria-current] { color: var(--ink); }

.article { max-width: 760px; margin: 0 auto; padding-block: clamp(40px, 6vw, 72px); }
.article-head { margin-bottom: 36px; }
.article-head h1 { font-size: clamp(2rem, 4.4vw, 3rem); margin-bottom: 18px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.04em; color: var(--muted); text-transform: uppercase; }
.article-meta .dot { width: 4px; height: 4px; background: var(--rule-strong); border-radius: 50%; }

/* Bloc réponse-d'abord (appât snippet + citation IA) */
.answer-box { background: var(--paper-2); border-left: 3px solid var(--accent); padding: 22px 26px; margin: 0 0 40px; }
.answer-box .label { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 10px; }
.answer-box p { font-size: 1.12rem; line-height: 1.55; margin: 0; color: var(--ink); font-family: var(--serif); }

/* Sommaire */
.toc { border: 1px solid var(--rule); padding: 20px 24px; margin: 0 0 44px; }
.toc .label { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 12px; }
.toc ol { margin: 0; padding-left: 0; list-style: none; counter-reset: toc; }
.toc li { counter-increment: toc; padding: 5px 0; font-size: 0.95rem; }
.toc li::before { content: counter(toc, decimal-leading-zero) "  "; font-family: var(--mono); color: var(--accent); font-size: 0.8rem; }
.toc a { color: var(--ink-soft); text-decoration: none; }
.toc a:hover { color: var(--accent); }

/* Corps de l'article */
.prose h2 { font-size: 1.65rem; margin: 48px 0 16px; padding-top: 18px; border-top: 1px solid var(--rule); }
.prose h3 { font-size: 1.18rem; margin: 30px 0 10px; }
.prose p { margin: 0 0 1.15rem; }
.prose ul { margin: 0 0 1.3rem; padding-left: 0; list-style: none; }
.prose ul li { position: relative; padding-left: 24px; margin-bottom: 9px; }
.prose ul li::before { content: ""; position: absolute; left: 4px; top: 0.62em; width: 7px; height: 1px; background: var(--accent); }
.prose strong { font-weight: 600; }

/* Appel de note (citation) */
sup.ref { font-family: var(--mono); font-size: 0.62em; line-height: 0; }
sup.ref a { color: var(--accent); text-decoration: none; padding: 0 1px; }
sup.ref a:hover { background: var(--accent); color: var(--paper); }

/* Tableau de faits */
.facts { width: 100%; border-collapse: collapse; margin: 8px 0 36px; font-size: 0.95rem; }
.facts caption { text-align: left; font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); padding-bottom: 12px; }
.facts th, .facts td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--rule); vertical-align: top; }
.facts th { width: 38%; font-weight: 600; color: var(--ink-soft); background: var(--paper-2); }

/* FAQ */
.faq { margin: 8px 0 0; }
.faq-item { border-top: 1px solid var(--rule); padding: 20px 0; }
.faq-item:last-child { border-bottom: 1px solid var(--rule); }
.faq-q { font-family: var(--serif); font-size: 1.12rem; margin: 0 0 8px; }
.faq-a { margin: 0; color: var(--ink-soft); font-size: 0.97rem; }

/* CTA contextuel unique */
.article-cta { background: var(--ink); color: var(--paper); padding: 28px 30px; margin: 48px 0; }
.article-cta h3 { color: var(--paper); margin-bottom: 8px; }
.article-cta p { color: #C9CBD0; font-size: 0.93rem; margin-bottom: 16px; }
.article-cta .btn--primary { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.article-cta .btn--primary:hover { background: var(--accent); color: var(--paper); border-color: var(--accent); }

/* Articles liés (maillage interne) */
.related { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 24px; }
.related a { border: 1px solid var(--rule); padding: 18px 20px; text-decoration: none; color: var(--ink); transition: border-color 0.2s ease; }
.related a:hover { border-color: var(--accent); }
.related .k { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-2); display: block; margin-bottom: 8px; }
.related .t { font-family: var(--serif); font-size: 1.02rem; }

/* Sources et vérification */
.sources { margin: 48px 0 0; padding-top: 24px; border-top: 2px solid var(--ink); }
.sources .label { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 14px; }
.sources ol { margin: 0; padding-left: 20px; }
.sources li { font-size: 0.86rem; color: var(--ink-soft); line-height: 1.5; margin-bottom: 10px; }
.sources a { color: var(--accent); word-break: break-word; }
.verif { margin-top: 22px; font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.04em; color: var(--muted); }
.verif b { color: var(--ink); font-weight: 500; }

@media (max-width: 680px) {
  .related { grid-template-columns: 1fr; }
  .facts th { width: 44%; }
}

/* ---- Page hub de pilier ---- */
.hub { padding-block: clamp(40px, 6vw, 68px); }
.hub-intro { max-width: 680px; margin-bottom: 44px; }
.hub-intro h1 { margin: 14px 0 16px; }
.article-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.ali { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.ali-main { flex: 1; }
.ali-t { font-family: var(--serif); font-size: 1.18rem; color: var(--ink); text-decoration: none; }
a.ali-t { background-image: linear-gradient(var(--accent), var(--accent)); background-size: 0 1px; background-repeat: no-repeat; background-position: 0 100%; transition: background-size 0.3s ease; padding-bottom: 2px; }
a.ali-t:hover { background-size: 100% 1px; }
.ali--soon .ali-t { color: var(--muted); }
.ali-d { margin: 6px 0 0; font-size: 0.92rem; color: var(--muted); }
.status { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase; padding: 4px 9px; white-space: nowrap; align-self: center; }
.status--live { color: var(--accent); border: 1px solid var(--accent); }
.status--soon { color: var(--muted-2); border: 1px solid var(--rule-strong); }
@media (max-width: 600px) { .ali { flex-direction: column; gap: 8px; align-items: flex-start; } }

/* ---- Couverture d'article (bandeau premium sombre) ---- */
.article-cover { position: relative; background: var(--ink); color: var(--paper); overflow: hidden; border-bottom: 1px solid var(--rule); }
.article-cover::before { content: ""; position: absolute; inset: 0; background-image: repeating-linear-gradient(to right, transparent, transparent calc(25% - 1px), rgba(255,255,255,0.05) calc(25% - 1px), rgba(255,255,255,0.05) 25%); pointer-events: none; }
.article-cover .wrap { position: relative; padding-block: clamp(44px, 7vw, 82px); }
.article-cover .eyebrow { color: #8FB0D6; }
.article-cover .eyebrow::before { background: #8FB0D6; }
.article-cover h1 { color: var(--paper); max-width: 20ch; margin: 0 0 18px; }
.article-cover .article-meta { color: #9CA1AA; }
.article-cover .article-meta .dot { background: #4A4F59; }
.cover-mark { position: absolute; right: -8px; bottom: -28px; font-family: var(--serif); font-weight: 600; font-size: clamp(130px, 22vw, 260px); line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(250,250,247,0.11); pointer-events: none; user-select: none; }
@media (max-width: 700px) { .cover-mark { display: none; } }

/* ---- Couverture éditoriale d'article (emplacement image) ----
   La vraie image (du workflow) remplacera le dégradé : il suffit d'ajouter <img> dans .post-cover. */
.post-cover { position: relative; aspect-ratio: 16 / 7; overflow: hidden; background: linear-gradient(118deg, #1B2D44 0%, #2F4A6B 52%, #5A7FAC 100%); border-bottom: 1px solid var(--rule); }
/* Une teinte par pilier : même famille, identité distincte */
.post-cover--comprendre { background: linear-gradient(118deg, #1B2D44 0%, #2F4A6B 52%, #5A7FAC 100%); }       /* bleu marine */
.post-cover--risques { background: linear-gradient(118deg, #2A1218 0%, #54212E 52%, #863A4B 100%); }          /* bordeaux profond */
.post-cover--comparatifs { background: linear-gradient(118deg, #0F2A21 0%, #1B4636 52%, #336B51 100%); }      /* vert forêt */
.post-cover--se-certifier { background: linear-gradient(118deg, #33260E 0%, #6B4D17 52%, #C08A2E 100%); }     /* ocre soleil */

/* Couleur par pilier sur les cartes de l'accueil (numéro + filet en haut) */
.pillar--comprendre { --pc: #2F4A6B; }
.pillar--risques { --pc: #863A4B; }
.pillar--comparatifs { --pc: #336B51; }
.pillar--se-certifier { --pc: #9A6F22; }
.pillar[class*="pillar--"] { border-top: 3px solid var(--pc); }
.pillar[class*="pillar--"] .numref { color: var(--pc); }
.pillar[class*="pillar--"] .go { color: var(--pc); }
.post-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.post-cover::after { content: ""; position: absolute; inset: 0; background-image: repeating-linear-gradient(to right, transparent, transparent calc(12.5% - 1px), rgba(255,255,255,0.06) calc(12.5% - 1px), rgba(255,255,255,0.06) 12.5%); pointer-events: none; }
.post-cover .cover-tag { position: absolute; top: 22px; left: 0; right: 0; }
.post-cover .cover-tag span { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--paper); background: rgba(22,24,29,0.4); backdrop-filter: blur(4px); padding: 7px 13px; }
.post-cover .cover-big { position: absolute; right: -6px; bottom: -34px; font-family: var(--serif); font-weight: 600; font-size: clamp(140px, 21vw, 250px); line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(255,255,255,0.16); pointer-events: none; user-select: none; }
.post-cover .cover-tag .wrap, .post-cover .cover-big { z-index: 2; }
@media (max-width: 700px) { .post-cover { aspect-ratio: 16 / 10; } .post-cover .cover-big { font-size: 120px; } }

/* ---- Diagrammes (beaux et utiles, sans photo) ---- */
.diagram { border: 1px solid var(--rule-strong); background: var(--paper-2); padding: 24px 24px 20px; margin: 32px 0; }
.diagram-cap { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 16px; }
.diagram-intro { font-size: 0.92rem; color: var(--ink-soft); margin: 0 0 16px; }
.clause-flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.clause-cell { border: 1px solid var(--rule); background: var(--paper); padding: 13px 14px; transition: border-color 0.2s ease; }
.clause-cell:hover { border-color: var(--accent); }
.clause-cell .n { font-family: var(--mono); font-size: 0.82rem; color: var(--accent); display: block; }
.clause-cell .t { font-family: var(--serif); font-size: 0.95rem; line-height: 1.2; display: block; margin-top: 5px; }
.diagram-note { margin: 14px 0 0; font-size: 0.8rem; color: var(--muted); }
@media (max-width: 640px) { .clause-flow { grid-template-columns: repeat(2, 1fr); } }

/* =================================================================
   ANIMATIONS (sobres, une seule entrée orchestrée)
   ================================================================= */
@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.reveal { opacity: 0; animation: rise 0.7s cubic-bezier(0.2, 0.6, 0.2, 1) forwards; }
.d1 { animation-delay: 0.05s; } .d2 { animation-delay: 0.15s; }
.d3 { animation-delay: 0.25s; } .d4 { animation-delay: 0.35s; } .d5 { animation-delay: 0.45s; }
/* Révélations au défilement (page d'accueil).
   Masquage conditionné à la classe .js : sans JavaScript, le contenu reste visible. */
.js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.7s cubic-bezier(0.2,0.6,0.2,1), transform 0.7s cubic-bezier(0.2,0.6,0.2,1); }
[data-reveal].in { opacity: 1; transform: none; }
[data-reveal][data-delay="1"] { transition-delay: 0.08s; }
[data-reveal][data-delay="2"] { transition-delay: 0.16s; }
[data-reveal][data-delay="3"] { transition-delay: 0.24s; }
[data-reveal][data-delay="4"] { transition-delay: 0.32s; }

/* En-tête : ombre fine au défilement */
.site-header { transition: box-shadow 0.3s ease; }
.site-header.scrolled { box-shadow: 0 10px 30px rgba(22,24,29,0.07); }

/* Survols : légère élévation */
.pillar, .term, .related a { transition: background 0.25s ease, transform 0.3s cubic-bezier(0.2,0.6,0.2,1), box-shadow 0.3s ease, border-color 0.25s ease; }
.pillar:hover, .term:hover, .related a:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(22,24,29,0.08); }

/* Barre de progression de lecture (pages d'article) */
#progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; z-index: 100; will-change: transform; }

/* Sommaire qui suit la lecture */
.toc a.active { color: var(--accent); font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none; opacity: 1; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .pillar:hover, .term:hover, .related a:hover { transform: none; }
  html { scroll-behavior: auto; }
}

/* =================================================================
   RESPONSIVE
   ================================================================= */
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .spine { order: 2; }
  .pillars { grid-template-columns: 1fr; }
  .pillar { border-right: 0 !important; }
  .pillar:nth-last-child(-n+2) { border-bottom: 1px solid var(--rule); }
  .pillar:last-child { border-bottom: 0; }
  .value-grid, .glossary-grid { grid-template-columns: 1fr; gap: 26px; }
  .resources { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  .nav { display: none; }
  .nav.open {
    display: flex; flex-direction: column; gap: 0;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--paper); border-bottom: 1px solid var(--rule);
    padding: 8px var(--gutter) 16px;
  }
  .nav.open a { padding: 12px 0; border-bottom: 1px solid var(--rule); }
  .menu-toggle {
    display: inline-flex; background: none; border: 1px solid var(--rule-strong);
    font-family: var(--mono); font-size: 0.8rem; padding: 7px 12px; cursor: pointer; color: var(--ink);
  }
  .author { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}
