/* ============================================================
   HelderPiscine — feuille de style principale
   Concept : eau · lumière du Sud-Ouest · formes organiques
   ============================================================ */

/* ---------- Fonts (auto-hébergées) ---------- */
@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('../fonts/bricolage-grotesque.woff2') format('woff2');
  font-weight: 200 800;
  font-display: swap;
  font-style: normal;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
  font-style: normal;
}

/* ---------- Tokens ---------- */
:root {
  /* Eau — teal profond, béton & eau */
  --eau-900: #0c2b30;
  --eau-800: #123a41;
  --eau-700: #1b525a;
  --eau-600: #2a6b73;
  --eau-500: #3f8990;
  --eau-400: #6aa6ab;
  --eau-200: #aecccd;

  /* Accent argile — terreux, mat, froid (ancien "brique", plus d'orange vif) */
  --brique: #9a7d68;
  --brique-600: #7e6450;
  --brique-clair: #b89a84;
  --brique-pale: #e4ddce;

  /* Pierre / béton clair */
  --creme: #f0ede6;
  --creme-2: #e6e1d7;
  --sable: #d9d3c6;

  /* Encre */
  --encre: #152528;
  --encre-soft: #4c5a5c;

  /* Typo */
  --font-display: 'Bricolage Grotesque', 'Segoe UI', system-ui, sans-serif;
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* Échelle fluide */
  --step--1: clamp(0.83rem, 0.79rem + 0.2vw, 0.94rem);
  --step-0:  clamp(1rem, 0.95rem + 0.25vw, 1.15rem);
  --step-1:  clamp(1.2rem, 1.1rem + 0.5vw, 1.5rem);
  --step-2:  clamp(1.5rem, 1.3rem + 1vw, 2.1rem);
  --step-3:  clamp(2rem, 1.6rem + 2vw, 3.2rem);
  --step-4:  clamp(2.6rem, 1.9rem + 3.4vw, 4.8rem);
  --step-5:  clamp(3.2rem, 2rem + 6vw, 7rem);

  /* Espace */
  --gutter: clamp(1.25rem, 5vw, 5rem);
  --section-y: clamp(4.5rem, 9vw, 9rem);
  --radius: 14px;

  /* Divers */
  --maxw: 1320px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.65;
  color: var(--encre);
  background: var(--creme);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, picture, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; padding: 0; }

/* Lenis */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* ---------- Typographie ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.02em;
  color: var(--eau-900);
}
.display {
  font-size: var(--step-5);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.03em;
}
.h1 { font-size: var(--step-4); }
.h2 { font-size: var(--step-3); }
.h3 { font-size: var(--step-2); }

.eyebrow {
  font-family: var(--font-sans);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brique);
  display: inline-block;
}
.lead { font-size: var(--step-1); color: var(--encre-soft); line-height: 1.55; }
.muted { color: var(--encre-soft); }

