/* LE GRENIER D'EN HAUT — direction engageante.
   Un papier crème, une encre chaude, le rouge du papier découpé du
   Pays-d'Enhaut, et le vert-noir des sapins pour la nuit. Fraunces (douce,
   SOFT 50) pour ce qui se raconte, Figtree pour ce qui informe.
   Le découpage de Hauswirth est un MASQUE (outils/decoupage.mjs) : sa
   couleur se règle ici, jamais dans le fichier.
   Les effets au défilement sont des animations CSS liées au défilement :
   là où le navigateur ne les connaît pas, la page reste immobile, et
   rien ne manque. */

@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces.woff2') format('woff2'); font-weight: 350 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces-italique.woff2') format('woff2'); font-weight: 350 500; font-style: italic; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree.woff2') format('woff2'); font-weight: 300 700; font-style: normal; font-display: swap; }

:root {
  --papier: #f4ede1;
  --papier-2: #ebe1cf;
  --papier-3: #e0d3bd;
  --encre: #2a211b;
  --encre-2: #5b4c40;
  --filet: #d6c8b1;
  --rouge: #8f2a22;
  --rouge-fonce: #6e1f19;
  --rouge-pale: #ecd3c9;
  --nuit: #1e2a24;
  --nuit-2: #273730;
  --nuit-filet: #3c4f45;
  --nuit-texte: #c9c1b0;

  --serif: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --sans: 'Figtree', 'Helvetica Neue', Arial, sans-serif;

  --marge: clamp(1rem, 4vw, 3.5rem);
  --large: 84rem;
  --section: clamp(5rem, 4rem + 6vw, 10rem);

  --t-petit: .8125rem;
  --t-corps: clamp(1rem, .96rem + .2vw, 1.125rem);
  --t-chapo: clamp(1.2rem, 1.02rem + .7vw, 1.6rem);
  --t-h3: clamp(1.35rem, 1.15rem + .7vw, 1.75rem);
  --t-h2: clamp(2.25rem, 1.35rem + 3.6vw, 4.5rem);
  --t-h1: clamp(3.4rem, 1.6rem + 7.4vw, 9rem);

  --entete-h: 4.25rem;
  --doux: cubic-bezier(.2, .7, .2, 1);
  /* La rangée de l'alpage : 2404 × 404 px. Sa hauteur suit la largeur
     jusqu'au plancher mobile, où elle déborde et se centre sur le chalet. */
  --alpage-ratio: 5.95;
  --alpage-h: max(6.5rem, calc(100vw / var(--alpage-ratio)));
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--entete-h) + 1rem); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font: 400 var(--t-corps)/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
/* Le grain du papier : un bruit très léger, peint une fois, jamais animé. */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: .06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .6 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* Un composant qui pose son display ne doit pas réafficher ce qu'on cache. */
[hidden] { display: none !important; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .22em; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 400; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
em, i { font-style: italic; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--rouge); outline-offset: 3px; }
::selection { background: var(--rouge); color: var(--papier); }

.cadre { width: 100%; max-width: var(--large); margin-inline: auto; padding-inline: var(--marge); }
.visuellement-cache { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.evitement { position: fixed; top: .5rem; left: .5rem; z-index: 200; padding: .75rem 1rem; background: var(--encre); color: var(--papier); transform: translateY(-200%); }
.evitement:focus { transform: none; }

.surtitre {
  margin-bottom: 1.25rem;
  font: 600 var(--t-petit)/1.3 var(--sans);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--rouge);
}
h2 { font-size: var(--t-h2); line-height: 1.02; letter-spacing: -.015em; }
h2 em { color: var(--rouge); }
.chapo { font: 400 var(--t-chapo)/1.42 var(--serif); }

/* ---------- Boutons ---------- */
.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6em;
  min-height: 3rem;
  padding: .8rem 1.5rem;
  border: 0;
  border-radius: 999px;
  background: var(--rouge);
  color: var(--papier);
  font: 600 1rem/1.1 var(--sans);
  text-decoration: none;
  cursor: pointer;
  transition: background-color .25s var(--doux), transform .25s var(--doux);
}
.bouton:hover { background: var(--rouge-fonce); }
.bouton:active { transform: translateY(1px); }
.bouton:disabled { background: var(--papier-3); color: var(--encre-2); cursor: not-allowed; }
.bouton-petit { min-height: 2.5rem; padding: .55rem 1.15rem; font-size: .9375rem; }
.bouton-large { width: 100%; }
.lien-fleche {
  display: inline-flex;
  align-items: center;
  gap: .55em;
  padding: 0;
  border: 0;
  background: none;
  font: 600 1rem/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
}
.lien-fleche::after { content: '→'; transition: transform .25s var(--doux); }
.lien-fleche:hover::after { transform: translateX(.25em); }

