/* ═══════════════════════════════════════════════════════════════
   on se lance — feuille de style
   Direction : moderne & chaleureux. Palette corail / crème.
   ═══════════════════════════════════════════════════════════════ */

/* ─── Polices auto-hébergées ──────────────────────────────────
   Déposer les .woff2 dans /assets/fonts/ (voir assets/fonts/README.md).
   Tant qu'ils sont absents, les piles de repli (Georgia / system-ui) prennent le relais. */
@font-face {
  font-family: "Fraunces";
  src: url("/assets/fonts/fraunces-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/inter-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/inter-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/inter-700.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}

:root {
  --bg:        #fbf6f1;
  --bg-warm:   #f6ebe1;
  --surface:   #ffffff;
  --fg:        #2c2320;
  --fg-soft:   #6a5b53;
  --fg-mute:   #9a887d;
  --rule:      #ecdcce;
  --accent:    #d0623f;
  --accent-soft:#f4e0d6;
  --accent-fg: #ffffff;
  --focus:     #7a5cff;
  --shadow:    0 1px 2px rgba(74,48,36,.04), 0 8px 24px -12px rgba(74,48,36,.14);
  --maxw:      70rem;
  --maxw-narrow: 43rem;
  --radius:    16px;
  --radius-sm: 10px;
  --serif: "Fraunces", Georgia, "Iowan Old Style", "Palatino Linotype", "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:      #201a17;
    --bg-warm: #2a221e;
    --surface: #2b2320;
    --fg:      #f3eae3;
    --fg-soft: #cdbcb1;
    --fg-mute: #9c897d;
    --rule:    #3c312b;
    --accent:  #e88a6c;
    --accent-soft:#3a2a23;
    --accent-fg: #241a16;
    --focus:   #b9a6ff;
    --shadow:  0 1px 2px rgba(0,0,0,.2), 0 10px 30px -14px rgba(0,0,0,.5);
  }
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.18; color: var(--fg); letter-spacing: -0.005em; }
h1 { font-size: clamp(2rem, 1.2rem + 3.4vw, 3.1rem); }
h2 { font-size: clamp(1.45rem, 1.1rem + 1.6vw, 2rem); }
h3 { font-size: 1.24rem; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 1.5rem; }
.container-narrow { max-width: var(--maxw-narrow); }

.section-label {
  display: inline-block; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); font-weight: 700; margin-bottom: .7rem;
}
.accent { color: var(--accent); }
.link-arrow { font-weight: 600; }

/* ─── Boutons ─────────────────────────────────────────────── */
.btn {
  display: inline-block; padding: .72rem 1.35rem; border-radius: 999px;
  font-weight: 600; font-size: .95rem; text-decoration: none; cursor: pointer;
  border: 1.5px solid transparent; transition: transform .05s ease, background .15s ease, border-color .15s ease;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-fg); box-shadow: var(--shadow); }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn-outline { border-color: var(--rule); color: var(--fg); background: var(--surface); }
.btn-outline:hover { border-color: var(--accent); }
.btn-ghost { color: var(--fg-soft); background: transparent; }
.btn-ghost:hover { color: var(--accent); }
.btn-large { padding: .9rem 1.7rem; font-size: 1rem; }

/* ─── En-tête ─────────────────────────────────────────────── */
#header {
  border-bottom: 1px solid var(--rule); background: var(--bg);
  position: sticky; top: 0; z-index: 20;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; }
.logo {
  display: inline-flex; align-items: flex-start; gap: .12rem; color: var(--fg);
  text-decoration: none; font-family: var(--serif); font-weight: 600;
  font-size: 1.2rem; letter-spacing: -0.01em; line-height: 1;
}
.logo:hover { text-decoration: none; }
.logo-word { padding-top: .18rem; }
.logo-a { color: var(--fg); }
.logo-b { color: var(--accent); }
.logo-arrow { width: 1.15rem; height: auto; color: var(--accent); flex-shrink: 0; }
footer .footer-brand .logo { font-size: 1.08rem; }
footer .footer-brand .logo-arrow { width: 1rem; }
#nav { display: flex; align-items: center; gap: 1.6rem; }
#nav a { color: var(--fg-soft); text-decoration: none; font-size: .95rem; font-weight: 600; }
#nav a:hover, #nav a[aria-current="page"] { color: var(--accent); }
#nav a.btn-outline { color: var(--fg); }
.burger { display: none; background: none; border: 0; width: 40px; height: 40px; padding: 8px; cursor: pointer; }
.burger span { display: block; height: 2px; background: var(--fg); margin: 5px 0; transition: .2s; border-radius: 2px; }