/* ---------- Layout ---------- */
.wrap { width: min(100% - var(--gutter) * 2, var(--maxw)); margin-inline: auto; }
.section { padding-block: var(--section-y); position: relative; }
.stack > * + * { margin-top: 1.1rem; }
.stack-lg > * + * { margin-top: 2rem; }

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.6em;
  padding: 0.95em 1.6em;
  border-radius: 2px;
  font-weight: 600;
  font-size: var(--step-0);
  letter-spacing: -0.005em;
  transition: transform 0.4s var(--ease), background 0.3s, color 0.3s, box-shadow 0.3s;
  will-change: transform;
}
.btn svg { width: 1.1em; height: 1.1em; transition: transform 0.4s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn-primary {
  background: var(--eau-900); color: var(--creme);
}
.btn-primary:hover { background: var(--eau-800); transform: translateY(-2px); }
.btn-ghost {
  background: transparent; color: var(--eau-900);
  box-shadow: inset 0 0 0 1px rgba(21, 37, 40, 0.35);
}
.btn-ghost:hover { box-shadow: inset 0 0 0 1px var(--eau-900); }
.btn-light { background: var(--creme); color: var(--eau-900); box-shadow: inset 0 0 0 1px rgba(21,37,40,0.12); }
.btn-light:hover { transform: translateY(-2px); background: #fff; }

/* ---------- Header / nav ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  padding-block: 1.1rem;
  transition: background 0.4s var(--ease), box-shadow 0.4s, padding 0.4s;
}
.site-header.scrolled {
  background: rgba(250, 244, 236, 0.82);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(16, 36, 43, 0.08);
  padding-block: 0.7rem;
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: flex; align-items: center; gap: 0.6rem; font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; letter-spacing: -0.02em; color: var(--eau-900); }
.brand .mark { width: 34px; height: 34px; flex: none; }
/* .nav-links = wrapper (simple <div> sur desktop, panneau fixed sur mobile) ; .nav-menu = la vraie liste de liens */
.nav-links { display: contents; }
.nav-menu { display: flex; align-items: center; gap: clamp(1rem, 2vw, 2rem); }
.nav-menu a { font-size: var(--step--1); font-weight: 500; color: var(--encre-soft); position: relative; padding-block: 0.3em; transition: color 0.25s; }
.nav-menu a::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1.5px; background: var(--brique); transform: scaleX(0); transform-origin: left; transition: transform 0.35s var(--ease); }
.nav-menu a:hover, .nav-menu a.active { color: var(--eau-900); }
.nav-menu a:hover::after, .nav-menu a.active::after { transform: scaleX(1); }
.nav-cta { display: flex; align-items: center; gap: 1rem; }
.nav-phone { font-weight: 600; color: var(--eau-900); font-size: var(--step--1); display: inline-flex; align-items: center; gap: 0.45em; }

.nav-toggle { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; flex: none; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--eau-900); position: relative; transition: 0.3s; }
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; width: 22px; height: 2px; background: var(--eau-900); transition: 0.3s var(--ease); }
.nav-toggle span::before { top: -7px; }
.nav-toggle span::after { top: 7px; }
body.nav-open .nav-toggle span { background: transparent; }
body.nav-open .nav-toggle span::before { top: 0; transform: rotate(45deg); }
body.nav-open .nav-toggle span::after { top: 0; transform: rotate(-45deg); }

.nav-backdrop { display: none; }
.nav-mobile-foot { display: none; }

@media (max-width: 900px) {
  .nav-toggle { display: flex; position: relative; z-index: 151; }
  .nav-cta .btn-primary { display: none; } /* évite le débordement topbar : la CTA vit au pied du menu */

  /* Fond assombri derrière le panneau, cliquable pour refermer */
  .nav-backdrop {
    display: block; position: fixed; inset: 0; z-index: 149;
    background: rgba(8,26,30,0.55);
    opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease), visibility 0s linear 0.4s;
  }
  body.nav-open .nav-backdrop { opacity: 1; visibility: visible; transition-delay: 0s; }
  body.nav-open { overflow: hidden; }
  /* Le backdrop-filter d'un ancêtre crée un nouveau bloc de positionnement pour les
     descendants fixed : ça effondrait le panneau menu (position:fixed) à la hauteur
     du header au lieu du viewport. On le désactive tant que le menu est ouvert. */
  body.nav-open .site-header.scrolled { backdrop-filter: none; }

  .nav-links {
    display: flex; flex-direction: column;
    position: fixed; inset: 0 0 0 auto; z-index: 150; width: min(84vw, 360px);
    padding: clamp(6.5rem, 15vw, 8rem) var(--gutter) 2rem;
    background: var(--creme); box-shadow: -30px 0 70px -34px rgba(6,20,24,0.5);
    transform: translateX(100%); transition: transform 0.5s var(--ease);
    overflow-y: auto;
  }
  body.nav-open .nav-links { transform: translateX(0); }

  .nav-menu { display: flex; flex-direction: column; gap: 0; width: 100%; }
  .nav-menu a {
    display: block; width: 100%; padding-block: 0.95rem;
    font-size: var(--step-1); font-family: var(--font-display); font-weight: 700; color: var(--eau-900);
    border-bottom: 1px solid rgba(21,37,40,0.12);
  }
  .nav-menu a::after { display: none; }
  .nav-phone span { display: none; }

  .nav-mobile-foot { display: flex; flex-direction: column; gap: 0.9rem; width: 100%; margin-top: auto; padding-top: 1.8rem; }
  .nav-mobile-foot .btn { width: 100%; justify-content: center; }
  .nav-mobile-foot .nav-phone-full { display: flex; align-items: center; justify-content: center; gap: 0.5rem; font-weight: 600; color: var(--eau-900); font-size: var(--step-0); padding-block: 0.4rem; }
}

