/* Design Artisan du Bâtiment. Matériaux : chaux, pierre, ardoise, brique, laine. Angles vifs, traits épais. */

html { scroll-padding-top: calc(var(--header-h) + 1rem); }
body { overflow-x: clip; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 88; letter-spacing: -0.025em; }
::selection { background: var(--laine); color: var(--ardoise); }

.kicker {
  font-size: var(--step--1); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--brique); margin-bottom: var(--space-s);
  display: flex; align-items: center; gap: 0.75rem;
}
.kicker::before { content: ""; width: 1.75rem; height: 3px; background: currentColor; }
.section-title { font-size: var(--step-4); line-height: 0.95; max-width: 16ch; }

/* Boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  padding: 0.8rem 1.2rem; font-weight: 600; text-decoration: none; border: 2px solid transparent;
  line-height: 1.2; cursor: pointer; transition: background .2s, color .2s, transform .2s var(--ease);
}
.btn--lg { padding: 1rem 1.5rem; font-size: var(--step-0); }
.btn--brick { background: var(--brique); color: var(--color-on-accent); }
.btn--brick:hover { background: var(--brique-fonce); }
.btn--line { border-color: var(--ardoise); color: var(--ardoise); }
.btn--line:hover { background: var(--ardoise); color: var(--chaux); }
.btn:active { transform: translateY(1px); }

/* ── En-tête ───────────────────────────────────────── */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 60; height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-m);
  padding-inline: var(--gutter);
  transition: background .3s, box-shadow .3s;
}
.site-header[data-scrolled] { background: var(--chaux); box-shadow: 0 1px 0 var(--color-line); }
.site-header__logo { display: block; flex: none; }
.site-header__logo svg { width: auto; height: 2.6rem; }
@media (min-width: 900px) { .site-nav { display: flex; align-items: center; gap: var(--space-l); } }
.site-nav__list { display: flex; gap: var(--space-m); }
.site-nav__list a { text-decoration: none; font-weight: 500; position: relative; padding-block: 0.4rem; }
.site-nav__list a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--brique);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.site-nav__list a:hover::after { transform: scaleX(1); }

.site-header__toggle {
  width: 2.75rem; height: 2.75rem; border: 0; background: none; align-items: center; justify-content: center; cursor: pointer;
}
.site-header__toggle-bars, .site-header__toggle-bars::before, .site-header__toggle-bars::after {
  display: block; width: 1.5rem; height: 3px; background: var(--ardoise); position: relative; transition: transform .3s var(--ease), background .2s;
}
.site-header__toggle-bars::before, .site-header__toggle-bars::after { content: ""; position: absolute; left: 0; }
.site-header__toggle-bars::before { top: -7px; }
.site-header__toggle-bars::after { top: 7px; }
.site-header__toggle[aria-expanded="true"] .site-header__toggle-bars { background: transparent; }
.site-header__toggle[aria-expanded="true"] .site-header__toggle-bars::before { transform: translateY(7px) rotate(45deg); }
.site-header__toggle[aria-expanded="true"] .site-header__toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 899px) {
  .site-header { background: var(--chaux); }
  .site-header__logo svg { height: 2.2rem; }
  .site-nav[data-open] {
    position: fixed; inset: var(--header-h) 0 0; background: var(--chaux);
    display: flex; flex-direction: column; align-items: stretch; justify-content: space-between;
    padding: var(--space-l) var(--gutter) calc(var(--space-l) + 4rem);
  }
  .site-nav__list { flex-direction: column; gap: 0; }
  .site-nav__list a { display: block; font-family: var(--font-display); font-weight: 800; font-size: var(--step-3); padding-block: 0.6rem; border-bottom: 2px solid var(--ardoise); }
  .site-nav__list a::after { display: none; }
  .site-nav__cta { padding: 1.1rem; }
}

