/* ============================================================
   Chartrand Leduc CPA — Design System
   Vanilla CSS + custom properties (portable pour thème WordPress/ACF)
   Brand : charcoal #231F20 · rouge signature #F04033 · gris #5B5F60 · papier #FBFBFA
   Type  : Fraunces (titres) + Inter (corps)
   Motif : la barre verticale rouge du logo, déclinée partout
   ============================================================ */

/* ---------- 1. Tokens ---------- */
:root {
  /* Couleurs de marque */
  --ink:        #231F20;   /* charcoal — texte & sections foncées */
  --ink-2:      #3A3637;   /* charcoal adouci */
  --red:        #F04033;   /* rouge signature — barres, accents, surlignage */
  --red-cta:    #C42E22;   /* rouge AA pour boutons/liens sur fond clair (texte blanc 4.6:1) */
  --red-cta-h:  #A82518;   /* rouge survol */
  --grey:       #5B5F60;   /* gris — texte secondaire */
  --paper:      #FBFBFA;   /* blanc chaud — fond principal */
  --paper-2:    #F3F0EB;   /* fond alterné chaud */
  --line:       #E6E2DC;   /* filet */
  --line-2:     #D8D3CB;   /* filet appuyé */

  /* Sur fond foncé */
  --on-dark:        #FBFBFA;
  --on-dark-muted:  #B6B1AB;
  --on-dark-line:   rgba(251,251,250,.16);

  /* Typo */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Échelle fluide */
  --step--1: clamp(0.83rem, 0.79rem + 0.18vw, 0.92rem);
  --step-0:  clamp(1rem, 0.95rem + 0.25vw, 1.13rem);
  --step-1:  clamp(1.2rem, 1.1rem + 0.5vw, 1.45rem);
  --step-2:  clamp(1.5rem, 1.3rem + 1vw, 2rem);
  --step-3:  clamp(1.9rem, 1.55rem + 1.7vw, 2.85rem);
  --step-4:  clamp(2.35rem, 1.8rem + 2.7vw, 4rem);
  --step-5:  clamp(2.9rem, 2rem + 4.4vw, 5.5rem);

  /* Rythme & formes */
  --wrap: 1200px;
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --section-y: clamp(4rem, 8vw, 8.5rem);
  --r-sm: 6px;
  --r:    12px;
  --r-lg: 18px;

  --shadow-sm: 0 1px 2px rgba(35,31,32,.05);
  --shadow:    0 18px 40px -22px rgba(35,31,32,.30);
  --ease: cubic-bezier(.22,.61,.36,1);
}

/* ---------- 2. Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
/* Évite tout défilement horizontal dû aux entrées animées (translate ±) ou bandes pleine largeur.
   Appliqué à #contenu (et non html/body) pour ne pas casser le header sticky.
   `clip` (vs `hidden`) ne crée pas de conteneur de défilement. */
#contenu { overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg, picture { display: block; max-width: 100%; }
a { color: inherit; }
ul, ol { list-style: none; padding: 0; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
::selection { background: var(--red); color: #fff; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.012em;
  font-optical-sizing: auto;
  text-wrap: balance;
}

/* Accent rouge récurrent dans les titres : <em> = surligné, non-italique */
h1 em, h2 em, .hero__title em, .edge__quote em, .problem__title em {
  font-style: normal;
  color: var(--red);
}

.lede { font-size: var(--step-1); line-height: 1.55; color: var(--ink-2); }

/* ---------- 3. Layout helpers ---------- */
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); }
.section--paper2 { background: var(--paper-2); }

.section__head { max-width: 760px; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section__head--split {
  display: flex; flex-wrap: wrap; gap: 1.5rem 3rem;
  align-items: end; justify-content: space-between; max-width: none;
}
.section__head-note { max-width: 34ch; color: var(--grey); }
.section__title { font-size: var(--step-3); }

/* Eyebrow : étiquette + barre rouge (le motif du logo) */
.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--font-body);
  font-size: var(--step--1); font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--grey); margin-bottom: 1.1rem;
}
.eyebrow--light { color: var(--on-dark-muted); }
.eyebrow__bar { width: 3px; height: 1.05em; background: var(--red); border-radius: 2px; }
.eyebrow__bar--light { background: var(--red); }

/* Liens soulignés animés */
.link-underline {
  font-weight: 600; color: var(--red-cta);
  text-decoration: none; background-image: linear-gradient(var(--red-cta), var(--red-cta));
  background-size: 0% 2px; background-position: 0 100%; background-repeat: no-repeat;
  transition: background-size .35s var(--ease);
  padding-bottom: 2px;
}
.link-underline:hover, .link-underline:focus-visible { background-size: 100% 2px; }
.link-underline--light { color: var(--on-dark); background-image: linear-gradient(var(--red), var(--red)); }

