/* Ardoise et Zinc Toitures : style « Toiture ». Fond ardoise, filets et textes secondaires en zinc, rouge tuile (--accent) avec parcimonie.
   Signature 1 : des pans de toiture (bords en pente de 9,6 degrés environ, qui s'emboîtent) et une échelle dont le curseur monte avec le défilement.
   Signature 2 : à l'ouverture, une trame d'ardoises se retire rangée par rangée et révèle la photo (voir site.js).
   Polices : --police-titre (Big Shoulders Display) et --police-texte (Hanken Grotesk) viennent de donnees.json. */
:root {
  --ardoise-0: #12171c;
  --ardoise-1: #1a2128;
  --ardoise-2: #222b34;
  --ardoise-3: #2c3742;
  --joint: #0d1115;
  --zinc: #aab4bd;
  --zinc-fonce: #7f8b95;
  --encre: #eef1f3;
  --etiquette: 2rem;
  --rayon: 2px;
  --h: 8.5vw;                 /* hauteur d'un pignon : demi-largeur x tan(9,6 degrés) */
  --haut-photo: min(70svh, 600px);
}
body {
  background: var(--joint);
  color: var(--encre);
  font-family: var(--police-texte);
  font-size: 1.0625rem;
  line-height: 1.65;
}
h1, h2, h3 { font-family: var(--police-titre); font-weight: 800; text-transform: uppercase; line-height: .96; letter-spacing: .01em; margin: 0 0 .5em; }
h2 { font-size: clamp(2.7rem, 1.2rem + 5.4vw, 6rem); }
h3 { font-size: 1.85rem; font-weight: 700; line-height: 1; letter-spacing: .02em; }
p { margin: 0 0 1em; }
a { color: inherit; }
.intro { color: var(--zinc); font-size: 1.125rem; }

.etiquette-demo { height: var(--etiquette); line-height: var(--etiquette); padding-block: 0; background: var(--ardoise-0); color: var(--zinc); }

