/* DLR Multi-Services — pages interieures : toiture, realisations, pages legales */
.section--serree { padding-top: 0; }

/* ------------------------------------------------------------------ hero court (toiture) */
.tete-photo { position: relative; min-height: 86svh; display: flex; align-items: flex-start; overflow: hidden; }
.tete-photo__fond, .tete-photo__fond img { position: absolute; inset: 0; width: 100%; height: 100%; }
.tete-photo__fond img { object-fit: cover; will-change: transform; }
.tete-photo__voile {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(13, 13, 13, .7) 0%, rgba(13, 13, 13, .15) 30%, rgba(13, 13, 13, .55) 62%, var(--noir) 100%);
}
.tete-photo__texte { position: relative; z-index: 1; padding-top: max(calc(var(--en-tete) + 40px), 30svh); padding-bottom: clamp(48px, 8vw, 96px); }
.tete-photo__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
@media (min-width: 900px) {
  .tete-photo__texte { padding-top: max(calc(var(--en-tete) + 60px), 22vh); }
  .tete-photo__voile { background: linear-gradient(90deg, rgba(13, 13, 13, .92) 0%, rgba(13, 13, 13, .55) 50%, rgba(13, 13, 13, .2) 100%), linear-gradient(180deg, rgba(13, 13, 13, 0) 70%, var(--noir)); }
}