/* ---------- 4. Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  font-weight: 600; font-size: var(--step-0); line-height: 1;
  padding: .95rem 1.5rem; border-radius: var(--r-sm);
  text-decoration: none; cursor: pointer;
  transition: background-color .25s var(--ease), color .25s var(--ease),
              border-color .25s var(--ease), transform .25s var(--ease), box-shadow .25s var(--ease);
  will-change: transform;
}
.btn svg { transition: transform .25s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn--primary { background: var(--red-cta); color: #fff; }
.btn--primary:hover { background: var(--red-cta-h); box-shadow: 0 12px 24px -12px rgba(196,46,34,.6); }
.btn--ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line-2); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn--light { background: var(--paper); color: var(--ink); }
.btn--light:hover { background: #fff; box-shadow: var(--shadow); }
.btn--sm { padding: .7rem 1.1rem; font-size: var(--step--1); }
.btn--lg { padding: 1.15rem 2rem; font-size: var(--step-1); }

/* ---------- 5. Brand wordmark ---------- */
.brand { display: inline-flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand__bar { width: 4px; height: 2.1em; background: var(--red); border-radius: 2px; flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--font-display); font-weight: 600; font-size: 1.18rem; letter-spacing: -.01em; }
.brand__cpa { font-family: var(--font-body); font-weight: 700; font-size: .68rem; letter-spacing: .34em; color: var(--red); margin-top: .22rem; }
.brand__logo { display: block; width: auto; max-width: min(220px, 52vw); max-height: 54px; }

/* ---------- 6. Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), box-shadow .3s var(--ease), background-color .3s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 8px 30px -24px rgba(35,31,32,.5); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 76px; }

.nav__list { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.2rem); }
.nav__link {
  position: relative; text-decoration: none; color: var(--ink);
  font-weight: 500; font-size: var(--step--1); letter-spacing: .01em; padding: .4rem 0;
  transition: color .2s var(--ease);
}
.nav__link::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 2px; width: 100%;
  background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav__link:hover { color: var(--red-cta); }
.nav__link:hover::after, .nav__link.is-current::after { transform: scaleX(1); }
.nav__link.is-current { color: var(--ink); }

.header-actions { display: flex; align-items: center; gap: clamp(.75rem, 1.6vw, 1.5rem); }
.header-phone {
  display: inline-flex; align-items: center; gap: .45rem;
  text-decoration: none; color: var(--ink); font-weight: 600; font-size: var(--step--1);
  transition: color .2s var(--ease);
}
.header-phone svg { color: var(--red); }
.header-phone:hover { color: var(--red-cta); }

.menu-toggle { display: none; width: 44px; height: 44px; position: relative; border-radius: var(--r-sm); }
.menu-toggle__bar { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px auto; border-radius: 2px; transition: transform .3s var(--ease), opacity .2s var(--ease); }
.nav__footer { display: none; } /* visible uniquement dans l'overlay mobile */

/* ---------- 7. Hero ---------- */
.hero { padding-block: clamp(3rem, 7vw, 6rem) clamp(3.5rem, 7vw, 6.5rem); }
.hero__inner {
  display: grid; grid-template-columns: 1.35fr .95fr;
  gap: clamp(2rem, 5vw, 5rem); align-items: center;
}
.hero__title { font-size: var(--step-5); margin: .4rem 0 1.4rem; max-width: 16ch; }
.hero__sub { font-size: var(--step-1); color: var(--ink-2); max-width: 52ch; line-height: 1.55; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 2.1rem; }

.hero__panel {
  position: relative; background: var(--ink); color: var(--on-dark);
  border-radius: var(--r-lg); padding: clamp(1.8rem, 3vw, 2.6rem);
  box-shadow: var(--shadow); overflow: hidden;
}
.hero__panel::before {
  content: ""; position: absolute; top: 0; left: 0; width: 5px; height: 100%; background: var(--red);
}
.hero__panel-eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: var(--step--1); font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--on-dark-muted); margin-bottom: 1.2rem;
}
.hero__panel-quote { font-family: var(--font-display); font-size: var(--step-2); line-height: 1.22; font-weight: 400; }
.hero__panel-quote .hl { color: var(--red); font-style: italic; }
.hero__panel-sign {
  margin-top: 1.6rem; padding-top: 1.1rem; border-top: 1px solid var(--on-dark-line);
  font-size: var(--step--1); letter-spacing: .04em; color: var(--on-dark-muted);
}

/* ---------- 8. Proof strip ---------- */
.proof { border-block: 1px solid var(--line); }
.proof__inner { display: grid; grid-template-columns: repeat(4, 1fr); }
.proof__item { padding: clamp(1.6rem, 3vw, 2.4rem) clamp(1rem, 2vw, 1.8rem); border-left: 1px solid var(--line); }
.proof__item:first-child { border-left: none; padding-left: 0; }
.proof__num {
  display: block; font-family: var(--font-display); font-weight: 600;
  font-size: var(--step-3); line-height: 1; color: var(--ink); margin-bottom: .6rem;
  position: relative; padding-left: 14px;
}
.proof__num::before { content: ""; position: absolute; left: 0; top: .08em; width: 3px; height: .82em; background: var(--red); border-radius: 2px; }
.proof__label { display: block; font-size: var(--step--1); color: var(--grey); line-height: 1.45; }

/* ---------- 9. Problème ---------- */
.problem__inner { max-width: 920px; }
.problem__title { font-size: var(--step-4); margin: .3rem 0 1.6rem; }
.problem__text { max-width: 64ch; }