/* ---------- Le cœur de Hauswirth : un masque, une couleur ---------- */
.coeur {
  display: inline-block;
  width: 1.75rem;
  aspect-ratio: 455 / 432;
  background: var(--rouge);
  -webkit-mask: url('../img/coeur.svg') center / contain no-repeat;
  mask: url('../img/coeur.svg') center / contain no-repeat;
}

/* ---------- Bandeau « maquette » ---------- */
.maquette {
  position: relative;
  z-index: 60;
  display: flex;
  flex-wrap: wrap;
  gap: .25rem 1.5rem;
  justify-content: space-between;
  align-items: center;
  padding: .55rem var(--marge);
  background: var(--encre);
  color: var(--papier);
  font: 400 var(--t-petit)/1.4 var(--sans);
}
.maquette span { font-weight: 600; }
.maquette a { white-space: nowrap; }

/* ---------- En-tête ----------
   Collant, et posé PAR-DESSUS le héros par une marge négative : il suit le
   bandeau au chargement, puis reste en haut. Sans script, il est plein ;
   avec, il est transparent tant qu'il survole la photo (site.js). */
.entete {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 2rem;
  height: var(--entete-h);
  margin-bottom: calc(-1 * var(--entete-h));
  padding-inline: var(--marge);
  background: var(--papier);
  color: var(--encre);
  box-shadow: 0 1px 0 var(--filet);
  transition: background-color .4s var(--doux), color .4s var(--doux), box-shadow .4s var(--doux);
}
@media (scripting: enabled) {
  .entete:not([data-etat='plein']) { background: linear-gradient(to bottom, rgb(16 14 12 / .42), rgb(16 14 12 / 0)); color: var(--papier); box-shadow: none; }
  .entete:not([data-etat='plein']) .coeur { background: var(--papier); }
}
.marque { display: inline-flex; align-items: center; gap: .65rem; margin-right: auto; text-decoration: none; }
.marque .coeur { width: 1.9rem; transition: background-color .4s var(--doux); }
.marque-nom { font: 450 1.3rem/1 var(--serif); letter-spacing: -.01em; white-space: nowrap; }
.entete-nav { display: flex; gap: 1.75rem; }
.entete-nav a { font: 500 .9375rem/1 var(--sans); text-decoration: none; }
.entete-nav a:hover { text-decoration: underline; }
.entete-menu { display: none; }
@media (max-width: 60rem) {
  .entete { gap: .75rem; }
  .entete-nav { display: none; }
  .entete-menu {
    display: grid;
    gap: 5px;
    place-content: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
  }
  .entete-menu span { display: block; width: 1.35rem; height: 2px; background: currentColor; }
}
@media (max-width: 26rem) {
  .marque-nom { font-size: 1.1rem; }
  .entete .bouton-petit { padding-inline: .9rem; }
}