@media (max-width: 760px) {
  .burger { display: block; }
  #nav {
    position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--rule); padding: .5rem 1.5rem 1.3rem;
    transform: translateY(-140%); transition: transform .22s ease; z-index: 15;
  }
  #nav.open { transform: translateY(0); }
  #nav a { width: 100%; padding: .75rem 0; }
  #nav a.btn-outline { margin-top: .6rem; text-align: center; }
}

/* ─── Sections ────────────────────────────────────────────── */
section { padding-block: clamp(2.6rem, 1.6rem + 3.5vw, 4.2rem); }
section + section { border-top: 1px solid var(--rule); }
main > .container > .optin { margin-block: clamp(2.6rem, 1.6rem + 3.5vw, 4rem); }

/* ─── Accueil ─────────────────────────────────────────────── */
.home-hero {
  background: linear-gradient(180deg, var(--bg-warm), var(--bg));
  padding-block: clamp(3rem, 2rem + 5vw, 5.5rem);
}
.home-hero h1 { max-width: 16ch; }
.home-hero-sub { margin-top: 1.3rem; max-width: 56ch; color: var(--fg-soft); font-size: 1.16rem; }
.home-hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .8rem; }

.topics-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); margin-top: 1.7rem; }
.topic-card {
  display: block; background: var(--surface); border: 1px solid var(--rule);
  border-radius: var(--radius); padding: 1.5rem; color: inherit; text-decoration: none;
  box-shadow: var(--shadow); transition: transform .12s ease, border-color .15s ease;
}
.topic-card:hover { text-decoration: none; transform: translateY(-2px); border-color: var(--accent); }
.topic-card h3 { margin-bottom: .45rem; }
.topic-card p { color: var(--fg-soft); font-size: .97rem; }

.home-blog h2, .home-about h2, .home-topics h2 { margin-bottom: 1.3rem; }
.home-blog-more { margin-top: 1.7rem; }
.home-about { background: var(--bg-warm); }
.home-about p { max-width: 60ch; color: var(--fg-soft); }
.home-about p + p { margin-top: .8rem; }

/* ─── Blog : hero, liste, cartes ─────────────────────────── */
.blog-hero { background: linear-gradient(180deg, var(--bg-warm), var(--bg)); }
.blog-hero h1 { max-width: 20ch; }
.blog-hero p { margin-top: 1.1rem; max-width: 58ch; color: var(--fg-soft); }
.blog-hero-intro { margin-top: 1.1rem; }

.blog-section-title { margin-bottom: 1.3rem; }
.dossier-strip { display: flex; flex-wrap: wrap; gap: .6rem; }
.dossier-chip {
  display: inline-flex; align-items: center; gap: .5rem; padding: .5rem 1rem;
  border: 1px solid var(--rule); border-radius: 999px; background: var(--surface);
  color: var(--fg); text-decoration: none; font-size: .9rem; font-weight: 600;
}
.dossier-chip:hover { border-color: var(--accent); text-decoration: none; }
.dossier-chip span { color: var(--fg-mute); font-size: .8rem; }

.blog-grid { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); }
.blog-card {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius);
  box-shadow: var(--shadow); transition: transform .12s ease, border-color .15s ease;
}
.blog-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.blog-card-link { display: block; padding: 1.4rem; color: inherit; text-decoration: none; height: 100%; }
.blog-card-link:hover { text-decoration: none; }
.blog-card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font-size: .8rem; color: var(--fg-mute); margin-bottom: .7rem; }
.blog-badge {
  background: var(--accent-soft); color: var(--accent); border-radius: 999px;
  padding: .15rem .6rem; font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .03em;
}
.blog-dot { color: var(--fg-mute); }
.blog-card-title { font-size: 1.16rem; margin-bottom: .45rem; }
.blog-card-excerpt { font-size: .95rem; color: var(--fg-soft); }
.blog-card-more { display: inline-block; margin-top: 1rem; font-size: .85rem; font-weight: 700; color: var(--accent); }
.blog-count { color: var(--fg-mute); font-size: .9rem; margin-bottom: 1rem; }
.blog-empty { color: var(--fg-mute); }
.blog-related { background: var(--bg-warm); }