/* ---------- 10. Piliers ---------- */
.pillars__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(1rem, 2vw, 1.5rem); }
.pillar {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--r); padding: clamp(1.5rem, 2.4vw, 2rem);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease);
}
.pillar:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--line-2); }
.pillar__icon {
  display: inline-grid; place-items: center; width: 54px; height: 54px;
  border-radius: 10px; background: color-mix(in srgb, var(--red) 11%, var(--paper));
  color: var(--red-cta); margin-bottom: 1.3rem;
}
.pillar__title { font-size: var(--step-1); margin-bottom: .55rem; }
.pillar__desc { font-size: var(--step--1); color: var(--grey); line-height: 1.55; }

/* ---------- 11. Notre approche (timeline) ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(1.5rem, 3vw, 2.5rem); }
.step { position: relative; padding-top: 2.6rem; }
.step__rail { position: absolute; top: 11px; left: calc(2.4rem + 8px); right: -2.5rem; height: 2px; background: var(--line-2); }
.step__rail::after { content: ""; position: absolute; inset: 0; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .8s var(--ease); }
.step.is-active .step__rail::after { transform: scaleX(1); }
.step__num {
  position: absolute; top: 0; left: 0;
  font-family: var(--font-display); font-weight: 600; font-size: 1.5rem; color: var(--red);
  width: 2.4rem; height: 2.4rem; display: grid; place-items: center;
  border: 2px solid var(--red); border-radius: 50%; background: var(--paper);
}
.step__title { font-size: var(--step-1); margin-bottom: .5rem; }
.step__desc { font-size: var(--step--1); color: var(--grey); line-height: 1.55; }

/* ---------- 12. Atout — Revenu Québec (band foncé) ---------- */
.edge { background: var(--ink); color: var(--on-dark); }
.edge__lead { max-width: 60ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.edge__quote { font-size: var(--step-3); font-weight: 400; line-height: 1.2; }
.edge__quote em { color: var(--red); font-style: italic; }

.founders { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 3vw, 3rem); }
.founder { display: flex; gap: 1.2rem; align-items: flex-start; }
.founder__mark {
  flex: none; width: 56px; height: 56px; display: grid; place-items: center;
  border: 1.5px solid var(--red); border-radius: 10px;
  font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; color: var(--red);
}
.founder__name { font-size: var(--step-1); margin-bottom: .5rem; }
.founder__name span { display: block; font-family: var(--font-body); font-weight: 500; font-size: var(--step--1); color: var(--on-dark-muted); letter-spacing: .02em; margin-top: .2rem; }
.founder__desc { font-size: var(--step--1); color: var(--on-dark-muted); line-height: 1.6; }
.edge__foot { margin-top: clamp(2rem, 4vw, 3rem); padding-top: 1.6rem; border-top: 1px solid var(--on-dark-line); font-size: var(--step-1); color: var(--on-dark); }
.edge__foot em { color: var(--red); font-style: italic; }
.edge__foot a { margin-left: .4rem; white-space: nowrap; }

/* ---------- 13. Client idéal + filtre ---------- */
.fit__inner { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.fit__lead .section__title { font-size: var(--step-3); margin: .3rem 0 1.4rem; max-width: 18ch; }
.fit__text { max-width: 46ch; }

.notfit {
  background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--red);
  border-radius: var(--r); padding: clamp(1.7rem, 3vw, 2.4rem);
}
.notfit__title { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); margin-bottom: 1.3rem; }
.notfit__list { display: grid; gap: .95rem; }
.notfit__list li { display: flex; align-items: flex-start; gap: .8rem; color: var(--ink-2); font-size: var(--step-0); }
.notfit__mark { flex: none; width: 16px; height: 2px; background: var(--red); margin-top: .75em; border-radius: 2px; }
.notfit__note { margin-top: 1.5rem; padding-top: 1.2rem; border-top: 1px solid var(--line); font-size: var(--step--1); color: var(--grey); font-style: italic; }

/* ---------- 14. CTA final ---------- */
.cta-final { text-align: center; }
.cta-final__inner { max-width: 760px; margin-inline: auto; display: flex; flex-direction: column; align-items: center; }
.cta-final__bar { width: 4px; height: 48px; background: var(--red); border-radius: 2px; margin-bottom: 1.8rem; }
.cta-final__title { font-size: var(--step-4); margin-bottom: 2.2rem; max-width: 20ch; }

/* ---------- 15. Footer ---------- */
.site-footer { background: var(--ink); color: var(--on-dark); padding-top: clamp(3.5rem, 6vw, 5.5rem); }
.site-footer__inner { display: grid; grid-template-columns: 1.6fr 1fr 1.2fr; gap: clamp(2rem, 5vw, 4rem); padding-bottom: clamp(2.5rem, 5vw, 4rem); }
.brand--footer .brand__name { color: var(--on-dark); }
.brand--footer { color: var(--on-dark); }
.site-footer__tag { margin-top: 1.2rem; max-width: 36ch; color: var(--on-dark-muted); font-size: var(--step--1); line-height: 1.6; }
.site-footer__h { font-family: var(--font-body); font-size: var(--step--1); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark-muted); margin-bottom: 1.2rem; }
.site-footer__col ul { display: grid; gap: .7rem; }
.site-footer__col a { text-decoration: none; color: var(--on-dark); transition: color .2s var(--ease); }
.site-footer__col a:hover { color: var(--red); }
.site-footer__nap { font-style: normal; display: grid; gap: .65rem; color: var(--on-dark-muted); font-size: var(--step--1); }
.site-footer__nap a { color: var(--on-dark); }
.site-footer__hours { line-height: 1.5; }
.site-footer__bottom {
  display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; justify-content: space-between;
  border-top: 1px solid var(--on-dark-line); padding-block: 1.6rem 2rem;
  font-size: var(--step--1); color: var(--on-dark-muted);
}
.site-footer__credit a { color: var(--on-dark); text-decoration: underline; text-underline-offset: 3px; }
.site-footer__credit a:hover { color: var(--red); }

