/* ==========================================================================
   DRAY & FILS — Feuille de style
   Direction : éditoriale et architecturale. Le fil conducteur est un réseau de
   plomberie qui traverse la page (conduite, raccords, fuites réparées, vannes).
   3 coloris : onyx (noir & laiton) · ivoire (ivoire & bronze) · abysse (nuit & chrome)
   ========================================================================== */

/* ---------- Coloris ---------- */
:root,
[data-theme="onyx"] {
  --bg: #0e0d0b;
  --bg-2: #15130f;
  --surface: #1b1915;
  --text: #efe9de;
  --text-2: #b3ab9d;
  --text-3: #857d70;
  --accent: #c9a86a;
  --line: rgba(239, 233, 222, 0.1);
  --line-2: rgba(239, 233, 222, 0.22);
  --water: #e6c98a;
  --water-2: #b48a45;
  --water-ink: #e6c98a; /* l'or de la conduite quand il sert à écrire (textes, liens) */
  --leak: #e0a24a;
  --m1: #c9a35c;
  --m2: #edd59a;
  --m3: #7d5c28;
  --m4: #f8ecc6;
  --sea: rgba(201, 168, 106, 0.06);
  color-scheme: dark;
}
[data-theme="ivoire"] {
  --bg: #f3efe7;
  --bg-2: #ebe5d9;
  --surface: #e3dccd;
  --text: #1d1a15;
  --text-2: #5b5447;
  --text-3: #6d6659;
  --accent: #7f5f2c; /* bronze à peine plus soutenu : petits libellés dorés lisibles sur ivoire (≥ 4,5:1) */
  --line: rgba(29, 26, 21, 0.12);
  --line-2: rgba(29, 26, 21, 0.26);
  --water: #b8893f;
  --water-2: #8d6a34;
  --water-ink: #7a5a2a; /* l'or clair de la conduite n'atteint que 2,7:1 sur ivoire : version foncée pour les textes et liens */
  --leak: #b9741e;
  --m1: #9c7236;
  --m2: #c99c5c;
  --m3: #5e421b;
  --m4: #e2c08a;
  --sea: rgba(141, 106, 52, 0.07);
  color-scheme: light;
}
[data-theme="abysse"] {
  --bg: #0a111b;
  --bg-2: #0f1824;
  --surface: #152131;
  --text: #e9eef4;
  --text-2: #a2aebd;
  --text-3: #7d899a;
  --accent: #c3cdd9;
  --line: rgba(233, 238, 244, 0.1);
  --line-2: rgba(233, 238, 244, 0.22);
  --water: #e3c78c;
  --water-2: #b39150;
  --water-ink: #e3c78c;
  --leak: #e0a24a;
  --m1: #b9c3d1;
  --m2: #eef2f8;
  --m3: #6c7a8e;
  --m4: #ffffff;
  --sea: rgba(140, 200, 255, 0.06);
  color-scheme: dark;
}
:root {
  --metal: linear-gradient(90deg, var(--m3) 0%, var(--m2) 32%, var(--m1) 55%, var(--m4) 72%, var(--m3) 100%);
  --metal-v: linear-gradient(180deg, var(--m3) 0%, var(--m2) 32%, var(--m1) 55%, var(--m4) 72%, var(--m3) 100%);
  --f-display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --f-sans: "Instrument Sans", "Helvetica Neue", system-ui, sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --gutter: clamp(20px, 4vw, 56px);
  --rail: 14px;
  --header-h: 76px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; overflow-x: clip; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.6s var(--ease), color 0.6s var(--ease);
}
.js body.is-loading { overflow: hidden; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
strong { font-weight: 600; color: var(--text); }
em { font-style: italic; }
::selection { background: var(--accent); color: var(--bg); }
:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip-link { position: fixed; left: 16px; top: -60px; z-index: 3000; padding: 10px 16px; background: var(--surface); color: var(--text); font-size: 14px; transition: top 0.3s; }
.skip-link:focus { top: 16px; }
.container { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Typographie ---------- */
.label {
  display: flex; align-items: center; gap: 14px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3);
}
.label b { font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums; }
.title {
  font-family: var(--f-display); font-weight: 400; font-size: clamp(34px, 4vw, 58px); line-height: 1.08;
  letter-spacing: -0.012em; color: var(--text);
}
.title em { color: var(--accent); }
.title, .galerie__title { text-wrap: balance; }
.faq__list summary { text-wrap: pretty; }
.lead { font-size: 19px; color: var(--text-2); max-width: 560px; }
.muted { color: var(--text-2); }
.fineprint { margin-top: 22px; font-size: 12px; color: var(--text-3); }

/* ---------- Boutons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 54px; padding: 0 28px; border-radius: 2px; overflow: hidden; isolation: isolate;
  font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap;
  transition: background-color 0.35s var(--ease), color 0.35s var(--ease), border-color 0.35s;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn--primary { background: var(--text); color: var(--bg); }
.btn--primary:hover { background: var(--accent); }
.btn--line { box-shadow: inset 0 0 0 1px var(--line-2); color: var(--text); }
.btn--line:hover { box-shadow: inset 0 0 0 1px var(--accent); color: var(--accent); }
.btn--sm { height: 42px; padding: 0 18px; font-size: 12px; }
.btn--block { width: 100%; }
.btn--wa { background: #1f9d55; color: #fff; }
.btn--wa:hover { background: #188a49; }
/* Bouton « robinet » : l'eau monte au survol */
.btn--water { background: var(--text); color: var(--bg); }
.btn--water::before {
  content: ""; position: absolute; left: -10%; right: -10%; bottom: -100%; height: 100%; z-index: -1;
  background:
    radial-gradient(28px 10px at 25% 0, var(--water) 98%, transparent) repeat-x,
    linear-gradient(var(--water), var(--water-2));
  background-size: 56px 12px, 100% 100%; background-position: 0 -6px, 0 0;
  transition: bottom 0.9s var(--ease);
  animation: wave 1.6s linear infinite;
}
.btn--water:hover::before, .btn--water.is-sending::before { bottom: 0; }
.btn--water:hover, .btn--water.is-sending { color: #06121d; }
@keyframes wave { to { background-position: 56px -6px, 0 0; } }
.text-link { display: inline-flex; align-items: center; gap: 10px; font-weight: 500; color: var(--text); border-bottom: 1px solid var(--line-2); padding-bottom: 3px; transition: color 0.3s, border-color 0.3s; }
.text-link:hover { color: var(--accent); border-color: var(--accent); }
.text-link svg { width: 18px; height: 18px; }
/* Lien « Parler de mon projet → » des onglets Savoir-faire (sans règle, la flèche s'affichait en 300 × 150 px) */
.link-arrow { display: inline-flex; align-items: center; gap: 12px; font-weight: 500; color: var(--text); border-bottom: 1px solid var(--line-2); padding-bottom: 4px; transition: color 0.3s, border-color 0.3s; }
.link-arrow svg { width: 18px; height: 18px; flex: none; transition: transform 0.4s var(--ease); }
.link-arrow:hover { color: var(--accent); border-color: var(--accent); }
.link-arrow:hover svg { transform: translateX(6px); }
.wa-link svg { color: #25d366; }

/* ---------- Vannes (les médaillons ronds) ---------- */
.orb {
  --size: 64px;
  position: relative; display: grid; place-items: center; width: var(--size); height: var(--size); flex: none;
  border-radius: 50%; background: var(--bg); color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--line-2);
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), box-shadow 0.4s;
}
.orb svg { width: 44%; height: 44%; }
.orb__lever {
  position: absolute; top: -9px; left: 50%; width: 30px; height: 6px; margin-left: -15px; border-radius: 3px;
  background: var(--metal); transform-origin: 50% 50%; transition: transform 0.6s var(--ease);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.3);
}
.orb__lever::after { content: ""; position: absolute; left: 50%; top: 100%; width: 4px; height: 5px; margin-left: -2px; background: var(--m3); }
.orb--sm { --size: 48px; }
.orb--sm .orb__lever { width: 22px; margin-left: -11px; height: 5px; top: -8px; }
.orb--lg { --size: 76px; }
.valve { display: inline-flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.valve__name { font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text); }
.valve__sub { font-size: 14px; color: var(--text-3); margin-top: -8px; }
.valve:hover .orb, .valve:focus-visible .orb { box-shadow: inset 0 0 0 1px var(--accent); }
.valve:hover .orb__lever, .valve:focus-visible .orb__lever { transform: rotate(90deg); }
.valve[aria-selected="true"] .orb, .valve[aria-pressed="true"] .orb { background: var(--text); color: var(--bg); box-shadow: none; }
.valve[aria-selected="true"] .orb__lever, .valve[aria-pressed="true"] .orb__lever { transform: rotate(90deg); }
.valve:focus-visible { outline: none; }
.valve:focus-visible .orb { outline: 1px solid var(--accent); outline-offset: 8px; }