/* Le menu mobile est un popover natif : il s'ouvre et se ferme sans script. */
.menu {
  inset: 0 0 auto;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: calc(var(--entete-h) + 1rem) var(--marge) 2rem;
  border: 0;
  background: var(--papier);
  color: var(--encre);
  box-shadow: 0 1rem 2rem rgb(42 33 27 / .18);
}
.menu:popover-open { display: grid; gap: .25rem; }
.menu a:not(.bouton) { padding: .7rem 0; border-bottom: 1px solid var(--filet); font: 400 1.75rem/1.2 var(--serif); text-decoration: none; }
.menu .bouton { margin-top: 1.5rem; }
.menu-fermer {
  position: absolute;
  top: calc((var(--entete-h) - 2.75rem) / 2);
  right: var(--marge);
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.menu-fermer::before, .menu-fermer::after { content: ''; position: absolute; top: 50%; left: 50%; width: 1.35rem; height: 2px; background: var(--encre); translate: -50% -50%; rotate: 45deg; }
.menu-fermer::after { rotate: -45deg; }
.menu::backdrop { background: rgb(30 42 36 / .35); }

/* ---------- Héros ---------- */
.heros {
  position: relative;
  display: grid;
  align-content: end;
  min-height: max(38rem, 100svh);
  padding-bottom: calc(var(--alpage-h) * .9 + 2.5rem);
  overflow: clip;
  color: var(--papier);
  background: var(--nuit);
}
.heros-image { position: absolute; inset: 0; }
.heros-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 50%;
}
.heros-voile {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgb(16 14 12 / .55) 0, rgb(16 14 12 / .2) 45%, transparent 70%),
    linear-gradient(to right, rgb(16 14 12 / .45), transparent 60%),
    linear-gradient(to bottom, rgb(16 14 12 / .35), transparent 22%);
}
.heros-texte {
  position: relative;
  max-width: 50rem;
  padding: calc(var(--entete-h) + 3rem) var(--marge) 0;
}
.heros .surtitre { color: var(--papier); opacity: .9; }
.heros h1 { font-size: var(--t-h1); line-height: .9; letter-spacing: -.025em; font-weight: 400; }
.heros h1 em { display: block; padding-left: .5em; }
.heros-chapo { max-width: 34rem; margin-top: 1.75rem; font: 400 var(--t-chapo)/1.4 var(--serif); }
.heros-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; margin-top: 2rem; }
.heros-prix {
  position: absolute;
  right: var(--marge);
  bottom: calc(var(--alpage-h) * .9 + 2.5rem);
  display: grid;
  gap: .2rem;
  padding: 1rem 1.25rem;
  border: 1px solid rgb(244 237 225 / .35);
  border-radius: .75rem;
  background: rgb(22 18 15 / .35);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font: 400 var(--t-petit)/1.35 var(--sans);
  text-align: right;
}
.heros-prix span:first-child { font: 400 1.35rem/1.2 var(--serif); }
.heros-prix b { font-weight: 600; }
/* Sur un écran étroit, le prix d'appel rentre dans le flux, sous les
   boutons : c'est l'argument de la maquette, il ne disparaît pas. */
@media (max-width: 60rem) {
  .heros-prix {
    position: relative;
    inset: auto;
    margin: 1.75rem var(--marge) 0;
    padding: .9rem 0 0;
    border: 0;
    border-top: 1px solid rgb(244 237 225 / .35);
    border-radius: 0;
    background: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    text-align: left;
  }
  .heros-prix span:first-child { font-size: 1.15rem; }
}

/* La rangée de l'alpage coupe le bas de la photo : le papier de la page,
   découpé. Ses vides laissent voir la photo derrière. */
.decoupe-alpage {
  position: absolute;
  inset: auto 0 -1px;
  height: var(--alpage-h);
  background: var(--papier);
  -webkit-mask: url('../img/decoupe-alpage.svg') center bottom / cover no-repeat;
  mask: url('../img/decoupe-alpage.svg') center bottom / cover no-repeat;
}

@media (prefers-reduced-motion: no-preference) {
  .heros-image img { animation: heros-recul 9s var(--doux) both; }
  .heros-texte > * { animation: monter 1s var(--doux) both; }
  .heros-texte > :nth-child(2) { animation-delay: .1s; }
  .heros-texte > :nth-child(3) { animation-delay: .2s; }
  .heros-texte > :nth-child(4) { animation-delay: .3s; }
}
@keyframes heros-recul { from { transform: scale(1.08); } to { transform: none; } }
/* Le papier se déplie depuis le pli : un découpage se taille plié en deux. */
@keyframes deplier { from { clip-path: inset(0 50% 0 50%); } to { clip-path: inset(0); } }
@media (prefers-reduced-motion: no-preference) {
  .decoupe-alpage { animation: deplier 1.4s var(--doux) .25s both; }
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .decoupe-pied {
      animation: deplier linear both;
      animation-timeline: view();
      animation-range: entry 10% entry 90%;
    }
  }
}
@keyframes monter { from { opacity: 0; transform: translateY(1.5rem); } to { opacity: 1; transform: none; } }

