/* Kech & Frontière — page d'accueil : filtre du hero, apparitions, scène JOYA au défilement */

/* ---------- Apparitions (seulement quand le script tourne) ---------- */
.js .rev { opacity: 0; transform: translateY(34px); transition: opacity 1s cubic-bezier(.2, .7, .1, 1), transform 1s cubic-bezier(.2, .7, .1, 1); transition-delay: var(--d, 0s); }
.js .rev.est-vu { opacity: 1; transform: none; }
.mot { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .12em; margin-bottom: -.12em; }
.js .mot > span { display: inline-block; transform: translateY(115%); transition: transform .9s cubic-bezier(.2, .8, .1, 1); transition-delay: calc(var(--i, 0) * 55ms); }
.js .est-vu .mot > span, .js .est-vu.mot > span { transform: none; }

/* ---------- Hero : le filtre ---------- */
.hero-texte { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); bottom: clamp(22px, 4.5vh, 48px); }
.hero-texte h1 { font-size: clamp(2.5rem, 6vw, 5.4rem); }
.filtre {
  grid-column: 1 / -1; pointer-events: auto;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 0;
  background: var(--ivoire); color: var(--encre); border-radius: 14px; padding: 8px;
  box-shadow: 0 18px 50px rgba(20, 8, 5, .35);
}
.filtre-champ { display: grid; gap: 2px; padding: 8px 18px; border-right: 1px solid rgba(84, 46, 38, .18); min-width: 0; }
.filtre-champ:nth-of-type(3) { border-right: 0; }
.filtre-champ span { font-size: .78rem; color: var(--terre); font-weight: 500; }
.filtre-champ select {
  appearance: none; border: 0; background: transparent; padding: 2px 22px 2px 0; width: 100%;
  font-size: 1.02rem; font-weight: 400; cursor: pointer; text-overflow: ellipsis;
  background-image: linear-gradient(45deg, transparent 50%, var(--profond) 50%), linear-gradient(135deg, var(--profond) 50%, transparent 50%);
  background-position: calc(100% - 9px) 55%, calc(100% - 4px) 55%; background-size: 5px 5px; background-repeat: no-repeat;
}
.filtre-champ select:focus-visible { outline: 2px solid var(--terre); outline-offset: 4px; }
.filtre .btn { min-height: 58px; padding: 0 30px; border-radius: 10px; }
@media (max-width: 900px) {
  .hero-texte .chapo { display: none; }
  .filtre { grid-template-columns: 1fr 1fr; }
  .filtre-champ { padding: 8px 12px; }
  .filtre-champ:nth-of-type(2) { border-right: 0; }
  .filtre-champ:nth-of-type(3) { grid-column: 1 / -1; border-top: 1px solid rgba(84, 46, 38, .18); }
  .filtre .btn { grid-column: 1 / -1; margin-top: 6px; }
}

/* ---------- Notre agence : la photo dans une arche ---------- */
.agence-photo { position: relative; margin: 0; }
.arche {
  position: relative; overflow: hidden; aspect-ratio: 4 / 4.6;
  border-radius: 46% 46% 0 0 / 30% 30% 0 0; background: var(--sable);
}
.js .arche { clip-path: inset(100% 0 0 0 round 46% 46% 0 0 / 30% 30% 0 0); transition: clip-path 1.5s cubic-bezier(.2, .7, .1, 1); }
.js .est-vu .arche, .js .arche.est-vu { clip-path: inset(0 0 0 0 round 46% 46% 0 0 / 30% 30% 0 0); }
.arche img, .arche video { position: absolute; inset: -8% 0; width: 100%; height: 116%; object-fit: cover; will-change: transform; }
.agence-photo figcaption { display: flex; justify-content: space-between; gap: 12px; padding-top: 12px; margin-top: 14px; border-top: 1px solid rgba(61, 79, 58, .4); font-size: .85rem; color: var(--olive); }
.agence-photo::before {
  content: ""; position: absolute; z-index: -1; left: -22px; right: 22px; top: 26px; bottom: 44px;
  border: 1px solid rgba(61, 79, 58, .55); border-radius: 46% 46% 0 0 / 30% 30% 0 0;
}
.agence-v2 { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(36px, 7vw, 120px); align-items: center; }
.agence-v2 h2 { color: var(--profond); margin-bottom: 26px; }
.agence-v2 .agence-texte { padding-top: 0; }
@media (max-width: 820px) { .agence-v2 { grid-template-columns: 1fr; } .agence-photo { max-width: 420px; } .agence-photo::before { left: -10px; right: 10px; } }