/* ---------- Hero plein cadre + scroll cinématique (photo & « ligne d'eau ») ---------- */
.hero { position: relative; min-height: 100svh; display: flex; align-items: center; overflow: hidden; background: var(--eau-900); isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 52%; transform: scale(1.06); will-change: transform; }
.hero-veil {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(8,26,30,0.55) 0%, rgba(8,26,30,0) 20%),
    linear-gradient(90deg, rgba(8,26,30,0.80) 0%, rgba(8,26,30,0.46) 40%, rgba(8,26,30,0.10) 70%, rgba(8,26,30,0) 100%),
    linear-gradient(0deg, rgba(8,26,30,0.62) 0%, rgba(8,26,30,0) 44%);
}
.hero-inner { position: relative; z-index: 2; padding-block: clamp(5.5rem, 12vh, 9rem); }
.hero-copy { max-width: 42ch; will-change: transform, opacity; }
.hero-eyebrow { display: inline-block; color: var(--eau-200); margin-bottom: 1.1rem; }
.hero-title {
  color: var(--creme); font-family: var(--font-display); font-weight: 700;
  line-height: 1.0; letter-spacing: -0.025em;
  font-size: clamp(2.5rem, 1rem + 4.3vw, 4.6rem);
  text-wrap: balance; text-shadow: 0 2px 30px rgba(6,20,24,0.35);
}
.hero-title em { font-style: normal; color: var(--eau-200); }
.hero-lead { color: rgba(240,237,230,0.88); max-width: 46ch; margin-top: 1.4rem; font-size: var(--step-1); text-shadow: 0 1px 18px rgba(6,20,24,0.35); }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.6rem; margin-top: 2.4rem; }
.btn-lg { padding: 1.05em 2em; font-size: var(--step-1); }
.hero .btn-primary { background: var(--creme); color: var(--eau-900); box-shadow: 0 18px 40px -18px rgba(0,0,0,0.55); }
.hero .btn-primary:hover { background: #fff; color: var(--eau-900); }
.hero-call { color: rgba(240,237,230,0.9); font-size: var(--step-0); }
.hero-call a { font-weight: 700; color: var(--creme); border-bottom: 1.5px solid var(--brique-clair); padding-bottom: 1px; white-space: nowrap; transition: border-color 0.25s; }
.hero-call a:hover { border-color: var(--creme); }
.hero-wave { position: absolute; left: 0; right: 0; bottom: -1px; z-index: 3; width: 100%; height: clamp(46px, 7vw, 104px); color: var(--eau-900); pointer-events: none; }

@media (max-width: 900px) {
  .hero-veil {
    background:
      linear-gradient(180deg, rgba(8,26,30,0.5) 0%, rgba(8,26,30,0) 18%),
      linear-gradient(0deg, rgba(8,26,30,0.74) 0%, rgba(8,26,30,0.12) 58%, rgba(8,26,30,0.34) 100%);
  }
  .hero-copy { max-width: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg img { transform: none; }
}

/* Header clair tant qu'on est au-dessus du hero photo (page d'accueil) ; bascule en foncé/frosté dès le scroll */
body.home .site-header:not(.scrolled) .brand { color: var(--creme); }
body.home .site-header:not(.scrolled) .brand span { color: var(--brique-clair) !important; }
body.home .site-header:not(.scrolled) .nav-links a { color: rgba(240,237,230,0.9); }
body.home .site-header:not(.scrolled) .nav-links a:hover,
body.home .site-header:not(.scrolled) .nav-links a.active { color: #fff; }
body.home .site-header:not(.scrolled) .nav-phone { color: var(--creme); }
body.home .site-header:not(.scrolled) .nav-toggle span,
body.home .site-header:not(.scrolled) .nav-toggle span::before,
body.home .site-header:not(.scrolled) .nav-toggle span::after { background: var(--creme); }
body.home .site-header:not(.scrolled) .btn-primary { background: var(--creme); color: var(--eau-900); }

/* ---------- Bandeau confiance ---------- */
.trust { background: var(--eau-900); color: var(--creme); padding-block: clamp(2.2rem, 4vw, 3rem); }
.trust-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 2rem; text-align: center; }
.trust-item .n { font-family: var(--font-display); font-size: var(--step-3); font-weight: 700; color: var(--eau-200); line-height: 1; letter-spacing: -0.03em; }
.trust-item .l { font-size: var(--step--1); color: rgba(250,244,236,0.7); margin-top: 0.5rem; letter-spacing: 0.03em; }

/* ---------- Section header ---------- */
.section-head { max-width: 60ch; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head .h2 { margin-top: 0.8rem; }
.section-head p { margin-top: 1.1rem; }

/* ---------- Image organique (motif haricot) ---------- */
.blob-img { position: relative; }
.blob-img img { width: 100%; object-fit: cover; border-radius: 42% 58% 63% 37% / 47% 42% 58% 53%; }
.blob-img.alt img { border-radius: 58% 42% 38% 62% / 55% 47% 53% 45%; }
.blob-img::before {
  content: ""; position: absolute; inset: -10% -6% auto auto; width: 55%; aspect-ratio: 1;
  background: radial-gradient(circle at 30% 30%, var(--brique-pale), transparent 70%);
  z-index: -1; top: -8%; right: -6%;
}

/* ---------- Cartes modèles ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: clamp(1.4rem, 3vw, 2.2rem); }
.card {
  background: var(--creme); border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 1px 0 rgba(16,36,43,0.06), 0 30px 50px -40px rgba(16,36,43,0.35);
  transition: transform 0.5s var(--ease), box-shadow 0.5s;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 40px 60px -35px rgba(16,36,43,0.45); }
.card-media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--eau-800); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.card:hover .card-media img { transform: scale(1.06); }
.card-body { padding: 1.4rem 1.5rem 1.7rem; display: flex; flex-direction: column; gap: 0.6rem; flex: 1; }
.card-body h3 { font-size: var(--step-2); }
.card-tag { font-size: var(--step--1); font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brique); }
.card-specs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: auto; padding-top: 0.8rem; }
.chip { font-size: var(--step--1); padding: 0.35em 0.8em; border-radius: 100px; background: var(--creme-2); color: var(--encre-soft); font-weight: 500; }

/* ---------- Étapes (process) ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px,100%), 1fr)); gap: clamp(1.6rem, 3vw, 2.4rem); counter-reset: step; }
.step { position: relative; padding-top: 3.4rem; }
.step::before { counter-increment: step; content: "0" counter(step); position: absolute; top: 0; left: 0; font-family: var(--font-display); font-weight: 700; font-size: var(--step-3); color: var(--brique); opacity: 0.9; line-height: 1; }
.step h3 { font-size: var(--step-1); margin-bottom: 0.5rem; }

/* ---------- Flow : bandes alternées pleine largeur ---------- */
.flow { display: flex; flex-direction: column; gap: clamp(1rem, 2.2vw, 1.6rem); margin-top: clamp(2.5rem, 5vw, 4rem); overflow-x: clip; padding-block: 10px; }
.flow-band {
  width: min(72%, 840px);
  display: flex; align-items: center; gap: clamp(1.2rem, 2.5vw, 2.2rem);
  padding: clamp(1.5rem, 3vw, 2.3rem) clamp(1.6rem, 4vw, 3.2rem);
}
.flow-band .fb-num { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.6rem, 5vw, 4.2rem); line-height: 0.9; flex: none; letter-spacing: -0.03em; }
.flow-band .fb-body h3 { font-size: var(--step-2); margin-bottom: 0.3rem; }
.flow-band .fb-body p { color: var(--encre-soft); max-width: 44ch; }
.flow-band:nth-child(odd) {
  margin-right: auto; border-radius: 0 clamp(28px, 5vw, 72px) clamp(28px, 5vw, 72px) 0;
  background: var(--creme); box-shadow: 0 30px 60px -42px rgba(6,39,47,0.5);
}
.flow-band:nth-child(odd) .fb-num { color: var(--brique); }
.flow-band:nth-child(even) {
  margin-left: auto; flex-direction: row-reverse; text-align: right;
  border-radius: clamp(28px, 5vw, 72px) 0 0 clamp(28px, 5vw, 72px);
  background: var(--eau-900); color: var(--creme);
}
.flow-band:nth-child(even) .fb-body h3 { color: var(--creme); }
.flow-band:nth-child(even) .fb-body p { color: rgba(250,244,236,0.8); margin-left: auto; }
.flow-band:nth-child(even) .fb-num { color: var(--brique-clair); }

.reveal.from-left { transform: translateX(-80px); }
.reveal.from-right { transform: translateX(80px); }
.reveal.from-left.in, .reveal.from-right.in { transform: none; }

@media (max-width: 820px) {
  .flow-band { width: 100%; flex-direction: row !important; text-align: left !important; border-radius: 18px !important; margin: 0 !important; gap: 1.2rem; }
  .flow-band .fb-body p { margin-left: 0 !important; }
  .reveal.from-left, .reveal.from-right { transform: translateY(28px); }
}

/* ---------- Parcours en serpent (process zigzag) ---------- */
.journey { position: relative; max-width: 940px; margin: 0 auto; padding: 0; list-style: none; display: grid; gap: clamp(1.5rem, 4vw, 3rem); }
.journey::before {
  content: ""; position: absolute; z-index: 0; top: 1.5rem; bottom: 1.5rem; left: 50%; transform: translateX(-50%); width: 40px;
  background: center top / 40px 80px repeat-y
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='80'%3E%3Cpath d='M20 0 C36 18 4 26 20 40 C36 54 4 62 20 80' fill='none' stroke='%23c0563a' stroke-width='2.5' stroke-opacity='0.45' stroke-linecap='round'/%3E%3C/svg%3E");
}
.journey-step { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 72px 1fr; align-items: center; gap: clamp(1rem, 2vw, 1.8rem); }
.journey-step .jn {
  grid-column: 2; justify-self: center; z-index: 2;
  width: 64px; height: 64px; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: var(--step-1);
  color: var(--brique); background: var(--creme);
  box-shadow: inset 0 0 0 2px var(--brique), 0 14px 28px -14px rgba(6,39,47,0.45);
}
.journey-step .jc h3 { font-size: var(--step-1); margin-bottom: 0.4rem; }
.journey-step .jc p { color: var(--encre-soft); }
.journey-step:nth-child(odd) .jc { grid-column: 1; text-align: right; }
.journey-step:nth-child(even) .jc { grid-column: 3; text-align: left; }
@media (max-width: 720px) {
  .journey::before { left: 32px; }
  .journey-step { grid-template-columns: 64px 1fr; gap: 1.2rem; align-items: start; }
  .journey-step .jn { grid-column: 1; width: 56px; height: 56px; }
  .journey-step:nth-child(odd) .jc,
  .journey-step:nth-child(even) .jc { grid-column: 2; text-align: left; }
}

/* ---------- Section eau (fond profond) ---------- */
.deep { background: var(--eau-900); color: var(--creme); position: relative; overflow: hidden; }
.deep h2, .deep h3 { color: var(--creme); }
.deep .lead, .deep .muted { color: rgba(250,244,236,0.75); }
.deep .eyebrow { color: var(--brique-clair); }
.deep-glow { position: absolute; width: 60vw; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(28,125,151,0.35), transparent 65%); filter: blur(20px); top: -20%; right: -10%; z-index: 0; pointer-events: none; }
.deep .wrap { position: relative; z-index: 1; }

/* ---------- Réalisations (galerie asymétrique) ---------- */
.gallery { display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(0.8rem, 2vw, 1.4rem); overflow-x: clip; }
/* Galerie « glissée » : l'anim est pilotée par le conteneur (.gallery.reveal),
   qui reste en place et est donc bien détecté par l'IntersectionObserver ;
   les photos, elles, peuvent partir loin hors champ sans casser le déclenchement. */
.gallery.reveal { opacity: 1; transform: none; transition: none; }
.gallery.reveal .g-left  { transform: translateX(-52vw) rotate(-1.4deg); opacity: 0; transition: transform 1s var(--ease), opacity 0.7s var(--ease); }
.gallery.reveal .g-right { transform: translateX(52vw) rotate(1.4deg); opacity: 0; transition: transform 1s var(--ease), opacity 0.7s var(--ease); }
.gallery.reveal.in .g-left, .gallery.reveal.in .g-right { transform: none; opacity: 1; }
.gallery.reveal.in > *:nth-child(2) { transition-delay: 0.09s; }
.gallery.reveal.in > *:nth-child(3) { transition-delay: 0.18s; }
.gallery.reveal.in > *:nth-child(4) { transition-delay: 0.27s; }
.gallery figure { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--eau-800); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.gallery figure:hover img { transform: scale(1.05); }
.gallery figcaption { position: absolute; inset: auto 0 0 0; padding: 1.4rem 1.2rem 1rem; color: var(--creme); font-family: var(--font-display); font-weight: 600; background: linear-gradient(transparent, rgba(6,39,47,0.8)); font-size: var(--step-0); }
.g-a { grid-column: span 4; aspect-ratio: 16/10; }
.g-b { grid-column: span 2; aspect-ratio: 3/4; }
.g-c { grid-column: span 2; aspect-ratio: 1; }
.g-d { grid-column: span 4; aspect-ratio: 16/8; }
@media (max-width: 720px) {
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .g-a, .g-b, .g-c, .g-d { grid-column: span 2; aspect-ratio: 4/3; }
  .gallery.reveal .g-left, .gallery.reveal .g-right { transform: translateY(30px) rotate(0); }
  .gallery.reveal.in .g-left, .gallery.reveal.in .g-right { transform: none; }
}

/* ---------- Témoignages ---------- */
.reviews { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px,100%), 1fr)); gap: clamp(1.4rem,3vw,2.2rem); }
.review { background: var(--creme); border-radius: var(--radius); padding: 2rem 1.8rem; box-shadow: 0 30px 50px -42px rgba(16,36,43,0.4); display: flex; flex-direction: column; gap: 1.1rem; }
.deep .review { background: rgba(255,255,255,0.05); backdrop-filter: blur(4px); box-shadow: none; border: 1px solid rgba(255,255,255,0.08); }
.stars { display: flex; gap: 0.2rem; color: var(--brique); }
.deep .stars { color: var(--brique-clair); }
.stars svg { width: 1.1em; height: 1.1em; }
.review p { font-size: var(--step-1); line-height: 1.5; }
.deep .review p { color: rgba(250,244,236,0.92); }
.review-author { display: flex; align-items: center; gap: 0.8rem; margin-top: auto; }
.review-author .av { width: 44px; height: 44px; border-radius: 50%; background: var(--brique); color: var(--creme); display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; }
.review-author .who { font-weight: 600; color: var(--eau-900); }
.deep .review-author .who { color: var(--creme); }
.review-author .loc { font-size: var(--step--1); color: var(--encre-soft); }
.deep .review-author .loc { color: rgba(250,244,236,0.6); }

