/* style.css — Feuille de style globale et premium */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

:root {
  /* HSL Color System */
  --primary-h: 146;
  --primary-s: 48%;
  
  /* Thème Clair par défaut */
  --bg: #f7f9f7;
  --bg-card: #ffffff;
  --text: #131715;
  --text-muted: #3c4940;
  --text-faint: #6c7c72;
  --accent: #22c55e;
  --accent-deep: #166534;
  --accent-wash: #f0fdf4;
  --earth: #a85507;
  --earth-wash: #fef3c7;
  --line: #e2e8f0;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.08);
  --max-w: 800px;
}

/* Thème Sombre */
[data-theme="dark"] {
  --bg: #0b0f0c;
  --bg-card: #121814;
  --text: #f0f4f1;
  --text-muted: #9bb0a2;
  --text-faint: #63776a;
  --accent: #22c55e;
  --accent-deep: #4ade80;
  --accent-wash: rgba(34, 197, 94, 0.08);
  --earth: #f59e0b;
  --earth-wash: rgba(245, 158, 11, 0.08);
  --line: #1c2620;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
}

/* Réinitialisation et Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  transition: background-color 0.3s ease;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.75;
  font-size: 16.5px;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Barre de défilement personnalisée */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg);
}
::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 99px;
  border: 2px solid var(--bg);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-faint);
}

/* Mise en page */
.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 28px;
}

/* En-tête collant (Glassmorphism) */
header.site {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
  position: sticky;
  top: 0;
  background: rgba(247, 249, 247, 0.85);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  z-index: 100;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
[data-theme="dark"] header.site {
  background: rgba(11, 15, 12, 0.85);
}

header.site .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.brand {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  letter-spacing: .02em;
  font-size: 17px;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text);
  transition: color 0.2s;
}
.brand span {
  color: var(--accent);
}

nav {
  display: flex;
  align-items: center;
  gap: 20px;
}
nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s, transform 0.2s;
}
nav a:hover {
  color: var(--accent);
}

/* Commutateur de thème */
.theme-toggle-btn {
  background: none;
  border: 1px solid var(--line);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s, background-color 0.2s, border-color 0.2s, transform 0.2s;
}
.theme-toggle-btn:hover {
  background-color: var(--accent-wash);
  color: var(--accent);
  border-color: var(--accent);
  transform: scale(1.05);
}
.theme-toggle-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Sections */
section {
  padding: 80px 0;
  border-bottom: 1px solid var(--line);
  transition: border-color 0.3s ease;
}

/* Typographie */
h1 {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(36px, 6vw, 56px);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -.03em;
  color: var(--text);
}

h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -.01em;
  margin-bottom: 22px;
  line-height: 1.25;
  color: var(--text);
}

h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 19px;
  font-weight: 700;
  margin: 36px 0 12px;
  color: var(--text);
}

p {
  color: var(--text-muted);
  margin-bottom: 20px;
  max-width: 720px;
}
p strong {
  color: var(--text);
}

/* Boutons / Liens */
a.accent-link {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1.5px solid var(--accent);
  transition: color 0.2s, border-color 0.2s;
}
a.accent-link:hover {
  color: var(--accent);
  border-color: var(--accent-light);
}

/* Hero Section */
.hero {
  padding: 100px 0 70px;
  border-bottom: 1px solid var(--line);
}
.kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 99px;
  padding: 6px 18px;
  margin-bottom: 28px;
  background-color: var(--accent-wash);
}
.hero p.lead {
  margin-top: 24px;
  font-size: 21px;
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 680px;
}

/* Fact Grid */
.factgrid {
  margin-top: 44px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 16px;
}
.factgrid div {
  background-color: var(--bg-card);
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.factgrid div:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
}
.factgrid dt {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.factgrid dd {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-top: 6px;
}

/* Citations */
blockquote {
  border-left: 4px solid var(--accent);
  background: var(--accent-wash);
  padding: 28px 32px;
  margin: 36px 0;
  border-radius: 0 16px 16px 0;
  font-size: 19px;
  line-height: 1.65;
  color: var(--accent-deep);
  font-style: italic;
  box-shadow: var(--shadow);
}
blockquote cite {
  display: block;
  margin-top: 14px;
  font-size: 14px;
  font-style: normal;
  color: var(--text-faint);
  font-weight: 500;
}

/* Listes de vision */
ul.vision {
  list-style: none;
  margin-top: 28px;
  display: grid;
  gap: 16px;
}
ul.vision li {
  background-color: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px 24px;
  color: var(--text-muted);
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
ul.vision li:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
}
ul.vision li::before {
  content: "→ ";
  color: var(--accent);
  font-weight: 800;
  margin-right: 8px;
}

/* Liens en capsules */
.links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}
.links a {
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  border: 1.5px solid var(--line);
  border-radius: 99px;
  padding: 10px 24px;
  background-color: var(--bg-card);
  box-shadow: var(--shadow);
  transition: all 0.2s ease;
}
.links a:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