/* ---------- La scène JOYA : la villa monte, puis reste dans les lettres ---------- */
.scene-piste { height: 420vh; }
.scene-fixe {
  position: sticky; top: 0; height: 100vh; min-height: 520px; overflow: hidden;
  background: linear-gradient(to bottom, #8f95c4 0%, #c9a3bd 34%, #f0b4a0 62%, #f8d3ad 100%);
  color: var(--profond);
}
.scene-nuage { position: absolute; border-radius: 50%; filter: blur(40px); background: rgba(255, 244, 236, .75); pointer-events: none; will-change: transform; }
.scene-nuage.n1 { width: 60vw; height: 22vh; left: -12vw; bottom: 6vh; }
.scene-nuage.n2 { width: 52vw; height: 20vh; right: -10vw; bottom: 16vh; }
.scene-nuage.n3 { width: 80vw; height: 18vh; left: 10vw; bottom: -8vh; z-index: 4; }
.scene-intro { position: absolute; z-index: 3; left: 0; right: 0; top: calc(var(--entete) + 5vh); text-align: center; padding: 0 var(--marge); display: grid; gap: 14px; justify-items: center; }
.scene-intro h2 { font-size: clamp(2.6rem, 7.4vw, 6.4rem); color: var(--ombre); }
.scene-intro p { max-width: 44ch; font-size: clamp(1rem, 1.4vw, 1.2rem); color: var(--ombre); }
.scene-villa {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center bottom; z-index: 2;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 30%); mask-image: linear-gradient(to bottom, transparent 0, #000 30%);
  will-change: transform, opacity; transform: translateY(58%) scale(1.1); transform-origin: center bottom;
}
.scene-mot, .scene-contour {
  position: absolute; inset: 0; z-index: 3; display: grid; place-items: center; margin: 0;
  font-family: var(--marque); font-weight: 400; font-size: min(30vw, 62vh); line-height: 1; letter-spacing: -.01em;
  padding-bottom: 6vh; opacity: 0; will-change: opacity, transform; pointer-events: none; user-select: none;
}
.scene-mot {
  color: transparent; -webkit-background-clip: text; background-clip: text;
  background-image: url("../assets/img/joya-facade-large.webp"); background-size: cover; background-position: center bottom;
}
.scene-contour { color: transparent; -webkit-text-stroke: 1.5px var(--ivoire); }
.scene-fin {
  position: absolute; z-index: 5; left: 0; right: 0; bottom: clamp(26px, 7vh, 70px); padding: 0 var(--marge);
  display: grid; gap: 18px; justify-items: center; text-align: center; opacity: 0; will-change: opacity, transform;
}
.scene-fin p { font-family: var(--titre); font-size: clamp(1.4rem, 2.6vw, 2.3rem); line-height: 1.15; color: var(--ombre); font-variation-settings: "SOFT" 60, "opsz" 80; }
.scene-fin .btn-contour { color: var(--ombre); }
.scene-fin .btn-contour:hover { background: rgba(46, 24, 19, .08); }

/* ---------- Le portail : une grande baie en arche ; on entre, puis on traverse la maison ---------- */
.portail-piste { height: 400vh; }
.portail-fixe {
  position: sticky; top: 0; height: 100vh; min-height: 560px; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, min(42vw, 600px)); align-items: stretch;
  gap: clamp(28px, 6vw, 110px); padding: 0 var(--marge);
}
.portail-texte { display: grid; gap: 22px; align-content: center; padding: calc(var(--entete) + 24px) 0 28px; }
.portail-compte { display: flex; align-items: baseline; gap: 10px; max-width: none; font-size: .76rem; letter-spacing: .18em; text-transform: uppercase; color: var(--olive-clair); }
.portail-compte b { font-family: var(--titre); font-weight: 340; font-size: clamp(2.6rem, 4.6vw, 4.2rem); line-height: 1; letter-spacing: 0; color: var(--ivoire); font-variant-numeric: tabular-nums; font-variation-settings: "SOFT" 60, "opsz" 144; }
.portail-compte i { font-style: normal; margin-left: 12px; padding-left: 16px; border-left: 1px solid rgba(245, 239, 230, .3); }
/* les trois étapes occupent la même case : la hauteur suit la plus haute, rien ne déborde sur les boutons */
.portail-etapes { display: grid; }
.portail-etape { grid-area: 1 / 1; opacity: 0; visibility: hidden; transform: translateY(18px); transition: opacity .6s, transform .6s, visibility 0s .6s; display: grid; gap: 14px; align-content: start; }
.portail-etape.est-active { visibility: visible; transition: opacity .6s, transform .6s, visibility 0s; }
.portail-etape .faits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.portail-etape .faits div { padding: 12px 14px 12px 0; }
.portail-etape .faits dd { font-size: clamp(1.1rem, 1.55vw, 1.4rem); white-space: nowrap; }
.portail-texte .actions { flex-wrap: nowrap; }
.portail-texte .actions .btn { white-space: nowrap; }
@media (max-height: 760px) and (min-width: 821px) {
  .portail-texte { gap: 14px; }
  .portail-texte > h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
  .portail-compte b { font-size: 2.4rem; }
  .portail-etape { gap: 10px; }
  .portail-etape h3 { font-size: clamp(1.25rem, 2vw, 1.7rem); }
  .portail-etape .faits div { padding: 8px 12px 8px 0; }
  .portail-etape .faits dd { font-size: 1.15rem; }
  .portail-etape .note { display: none; }
  .portail-texte .actions .btn { min-height: 46px; }
}
.portail-etape.est-active { opacity: 1; transform: none; }
.portail-etape h3 { font-size: clamp(1.5rem, 2.6vw, 2.3rem); }
.portail-jauge { width: min(320px, 100%); height: 2px; background: rgba(245, 239, 230, .22); }
.portail-jauge i { display: block; height: 100%; width: 0; background: var(--olive-clair); }
.portail-baie {
  position: relative; align-self: end; height: calc(100vh - var(--entete) - 26px); min-height: 440px;
  border-radius: 999px 999px 0 0; overflow: hidden; background: var(--ombre); isolation: isolate;
  box-shadow: 0 0 0 1px rgba(245, 239, 230, .16), 0 0 0 14px rgba(245, 239, 230, .04);
}
.portail-plan { position: absolute; inset: 0; overflow: hidden; will-change: clip-path, transform; transform-origin: 50% 64%; }
.portail-plan + .portail-plan { clip-path: inset(100% 50% 0 50% round 999px 999px 0 0); }
.portail-plan img, .portail-plan canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; will-change: transform; transform-origin: 50% 64%; }
.portail-baie::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to top, rgba(46, 24, 19, .5), transparent 22%); }
@media (max-width: 820px) {
  .portail-fixe { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); gap: 12px; }
  .portail-texte { gap: 10px; padding: calc(var(--entete) + 16px) 0 0; }
  .portail-compte b { font-size: 2rem; }
  .portail-texte > h2 { font-size: 2rem; }
  .portail-etape { gap: 8px; }
  .portail-etape h3 { font-size: 1.2rem; }
  .portail-etape p { font-size: .92rem; }
  .portail-etape .faits dd { font-size: 1rem; white-space: normal; }
  .portail-etape .faits div { padding: 6px 8px 6px 0; }
  .portail-etape .note { display: none; }
  .portail-texte .actions { gap: 8px; }
  .portail-texte .actions .btn { flex: 1 1 0; min-height: 44px; padding: 0 10px; font-size: .86rem; }
  .portail-baie { height: 100%; min-height: 0; width: min(74vw, 330px); justify-self: center; }
}