/* ---------- en-tête flottant ---------- */
.entete { position: fixed; top: var(--etiquette); left: 0; right: 0; z-index: 70; color: #fff; background: rgba(18, 23, 28, .78); transition: background-color .25s, box-shadow .25s; }
html.defile .entete { top: 0; background: var(--ardoise-0); box-shadow: 0 1px 0 rgba(170, 180, 189, .25); }
.entete-interieur { display: flex; align-items: center; justify-content: space-between; min-height: 4.25rem; gap: 1rem; }
.marque { display: inline-flex; align-items: center; gap: .55rem; min-height: 2.75rem; font-family: var(--police-titre); font-weight: 800; font-size: clamp(1.1rem, .85rem + 1vw, 1.4rem); text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; text-decoration: none; line-height: 1; }
.marque-pignon { width: 1.5rem; height: auto; flex: none; }
.menu ul { display: flex; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.menu a { text-decoration: none; }
.menu li a { display: inline-flex; align-items: center; min-height: 2.75rem; }
.menu li a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 6px; text-decoration-thickness: 2px; }
.menu-telephone { font-weight: 700; }
.menu-bouton { display: inline-flex; align-items: center; gap: .6rem; min-height: 2.75rem; padding: 0 .9rem; background: transparent; color: inherit; border: 1.5px solid currentColor; border-radius: var(--rayon); font: inherit; font-weight: 600; }
.menu-bouton-barres { width: 1.1rem; height: 2px; background: currentColor; position: relative; }
.menu-bouton-barres::before, .menu-bouton-barres::after { content: ""; position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; }
.menu-bouton-barres::before { top: -6px; }
.menu-bouton-barres::after { top: 6px; }
@media (min-width: 900px) {
  .menu { display: flex; align-items: center; gap: 2rem; }
}
@media (max-width: 899px) {
  .menu { position: absolute; top: 100%; left: 0; right: 0; padding: 1rem var(--gouttiere) 1.5rem; background: var(--ardoise-0); color: var(--encre); border-top: 1px solid rgba(170, 180, 189, .25); }
  .menu ul { flex-direction: column; gap: 0; }
  .menu li a, .menu-telephone { display: flex; align-items: center; min-height: 2.75rem; padding: .35rem 0; }
  .menu-telephone { border-top: 1px solid rgba(170, 180, 189, .25); margin-top: .5rem; }
}

/* ---------- échelle : barreaux sur le côté, curseur qui monte avec le défilement (--p de 0 à 1, posé par site.js) ---------- */
.echelle { position: fixed; z-index: 55; left: clamp(5px, 1.6vw, 24px); top: 26vh; bottom: 20vh; width: clamp(7px, 1.9vw, 26px); pointer-events: none; --p: 0; }
.echelle-barreaux { position: absolute; inset: 0; border-inline: 2px solid rgba(170, 180, 189, .55); background: repeating-linear-gradient(to bottom, transparent 0, transparent 15px, rgba(170, 180, 189, .55) 15px, rgba(170, 180, 189, .55) 17px); }
.echelle-curseur { position: absolute; left: -5px; right: -5px; height: 1.9rem; top: calc(var(--p) * (100% - 1.9rem)); background: var(--accent); border-radius: 1px; box-shadow: 0 0 0 3px var(--ardoise-0); }
@media (max-width: 899px) { .echelle { top: 30vh; bottom: 24vh; } .echelle-curseur { left: -2px; right: -2px; height: 1.5rem; top: calc(var(--p) * (100% - 1.5rem)); } }

/* ---------- pans de toiture : bords en pente qui s'emboîtent (le pan suivant remonte dans l'entaille du précédent) ---------- */
.pan { --fond: var(--ardoise-1); position: relative; background: var(--fond); margin-top: calc(var(--h) * -1); padding-block: calc(var(--h) + clamp(2.5rem, 5vw, 5.5rem)); clip-path: polygon(0 var(--h), 50% 0, 100% var(--h), 100% 100%, 50% calc(100% - var(--h)), 0 100%); }
.f0 { --fond: var(--ardoise-0); }
.f1 { --fond: var(--ardoise-1); }
.f2 { --fond: var(--ardoise-2); }
/* filet de zinc le long de la pente du haut (SVG réel en tête du pan) */
.filet { position: absolute; left: 0; top: 0; width: 100%; height: var(--h); pointer-events: none; overflow: visible; }
.filet polyline { fill: none; stroke: rgba(170, 180, 189, .55); stroke-width: 2; vector-effect: non-scaling-stroke; }

.tete-section { margin-bottom: clamp(2rem, 4vw, 3.5rem); max-width: 60rem; }
.etiquette-section { display: flex; align-items: center; gap: .9rem; margin: 0 0 1rem; font-size: .8125rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--zinc); }
.etiquette-num { display: inline-flex; align-items: center; gap: .9rem; font-family: var(--police-titre); font-size: 1.15rem; letter-spacing: .08em; color: var(--encre); }
.etiquette-num::after { content: ""; width: 2.25rem; height: 3px; background: var(--accent); }

