/* ======================================================
   Ekin Frites — pages intérieures
   ------------------------------------------------------
   Complément de styles.css : ne redéfinit rien, n'ajoute
   que les composants propres aux pages Valeurs,
   Actualités, Article et pages légales.
   À charger APRÈS styles.css.
   Toutes les valeurs viennent des variables de la charte
   (--red, --gold, --ink, --cream…) définies dans styles.css.
   ====================================================== */

/* ---------- Fil d'Ariane ---------- */
.crumbs {
  position: relative; z-index: 10;
  background: var(--white);
  border-bottom: 1px solid #eee;
  font-size: .85rem;
  color: var(--grey);
}
.crumbs .container { display: flex; gap: 8px; align-items: center; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }
.crumbs a { color: var(--grey); border-bottom: 1px solid transparent; }
.crumbs a:hover { color: var(--ink); border-bottom-color: var(--gold); }
.crumbs span[aria-current] { color: var(--ink); font-weight: 600; }

/* ---------- Animations d'apparition (reveal.js) ---------- */
[data-reveal] { will-change: transform, opacity; }
.no-motion [data-reveal] { opacity: 1 !important; transform: none !important; }

/* ---------- Barre de progression de lecture ---------- */
.read-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px;
  z-index: 60; background: transparent; pointer-events: none;
}
.read-progress i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--gold), var(--red));
  transform-origin: 0 50%;
}

/* ---------- Chiffres clés ---------- */
.stats { position: relative; z-index: 10; background: var(--ink); color: var(--white); padding: 68px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; text-align: center; }
.stat b {
  display: block;
  font-family: var(--font-head); font-weight: 400;
  font-size: clamp(2.6rem, 6vw, 4.2rem); line-height: 1;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}
.stat span { display: block; margin-top: 10px; font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.66); }

/* ---------- Bloc texte + image ---------- */
.split { position: relative; z-index: 10; padding: 88px 0; background: var(--cream); }
.split.on-white { background: var(--white); }
.split-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 56px; align-items: center; }
.split-grid.reverse .split-media { order: 2; }
.split-media { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: #111; }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-text h2 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: clamp(2rem, 4vw, 3rem); }
.split-text p { color: var(--grey); }
.split-text .eyebrow { display: inline-block; margin-bottom: 14px; }

.eyebrow {
  font-size: .74rem; letter-spacing: .18em; text-transform: uppercase;
  font-weight: 700; color: var(--red);
}

/* ---------- Frise chronologique ---------- */
.timeline { position: relative; z-index: 10; padding: 88px 0; background: var(--white); }
.tl-list { position: relative; margin-top: 44px; padding-left: 34px; }
.tl-list::before {
  content: ""; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px;
  background: linear-gradient(180deg, var(--gold), rgba(253,165,0,.15));
}
.tl-item { position: relative; padding: 0 0 34px; }
.tl-item::before {
  content: ""; position: absolute; left: -34px; top: 8px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--white); border: 3px solid var(--red);
}
.tl-year { font-family: var(--font-head); font-size: 1.7rem; color: var(--red); line-height: 1; }
.tl-item h3 { font-size: 1.1rem; margin: 6px 0 4px; }
.tl-item p { margin: 0; color: var(--grey); font-size: .95rem; max-width: 62ch; }

/* ---------- Filiales du groupe ---------- */
.brands { position: relative; z-index: 10; padding: 88px 0; background: var(--cream); }
.brand-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; margin-top: 38px; }
.brand {
  display: block; background: var(--white); border: 1px solid #f0ece3;
  border-radius: var(--radius); padding: 28px 30px;
  box-shadow: 0 6px 22px rgba(17,17,17,.05);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.brand:hover { transform: translateY(-5px); box-shadow: 0 16px 38px rgba(17,17,17,.12); border-color: var(--gold); }
.brand .eyebrow { color: var(--gold); }
.brand h3 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: 1.7rem; margin: 8px 0 8px; }
.brand p { margin: 0 0 14px; color: var(--grey); font-size: .95rem; }
.brand .go { font-weight: 700; font-size: .9rem; border-bottom: 2px solid var(--gold); padding-bottom: 2px; }

