:root {
  /* Couleurs */
  --ivoire: #FAF7F2;
  --parchemin: #F0EBE3;
  --pierre: #C4B8A0;
  --encre: #1A2635;
  --vermillon: #C94040;
  --or: #D4A84B;

  /* Dérivées opacité */
  --encre-80: rgba(26, 38, 53, 0.80);
  --encre-65: rgba(26, 38, 53, 0.65);
  --encre-40: rgba(26, 38, 53, 0.40);
  --encre-20: rgba(26, 38, 53, 0.20);
  --encre-10: rgba(26, 38, 53, 0.10);
  --encre-06: rgba(26, 38, 53, 0.06);
  --ivoire-95: rgba(250, 247, 242, 0.95);
  --ivoire-75: rgba(250, 247, 242, 0.75);
  --ivoire-40: rgba(250, 247, 242, 0.40);

  /* Polices */
  --ff-display: 'Playfair Display', Georgia, serif;
  --ff-body: 'Source Serif 4', 'Georgia', serif;
  --ff-accent: 'Cormorant Garamond', Georgia, serif;

  /* Mesures */
  --measure-article: 680px;
  --measure-wide: 1280px;
  --measure-hero: 1440px;
  --gutter: clamp(1rem, 4vw, 2rem);

  /* Transitions */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 300ms;
  --dur: 500ms;
  --dur-slow: 700ms;
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* Reset anti-distorsion OBLIGATOIRE (REGLE CODEX 14) */
img { max-width: 100%; height: auto; display: block; }

body {
  font-family: var(--ff-body);
  background: var(--ivoire);
  color: var(--encre);
  line-height: 1.7;
  font-size: 1.0625rem;
}

/* ===== WRAPPERS ANTI-DISTORSION ===== */
.img-hero     { width: 100%; height: clamp(280px, 35vw, 520px); overflow: hidden; }
.img-card     { aspect-ratio: 3/2;  overflow: hidden; }
.img-body     { aspect-ratio: 3/2;  overflow: hidden; }
.img-portrait { aspect-ratio: 1/1;  overflow: hidden; border-radius: 50%; }
.img-hero img, .img-card img, .img-body img, .img-portrait img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
}

/* ===== TYPOGRAPHIE ===== */
h1, h2, h3, h4 {
  font-family: var(--ff-display);
  color: var(--encre);
  line-height: 1.2;
}
h1 { font-size: clamp(1.75rem, 4vw, 3rem); font-weight: 700; }
h2 { font-size: clamp(1.35rem, 2.5vw, 2rem); font-weight: 600; }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); font-weight: 600; }

a { color: var(--vermillon); text-decoration: none; }
a:hover { text-decoration: underline; }

p { margin-bottom: 1.25rem; }

/* ===== LAYOUT ===== */
.container {
  max-width: var(--measure-wide);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ===== KICKER ===== */
.kicker {
  font-family: var(--ff-body);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--vermillon);
  font-weight: 600;
  display: block;
  margin-bottom: 0.5rem;
}

/* ===== PULL QUOTE ===== */
.pull-quote {
  border-left: 3px solid var(--vermillon);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-family: var(--ff-accent);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--encre-80);
}

/* ===== ARTICLE BODY ===== */
.article-body h2 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  position: relative;
}
.article-body h2::after {
  content: '';
  display: block;
  height: 2px;
  background: var(--vermillon);
  width: 0;
  transition: width var(--dur) var(--ease);
  margin-top: 0.4rem;
}
.article-body h2:hover::after,
.article-body h2.visible::after { width: 3rem; }

.article-body h3 {
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
}

/* Lettrine premier paragraphe */
.article-body > p:first-of-type::first-letter {
  font-family: var(--ff-display);
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--vermillon);
  float: left;
  line-height: 0.85;
  margin-right: 0.1em;
  margin-top: 0.05em;
}

.article-body ul, .article-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1.25rem;
}
.article-body li { margin-bottom: 0.4rem; }