/* ---------- 16. Accessibility utils ---------- */
.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .8rem 1.2rem; border-radius: var(--r-sm);
  text-decoration: none; transition: top .2s var(--ease);
}
.skip-link:focus { top: 1rem; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 3px; }

/* ---------- 17. Reveal (animations) ---------- */
html.js.motion-ready [data-reveal] { will-change: opacity, transform; }
@media (prefers-reduced-motion: reduce) {
 html.js.motion-ready [data-reveal] { opacity: 1 !important; transform: none !important; }
 .step.is-active .step__rail::after { transition: none; }
}

/* ---------- 18. Responsive ---------- */
@media (max-width: 1024px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__title { max-width: 20ch; }
  .hero__panel { max-width: 520px; }
  .pillars__grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step__rail { display: none; }
  .fit__inner { grid-template-columns: 1fr; }
  .site-footer__inner { grid-template-columns: 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  /* Header → menu mobile */
  /* Pas de backdrop-filter sur mobile : sinon le header devient le bloc conteneur
     du menu en position:fixed et l'overlay ne couvre plus tout l'écran. */
  .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--paper); }
  .nav {
    position: fixed; inset: 76px 0 0; z-index: 49;
    background: var(--paper);
    transform: translateX(100%); visibility: hidden;
    transition: transform .45s var(--ease), visibility 0s linear .45s;
    display: flex; flex-direction: column;
    padding: clamp(1.5rem, 7vw, 2.75rem) var(--gutter) clamp(1.75rem, 6vw, 2.5rem);
    overflow-y: auto; -webkit-overflow-scrolling: touch;
  }
  body.menu-open .nav { transform: translateX(0); visibility: visible; transition: transform .45s var(--ease), visibility 0s; }
  body.menu-open { overflow: hidden; }

  .nav__list { flex-direction: column; align-items: stretch; gap: 0; width: 100%; counter-reset: navi; }
  .nav__list > li { border-bottom: 1px solid var(--line); }
  .nav__list > li:first-child { border-top: 1px solid var(--line); }
  .nav__link {
    display: flex; align-items: center; gap: .85rem;
    font-family: var(--font-display); font-weight: 500; line-height: 1.1;
    font-size: clamp(1.55rem, 7vw, 2.25rem); color: var(--ink);
    padding: clamp(.75rem, 3.2vw, 1.1rem) 0;
    opacity: 0; transform: translateX(16px);
    transition: color .2s var(--ease), opacity .45s var(--ease), transform .45s var(--ease);
  }
  .nav__link::after { display: none; }
  .nav__link::before {
    counter-increment: navi; content: "0" counter(navi);
    font-family: var(--font-body); font-size: .78rem; font-weight: 600;
    color: var(--red); letter-spacing: .08em; min-width: 1.7em;
  }
  .nav__link.is-current { color: var(--red-cta); }
  .nav__link:hover, .nav__link:focus-visible { color: var(--red-cta); }
  body.menu-open .nav__link { opacity: 1; transform: none; }
  body.menu-open .nav__list > li:nth-child(1) .nav__link { transition-delay: .08s; }
  body.menu-open .nav__list > li:nth-child(2) .nav__link { transition-delay: .14s; }
  body.menu-open .nav__list > li:nth-child(3) .nav__link { transition-delay: .20s; }
  body.menu-open .nav__list > li:nth-child(4) .nav__link { transition-delay: .26s; }
  body.menu-open .nav__list > li:nth-child(5) .nav__link { transition-delay: .32s; }

  .nav__footer {
    display: flex; flex-direction: column; gap: 1.1rem; width: 100%;
    margin-top: auto; padding-top: clamp(1.75rem, 7vw, 2.5rem);
    opacity: 0; transform: translateY(12px);
    transition: opacity .45s var(--ease) .3s, transform .45s var(--ease) .3s;
  }
  body.menu-open .nav__footer { opacity: 1; transform: none; }
  .nav__phone {
    display: inline-flex; align-items: center; gap: .65rem; min-height: 44px;
    font-weight: 600; font-size: var(--step-1); color: var(--ink); text-decoration: none;
  }
  .nav__phone svg { color: var(--red); flex: none; }
  .nav__phone:hover, .nav__phone:focus-visible { color: var(--red-cta); }
  .nav__cta { width: 100%; justify-content: center; }

  .menu-toggle { display: block; }
  .header-phone { display: none; }
  .header-actions .btn--sm { display: none; }
  body.menu-open .menu-toggle__bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  body.menu-open .menu-toggle__bar:nth-child(2) { transform: translateY(-6px) rotate(-45deg); }

  .proof__inner { grid-template-columns: 1fr 1fr; }
  .proof__item { border-left: none; border-top: 1px solid var(--line); padding-inline: 0; }
  .proof__item:nth-child(odd) { padding-right: 1rem; }
  .proof__item:nth-child(1), .proof__item:nth-child(2) { border-top: none; }

  .pillars__grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 0; }
  .step { padding: 0 0 2.2rem 3.6rem; }
  .step:not(:last-child)::before { content: ""; position: absolute; left: calc(1.2rem - 1px); top: 2.4rem; bottom: 0; width: 2px; background: var(--line-2); }
  .founders { grid-template-columns: 1fr; }
  .edge__foot a { display: inline-block; margin-left: 0; }
  .site-footer__inner { grid-template-columns: 1fr; }
  .site-footer__bottom { flex-direction: column; }
}

