/* =========================================================
   Accessibilité Numérique — par Warren Walter
   Charte reprise du site warren-walter.com :
   indigo profond #241f59, fond crème #fbf7f0, accent jaune
   #f4b400, accent doux #fff2c7, police Poppins, radius 18px.
   ========================================================= */

/* Poppins, avec fallback système si la police ne charge pas */
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: local("Poppins");
}

:root {
  --bg: #fbf7f0;            /* fond crème */
  --card: #ffffff;
  --text: #241f59;         /* indigo profond — contraste élevé sur crème */
  --accent: #f4b400;       /* jaune */
  --accent-soft: #fff2c7;
  --alt: #f2f3fb;          /* fond de section alterné */
  --border: rgba(36, 31, 89, .12);
  --shadow: 0 6px 18px rgba(36, 31, 89, .06);
  --radius: 18px;
  --radius-btn: 12px;
  --max: 1140px;
  --max-narrow: 760px;
  --s2: .75rem; --s3: 1rem; --s4: 1.5rem; --s5: 2rem; --s6: 3rem; --s7: 4.5rem;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
}

/* A11Y : respect de prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

img { max-width: 100%; height: auto; }

a { color: inherit; }
a:hover { text-decoration: underline; }

/* A11Y : focus visible et contrasté partout */
:focus-visible {
  outline: 3px solid var(--text);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Masquage visuel mais accessible aux lecteurs d'écran */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* A11Y : lien d'évitement */
.skip-link {
  position: absolute; left: 8px; top: -60px;
  background: var(--text); color: #fff;
  padding: .7rem 1rem; border-radius: 8px;
  z-index: 1000; text-decoration: none; font-weight: 700;
  transition: top .15s ease;
}
.skip-link:focus { top: 8px; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1.25rem; }
.container.narrow { max-width: var(--max-narrow); }

/* ---------- Boutons (style WW) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none; font-weight: 700; line-height: 1.2;
  border-radius: var(--radius-btn);
  padding: .85rem 1.3rem;
  border: 2px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn.primary { background: var(--accent); color: #111; }      /* jaune / texte quasi-noir : contraste AA */
.btn.primary:hover { background: #e0a600; }
.btn.secondary { background: transparent; border-color: rgba(36, 31, 89, .28); color: var(--text); }
.btn.secondary:hover { background: rgba(36, 31, 89, .06); }

.cta-row { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s4); }
.cta-row.center { justify-content: center; }

/* ---------- Titres ---------- */
h1 { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.1; margin: 0 0 var(--s4); }
h2 { font-size: clamp(1.6rem, 2.4vw, 2.4rem); line-height: 1.15; margin: 0 0 var(--s4); }
h3 { font-size: 1.2rem; margin: 0 0 var(--s2); }

/* ---------- Header ---------- */
.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 50;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); padding: .9rem 0; }
.brand { display: flex; flex-direction: column; text-decoration: none; line-height: 1.1; }
.brand:hover { text-decoration: none; }
.brand-name { font-weight: 700; font-size: 1.1rem; }
.brand-by { font-size: .8rem; opacity: .8; }

.site-nav { display: flex; align-items: center; gap: var(--s4); }
.site-nav ul { display: flex; gap: var(--s4); list-style: none; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; font-weight: 500; padding: .3rem 0; }
.site-nav a:hover { text-decoration: underline; }
.header-cta { padding: .6rem 1rem; }

.nav-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { padding: var(--s7) 0 var(--s6); }
.hero-inner { display: grid; grid-template-columns: 1.2fr .8fr; gap: var(--s6); align-items: center; }
.eyebrow {
  display: inline-block; background: var(--accent-soft); color: var(--text);
  font-weight: 600; font-size: .85rem; padding: .35rem .8rem; border-radius: 999px;
  margin: 0 0 var(--s3);
}
.lead { font-size: 1.2rem; margin: 0 0 var(--s3); }
.reassurance { margin-top: var(--s4); font-weight: 600; }

.hero-visual { display: flex; justify-content: center; }
.hero-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: var(--s5); display: flex; flex-wrap: wrap; gap: var(--s2); max-width: 320px;
}
.hero-badge {
  background: var(--accent-soft); border: 1px solid var(--border);
  border-radius: 999px; padding: .4rem .9rem; font-weight: 600; font-size: .9rem;
}