/* ── Héros ─────────────────────────────────────────── */
.hero { position: relative; padding-top: calc(var(--header-h) + var(--space-l)); padding-bottom: var(--space-xl); }
.hero__inner {
  display: grid; gap: var(--space-l);
  grid-template-columns: 1fr;
  grid-template-areas: "text" "mark" "trades";
}
.hero__text { grid-area: text; }
.hero__title { font-size: var(--step-5); line-height: 0.86; letter-spacing: -0.04em; margin-bottom: var(--space-m); }
.hero__line { display: block; }
.hero__line:last-child { color: var(--brique); }
.hero__subtitle { font-size: var(--step-1); line-height: 1.45; max-width: 36ch; color: var(--ardoise); margin-bottom: var(--space-l); }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-s); }
.hero__mark { grid-area: mark; justify-self: center; width: min(52vw, 20rem); }
.hero__mark svg { width: 100%; overflow: visible; }
.hm-roof { fill: var(--ardoise); }
.hm-zig { fill: none; stroke: var(--laine); stroke-width: 2.4; }
.hm-b { fill: var(--ardoise); }
.hm-b--accent { fill: var(--brique); }

.hero__trades {
  grid-area: trades; display: grid; grid-template-columns: repeat(2, 1fr);
  border-top: 3px solid var(--ardoise);
}
.hero__trades li { border-bottom: 1px solid var(--color-line); }
.hero__trades li:nth-child(odd) { border-right: 1px solid var(--color-line); }
.hero__trades a {
  display: flex; flex-direction: column; gap: 0.2rem; padding: var(--space-s) var(--space-s) var(--space-s) 0;
  text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: var(--step-1); line-height: 1.1;
}
.hero__trades li:nth-child(even) a { padding-left: var(--space-s); }
.hero__trades .num { font-family: var(--font-body); font-size: var(--step--1); font-weight: 600; color: var(--brique); }
.hero__trades a:hover { color: var(--brique); }
.hero__hint { display: none; }

@media (min-width: 900px) {
  .hero { min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding-bottom: var(--space-l); }
  .hero__inner {
    grid-template-columns: repeat(12, 1fr); column-gap: var(--space-m); row-gap: var(--space-xl);
    grid-template-areas:
      "text text text text text text text text mark mark mark mark"
      "trades trades trades trades trades trades trades trades trades trades trades trades";
    align-items: end;
  }
  .hero__mark { width: 100%; max-width: 26rem; justify-self: end; margin-bottom: 0.5rem; }
  .hero__trades { grid-template-columns: repeat(4, 1fr); }
  .hero__trades li, .hero__trades li:nth-child(odd) { border-right: 1px solid var(--color-line); border-bottom: 0; }
  .hero__trades li:last-child { border-right: 0; }
  .hero__trades a, .hero__trades li:nth-child(even) a { padding: var(--space-m) var(--space-m) 0; }
  .hero__trades li:first-child a { padding-left: 0; }
  .hero__hint {
    display: flex; align-items: center; gap: 0.75rem; position: absolute; left: var(--gutter); bottom: var(--space-m);
    font-size: var(--step--1); color: var(--gris);
  }
  .hero__hint span { width: 3px; height: 2rem; background: var(--color-line); position: relative; overflow: hidden; }
  .hero__hint span::after { content: ""; position: absolute; inset: 0; background: var(--brique); animation: hint 1.8s var(--ease) infinite; }
}
@keyframes hint { from { transform: translateY(-100%); } to { transform: translateY(100%); } }

/* Animation d'arrivée : le logo se construit */
.js-motion .hero__line { animation: rise .9s var(--ease) both; animation-delay: calc(var(--i) * 110ms + 100ms); }
.js-motion .hero__subtitle, .js-motion .hero__actions, .js-motion .hero__trades { animation: fade .9s var(--ease) both .55s; }
.js-motion .hm-b { animation: brick .55s var(--ease) both; animation-delay: calc(var(--d) * 90ms + 250ms); }
.js-motion .hm-b--accent { animation: brick .55s var(--ease) both calc(3 * 90ms + 250ms), paint 1s ease both 1.2s; }
.js-motion .hm-roof { animation: roof .8s var(--ease) both 1s; }
.js-motion .hm-zig { stroke-dasharray: 60; animation: draw 1s ease both 1.5s; }
@keyframes rise { from { opacity: 0; transform: translateY(0.4em); } }
@keyframes fade { from { opacity: 0; transform: translateY(14px); } }
@keyframes brick { from { opacity: 0; transform: translateY(-14px); } }
@keyframes roof { from { opacity: 0; transform: translateY(-18px); } }
@keyframes draw { from { stroke-dashoffset: 60; } to { stroke-dashoffset: 0; } }
@keyframes paint { from { fill: var(--ardoise); } to { fill: var(--brique); } }