/* ---------- CTA bande ---------- */
.cta-band { position: relative; overflow: hidden; border-radius: clamp(20px, 3vw, 36px); background: var(--brique); color: var(--creme); padding: clamp(2.5rem, 6vw, 5rem); }
.cta-band h2 { color: var(--creme); max-width: 18ch; }
.cta-band::before { content: ""; position: absolute; width: 40%; aspect-ratio: 1; border-radius: 50%; background: rgba(255,255,255,0.1); top: -20%; right: -8%; }
.cta-band .btn-light { position: relative; }

/* ---------- Formulaire ---------- */
.form-card { background: var(--creme); border-radius: clamp(18px, 2vw, 28px); padding: clamp(1.8rem, 4vw, 3rem); box-shadow: 0 40px 70px -50px rgba(16,36,43,0.5); }
.field { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1.2rem; }
.field label { font-size: var(--step--1); font-weight: 600; color: var(--eau-900); letter-spacing: 0.01em; }
.field input, .field select, .field textarea {
  font: inherit; font-size: var(--step-0); color: var(--encre);
  padding: 0.85em 1em; border-radius: 12px; background: var(--creme-2);
  border: 1.5px solid transparent; transition: border 0.25s, background 0.25s;
  width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--eau-500); background: #fff; }
.field textarea { resize: vertical; min-height: 120px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }
.form-note { font-size: var(--step--1); color: var(--encre-soft); margin-top: 0.5rem; }
.form-success { display: none; text-align: center; padding: 1rem 0; }
.form-success svg { width: 56px; height: 56px; color: var(--eau-500); margin: 0 auto 1rem; }
form.sent .form-body { display: none; }
form.sent .form-success { display: block; }