/* ---------- Emplacement ---------- */
.lieu { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(28px, 7vw, 120px); align-items: center; }
.lieu .porte { height: min(78vh, 720px); }
.lieu-texte { display: grid; gap: 22px; }
.lieu-texte h2 { color: var(--profond); }
.lieu-reperes { display: grid; border-top: 1px solid rgba(84, 46, 38, .25); }
.lieu-reperes li { display: grid; grid-template-columns: 9ch 1fr; gap: 18px; padding: 14px 0; border-bottom: 1px solid rgba(84, 46, 38, .25); }
.lieu-reperes span { color: var(--olive); font-weight: 500; }
@media (max-width: 820px) { .lieu { grid-template-columns: 1fr; } .lieu .porte { height: auto; width: min(100%, 320px); } }

/* ---------- Les journées à JOYA ---------- */
.journees-tete { display: flex; flex-wrap: wrap; gap: 14px 40px; align-items: end; justify-content: space-between; margin-bottom: 34px; }
.journees {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 14px;
}
.journees figure { position: relative; overflow: hidden; border-radius: 6px; background: var(--ombre); grid-column: span 4; aspect-ratio: 16 / 10; }
.journees figure.grand { grid-column: span 8; aspect-ratio: auto; grid-row: span 2; }
.journees img, .journees video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s cubic-bezier(.2, .7, .1, 1); }
.journees figure:hover img, .journees figure:hover video { transform: scale(1.05); }
.journees figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 16px 12px; color: var(--ivoire); font-size: .92rem;
  background: linear-gradient(to top, rgba(46, 24, 19, .8), transparent);
}
@media (max-width: 820px) { .journees figure, .journees figure.grand { grid-column: 1 / -1; aspect-ratio: 16 / 10; grid-row: auto; } }