/* ---------- Actualités : la une ---------- */
.featured { position: relative; z-index: 10; padding: 52px 0 0; background: var(--cream); }
.featured-card {
  display: grid; grid-template-columns: 1.15fr 1fr; gap: 0;
  background: var(--ink); color: var(--white);
  border-radius: var(--radius); overflow: hidden;
}
.featured-media { min-height: 340px; background: #111 center/cover no-repeat; }
.featured-body { padding: 44px 44px; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.featured-body h2 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: clamp(1.9rem, 3.4vw, 2.8rem); margin: 0; color: var(--white); }
.featured-body p { margin: 0; color: rgba(255,255,255,.72); }
.post-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.pill { background: var(--red); color: var(--white); padding: 4px 11px; border-radius: 999px; font-weight: 700; letter-spacing: .08em; }

/* ---------- Actualités : grille ---------- */
.news-list { position: relative; z-index: 10; padding: 44px 0 88px; background: var(--cream); }
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; }
.article-card {
  display: flex; flex-direction: column;
  background: var(--white); border: 1px solid #f0ece3; border-radius: var(--radius);
  overflow: hidden; box-shadow: 0 6px 22px rgba(17,17,17,.05);
  transition: transform .25s ease, box-shadow .25s ease;
}
.article-card:hover { transform: translateY(-5px); box-shadow: 0 16px 38px rgba(17,17,17,.12); }
.article-card .ac-media { height: 186px; background: #111 center/cover no-repeat; }
.article-card .ac-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.ac-meta { display: flex; gap: 10px; align-items: center; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); }
.ac-meta .pill { background: var(--gold); color: var(--ink); }
.article-card h3 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: 1.45rem; margin: 0; line-height: 1.05; }
.article-card p { margin: 0; color: var(--grey); font-size: .93rem; }
.article-card .go { margin-top: auto; font-weight: 700; font-size: .88rem; color: var(--red); }
.news-empty { color: var(--grey); padding: 40px 0; }

/* ---------- Article ---------- */
.article-hero { position: relative; z-index: 10; color: var(--white); text-align: center; padding: 96px 0 84px; }
.article-hero .post-meta { justify-content: center; margin-bottom: 16px; }
.article-hero h1 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: clamp(2.3rem, 5.4vw, 4rem); color: var(--white); max-width: 20ch; margin: 0 auto; text-wrap: balance; }