/* FAQ Details */
/* FAQ Accordion Hardware-Accelerated (Style Apple & Fable) */
details.faq {
  border: 1px solid var(--line);
  border-radius: 16px;
  background-color: var(--bg-card);
  margin-bottom: 16px;
  max-width: 100%;
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
details.faq:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-hover);
}
details.faq summary {
  cursor: pointer;
  padding: 20px 24px;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: var(--text);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  outline: none;
}
details.faq summary::-webkit-details-marker {
  display: none;
}
details.faq summary::after {
  content: "";
  width: 16px;
  height: 16px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2322c55e' stroke-width='3'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19.5 8.25l-7.5 7.5-7.5-7.5'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  opacity: 0.8;
}
details.faq[open] summary::after {
  transform: rotate(180deg);
}
details.faq .faq-content {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
details.faq[open] .faq-content {
  grid-template-rows: 1fr;
}
details.faq .faq-inner {
  overflow: hidden;
  padding: 0 24px 20px;
  color: var(--text-muted);
  font-size: 15.5px;
  line-height: 1.6;
}

/* Chronologie (stablex.html) */
.tl {
  position: relative;
  margin-left: 12px;
  padding-left: 38px;
  border-left: 2px solid var(--line);
}
.tl-item {
  position: relative;
  padding-bottom: 40px;
}
.tl-item:last-child {
  padding-bottom: 0;
}
.tl-item::before {
  content: "";
  position: absolute;
  left: -47px;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--bg);
  border: 3.5px solid var(--accent);
  transition: background-color 0.3s, border-color 0.3s;
}
.tl-item.major::before {
  background: var(--accent);
}
.tl-date {
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--earth);
  background-color: var(--earth-wash);
  display: inline-block;
  padding: 2px 10px;
  border-radius: 4px;
  margin-bottom: 8px;
}
.tl-item h3 {
  font-size: 19px;
  font-weight: 700;
  margin: 4px 0 10px;
  line-height: 1.35;
}
.tl-item p {
  color: var(--text-muted);
  font-size: 15.5px;
  max-width: 660px;
}
.tl-item a {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  transition: color 0.2s, border-color 0.2s;
}
.tl-item a:hover {
  color: var(--accent);
  border-color: var(--accent-light);
}

/* Chiffres clés (stablex.html) */
.keyfacts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 14px;
}
.keyfacts div {
  background-color: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.keyfacts div:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
}
.keyfacts .num {
  font-family: 'Outfit', sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.1;
}
.keyfacts .lbl {
  font-size: 14px;
  color: var(--text-faint);
  margin-top: 8px;
  line-height: 1.45;
}

/* Boîte de copie (presse.html) */
.copybox {
  background-color: var(--bg-card);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 0 12px 12px 0;
  padding: 24px 28px;
  margin: 24px 0;
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--text);
  box-shadow: var(--shadow);
  transition: border-color 0.3s;
}
.copybox .label {
  font-family: 'Outfit', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--earth);
  display: block;
  margin-bottom: 12px;
}

/* Liste des sources (presse.html) */
ul.srcs {
  list-style: none;
  margin: 20px 0;
}
ul.srcs li {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  transition: border-color 0.3s;
}
ul.srcs li:last-child {
  border-bottom: none;
}
ul.srcs .tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  background: var(--accent-wash);
  color: var(--accent-deep);
  border-radius: 4px;
  padding: 3px 10px;
  margin-right: 12px;
  vertical-align: middle;
}
ul.srcs a {
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s;
  vertical-align: middle;
}
ul.srcs a:hover {
  color: var(--accent);
  text-decoration: underline;
}
ul.srcs .meta {
  display: block;
  font-size: 13.5px;
  color: var(--text-faint);
  margin-top: 6px;
  padding-left: 0;
}

/* Notes */
.note {
  background-color: var(--accent-wash);
  border-radius: 12px;
  padding: 20px 24px;
  font-size: 14.5px;
  color: var(--accent-deep);
  margin-top: 24px;
  border: 1px solid rgba(34, 197, 94, 0.15);
}