/* ---------- Les journées à JOYA : galerie plein écran menée par le défilement ---------- */
.recit { background: var(--ombre); color: var(--ivoire); }
.recit-piste { height: 640vh; }
.recit-fixe { position: sticky; top: 0; height: 100vh; min-height: 520px; overflow: hidden; }
.recit-cadre { position: absolute; inset: 0; clip-path: inset(24% 31% round 10px); will-change: clip-path; }
.recit-vue { position: absolute; inset: 0; margin: 0; overflow: hidden; will-change: clip-path; }
.recit-vue + .recit-vue { clip-path: inset(100% 0 0 0); }
.recit-vue img, .recit-vue video { position: absolute; left: 0; top: -3%; width: 100%; height: 106%; object-fit: cover; will-change: transform; }
.recit-vue::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(30, 14, 10, .34) 0%, rgba(30, 14, 10, 0) 26%, rgba(30, 14, 10, 0) 58%, rgba(30, 14, 10, .62) 100%); }
.recit-vue figcaption { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.recit-intro {
  position: absolute; z-index: 3; left: 0; right: 0; top: calc(var(--entete) + 3vh); text-align: center; padding: 0 var(--marge);
  font-size: clamp(2.2rem, 5.4vw, 4.6rem); will-change: opacity, transform;
}
.recit-titre {
  position: absolute; z-index: 3; left: 0; right: 0; top: 50%; transform: translateY(-50%); margin: 0; max-width: none;
  text-align: center; padding: 0 var(--marge); pointer-events: none;
  font-family: var(--titre); font-weight: 340; font-size: clamp(2rem, 5.2vw, 4.8rem); line-height: 1.05; letter-spacing: -.015em;
  font-variation-settings: "SOFT" 60, "opsz" 144; text-shadow: 0 2px 30px rgba(20, 8, 5, .55); opacity: 0;
}
.recit-texte {
  position: absolute; z-index: 3; left: var(--marge); top: calc(var(--entete) + 22px); max-width: 30ch; margin: 0;
  font-size: .98rem; line-height: 1.5; text-shadow: 0 1px 16px rgba(20, 8, 5, .6); opacity: 0;
}
.recit-vignettes { position: absolute; z-index: 4; right: var(--marge); top: 50%; transform: translateY(-50%); display: grid; gap: 8px; opacity: 0; }
.recit-vignettes button { display: block; width: 62px; height: 42px; padding: 0; border: 1px solid rgba(245, 239, 230, .5); border-radius: 4px; overflow: hidden; background: var(--ombre); cursor: pointer; opacity: .55; transition: opacity .3s, transform .3s; }
.recit-vignettes button:hover { opacity: .9; }
.recit-vignettes button[aria-current="true"] { opacity: 1; border-color: var(--ivoire); transform: scale(1.12); }
.recit-vignettes img { width: 100%; height: 100%; object-fit: cover; }
.recit-note { position: absolute; z-index: 3; left: var(--marge); bottom: 18px; margin: 0; font-size: .8rem; opacity: .8; text-shadow: 0 1px 12px rgba(20, 8, 5, .7); }
@media (max-width: 820px) {
  .recit-cadre { clip-path: inset(30% 14% round 10px); }
  .recit-vignettes { right: auto; left: 50%; top: auto; bottom: 46px; transform: translateX(-50%); grid-auto-flow: column; }
  .recit-vignettes button { width: 44px; height: 32px; }
  .recit-texte { max-width: 24ch; font-size: .9rem; }
}

/* ---------- D'autres portes vont s'ouvrir : des portails à claustra qui s'entrouvrent ---------- */
.seuils { background: var(--ombre); color: var(--ivoire); overflow: hidden; }
.seuils-grille { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(36px, 7vw, 120px); align-items: center; }
.seuils-tete { display: grid; gap: 18px; max-width: 46ch; }
.seuils-tete .lien { color: var(--olive-clair); }
.maquette-suite { margin-top: 26px; }
.maquette-aide { margin-top: 12px; font-size: .85rem; opacity: .75; }
@media (max-width: 820px) { .seuils-grille { grid-template-columns: 1fr; } }
.seuils-rang { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(18px, 4vw, 64px); max-width: 620px; width: 100%; margin: 0 auto; }
.seuil a { display: grid; justify-items: center; text-decoration: none; text-align: center; --ouvert: inherit; }
.seuil { --ouvert: 0; }
.seuil:hover, .seuil:focus-within { --ouvert: 1 !important; }
.seuil-arche {
  position: relative; display: block; width: 100%; aspect-ratio: 3 / 4.7; overflow: hidden;
  border-radius: 999px 999px 0 0; background: #1a0c08;
  box-shadow: 0 0 0 1px rgba(245, 239, 230, .16), 0 0 calc(var(--ouvert) * 90px) rgba(255, 196, 120, calc(var(--ouvert) * .45));
  transition: box-shadow .9s;
}
.seuil-lumiere {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: radial-gradient(ellipse at 50% 72%, #fff1d6 0%, #ffd596 38%, #e9975a 78%, #b9603a 100%);
  opacity: calc(.25 + var(--ouvert) * .75); transition: opacity .9s;
}
.seuil-lumiere span {
  font-family: var(--titre); font-size: clamp(1.1rem, 2.4vw, 2rem); color: var(--profond); font-variation-settings: "SOFT" 60, "opsz" 60;
  opacity: calc(var(--ouvert) * 1.6 - .6); transform: translateY(calc((1 - var(--ouvert)) * 14px)); transition: opacity .7s, transform .9s;
}
.seuil-battant {
  position: absolute; top: 0; bottom: 0; width: 50%;
  background:
    repeating-linear-gradient(to right, rgba(20, 8, 5, .34) 0 2px, transparent 2px 13px),
    linear-gradient(to bottom, rgba(255, 255, 255, .1), rgba(0, 0, 0, .18)),
    var(--teinte);
  transition: transform 1s cubic-bezier(.2, .7, .1, 1), filter 1s;
  filter: brightness(calc(1 - var(--ouvert) * .28));
  backface-visibility: hidden;
}
.seuil-battant.gauche { left: 0; transform-origin: left center; transform: perspective(900px) rotateY(calc(var(--ouvert) * 74deg)); }
.seuil-battant.droite { right: 0; transform-origin: right center; transform: perspective(900px) rotateY(calc(var(--ouvert) * -74deg)); }
.seuil-battant.gauche::after, .seuil-battant.droite::after { content: ""; position: absolute; top: 56%; width: 7px; height: 7px; border-radius: 50%; background: var(--ivoire); opacity: .85; }
.seuil-battant.gauche::after { right: 9px; }
.seuil-battant.droite::after { left: 9px; }
.seuil-sol {
  display: block; width: 150%; height: clamp(40px, 7vw, 90px); margin-bottom: 6px;
  background: linear-gradient(to bottom, rgba(255, 205, 140, .55), rgba(255, 205, 140, 0));
  clip-path: polygon(22% 0, 78% 0, 100% 100%, 0 100%);
  opacity: var(--ouvert); transition: opacity .9s; filter: blur(6px);
}
.seuil-nom { font-family: var(--titre); font-size: clamp(1.15rem, 2.2vw, 1.9rem); line-height: 1.15; font-variation-settings: "SOFT" 60, "opsz" 60; }
.seuil-etat { font-size: .9rem; color: var(--olive-clair); margin-top: 4px; }
.seuil a:focus-visible { outline-offset: 8px; }
@media (max-width: 620px) { .seuils-rang { gap: 12px; } .seuil-nom { font-size: 1rem; } .seuil-etat { font-size: .78rem; } }

/* ---------- Vendre ---------- */
.vendre { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(36px, 7vw, 120px); align-items: center; }
.vendre-texte { display: grid; gap: 24px; justify-items: start; }
.vendre-etapes { counter-reset: etape; display: grid; width: 100%; border-top: 1px solid rgba(245, 239, 230, .3); }
.vendre-etapes li { counter-increment: etape; display: grid; grid-template-columns: 3ch 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid rgba(245, 239, 230, .3); }
.vendre-etapes li::before { content: counter(etape); font-family: var(--titre); font-size: 1.5rem; line-height: 1.1; opacity: .8; }
.vendre-etapes b { font-weight: 500; display: block; }
.vendre .arche { aspect-ratio: 4 / 4.4; }
@media (max-width: 820px) { .vendre { grid-template-columns: 1fr; } .vendre figure { max-width: 420px; } }

/* ---------- Page JOYA : l'ouverture ---------- */
.joya-hero { position: relative; height: 100svh; min-height: 640px; overflow: hidden; background: var(--ombre); color: var(--ivoire); }
.joya-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 62%; animation: recul 2.6s cubic-bezier(.2, .7, .1, 1) both; }
@keyframes recul { from { transform: scale(1.14); } to { transform: scale(1); } }
.joya-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(46, 24, 19, .95) 0%, rgba(46, 24, 19, .6) 30%, rgba(46, 24, 19, 0) 62%), linear-gradient(to bottom, rgba(46, 24, 19, .55) 0%, rgba(46, 24, 19, 0) 20%);
}
.joya-hero-texte { position: absolute; z-index: 2; left: var(--marge); right: var(--marge); bottom: clamp(24px, 5vh, 54px); display: grid; gap: 20px; }
.joya-hero-haut { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 90px); align-items: end; }
.joya-hero-haut .vedette-nom { font-size: clamp(5rem, 14vw, 13rem); }
.joya-hero .faits dd { font-size: clamp(1.15rem, 1.9vw, 1.7rem); }
.joya-hero-suite { display: grid; gap: 20px; justify-items: start; padding-bottom: 1.2vw; }
.joya-hero .faits { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 820px) {
  .joya-hero-haut { grid-template-columns: 1fr; gap: 14px; }
  .joya-hero .faits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .joya-hero .faits div { padding: 10px 10px 10px 0; }
  .joya-hero-suite .chapo { font-size: 1rem; }
}