/* ---------- Contact aside ---------- */
.contact-info { display: flex; flex-direction: column; gap: 1.6rem; }
.contact-line { display: flex; gap: 1rem; align-items: flex-start; }
.contact-line .ico { width: 44px; height: 44px; flex: none; border-radius: 12px; background: var(--brique-pale); color: var(--brique-600); display: grid; place-items: center; }
.contact-line .ico svg { width: 1.3em; height: 1.3em; }
.contact-line .lbl { font-size: var(--step--1); color: var(--encre-soft); text-transform: uppercase; letter-spacing: 0.12em; }
.contact-line .val { font-weight: 600; color: var(--eau-900); font-size: var(--step-1); }
.map-embed { border-radius: var(--radius); overflow: hidden; aspect-ratio: 16/9; background: var(--eau-800); border: 0; width: 100%; box-shadow: 0 30px 50px -45px rgba(16,36,43,0.4); }

/* ---------- Footer ---------- */
.site-footer { background: var(--eau-900); color: rgba(250,244,236,0.75); padding-block: clamp(3.5rem, 6vw, 5rem) 2rem; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 2.5rem; }
@media (max-width: 820px) { .footer-top { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-top { grid-template-columns: 1fr; } }
.site-footer .brand { color: var(--creme); margin-bottom: 1rem; }
.footer-col h4 { color: var(--creme); font-size: var(--step-0); margin-bottom: 1rem; font-family: var(--font-sans); font-weight: 600; letter-spacing: 0.02em; }
.footer-col a { display: block; padding-block: 0.35rem; transition: color 0.25s; }
.footer-col a:hover { color: var(--brique-clair); }
.footer-bottom { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid rgba(250,244,236,0.12); font-size: var(--step--1); }
.footer-bottom a:hover { color: var(--brique-clair); }

/* ---------- Divider organique ---------- */
.wave { display: block; width: 100%; height: auto; }
.wave-top { margin-bottom: -1px; }

/* ---------- Reveal animations ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-scroll::after { animation: none; }
  * { scroll-behavior: auto !important; }
}

/* ---------- Utilitaires ---------- */
.text-center { text-align: center; }
.mt-lg { margin-top: clamp(2.5rem, 5vw, 4rem); }
.badge-local { display: inline-flex; align-items: center; gap: 0.5em; font-size: var(--step--1); font-weight: 600; color: var(--brique); background: var(--brique-pale); padding: 0.5em 1em; border-radius: 100px; }

/* ---------- Page hero (sous-pages) ---------- */
.page-hero { position: relative; background: var(--creme); padding-top: clamp(7rem, 12vw, 10rem); padding-bottom: clamp(2.5rem, 5vw, 4rem); overflow: hidden; }
.page-hero::before { content: ""; position: absolute; top: -22%; right: -8%; width: min(46vw, 560px); aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 40% 40%, var(--brique-pale), transparent 68%); opacity: 0.7; z-index: 0; pointer-events: none; }
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero h1 { font-size: var(--step-4); max-width: 18ch; margin-top: 0.7rem; }
.page-hero .lead { margin-top: 1.2rem; max-width: 56ch; }
.breadcrumb { font-size: var(--step--1); color: var(--encre-soft); letter-spacing: 0.02em; }
.breadcrumb a:hover { color: var(--brique); }