/* Tables */
table.dist, table.facts {
  width: 100%;
  border-collapse: collapse;
  margin: 28px 0;
  font-size: 15.5px;
}
table.dist th {
  font-family: 'Outfit', sans-serif;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding: 14px 18px;
  border-bottom: 2px solid var(--accent);
}
table.dist td, table.facts td {
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--text-muted);
  vertical-align: top;
  transition: border-color 0.3s;
}
table.dist td:first-child {
  font-weight: 700;
  color: var(--earth);
  white-space: nowrap;
}
table.facts td:first-child {
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  width: 220px;
}
table.facts a {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
}
table.facts a:hover {
  color: var(--accent);
}

/* Pied de page */
footer {
  padding: 60px 0 80px;
  font-size: 14px;
  color: var(--text-faint);
  border-top: 1px solid var(--line);
  transition: border-color 0.3s;
}
footer .wrap {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}
footer a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
footer a:hover {
  color: var(--accent);
}

/* Note de source en bas */
.srcnote {
  font-size: 13.5px;
  color: var(--text-faint);
  margin-top: 28px;
  max-width: 720px;
}
.srcnote a {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
}
.srcnote a:hover {
  color: var(--accent);
}

/* Animations de chargement et défilement (Scroll Reveal) */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Version mobile de la navigation */
@media (max-width: 640px) {
  nav {
    gap: 12px;
  }
  nav a {
    font-size: 13px;
  }
  .hero {
    padding: 70px 0 50px;
  }
  section {
    padding: 56px 0;
  }
  table.facts td:first-child {
    width: auto;
    display: block;
    padding-bottom: 4px;
  }
  table.facts td {
    display: block;
    padding: 10px 0;
  }
  footer .wrap {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
  }
}

/* Styles spécifiques pour la page 404 */
.card-404 {
  max-width: 560px;
  text-align: center;
}
.leaf {
  width: 88px;
  height: 88px;
  margin: 0 auto 32px;
  border-radius: 50%;
  background: var(--accent-wash);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
}
.leaf svg {
  stroke: var(--accent);
}
.code {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--earth);
  margin-bottom: 14px;
}
.actions-404 {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  margin-top: 24px;
}
.btn {
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  border-radius: 99px;
  padding: 13px 28px;
  box-shadow: var(--shadow);
  transition: all 0.2s ease;
}
.btn-primary {
  background: var(--accent);
  color: #ffffff;
  border: 1.5px solid var(--accent);
}
.btn-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}
.btn-ghost {
  color: var(--accent-deep);
  border: 1.5px solid var(--accent);
  background: transparent;
}
.btn-ghost:hover {
  background: var(--accent-wash);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}
.shortcuts {
  margin-top: 52px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  justify-content: center;
  font-size: 14px;
}
.shortcuts a {
  color: var(--text-faint);
  text-decoration: none;
  transition: color 0.2s;
}
.shortcuts a:hover {
  color: var(--accent);
}
@media (max-width: 480px) {
  .actions-404 {
    flex-direction: column;
  }
  .btn {
    width: 100%;
  }
}

/* ==========================================
   REFONTE ESTHÉTIQUE & INTERACTIVE (NIVEAU ENFER)
   ========================================== */