/* ===== HEADER ===== */
.site-header {
  background: var(--ivoire-95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--encre-10);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  padding-bottom: 1rem;
  gap: 1rem;
}
.site-logo {
  font-family: var(--ff-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--encre);
  text-decoration: none;
}
.site-logo span { color: var(--vermillon); }

.site-nav {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  align-items: center;
}
.site-nav a {
  font-family: var(--ff-body);
  font-size: 0.875rem;
  letter-spacing: 0.04em;
  color: var(--encre);
  font-weight: 600;
  transition: color var(--dur-fast);
}
.site-nav a:hover { color: var(--vermillon); text-decoration: none; }

/* ===== FOOTER ===== */
.site-footer {
  background: var(--encre);
  color: var(--ivoire-75);
  padding: 3rem 0 1.5rem;
  margin-top: 4rem;
  font-size: 0.9rem;
}
.site-footer .footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}
.site-footer h4 {
  font-family: var(--ff-body);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--pierre);
  margin-bottom: 1rem;
}
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 0.4rem; }
.site-footer a { color: var(--ivoire-75); }
.site-footer a:hover { color: var(--ivoire); }
.site-footer .footer-bottom {
  border-top: 1px solid rgba(250,247,242,0.15);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--pierre);
}
.site-footer .brand-text {
  font-family: var(--ff-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ivoire);
  margin-bottom: 0.5rem;
}
.site-footer .brand-tagline {
  font-family: var(--ff-accent);
  font-style: italic;
  color: var(--pierre);
  font-size: 0.95rem;
}

/* ===== HERO ===== */
.hero-full {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--encre);
}
.hero-full .hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0.45;
}
.hero-full .hero-content {
  position: relative;
  z-index: 2;
  max-width: 780px;
  padding: 4rem var(--gutter);
}
.hero-full h1 { color: var(--ivoire); margin-bottom: 1rem; }
.hero-full .hero-sub {
  font-family: var(--ff-accent);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--ivoire-75);
  margin-bottom: 2rem;
  max-width: 560px;
}
.hero-full .scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ivoire-75);
}

/* ===== HERO PAGE (pas full-screen) ===== */
.hero-page {
  background: var(--parchemin);
  padding: 4rem var(--gutter) 3rem;
  border-bottom: 1px solid var(--encre-10);
}
.hero-page h1 { margin-bottom: 0.75rem; }
.hero-page .summary {
  font-family: var(--ff-accent);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--encre-80);
  max-width: 660px;
  line-height: 1.8;
}

/* ===== GUIDE CARDS ===== */
.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}
.guide-card {
  position: relative;
  overflow: hidden;
  background: var(--ivoire);
  border: 1px solid var(--encre-10);
  border-radius: 2px;
  padding: 1.75rem 1.5rem;
  transition: transform var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
  text-decoration: none;
  color: var(--encre);
  display: block;
}
.guide-card[data-n]::before {
  content: attr(data-n);
  position: absolute;
  right: -0.2em;
  bottom: -0.2em;
  font-family: var(--ff-display);
  font-size: 8rem;
  font-weight: 700;
  color: var(--pierre);
  opacity: 0.3;
  line-height: 1;
  pointer-events: none;
}
.guide-card:hover {
  transform: translateY(-3px);
  border-left: 3px solid var(--vermillon);
  box-shadow: 0 8px 24px var(--encre-10);
  text-decoration: none;
}
.guide-card .guide-cat {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--vermillon);
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-family: var(--ff-body);
}
.guide-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.3;
}