/* ---------- Le grenier ---------- */
.grenier {
  display: grid;
  gap: 3rem;
  padding-block: calc(var(--section) * .8) var(--section);
}
.grenier-texte { display: grid; gap: 1.5rem; align-content: start; }
.grenier-texte .surtitre { margin-bottom: 0; }
.grenier-texte > p:last-child { max-width: 36rem; color: var(--encre-2); }
.fiche { margin: 0; align-self: start; border-top: 2px solid var(--encre); }
.fiche div { display: grid; grid-template-columns: 9rem 1fr; gap: 1rem; padding: .95rem 0; border-bottom: 1px solid var(--filet); }
.fiche dt { font: 600 var(--t-petit)/1.5 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--encre-2); }
.fiche dd { margin: 0; }
@media (min-width: 64rem) {
  .grenier { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 6rem; }
  .fiche { margin-top: 3.25rem; }
}

/* ---------- À l'intérieur ---------- */
.interieur { padding-bottom: var(--section); }
.interieur-tete { display: grid; gap: 1.5rem; margin-bottom: 3rem; }
.interieur-tete .surtitre { margin-bottom: 0; }
.interieur-tete .chapo { max-width: 40rem; color: var(--encre-2); }

.galerie {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 2.5rem 1.5rem;
  margin-block: 0;
  list-style: none;
}
.galerie li { grid-column: 1 / -1; }
.galerie figure { margin: 0; }
.galerie-ouvrir {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: var(--papier-2);
  cursor: zoom-in;
}
.galerie img {
  width: 100%;
  height: var(--h, 64vw);
  object-fit: cover;
  transition: transform .9s var(--doux);
}
.galerie-ouvrir:hover img { transform: scale(1.035); }
.galerie figcaption { max-width: 34rem; margin-top: .85rem; color: var(--encre-2); font-size: .9688rem; }
.galerie figcaption b { color: var(--encre); font: 500 1.0625rem/1 var(--serif); }
@media (min-width: 44rem) {
  .g-sejour { --h: clamp(20rem, 38vw, 36rem); }
  .g-chambre { --h: clamp(20rem, 38vw, 36rem); }
  .g-mezzanine, .g-cuisine, .g-matin { --h: clamp(16rem, 26vw, 24rem); }
  .g-bain { --h: clamp(20rem, 44vw, 42rem); }
  .galerie .g-sejour { grid-column: 1 / span 7; }
  .galerie .g-chambre { grid-column: 8 / span 5; }
  .galerie .g-mezzanine { grid-column: 1 / span 4; }
  .galerie .g-cuisine { grid-column: 5 / span 4; }
  .galerie .g-matin { grid-column: 9 / span 4; }
  .galerie .g-bain { grid-column: 1 / -1; }
}
@media (min-width: 44rem) and (max-width: 63.99rem) {
  .galerie .g-mezzanine { grid-column: 1 / span 6; }
  .galerie .g-cuisine { grid-column: 7 / span 6; }
  .galerie .g-matin { grid-column: 1 / -1; }
}