/* Collecteur : conduite horizontale qui alimente les vannes */
.manifold { position: relative; display: grid; grid-template-columns: repeat(var(--n, 4), 1fr); gap: 16px; padding-top: 12px; }
.manifold::before, .manifold::after {
  content: ""; position: absolute; left: calc(100% / var(--n, 4) / 2); right: calc(100% / var(--n, 4) / 2); top: calc(12px + var(--orb, 64px) / 2 - 5px);
  height: 10px; border-radius: 5px; z-index: 0;
}
.manifold::before { box-shadow: inset 0 0 0 1px var(--line-2); background: var(--sea); }
.manifold::after {
  inset-inline: calc(100% / var(--n, 4) / 2 + 3px); height: 4px; margin-top: 3px; border-radius: 2px; opacity: 0.85;
  background: repeating-linear-gradient(90deg, var(--water) 0 16px, var(--water-2) 16px 30px);
  background-size: 30px 100%; animation: flow-x 1.1s linear infinite;
}
.manifold .valve { position: relative; z-index: 1; }
@keyframes flow-x { to { background-position: 30px 0; } }
@keyframes flow-y { to { background-position: 0 30px; } }

/* ---------- Réseau principal : conduite, raccords, fuites ---------- */
main { position: relative; }
.pipeline { position: absolute; z-index: 4; width: var(--rail); pointer-events: none; left: 0; top: 0; height: 0; }
.pipe { position: absolute; inset: 0; border-radius: calc(var(--rail) / 2); box-shadow: inset 0 0 0 1px var(--line-2); background: var(--sea); }
.pipe__water {
  position: absolute; left: 4px; right: 4px; top: 0; height: var(--water-h, 0px); border-radius: 3px;
  background: repeating-linear-gradient(180deg, var(--water) 0 16px, var(--water-2) 16px 30px);
  animation: flow-y 0.9s linear infinite; transition: height 1.1s var(--ease);
}
.pipe__water::after { content: ""; position: absolute; left: -2px; right: -2px; bottom: -3px; height: 8px; border-radius: 50%; background: var(--water); filter: blur(1px); }
.pipeline.no-anim .pipe__water { transition: none; }
.joint { position: absolute; left: 0; width: var(--rail); height: 0; }
.joint__coupling {
  position: absolute; left: -6px; top: -11px; width: calc(var(--rail) + 12px); height: 22px; border-radius: 3px;
  background: var(--metal-v); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}
.joint__coupling::before, .joint__coupling::after { content: ""; position: absolute; left: 2px; right: 2px; height: 2px; background: rgba(0, 0, 0, 0.25); }
.joint__coupling::before { top: 5px; }
.joint__coupling::after { bottom: 5px; }
.joint__branch {
  position: absolute; left: var(--rail); top: -5px; height: 10px; width: var(--branch, 40px);
  border-radius: 0 5px 5px 0; box-shadow: inset 0 0 0 1px var(--line-2); background: var(--sea); overflow: hidden;
}
.joint__branch i { position: absolute; left: 0; top: 3px; height: 4px; width: 0; background: var(--water); transition: width 0.9s var(--ease) 0.2s; }
.joint.is-wet .joint__branch i, .joint.is-fixed .joint__branch i { width: 100%; }
.joint.is-wet .joint__coupling, .joint.is-fixed .joint__coupling { box-shadow: 0 0 0 1px var(--accent), 0 2px 8px rgba(0, 0, 0, 0.35); }
/* fuite : jet, gouttes et flaque restent dans la marge entre la conduite et le texte (au moins 19 px), sans le recouvrir */
.joint__leak { position: absolute; left: calc(var(--rail) + 2px); top: -2px; width: 60px; height: 160px; opacity: 0; transition: opacity 0.4s; }
.joint__leak i { position: absolute; left: 0; top: 0; width: 6px; height: 9px; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; background: var(--water); opacity: 0; }
.joint.is-leaking .joint__leak { opacity: 1; }
.joint.is-leaking .joint__leak i { animation: drip 0.9s cubic-bezier(0.5, 0, 1, 0.6) infinite; }
.joint__leak i:nth-child(2) { animation-delay: 0.3s !important; left: 4px; }
.joint__leak i:nth-child(3) { animation-delay: 0.6s !important; left: 8px; }
.joint__leak i:nth-child(4) { animation-delay: 0.15s !important; left: 2px; }
@keyframes drip {
  0% { transform: translate(0, 0) scale(0.6); opacity: 0; }
  15% { opacity: 1; }
  100% { transform: translate(var(--dx, 4px), 140px) scale(1); opacity: 0; }
}
.joint__spray { position: absolute; left: calc(var(--rail) + 4px); top: -6px; width: 12px; height: 12px; opacity: 0; background: radial-gradient(circle at 0 50%, var(--water) 0 2px, transparent 3px) 0 0 / 6px 4px; }
.joint.is-leaking .joint__spray { opacity: 0.8; animation: spray 0.25s steps(2) infinite; }
@keyframes spray { to { transform: translateX(3px) scaleY(1.3); } }
.joint__puddle { position: absolute; left: -8px; top: 150px; width: 0; height: 6px; border-radius: 50%; background: var(--water); opacity: 0.45; transition: width 1.6s var(--ease), opacity 1s; }
.joint.is-leaking .joint__puddle { width: 40px; }
.joint.is-fixed .joint__puddle { width: 0; opacity: 0; transition-delay: 0.4s; }
/* réparation : la clé serre le raccord */
.joint__wrench { position: absolute; left: -26px; top: -26px; width: 66px; height: 52px; opacity: 0; color: var(--text); transform-origin: 38px 26px; }
.joint.is-repairing .joint__wrench { opacity: 1; animation: tighten 0.45s ease-in-out 3 alternate; }
@keyframes tighten { from { transform: rotate(-26deg); } to { transform: rotate(12deg); } }
.joint__tag {
  position: absolute; left: calc(var(--rail) + var(--branch, 40px) + 14px); top: -32px; white-space: nowrap;
  font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0;
  transition: opacity 0.4s, transform 0.4s var(--ease); transform: translateY(4px);
}
.joint__tag::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 8px; vertical-align: 1px; background: currentColor; }
.joint.is-leaking .joint__tag, .joint.is-repairing .joint__tag { opacity: 1; transform: none; color: var(--leak); }
.joint.is-fixed .joint__tag { opacity: 1; transform: none; color: var(--water-ink); animation: tag-out 0.6s ease 3.5s forwards; }
@keyframes tag-out { to { opacity: 0; } }
.joint__glint { position: absolute; left: -14px; top: -16px; width: 36px; height: 32px; border-radius: 50%; opacity: 0; background: radial-gradient(closest-side, rgba(255, 255, 255, 0.8), transparent); }
.joint.is-fixed .joint__glint { animation: glint 0.9s ease-out 1; }
@keyframes glint { 0% { opacity: 0; transform: scale(0.4); } 30% { opacity: 1; } 100% { opacity: 0; transform: scale(1.6); } }
/* Une seule colonne (moins de 980 px) : 16 px seulement entre la conduite et le texte. La fuite reste dans cette marge,
   gouttes le long de la conduite et flaque à son pied ; clé et reflet réduits : aucun texte n'est recouvert. */