/* ---------- Page JOYA : la maison ---------- */
.maison { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .8fr); gap: clamp(36px, 7vw, 120px); align-items: center; }
.maison h2 { color: var(--profond); margin-bottom: 26px; }
.maison .arche { aspect-ratio: 9 / 13; }
.chiffres { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin-top: clamp(48px, 7vw, 96px); border-top: 1px solid rgba(84, 46, 38, .25); }
.chiffres div { padding: 26px 18px 0 0; }
.chiffres b { display: block; font-family: var(--titre); font-weight: 340; font-size: clamp(3rem, 6.4vw, 6rem); line-height: 1; color: var(--terre); font-variation-settings: "SOFT" 60, "opsz" 144; font-variant-numeric: tabular-nums; }
.chiffres span { display: block; margin-top: 8px; max-width: 22ch; }
@media (max-width: 820px) { .maison { grid-template-columns: 1fr; } .maison figure { max-width: 320px; } .chiffres { grid-template-columns: 1fr 1fr; } .chiffres div { padding-bottom: 18px; } }

/* ---------- Page JOYA : le calendrier et le formulaire du projet ---------- */
.joya-hero-suite .surtitre { color: var(--olive-clair); }
.calendrier { margin-top: clamp(56px, 8vw, 110px); display: grid; gap: 28px; }
.calendrier-tete { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(20px, 6vw, 100px); align-items: end; }
.calendrier-tete h2 { color: var(--profond); }
.calendrier-etapes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 2px solid var(--olive); }
.calendrier-etapes li { position: relative; display: grid; gap: 6px; padding: 26px 22px 0 0; }
.calendrier-etapes li::before { content: ""; position: absolute; left: 0; top: -8px; width: 14px; height: 14px; border-radius: 50%; background: var(--ivoire); border: 2px solid var(--olive); }
.calendrier-etapes li:first-child::before { background: var(--olive); }
.calendrier-etapes span { font-size: .76rem; text-transform: uppercase; letter-spacing: .18em; color: var(--olive); }
.calendrier-etapes b { font-family: var(--titre); font-weight: 340; font-size: clamp(1.5rem, 2.6vw, 2.3rem); line-height: 1.1; color: var(--profond); font-variation-settings: "SOFT" 60, "opsz" 80; }
.interet { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 100px); align-items: center; }
.interet-texte { display: grid; gap: 22px; }
.interet .carte-formulaire, .interet .merci { color: var(--encre); }
@media (max-width: 820px) {
  .calendrier-tete, .interet { grid-template-columns: 1fr; }
  .calendrier-etapes { grid-template-columns: 1fr; border-top: 0; border-left: 2px solid var(--olive); }
  .calendrier-etapes li { padding: 0 0 26px 24px; }
  .calendrier-etapes li::before { left: -8px; top: 2px; }
}