.article-body { position: relative; z-index: 10; background: var(--white); padding: 72px 0 84px; }
.article-body .container { max-width: 760px; }
.chapo { font-size: 1.2rem; line-height: 1.65; color: var(--ink); font-weight: 500; margin: 0 0 32px; }
.article-body h2 { font-family: var(--font-head); font-weight: 400; text-transform: uppercase; font-size: 1.9rem; margin: 44px 0 14px; }
.article-body h3 { font-size: 1.12rem; margin: 28px 0 8px; }
.article-body p { color: #34302a; margin: 0 0 18px; }
.article-body ul { color: #34302a; padding-left: 22px; margin: 0 0 20px; }
.article-body li { margin-bottom: 8px; }
.article-figure { margin: 34px 0; }
.article-figure img { width: 100%; border-radius: var(--radius); }
.article-figure figcaption { font-size: .85rem; color: var(--grey); margin-top: 10px; }
.pullquote {
  margin: 40px 0; padding: 26px 30px;
  border-left: 4px solid var(--red); background: var(--cream);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-family: var(--font-head); font-weight: 400; text-transform: uppercase;
  font-size: 1.55rem; line-height: 1.15;
}
.share { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 44px; padding-top: 26px; border-top: 1px solid #eee; font-size: .9rem; }
.share span { color: var(--grey); }
.share a { border: 1px solid #e5e0d6; border-radius: 999px; padding: 7px 15px; font-weight: 600; transition: border-color .18s ease, background .18s ease; }
.share a:hover { border-color: var(--ink); background: var(--cream); }

.related { position: relative; z-index: 10; background: var(--cream); padding: 72px 0 88px; }

/* ---------- Pages légales ---------- */
.legal { position: relative; z-index: 10; background: var(--white); padding: 64px 0 88px; }
.legal-grid { display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 52px; align-items: start; }
.toc { position: sticky; top: 100px; font-size: .9rem; }
.toc strong { display: block; font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--grey); margin-bottom: 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; counter-reset: toc; }
.toc a {
  display: block; padding: 7px 12px; border-radius: 8px;
  color: var(--grey); border-left: 2px solid transparent;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}
.toc a:hover { background: var(--cream); color: var(--ink); }
.toc a.is-current { color: var(--ink); font-weight: 600; border-left-color: var(--red); background: var(--cream); }

.legal-body { max-width: 72ch; }
.legal-body h2 {
  font-family: var(--font-head); font-weight: 400; text-transform: uppercase;
  font-size: 1.7rem; margin: 46px 0 12px; scroll-margin-top: 110px;
}
.legal-body h2:first-child { margin-top: 0; }
.legal-body p, .legal-body li { color: #34302a; }
.legal-body ul { padding-left: 22px; }
.legal-body li { margin-bottom: 7px; }
.legal-updated { color: var(--grey); font-size: .88rem; margin: 0 0 30px; }
.legal-table { width: 100%; border-collapse: collapse; margin: 16px 0 24px; font-size: .94rem; }
.legal-table th, .legal-table td { text-align: left; padding: 11px 14px; border-bottom: 1px solid #eee; vertical-align: top; }
.legal-table th { width: 34%; font-weight: 600; color: var(--ink); background: var(--cream); }
.legal-note { background: var(--cream); border-radius: var(--radius); padding: 18px 22px; font-size: .92rem; color: var(--grey); }

/* ---------- Liens légaux du pied de page ---------- */
.footer-legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; margin-top: 10px; font-size: .84rem; }
.footer-legal a { color: rgba(255,255,255,.6); }
.footer-legal a:hover { color: var(--gold); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 34px; }
  .split-grid { grid-template-columns: 1fr; gap: 30px; }
  .split-grid.reverse .split-media { order: 0; }
  .brand-grid { grid-template-columns: 1fr; }
  .featured-card { grid-template-columns: 1fr; }
  .featured-media { min-height: 220px; }
  .featured-body { padding: 30px 26px; }
  .news-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .legal-grid { grid-template-columns: 1fr; gap: 28px; }
  .toc { position: static; }
  .toc ol { grid-template-columns: repeat(2, 1fr); display: grid; }
}
@media (max-width: 620px) {
  .news-grid { grid-template-columns: 1fr; }
  .split, .timeline, .brands { padding: 60px 0; }
  .toc ol { grid-template-columns: 1fr; }
  .pullquote { font-size: 1.3rem; padding: 20px 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .brand:hover, .article-card:hover { transform: none; }
}

/* ---------- Page courante dans la navigation ---------- */
.nav a.is-current { color: var(--red); }
.nav a.is-current::after {
  content: ""; display: block; height: 2px; margin-top: 3px;
  background: var(--red);
}

/* ---------- Alignements repris de la charte ----------
   Dans styles.css, .section-title et .section-lead sont centrés :
   les surtitres qui les précèdent doivent l'être aussi. */
.timeline > .container > .eyebrow,
.brands > .container > .eyebrow,
.related > .container > .eyebrow {
  display: block; text-align: center; margin-bottom: 10px;
}
.brands > .container > .lead {
  text-align: center; max-width: 580px; margin: 0 auto;
}

/* Titre de la une : plus compact, il ne doit pas écraser la carte. */
.featured-body h2 { font-size: clamp(1.6rem, 2.6vw, 2.25rem); line-height: 1.02; }
.featured-media { min-height: 300px; }
.featured-body .btn { align-self: flex-start; margin-top: 6px; }

/* Ancres : ne pas passer sous l'en-tête collant. */
.legal-body h2, section[id] { scroll-margin-top: 110px; }