/* ---------- Split (rangées alternées) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.split.rev .split-media { order: 2; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } .split.rev .split-media { order: 0; } }

/* ---------- Checklist ---------- */
.checklist { display: grid; gap: 0.9rem; }
.checklist li { display: flex; gap: 0.8rem; align-items: flex-start; }
.checklist .ic { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--brique-pale); color: var(--brique-600); display: grid; place-items: center; margin-top: 2px; }
.checklist .ic svg { width: 15px; height: 15px; }
.deep .checklist .ic { background: rgba(255,255,255,0.1); color: var(--brique-clair); }

/* ---------- Value cards ---------- */
.values { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: clamp(1.4rem, 3vw, 2rem); }
.value { background: var(--creme); border-radius: var(--radius); padding: 2rem 1.8rem; box-shadow: 0 30px 50px -42px rgba(16,36,43,0.35); }
.value .vi { width: 52px; height: 52px; border-radius: 14px; background: var(--brique-pale); color: var(--brique-600); display: grid; place-items: center; margin-bottom: 1.1rem; }
.value .vi svg { width: 26px; height: 26px; }
.value h3 { font-size: var(--step-1); margin-bottom: 0.5rem; }

/* ---------- Fiche d'engagement (à propos) ---------- */
.engagement {
  max-width: 860px; margin: 0 auto; background: var(--creme);
  border: 1px solid rgba(21,37,40,0.16); border-radius: 3px;
  padding: clamp(1.8rem, 4vw, 3.4rem) clamp(1.5rem, 4vw, 3.6rem) clamp(1.6rem, 3vw, 2.6rem);
  box-shadow: 0 40px 70px -50px rgba(16,36,43,0.5);
  position: relative;
}
.engagement::before {
  content: "RÉF. HP-01"; position: absolute; top: 0; right: 0;
  font-family: var(--font-display); font-size: 0.7rem; letter-spacing: 0.14em;
  color: var(--encre-soft); background: var(--creme-2);
  padding: 0.45em 0.9em; border-left: 1px solid rgba(21,37,40,0.16); border-bottom: 1px solid rgba(21,37,40,0.16);
}
.eng-head { border-bottom: 1.5px solid var(--encre); padding-bottom: clamp(1rem, 2vw, 1.4rem); margin-bottom: clamp(1.2rem, 2.5vw, 1.8rem); }
.eng-head .eyebrow { margin-bottom: 0.6rem; }
.eng-head h2 { font-size: clamp(1.5rem, 1rem + 1.6vw, 2.1rem); }
.eng-list { list-style: none; padding: 0; margin: 0; display: grid; }
.eng-list li { display: grid; grid-template-columns: auto 1fr; gap: clamp(0.9rem, 2vw, 1.4rem); align-items: baseline; padding: clamp(0.95rem, 2vw, 1.25rem) 0; border-bottom: 1px dashed rgba(21,37,40,0.18); }
.eng-list li:last-child { border-bottom: 0; }
.eng-list .ec { width: 26px; height: 26px; flex: none; border-radius: 2px; background: var(--eau-900); color: var(--creme); display: grid; place-items: center; transform: translateY(2px); }
.eng-list .ec svg { width: 15px; height: 15px; }
.eng-list strong { font-family: var(--font-display); font-weight: 700; color: var(--encre); font-size: var(--step-1); display: block; margin-bottom: 0.2rem; }
.eng-list p { color: var(--encre-soft); margin: 0; font-size: var(--step-0); }
.eng-sign { display: flex; align-items: flex-end; justify-content: flex-end; gap: 1rem; margin-top: clamp(1.4rem, 3vw, 2.2rem); }
.eng-sign .sig-block { text-align: right; }
.eng-sign svg.sig { display: block; margin-left: auto; width: clamp(120px, 22vw, 168px); height: auto; color: var(--eau-800); }
.eng-sign .sig-name { display: block; font-family: var(--font-display); font-weight: 600; color: var(--encre); margin-top: 0.35rem; }
.eng-sign .sig-role { display: block; font-size: 0.85rem; color: var(--encre-soft); letter-spacing: 0.02em; }
@media (max-width: 560px) {
  .eng-sign { flex-direction: column; align-items: flex-end; }
  .engagement::before { position: static; display: inline-block; margin-bottom: 1rem; border: 1px solid rgba(21,37,40,0.16); }
}

/* ---------- Spec list (modèles) ---------- */
.spec-list { display: grid; gap: 0; margin-top: 1.2rem; }
.spec-list div { display: flex; justify-content: space-between; gap: 1rem; padding-block: 0.8rem; border-bottom: 1px solid rgba(16,36,43,0.1); font-size: var(--step-0); }
.spec-list .k { color: var(--encre-soft); }
.spec-list .v { font-weight: 600; color: var(--eau-900); text-align: right; }

/* ---------- Price tag ---------- */
.price-tag { display: inline-flex; align-items: baseline; gap: 0.5rem; margin-top: 1.4rem; }
.price-tag .amt { font-family: var(--font-display); font-weight: 700; font-size: var(--step-3); color: var(--brique); line-height: 1; }
.price-tag .cur { font-size: var(--step-0); color: var(--encre-soft); }

/* ---------- Grain béton (matière, statique) ---------- */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 9999; pointer-events: none;
  opacity: 0.09; mix-blend-mode: multiply; background-size: 170px 170px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='170' height='170'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='170' height='170' filter='url(%23n)'/%3E%3C/svg%3E");
}
@media (prefers-reduced-motion: reduce) { body::after { opacity: 0.06; } }