@media (max-width: 979px) {
  .joint__spray { left: calc(var(--rail) + 2px); width: 9px; }
  .joint__leak i { --dx: 0px !important; }
  .joint__leak i:nth-child(2) { left: 3px; }
  .joint__leak i:nth-child(3) { left: 6px; }
  .joint__leak i:nth-child(4) { left: 1.5px; }
  .joint__puddle { left: -6px; }
  .joint.is-leaking .joint__puddle { width: 30px; }
  .joint__wrench { left: -8px; top: -14px; width: 34px; height: 27px; transform-origin: 20px 14px; }
  .joint__glint { left: -11px; width: 28px; }
}
.pipe-end { position: absolute; left: -5px; width: calc(var(--rail) + 10px); height: 16px; border-radius: 3px 3px 8px 8px; background: var(--metal-v); bottom: -8px; }

/* ---------- Loader : la conduite se remplit ---------- */
.loader { display: none; }
.js .loader { display: block; position: fixed; inset: 0; z-index: 1000; background: var(--bg); transition: opacity 0.9s var(--ease), visibility 0.9s; }
/* Logo plat, visible dès le début du chargement, à la place exacte du logo 3D (mise en page « intro » de logo3d.js :
   285 unités du dessin sur min(66vw, 65,5 % de la hauteur), point 151 × 104 du dessin à 43 % de la hauteur).
   Il s'efface quand la 3D est confirmée à l'écran (has-3d) et reste si elle échoue (no-webgl). */
.loader__mark { display: block; position: absolute; left: 50%; top: 43vh; top: 43lvh; width: min(69.47vw, 69vh); width: min(69.47vw, 69lvh); aspect-ratio: 300 / 210; height: auto; transform: translate(-50.33%, -49.52%); transition: opacity 0.45s var(--ease); }
.loader.has-3d .loader__mark { opacity: 0; }
.no-webgl .loader .loader__mark { opacity: 1; }
.loader__brand { position: absolute; left: 0; right: 0; top: 71%; text-align: center; z-index: 1002; }
.loader__name { font-family: var(--f-display); font-size: clamp(26px, 3.6vw, 46px); letter-spacing: 0.2em; text-transform: uppercase; line-height: 1; }
.loader__name .l { display: inline-block; opacity: 0; transform: translateY(0.4em); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); transition-delay: calc(var(--li) * 40ms); }
.loader.show-name .loader__name .l { opacity: 1; transform: none; }
.loader__name .l--amp { font-style: italic; text-transform: none; color: var(--accent); }
.loader__place { margin-top: 16px; font-size: 12px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--text-3); opacity: 0; transition: opacity 0.8s 0.4s; }
.loader.show-name .loader__place { opacity: 1; }
.loader__label { display: none; }
.loader.is-done { opacity: 0; visibility: hidden; }

/* ---------- Canvas 3D ---------- */
.webgl { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; height: 100lvh; z-index: 1; pointer-events: none; display: block; }
.js .webgl.is-top { z-index: 1001; }
.no-webgl .webgl { display: none; }