/* ---------- Sections ---------- */
.section { padding: var(--s6) 0; }
.section.alt { background: var(--alt); }

/* ---------- Cartes ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: var(--s4); list-style: none; padding: 0; margin: 0; }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: var(--s4); }
.card p { margin: 0; }
.card.offer { display: flex; flex-direction: column; }
.card-link { display: inline-block; margin-top: var(--s3); font-weight: 700; color: var(--text); }

/* Steps (méthode) */
.steps { counter-reset: step; list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--s4); }
.step { position: relative; }
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.2rem; height: 2.2rem; border-radius: 999px;
  background: var(--text); color: #fff; font-weight: 700; margin-bottom: var(--s2);
}

/* ---------- Listes ---------- */
.list-checks { list-style: none; padding: 0; margin: 0 0 var(--s4); }
.list-checks li { padding-left: 1.6rem; position: relative; margin-bottom: .4rem; }
.list-checks li::before { content: "✓"; position: absolute; left: 0; font-weight: 700; color: var(--text); }

/* Références */
.refs-intro { font-weight: 600; margin-bottom: var(--s2); }
.refs { display: flex; flex-wrap: wrap; gap: .6rem; list-style: none; padding: 0; margin: 0; }
.refs li { background: var(--card); border: 1px solid var(--border); border-radius: 999px; padding: .4rem .9rem; font-size: .9rem; }

/* ---------- Formulaire ---------- */
.form { margin-top: var(--s4); }
.form-required-note { font-size: .9rem; margin: 0 0 var(--s4); }
.field { margin-bottom: var(--s4); }
.field label { display: block; font-weight: 600; margin-bottom: .4rem; }
.req { color: #b00020; }   /* astérisque ; l'obligation est aussi indiquée par le texte/aria-required */
.field input, .field select, .field textarea {
  width: 100%; padding: .7rem .85rem; font: inherit; color: var(--text);
  background: var(--card); border: 1px solid rgba(36, 31, 89, .35); border-radius: 10px;
}
.field textarea { resize: vertical; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: 3px solid var(--text); outline-offset: 1px; border-color: var(--text);
}
/* A11Y : champ en erreur, signalé par couleur ET bordure ET message texte */
.field input[aria-invalid="true"], .field select[aria-invalid="true"], .field textarea[aria-invalid="true"] {
  border-color: #b00020; border-width: 2px;
}
.error { color: #b00020; font-weight: 600; margin: .4rem 0 0; }
.form-success {
  background: var(--accent-soft); border: 1px solid var(--border);
  border-radius: 10px; padding: var(--s3); font-weight: 600; margin-bottom: var(--s4);
}

/* ---------- FAQ ---------- */
.faq-item {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: var(--s3) var(--s4); margin-bottom: var(--s3);
}
.faq-item summary { font-weight: 700; cursor: pointer; }
.faq-item summary:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.faq-item p { margin: var(--s3) 0 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--text); color: #fff; padding: var(--s6) 0; }
.site-footer a { color: #fff; }
.footer-brand { font-weight: 700; margin: 0 0 var(--s3); }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--s4); list-style: none; padding: 0; margin: 0 0 var(--s4); }
.footer-note { opacity: .85; margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { order: -1; }

  /* Menu mobile accessible */
  .nav-toggle {
    display: inline-flex; align-items: center; gap: .5rem;
    background: transparent; border: 2px solid rgba(36, 31, 89, .28);
    border-radius: 10px; padding: .5rem .8rem; font: inherit; font-weight: 700;
    color: var(--text); cursor: pointer;
  }
  .nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    content: ""; display: block; width: 20px; height: 2px; background: var(--text); position: relative;
  }
  .nav-toggle-bars::before { position: absolute; top: -6px; }
  .nav-toggle-bars::after { position: absolute; top: 6px; }

  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: var(--s3);
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: var(--s4) 1.25rem;
  }
  .site-nav.open { display: flex; }
  .site-nav ul { flex-direction: column; gap: var(--s3); }
  .header-cta { align-self: flex-start; }
  .header-inner { position: relative; }
}