/* La photo se déroule comme une feuille qu'on tire vers le bas. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .galerie-ouvrir {
      animation: derouler linear both;
      animation-timeline: view();
      animation-range: entry 5% entry 75%;
    }
  }
}
@keyframes derouler { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }

.equipements {
  display: grid;
  gap: 1.5rem;
  margin-top: calc(var(--section) * .7);
}
.equipements h3 { font-size: var(--t-h3); }
.equipements ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  gap: 0 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 2px solid var(--encre);
}
.equipements li { display: flex; gap: .85rem; align-items: baseline; padding: 1rem 0; border-bottom: 1px solid var(--filet); }
.equipements li::before {
  content: '';
  flex: none;
  width: .85rem;
  aspect-ratio: 455 / 432;
  translate: 0 .1em;
  background: var(--rouge);
  -webkit-mask: url('../img/coeur.svg') center / contain no-repeat;
  mask: url('../img/coeur.svg') center / contain no-repeat;
}
@media (min-width: 64rem) {
  .equipements { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 3rem; }
  .equipements h3 { padding-top: 1rem; }
}

/* ---------- Visionneuse ---------- */
html:has(.visionneuse[open]) { overflow: hidden; }
.visionneuse {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: clamp(1rem, 4vw, 3rem);
  border: 0;
  background: rgb(18 16 14 / .96);
  color: var(--papier);
}
.visionneuse[open] { display: grid; place-items: center; }
.visionneuse::backdrop { background: transparent; }
.visionneuse figure { display: grid; gap: 1rem; justify-items: center; max-width: 100%; max-height: 100%; margin: 0; }
.visionneuse img { max-width: min(100%, 96rem); max-height: calc(100dvh - 9rem); width: auto; height: auto; object-fit: contain; }
.visionneuse figcaption { max-width: 44rem; text-align: center; color: var(--nuit-texte); font-size: .9688rem; }
.visionneuse figcaption b { color: var(--papier); font: 500 1.0625rem/1 var(--serif); }
.visionneuse button {
  position: absolute;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  padding: 0;
  border: 1px solid rgb(244 237 225 / .35);
  border-radius: 50%;
  background: rgb(18 16 14 / .5);
  cursor: pointer;
}
.visionneuse button:hover { background: rgb(244 237 225 / .15); }
.visionneuse button::before { content: ''; width: .7rem; height: .7rem; border: solid var(--papier); border-width: 2px 2px 0 0; }
.visionneuse-prec { left: 1rem; top: 50%; translate: 0 -50%; }
.visionneuse-prec::before { rotate: -135deg; translate: .15rem 0; }
.visionneuse-suiv { right: 1rem; top: 50%; translate: 0 -50%; }
.visionneuse-suiv::before { rotate: 45deg; translate: -.15rem 0; }
.visionneuse-fermer { top: 1rem; right: 1rem; }
.visionneuse-fermer::before { width: 1.1rem !important; height: 2px !important; border: 0 !important; background: var(--papier); rotate: 45deg; box-shadow: none; }
.visionneuse-fermer::after { content: ''; position: absolute; width: 1.1rem; height: 2px; background: var(--papier); rotate: -45deg; }
@media (max-width: 44rem) {
  .visionneuse-prec, .visionneuse-suiv { top: auto; bottom: 1rem; translate: none; }
}
::view-transition-group(photo) { animation-duration: .45s; animation-timing-function: var(--doux); }

/* ---------- Le pays ---------- */
.pays { padding-block: var(--section); background: var(--papier-2); }
.pays-tete { display: grid; gap: 1.5rem; }
.pays-tete .surtitre { margin-bottom: 0; }
.pays-tete .chapo { max-width: 44rem; color: var(--encre-2); }

/* La procession avance vers la droite quand on descend : elle est plus
   large que l'écran, et le défilement la fait traverser. */
.poya { margin: clamp(2.5rem, 5vw, 4.5rem) 0 clamp(2.5rem, 5vw, 4rem); overflow: clip; }
.decoupe-poya {
  --poya-l: max(135vw, 72rem);
  width: var(--poya-l);
  aspect-ratio: 2115 / 209;
  background: var(--rouge);
  translate: calc((100vw - var(--poya-l)) / 2) 0;
  -webkit-mask: url('../img/decoupe-poya.svg') center / 100% 100% no-repeat;
  mask: url('../img/decoupe-poya.svg') center / 100% 100% no-repeat;
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .decoupe-poya {
      animation: poya linear both;
      animation-timeline: view();
      animation-range: cover 0% cover 100%;
    }
  }
}
@keyframes poya {
  from { translate: calc(100vw - var(--poya-l)) 0; }
  to { translate: 0 0; }
}
.poya figcaption { margin-top: .9rem; color: var(--encre-2); font-size: var(--t-petit); }