@media (max-width: 380px) {
  .hero__cta .btn { width: 100%; justify-content: center; }
}


/* ===== Couche animation (Option B, fusionnée) ===== */
/* ============================================================
   Chartrand Leduc CPA — Couche d'animation (Version B)
   À charger APRÈS styles.css. Ajoute/écrase pour la variante "plus animée".
   Tout dégrade : sans JS ou en reduced-motion, le contenu reste visible.
   ============================================================ */

/* ---- Barre de progression de défilement ---- */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60;
  background: var(--red); transform: scaleX(0); transform-origin: 0 50%;
  will-change: transform;
}

/* ---- Header : masquer au défilement vers le bas ---- */
.site-header { transition: transform .45s var(--ease), border-color .3s var(--ease), box-shadow .3s var(--ease), background-color .3s var(--ease); }
.site-header.is-hidden { transform: translateY(-100%); }

/* ---- Hero : révélation par mots ---- */
html.js.motion-ready [data-split] { will-change: opacity; }
.word { display: inline-block; will-change: transform; }
/* l'<em> conserve sa couleur rouge */
[data-split] em { font-style: normal; color: var(--red); }

/* la barre de l'eyebrow se "dessine" */
html.js.motion-ready [data-draw-bar] { transform-origin: 50% 0; }

/* Indice de défilement */
.scroll-cue {
  display: inline-flex; align-items: center; gap: .55rem; margin-top: 2.6rem;
  font-size: var(--step--1); letter-spacing: .14em; text-transform: uppercase; color: var(--grey);
}
.scroll-cue svg { color: var(--red); animation: cue-bob 1.8s var(--ease) infinite; }
@keyframes cue-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(5px); } }

/* parallaxe : juste un repère de perf */
[data-parallax] { will-change: transform; }