/* ---------- En-tête ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50; height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 var(--gutter);
  border-bottom: 1px solid transparent; transition: background-color 0.4s, border-color 0.4s, transform 0.5s var(--ease), opacity 0.6s;
}
.js body.is-loading .site-header { opacity: 0; }
.site-header.is-scrolled { background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-color: var(--line); }
.site-header.is-hidden { transform: translateY(-100%); }
.brand { display: flex; align-items: center; gap: 14px; --ko: var(--bg); }
.brand__mark { width: 54px; height: 38px; flex: none; }
.brand__name { display: block; font-family: var(--f-display); font-size: 17px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; line-height: 1.1; }
.brand__name i { color: var(--accent); text-transform: none; letter-spacing: 0; }
.brand__sub { display: block; font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--text-3); margin-top: 3px; }
.nav ul { display: flex; gap: clamp(18px, 2vw, 32px); }
.nav a { font-size: 14px; color: var(--text-2); padding: 6px 0; border-bottom: 1px solid transparent; transition: color 0.3s, border-color 0.3s; white-space: nowrap; }
.nav a:hover, .nav a.is-active { color: var(--text); border-color: var(--accent); }
.header__tools { display: flex; align-items: center; gap: 16px; }
.header__phone { font-size: 14px; font-weight: 500; font-variant-numeric: tabular-nums; color: var(--text); white-space: nowrap; }
.header__wa { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--line-2); color: #25d366; transition: box-shadow 0.3s, background-color 0.3s; }
.header__wa:hover { box-shadow: inset 0 0 0 1px #25d366; background: rgba(37, 211, 102, 0.08); }
.header__wa svg { width: 18px; height: 18px; }
.lang-switch { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--line-2); font-size: 11px; font-weight: 600; letter-spacing: 0.08em; color: var(--text-2); transition: color 0.3s, box-shadow 0.3s; }
.lang-switch:hover { color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.themes { display: flex; gap: 6px; }
.swatch { position: relative; width: 20px; height: 20px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--line-2); transition: transform 0.3s var(--ease); }
.swatch::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; }
.swatch::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; box-shadow: 0 0 0 1px var(--accent); opacity: 0; transition: opacity 0.3s; }
.swatch[aria-pressed="true"]::after { opacity: 1; }
.swatch:hover { transform: scale(1.1); }
.swatch--onyx { background: #0e0d0b; } .swatch--onyx::before { background: #c9a86a; }
.swatch--ivoire { background: #f3efe7; } .swatch--ivoire::before { background: #8d6a34; }
.swatch--abysse { background: #0a111b; } .swatch--abysse::before { background: #c3cdd9; }
.themes--lg .swatch { width: 30px; height: 30px; }
.themes--lg .swatch::before { inset: 9px; }
.burger { display: none; width: 44px; height: 44px; position: relative; }
.burger i { position: absolute; left: 11px; right: 11px; height: 1px; background: var(--text); transition: transform 0.4s var(--ease), top 0.4s var(--ease); }
.burger i:nth-of-type(1) { top: 18px; }
.burger i:nth-of-type(2) { top: 25px; }
.burger[aria-expanded="true"] i:nth-of-type(1), .burger[aria-expanded="true"] i:nth-of-type(2) { top: 21.5px; }
.burger[aria-expanded="true"] i:nth-of-type(1) { transform: rotate(45deg); }
.burger[aria-expanded="true"] i:nth-of-type(2) { transform: rotate(-45deg); }
.menu {
  position: fixed; inset: 0; z-index: 45; background: var(--bg); display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--header-h) + 24px) var(--gutter) max(28px, env(safe-area-inset-bottom));
  overflow-y: auto; overscroll-behavior: contain; /* sur écran bas, le pied du menu (WhatsApp, EN, coloris) reste accessible */
  opacity: 0; transition: opacity 0.4s var(--ease);
}
.menu.is-open { opacity: 1; }
/* menu fermé : il ne doit plus couvrir la page (sinon il capte les clics et le glisser des photos avant / après) */
.menu[hidden] { display: none; }
.menu ol { display: grid; }
.menu ol a { display: flex; align-items: baseline; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-family: var(--f-display); font-size: clamp(26px, 7vw, 36px); }
.menu ol a small { font-family: var(--f-sans); font-size: 12px; color: var(--accent); }
.menu__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: calc(var(--header-h) + 48px) 0 56px; }
.hero__fallback { display: none; position: absolute; z-index: 1; right: 7%; top: 44%; width: 38%; transform: translateY(-50%); --ko: var(--bg); }
.no-webgl .hero__fallback { display: grid; }
.hero__fallback svg { width: 100%; height: auto; aspect-ratio: 300 / 210; }
.hero__inner { position: relative; z-index: 2; }
.hero__content { max-width: min(620px, calc(50vw - var(--gutter))); }
.hero__title { margin: 22px 0 24px; font-family: var(--f-display); font-weight: 400; font-size: clamp(42px, 5.3vw, 84px); line-height: 1.02; letter-spacing: -0.02em; }
.hero__pre { display: block; font-family: var(--f-sans); font-size: 15px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2); margin-bottom: 18px; }
.hero__title em { color: var(--accent); }
.hero__lead { color: var(--text-2); max-width: 520px; font-size: 18px; }
.hero__ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 28px; margin-top: 34px; }
.hero__index { position: relative; z-index: 2; margin-top: clamp(48px, 7vh, 88px); }
.hero__index .manifold { --n: 5; max-width: 900px; }
[data-hero] { transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: calc(0.2s + var(--i, 0) * 0.1s); }
.js body.is-loading [data-hero] { opacity: 0; transform: translateY(20px); transition: none; }

/* ---------- Sections ---------- */
.section { position: relative; z-index: 2; padding: clamp(96px, 11vw, 160px) 0; background: var(--bg); border-top: 1px solid var(--line); transition: background-color 0.6s var(--ease); }
.section--alt { background: var(--bg-2); }
.sec-head { display: grid; grid-template-columns: 1fr 2fr; gap: 32px; align-items: start; margin-bottom: clamp(48px, 6vw, 80px); }
.sec-head .label { padding-top: 14px; }
.sec-head--stack { grid-template-columns: 1fr; gap: 18px; }

/* La maison */
.maison__grid { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.maison__text { order: -1; }
.maison__media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.maison__media figcaption { margin-top: 12px; font-size: 13px; color: var(--text-3); }
.maison__text .title { margin-bottom: 28px; }
.maison__text p + p { margin-top: 16px; }
.maison__text > p { color: var(--text-2); max-width: 600px; }
.facts { margin-top: 44px; border-top: 1px solid var(--line); }
.facts li { display: grid; grid-template-columns: 56px 1fr; gap: 20px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.facts .orb { --size: 46px; }
.facts h3 { font-family: var(--f-display); font-weight: 400; font-size: 22px; line-height: 1.2; }
.facts p { color: var(--text-2); font-size: 15px; margin-top: 4px; }

/* Savoir-faire */
.services__tabs { --n: 5; margin-bottom: clamp(48px, 6vw, 72px); }
.services__tabs .valve__name { font-size: 12px; }
.panel { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(36px, 5vw, 80px); align-items: center; }
.panel[hidden] { display: none; }
.panel__media { position: relative; overflow: hidden; }
.panel__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.panel__media figcaption { position: absolute; left: 0; bottom: 0; padding: 10px 16px; background: var(--bg); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2); }
.panel__media figcaption span { color: var(--accent); margin-right: 10px; }
.panel__body h3 { font-family: var(--f-display); font-weight: 400; font-size: clamp(28px, 2.8vw, 40px); line-height: 1.1; margin-bottom: 18px; }
.panel__body > p { color: var(--text-2); margin-bottom: 24px; }
.checks { margin-bottom: 30px; border-top: 1px solid var(--line); }
.checks li { padding: 12px 0 12px 28px; border-bottom: 1px solid var(--line); position: relative; font-size: 16px; }
.checks li::before { content: ""; position: absolute; left: 0; top: 50%; width: 14px; height: 1px; background: var(--accent); }
.panel.is-entering .panel__media img { animation: fade-in 0.8s var(--ease) both; }
.panel.is-entering .panel__body { animation: rise 0.7s var(--ease) both; }

/* Galerie : ce qui se cache, ce qui se voit */
.galerie { margin-top: clamp(64px, 8vw, 110px); padding-top: clamp(40px, 5vw, 64px); border-top: 1px solid var(--line); }
.galerie__head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 16px clamp(36px, 5vw, 80px); align-items: end; margin-bottom: clamp(28px, 3vw, 40px); }
.galerie__title { font-family: var(--f-display); font-weight: 400; font-size: clamp(28px, 2.8vw, 40px); line-height: 1.1; }
.galerie__title em { color: var(--accent); }
.galerie__head p { color: var(--text-2); max-width: 600px; }
.galerie__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.2vw, 18px); }
.galerie__item { position: relative; overflow: hidden; background: var(--bg-2); }
.galerie__item img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform 1.2s var(--ease); }
.galerie__item:hover img { transform: scale(1.04); }
.galerie__item figcaption { position: absolute; left: 0; bottom: 0; max-width: calc(100% - 24px); padding: 10px 14px; background: var(--bg); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-2); }
.galerie__item figcaption span { display: block; margin-bottom: 3px; font-size: 10px; letter-spacing: 0.2em; color: var(--accent); }
.galerie__note { margin-top: 16px; font-size: 13px; color: var(--text-3); }
@keyframes fade-in { from { opacity: 0; transform: scale(1.03); } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }

/* Avant / Après */
.filters { --n: 5; --orb: 48px; max-width: 720px; margin-bottom: clamp(36px, 5vw, 56px); }
.filters .valve__name { font-size: 11px; }
.ba-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(24px, 3vw, 40px); }
.ba-card--wide { grid-column: 1 / -1; }
.ba-card.is-out { opacity: 0 !important; transform: scale(0.98) !important; transition: opacity 0.3s, transform 0.3s; }
.ba-card[hidden] { display: none; }
.ba { --pos: 50%; position: relative; overflow: hidden; aspect-ratio: 4 / 3; background: var(--surface); touch-action: pan-y; user-select: none; -webkit-user-select: none; cursor: ew-resize; }
.ba-card--wide .ba { aspect-ratio: 16 / 9; }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ba__before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba__before img { filter: saturate(0.85); }
/* la poignée est un tuyau avec un raccord */
.ba__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 8px; margin-left: -4px; pointer-events: none; background: var(--metal); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25); }
.ba__knob { position: absolute; top: 50%; left: 50%; width: 50px; height: 50px; margin: -25px 0 0 -25px; border-radius: 50%; display: grid; place-items: center; background: #0e0d0b; color: #efe9de; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35), 0 6px 18px rgba(0, 0, 0, 0.4); transition: transform 0.3s var(--ease); }
.ba__knob svg { width: 22px; height: 22px; }
.ba.is-dragging .ba__knob { transform: scale(0.92); }
.ba__range { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 0; opacity: 0; margin: 0; pointer-events: none; }
.ba:focus-within .ba__knob { box-shadow: 0 0 0 2px var(--accent); }
.ba__tag { position: absolute; top: 14px; padding: 6px 10px; font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: #fff; background: rgba(8, 8, 8, 0.55); pointer-events: none; transition: opacity 0.3s; }
.ba__tag--before { left: 14px; }
.ba__tag--after { right: 14px; }
.ba-card__meta { padding-top: 18px; display: grid; grid-template-columns: auto 1fr; column-gap: 24px; align-items: baseline; }
.ba-card__cat { grid-column: 1 / -1; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.ba-card__meta h3 { font-family: var(--f-display); font-weight: 400; font-size: 24px; white-space: nowrap; }
.ba-card__meta p { color: var(--text-2); font-size: 15px; }

/* Citation */
.quote { position: relative; z-index: 2; padding: clamp(90px, 10vw, 150px) 0; background: var(--bg); border-top: 1px solid var(--line); text-align: center; }
.quote blockquote { font-family: var(--f-display); font-style: italic; font-size: clamp(28px, 3.6vw, 52px); line-height: 1.2; max-width: 980px; margin: 0 auto 22px; }
.quote p { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); }

/* Méthode : le manomètre */
.methode__grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(40px, 6vw, 96px); align-items: center; }
.gauge { position: relative; max-width: 420px; margin: 0 auto; }
.gauge svg { width: 100%; height: auto; overflow: visible; }
.gauge__dial { fill: var(--bg-2); stroke: var(--line-2); stroke-width: 1.5; }
.gauge__ring { fill: none; stroke: var(--metal-stroke, var(--accent)); stroke-width: 10; }
.gauge__tick { stroke: var(--text-3); stroke-width: 2; }
.gauge__tick--major { stroke: var(--text); stroke-width: 3; }
.gauge__num { font-family: var(--f-display); font-size: 20px; fill: var(--text-2); text-anchor: middle; }
.gauge__num.is-on { fill: var(--accent); }
.gauge__arc { fill: none; stroke: var(--water); stroke-width: 6; stroke-linecap: round; }
.gauge__needle { transform-origin: 200px 200px; transform: rotate(calc(-120deg + var(--p, 0) * 240deg)); transition: transform 0.25s linear; }
.gauge__needle path { fill: var(--leak); }
.gauge__hub { fill: var(--text); }
.gauge__unit { font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; fill: var(--text-3); text-anchor: middle; }
.steps { border-top: 1px solid var(--line); counter-reset: s; }
.step { display: grid; grid-template-columns: 64px 1fr; gap: 20px; padding: 24px 0; border-bottom: 1px solid var(--line); opacity: 0.45; transition: opacity 0.5s; }
.step.is-active { opacity: 1; }
.step__num { font-family: var(--f-display); font-size: 34px; line-height: 1; color: var(--accent); }
.step h3 { font-family: var(--f-display); font-weight: 400; font-size: 24px; line-height: 1.2; }
.step p { color: var(--text-2); font-size: 15px; margin-top: 4px; }
.engagements { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: clamp(64px, 8vw, 100px); border-top: 1px solid var(--line); }
.engagements li { display: flex; align-items: center; gap: 14px; padding: 24px 20px 0 0; font-size: 14px; font-weight: 500; }
.engagements svg { width: 26px; height: 26px; color: var(--accent); flex: none; }

/* Zone */
.zone__grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(40px, 6vw, 96px); align-items: center; }
.zone__text .title { margin-bottom: 24px; }
.zone__text > p { color: var(--text-2); margin-bottom: 26px; }
.zone__map svg { width: 100%; height: auto; overflow: hidden; }
.map-sea { fill: var(--sea); }
.map-coast { fill: none; stroke: var(--line-2); stroke-width: 1.2; }
.map-hatch line { stroke: var(--line); stroke-width: 1; }
.map-ring { fill: none; stroke: var(--line-2); stroke-dasharray: 3 6; }
.map-ring-label { font-size: 10px; letter-spacing: 0.16em; fill: var(--text-3); paint-order: stroke; stroke: var(--bg-2); stroke-width: 4px; }
.map-sea-label { font-family: var(--f-display); font-style: italic; font-size: 18px; fill: var(--text-3); }
@keyframes pulse { from { transform: scale(0.4); opacity: 1; } to { transform: scale(3.2); opacity: 0; } }