.saisons {
  display: grid;
  gap: 2.5rem 1.5rem;
  margin-block: 0;
  list-style: none;
}
.saisons img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; margin-bottom: 1.15rem; }
.saison-mois { font: 600 var(--t-petit)/1.3 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--rouge); }
.saisons h3 { margin: .45rem 0 .6rem; font-size: var(--t-h3); line-height: 1.15; }
.saisons p:last-child { color: var(--encre-2); }
@media (max-width: 43.99rem) {
  .saisons {
    grid-auto-flow: column;
    grid-auto-columns: 78%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--marge);
    scrollbar-width: none;
  }
  .saisons li { scroll-snap-align: start; }
}
@media (min-width: 44rem) { .saisons { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64rem) { .saisons { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) and (min-width: 44rem) {
    .saisons li {
      animation: monter linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 55%;
    }
    .saisons li:nth-child(2) { animation-range: entry 6% entry 61%; }
    .saisons li:nth-child(3) { animation-range: entry 12% entry 67%; }
    .saisons li:nth-child(4) { animation-range: entry 18% entry 73%; }
  }
}

.pays-apartes {
  display: grid;
  gap: 1.5rem;
  margin-top: calc(var(--section) * .6);
}
.aparte {
  display: grid;
  gap: 1.5rem;
  align-items: center;
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--papier);
  box-shadow: 0 1px 0 var(--filet), 0 1.5rem 3rem -2rem rgb(42 33 27 / .35);
}
.aparte h3 { margin-bottom: .6rem; font-size: var(--t-h3); }
.aparte p { color: var(--encre-2); }
.aparte img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.coeur-grand { width: clamp(6rem, 12vw, 9rem); justify-self: center; }
@media (min-width: 44rem) {
  .aparte { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }
}
@media (min-width: 64rem) {
  .pays-apartes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Réservation ---------- */
.reserver {
  padding-block: var(--section);
  background: var(--nuit);
  color: var(--papier);
}
.reserver .surtitre { color: #e6a596; }
.reserver h2 em { color: inherit; }
.reserver-tete { display: grid; gap: 1.5rem; margin-bottom: 3rem; }
.reserver-tete .surtitre { margin-bottom: 0; }
.reserver-tete .chapo { max-width: 42rem; color: var(--nuit-texte); }

.carte-resa {
  display: grid;
  overflow: hidden;
  border-radius: 1.25rem;
  background: var(--papier);
  color: var(--encre);
  box-shadow: 0 2rem 4rem -2rem rgb(0 0 0 / .6);
}
@media (min-width: 64rem) {
  .carte-resa { grid-template-columns: minmax(0, 1fr) 22rem; }
}

.calendrier { padding: clamp(1rem, 3vw, 2.25rem); }
.calendrier-barre { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.calendrier-nav {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  flex: none;
  padding: 0;
  border: 1px solid var(--filet);
  border-radius: 50%;
  background: var(--papier);
  cursor: pointer;
}
.calendrier-nav:hover:not(:disabled) { border-color: var(--encre); }
.calendrier-nav:disabled { opacity: .35; cursor: default; }
.calendrier-nav::before { content: ''; width: .55rem; height: .55rem; border: solid currentColor; border-width: 2px 2px 0 0; rotate: -135deg; translate: .12rem 0; }
.calendrier-nav-suiv::before { rotate: 45deg; translate: -.12rem 0; }
.calendrier-legende { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .35rem 1rem; font-size: var(--t-petit); color: var(--encre-2); }
.calendrier-legende span { white-space: nowrap; }
.pastille { display: inline-block; width: .8rem; height: .8rem; margin-right: .35rem; border-radius: 3px; vertical-align: -.05rem; }
.pastille-libre { border: 1px solid var(--filet); background: var(--papier); }
.pastille-pris { background: repeating-linear-gradient(-45deg, var(--papier-3) 0 2px, var(--papier-2) 2px 5px); }
.pastille-choix { background: var(--rouge); }

.calendrier-mois { display: grid; gap: 2rem; }
@media (min-width: 44rem) { .calendrier-mois { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.mois-titre { margin-bottom: .85rem; font: 450 1.35rem/1.2 var(--serif); text-align: center; }
.mois-titre::first-letter { text-transform: uppercase; }
.mois table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.mois th { padding-bottom: .5rem; font: 600 .75rem/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--encre-2); }
.mois td { padding: 2px 0; }
.jour {
  position: relative;
  display: grid;
  place-content: center;
  width: 100%;
  aspect-ratio: 1 / 1.02;
  padding: 0;
  border: 0;
  border-radius: .5rem;
  background: none;
  font: 500 .9688rem/1 var(--sans);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.jour small { display: block; margin-top: .3rem; font: 500 .6875rem/1 var(--sans); color: var(--encre-2); }
.jour:hover:not([aria-disabled='true']):not(.est-choisi) { box-shadow: inset 0 0 0 1.5px var(--encre); }
.jour[aria-disabled='true'] { cursor: default; color: rgb(42 33 27 / .38); }
.jour[aria-disabled='true'] small { visibility: hidden; }
.jour[data-etat='pris'] {
  color: rgb(42 33 27 / .45);
  text-decoration: line-through;
  text-decoration-color: rgb(42 33 27 / .35);
  background: repeating-linear-gradient(-45deg, var(--papier-3) 0 2px, var(--papier-2) 2px 6px);
}
.jour[data-etat='pris'][aria-disabled='false'] { color: var(--encre); text-decoration: none; }
.jour.est-dans { border-radius: 0; background: var(--rouge-pale); color: var(--encre); }
.jour.est-dans small { color: var(--encre); }
.jour.est-choisi { background: var(--rouge); color: var(--papier); text-decoration: none; }
.jour.est-choisi small { color: var(--papier); }
.jour.est-arrivee { border-radius: .5rem 0 0 .5rem; }
.jour.est-depart { border-radius: 0 .5rem .5rem 0; }
.jour.est-arrivee.est-depart { border-radius: .5rem; }
.jour.est-apercu { background: var(--rouge-pale); border-radius: 0; }
.jour.est-aujourdhui::after { content: ''; position: absolute; left: 50%; bottom: .3rem; width: .3rem; height: .3rem; border-radius: 50%; background: var(--rouge); translate: -50% 0; }
.calendrier-sans-js { padding: 1rem; background: var(--papier-2); }

.resume {
  display: grid;
  gap: 1.1rem;
  align-content: start;
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--papier-2);
}
.resume-titre { font: 450 1.5rem/1.2 var(--serif); }
.resume-dates { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--filet); border-radius: .75rem; background: var(--papier); }
.resume-dates div { display: grid; gap: .2rem; padding: .75rem .9rem; }
.resume-dates div + div { border-left: 1px solid var(--filet); }
.resume-dates span, .voyageurs > span { font: 600 .6875rem/1.2 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--encre-2); }
.resume-dates b { font-weight: 500; }
.voyageurs { display: flex; align-items: center; justify-content: space-between; padding: .5rem .25rem; }
.voyageurs-choix { display: flex; align-items: center; gap: .75rem; }
.voyageurs-choix button {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid var(--filet);
  border-radius: 50%;
  background: var(--papier);
  font-size: 1.15rem;
  cursor: pointer;
}
.voyageurs-choix button:hover:not(:disabled) { border-color: var(--encre); }
.voyageurs-choix button:disabled { opacity: .35; cursor: default; }
.voyageurs-choix output { min-width: 1.5ch; font-weight: 600; text-align: center; font-variant-numeric: tabular-nums; }
.resume-aide { min-height: 3em; color: var(--encre-2); font-size: .9688rem; }
.resume-lignes { display: grid; gap: .45rem; margin: 0; }
.resume-lignes:empty { display: none; }
.resume-lignes div { display: flex; justify-content: space-between; gap: 1rem; font-size: .9688rem; }
.resume-lignes dd { margin: 0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.resume-lignes .ligne-gratuit dd { color: #2f6b45; font-weight: 600; }
.resume-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: .9rem; border-top: 2px solid var(--encre); }
.resume-total span { font-weight: 600; }
.resume-total b { font: 500 1.75rem/1 var(--serif); font-variant-numeric: tabular-nums; }
.resume-note { color: var(--encre-2); font-size: var(--t-petit); text-align: center; }

.demande, .merci {
  margin-top: 1.5rem;
  padding: clamp(1.25rem, 3vw, 2.25rem);
  border-radius: 1.25rem;
  background: var(--papier);
  color: var(--encre);
}
.demande h3, .merci h3 { font-size: var(--t-h3); }
.demande-rappel { margin: .4rem 0 1.5rem; color: var(--encre-2); }
.demande-champs { display: grid; gap: 1rem 1.5rem; }
@media (min-width: 44rem) {
  .demande-champs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .demande-message { grid-column: 1 / -1; }
}
.demande label { display: grid; gap: .4rem; font-weight: 600; font-size: .9375rem; }
.demande small { font-weight: 400; color: var(--encre-2); }
.demande input, .demande textarea {
  width: 100%;
  padding: .8rem .9rem;
  border: 1px solid var(--papier-3);
  border-radius: .6rem;
  background: #fffaf2;
  color: var(--encre);
  font: 400 1rem/1.4 var(--sans);
}
.demande input:focus-visible, .demande textarea:focus-visible { outline: 2px solid var(--rouge); outline-offset: 1px; border-color: transparent; }
.demande [aria-invalid='true'] { border-color: var(--rouge); }
.demande-erreur { min-height: 1.5em; margin-top: .75rem; color: var(--rouge); font-weight: 600; }
.demande-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; margin-top: .5rem; }
.lien-retour::after { content: none; }
.lien-retour::before { content: '←'; }
.merci { display: grid; gap: .75rem; justify-items: start; }
.merci:focus { outline: none; }
.coeur-moyen { width: 3rem; }
.merci-maquette { padding: .9rem 1rem; border-left: 3px solid var(--rouge); background: var(--papier-2); color: var(--encre-2); font-size: .9375rem; }

.tarifs {
  width: 100%;
  margin-top: 3rem;
  border-collapse: collapse;
  font-size: .9688rem;
}
.tarifs caption { margin-bottom: 1rem; font: 450 var(--t-h3)/1.2 var(--serif); text-align: left; }
.tarifs th, .tarifs td { padding: .8rem .75rem .8rem 0; border-bottom: 1px solid var(--nuit-filet); text-align: left; vertical-align: top; }
.tarifs thead th { font: 600 .6875rem/1.2 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--nuit-texte); }
.tarifs tbody th { font-weight: 600; }
.tarifs td:nth-child(3) { white-space: nowrap; font-variant-numeric: tabular-nums; }
.tarifs td { color: var(--nuit-texte); }
.tarifs-note { margin-top: 1rem; color: var(--nuit-texte); font-size: var(--t-petit); }
@media (max-width: 43.99rem) {
  .tarifs thead { display: none; }
  .tarifs tr { display: grid; grid-template-columns: 1fr auto; gap: .15rem 1rem; padding: .85rem 0; border-bottom: 1px solid var(--nuit-filet); }
  .tarifs th, .tarifs td { padding: 0; border: 0; }
  .tarifs td:nth-child(2) { grid-column: 1; grid-row: 2; }
  .tarifs td:nth-child(3) { grid-column: 2; grid-row: 1; color: var(--papier); }
  .tarifs td:nth-child(4) { grid-column: 2; grid-row: 2; text-align: right; }
}

/* ---------- Infos pratiques ---------- */
.infos {
  display: grid;
  gap: 3rem;
  padding-block: var(--section) calc(var(--section) + var(--alpage-h) * .6);
}
.infos-tete .surtitre { margin-bottom: 1.25rem; }
.infos-grille { display: grid; gap: 2rem 3rem; }
.infos h3 { margin-bottom: .6rem; font-size: var(--t-h3); }
.infos article { padding-top: 1.25rem; border-top: 2px solid var(--encre); }
.infos article p + p { margin-top: .75rem; }
.infos article p { color: var(--encre-2); }
@media (min-width: 44rem) { .infos-grille { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64rem) {
  .infos { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
}

/* ---------- Pied ----------
   Le rouge du pied monte dans le papier de la page par la rangée de
   l'alpage : la même découpe que le héros, en miroir de couleur. */
.pied {
  position: relative;
  padding-top: 2rem;
  background: var(--rouge);
  color: var(--papier);
}
.decoupe-pied {
  position: absolute;
  inset: auto 0 calc(100% - 1px);
  height: var(--alpage-h);
  background: var(--rouge);
  -webkit-mask: url('../img/decoupe-alpage.svg') center bottom / cover no-repeat;
  mask: url('../img/decoupe-alpage.svg') center bottom / cover no-repeat;
}
.pied-grille { display: grid; gap: 2.5rem; padding-block: 2rem 3rem; }
.pied-marque { display: grid; gap: .6rem; justify-items: start; }
.coeur-pied { width: 4rem; background: var(--papier); }
.pied-nom { font: 450 1.9rem/1.1 var(--serif); }
.pied-marque p:last-child { color: rgb(244 237 225 / .82); }
.pied-liens { display: grid; gap: .6rem; align-content: start; }
.pied-liens a { text-decoration: none; }
.pied-liens a:hover { text-decoration: underline; }
.pied-credits { display: grid; gap: .9rem; align-content: start; font-size: .9375rem; }
.pied-credits details { color: rgb(244 237 225 / .85); }
.pied-credits summary { cursor: pointer; font-weight: 600; color: var(--papier); }
.pied-credits ul { margin: .75rem 0; padding-left: 1.1rem; }
.pied-bas {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 2rem;
  padding-block: 1.25rem 1.75rem;
  border-top: 1px solid rgb(244 237 225 / .3);
  font-size: var(--t-petit);
}
.pied a:focus-visible { outline-color: var(--papier); }
@media (min-width: 64rem) {
  .pied-grille { grid-template-columns: minmax(0, 4fr) minmax(0, 3fr) minmax(0, 5fr); }
}
