/* ==========================================================================
   RÉNOVA HABITAT — Rénovation générale, tous corps de métier
   DA : contemporaine, épurée, haut de gamme.
   Palette : chaux / graphite / vert profond + neutres.
   Type : Instrument Serif (display) × Inter (corps).
   Grille asymétrique, animations au service de la lisibilité.
   ========================================================================== */

/* ---------- 1. Typographies auto-hébergées (SIL OFL) ---------- */
@font-face { font-family:'Instrument Serif'; src:url('../fonts/instrument-serif.woff2') format('woff2'); font-weight:400; font-style:normal; font-display:swap; }
@font-face { font-family:'Instrument Serif'; src:url('../fonts/instrument-serif-italic.woff2') format('woff2'); font-weight:400; font-style:italic; font-display:swap; }
@font-face { font-family:'Inter'; src:url('../fonts/inter-variable.woff2') format('woff2'); font-weight:400; font-style:normal; font-display:swap; }
@font-face { font-family:'Inter'; src:url('../fonts/inter-variable.woff2') format('woff2'); font-weight:500; font-style:normal; font-display:swap; }

/* ---------- 2. Tokens ---------- */
:root {
  /* 2 couleurs + neutres */
  --forest:   #1F4D34;   /* couleur de marque, mature */
  --forest-d: #14331F;
  --lime:     #4CB65C;   /* accent du logo, usage homéopathique */

  --chaux:    #F5F2ED;
  --chaux-2:  #EAE5DC;
  --white:    #FFFFFF;
  --graphite: #17191A;
  --gr-70:    #4B4F4E;
  --gr-45:    #7C807E;
  --gr-25:    #ADB0AD;
  --line:     #DDD8CE;
  --line-2:   rgba(23,25,26,.12);

  --display: 'Instrument Serif', Georgia, serif;
  --sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, SFMono-Regular, Consolas, monospace;

  --t-mono: 0.6875rem;
  --t-xs:   0.75rem;
  --t-sm:   0.875rem;
  --t-md:   clamp(1.0625rem, .35vw + 1rem, 1.1875rem);
  --t-lg:   clamp(1.375rem, 1vw + 1.1rem, 1.75rem);
  --t-xl:   clamp(1.9rem, 3vw + 1.1rem, 3.25rem);
  --t-2xl:  clamp(2.4rem, 5vw + 1rem, 4.75rem);
  --t-3xl:  clamp(2.7rem, 7.5vw + .5rem, 7rem);

  --gutter: clamp(1.25rem, 4.5vw, 4.5rem);
  --max: 1600px;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

/* ---------- 3. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--sans); font-size: 1rem; line-height: 1.62;
  color: var(--graphite); background: var(--chaux);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
ul, ol { list-style: none; padding: 0; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: .98; letter-spacing: -.022em; text-wrap: balance; }
::selection { background: var(--forest); color: var(--chaux); }
:focus-visible { outline: 2px solid var(--forest); outline-offset: 3px; }
.on-dark :focus-visible { outline-color: var(--chaux); }

/* ---------- 4. Ossature ---------- */
.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.wrap-narrow { max-width: 880px; }
.section { padding-block: clamp(4.5rem, 10vw, 9.5rem); position: relative; }
.section-white { background: var(--white); }
.on-dark { background: var(--forest); color: var(--chaux); }
.on-dark h2, .on-dark h3 { color: var(--white); }

.skip-link {
  position: fixed; left: 1rem; top: 1rem; z-index: 400; transform: translateY(-250%);
  background: var(--graphite); color: var(--white); padding: .9rem 1.25rem; font-size: var(--t-sm);
}
.skip-link:focus { transform: none; }

.tag { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--gr-45); }
.on-dark .tag { color: #8FB39C; }
.tag-line { display: flex; align-items: center; gap: .9rem; }
.tag-line::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.on-dark .tag-line::after { background: rgba(245,242,237,.2); }

.title { font-size: var(--t-xl); }
.title-lg { font-size: var(--t-2xl); }
.it { font-style: italic; }
.lede { font-size: var(--t-md); line-height: 1.6; color: var(--gr-70); max-width: 54ch; text-wrap: pretty; }
.on-dark .lede { color: #B7CCBE; }

/* En-têtes de section : grille asymétrique 7/5, jamais centré */
.head { display: grid; gap: 1.5rem; margin-bottom: clamp(2.75rem, 5.5vw, 4.5rem); }
@media (min-width: 60rem) {
  .head { grid-template-columns: 7fr 5fr; gap: 3.5rem; align-items: end; }
  .head .tag-line { grid-column: 1 / -1; margin-bottom: .5rem; }
  .head .title { max-width: 18ch; }
}

/* ---------- 5. Boutons, liens, curseur ---------- */
.btn {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: .8rem;
  padding: 1.05rem 2rem; cursor: pointer;
  background: var(--graphite); color: var(--white); border: 1px solid var(--graphite);
  font-size: var(--t-sm); font-weight: 500; letter-spacing: .01em;
  transition: color .5s var(--ease), border-color .5s var(--ease);
}
.btn::before {
  content: ""; position: absolute; inset: 0; background: var(--forest);
  transform: translateY(101%); transition: transform .55s var(--ease); z-index: 0;
}
.btn:hover::before { transform: translateY(0); }
.btn:hover { border-color: var(--forest); }
.btn > * { position: relative; z-index: 1; }
.btn-ghost { background: transparent; color: var(--graphite); border-color: var(--line); }
.btn-ghost:hover { color: var(--white); border-color: var(--forest); }
.on-dark .btn { background: var(--chaux); color: var(--graphite); border-color: var(--chaux); }
.on-dark .btn::before { background: var(--lime); }

.link { position: relative; display: inline-flex; align-items: baseline; gap: .55rem; font-size: var(--t-sm); font-weight: 500; padding-block: .25rem; }
.link::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform-origin: right; transition: transform .55s var(--ease); }
.link:hover::after { transform: scaleX(0); }
.arrow { transition: transform .55s var(--ease); }
.link:hover .arrow { transform: translateX(5px); }

/* Curseur : anneau qui suit et s'élargit sur les éléments actifs (desktop fin uniquement) */
.cursor {
  position: fixed; top: 0; left: 0; z-index: 350; pointer-events: none;
  width: 26px; height: 26px; margin: -13px 0 0 -13px; border-radius: 50%;
  border: 1px solid var(--forest); opacity: 0;
  transition: opacity .3s ease, width .35s var(--ease), height .35s var(--ease),
              margin .35s var(--ease), background-color .35s var(--ease);
  will-change: transform;
}
.cursor.is-on { opacity: .8; }
.cursor.is-hot { width: 54px; height: 54px; margin: -27px 0 0 -27px; background: rgba(31,77,52,.08); }
@media (hover: none), (pointer: coarse), (prefers-reduced-motion: reduce) { .cursor { display: none; } }

/* ---------- 6. En-tête ---------- */
/* Sticky et non fixed : la photo du hero démarre sous l'en-tête, ce qui garantit
   la lisibilité du logo quelle que soit la photo mise en avant. */
.header { position: sticky; top: 0; z-index: 100; background: var(--chaux); border-bottom: 1px solid transparent; transition: border-color .5s var(--ease); }
.header.is-stuck { background: rgba(245,242,237,.92); backdrop-filter: blur(14px); border-bottom-color: var(--line); }
.header-in { display: flex; align-items: center; gap: 1.5rem; min-height: clamp(64px, 6vw, 84px); }
.brand {
  margin-right: auto;
  display: flex; align-items: center; gap: .55rem;
  color: var(--graphite);
}
.brand-mark { width: clamp(30px, 3.4vw, 38px); height: auto; flex: none; }
.brand-mot {
  display: grid; line-height: 1;
  font-weight: 700; letter-spacing: .015em;
  font-size: clamp(.95rem, 1.5vw, 1.15rem);
}
.brand-nom { white-space: nowrap; }
.brand-mot b { color: var(--forest); font-weight: 700; }
.brand-mot small {
  font-weight: 400; letter-spacing: .04em;
  font-size: .5em; color: var(--gr-45); margin-top: .32em;
}
@media (max-width: 30rem) { .brand-mot small { display: none; } }
.nav-list { display: none; }
.nav-list a { font-size: var(--t-sm); color: var(--gr-70); transition: color .4s var(--ease); }
.nav-list a:hover { color: var(--graphite); }
.burger { display: inline-flex; align-items: center; gap: .65rem; background: none; border: 0; padding: .5rem 0; cursor: pointer; font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; }
.burger i { display: block; width: 20px; height: 1px; background: var(--graphite); position: relative; }
.burger i::before, .burger i::after { content: ""; position: absolute; left: 0; width: 20px; height: 1px; background: var(--graphite); transition: transform .4s var(--ease); }
.burger i::before { top: -5px; } .burger i::after { top: 5px; }
.burger[aria-expanded="true"] i { background: transparent; }
.burger[aria-expanded="true"] i::before { transform: translateY(5px) rotate(45deg); }
.burger[aria-expanded="true"] i::after { transform: translateY(-5px) rotate(-45deg); }

.nav { position: fixed; inset: 0; z-index: 99; background: var(--chaux); padding: clamp(6rem,15vh,9rem) var(--gutter) var(--gutter); display: grid; align-content: space-between; opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility .45s; }
.nav.is-open { opacity: 1; visibility: visible; }
.nav-panel a { display: flex; align-items: baseline; gap: 1rem; font-family: var(--display); font-size: clamp(1.85rem, 8.5vw, 3rem); line-height: 1.1; border-bottom: 1px solid var(--line); padding-block: .4em; }
.nav-panel a::before { content: attr(data-n); font-family: var(--mono); font-size: var(--t-mono); color: var(--gr-25); }
.nav-foot { display: grid; gap: .4rem; padding-top: 2rem; font-size: var(--t-sm); }

@media (min-width: 64rem) {
  .burger, .nav { display: none; }
  .nav-list { display: flex; gap: clamp(1.4rem, 2.3vw, 2.4rem); }
}

/* ---------- 7. Hero : photo de realisation plein cadre ---------- */
.hero {
  position: relative; isolation: isolate;
  min-height: clamp(520px, calc(100svh - 84px), 900px);
  display: grid; align-items: end;
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: -1; overflow: hidden; }
.hero-media img {
  display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: 56% 46%;
  filter: var(--grade);
}

/* Voile bas : le nom reste lisible quelle que soit la photo */
.hero-media::after {
  content: ""; position: absolute; inset: 0; z-index: 2;
  background:
    radial-gradient(125% 95% at 50% 44%, transparent 42%, rgba(38,24,12,.32) 100%),
    linear-gradient(to top, rgba(15,17,16,.82) 0%, rgba(15,17,16,.45) 32%, rgba(15,17,16,.06) 62%, transparent 100%);
}

.hero-in { position: relative; z-index: 2; padding-block: clamp(2.5rem, 6vw, 4.5rem); color: #FFF; }
.hero-in .tag { color: rgba(255,255,255,.72); }
.hero-name {
  font-size: clamp(2.9rem, 9vw, 7.5rem);
  line-height: .92; letter-spacing: -.035em; color: #FFF;
  margin-block: clamp(.75rem, 2vw, 1.25rem);
}
.hero-base { font-size: var(--t-md); color: rgba(255,255,255,.86); max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; margin-top: clamp(1.75rem, 3.5vw, 2.5rem); }
.hero .btn { background: #FFF; color: var(--graphite); border-color: #FFF; }
.hero .btn-appel { background: transparent; color: #FFF; border-color: rgba(255,255,255,.75); }
.hero .btn-appel::before { background: #FFF; }
.hero .btn-appel:hover { color: var(--graphite); border-color: #FFF; }
.hero .btn::before { background: var(--forest); }
.hero .btn:hover { color: #FFF; border-color: var(--forest); }
.hero .link { color: #FFF; }
@media (min-width: 64rem) {
  .hero-in { display: grid; grid-template-columns: 7fr 5fr; align-items: end; gap: 3rem; }
  .hero-actions { margin-top: 0; justify-content: flex-end; padding-bottom: .5rem; }
}


/* ---------- 7 ter. Étalonnage des photos ----------
   Un seul endroit pour régler le rendu de toutes les images du site.
   Principe repris de l'étalonnage cinéma : on réchauffe les tons moyens
   sans virer les blancs, on ouvre légèrement les ombres, on garde les
   hautes lumières propres. Rien n'est cuit dans les fichiers : les
   originaux restent intacts, tout est réversible ici. */
:root {
  --grade: saturate(1.16) contrast(1.055) brightness(1.025);
  --grade-soft: saturate(1.1) contrast(1.04) brightness(1.015);
}

/* Voile chaud en soft-light : réchauffe les bois et les enduits,
   laisse les blancs des murs neutres. */
/* Pas de « position » ici : .warm se pose sur un conteneur déjà positionné,
   sinon la règle écraserait le positionnement de l.hôte. */
.warm::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  mix-blend-mode: soft-light; opacity: .34;
  background: linear-gradient(178deg, #FFE0B8 0%, #FFB06A 55%, #8A5C33 100%);
}

/* ---------- 7 bis. Coupe de cloison en volume ----------
   Les couches sont empilées à plat, puis s'écartent en profondeur à
   l'arrivée à l'écran. Rotation pilotée à la souris sur desktop. */
.cutaway { display: grid; gap: clamp(2.5rem, 5vw, 3.5rem); align-items: center; }
@media (min-width: 64rem) {
  .cutaway { grid-template-columns: 4fr 8fr; gap: clamp(2rem, 4vw, 3.5rem); }
}

/* La coupe est une planche technique dessinee : axonometrie a plat, couches
   decalees en escalier pour que chaque epaisseur se lise, libelles renvoyes de
   part et d'autre. Elle se construit couche par couche a l'arrivee a l'ecran,
   du mur support jusqu'a l'enduit — l'ordre reel de pose. */
.cutaway-scene { display: grid; gap: 1rem; }

.mur-plan { display: block; width: 100%; height: auto; overflow: visible; }

/* Chaque couche arrive depuis l'arriere, dans l'axe de fuite du dessin. */
.mur-plan .couche {
  opacity: 0; transform: translate(38px, -21px);
  transition: opacity .55s ease var(--d), transform .8s cubic-bezier(.2, .8, .2, 1) var(--d);
}
.mur-plan.on .couche { opacity: 1; transform: none; }

.mur-plan .repere { opacity: 0; transition: opacity .5s ease var(--d); }
.mur-plan.on .repere { opacity: 1; }

.mur-plan .rappel { fill: none; stroke: var(--gr-25); stroke-width: 1.2; }
.mur-plan .pastille { fill: var(--white); stroke: var(--graphite); stroke-width: 1.4; }
.mur-plan .num {
  font-family: var(--mono); font-size: 15px; font-weight: 500;
  fill: var(--graphite); text-anchor: middle;
}
.mur-plan .lib { font-family: var(--sans); font-size: 27px; font-weight: 500; fill: var(--graphite); }
.mur-plan .cote {
  font-family: var(--mono); font-size: 19px; letter-spacing: .06em; fill: var(--gr-45);
}

/* Ecran reduit : les libelles deportes ne tiennent plus, le dessin prend toute
   la largeur et la nomenclature sous le dessin prend le relais. */
@media (max-width: 52rem) {
  .mur-plan .reperes { display: none; }
  .mur-plan { margin-inline: -1rem; }
}

@media (prefers-reduced-motion: reduce) {
  .mur-plan .couche, .mur-plan .repere { opacity: 1; transform: none; transition: none; }
}

/* Le volume se pose sur la planche : celle-ci donne la hauteur du bloc et
   reprend la main si la 3D ne demarre pas (pas de JavaScript, pas de WebGL,
   ecran etroit). */
.coupe-vue { position: relative; }
#coupe3d { position: absolute; inset: 0; cursor: grab; touch-action: none; }
#coupe3d canvas { display: block; width: 100%; height: 100%; }
#coupe3d.tire { cursor: grabbing; }
.coupe3d-ok .mur-plan .dessin { visibility: hidden; }

/* Ligne eclairee : la couche correspondante est designee dans le volume, ou
   l'inverse. Le vert de la marque sert de fil entre les deux. */
.coupe3d-lie .legend li { cursor: pointer; transition: background-color .18s ease; }
.coupe3d-lie .legend li:focus-visible { outline: 2px solid var(--lime); outline-offset: 2px; }
.legend li.actif { background: rgba(76, 182, 92, .10); }
.legend li.actif .n { color: var(--forest); }
.legend li.actif .l { color: var(--forest); font-weight: 600; }
.legend li.actif .v { color: var(--gr-70); }

.legend { display: grid; gap: 0; border-top: 1px solid var(--line); }
.legend li {
  display: grid; grid-template-columns: 2.5rem 1fr auto; gap: 1rem;
  align-items: baseline; padding-block: .75rem; border-bottom: 1px solid var(--line);
}
.legend .n { font-family: var(--mono); font-size: var(--t-mono); color: var(--gr-25); }
.legend .l { font-size: var(--t-sm); font-weight: 500; }
.legend .v { font-family: var(--mono); font-size: var(--t-mono); color: var(--gr-45); text-align: right; }

/* ---------- 8. Chiffres clés ---------- */
.stats { display: grid; gap: 0; border-top: 1px solid var(--line-2); }
.stat { padding-block: clamp(1.5rem, 3vw, 2.25rem); border-bottom: 1px solid var(--line-2); }
.stat b { display: block; font-family: var(--display); font-weight: 400; font-size: clamp(2.75rem, 6vw, 4.5rem); line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.stat span { display: block; margin-top: .5rem; font-size: var(--t-sm); color: var(--gr-45); max-width: 22ch; }
@media (min-width: 52rem) {
  .stats { grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line-2); }
  .stat { border-bottom: 0; border-left: 1px solid var(--line-2); padding: clamp(1.75rem,3vw,2.5rem) clamp(1rem,2vw,2rem); }
  .stat:first-child { border-left: 0; padding-left: 0; }
}

/* ---------- 9. Bande matière (parallax) ---------- */
.band { overflow: hidden; height: clamp(220px, 42vw, 460px); position: relative; }
.band img { position: absolute; inset: -12% 0; width: 100%; height: 124%; object-fit: cover; will-change: transform; }
.band figcaption { position: absolute; left: var(--gutter); bottom: 1.25rem; font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--white); text-shadow: 0 1px 12px rgba(0,0,0,.6); }

/* ---------- 10. Savoir-faire ---------- */
.craft { display: grid; gap: 0; border-top: 1px solid var(--line); }
.craft > li { border-bottom: 1px solid var(--line); }
.craft-row { display: grid; gap: .6rem 2rem; padding-block: clamp(1.6rem, 3vw, 2.4rem); transition: padding-inline .6s var(--ease), background-color .6s var(--ease); }
.craft > li:hover .craft-row { background: var(--white); padding-inline: clamp(.75rem, 1.8vw, 1.5rem); }
.craft-n { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; color: var(--gr-25); }
.craft-t { font-family: var(--display); font-size: var(--t-lg); line-height: 1.1; }
.craft-d { font-size: var(--t-sm); color: var(--gr-70); max-width: 64ch; }
.craft-k { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .9rem; }
.craft-k li { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .06em; color: var(--gr-45); border: 1px solid var(--line); padding: .25rem .6rem; }
@media (min-width: 60rem) {
  .craft-row { grid-template-columns: 4.5rem minmax(0, 17rem) minmax(0, 1fr); align-items: start; }
  .craft-n { padding-top: .5rem; }
}

/* ---------- 11. Portfolio ---------- */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.filters button {
  background: none; cursor: pointer; padding: .55rem 1.1rem;
  border: 1px solid var(--line); color: var(--gr-70);
  font-size: var(--t-sm); transition: background-color .4s var(--ease), color .4s var(--ease), border-color .4s var(--ease);
}
.filters button:hover { border-color: var(--gr-45); }
.filters button[aria-pressed="true"] { background: var(--graphite); border-color: var(--graphite); color: var(--white); }

.grid { display: grid; gap: clamp(1.75rem, 3.5vw, 3rem); }
.project { transition: opacity .5s var(--ease), transform .5s var(--ease); }
.project.is-hidden { display: none; }
.project.is-fading { opacity: 0; transform: translateY(12px) scale(.985); }

.tilt { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; text-align: left; perspective: 1000px; }
.tilt-in {
  transform-style: preserve-3d;
  transform: rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg));
  transition: transform .6s var(--ease);
}
.tilt-frame { position: relative; overflow: hidden; background: var(--chaux-2); }
.tilt-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.tilt:hover .tilt-frame img { transform: scale(1.05); }
.tilt-frame::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(23,25,26,.35), transparent 55%); opacity: 0; transition: opacity .5s var(--ease); }
.tilt:hover .tilt-frame::after { opacity: 1; }
.tilt-badge {
  position: absolute; left: 1rem; bottom: 1rem; transform: translateZ(45px);
  background: rgba(245,242,237,.94); color: var(--graphite);
  font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .16em; text-transform: uppercase;
  padding: .4rem .75rem; opacity: 0; transition: opacity .5s var(--ease);
}
.tilt:hover .tilt-badge { opacity: 1; }
.p-l .tilt-frame img { aspect-ratio: 4 / 3; }
.p-p .tilt-frame img { aspect-ratio: 3 / 4; }
.project figcaption { display: flex; justify-content: space-between; align-items: baseline; gap: 1.25rem; padding-top: .9rem; margin-top: .9rem; border-top: 1px solid var(--line); }
.project figcaption h3 { font-size: var(--t-md); }
.project figcaption span { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--gr-45); }
.img-missing { visibility: hidden; }
@media (min-width: 52rem) {
  .grid { grid-template-columns: repeat(6, 1fr); }
  .project { grid-column: span 3; }
  .project:nth-child(4n+1) { grid-column: span 4; }
  .project:nth-child(4n+2) { grid-column: span 2; align-self: end; }
}

/* ---------- 12. Process ---------- */
.process { display: grid; gap: clamp(2.5rem, 5vw, 4rem); }
.steps { display: grid; }
.step { display: grid; gap: .5rem; padding-block: clamp(1.6rem, 3vw, 2.4rem); border-top: 1px solid rgba(245,242,237,.18); position: relative; }
.step:last-child { border-bottom: 1px solid rgba(245,242,237,.18); }
.step-n { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; color: #8FB39C; }
.step h3 { font-size: var(--t-lg); }
.step p { font-size: var(--t-sm); color: #B7CCBE; max-width: 58ch; }
.step-bar { position: absolute; left: 0; bottom: -1px; height: 1px; background: var(--lime); width: 0; transition: width 1.2s var(--ease); }
.step.on .step-bar { width: 100%; }
@media (min-width: 64rem) {
  .process { grid-template-columns: minmax(0, 24rem) minmax(0, 1fr); gap: clamp(3rem, 8vw, 8rem); }
  .process-head { position: sticky; top: clamp(7rem, 14vh, 10rem); align-self: start; }
  .step { grid-template-columns: 5rem minmax(0, 1fr); gap: 2rem; align-items: start; }
  .step-n { grid-row: span 2; padding-top: .5rem; }
  .step p { grid-column: 2; }
}

/* ---------- 13. Témoignages ---------- */
.quotes { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); }
.quote { background: var(--white); border: 1px solid var(--line); padding: clamp(1.5rem, 3vw, 2.25rem); display: grid; gap: 1.25rem; align-content: start; }
.quote blockquote { font-family: var(--display); font-size: var(--t-lg); line-height: 1.25; }
.quote figcaption { font-size: var(--t-sm); color: var(--gr-45); }
.quote figcaption b { display: block; color: var(--graphite); font-weight: 500; }
.quote .work { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--gr-25); }
@media (min-width: 52rem) { .quotes { grid-template-columns: repeat(3, 1fr); } }

/* La carte d'engagement reprend le cadre des avis, sans guillemets ni
   signature : rien ne doit pouvoir se lire comme un propos de client. */
.engagement h3 {
  font-family: var(--display); font-size: var(--t-lg); line-height: 1.2;
  font-weight: 400; letter-spacing: -.01em;
}
.engagement p { color: var(--gr-70); }
.engagement .work { margin: 0; }

/* ---------- 14. Devis ---------- */
.form { display: grid; gap: 2rem; margin-top: clamp(2.5rem, 5vw, 3.5rem); }
.row-2 { display: grid; gap: 2rem; }
@media (min-width: 46rem) { .row-2 { grid-template-columns: 1fr 1fr; } }
.field { display: grid; gap: .5rem; }
.field label { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: #8FB39C; }
.field input, .field select, .field textarea {
  width: 100%; padding: .7rem 0; background: transparent; color: var(--chaux);
  border: 0; border-bottom: 1px solid rgba(245,242,237,.3);
  font-size: var(--t-md); transition: border-color .5s var(--ease);
}
.field textarea { resize: vertical; min-height: 6em; }
.field input::placeholder, .field textarea::placeholder { color: #6E8C79; }
.field input:hover, .field select:hover, .field textarea:hover { border-bottom-color: rgba(245,242,237,.6); }
.field input:focus, .field select:focus, .field textarea:focus { outline: 0; border-bottom-color: var(--lime); }
.field select { -webkit-appearance: none; appearance: none; border-radius: 0; cursor: pointer; }
.field select option { color: var(--graphite); background: var(--chaux); }
.field [aria-invalid="true"] { border-bottom-color: #E5A183; }
.err { font-family: var(--mono); font-size: var(--t-mono); color: #E5A183; }
.field-check { grid-template-columns: auto 1fr; align-items: start; gap: 1rem; }
.field-check input { width: 17px; height: 17px; margin-top: .35rem; padding: 0; accent-color: var(--lime); }
.field-check label { font-family: var(--sans); font-size: var(--t-sm); letter-spacing: normal; text-transform: none; color: #B7CCBE; line-height: 1.5; }
.field-check .err { grid-column: 1 / -1; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-foot { display: grid; gap: 1.1rem; justify-items: start; }
.form-status { font-family: var(--mono); font-size: var(--t-xs); min-height: 1.4em; }
.form-status.ok { color: var(--lime); }
.form-status.ko { color: #E5A183; }
.form-legal { font-size: var(--t-xs); color: #8FB39C; max-width: 62ch; }
.form-legal a { border-bottom: 1px solid currentColor; }

.contact-side { display: grid; align-content: start; }
.contact-side div { display: grid; gap: .2rem; padding-block: 1rem; border-top: 1px solid rgba(245,242,237,.18); }
.contact-side dt { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: #8FB39C; }
.contact-side dd { font-size: var(--t-md); }
.contact-grid { display: grid; gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 64rem) { .contact-grid { grid-template-columns: minmax(0,1fr) minmax(0,19rem); gap: clamp(3rem,7vw,6rem); } }

/* ---------- 15. Pied de page ---------- */
.footer { background: var(--graphite); color: var(--chaux); padding-top: clamp(3.5rem, 7vw, 6rem); }
.footer-word { font-family: var(--display); font-size: clamp(2.5rem, 12vw, 9.5rem); line-height: .85; letter-spacing: -.035em; padding-bottom: clamp(2rem, 5vw, 3.5rem); border-bottom: 1px solid rgba(245,242,237,.15); }
.footer-grid { display: grid; gap: 2.5rem; padding-block: clamp(2.5rem, 5vw, 4rem); }
.footer-grid h2 { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--gr-25); margin-bottom: 1rem; }
.footer-grid ul { display: grid; gap: .5rem; font-size: var(--t-sm); color: #B6B9B6; }
.footer-grid a:hover { color: var(--lime); }
.footer-bottom { display: grid; gap: .5rem; padding-bottom: clamp(2rem, 4vw, 3rem); font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .1em; color: var(--gr-25); }
@media (min-width: 52rem) { .footer-grid { grid-template-columns: repeat(3,1fr); } .footer-bottom { grid-template-columns: 1fr auto; align-items: center; } }

/* ---------- 16. Barre mobile ---------- */
.dock { position: fixed; z-index: 95; inset: auto 0 0 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); transform: translateY(100%); transition: transform .55s var(--ease); }
.dock.is-shown { transform: none; }
.dock a { display: flex; align-items: center; justify-content: center; padding: 1rem .75rem calc(1rem + env(safe-area-inset-bottom)); font-size: var(--t-sm); font-weight: 500; background: rgba(245,242,237,.94); backdrop-filter: blur(12px); }
.dock a + a { background: var(--graphite); color: var(--white); }
@media (min-width: 64rem) { .dock { display: none; } }

/* ---------- 17. Visionneuse ---------- */
.lightbox { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; padding: 0; border: 0; background: var(--graphite); color: var(--chaux); }
.lightbox::backdrop { background: rgba(23,25,26,.95); }
.lightbox[open] { display: grid; grid-template-rows: auto 1fr auto; }
.lb-bar, .lb-foot { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; padding: 1.1rem var(--gutter); }
.lb-bar { border-bottom: 1px solid rgba(245,242,237,.15); }
.lb-foot { border-top: 1px solid rgba(245,242,237,.15); }
.lb-bar p, .lb-bar button { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .18em; text-transform: uppercase; color: var(--gr-25); }
.lb-bar button { background: none; border: 0; cursor: pointer; }
.lb-bar button:hover { color: var(--chaux); }
.lb-foot figcaption { font-size: var(--t-sm); color: #B6B9B6; }
.lb-stage { display: grid; place-items: center; min-height: 0; padding: 1.25rem var(--gutter); }
.lb-stage img { max-height: 100%; max-width: 100%; width: auto; object-fit: contain; }
.lb-nav { display: flex; gap: .5rem; flex: none; }
.lb-nav button { width: 46px; height: 46px; background: none; color: inherit; border: 1px solid rgba(245,242,237,.3); cursor: pointer; transition: background-color .4s var(--ease), color .4s var(--ease); }
.lb-nav button:hover { background: var(--chaux); color: var(--graphite); }

/* ---------- 18. Révélations au scroll ---------- */
.js .rv { opacity: 0; transform: translateY(22px); }
.js .rv.on { opacity: 1; transform: none; transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js .rv-img { clip-path: inset(0 0 100% 0); }
.js .rv-img.on { clip-path: inset(0 0 0 0); transition: clip-path 1.2s var(--ease); }
.js .rv-d1.on { transition-delay: .1s; }
.js .rv-d2.on { transition-delay: .2s; }
.js .rv-d3.on { transition-delay: .3s; }
@media (prefers-reduced-motion: reduce) {
  .js .rv, .js .rv.on, .js .rv-img, .js .rv-img.on { opacity: 1; transform: none; clip-path: none; transition: none; }
  .tilt-in, .tilt-frame img, .btn::before, .band img, .cutaway-stage { transition: none !important; }
}

/* ---------- 19. Mentions légales ---------- */
.prose { padding-block: clamp(3rem, 7vw, 6rem) clamp(4rem, 9vw, 8rem); }
.prose h1 { font-size: var(--t-2xl); margin-bottom: 2.5rem; }
.prose h2 { font-size: var(--t-lg); margin-top: 3.5rem; margin-bottom: 1rem; }
.prose h3 { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--gr-45); margin-top: 2rem; margin-bottom: .6rem; }
.prose p, .prose li { color: var(--gr-70); font-size: var(--t-sm); }
.prose p + p { margin-top: 1rem; }
.prose ul { display: grid; gap: .6rem; margin-top: 1rem; }
.prose ul li { padding-left: 1.2rem; position: relative; }
.prose ul li::before { content: "—"; position: absolute; left: 0; color: var(--gr-25); }
.prose strong { font-weight: 500; color: var(--graphite); }
.prose a { border-bottom: 1px solid var(--line); }
.prose .maj { background: #E7E0C8; padding: .05em .4em; color: var(--graphite); }
.prose .note { border-left: 2px solid var(--line); padding: .25rem 0 .25rem 1.25rem; margin-top: 2rem; }

/* Étalonnage appliqué au reste des photos */
.band img, .tilt-frame img { filter: var(--grade-soft); }
.tilt:hover .tilt-frame img { filter: var(--grade); }