/* Le réseau en couches : gaine, manchons, métal, reflet, alésage, puis l'eau (carte et schéma) */
.net-view { --pw: 6px; }
.net-view svg path { fill: none; stroke-linejoin: round; }
[data-feeds] { transition: opacity 0.35s; }
.net-case path { stroke: var(--m3); stroke-width: calc(var(--pw) + 2px); stroke-linecap: round; }
.net-sleeve-o path { stroke: var(--m3); stroke-width: calc(var(--pw) + 6px); }
.net-sleeve path { stroke: var(--m2); stroke-width: calc(var(--pw) + 4px); }
.net-metal path { stroke: var(--m1); stroke-width: var(--pw); stroke-linecap: round; }
.net-shine path { stroke: var(--m4); stroke-width: calc(var(--pw) * 0.5 + 2px); stroke-linecap: round; opacity: 0.7; }
.net-bore path { stroke: var(--bg); stroke-width: calc(var(--pw) * 0.5); stroke-linecap: round; }
.net-fill path {
  stroke: var(--water); stroke-width: calc(var(--pw) * 0.5);
  stroke-dasharray: var(--len) var(--len); stroke-dashoffset: var(--len);
  transition: stroke-dashoffset var(--dur) linear var(--delay), opacity 0.35s;
}
.net-view.is-on .net-fill path { stroke-dashoffset: 0; }
.net-flow path {
  stroke: #fff; stroke-width: calc(var(--pw) * 0.28); stroke-linecap: round; stroke-dasharray: 0.1 10; stroke-opacity: 0;
  animation: net-flow 1s linear infinite paused;
  transition: stroke-opacity 0.6s ease calc(var(--delay) + var(--dur)), opacity 0.35s;
}
.net-view.is-on .net-flow path { stroke-opacity: 0.75; }
.net-view.in-view .net-flow path { animation-play-state: running; }
@keyframes net-flow { to { stroke-dashoffset: -10.1; } }
.net-valve .v-body { fill: var(--m1); stroke: var(--m3); stroke-width: 1; stroke-linejoin: round; }
.net-valve .v-stem { stroke: var(--m3); stroke-width: 2; }
.net-valve .v-wheel { fill: var(--m2); stroke: var(--m3); stroke-width: 1; }
/* un trajet allumé : le reste du réseau s'efface */
.net-view.has-route [data-feeds]:not(.is-route) { opacity: 0.2; }
.net-view.is-on .net-flow .is-route { stroke-width: calc(var(--pw) * 0.4); animation-duration: 0.5s; }

/* Carte : raccords et vanne de l'atelier */
.map-town, .map-home { cursor: pointer; }
.map-town { transition: opacity 0.35s; }
.map-town .fit { fill: var(--m1); stroke: var(--m3); stroke-width: 1; }
.map-town .hole { fill: var(--bg); }
.map-town .port { fill: var(--water); transform: scale(0); transform-box: fill-box; transform-origin: center; transition: transform 0.5s var(--ease) var(--t, 0s); }
.net-view.is-on .map-town .port { transform: none; }
.map-town text { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; fill: var(--text-3); paint-order: stroke; stroke: var(--bg-2); stroke-width: 3px; stroke-linejoin: round; transition: fill 0.3s; }
.map-town--key text { font-family: var(--f-display); font-size: 17px; letter-spacing: 0.02em; text-transform: none; fill: var(--text); }
.map-town.is-route text { fill: var(--text); }
.map-town.is-hl .fit { stroke: var(--water); stroke-width: 2.5; }
.map-town.is-hl text { fill: var(--water-ink); }
.net-view.has-route .map-town:not(.is-route) { opacity: 0.35; }
.map-home .pulse { fill: none; stroke: var(--accent); transform-box: fill-box; transform-origin: center; animation: pulse 2.6s var(--ease) infinite; }
.map-home .wheel { transform-box: fill-box; transform-origin: center; transition: transform 1.4s var(--ease); }
.map-home .wheel circle { fill: var(--bg); stroke: var(--m1); stroke-width: 2.6; }
.map-home .wheel path { stroke: var(--m1); stroke-width: 1.6; }
.net-view.is-on .map-home .wheel { transform: rotate(-270deg); }
.map-home .hub { fill: var(--accent); }
.map-home text { font-family: var(--f-display); font-size: 16px; letter-spacing: 0.08em; fill: var(--text); paint-order: stroke; stroke: var(--bg-2); stroke-width: 3px; stroke-linejoin: round; }

/* Schéma : les communes desservies, raccordées à l'atelier */
.pnet { --pw: 9px; margin-top: clamp(72px, 9vw, 128px); }
.pnet__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 48px; margin-bottom: 40px; }
.pnet__head h3 { font-family: var(--f-display); font-weight: 400; font-size: clamp(28px, 3.2vw, 42px); line-height: 1.08; letter-spacing: -0.01em; }
.pnet__head h3 em { color: var(--accent); }
.pnet__head div > p { margin-top: 10px; font-size: 15px; color: var(--text-2); }
.pnet__readout { display: grid; gap: 3px; width: min(100%, 400px); padding: 14px 18px; border-left: 2px solid var(--water); background: var(--sea); font-size: 14.5px; line-height: 1.45; color: var(--text-2); }
.pnet__k { font-size: 10.5px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-3); }
.pnet__v b { font-weight: 600; color: var(--text); }
.pnet__km { font-size: 12.5px; color: var(--water-ink); }
.pnet__stage { position: relative; }
.pnet__stage > svg { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }
/* sans JavaScript : une simple liste par secteur */
.pnet:not(.is-drawn) .pnet__source { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.pnet:not(.is-drawn) .pnet__line + .pnet__line { margin-top: 18px; }
.pnet:not(.is-drawn) .pnet__name { margin-bottom: 6px; font-size: 11px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-3); }
.pnet:not(.is-drawn) ol { display: flex; flex-wrap: wrap; gap: 4px 22px; }
/* schéma dessiné */
.pnet.is-drawn .pnet__source, .pnet.is-drawn .pnet__name, .pnet.is-drawn li, .pnet.is-drawn .pnet__stage > .pnet__readout { position: absolute; z-index: 1; }
.pnet__source { display: flex; align-items: center; gap: 14px; }
.pnet.is-drawn .pnet__source { transform: translate(-24px, -50%); }
.pnet__source p { display: grid; line-height: 1.2; }
.pnet__source .town-btn { font-family: var(--f-display); font-size: 24px; text-align: left; transition: color 0.3s; }
.pnet__source .town-btn:hover, .pnet__source .town-btn.is-hl { color: var(--water-ink); }
.pnet__source small { font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-3); }
.pnet.is-on .pnet__source .orb__lever { transform: rotate(90deg); }
.pnet.is-drawn .pnet__name {
  transform: translateY(-50%); white-space: nowrap; line-height: 1;
  padding: 6px 10px 6px 12px; border-radius: 3px; background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--m1);
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text);
}
.pnet.is-drawn .pnet__name::after { content: "▸"; margin-left: 8px; color: var(--water-ink); }
.pnet.is-drawn .pnet__name small { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.pnet li .town-btn { position: relative; font-size: 13.5px; line-height: 1.25; color: var(--text-2); transition: color 0.3s, opacity 0.35s; }
.pnet li .town-btn.is-key { font-weight: 600; color: var(--text); }
.pnet li .town-btn::before, .pnet li .town-btn::after { content: ""; position: absolute; border-radius: 50%; }
.pnet li .town-btn::before { width: 22px; height: 22px; background: var(--bg); box-shadow: 0 0 0 1px var(--m3), inset 0 0 0 3px var(--m1), inset 0 0 0 4px var(--m4); transition: box-shadow 0.3s; }
.pnet li .town-btn::after { width: 10px; height: 10px; background: var(--water); transform: scale(0); transition: transform 0.5s var(--ease) var(--t, 0s); }
.pnet.is-on li .town-btn::after { transform: none; }
.pnet--across li { transform: translate(-50%, -11px); }
.pnet--across li .town-btn { display: block; width: 100%; padding-top: 31px; text-align: center; }
.pnet--across li .town-btn::before { left: 50%; top: 0; margin-left: -11px; }
.pnet--across li .town-btn::after { left: 50%; top: 6px; margin-left: -5px; }
.pnet--down li { transform: translate(-11px, -50%); }
.pnet--down li .town-btn { display: flex; align-items: center; min-height: 22px; padding-left: 34px; text-align: left; }
.pnet--down li .town-btn::before { left: 0; top: 50%; margin-top: -11px; }
.pnet--down li .town-btn::after { left: 6px; top: 50%; margin-top: -5px; }
.pnet li .town-btn:hover, .pnet li .town-btn.is-hl, .pnet li .town-btn.is-route { color: var(--text); }
.pnet li .town-btn:hover::before, .pnet li .town-btn.is-hl::before { box-shadow: 0 0 0 1px var(--m3), inset 0 0 0 3px var(--m1), inset 0 0 0 4px var(--m4), 0 0 0 6px color-mix(in srgb, var(--water) 30%, transparent); }
.pnet.has-route li .town-btn:not(.is-route) { opacity: 0.4; }
.pnet .town-btn[aria-pressed="true"], .pnet li .town-btn[aria-pressed="true"] { color: var(--water-ink); }
.town-btn:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }
.pnet--down > .pnet__readout { position: sticky; z-index: 3; bottom: 16px; width: 100%; margin-top: 32px; background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--line), 0 14px 34px rgba(0, 0, 0, 0.28); }
/* communes citées dans le texte : elles mènent à la carte */
.zone__pages { display: flex; flex-wrap: wrap; gap: 14px 28px; }
.pnet__more { justify-self: start; margin-top: 6px; font-size: 13px; color: var(--text); border-bottom: 1px solid var(--line-2); transition: color 0.3s, border-color 0.3s; }
.pnet__more:hover { color: var(--accent); border-color: var(--accent); }
.town-link { color: var(--text); border-bottom: 1px dotted var(--water-ink); transition: color 0.3s, border-color 0.3s; }
.town-link.is-key { font-weight: 600; }
.town-link:hover, .town-link:focus-visible, .town-link.is-hl { color: var(--water-ink); border-bottom-style: solid; }