/* ===== BLOG CARDS ===== */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}
.blog-card {
  background: var(--ivoire);
  border: 1px solid var(--encre-10);
  border-radius: 2px;
  overflow: hidden;
  transition: transform var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
  text-decoration: none;
  color: var(--encre);
  display: block;
}
.blog-card:hover {
  transform: translateY(-3px);
  border-left: 3px solid var(--vermillon);
  box-shadow: 0 8px 24px var(--encre-10);
  text-decoration: none;
}
.blog-card .blog-card-body { padding: 1.25rem 1.25rem 1.5rem; }
.blog-card .blog-card-cat {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--vermillon);
  font-weight: 600;
  margin-bottom: 0.4rem;
  font-family: var(--ff-body);
}
.blog-card h3 { font-size: 1rem; font-weight: 600; line-height: 1.35; margin-bottom: 0.5rem; }
.blog-card .blog-card-date {
  font-size: 0.8rem;
  color: var(--encre-40);
  font-family: var(--ff-body);
}

/* ===== FAQ ===== */
.faq-section { margin: 3rem 0; }
.faq-section h2 { margin-bottom: 1.5rem; }
.faq-item {
  border-bottom: 1px solid var(--encre-10);
  padding: 1rem 0;
}
.faq-item summary {
  font-family: var(--ff-display);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 1.25rem;
  color: var(--vermillon);
  flex-shrink: 0;
}
.faq-item[open] summary::after { content: '−'; }
.faq-item .faq-answer {
  padding: 1rem 0 0.5rem;
  color: var(--encre-80);
  line-height: 1.7;
}

/* ===== SECTIONS ===== */
.section { padding: 4rem 0; }
.section-alt { background: var(--parchemin); }
.section-dark {
  background: var(--encre);
  color: var(--ivoire);
}
.section-dark h2, .section-dark h3 { color: var(--ivoire); }
.section-title {
  font-family: var(--ff-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.section-sub {
  font-family: var(--ff-accent);
  font-style: italic;
  color: var(--encre-65);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  font-family: var(--ff-body);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 1px;
  transition: background var(--dur-fast), color var(--dur-fast);
  text-decoration: none;
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: var(--vermillon);
  color: var(--ivoire);
}
.btn-primary:hover { background: #a83030; color: var(--ivoire); text-decoration: none; }
.btn-outline {
  background: transparent;
  color: var(--ivoire);
  border: 2px solid var(--ivoire);
}
.btn-outline:hover { background: var(--ivoire); color: var(--encre); text-decoration: none; }

/* ===== BREADCRUMB ===== */
.breadcrumb {
  font-size: 0.8rem;
  color: var(--encre-40);
  padding: 0.75rem 0;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.breadcrumb a { color: var(--encre-40); }
.breadcrumb a:hover { color: var(--vermillon); }
.breadcrumb span::before { content: '›'; margin-right: 0.5rem; }

/* ===== TOC ===== */
.toc-aside {
  background: var(--parchemin);
  border-left: 3px solid var(--vermillon);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  font-size: 0.9rem;
}
.toc-aside h4 {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--vermillon);
  margin-bottom: 0.75rem;
  font-family: var(--ff-body);
}
.toc-aside ol { padding-left: 1.25rem; }
.toc-aside li { margin-bottom: 0.3rem; }
.toc-aside li.toc-sub { padding-left: 1rem; font-size: 0.875em; list-style-type: none; }
.toc-aside li.toc-sub::before { content: '↳'; margin-right: 0.35rem; color: var(--pierre); }
.toc-aside a { color: var(--encre-80); }
.toc-aside a:hover { color: var(--vermillon); }

/* ===== IMMERSIVE SECTION ===== */
.section-immersive {
  position: relative;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  background: var(--encre);
}
.section-immersive .bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.35;
}
.section-immersive .content {
  position: relative;
  z-index: 2;
  color: var(--ivoire);
  padding: 3rem var(--gutter);
}
.section-immersive h2 { color: var(--ivoire); margin-bottom: 1.25rem; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .site-nav { display: none; }
  .guides-grid, .blog-grid { grid-template-columns: 1fr; }
  .site-footer .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-full { min-height: 70vh; }
}
@media (max-width: 480px) {
  .site-footer .footer-grid { grid-template-columns: 1fr; }
}