/* ------------------------------------------------------------------ prestations */
.prestations { list-style: none; margin: 56px 0 0; padding: 0; display: grid; gap: 16px; }
@media (min-width: 680px) { .prestations { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1040px) { .prestations { grid-template-columns: repeat(3, 1fr); gap: 20px; } }
.prestation { padding: 30px 28px; }
.prestation h3 { font-size: 1.45rem; margin-bottom: 10px; }
.prestation p { color: var(--doux); }

/* ------------------------------------------------------------------ recit du chantier, au defilement */
.recit { position: relative; margin-top: 56px; }
.recit__visuel { position: relative; height: 72svh; border-radius: 22px; overflow: hidden; border: 1px solid var(--bord-or); background: var(--noir-3); }
.recit__image { position: absolute; inset: 0; opacity: 0; transition: opacity .6s var(--courbe); }
.recit__image.actif { opacity: 1; }
.recit__image img { width: 100%; height: 100%; object-fit: cover; }
.recit__progression { position: absolute; left: 18px; right: 18px; top: 16px; z-index: 2; height: 3px; border-radius: 3px; background: rgba(247, 247, 245, .22); overflow: hidden; }
.recit__progression span { display: block; height: 100%; background: var(--or); transform-origin: left; transform: scaleX(.2); transition: transform .5s var(--courbe); }
.recit__etapes { list-style: none; margin: 0; padding: 0; position: relative; z-index: 2; }
.recit__etape { display: flex; align-items: flex-end; min-height: 90svh; padding-bottom: 6svh; }
.recit__carte { padding: 24px 22px; width: 100%; }
.recit__num { font: 600 .95rem/1.2 var(--police); color: var(--or); margin-bottom: 12px; }
.recit__carte h3 { font-size: clamp(1.35rem, 2.6vw, 2rem); margin-bottom: 10px; }
.recit__carte p:last-child { color: var(--doux); }
.recit__suite { margin-top: 40px; }
/* sans mouvement : les etapes sont listees avec leur photo, dans l'ordre */
html:not(.mvt) .recit__visuel { height: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; border: 0; background: none; margin-bottom: 24px; }
html:not(.mvt) .recit__image { position: relative; opacity: 1; transform: none; aspect-ratio: 9 / 16; border-radius: 14px; overflow: hidden; }
html:not(.mvt) .recit__progression { display: none; }
html:not(.mvt) .recit__etape { min-height: 0; padding: 0 0 16px; }
.mvt .recit__visuel { position: sticky; top: calc(var(--en-tete) + 18px); height: calc(100svh - var(--en-tete) - 36px); }
.mvt .recit__etapes { margin-top: calc(-100svh + var(--en-tete) + 36px); }
.mvt .recit__etape:first-child { min-height: calc(100svh - var(--en-tete) - 36px); }
@media (max-width: 899px) {
  .mvt .recit__etape { padding-inline: 14px; }
  /* le flou d'arriere-plan recalcule a chaque image sur une photo qui defile coute cher sur mobile : fond plein */
  .recit__carte { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(17, 17, 15, .88); }
}
@media (min-width: 900px) {
  .mvt .recit { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 60px; align-items: start; }
  .mvt .recit__visuel { top: calc(var(--en-tete) + 6vh); height: calc(88vh - var(--en-tete)); }
  .mvt .recit__etapes { margin-top: 0; }
  .mvt .recit__etape, .mvt .recit__etape:first-child { min-height: 88vh; align-items: center; padding: 0; }
  .recit__carte { padding: 38px 36px; }
  .mvt .recit__etape .recit__carte { opacity: .35; transform: translateX(16px); transition: opacity .5s, transform .6s var(--courbe); }
  .mvt .recit__etape.actif .recit__carte { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ grille de cartes chantier */
.grille-chantiers { display: grid; gap: 18px; margin-top: 44px; }
@media (min-width: 700px) { .grille-chantiers { grid-template-columns: repeat(3, 1fr); } }
.carte-chantier--grille { width: auto; display: block; }

/* ------------------------------------------------------------------ realisations : filtres et cartes */
.filtres { display: flex; flex-wrap: wrap; gap: 8px; }
.filtre {
  position: relative; min-height: 44px; padding: 0 20px; border-radius: 999px; cursor: pointer; overflow: hidden;
  border: 1px solid var(--bord-or); background: rgba(247, 247, 245, .03); color: var(--blanc);
  font: 500 1rem/1 var(--police); transition: color .3s, border-color .3s;
}
.filtre::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--or); border-radius: inherit; transform: scale(.4); opacity: 0; transition: transform .45s var(--courbe), opacity .3s; }
.filtre { isolation: isolate; }
.filtre[aria-pressed="true"] { color: var(--noir); border-color: var(--or); }
.filtre[aria-pressed="true"]::before { transform: none; opacity: 1; }
.filtre:hover { border-color: var(--or); }
.filtres__etat { margin-top: 14px; color: var(--doux); font-size: .92rem; min-height: 1.4em; }
.reals { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 18px; }
@media (min-width: 700px) { .reals { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .reals { grid-template-columns: repeat(3, 1fr); gap: 22px; } }
.real[hidden] { display: none; }
.real__carte {
  position: relative; display: block; aspect-ratio: 4 / 5; border-radius: 20px; overflow: hidden; text-decoration: none; color: var(--blanc);
  border: 1px solid var(--bord-or); background: var(--noir-3); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .8);
}
.real__photo, .real__photo img { position: absolute; inset: 0; width: 100%; height: 100%; }
.real__photo img { object-fit: cover; transition: scale .9s var(--courbe); }
.real__carte:hover .real__photo img { scale: 1.05; }
.real__carte::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(13, 13, 13, 0) 45%, rgba(13, 13, 13, .94)); }
.real__texte { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 24px; }
.real__titre { display: block; margin-top: 10px; font-size: clamp(1.4rem, 2.2vw, 1.75rem); font-weight: 800; line-height: 1.08; }
.real__info { display: block; margin-top: 8px; color: var(--doux); font-size: .95rem; }
.real__badge { color: var(--or); }
.reals__vide { margin-top: 24px; padding: 26px; color: var(--doux); }
.reals__vide a { color: var(--blanc); }
.appel-bas__boite { display: grid; gap: 28px; padding: clamp(28px, 5vw, 60px); align-items: center; }
@media (min-width: 900px) { .appel-bas__boite { grid-template-columns: 1fr auto; } }
.appel-bas__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ------------------------------------------------------------------ visionneuse d'un chantier */
.visionneuse { position: fixed; inset: 0; z-index: 80; display: flex; align-items: stretch; justify-content: center; }
.visionneuse__fond { position: absolute; inset: 0; background: rgba(8, 8, 8, .9); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.visionneuse__boite {
  position: relative; display: flex; flex-direction: column; width: 100%; max-width: 1400px;
  padding: max(16px, env(safe-area-inset-top)) 0 max(14px, env(safe-area-inset-bottom)); touch-action: pan-x pinch-zoom;
}
.visionneuse__tete { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 0 var(--gouttiere); }
.visionneuse__metier { font: 600 .95rem/1.2 var(--police); color: var(--or); margin-bottom: 8px; }
.visionneuse__titre { font-size: clamp(1.5rem, 3.4vw, 2.6rem); }
.visionneuse__resume { padding: 10px var(--gouttiere) 0; color: var(--doux); max-width: 80ch; font-size: .98rem; }
.visionneuse__fermer { position: relative; flex: none; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--bord-or); background: rgba(247, 247, 245, .06); cursor: pointer; color: var(--blanc); }
.visionneuse__fermer span { position: absolute; left: 14px; right: 14px; top: 23px; height: 2px; background: currentColor; border-radius: 2px; transform: rotate(45deg); }
.visionneuse__fermer span + span { transform: rotate(-45deg); }
.visionneuse__fermer:hover { border-color: var(--or); color: var(--or); }
.visionneuse__piste {
  flex: 1; min-height: 0; display: flex; gap: 14px; margin-top: 16px; padding: 0 var(--gouttiere);
  overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior: contain;
}
.visionneuse__piste::-webkit-scrollbar { display: none; }
.vue { position: relative; flex: none; height: 100%; display: flex; flex-direction: column; gap: 10px; scroll-snap-align: center; margin: 0; max-width: calc(100vw - 2 * var(--gouttiere)); }
.vue__cadre { position: relative; flex: 1; min-height: 0; border-radius: 16px; overflow: hidden; background: var(--noir-3); border: 1px solid rgba(227, 168, 43, .22); }
.vue__cadre picture, .vue__cadre img { display: block; width: 100%; height: 100%; }
.vue__cadre img { object-fit: contain; }
.vue figcaption { font-size: .92rem; line-height: 1.35; max-height: 2.7em; overflow: hidden; color: var(--doux); }
.vue figcaption strong { font-weight: 600; color: var(--or); margin-right: 8px; }
.visionneuse__bas { display: flex; align-items: center; justify-content: center; gap: 22px; padding-top: 12px; }
.visionneuse__nav { width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--bord-or); background: rgba(247, 247, 245, .05); color: var(--blanc); font-size: 1.2rem; cursor: pointer; }
.visionneuse__nav:hover { border-color: var(--or); color: var(--or); }
.visionneuse__nav:disabled { opacity: .35; cursor: default; }
.visionneuse__compteur { min-width: 7ch; text-align: center; font: 500 1rem/1 var(--police); color: var(--doux); font-variant-numeric: tabular-nums; }
.mvt .visionneuse:not(.prepare) .visionneuse__fond { animation: vis-fond .4s ease both; }
.mvt .visionneuse.ferme .visionneuse__fond { animation: vis-fond .3s ease reverse both; }
.mvt .visionneuse:not(.prepare) .visionneuse__tete, .mvt .visionneuse:not(.prepare) .visionneuse__resume, .mvt .visionneuse:not(.prepare) .visionneuse__bas { animation: vis-texte .5s .12s var(--courbe) both; }
/* fenetre remplie, mise en page et peinte avant la transition, mais transparente : photos decodees et tuiles
   pretes quand l'animation demarre (sinon la photo se dessine par carres pendant l'agrandissement) */
