/* ==========================================================
   Kanvo — feuille de style commune
   Palette : encre (bleu nuit), mirabelle (jaune lorrain), feuille (vert)
   ========================================================== */
:root {
  --paper: #FFFFFF;
  --mist: #F3F5F8;        /* fonds de section discrets */
  --ink: #1C2541;         /* texte principal, bandeaux */
  --ink-2: #2B3557;
  --stone: #535B70;       /* texte secondaire (contraste 6,6:1 sur blanc) */
  --line: #DFE3EA;
  --mirabelle: #F2B705;   /* boutons, repères */
  --mirabelle-deep: #D89F00;
  --mirabelle-soft: #FFF4CC;
  --leaf: #2E6B4F;
  --radius-s: 8px;
  --radius-m: 14px;
  --radius-l: 28px;
  --wrap: 1160px;
  --font: 'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.6; font-weight: 400;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { margin: 0; line-height: 1.08; letter-spacing: -0.025em; font-weight: 800; }
h1 { font-size: clamp(40px, 6.2vw, 72px); letter-spacing: -0.035em; }
h2 { font-size: clamp(30px, 4vw, 48px); }
h3 { font-size: 21px; letter-spacing: -0.015em; line-height: 1.25; }
.lead { font-size: clamp(18px, 1.6vw, 20px); color: var(--stone); max-width: 36em; }
.muted { color: var(--stone); }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } body { font-size: 16px; } }

.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: var(--radius-s); z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--mirabelle-deep); outline-offset: 3px; border-radius: 4px; }

/* ---------- boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px; border-radius: var(--radius-s); border: 0;
  font: 700 17px/1 var(--font); text-decoration: none; cursor: pointer;
  background: var(--mirabelle); color: var(--ink);
  transition: background .15s ease, transform .15s ease;
}
.btn:hover { background: var(--mirabelle-deep); }
.btn:active { transform: translateY(1px); }
.btn-ghost { background: transparent; box-shadow: inset 0 0 0 2px var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-small { min-height: 42px; padding: 0 16px; font-size: 15px; }
.textlink { font-weight: 700; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; text-decoration-color: var(--mirabelle); }
.textlink:hover { text-decoration-color: var(--ink); }

/* ---------- en-tête ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 72px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 24px; letter-spacing: -0.03em; }
.logo svg { width: 32px; height: 28px; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { text-decoration: none; font-weight: 600; font-size: 16px; color: var(--ink-2); }
.nav .btn { gap: 0; }
.nav a:not(.btn):hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; text-decoration-color: var(--mirabelle); }
@media (max-width: 820px) { .nav a:not(.btn) { display: none; } }
@media (max-width: 420px) { .hide-xs { display: none; } .logo { font-size: 22px; } }

/* ---------- pied de page ---------- */
.site-footer { background: var(--ink); color: #D9DEEA; padding: 56px 0 40px; margin-top: 0; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.footer-grid h4 { font-size: 16px; color: #fff; margin-bottom: 12px; letter-spacing: 0; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-grid a { text-decoration: none; }
.footer-grid a:hover { text-decoration: underline; }
.footer-brand .logo { color: #fff; margin-bottom: 12px; }
.footer-brand p { max-width: 30em; font-size: 15px; }
.footer-legal { border-top: 1px solid rgba(255,255,255,.15); margin-top: 40px; padding-top: 20px; font-size: 14px; color: #B9C1D4; display: flex; flex-wrap: wrap; gap: 8px 28px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- pages légales ---------- */
.legal-hero { padding: 64px 0 24px; border-bottom: 1px solid var(--line); }
.legal-hero h1 { font-size: clamp(34px, 5vw, 52px); }
.legal-hero p { color: var(--stone); margin-top: 12px; }
.legal-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; padding: 48px 0 80px; }
.legal-toc { position: sticky; top: 96px; align-self: start; font-size: 15px; }
.legal-toc ol { margin: 0; padding-left: 20px; display: grid; gap: 8px; color: var(--stone); }
.legal-toc a { text-decoration: none; }
.legal-toc a:hover { text-decoration: underline; }
.legal-content { max-width: 720px; }
.legal-content section { padding-bottom: 32px; margin-bottom: 32px; border-bottom: 1px solid var(--line); scroll-margin-top: 96px; }
.legal-content section:last-child { border-bottom: 0; }
.legal-content h2 { font-size: 28px; margin-bottom: 16px; }
.legal-content h2 .num { color: var(--stone); font-weight: 600; margin-right: 10px; }
.legal-content h2 .italic { font-style: normal; }
.legal-content h3 { font-size: 19px; margin: 24px 0 8px; }
.legal-content ul { padding-left: 20px; }
.legal-content li { margin-bottom: 6px; }
.legal-content code { background: var(--mist); padding: 1px 6px; border-radius: 4px; font-size: .92em; }
.legal-content a { text-decoration: underline; text-decoration-color: var(--mirabelle-deep); text-underline-offset: 3px; }
.legal-card { border: 1px solid var(--line); border-radius: var(--radius-m); margin: 16px 0; overflow: hidden; }
.legal-data-row, .pricing-row { display: grid; grid-template-columns: 200px 1fr; gap: 16px; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.pricing-row { grid-template-columns: 190px 1fr auto; }
.legal-data-row:last-child, .pricing-row:last-child { border-bottom: 0; }
.legal-data-label, .pricing-name { font-weight: 700; }
.pricing-name em { font-style: normal; }
.pricing-price { font-weight: 700; white-space: nowrap; }
.legal-callout { background: var(--mirabelle-soft); border-radius: var(--radius-m); padding: 16px 20px; margin: 16px 0; }
.legal-callout p:last-child { margin-bottom: 0; }
.legal-rights-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; margin: 16px 0; }
.legal-right { border: 1px solid var(--line); border-radius: var(--radius-m); padding: 14px 16px; }
.legal-right-name { font-weight: 700; margin-bottom: 4px; }
.legal-right-name em { font-style: normal; }
.legal-right-desc { margin: 0; color: var(--stone); font-size: 15px; }
@media (max-width: 860px) {
  .legal-layout { grid-template-columns: 1fr; gap: 24px; }
  .legal-toc { display: none; }
  .legal-data-row, .pricing-row { grid-template-columns: 1fr; gap: 2px; }
  .legal-rights-grid { grid-template-columns: 1fr; }
}
