/* The Dojo — feuille de style unique
   Tokens issus de thedojo-brand-booklet.html
   Deux paires de contraste du brand kit ont ete corrigees :
   - bouton orange : label ink #1A1A1A (4,80:1) et non blanc (3,63:1)
   - eyebrow : ink-soft #4A4A4A (7,73:1) et non green-light #4A7C5A (4,24:1 / 2,58:1)
   Aucun JavaScript n'est necessaire au fonctionnement de la navigation. */

:root {
  --dojo-green: #1C3A22;
  --dojo-green-mid: #2D5C38;
  --dojo-green-light: #4A7C5A;
  --dojo-cream: #F5EFE0;
  --dojo-cream-deep: #EDE5D0;
  --dojo-orange: #C4722A;
  --dojo-orange-light: #D98C48;
  --ink: #1A1A1A;
  --ink-soft: #4A4A4A;
  --white: #FFFFFF;
  --rule: rgba(28, 58, 34, 0.14);
  --font-sans: 'Instrument Sans', system-ui, -apple-system, sans-serif;
  --font-serif: 'Instrument Serif', Georgia, serif;
  --wrap: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--dojo-green);
  background: var(--dojo-cream);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .5em; font-weight: 700; letter-spacing: -0.015em; }
/* Le h1 de la home tenait sur cinq lignes a 360 px et repoussait le CTA sous le
   bandeau de consentement. La borne basse du clamp est donc descendue a 1.75rem :
   c'est cette valeur, pas le bandeau, qui decidait de la visibilite du bouton. */
h1 { font-size: clamp(1.75rem, 5.4vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.25rem); }
h3 { font-size: clamp(1.15rem, 2.6vw, 1.4rem); }
h4 { font-size: 1.05rem; font-weight: 600; }
p { margin: 0 0 1.1em; max-width: 68ch; }

a { color: var(--dojo-green); text-underline-offset: .18em; }
a:hover { color: var(--dojo-green-mid); }

.serif { font-family: var(--font-serif); font-weight: 400; letter-spacing: 0; }

.eyebrow {
  font-size: .75rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-soft);
  margin: 0 0 .7rem;
}
.on-dark .eyebrow { color: var(--dojo-orange-light); }

.lede { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: var(--ink-soft); max-width: 60ch; }
.on-dark .lede { color: var(--dojo-cream-deep); }

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

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--dojo-green); color: var(--dojo-cream); padding: .7rem 1rem;
}
.skip:focus { left: 0; }

:where(a, button, input, summary, label) :focus-visible,
a:focus-visible, button:focus-visible, input:focus-visible,
textarea:focus-visible, select:focus-visible, label:focus-visible {
  outline: 3px solid var(--dojo-orange);
  outline-offset: 2px;
}

/* ---------- Boutons ---------- */

.btn {
  display: inline-block; font: inherit; font-weight: 600;
  padding: .78rem 1.4rem; border-radius: 6px; border: 1.5px solid transparent;
  text-decoration: none; cursor: pointer; transition: background .18s var(--ease);
}
.btn-primary { background: var(--dojo-green); color: var(--dojo-cream); }
.btn-primary:hover { background: var(--dojo-green-mid); color: var(--dojo-cream); }
.btn-accent { background: var(--dojo-orange); color: var(--ink); }
.btn-accent:hover { background: var(--dojo-orange-light); color: var(--ink); }
.btn-ghost { border-color: currentColor; color: var(--dojo-green); }
.btn-ghost:hover { background: rgba(28, 58, 34, .06); }
.on-dark .btn-ghost { color: var(--dojo-cream); }
.on-dark .btn-ghost:hover { background: rgba(245, 239, 224, .12); }
.btn-sm { padding: .55rem 1rem; font-size: .9rem; }

/* ---------- Entete et navigation, sans JavaScript ---------- */

.site-header {
  background: var(--dojo-green); color: var(--dojo-cream);
  position: relative; z-index: 50;
}
.site-header a { color: var(--dojo-cream); text-decoration: none; }

.header-bar {
  display: flex; align-items: center; gap: 1rem;
  min-height: 68px; padding: .6rem 1.25rem;
  max-width: var(--wrap); margin: 0 auto;
}

.brand { display: flex; flex-direction: column; line-height: 1.15; margin-right: auto; }
.brand strong { font-size: 1.12rem; font-weight: 700; letter-spacing: -0.01em; }
.brand span { font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; color: var(--dojo-orange-light); }

.nav-toggle { position: absolute; opacity: 0; width: 1px; height: 1px; }
.nav-toggle-label {
  display: inline-flex; align-items: center; gap: .45rem;
  font-size: .9rem; font-weight: 600; cursor: pointer;
  padding: .5rem .7rem; border: 1.5px solid rgba(245, 239, 224, .35); border-radius: 6px;
}
.nav-toggle:focus-visible + .nav-toggle-label { outline: 3px solid var(--dojo-orange); outline-offset: 2px; }