.visionneuse.prepare { opacity: .001; pointer-events: none; }
.visionneuse.prepare, .visionneuse.anim,
.visionneuse.anim .visionneuse__tete, .visionneuse.anim .visionneuse__resume, .visionneuse.anim .visionneuse__bas { will-change: transform, opacity; }
/* pendant l'ouverture et la fermeture : fond sombre uni a la place du flou (le flou revient une fois ouverte) */
.visionneuse.anim .visionneuse__fond { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(8, 8, 8, .94); }
@keyframes vis-fond { from { opacity: 0; } }
@keyframes vis-texte { from { opacity: 0; transform: translateY(12px); } }
.visionneuse-ouverte { overflow: hidden; }

/* curseur avant / apres */
.avap { position: relative; height: 100%; aspect-ratio: var(--ratio); max-width: 100%; margin: 0 auto; user-select: none; touch-action: pan-y; cursor: ew-resize; }
.avap picture, .avap img { position: absolute; inset: 0; width: 100%; height: 100%; }
.avap img { object-fit: cover; pointer-events: none; }
.avap__avant { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); }
.avap__ligne { position: absolute; top: 0; bottom: 0; left: var(--pos, 50%); width: 2px; margin-left: -1px; background: var(--or); box-shadow: 0 0 12px rgba(227, 168, 43, .7); pointer-events: none; }
.avap__poignee {
  position: absolute; top: 50%; left: var(--pos, 50%); width: 50px; height: 50px; margin: -25px 0 0 -25px; border-radius: 50%; pointer-events: none;
  background: var(--or); color: var(--noir); display: grid; place-items: center; font-weight: 800; box-shadow: 0 6px 20px rgba(0, 0, 0, .5);
}
.avap__etiquette { position: absolute; top: 12px; padding: 6px 10px; border-radius: 999px; background: rgba(13, 13, 13, .7); font: 600 .85rem/1 var(--police); pointer-events: none; }
.avap__etiquette--avant { left: 12px; }
.avap__etiquette--apres { right: 12px; color: var(--or); }
.avap input[type="range"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.avap:has(input:focus-visible) { outline: 3px solid var(--or); outline-offset: 3px; }

/* transitions de vue (ouverture de la carte en grand) */
::view-transition-group(photo-chantier) { animation-duration: .55s; animation-timing-function: cubic-bezier(.2, .7, .2, 1); transform-origin: 0 0; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .35s; }

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* ------------------------------------------------------------------ pages metier et FAQ : mise en page simple
   Une image, un texte a cote, puis l'inverse. Ni verre, ni carrousel, ni parallaxe, ni section epinglee.
   Une seule animation : apparition en fondu au defilement (classe .vu posee par commun.js). */
.simple-tete { padding: calc(var(--en-tete) + clamp(40px, 6vw, 76px)) 0 0; }
.simple-tete .fil { margin-bottom: 20px; }
.simple-tete__titre { font-size: clamp(2rem, 4.6vw, 3.6rem); max-width: 22ch; }
.simple-tete .chapeau { margin-top: 18px; }
.simple-une { margin-top: clamp(28px, 4vw, 48px); border-radius: 20px; overflow: hidden; border: 1px solid var(--bord-or); background: var(--noir-3); }
.simple-une img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.simple-section { position: relative; padding: clamp(56px, 8vw, 110px) 0 0; }
.simple-section--appel { padding-bottom: clamp(56px, 8vw, 110px); }
.simple-h2 { font-size: clamp(1.55rem, 2.8vw, 2.25rem); line-height: 1.08; max-width: 24ch; }
.bloc { display: grid; gap: 26px; align-items: center; }
.bloc + .bloc { margin-top: clamp(64px, 9vw, 120px); }
.bloc__image { border-radius: 20px; overflow: hidden; border: 1px solid var(--bord-or); background: var(--noir-3); }
.bloc__image img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.bloc__texte > p { color: var(--doux); margin-top: 14px; max-width: 62ch; }
.bloc__texte .simple-h2 + p { margin-top: 16px; }
.bloc__texte > .simple-h2 ~ .simple-h2 { margin-top: 36px; }
.bloc__note { padding-top: 18px; border-top: 1px solid var(--ligne); margin-top: 22px !important; font-size: .98rem; }
@media (min-width: 900px) {
  .bloc { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 5vw, 72px); }
  .bloc--inverse .bloc__image { order: 2; }
}
.puces { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.puces li { position: relative; padding-left: 22px; max-width: 62ch; }
.puces li::before { content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px; background: var(--or); }
.puces--prestations { gap: 14px; }
.puces--prestations li { color: var(--doux); }
.puces--prestations strong { display: block; color: var(--blanc); font-weight: 600; }

.simple-zone { margin-top: 18px; color: var(--doux); font-size: clamp(1.06rem, 1.5vw, 1.2rem); max-width: 68ch; }
.simple-suite { margin-top: 28px; }
.simple-appel {
  display: grid; gap: 24px; align-items: center; padding: clamp(26px, 4.5vw, 52px);
  border-radius: 20px; border: 1px solid var(--bord-or); background: var(--noir-2);
}
.simple-appel p { color: var(--doux); margin-top: 12px; max-width: 52ch; }
.simple-appel__actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (min-width: 900px) { .simple-appel { grid-template-columns: 1fr auto; } }
@media (max-width: 480px) { .simple-appel__actions .bouton { width: 100%; } }
.simple-note { margin-top: 18px; color: var(--doux); font-size: .9rem; }

/* page toiture : le chantier de faitage etape par etape (liste simple, sans defilement pilote) */
.etapes-photo { list-style: none; margin: 36px 0 0; padding: 0; display: grid; gap: 18px; }
.etape-photo { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 16px; align-items: start; }
.etape-photo__image { border-radius: 14px; overflow: hidden; border: 1px solid var(--bord-or); background: var(--noir-3); }
.etape-photo__image img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; }
.etape-photo__num { font: 600 .9rem/1.2 var(--police); color: var(--or); }
.etape-photo h3 { font-size: 1.15rem; line-height: 1.15; margin: 6px 0 6px; }
.etape-photo__texte > p:last-child { color: var(--doux); font-size: .98rem; }
@media (min-width: 900px) {
  .etapes-photo { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; }
  .etape-photo { grid-template-columns: 1fr; gap: 14px; }
}

/* FAQ : menu des themes et themes */
.themes { margin-top: 30px; }
.themes ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.themes a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--bord-or); background: rgba(247, 247, 245, .03); font: 500 .98rem/1 var(--police); transition: border-color .2s, color .2s;
}
.themes a:hover { border-color: var(--or); color: var(--or); }
.faq-theme { position: relative; padding-top: clamp(56px, 7vw, 96px); }
.ancre--decalee { position: relative; top: calc(-1 * var(--en-tete) - 18px); }

/* apparition en fondu (pages simples) */
.mvt .page-simple [data-apparition] { transition: opacity .8s var(--courbe), transform .8s var(--courbe); will-change: auto; }
.mvt .page-simple [data-apparition].vu { opacity: 1; transform: none; }
/* cartes de la grille (page toiture) : largeur de la colonne, hauteur selon le format (la regle du carrousel de l'accueil fixe une hauteur) */
.grille-chantiers .carte-chantier--grille, .mvt .grille-chantiers .carte-chantier--grille { width: auto; height: auto; max-height: none; aspect-ratio: 4 / 5; }
.grille-chantiers .carte-chantier__photo img { left: 0; width: 100%; }