/* ── Le chantier ───────────────────────────────────── */
.chantier { background: var(--pierre); padding-top: var(--space-xl); position: relative; }
.chantier__head { margin-bottom: var(--space-l); }
.chantier__grid { display: grid; }
.chantier__figure {
  position: sticky; top: var(--header-h); z-index: 2;
  background: var(--pierre); padding-block: var(--space-s);
  border-bottom: 1px solid var(--color-line);
}
.chantier__stage { max-width: 34rem; margin-inline: auto; }
.house { width: 100%; height: auto; max-height: 44svh; margin-inline: auto; }
.chantier__status { display: flex; align-items: center; justify-content: space-between; gap: var(--space-s); margin-bottom: 0.5rem; }
.chantier__state {
  font-size: var(--step--1); font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 0.3rem 0.6rem; background: var(--ardoise); color: var(--chaux); transition: background .3s;
}
.chantier__state.is-done { background: var(--brique); }
.chantier__bars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; flex: 1; max-width: 14rem; }
.chantier__bars li { height: 6px; background: rgba(29, 33, 37, .15); overflow: hidden; }
.chantier__bars span { display: block; height: 100%; background: var(--brique); transform-origin: left; transform: scaleX(1); }

.chantier__steps { padding-bottom: 30svh; }
.step { min-height: 62svh; padding-block: var(--space-l); display: flex; flex-direction: column; justify-content: center; transition: opacity .4s; }
.js-motion .step { opacity: .28; }
.js-motion .step.is-active { opacity: 1; }
.step__num { font-weight: 600; text-transform: uppercase; letter-spacing: 0.12em; font-size: var(--step--1); color: var(--brique); margin-bottom: var(--space-s); }
.step__num span {
  font-family: var(--font-display); font-weight: 800; font-size: var(--step-3); letter-spacing: -0.03em;
  color: transparent; -webkit-text-stroke: 2px var(--ardoise); margin-right: 0.4rem; vertical-align: -0.15em;
}
.step__title { font-size: var(--step-3); line-height: 1; margin-bottom: var(--space-s); max-width: 14ch; }
.step__text { max-width: 42ch; font-size: var(--step-0); }