/* ---- Marquee (bande services) ---- */
.marquee {
  border-block: 1px solid var(--line); background: var(--paper);
  overflow: hidden; white-space: nowrap; padding-block: 1rem;
}
.marquee__track { display: inline-flex; align-items: center; gap: 0; will-change: transform; animation: marquee-scroll 34s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__item {
  font-family: var(--font-display); font-weight: 500; font-size: var(--step-1);
  color: var(--ink-2); padding-inline: 1.6rem; display: inline-flex; align-items: center; gap: 1.6rem;
}
.marquee__item::after { content: ""; width: 7px; height: 7px; background: var(--red); border-radius: 50%; flex: none; }
@keyframes marquee-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---- Notre approche : version épinglée ---- */
.approach--v2 .steps2 { position: relative; margin-top: clamp(2rem, 4vw, 3.5rem); }
.steps2__track { position: absolute; top: 23px; left: 0; right: 0; height: 2px; background: var(--line-2); }
.steps2__fill { position: absolute; inset: 0; background: var(--red); transform: scaleX(0); transform-origin: 0 50%; }
.steps2__list { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(1.5rem, 3vw, 2.5rem); }
.step2 { position: relative; padding-top: 4rem; transition: opacity .4s var(--ease); }
.step2 .step2__num {
  position: absolute; top: 0; left: 0;
  width: 48px; height: 48px; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 600; font-size: 1.35rem;
  border: 2px solid var(--line-2); border-radius: 50%; background: var(--paper); color: var(--grey);
  transition: color .35s var(--ease), border-color .35s var(--ease), background-color .35s var(--ease), transform .35s var(--ease);
}
.step2.is-active .step2__num { color: #fff; background: var(--red); border-color: var(--red); transform: scale(1.06); }
.step2__title { font-size: var(--step-1); margin-bottom: .5rem; }
.step2__desc { font-size: var(--step--1); color: var(--grey); line-height: 1.55; }

/* ---- Magnétique ---- */
[data-magnetic] { will-change: transform; }

/* ---- Reveal directionnel (variante) ---- */
html.js.motion-ready [data-reveal-x] { will-change: opacity, transform; }

@media (prefers-reduced-motion: reduce) {
  html.js.motion-ready [data-split],
  html.js.motion-ready [data-reveal-x] { opacity: 1 !important; transform: none !important; }
  html.js.motion-ready [data-draw-bar] { transform: none !important; }
  .marquee__track { animation: none; }
  .scroll-cue svg { animation: none; }
  .steps2__fill { transform: scaleX(1); }
  .step2 { opacity: 1; }
  .step2 .step2__num { color: #fff; background: var(--red); border-color: var(--red); }
}

/* ---- Responsive : approche non épinglée sur mobile ---- */
@media (max-width: 1024px) {
  .steps2__list { grid-template-columns: repeat(2, 1fr); row-gap: 2.5rem; }
  .steps2__track { display: none; }
}
@media (max-width: 760px) {
  .steps2__list { grid-template-columns: 1fr; }
  .marquee__item { font-size: var(--step-0); }
}


/* ============================================================
   Pages intérieures — composants
   (Accompagnement CPA · À propos · Contact)
   ============================================================ */

/* ---- Page hero (intérieur) ---- */
.page-hero { padding-block: clamp(2.8rem, 6vw, 5rem) clamp(2.2rem, 4vw, 3.5rem); }
.page-hero__inner { max-width: 900px; }
.page-hero__title { font-size: var(--step-4); margin: .4rem 0 1.4rem; }
.page-hero__intro { font-size: var(--step-1); color: var(--ink-2); max-width: 62ch; line-height: 1.55; }

/* ---- Blocs de services (Accompagnement) ---- */
.svc-list { display: grid; }
.svc { display: grid; grid-template-columns: .92fr 1.08fr; gap: clamp(1.5rem, 4vw, 4rem); padding-block: clamp(2.2rem, 4vw, 3.4rem); border-top: 1px solid var(--line); }
.svc:last-child { border-bottom: 1px solid var(--line); }
.svc__num { font-family: var(--font-display); font-weight: 600; font-size: clamp(2rem, 4vw, 3rem); color: var(--red); line-height: 1; display: block; margin-bottom: 1rem; }
.svc__title { font-size: var(--step-2); margin-bottom: .9rem; }
.svc__lead { color: var(--grey); max-width: 38ch; }
.svc__points { display: grid; gap: .85rem; align-self: center; }
.svc__points li { display: flex; gap: .7rem; align-items: flex-start; font-size: var(--step-0); color: var(--ink-2); }
.svc__points svg { color: var(--red-cta); flex: none; margin-top: .25em; }

/* ---- Flux de qualité (process) ---- */
.flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(1rem, 2vw, 1.4rem); margin-top: clamp(2rem, 4vw, 3rem); }
.flow__node { position: relative; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(1.3rem, 2.4vw, 1.9rem); }
.flow__node::before { content: ""; position: absolute; top: 0; left: clamp(1.3rem, 2.4vw, 1.9rem); right: clamp(1.3rem, 2.4vw, 1.9rem); height: 3px; background: var(--red); border-radius: 0 0 2px 2px; }
.flow__num { font-family: var(--font-display); font-weight: 600; font-size: 1.4rem; color: var(--red); }
.flow__node h3 { font-size: var(--step-1); margin: .7rem 0 .4rem; }
.flow__node p { font-size: var(--step--1); color: var(--grey); line-height: 1.5; }
.flow__caption { margin-top: 1.5rem; color: var(--grey); font-size: var(--step--1); font-style: italic; }

/* ---- FAQ (accordéon accessible) ---- */
.faq { max-width: 840px; }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item:first-child { border-top: 1px solid var(--line); }
.faq__q {
  display: flex; justify-content: space-between; align-items: center; gap: 1.2rem; width: 100%;
  text-align: left; cursor: pointer; padding: 1.35rem 0;
  font-family: var(--font-display); font-weight: 500; font-size: var(--step-1); color: var(--ink);
}
.faq__icon { position: relative; flex: none; width: 22px; height: 22px; }
.faq__icon::before, .faq__icon::after { content: ""; position: absolute; background: var(--red); border-radius: 2px; transition: transform .3s var(--ease), opacity .3s var(--ease); }
.faq__icon::before { top: 10px; left: 0; width: 22px; height: 2px; }
.faq__icon::after { left: 10px; top: 0; width: 2px; height: 22px; }
.faq__item:not(.is-collapsed) .faq__icon::after { transform: rotate(90deg); opacity: 0; }
.faq__a-wrap { display: grid; grid-template-rows: 1fr; transition: grid-template-rows .35s var(--ease); }
.faq__item.is-collapsed .faq__a-wrap { grid-template-rows: 0fr; }
.faq__a-inner { overflow: hidden; }
.faq__a { padding: 0 0 1.4rem; color: var(--grey); max-width: 72ch; }

/* ---- Histoire / prose ---- */
.split-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.prose { max-width: 64ch; }
.prose p { margin-bottom: 1.1rem; color: var(--ink-2); }
.feature-list { display: grid; gap: .9rem; }
.feature-list li { display: flex; gap: .75rem; color: var(--ink-2); }
.feature-list svg { color: var(--red-cta); flex: none; margin-top: .25em; }

/* ---- Équipe ---- */
.team { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.8rem, 4vw, 3rem); }
.member { display: grid; grid-template-columns: auto 1fr; gap: clamp(1.2rem, 2.5vw, 2rem); align-items: start; }
.member__photo {
  width: clamp(120px, 15vw, 168px); aspect-ratio: 4 / 5; border-radius: var(--r);
  background: var(--paper-2); border: 1px solid var(--line); display: grid; place-items: center;
  position: relative; overflow: hidden; flex: none;
}
.member__photo::before { content: ""; position: absolute; left: 0; top: 0; width: 5px; height: 100%; background: var(--red); }
.member__photo span { font-family: var(--font-display); font-weight: 600; font-size: 2rem; color: var(--red); }
.member__name { font-size: var(--step-2); }
.member__role { color: var(--red-cta); font-weight: 600; font-size: var(--step--1); letter-spacing: .02em; margin: .35rem 0 1rem; }
.member__creds { display: grid; gap: .55rem; margin-bottom: 1.1rem; }
.member__creds li { display: flex; gap: .6rem; font-size: var(--step--1); color: var(--ink-2); }
.member__creds svg { color: var(--red-cta); flex: none; margin-top: .2em; }
.member__bio { color: var(--grey); }
.member--solo { grid-template-columns: auto 1fr; }

/* ---- Valeurs ---- */
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.4rem, 3vw, 2.4rem); }
.value { position: relative; padding-top: 1.5rem; border-top: 2px solid var(--line-2); }
.value::before { content: ""; position: absolute; top: -2px; left: 0; width: 48px; height: 2px; background: var(--red); }
.value h3 { font-size: var(--step-1); margin-bottom: .5rem; }
.value p { color: var(--grey); font-size: var(--step--1); line-height: 1.55; }