.nav { display: none; }
.nav ul { list-style: none; margin: 0; padding: 0; }
.nav > ul > li > a, .nav > ul > li > .nav-label {
  display: block; padding: .75rem 0; font-size: .95rem; font-weight: 600;
  min-height: 44px; line-height: 1.5;
}
/* .nav-label est un <button> : c'est ce qui rend le sous-menu atteignable au
   Tab comme au doigt via :focus-within. On lui retire l'apparence native. */
.nav-label {
  background: none; border: 0; color: inherit; font-family: inherit;
  text-align: left; width: 100%; cursor: pointer;
}
.submenu li a {
  display: block; padding: .6rem 0 .6rem 1rem; font-size: .9rem; font-weight: 400;
  color: var(--dojo-cream-deep); min-height: 44px; line-height: 1.6;
}
.submenu li a:hover { color: var(--white); }
.header-cta { margin-top: 1rem; display: block; }

.nav-toggle:checked ~ .nav { display: block; padding: 0 1.25rem 1.5rem; }

@media (min-width: 900px) {
  .nav-toggle-label { display: none; }
  /* La case a cocher pilote le menu sous 900 px. Au-dessus elle n'a plus d'objet :
     laissee focusable, elle mettait un arret invisible dans l'ordre de tabulation. */
  .nav-toggle { display: none; }
  .nav { display: block !important; padding: 0 !important; }
  .nav > ul { display: flex; align-items: center; gap: .35rem; }
  .nav > ul > li { position: relative; }
  .nav > ul > li > a, .nav > ul > li > .nav-label {
    padding: 1.1rem .8rem; width: auto; min-height: 0;
  }
  .header-bar { flex-wrap: nowrap; }
  .header-cta { margin: 0 0 0 .8rem; }

  .submenu {
    display: none; position: absolute; top: 100%; left: 0; min-width: 288px;
    background: var(--dojo-green-mid); border: 1px solid rgba(245, 239, 224, .2);
    border-radius: 8px; padding: .5rem; box-shadow: none;
  }
  .has-menu > .nav-label::after { content: " \25BE"; font-size: .7em; }
  .has-menu:hover > .submenu, .has-menu:focus-within > .submenu { display: block; }
  .submenu li a { padding: .55rem .7rem; border-radius: 4px; min-height: 0; }
  .submenu li a:hover { background: rgba(245, 239, 224, .1); }
}

/* ---------- Sections ---------- */

.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section-tight { padding: clamp(2rem, 4vw, 3rem) 0; }
.on-dark { background: var(--dojo-green); color: var(--dojo-cream); }
.on-dark a { color: var(--dojo-cream); }
.on-white { background: var(--white); }
.on-cream-deep { background: var(--dojo-cream-deep); }

.hero { padding: clamp(1.5rem, 7vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4rem); }
.hero h1 { max-width: 26ch; }
/* Sous 480 px, le h1 du hero descend sous le minimum global : sinon le titre
   pousse le premier CTA sous le bandeau de consentement a 360x640 (brief §12,
   defaut 3 — CTA visible avec 20 px de marge). */
@media (max-width: 480px) { .hero h1 { font-size: 1.5rem; } }
/* Le lede du hero est plus gros que celui des pages internes : c'est la seule
   ligne qui qualifie la promesse au-dessus de la ligne de flottaison. */
.hero .lede { margin-top: .9rem; font-size: clamp(1.2rem, 2.8vw, 1.55rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.5rem; }

/* Preuve au premier ecran. Le bloc chiffre complet arrive juste apres, mais la
   home ne peut pas ouvrir sur trois promesses sans un seul fait verifiable. */
.hero-proof {
  margin-top: 1.6rem; padding-top: 1.1rem; border-top: 1px solid var(--rule);
  font-size: .9rem; color: var(--ink-soft); max-width: 60ch;
}
.hero-proof strong { color: var(--dojo-green); font-weight: 700; }

.rule { border: 0; border-top: 1px solid var(--rule); margin: 2.5rem 0; }
.on-dark .rule { border-top-color: rgba(245, 239, 224, .2); }

/* ---------- Grilles et cartes ---------- */

.grid { display: grid; gap: 1.25rem; }
@media (min-width: 700px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 700px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--white); border: 1px solid var(--rule); border-radius: 12px;
  padding: 1.6rem; display: flex; flex-direction: column;
}
.card h3 { margin-bottom: .6rem; }
.card p { font-size: .96rem; color: var(--ink-soft); }
.card .card-foot { margin-top: auto; padding-top: 1rem; font-weight: 600; font-size: .95rem; }
.card-quote {
  font-family: var(--font-serif); font-size: 1.28rem; line-height: 1.3;
  color: var(--dojo-green); margin: 0 0 .9rem;
}
.on-dark .card { background: rgba(245, 239, 224, .07); border-color: rgba(245, 239, 224, .22); }
.on-dark .card p { color: var(--dojo-cream-deep); }
.on-dark .card h3, .on-dark .card-quote { color: var(--dojo-cream); }

a.card { text-decoration: none; }
a.card:hover { border-color: var(--dojo-green-mid); }