/* ---------- boutons ---------- */
.bouton { display: inline-flex; align-items: center; justify-content: center; min-height: 3.25rem; padding: 0 1.6rem; background: var(--accent); color: #fff; border: 2px solid var(--accent); border-radius: var(--rayon); font-family: var(--police-titre); font-weight: 800; font-size: 1.4rem; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background-color .2s, border-color .2s, color .2s; }
.bouton:hover { background: #b3354b; border-color: #b3354b; }
.bouton-clair { background: transparent; border-color: var(--encre); color: var(--encre); }
.bouton-clair:hover { background: var(--encre); border-color: var(--encre); color: var(--ardoise-0); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.75rem 0 0; }

/* ---------- ouverture : photo d'ardoises, motif posé, trame d'ardoises qui se retire ---------- */
.ouverture { --fond: var(--ardoise-0); position: relative; background: var(--ardoise-0); min-height: calc(100svh - var(--etiquette)); display: flex; align-items: flex-end; color: #fff; overflow: hidden; isolation: isolate; clip-path: polygon(0 0, 100% 0, 100% 100%, 50% calc(100% - var(--h)), 0 100%); }
.ouverture-photo { position: absolute; inset: 0; z-index: -1; isolation: isolate; background: var(--ardoise-0); }
.ouverture-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* le voile fait partie du décor (photo et voile sont mesurés ensemble par le contrôle de contraste) */
.ouverture-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(18, 23, 28, .86) 0%, rgba(18, 23, 28, .66) 55%, rgba(18, 23, 28, .6) 100%); z-index: 1; }
.motif { position: absolute; z-index: 2; right: 0; top: clamp(6.5rem, 14vh, 9rem); width: min(44%, 620px); height: auto; }
/* téléphone : le motif se réduit à deux rangs en haut à droite, au-dessus du texte */
@media (max-width: 599px) {
  .motif { top: 6rem; width: 40%; aspect-ratio: 600 / 135; }
  .m-ardoise[data-rang="2"], .m-ardoise[data-rang="3"], .m-ardoise[data-rang="4"] { display: none; }
}
.m-ardoise { fill: #1b232a; fill-opacity: .88; stroke: var(--zinc); stroke-opacity: .42; stroke-width: 1.5; }
.ardoises { position: absolute; inset: 0; z-index: 3; overflow: hidden; pointer-events: none; }
.trame { position: absolute; left: 0; top: 0; width: 100%; height: 100%; display: block; max-width: none; }
.ardoise { stroke: rgba(170, 180, 189, .16); stroke-width: 1; }
/* Couverture de départ, active seulement sous html.anim : elle est retirée dans la même tâche que html.anim, quand site.js pose les vraies ardoises (aucune image entre les deux). Secours : elle s'efface seule après 2,2 s. */
html.anim .ouverture-photo::before { content: ""; position: absolute; inset: 0; z-index: 4; background: #232d36; animation: couvreur-secours .3s ease-out 2.2s forwards; }
@keyframes couvreur-secours { to { opacity: 0; visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { html.anim .ouverture-photo::before { display: none; } }
.ouverture-texte { position: relative; z-index: 5; padding-block: 7.5rem calc(var(--h) + 2rem); }
.surtitre { display: inline-flex; align-items: center; gap: .9rem; font-size: .9375rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 1.1rem; color: var(--encre); }
.surtitre::before { content: ""; width: 2.25rem; height: 3px; background: var(--accent); flex: none; }
.ouverture h1 { font-size: clamp(3.3rem, 1.2rem + 6.2vw, 8rem); max-width: 6.3em; line-height: .92; margin-bottom: .3em; }
.chapo { font-size: clamp(1.0625rem, 1rem + .5vw, 1.375rem); max-width: 50ch; color: var(--encre); }
.index-matieres { margin: 1.75rem 0 0; font-family: var(--police-titre); font-weight: 700; font-size: 1.1rem; letter-spacing: .22em; text-transform: uppercase; color: var(--zinc); }

/* ---------- matières ---------- */
.matieres { list-style: none; margin: 0; padding: 0; display: grid; gap: 3rem 2rem; grid-template-columns: 1fr; }
.matiere { display: grid; gap: 1.25rem; align-content: start; }
@media (min-width: 600px) and (max-width: 899px) { .matiere { grid-template-columns: 5fr 7fr; gap: 1.75rem; align-items: center; } }
@media (min-width: 900px) { .matieres { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* la photo, en pan : bord haut en pente, entière à l'écran (hauteur plafonnée) */
.matiere-photo { margin: 0; clip-path: polygon(0 20%, 100% 0, 100% 100%, 0 100%); background: var(--ardoise-0); }
.matiere-photo img { width: 100%; aspect-ratio: 3 / 2; max-height: var(--haut-photo); object-fit: cover; }
.matiere-texte h3 { color: var(--encre); margin-bottom: .35rem; }
.matiere-accroche { font-weight: 700; color: var(--zinc); letter-spacing: .02em; }
.points { list-style: none; margin: 1rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.points li { padding: .3rem .8rem; border: 1px solid rgba(170, 180, 189, .5); border-radius: var(--rayon); font-size: .9375rem; color: var(--zinc); }

/* ---------- prestations ---------- */
.presta-grille, .methode-grille, .zone-grille { display: grid; gap: 2.5rem; grid-template-columns: 1fr; align-items: start; }
.presta-grille { grid-template-areas: "photo" "liste" "carte"; }
.presta-figure { grid-area: photo; }
.prestations-liste { grid-area: liste; }
.presta-carte { grid-area: carte; }
@media (min-width: 900px) {
  .presta-grille { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); grid-template-rows: auto 1fr; grid-template-areas: "photo liste" "carte liste"; gap: 2.5rem 4rem; }
  .presta-carte { align-self: end; }
  .methode-grille { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 4rem; }
  .methode-figure { position: sticky; top: 7rem; }
  .zone-grille { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 4rem; }
}
.presta-figure, .methode-figure { margin: 0; }
.presta-carte { padding: 1.5rem 1.6rem 1rem; background: var(--ardoise-1); border-top: 3px solid var(--accent); border-radius: var(--rayon); }
.presta-carte h3 { margin-bottom: .6rem; }
.presta-carte p { color: var(--zinc); }
.presta-carte .actions { margin: 1.25rem 0 .5rem; }
.presta-figure .revele, .methode-figure .revele { clip-path: polygon(0 10%, 100% 0, 100% 100%, 0 100%); background: var(--ardoise-0); }
.presta-photo, .methode-photo { width: 100%; aspect-ratio: 4 / 3; max-height: var(--haut-photo); object-fit: cover; object-position: 50% 42%; }
@media (min-width: 900px) { .presta-photo, .methode-photo { aspect-ratio: 3 / 4; } }
figcaption { margin-top: 1rem; color: var(--zinc); font-size: .9375rem; padding-left: 1rem; border-left: 3px solid var(--accent); }
.prestations-liste, .etapes { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.prestation, .etape { display: grid; grid-template-columns: 4.25rem 1fr; gap: 1rem; padding-block: 1.5rem; border-top: 1px solid rgba(170, 180, 189, .4); }
.prestation:last-child, .etape:last-child { border-bottom: 1px solid rgba(170, 180, 189, .4); }
.prestation-num, .etape-num { font-family: var(--police-titre); font-weight: 800; font-size: 3rem; line-height: .9; color: var(--accent); }
.prestation h3, .etape h3 { margin-bottom: .45rem; }
.prestation p, .etape p { color: var(--zinc); margin-bottom: 0; }
.prestation .points { margin-top: .9rem; }

/* ---------- méthode ---------- */
.etape-num { font-size: 3.4rem; }
.etape p { max-width: 52ch; }

/* ---------- bandeau fuite : photo pleine largeur sous un voile sombre uniforme ---------- */
.bandeau { min-height: min(70svh, 600px); display: flex; align-items: center; color: #fff; overflow: hidden; isolation: isolate; }
.bandeau-photo { position: absolute; inset: 0; z-index: -1; background: var(--ardoise-0); }
.bandeau-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%; }
.bandeau-photo::after { content: ""; position: absolute; inset: 0; background: rgba(13, 17, 21, .64); }
.bandeau-texte { position: relative; z-index: 1; max-width: none; }
.bandeau h2 { font-size: clamp(2.6rem, 1.2rem + 4.8vw, 5.5rem); max-width: 15em; color: #fff; }
.bandeau .lecture { font-size: 1.1875rem; max-width: 46ch; }

/* ---------- zone ---------- */
.zone-liste { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .6rem; }
.zone-liste li { padding: .55rem 1.1rem; border: 1px solid rgba(170, 180, 189, .55); border-radius: var(--rayon); font-weight: 600; }
.zone-liste .zone-siege { background: var(--ardoise-0); border-color: var(--accent); border-width: 2px; }
.carte { margin: 1.75rem 0 0; max-width: 640px; }
.carte svg { width: 100%; height: auto; display: block; overflow: visible; }
.carte-fleuve { fill: none; stroke: var(--zinc-fonce); stroke-width: 14; stroke-linecap: round; opacity: .35; }
.carte-lien { stroke: var(--zinc-fonce); stroke-opacity: .5; stroke-width: 2; stroke-dasharray: 3 7; }
.carte-pignon { fill: var(--ardoise-0); stroke: var(--zinc); stroke-width: 3; stroke-linejoin: round; }
.carte-noeud text { font-family: var(--police-texte); font-size: 21px; font-weight: 600; fill: var(--encre); }
.carte-siege .carte-pignon { fill: var(--accent); stroke: var(--accent); transform: scale(1.5); }
.carte-siege text { font-size: 24px; font-weight: 800; }
.carte figcaption { margin-top: .6rem; font-size: .875rem; border-left: 0; padding-left: 0; }
.zone-photo .revele { clip-path: polygon(0 12%, 100% 0, 100% 100%, 0 100%); background: var(--ardoise-0); }
.zone-photo img { width: 100%; aspect-ratio: 7 / 5; max-height: var(--haut-photo); object-fit: cover; }
@media (min-width: 900px) { .zone-photo img { aspect-ratio: 4 / 5; } }
.avis { margin: clamp(2rem, 4vw, 3.5rem) 0 0; padding: 1.25rem 1.5rem; border: 1px dashed rgba(170, 180, 189, .6); border-radius: var(--rayon); color: var(--zinc); text-align: center; }

/* ---------- contact ---------- */
.contact-ligne { margin: 0 0 .75rem; }
.contact-tel { display: inline-flex; align-items: center; min-height: 3rem; font-family: var(--police-titre); font-weight: 800; font-size: clamp(2.4rem, 1.6rem + 2.4vw, 3.6rem); letter-spacing: .03em; text-decoration: none; color: var(--encre); }
.contact-tel:hover { color: var(--accent); }
address { font-style: normal; margin-bottom: 1.25rem; color: var(--zinc); }
.horaires { display: grid; grid-template-columns: auto 1fr; gap: .25rem 1.25rem; margin: 0 0 2rem; }
.horaires dt { font-weight: 700; }
.horaires dd { margin: 0; color: var(--zinc); }
.contact-bande { margin-bottom: clamp(2rem, 4vw, 3.5rem); }
.contact-bande .revele { clip-path: polygon(0 24%, 100% 0, 100% 100%, 0 100%); background: var(--ardoise-0); }
.contact-bande img { width: 100%; aspect-ratio: 4 / 3; max-height: var(--haut-photo); object-fit: cover; object-position: 50% 45%; }
@media (min-width: 700px) { .contact-bande img { aspect-ratio: 16 / 5; } }
.formulaire { display: grid; gap: 1.1rem; padding: clamp(1.25rem, 3vw, 2.25rem); background: var(--ardoise-1); border-top: 3px solid var(--accent); border-radius: var(--rayon); }
.champ label { display: block; font-weight: 600; margin-bottom: .35rem; }
.champ-requis { color: var(--zinc); }
.champ input, .champ textarea { width: 100%; min-height: 3rem; padding: .7rem .9rem; background: var(--joint); color: var(--encre); border: 1.5px solid var(--zinc-fonce); border-radius: var(--rayon); font: inherit; }
.champ textarea { min-height: 8rem; resize: vertical; }
.formulaire .bouton { justify-self: start; }
.formulaire-statut { padding: .9rem 1rem; background: var(--joint); border-left: 4px solid var(--accent); border-radius: var(--rayon); margin: 0; }

/* ---------- pied : pignon en haut, comme les autres pans ---------- */
.pied { position: relative; margin-top: calc(var(--h) * -1); background: var(--joint); color: var(--encre); clip-path: polygon(0 var(--h), 50% 0, 100% var(--h), 100% 100%, 0 100%); padding-top: var(--h); }
.pied-interieur { padding-block: 3rem 1rem; }
.pied-nom { font-family: var(--police-titre); font-weight: 800; font-size: 1.8rem; text-transform: uppercase; letter-spacing: .05em; }
.pied-interieur p:not(.pied-nom) { color: var(--zinc); }
.mention-pied { border-top: 1px solid rgba(170, 180, 189, .25); color: var(--zinc); }

/* ---------- barre d'appel (téléphone) ---------- */
.barre-appel a { background: var(--accent); color: #fff; font-family: var(--police-titre); font-weight: 800; font-size: 1.4rem; letter-spacing: .06em; text-transform: uppercase; }

/* contact : texte et formulaire côte à côte */
.contact-grille { display: grid; gap: 2.5rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 900px) { .contact-grille { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 4rem; } }

/* méthode : la colonne de la photo (photo, légende, remis en fin de chantier) tient dans l'écran quand elle reste en place */
.methode-photo { max-height: min(56svh, 480px); }
@media (min-width: 900px) { .methode-photo { aspect-ratio: 1 / 1; } }
.methode-carte { margin-top: 1.5rem; padding: 1.25rem 1.5rem; background: var(--ardoise-0); border-top: 3px solid var(--accent); border-radius: var(--rayon); }
.methode-carte h3 { margin-bottom: .6rem; font-size: 1.5rem; }
.methode-carte ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; color: var(--zinc); }
.methode-carte li { padding-left: 1.4rem; position: relative; }
.methode-carte li::before { content: ""; position: absolute; left: 0; top: .62em; width: .6rem; height: .6rem; border-left: 3px solid var(--accent); border-bottom: 3px solid var(--accent); transform: rotate(-45deg) scale(.8); transform-origin: center; }