/* FAQ : chaque question s'ouvre comme une vanne quart de tour */
.faq__grid { display: grid; grid-template-columns: 4fr 8fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.faq__aside { position: sticky; top: 120px; }
.faq__aside .title { margin: 18px 0 18px; }
.faq__aside p { color: var(--text-2); }
.faq__aside a { color: var(--text); border-bottom: 1px solid var(--line-2); }
.faq__list { border-top: 1px solid var(--line); }
.faq__list details { border-bottom: 1px solid var(--line); }
.faq__list summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 0; cursor: pointer; font-family: var(--f-display); font-size: clamp(19px, 1.7vw, 24px); transition: color 0.3s; }
.faq__list summary::-webkit-details-marker { display: none; }
.faq__list summary:hover { color: var(--accent); }
.faq__icon { width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--accent); }
.faq__icon svg { width: 22px; height: 22px; transition: transform 0.5s var(--ease); }
details[open] .faq__icon svg { transform: rotate(90deg); }
details[open] .faq__icon { background: var(--text); color: var(--bg); box-shadow: none; }
.faq__a p { color: var(--text-2); padding: 0 56px 26px 0; }

/* Contact */
.contact__grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.contact__info .title { margin: 18px 0 18px; }
.contact__info > p { color: var(--text-2); margin-bottom: 32px; }
.channels { border-top: 1px solid var(--line); }
.channels a, .channels li > span { display: flex; align-items: center; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.channels .orb { --size: 46px; }
.channels small { display: block; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3); }
.channels strong { display: block; font-family: var(--f-display); font-weight: 400; font-size: 24px; }
.channels a:hover strong { color: var(--accent); }
.orb--wa { color: #25d366; }
.form { display: grid; gap: 22px; padding: clamp(24px, 3.5vw, 44px); background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--line); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.field { display: grid; gap: 8px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field > span, .field legend { font-size: 12px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2); padding: 0; }
.field i { font-style: normal; font-weight: 400; color: var(--text-3); letter-spacing: 0; text-transform: none; }
.field input, .field textarea { width: 100%; font: inherit; font-size: 17px; color: var(--text); background: transparent; border: 0; border-bottom: 1px solid var(--line-2); padding: 10px 0; border-radius: 0; transition: border-color 0.3s; }
.field textarea { resize: vertical; min-height: 110px; }
.field input::placeholder, .field textarea::placeholder { color: var(--text-3); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field.is-invalid input, .field.is-invalid textarea { border-color: #c2584a; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chips span { display: block; padding: 9px 16px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line-2); font-size: 14px; transition: 0.3s var(--ease); }
.chips input:checked + span { background: var(--text); color: var(--bg); box-shadow: none; }
.chips input:focus-visible + span { outline: 1px solid var(--accent); outline-offset: 3px; }
.drop { position: relative; display: flex; align-items: center; gap: 16px; padding: 16px 18px; margin-top: 4px; border: 1px dashed var(--line-2); cursor: pointer; transition: border-color 0.3s, background-color 0.3s; }
.drop:hover, .drop.is-over { border-color: var(--accent); background: var(--sea); }
.drop input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.drop.is-full { opacity: 0.5; pointer-events: none; }
.drop__text { display: grid; gap: 2px; }
.drop__text strong { font-size: 14px; font-weight: 600; }
.drop__text small { font-size: 14px; color: var(--text-3); }
.drop__count { margin-left: auto; font-size: 13px; color: var(--accent); white-space: nowrap; font-variant-numeric: tabular-nums; }
.drop:focus-within { outline: 1px solid var(--accent); outline-offset: 3px; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 10px; }
.thumbs:empty { display: none; }
.thumb { position: relative; aspect-ratio: 1; overflow: hidden; box-shadow: inset 0 0 0 1px var(--line-2); animation: fade-in 0.5s var(--ease) both; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb button { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: rgba(10, 9, 8, 0.72); color: #fff; }
.thumb button:hover { background: var(--accent); color: var(--bg); }
.thumb button svg { width: 14px; height: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--text-2); line-height: 1.5; }
.consent input { margin-top: 3px; accent-color: var(--accent); width: 16px; height: 16px; flex: none; }
.consent.is-invalid span { color: #c2584a; }
.form__actions { display: grid; grid-template-columns: 1fr auto; gap: 12px; }
.form__status { min-height: 1.4em; font-size: 15px; color: var(--accent); text-align: center; }

/* ---------- Pied de page ---------- */
.footer { position: relative; z-index: 2; background: var(--bg-2); border-top: 1px solid var(--line); padding: clamp(64px, 8vw, 100px) 0 28px; --ko: var(--bg-2); }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 56px; }
.footer__mark { width: 96px; height: 67px; margin-bottom: 16px; }
.footer__name { font-family: var(--f-display); font-size: 26px; letter-spacing: 0.16em; text-transform: uppercase; }
.footer__name i { color: var(--accent); text-transform: none; letter-spacing: 0; }
.footer__tag { color: var(--text-2); margin-top: 6px; }
.footer h2 { font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); margin-bottom: 16px; }
.footer__nav ul { display: grid; gap: 8px; }
.footer a { transition: color 0.3s; }
.footer a:hover { color: var(--accent); }
.footer__contact p { color: var(--text-2); margin-bottom: 8px; }
.footer__contact p a { color: var(--text); }
.footer__bottom { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-top: 22px; border-top: 1px solid var(--line); font-size: 13px; color: var(--text-3); }

/* Barre d'appel mobile */
.callbar { display: none; }

/* Logo SVG : séparations entre les pièces superposées */
.mark-ko { stroke: var(--ko, var(--bg)); stroke-width: 3.5; paint-order: stroke; }
.mark-rain { stroke-dasharray: 5 7; animation: rain 1.1s linear infinite; opacity: 0.8; }
@keyframes rain { to { stroke-dashoffset: -24; } }

/* ---------- Apparitions ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: var(--d, 0s); }
.js .reveal.is-in { opacity: 1; transform: none; }
/* Repères de la conduite : main.js mesure leur position au chargement, avant leur apparition.
   Sans décalage vertical, raccords et étiquettes « Fuite détectée » restent calés sur le libellé (au lieu de 18-20 px trop bas, l'étiquette chevauchant le libellé). */
.js .reveal[data-joint], .js body.is-loading .hero__index[data-hero] { transform: none; }
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

/* ---------- Responsive ---------- */
@media (max-width: 1520px) {
  .nav ul { gap: 18px; }
  .header__tools { gap: 12px; }
}
@media (max-width: 1400px) {
  .nav { display: none; }
  .burger { display: block; }
}
@media (max-width: 979px) {
  :root { --header-h: 66px; --rail: 10px; }
  .container { padding-left: calc(var(--gutter) + 22px); }
  .hero { justify-content: flex-start; padding-top: 40svh; padding-bottom: 48px; }
  .hero__content { max-width: none; }
  .hero__fallback { right: 50%; top: 23svh; width: min(78vw, 400px); transform: translate(50%, -50%); }
  .sec-head { grid-template-columns: 1fr; gap: 14px; }
  .sec-head .label { padding-top: 0; }
  .maison__grid, .panel, .zone__grid, .faq__grid, .contact__grid, .methode__grid { grid-template-columns: 1fr; }
  .faq__aside { position: static; }
  .engagements { grid-template-columns: 1fr 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
  .header__phone { display: none; }
  .galerie__head { grid-template-columns: 1fr; }
  .galerie__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* Avant / Après sur deux colonnes étroites : le titre (insécable) élargissait la grille au-delà de l'écran vers 720-930 px */
  .ba-card__meta { grid-template-columns: 1fr; }
  .ba-card__meta h3 { white-space: normal; margin-bottom: 4px; }
}
/* Menu plein écran sur écran bas (portable 1280 × 800, téléphone 360 × 740…) : rangs resserrés pour garder le pied visible */
@media (max-height: 860px) {
  .menu ol a { padding: 10px 0; line-height: 1.3; }
}
@media (max-height: 760px) {
  .menu ol a { padding: 8px 0; line-height: 1.2; }
}
@media (max-width: 560px) {
  .galerie__grid { grid-template-columns: 1fr; gap: 22px; }
  .galerie__item { background: none; }
  .galerie__item figcaption { position: static; max-width: none; padding: 10px 0 0; background: none; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .site-header { gap: 16px; }
  .site-header .themes, .site-header .btn, .site-header .lang-switch { display: none; }
  .brand { gap: 10px; }
  .brand__mark { width: 46px; height: 32px; }
  .brand__name { font-size: 15px; letter-spacing: 0.12em; white-space: nowrap; }
  .brand__sub { font-size: 9px; letter-spacing: 0.14em; white-space: nowrap; }
  .hero__ctas { gap: 18px; }
  .hero__ctas .btn { width: 100%; }
  .manifold { gap: 6px; --orb: 56px; }
  .orb { --size: 56px; }
  .filters { --orb: 40px; }
  .filters .orb--sm { --size: 40px; }
  .valve__name { font-size: 10.5px; letter-spacing: 0.04em; }
  .valve__sub { display: none; }
  /* Collecteurs à cinq vannes (ouverture, savoir-faire) : médaillons et libellés resserrés pour tenir dès 360 px */
  .hero__index .manifold, .services__tabs { gap: 4px; --orb: 46px; }
  .hero__index .orb, .services__tabs .orb { --size: 46px; }
  .hero__index .orb__lever, .services__tabs .orb__lever { width: 22px; margin-left: -11px; height: 5px; top: -8px; }
  .hero__index .valve__name, .services__tabs .valve__name { font-size: 10px; letter-spacing: 0.02em; }
  .ba-grid { grid-template-columns: 1fr; }
  .ba, .ba-card--wide .ba { aspect-ratio: 4 / 3.4; }
  .engagements { grid-template-columns: 1fr; }
  .form__row, .form__actions { grid-template-columns: 1fr; }
  .faq__a p { padding-right: 0; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer { padding-bottom: 96px; }
  .callbar {
    display: grid; grid-template-columns: 1fr 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: var(--bg); border-top: 1px solid var(--line-2); padding-bottom: env(safe-area-inset-bottom);
    transform: translateY(110%); transition: transform 0.5s var(--ease);
  }
  .callbar.is-visible { transform: none; }
  .callbar a { display: flex; align-items: center; justify-content: center; gap: 8px; height: 56px; font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
  .callbar a + a { border-left: 1px solid var(--line); }
  .callbar svg { width: 18px; height: 18px; }
  .callbar .wa svg { color: #25d366; }
  .joint__tag { display: none; }
  .zone__map { --pw: 10px; }
  .pnet { --pw: 8px; }
  .pnet__readout { width: 100%; }
  .pnet--down > .pnet__readout { bottom: calc(66px + env(safe-area-inset-bottom)); }
}
/* Très petits téléphones (320 px) : le bouton ☰ sortait de l'écran ; WhatsApp reste dans la barre d'appel et dans le menu */
@media (max-width: 359px) {
  .site-header .header__wa { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001s !important; animation-iteration-count: 1 !important; transition-duration: 0.001s !important; }
  .net-view *, .net-view *::before, .net-view *::after { transition-delay: 0s !important; }
}
/* Safari avant 16.2 (iOS 16.1 et avant) ne connaît pas color-mix() : replis en couleurs simples. Une déclaration de repli
   placée juste avant ne suffirait pas : avec var(), color-mix() passe la lecture puis échoue au calcul (fond transparent). */
@supports not (color: color-mix(in srgb, red, blue)) {
  .site-header.is-scrolled { background: var(--bg); }
  .pnet li .town-btn:hover::before, .pnet li .town-btn.is-hl::before { box-shadow: 0 0 0 1px var(--m3), inset 0 0 0 3px var(--m1), inset 0 0 0 4px var(--m4), 0 0 0 6px rgba(214, 180, 112, 0.3); }
}