/* ---------- Chiffres ---------- */

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem 1rem; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat .n { font-family: var(--font-serif); font-size: clamp(2.1rem, 5vw, 3rem); line-height: 1; display: block; }
.stat .l { font-size: .82rem; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-soft); }
.on-dark .stat .l { color: var(--dojo-orange-light); }

.source { font-size: .8rem; color: var(--ink-soft); max-width: 70ch; }
.on-dark .source { color: var(--dojo-cream-deep); }

/* ---------- Listes ---------- */

.list-clean { list-style: none; padding: 0; margin: 0 0 1.2em; max-width: 68ch; }
.list-clean li { padding: .5rem 0 .5rem 1.5rem; position: relative; border-bottom: 1px solid var(--rule); }
.list-clean li::before { content: "\2192"; position: absolute; left: 0; color: var(--dojo-orange); }
.on-dark .list-clean li { border-bottom-color: rgba(245, 239, 224, .18); }
.on-dark .list-clean li::before { color: var(--dojo-orange-light); }

.steps { list-style: none; counter-reset: s; padding: 0; margin: 0; }
.steps li { counter-increment: s; padding: 1.1rem 0 1.1rem 3rem; position: relative; border-top: 1px solid var(--rule); }
.steps li::before {
  content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: 1.1rem;
  font-family: var(--font-serif); font-size: 1.2rem; color: var(--dojo-orange);
}

/* ---------- Bloc marche suivante ---------- */

.next-step {
  border-left: 3px solid var(--dojo-orange); border-radius: 0;
  background: var(--dojo-cream-deep); padding: 1.5rem 1.6rem; margin-top: 2.5rem;
}
.next-step p:last-child { margin-bottom: 0; }
.next-step .q { font-family: var(--font-serif); font-size: 1.25rem; line-height: 1.35; }

.callout {
  border-left: 3px solid var(--dojo-green-mid); border-radius: 0;
  background: var(--white); padding: 1.2rem 1.4rem; font-size: .95rem;
}
.callout p:last-child { margin-bottom: 0; }

/* ---------- Preuve ---------- */

.proof { background: var(--white); border: 1px solid var(--rule); border-radius: 12px; padding: 1.4rem 1.5rem; }
.proof .tag {
  display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--ink); background: var(--dojo-orange);
  padding: .2rem .55rem; border-radius: 4px; margin-bottom: .8rem;
}
.proof-soft .tag { background: var(--dojo-cream-deep); color: var(--dojo-green); }

/* ---------- Contact ---------- */

.contact-box { background: var(--white); border: 1px solid var(--rule); border-radius: 12px; padding: clamp(1.5rem, 4vw, 2.5rem); }
.contact-mail { font-family: var(--font-serif); font-size: clamp(1.4rem, 4vw, 2rem); word-break: break-word; }
/* Hauteur genereuse plutot qu'un cadre a defilement interne : sur mobile un
   double scroll rend un formulaire embarque tres difficile a remplir. */
.form-embed {
  width: 100%; height: 820px; border: 1px solid var(--rule);
  border-radius: 8px; background: var(--white); display: block;
}

/* Informations legales non encore saisies. Visible, et bloquant au test de build. */
.todo {
  background: var(--dojo-orange); color: var(--ink); font-weight: 700;
  font-size: .78rem; letter-spacing: .06em; padding: .1rem .45rem; border-radius: 3px;
}

/* ---------- Pied de page ---------- */

.site-footer { background: var(--dojo-green); color: var(--dojo-cream); padding: 3rem 0 2rem; }
.site-footer a { color: var(--dojo-cream); }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.site-footer h2 { font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--dojo-orange-light); margin-bottom: .8rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { padding: .28rem 0; font-size: .93rem; }
.footer-legal { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid rgba(245, 239, 224, .2); font-size: .82rem; color: var(--dojo-cream-deep); }

/* ---------- Fil d'Ariane ---------- */

.crumb { font-size: .85rem; color: var(--ink-soft); padding: 1.2rem 0 0; }
.crumb a { color: var(--ink-soft); }

/* ---------- Bandeau de consentement ---------- */

/* Le bandeau recouvre le bas de l'ecran tant qu'aucun choix n'est fait. A 182 px
   de haut il masquait entierement le CTA du hero sur un ecran de 640 px. Texte
   ramene a une ligne et boutons sur la meme rangee : environ 60 px au lieu de 182. */
.consent {
  position: sticky; bottom: 0; z-index: 60;
  background: var(--dojo-green); color: var(--dojo-cream);
  border-top: 2px solid var(--dojo-orange); padding: .7rem 1.25rem;
}
.consent-inner {
  max-width: var(--wrap); margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: .6rem .8rem; align-items: center;
}
.consent p { margin: 0; font-size: .85rem; flex: 1 1 260px; max-width: none; color: var(--dojo-cream-deep); }
.consent a { color: var(--dojo-orange-light); }
.consent .btn { padding: .45rem .9rem; font-size: .85rem; }

@media print { .site-header, .consent, .site-footer { display: none; } }