/* ─── Article ─────────────────────────────────────────────── */
.breadcrumb { font-size: .82rem; color: var(--fg-mute); margin-bottom: 1.5rem; }
.breadcrumb a { color: var(--fg-soft); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb-current { color: var(--fg-mute); }

.article { padding-block: clamp(2rem, 1.5rem + 3vw, 3.5rem); }
.article-head { margin-bottom: 1.9rem; }
.article-head h1 { margin-top: .7rem; }
.article-meta { margin-top: 1rem; font-size: .88rem; color: var(--fg-mute); display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }

.article-body { font-size: 1.09rem; }
.article-body > * + * { margin-top: 1.2rem; }
.article-body h2 { margin-top: 2.3rem; }
.article-body h3 { margin-top: 1.7rem; }
.article-body ul, .article-body ol { padding-left: 1.4rem; }
.article-body li + li { margin-top: .35rem; }
.article-body blockquote {
  border-left: 3px solid var(--accent); padding: .2rem 0 .2rem 1.1rem; color: var(--fg-soft); font-style: italic;
}
.article-body a { font-weight: 600; }
.article-body code { background: var(--bg-warm); padding: .1em .35em; border-radius: 5px; font-size: .9em; }

.affiliate-disclosure {
  background: var(--accent-soft); border-radius: var(--radius-sm);
  padding: .85rem 1.1rem; font-size: .9rem; color: var(--fg-soft); margin-block: 1.7rem;
}
.article-dossier-link { margin-top: 2.1rem; font-size: .95rem; color: var(--fg-soft); }

/* ─── Opt-in ──────────────────────────────────────────────── */
.optin {
  background: linear-gradient(150deg, var(--accent-soft), var(--surface));
  border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow);
}
.optin-inner { padding: clamp(1.5rem, 1rem + 2vw, 2.4rem); }
.optin-kicker { font-size: .74rem; letter-spacing: .13em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.optin-title { margin: .55rem 0 .65rem; font-size: 1.4rem; max-width: 24ch; }
.optin-text { color: var(--fg-soft); max-width: 56ch; margin-bottom: 1.3rem; }

/* ─── Guide ───────────────────────────────────────────────── */
.guide-lead { font-size: 1.13rem; color: var(--fg-soft); margin-block: 1.3rem; }
.guide-points { padding-left: 1.4rem; margin-block: 1.3rem; }
.guide-points li { margin-top: .4rem; }
.guide-form { margin-block: 1.7rem; }
.guide-form iframe {
  display: block; width: 100%; max-width: 540px; height: 680px;
  border: 0; margin-inline: auto;
}
.guide-form-note { font-size: .85rem; color: var(--fg-mute); text-align: center; }
.guide-transparency { font-size: .88rem; color: var(--fg-soft); background: var(--bg-warm); border-radius: var(--radius-sm); padding: .8rem 1rem; margin-top: 1.6rem; }

/* ─── Pied de page ────────────────────────────────────────── */
footer { border-top: 1px solid var(--rule); background: var(--bg-warm); padding-block: 2.8rem; margin-top: 2rem; }
.footer-inner { display: grid; gap: 1.1rem; }
.footer-brand .logo { margin-bottom: .5rem; }
.footer-brand p { color: var(--fg-mute); font-size: .9rem; max-width: 42ch; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; }
.footer-links a { color: var(--fg-soft); text-decoration: none; font-size: .9rem; }
.footer-links a:hover { color: var(--accent); }
.footer-disclosure { color: var(--fg-mute); font-size: .82rem; max-width: 70ch; border-top: 1px solid var(--rule); padding-top: 1.1rem; }
.footer-legal { color: var(--fg-mute); font-size: .82rem; }

/* ─── Bandeau de consentement ────────────────────────────── */
.consent {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  background: var(--surface); border-top: 1px solid var(--rule);
  box-shadow: 0 -8px 30px -14px rgba(74,48,36,.25);
}
.consent-inner {
  max-width: var(--maxw); margin-inline: auto; padding: 1rem 1.5rem;
  display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; justify-content: space-between;
}
.consent-text { font-size: .9rem; color: var(--fg-soft); max-width: 62ch; margin: 0; }
.consent-actions { display: flex; gap: .6rem; flex-shrink: 0; }
.consent-actions .btn { padding: .55rem 1.1rem; font-size: .9rem; }
@media (max-width: 560px) {
  .consent-actions { width: 100%; }
  .consent-actions .btn { flex: 1; text-align: center; }
}

/* ─── Apparitions (progressive enhancement) ─────────────── */
.js [data-animate] { opacity: 0; transform: translateY(14px); transition: opacity .45s ease, transform .45s ease; }
.js [data-animate].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .js [data-animate] { opacity: 1 !important; transform: none !important; transition: none; }
}