/* ---------- Page JOYA : la galerie qui défile de côté ---------- */
.defile-fixe { padding: clamp(60px, 9vw, 120px) 0; }
.defile-tete { display: flex; flex-wrap: wrap; gap: 14px 40px; align-items: end; justify-content: space-between; padding: 0 var(--marge); margin-bottom: 30px; }
.defile-rail { display: flex; gap: 16px; padding: 0 var(--marge) 16px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--pierre, #c9b7a2) transparent; }
.defile-rail figure { flex: 0 0 min(72vw, 330px); scroll-snap-align: start; display: grid; gap: 10px; align-content: start; }
.defile-rail img { width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 4px; background: var(--ombre); }
.defile-rail figcaption { font-size: .9rem; }
.defile.est-epingle .defile-fixe {
  position: sticky; top: 0; height: 100vh; min-height: 560px; overflow: hidden;
  padding: calc(var(--entete) + 22px) 0 22px; display: grid; grid-template-rows: auto minmax(0, 1fr);
}
.defile.est-epingle .defile-rail { overflow: visible; scroll-snap-type: none; padding-bottom: 0; will-change: transform; height: 100%; }
.defile.est-epingle .defile-rail figure { flex: 0 0 auto; height: 100%; grid-template-rows: minmax(0, 1fr) auto; }
.defile.est-epingle .defile-rail img { height: 100%; width: auto; }
.defile-jauge { height: 2px; margin: 0 var(--marge); background: rgba(245, 239, 230, .22); display: none; }
.defile.est-epingle .defile-jauge { display: block; position: absolute; left: 0; right: 0; bottom: 12px; }
.defile-jauge i { display: block; height: 100%; width: 0; background: var(--ivoire); }

/* ---------- Mobile : « JOYA en images » en cartes compactes qui glissent, et images plus légères ---------- */
@media (max-width: 820px) {
  .defile-fixe { padding: 56px 0 44px; }
  .defile-tete { margin-bottom: 20px; }
  .defile-rail { gap: 12px; padding: 0 var(--marge) 6px; scroll-padding-left: var(--marge); scrollbar-width: none; counter-reset: vue; align-items: flex-start; }
  .defile-rail::-webkit-scrollbar { display: none; }
  .defile-rail figure { position: relative; flex: 0 0 58vw; max-width: 270px; display: block; border-radius: 16px; overflow: hidden; counter-increment: vue; box-shadow: 0 14px 34px rgba(20, 8, 5, .3); }
  .defile-rail figure:nth-child(even) { margin-top: 22px; }
  .defile-rail figure::after { content: ""; flex: none; }
  .defile-rail img { aspect-ratio: 4 / 5; border-radius: 0; }
  .defile-rail figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 14px 12px; font-size: .86rem; line-height: 1.3; background: linear-gradient(to top, rgba(30, 14, 10, .88), rgba(30, 14, 10, 0)); }
  .defile-rail figcaption::before { content: counter(vue, decimal-leading-zero) " / 09"; display: block; margin-bottom: 3px; font-size: .68rem; letter-spacing: .18em; color: var(--olive-clair); }
  .defile-tete::after { content: "Glissez →"; font-size: .76rem; letter-spacing: .16em; text-transform: uppercase; color: var(--olive-clair); }
  .scene-mot { background-image: url("../assets/img/joya-facade-large-900.webp"); }
}