/* ---- Partenaires ---- */
.partners-card { position: relative; background: var(--ink); color: var(--on-dark); border-radius: var(--r-lg); padding: clamp(2rem, 4vw, 3.2rem); overflow: hidden; }
.partners-card::before { content: ""; position: absolute; top: 0; left: 0; width: 5px; height: 100%; background: var(--red); }
.partners-card p { font-family: var(--font-display); font-weight: 400; font-size: var(--step-2); line-height: 1.32; max-width: 54ch; }

/* ---- Contact ---- */
.contact-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: clamp(2rem, 5vw, 3.5rem); align-items: start; }
.form { display: grid; gap: 1.25rem; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.field { display: grid; gap: .45rem; }
.field > label, .fieldset__legend { font-weight: 600; font-size: var(--step--1); color: var(--ink); }
.req { color: var(--red-cta); }
.field input, .field select, .field textarea {
  font: inherit; font-size: var(--step-0); color: var(--ink); background: var(--paper);
  border: 1.5px solid var(--line-2); border-radius: var(--r-sm); padding: .8rem .9rem; width: 100%;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--red); box-shadow: 0 0 0 3px color-mix(in srgb, var(--red) 18%, transparent);
}
.field textarea { min-height: 130px; resize: vertical; }
.field.is-error input, .field.is-error select, .field.is-error textarea, fieldset.is-error .choice, fieldset.is-error .radio { border-color: var(--red); }
.field__error { color: var(--red-cta); font-size: var(--step--1); display: none; }
.field.is-error .field__error, fieldset.is-error .field__error { display: block; }
fieldset { border: none; padding: 0; margin: 0; display: grid; gap: .55rem; }
.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.choice, .radio {
  display: flex; gap: .6rem; align-items: center; padding: .7rem .9rem;
  border: 1.5px solid var(--line-2); border-radius: var(--r-sm); cursor: pointer;
  font-size: var(--step--1); transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.choice--consent { align-items: flex-start; line-height: 1.45; }
.choice:hover, .radio:hover { border-color: var(--grey); }
.choice input, .radio input { accent-color: var(--red-cta); width: auto; margin: 0; }
.choice:has(input:checked), .radio:has(input:checked) { border-color: var(--red); background: color-mix(in srgb, var(--red) 7%, var(--paper)); }
.radio-row { display: flex; flex-wrap: wrap; gap: .6rem; }
.form__note { font-size: var(--step--1); color: var(--grey); }
.form__success {
  display: none; padding: 1.6rem 1.8rem; border: 1.5px solid var(--red); border-left-width: 4px;
  border-radius: var(--r); background: color-mix(in srgb, var(--red) 6%, var(--paper));
}
.form__success.is-visible { display: block; }
.form__success h2 { font-size: var(--step-2); margin-bottom: .5rem; }

/* Aside coordonnées */
.contact-info { display: grid; gap: 1.35rem; background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(1.6rem, 3vw, 2.2rem); }
.contact-info__item { display: flex; gap: .9rem; align-items: flex-start; }
.contact-info__item svg { color: var(--red); flex: none; margin-top: .15em; }
.contact-info__item h3 { font-family: var(--font-body); font-weight: 600; font-size: var(--step--1); text-transform: uppercase; letter-spacing: .1em; color: var(--grey); margin-bottom: .25rem; }
.contact-info__item a, .contact-info__item p { color: var(--ink); text-decoration: none; line-height: 1.5; }
.contact-info__item a:hover { color: var(--red-cta); }
.map-ph {
  margin-top: 1.4rem; aspect-ratio: 16 / 10; border-radius: var(--r);
  background: repeating-linear-gradient(45deg, var(--paper-2), var(--paper-2) 12px, #efece6 12px, #efece6 24px);
  border: 1px dashed var(--line-2); display: grid; place-items: center; text-align: center;
  color: var(--grey); font-size: var(--step--1); padding: 1rem;
}
.map-ph--embed { display: block; padding: 0; overflow: hidden; background: var(--paper); border-style: solid; }
.map-ph iframe { display: block; width: 100%; height: 100%; min-height: 260px; border: 0; }

/* ---- Responsive (pages intérieures) ---- */
@media (max-width: 860px) {
  .svc { grid-template-columns: 1fr; gap: 1rem; }
  .flow { grid-template-columns: 1fr 1fr; }
  .split-2 { grid-template-columns: 1fr; }
  .team { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .form__row { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .flow { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr; }
  .member { grid-template-columns: 1fr; }
  .choice-grid { grid-template-columns: 1fr; }
}

/* Machine à écrire — curseur clignotant */
.tw-cursor { display:inline-block; width:3px; height:1em; margin-left:3px; vertical-align:-0.12em; background: var(--red); animation: tw-blink 1s steps(1) infinite; }
@keyframes tw-blink { 0%,50% { opacity:1; } 50.01%,100% { opacity:0; } }
@media (prefers-reduced-motion: reduce) { .tw-cursor { display:none; } }


/* ============================================================
   WordPress — état d'erreur du repli + habillage Formidable Forms
   ============================================================ */

/* Repli (formulaire intégré) : message d'erreur */
.form__error {
  padding: 1rem 1.2rem; margin-bottom: 1.5rem; font-size: var(--step--1); color: var(--ink);
  border: 1.5px solid var(--red); border-left-width: 4px; border-radius: var(--r-sm);
  background: color-mix(in srgb, var(--red) 7%, var(--paper));
}

/* Formidable Forms — alignement sur la charte (portée : .clcpa-form) */
.clcpa-form .frm_forms,
.clcpa-form .frm_form_fields { max-width: none; }
.clcpa-form fieldset { border: 0; padding: 0; margin: 0; }
.clcpa-form .frm_form_field { margin-bottom: 1.2rem; }
.clcpa-form .frm_primary_label { display: block; font-weight: 600; font-size: var(--step--1); color: var(--ink); margin-bottom: .45rem; }
.clcpa-form .frm_required { color: var(--red-cta); }

.clcpa-form input[type="text"],
.clcpa-form input[type="email"],
.clcpa-form input[type="tel"],
.clcpa-form input[type="url"],
.clcpa-form input[type="number"],
.clcpa-form select,
.clcpa-form textarea {
  font: inherit; font-size: var(--step-0); color: var(--ink); background: var(--paper);
  border: 1.5px solid var(--line-2); border-radius: var(--r-sm); padding: .8rem .9rem; width: 100%;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.clcpa-form input:focus, .clcpa-form select:focus, .clcpa-form textarea:focus {
  outline: none; border-color: var(--red); box-shadow: 0 0 0 3px color-mix(in srgb, var(--red) 18%, transparent);
}
.clcpa-form textarea { min-height: 130px; resize: vertical; }

/* Cases à cocher & boutons radio en « chips » */
.clcpa-form .frm_opt_container { display: flex; flex-wrap: wrap; gap: .6rem; }
.clcpa-form .frm_checkbox, .clcpa-form .frm_radio { margin: 0; }
.clcpa-form .frm_checkbox label, .clcpa-form .frm_radio label {
  display: flex; align-items: center; gap: .6rem; margin: 0; padding: .7rem .9rem; cursor: pointer;
  border: 1.5px solid var(--line-2); border-radius: var(--r-sm); font-size: var(--step--1);
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.clcpa-form .frm_checkbox label:hover, .clcpa-form .frm_radio label:hover { border-color: var(--grey); }
.clcpa-form input[type="checkbox"], .clcpa-form input[type="radio"] { accent-color: var(--red-cta); width: auto; margin: 0; }

/* Bouton d'envoi */
.clcpa-form .frm_submit { margin-top: .5rem; }
/* !important : surclasse le style par défaut de Formidable (scopé par ID de conteneur). */
.clcpa-form .frm_submit button,
.clcpa-form .frm_submit input[type="submit"],
.clcpa-form .frm_button_submit {
  display: inline-flex !important; align-items: center; gap: .55rem; cursor: pointer;
  width: auto !important; font-family: var(--font-body) !important; font-weight: 600 !important;
  font-size: var(--step-1) !important; line-height: 1 !important; text-transform: none !important;
  padding: 1.15rem 2rem !important; border: 0 !important; border-radius: var(--r-sm) !important;
  background: var(--red-cta) !important; color: #fff !important;
  transition: background-color .25s var(--ease), box-shadow .25s var(--ease);
}
.clcpa-form .frm_submit button:hover,
.clcpa-form .frm_submit input[type="submit"]:hover,
.clcpa-form .frm_button_submit:hover { background: var(--red-cta-h) !important; box-shadow: 0 12px 24px -12px rgba(196,46,34,.6); }

/* Messages d'erreur et de confirmation Formidable */
.clcpa-form .frm_error { color: var(--red-cta); font-size: var(--step--1); margin-top: .35rem; }
.clcpa-form .frm_blank_field input,
.clcpa-form .frm_blank_field select,
.clcpa-form .frm_blank_field textarea { border-color: var(--red); }
.clcpa-form .frm_message,
.frm_forms .frm_message {
  padding: 1.5rem 1.8rem; border: 1.5px solid var(--red); border-left-width: 4px; border-radius: var(--r);
  background: color-mix(in srgb, var(--red) 6%, var(--paper)); color: var(--ink);
}

.member__photo img { width: 100%; height: 100%; object-fit: cover; }