/* Hero Immersive */
.hero-immersive {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: linear-gradient(to bottom, rgba(11, 15, 12, 0.4) 0%, rgba(11, 15, 12, 0.85) 100%), url('tourbiere.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: scroll;
  color: #ffffff;
  padding: 100px 0;
  text-align: center;
  overflow: hidden;
  border-bottom: 2px solid var(--accent);
  transition: border-color 0.3s;
}

[data-theme="dark"] .hero-immersive {
  background-image: linear-gradient(to bottom, rgba(11, 15, 12, 0.5) 0%, rgba(11, 15, 12, 0.95) 100%), url('tourbiere.jpg');
}

.hero-immersive .wrap {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
}

.hero-immersive h1 {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(38px, 6.5vw, 68px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #ffffff;
  line-height: 1.1;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.hero-immersive .kicker {
  background-color: rgba(34, 197, 94, 0.25);
  color: #4ade80;
  border-color: #4ade80;
  backdrop-filter: blur(4px);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 0;
}

.hero-immersive p.lead {
  font-size: clamp(17px, 2.2vw, 22px);
  line-height: 1.55;
  color: rgba(240, 244, 241, 0.95);
  max-width: 700px;
  margin: 0 auto;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.citation-hero {
  border-left: none;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.2);
  backdrop-filter: blur(10px);
  padding: 24px 30px;
  margin: 16px 0 24px;
  border-radius: 16px;
  max-width: 680px;
  color: #ffffff;
  box-shadow: var(--shadow-hover);
  animation: pulse-glow 4s infinite alternate;
}

@keyframes pulse-glow {
  0% { box-shadow: 0 4px 15px rgba(34, 197, 94, 0.15); }
  100% { box-shadow: 0 4px 30px rgba(34, 197, 94, 0.3); }
}

.citation-hero p {
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 700;
  line-height: 1.4;
  color: #ffffff !important;
  font-family: 'Outfit', sans-serif;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0,0,0,0.4);
}

.citation-hero cite {
  display: block;
  margin-top: 10px;
  font-size: 13.5px;
  color: rgba(255,255,255,0.7);
  font-style: normal;
}

/* Scroll indicator mouse */
.scroll-indicator {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: color 0.3s;
}

.scroll-indicator:hover {
  color: #4ade80;
}

.scroll-mouse {
  width: 24px;
  height: 38px;
  border: 2px solid currentColor;
  border-radius: 20px;
  position: relative;
}

.scroll-wheel {
  width: 4px;
  height: 7px;
  background-color: currentColor;
  border-radius: 2px;
  position: absolute;
  top: 7px;
  left: 50%;
  transform: translateX(-50%);
  animation: scroll-wheel-anim 1.6s infinite;
}

@keyframes scroll-wheel-anim {
  0% { opacity: 1; top: 7px; }
  50% { opacity: 0.3; top: 16px; }
  100% { opacity: 0; top: 16px; }
}

/* Dashboard / Live Tracker */
.tracker-section {
  padding: 80px 0 60px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--line);
  position: relative;
  transition: background-color 0.3s, border-color 0.3s;
}

.tracker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin-top: 32px;
}

.tracker-card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 30px 24px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.tracker-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
}

.tracker-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--accent-wash);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.tracker-card .counter-num {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(30px, 4.5vw, 40px);
  font-weight: 800;
  color: var(--accent);
  line-height: 1.1;
  margin-bottom: 8px;
}

.tracker-card .counter-lbl {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text);
  margin-bottom: 6px;
}

.tracker-card .counter-desc {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.45;
}

/* Timeline Awards (Distinctions) */
.timeline-awards {
  list-style: none;
  margin: 32px 0;
  position: relative;
  padding-left: 24px;
}

.timeline-awards::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--line);
}

.timeline-awards li {
  position: relative;
  padding-bottom: 32px;
  padding-left: 16px;
}

.timeline-awards li:last-child {
  padding-bottom: 0;
}

.timeline-awards li::before {
  content: "";
  position: absolute;
  left: -29px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  border: 3px solid var(--accent);
  box-shadow: 0 0 0 4px var(--bg);
  z-index: 2;
  transition: background-color 0.3s, transform 0.3s;
}

.timeline-awards li:hover::before {
  background: var(--accent);
  transform: scale(1.2);
}

.timeline-awards .year {
  display: inline-block;
  font-family: 'Outfit', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--earth);
  background: var(--earth-wash);
  padding: 3px 10px;
  border-radius: 99px;
  margin-bottom: 8px;
}

.timeline-awards strong {
  display: block;
  font-family: 'Outfit', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.timeline-awards p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

/* Cartes Documents */
.docs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.doc-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: transform 0.3s, box-shadow 0.3s;
}

.doc-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.doc-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--earth-wash);
  color: var(--earth);
  display: flex;
  align-items: center;
  justify-content: center;
}

.doc-info h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 16.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.doc-info p {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

.doc-card button.btn-open-doc {
  background: var(--accent-wash);
  color: var(--accent-deep);
  border: 1.5px solid var(--accent);
  padding: 10px 18px;
  border-radius: 99px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  text-align: center;
  margin-top: auto;
  transition: all 0.2s;
}

.doc-card button.btn-open-doc:hover {
  background: var(--accent);
  color: #ffffff;
}

/* Modaux <dialog> (Style Apple avec transition) */
dialog.doc-dialog {
  border: none;
  border-radius: 24px;
  background: var(--bg-card);
  color: var(--text);
  max-width: 680px;
  width: 90%;
  padding: 32px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.25);
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -35%) scale(0.95);
  opacity: 0;
  z-index: 1000;
  outline: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), overlay 0.4s allow-discrete, display 0.4s allow-discrete;
}