/* ---------- Mouvement réduit : tout est visible, rien n'est épinglé ---------- */
@media (prefers-reduced-motion: reduce) {
  .js .rev, .js .mot > span { opacity: 1; transform: none; }
  .js .arche { clip-path: none; }
  .joya-hero > img { animation: none; }
  .seuil { --ouvert: .45; }
  .seuil-battant, .seuil-lumiere, .seuil-lumiere span, .seuil-arche, .seuil-sol { transition: none; }
  .recit-piste { height: auto; }
  .recit-fixe { position: relative; height: auto; min-height: 0; padding: calc(var(--entete) + 20px) var(--marge) 60px; }
  .recit-intro { position: relative; top: 0; margin-bottom: 30px; }
  .recit-cadre { position: relative; clip-path: none; display: grid; gap: 14px; }
  .recit-vue, .recit-vue + .recit-vue { position: relative; clip-path: none; aspect-ratio: 16 / 9; border-radius: 6px; }
  .recit-vue img, .recit-vue video { top: 0; height: 100%; }
  .recit-vue::after { background: linear-gradient(to top, rgba(30, 14, 10, .7), transparent 45%); }
  .recit-vue figcaption { width: auto; height: auto; clip-path: none; left: 16px; bottom: 12px; z-index: 2; }
  .recit-titre, .recit-texte, .recit-vignettes { display: none; }
  .recit-note { position: relative; left: 0; bottom: 0; margin-top: 16px; }
  .scene-piste, .portail-piste { height: auto; }
  .scene-fixe, .portail-fixe { position: relative; }
  .scene-villa { transform: none; }
  .scene-fin { opacity: 1; }
  .scene-intro { position: relative; z-index: 5; }
  .portail-etapes { gap: 22px; }
  .portail-etape { grid-area: auto; opacity: 1; visibility: visible; transform: none; }
  #portail-toile, .portail-jauge, .portail-compte { display: none; }
  .portail-baie { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; height: auto; border-radius: 0; }
  .portail-plan, .portail-plan + .portail-plan { position: relative; clip-path: none; aspect-ratio: 9 / 16; border-radius: 999px 999px 0 0; }
}