/* éléments animés de la maison */
.house__ground { fill: var(--ardoise); }
.brick { fill: #B4462A; }
.brick--v1 { fill: #A33E24; }
.brick--v2 { fill: #BD5535; }
.moss { fill: #5F6E2C; }
.moss--light { fill: #7F8E3B; }
.house__dirt { opacity: 0; }
.house__shine { opacity: 0; }
.house__roller { opacity: 0; }
.house__crack { opacity: 0; }
.js-house .moss { transform-box: fill-box; transform-origin: center; }

@media (min-width: 900px) {
  .chantier__grid { grid-template-columns: 5fr 7fr; column-gap: var(--space-xl); align-items: start; }
  .chantier__figure {
    order: 2; top: calc(var(--header-h) + 2vh); height: calc(100svh - var(--header-h) - 4vh);
    display: flex; align-items: center; border: 0; padding: 0;
  }
  .chantier__stage { width: 100%; max-width: 40rem; }
  .house { max-height: 72svh; }
  .chantier__steps { order: 1; padding-bottom: 20svh; }
  .step { min-height: 88svh; }
}

/* ── Bandeau défilant ──────────────────────────────── */
.marquee { background: var(--ardoise); color: var(--chaux); padding-block: var(--space-l); overflow: hidden; }
.marquee__line {
  display: flex; gap: 0; white-space: nowrap; margin: 0; will-change: transform;
  font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 80;
  font-size: var(--step-4); line-height: 1.1; letter-spacing: -0.03em;
}
.marquee__line span::after { content: "/"; color: var(--brique); margin-inline: 0.45em; }
.marquee__line--b { color: rgba(243, 238, 229, .38); transform: translateX(-30%); }
.marquee__line--b span::after { color: var(--laine); }

/* ── Pour qui ──────────────────────────────────────── */
.clients { padding-block: var(--space-2xl) var(--space-xl); }
.clients__grid { display: grid; gap: var(--space-l); }
.clients__intro { font-size: var(--step-1); line-height: 1.45; max-width: 32ch; margin-top: var(--space-m); color: var(--gris); }
.clients__list { border-top: 3px solid var(--ardoise); }
.client { display: grid; gap: 0.4rem; padding-block: var(--space-m); border-bottom: 1px solid var(--color-line); }
.client__name { font-size: var(--step-2); line-height: 1.05; }
.client p { color: var(--gris); max-width: 46ch; }
@media (min-width: 900px) {
  .clients__grid { grid-template-columns: 5fr 7fr; column-gap: var(--space-xl); align-items: start; }
  .clients__head { position: sticky; top: calc(var(--header-h) + var(--space-l)); }
  .client { grid-template-columns: 15rem 1fr; column-gap: var(--space-l); align-items: baseline; padding-block: var(--space-l); }
}

/* ── Métiers ───────────────────────────────────────── */
.metiers { padding-block: var(--space-xl); background: var(--chaux); border-top: 1px solid var(--color-line); }
.metiers .section-title { margin-bottom: var(--space-l); }
.metiers__list { display: grid; gap: 3px; background: var(--ardoise); border: 3px solid var(--ardoise); }
.metier { background: var(--chaux); padding: var(--space-l) var(--space-m); display: grid; gap: var(--space-s); position: relative; overflow: hidden; }
.metier__num {
  position: absolute; right: -0.05em; top: -0.18em; margin: 0; pointer-events: none;
  font-family: var(--font-display); font-weight: 800; font-size: clamp(6rem, 4rem + 10vw, 12rem); line-height: 1;
  color: transparent; -webkit-text-stroke: 2px rgba(29, 33, 37, .12);
}
.metier__name { font-size: var(--step-3); line-height: 1; }
.metier__lead { color: var(--brique); font-weight: 600; margin-top: 0.4rem; }
.metier__items li { padding: 0.55rem 0 0.55rem 1.6rem; border-top: 1px solid var(--color-line); position: relative; }
.metier__items li::before { content: ""; position: absolute; left: 0; top: 1.05rem; width: 0.9rem; height: 0.45rem; background: var(--ardoise); }
.metier--peinture .metier__items li::before { background: var(--brique); }
.metier--isolation .metier__items li::before { background: var(--laine); }
.metier--toiture .metier__items li::before { background: #5F6E2C; }
@media (min-width: 900px) {
  .metiers__list { grid-template-columns: 1fr 1fr; }
  .metier { padding: var(--space-l); grid-template-rows: auto 1fr; }
}

/* ── Méthode ───────────────────────────────────────── */
.methode { padding-block: var(--space-xl); background: var(--pierre); }
.methode .section-title { margin-bottom: var(--space-l); }
.methode__steps { display: grid; gap: 0; counter-reset: s; }
.methode__steps li { padding: var(--space-m) 0; border-top: 3px solid var(--ardoise); display: grid; grid-template-columns: 3rem 1fr; column-gap: var(--space-s); }
.methode__n { grid-row: span 2; font-family: var(--font-display); font-weight: 800; font-size: var(--step-3); line-height: 0.9; color: var(--brique); }
.methode__steps h3 { font-size: var(--step-1); line-height: 1.15; margin-bottom: 0.4rem; }
.methode__steps p { color: var(--gris); }
@media (min-width: 900px) {
  .methode__steps { grid-template-columns: repeat(4, 1fr); column-gap: var(--space-m); }
  .methode__steps li { grid-template-columns: 1fr; padding-top: var(--space-m); }
  .methode__n { grid-row: auto; margin-bottom: var(--space-m); font-size: var(--step-4); }
  .js-motion .methode__steps[data-reveal] { transform: none; }
  .js-motion .methode__steps[data-reveal] li { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: calc(var(--i) * 120ms); }
  .js-motion .methode__steps.is-visible li { opacity: 1; transform: none; }
}

/* ── Devis ─────────────────────────────────────────── */
.devis { background: var(--ardoise); color: var(--chaux); padding-block: var(--space-xl); }
.devis .kicker { color: var(--laine); }
.devis__grid { display: grid; gap: var(--space-l); }
.devis__intro { font-size: var(--step-1); line-height: 1.45; max-width: 32ch; margin-top: var(--space-m); color: rgba(243, 238, 229, .8); }
.devis__place { margin-top: var(--space-l); padding-top: var(--space-m); border-top: 1px solid rgba(243, 238, 229, .25); }
.devis__place-title { font-family: var(--font-display); font-weight: 700; font-size: var(--step-1); margin-bottom: 0.3rem; }
.devis__place address { font-style: normal; color: rgba(243, 238, 229, .75); }
.devis__phone { display: inline-block; margin-top: var(--space-s); font-family: var(--font-display); font-weight: 800; font-size: var(--step-3); text-decoration: none; }

.devis-form { display: grid; gap: var(--space-m); grid-template-columns: 1fr; }
.devis-form fieldset { border: 0; padding: 0; margin: 0; }
.devis-form legend, .devis-form label:not(.chip) { display: block; font-weight: 600; margin-bottom: 0.5rem; font-size: var(--step--1); letter-spacing: 0.06em; text-transform: uppercase; color: rgba(243, 238, 229, .85); }
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chips legend { width: 100%; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chip span { display: inline-block; padding: 0.55rem 0.9rem; border: 2px solid rgba(243, 238, 229, .35); transition: background .2s, border-color .2s, color .2s; }
.chip:hover span { border-color: var(--chaux); }
.chip input:checked + span { background: var(--laine); border-color: var(--laine); color: var(--ardoise); font-weight: 600; }
.chip input:focus-visible + span { outline: 2px solid var(--laine); outline-offset: 3px; }
.field input, .field textarea {
  width: 100%; padding: 0.85rem 0.9rem; background: var(--chaux); color: var(--ardoise);
  border: 2px solid var(--chaux); border-radius: 0; font-size: 1rem;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--laine); }
.field__hint { font-size: var(--step--1); color: rgba(243, 238, 229, .6); margin-top: 0.4rem; }
.devis-form__submit { display: grid; gap: var(--space-s); }
.devis-form__submit .btn { width: 100%; }
.devis-form__status { font-weight: 600; color: var(--laine); min-height: 1.5em; }
@media (min-width: 640px) {
  .devis-form { grid-template-columns: 1fr 1fr; }
  .devis-form fieldset, .field--wide, .devis-form__submit { grid-column: 1 / -1; }
  .devis-form__submit .btn { width: auto; justify-self: start; }
}
@media (min-width: 900px) {
  .devis__grid { grid-template-columns: 5fr 7fr; column-gap: var(--space-xl); align-items: start; }
}

/* ── Pied de page ──────────────────────────────────── */
.site-footer { background: var(--ardoise); color: var(--chaux); border-top: 1px solid rgba(243, 238, 229, .15); padding-block: var(--space-l) var(--space-m); }
.site-footer__inner { display: grid; gap: var(--space-l); }
.site-footer__brand svg { height: 3.4rem; width: auto; margin-bottom: var(--space-s); }
.site-footer__tagline { max-width: 34ch; color: rgba(243, 238, 229, .7); }
.site-footer__label { font-size: var(--step--1); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--laine); margin-bottom: 0.5rem; }
.site-footer address { font-style: normal; margin-bottom: 0.5rem; }
.site-footer a { text-decoration-color: rgba(243, 238, 229, .4); text-underline-offset: 3px; }
.site-footer__contact li { margin-bottom: 0.3rem; }
.site-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-s); margin-top: var(--space-l); padding-top: var(--space-m); border-top: 1px solid rgba(243, 238, 229, .15); font-size: var(--step--1); color: rgba(243, 238, 229, .55); }
.site-footer__bottom p { margin: 0; }
@media (min-width: 900px) {
  .site-footer__inner { grid-template-columns: 2fr 1fr 1fr; }
}

/* ── CTA mobile ────────────────────────────────────── */
.sticky-cta { display: none; }
@media (max-width: 899px) {
  .sticky-cta { display: flex; gap: 0.5rem; transition: transform .35s var(--ease); }
  .sticky-cta.is-hidden { transform: translateY(160%); }
  .sticky-cta__link {
    flex: 1; display: block; text-align: center; padding: 1rem; font-weight: 600; text-decoration: none;
    background: var(--brique); color: var(--color-on-accent); box-shadow: 0 6px 0 var(--ardoise);
  }
  .sticky-cta__link--ghost { flex: 0 0 auto; background: var(--ardoise); color: var(--chaux); box-shadow: none; }
}

/* Révélation au défilement, sur quelques éléments choisis */
.js-motion [data-reveal] { transform: translateY(32px); }

@media (max-width: 899px) {
  body { padding-bottom: 0; }
  .site-footer { padding-bottom: 6.5rem; }
}