dialog.doc-dialog[open] {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

@starting-style {
  dialog.doc-dialog[open] {
    opacity: 0;
    transform: translate(-50%, -35%) scale(0.95);
  }
}

dialog.doc-dialog::backdrop {
  background: rgba(11, 15, 12, 0);
  backdrop-filter: blur(0px);
  transition: background-color 0.4s cubic-bezier(0.16, 1, 0.3, 1), backdrop-filter 0.4s cubic-bezier(0.16, 1, 0.3, 1), overlay 0.4s allow-discrete, display 0.4s allow-discrete;
}

dialog.doc-dialog[open]::backdrop {
  background: rgba(11, 15, 12, 0.6);
  backdrop-filter: blur(12px);
}

@starting-style {
  dialog.doc-dialog[open]::backdrop {
    background: rgba(11, 15, 12, 0);
    backdrop-filter: blur(0px);
  }
}

.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 16px;
}

.dialog-header h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.25;
  margin: 0;
}

.dialog-close {
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.dialog-close:hover {
  color: var(--text);
  background: var(--line);
}

.dialog-body {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.dialog-body iframe {
  width: 100%;
  height: 350px;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-top: 16px;
}

.dialog-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

/* Menu Mobile Responsif (Style Apple avec transitions SVG) */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: background-color 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.menu-toggle:hover {
  background-color: var(--accent-wash);
}
.menu-toggle svg {
  display: block;
}
.menu-toggle svg line {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  transform-origin: center;
}
.menu-toggle.active .line-1 {
  transform: translateY(6px) rotate(45deg);
}
.menu-toggle.active .line-2 {
  opacity: 0;
  transform: scaleX(0);
}
.menu-toggle.active .line-3 {
  transform: translateY(-6px) rotate(-45deg);
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
  
  header.site .wrap {
    position: relative;
  }
  
  nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-bottom: 1.5px solid var(--accent);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 999;
    border-radius: 0 0 16px 16px;
  }
  
  nav.active {
    display: flex;
    animation: slideDown 0.3s ease-out forwards;
  }
  
  @keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
  }
  
  nav a {
    margin-left: 0;
    font-size: 16px;
    font-weight: 600;
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
    text-align: center;
  }
  
  nav a:last-child {
    border-bottom: none;
  }
  
  nav .theme-btn {
    width: auto;
    margin: 10px auto 0;
  }
}

/* ==========================================
   AMBIANCE VISUELLE & EFFETS SUR SCROLL (STYLE FABLE)
   ========================================== */

/* Blobs d'arrière-plan */
.bg-blob-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -2;
  overflow: hidden;
}

.bg-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(130px);
  opacity: 0.08;
  animation: float-blob 22s infinite alternate ease-in-out;
  transition: opacity 0.5s ease;
}

[data-theme="dark"] .bg-blob {
  opacity: 0.05;
}

.blob-1 {
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background-color: var(--accent);
  animation-duration: 28s;
}

.blob-2 {
  bottom: -15%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background-color: var(--earth);
  animation-duration: 34s;
  animation-delay: -6s;
}

.blob-3 {
  top: 35%;
  left: 55%;
  width: 42vw;
  height: 42vw;
  background-color: var(--accent-deep);
  animation-duration: 25s;
  animation-delay: -12s;
}

@keyframes float-blob {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33% { transform: translate(4vw, 8vh) scale(1.08) rotate(120deg); }
  66% { transform: translate(-4vw, 4vh) scale(0.96) rotate(240deg); }
  100% { transform: translate(0, 0) scale(1) rotate(360deg); }
}

/* Barre de progression de défilement */
.scroll-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3.5px;
  background: linear-gradient(to right, var(--earth), var(--accent));
  z-index: 10000;
  transition: width 0.1s linear;
  border-radius: 0 2px 2px 0;
}

/* Highlight Timeline Active */
.timeline-awards li,
ul.timeline li,
.tl-item {
  transition: opacity 0.5s ease;
}

.timeline-awards li.active-node::before,
ul.timeline li.active-node::before,
.tl-item.active-node::before {
  background-color: var(--accent) !important;
  box-shadow: 0 0 0 6px var(--bg), 0 0 16px var(--accent) !important;
  transform: scale(1.25) !important;
  border-color: var(--accent) !important;
}

.timeline-awards li.active-node strong,
ul.timeline li.active-node strong,
.tl-item.active-node h3 {
  color: var(--accent-deep) !important;
  transition: color 0.3s ease;
}
