/* V2 « Le sapin de lumière » — page d'accueil.
   Couches : .fond (décor CSS) < .toile (WebGL transparent) < .page (interface HTML) < écrin < #eclat (film.css).
   De haut en bas, sur un seul écran : le titre, le sapin (étoile, 24 boules, 6 bijoux), le logo RS Selection
   à son pied, la date, le bouton principal, le pied de page.
   Le sapin 2D ci-dessous est l'affiche instantanée et la version de repli ; en 3D (html.mode-3d),
   son dessin s'efface et il ne reste que les boutons, alignés sur les ornements.
   Police, jetons et bouton principal : jetons.css (communs avec l'écrin). Mouvement de l'arrivée : film.css. */

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--nuit); color-scheme: dark; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  position: relative; margin: 0; min-height: 100vh; min-height: 100svh;
  background: var(--nuit); color: var(--blanc);
  font-family: var(--sans); font-weight: 400; font-stretch: 100%; font-size: var(--t-texte); line-height: 1.5;
  font-variant-numeric: lining-nums; letter-spacing: 0;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden; overscroll-behavior: none;
}
a { color: inherit; text-decoration: none; }
p, h1, h2 { margin: 0; }
sup { font-size: .62em; line-height: 0; vertical-align: .5em; margin-left: .03em; }
.cache {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}
:focus-visible { outline: var(--anneau); outline-offset: 3px; }

/* ------------------------------------------------------------ décor */
.fond {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  /* L'intérieur d'un chalet, le soir : bois, feu de cheminée, guirlandes, la neige derrière la fenêtre — le tout hors
     foyer, pour que le sapin reste au premier plan. Image de décor (assets/v2/decor/), une version par orientation. */
  background: var(--fond-base) url("../decor/chalet-portrait.webp") 50% 50% / cover no-repeat;
}
@media (min-aspect-ratio: 1/1) {
  .fond { background-image: url("../decor/chalet-paysage.webp"); }
}
/* Un grain fixe par-dessus l'image : il lui donne une surface et casse les paliers des zones sombres. */
.fond::before {
  content: ""; position: absolute; inset: 0; opacity: .06;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 .96  0 0 0 0 .9  0 0 0 1.2 -.35'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23g)'/%3E%3C/svg%3E") 0 0 / 180px 180px;
}
/* Voiles de lisibilité : le haut (titre) et le bas (logo, date, bouton, pied de page) restent plus profonds. */
.fond::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(14, 8, 4, .55) 0, rgba(14, 8, 4, 0) 20%),
    linear-gradient(to top, rgba(14, 8, 4, .78) 0, rgba(14, 8, 4, .4) 20%, rgba(14, 8, 4, 0) 40%),
    radial-gradient(ellipse 92% 86% at 50% 44%, rgba(14, 8, 4, 0) 54%, rgba(14, 8, 4, .36) 100%);
}
.toile {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; display: block;
  opacity: 0; pointer-events: none; transition: opacity 1.1s var(--sortie);
}
.mode-3d .toile { opacity: 1; }

/* ------------------------------------------------------------ page */
.page {
  position: relative; z-index: 2; display: flex; flex-direction: column;
  min-height: 100vh; min-height: 100svh;
  padding: 0 max(16px, env(safe-area-inset-right)) 0 max(16px, env(safe-area-inset-left));
  touch-action: pan-y;
}
.bandeau-test {
  flex: none; margin: 0 -16px; padding: 4px 12px; text-align: center;
  font-size: var(--t-xs); line-height: 1.35; color: var(--blanc-doux);
  background: rgba(244, 238, 227, .05); border-bottom: 1px solid var(--filet);
}
.bandeau-test[hidden] { display: none; }

/* Le haut : un seul titre, petit, centré, en Saira large. Le logo est au pied du sapin. */
.entete {
  flex: none; display: flex; justify-content: center;
  padding: max(14px, env(safe-area-inset-top)) 0 4px;
  transition: opacity 1.1s var(--sortie) .25s;
}
.entete__titre {
  font-weight: 400; font-stretch: var(--chasse-titre); font-size: 1.125rem; line-height: 1.25; letter-spacing: 0;
  color: var(--blanc); text-align: center;
}
.sapin { flex: 1 1 auto; min-height: 336px; }
.sans-js { padding: 30vh 12px 0; text-align: center; color: var(--blanc-doux); }

/* Au pied du sapin : la marque. Le logo RS Selection, jamais redessiné ni recoloré, de l'air tout autour. */
.pied-sapin { flex: none; display: flex; justify-content: center; transition: opacity 1.1s var(--sortie) .25s; }
/* Le pied : la date, le bouton, puis une ligne discrète. */
.socle {
  flex: none; display: flex; flex-direction: column; align-items: center; text-align: center;
  padding-bottom: max(10px, env(safe-area-inset-bottom));
  transition: opacity 1.1s var(--sortie) .25s;
}
.marque { display: block; flex: none; margin-top: 2px; padding: 8px 14px; border-radius: 3px; }
.marque picture, .marque img { display: block; }
.marque img { width: 104px; height: auto; }
.socle__date {
  display: grid; justify-items: center; margin-top: 4px; min-height: 1.5em;
  /* la date tient sur une ligne en trois langues (« 1er décembre · December 1st · 1. Dezember ») jusqu'à 320 px de large */
  font-size: clamp(.8125rem, 3.7vw, 1rem); line-height: 1.5; color: var(--blanc-doux);
}
.socle__date[hidden] { display: none; }
.socle__date > span { grid-area: 1 / 1; white-space: nowrap; transition: opacity .35s var(--sortie); }
/* Avis d'une case verrouillée (« S’ouvre le 14 décembre ») : il prend un instant la place de la date. */
.socle__avis { opacity: 0; color: var(--blanc); }
.socle__date--avis .socle__jour { opacity: 0; }
.socle__date--avis .socle__avis { opacity: 1; }
.socle__message {
  margin-top: 10px; min-height: 52px; display: flex; align-items: center; justify-content: center;
  font-weight: 300; font-stretch: var(--chasse-titre); font-size: var(--t-l); line-height: 1.2; color: var(--blanc);
  max-width: 17em; text-wrap: balance;
}
.socle__message[hidden] { display: none; }
.socle__pied { margin-top: 6px; font-size: var(--t-xs); line-height: 1.35; color: var(--blanc-discret); }
.socle__pied a { display: inline-block; padding: 5px 12px; transition: color .3s; }
.socle__pied a:hover { color: var(--blanc-doux); }

/* Le bouton principal (forme et matière : jetons.css, .bouton-principal) : ici, seulement sa place. */
.cta { margin-top: 10px; height: auto; min-height: 52px; padding-top: 10px; padding-bottom: 10px; }
/* Son libellé en trois langues, une ligne par langue : le français en tête, l'anglais et l'allemand un ton en dessous. */
.cta .bouton-principal__texte { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: var(--t-m); line-height: 1.2; }
.cta__ligne { display: block; white-space: nowrap; }
.cta__ligne:not(:first-child) { font-weight: 400; opacity: .9; }

/* ------------------------------------------------------------ les 31 cases */
/* Les boutons suivent les ornements à coups de transform : le conteneur les rogne, pour qu'une pièce qui sort
   du cadre (rotation, plan d'arrivée) n'élargisse jamais la page. */
.cases { position: absolute; inset: 0; pointer-events: none; touch-action: pan-y; overflow: hidden; overflow: clip; }
.page.glisse, .page.glisse .case { cursor: grabbing; }
.page.glisse { -webkit-user-select: none; user-select: none; }
.case {
  position: absolute; top: 0; left: 0; width: var(--l, 44px); height: var(--h, 44px);
  margin: 0; padding: 0; border: 0; border-radius: 50%; background: none; color: inherit; font: inherit;
  cursor: pointer; pointer-events: auto; touch-action: pan-y; -webkit-tap-highlight-color: transparent;
  user-select: none; -webkit-user-select: none;
}
.case[aria-disabled="true"] { cursor: default; }
.case:focus-visible { outline: var(--anneau); outline-offset: 3px; }
.case__corps {
  position: absolute; left: 50%; top: 50%; pointer-events: none;
  width: calc(2 * var(--u) * var(--r)); height: calc(2 * var(--u) * var(--r));
  margin: calc(-1 * var(--u) * var(--r)) 0 0 calc(-1 * var(--u) * var(--r));
  transition: opacity .9s var(--sortie), visibility 0s linear .9s;
}
.mode-3d .case__corps { opacity: 0; visibility: hidden; }
html:not(.mode-3d) .case__corps { transition-delay: 0s; }

/* Fil : un cheveu d'or qui se perd vers le haut. */
.case__fil {
  position: absolute; left: 50%; bottom: calc(100% + .46 * var(--u) * var(--r)); width: 1px; margin-left: -.5px;
  height: calc(var(--fil) * var(--u));
  background: linear-gradient(to top, rgba(217, 192, 140, .5), rgba(217, 192, 140, 0));
}
/* Coiffe et anneau : une couronne de montre, pas un créneau. */
.case__coiffe {
  position: absolute; left: 50%; bottom: calc(100% - .08 * var(--u) * var(--r));
  width: calc(.44 * var(--u) * var(--r)); height: calc(.24 * var(--u) * var(--r)); margin-left: calc(-.22 * var(--u) * var(--r));
  border-radius: 1px 1px 0 0;
  background: linear-gradient(90deg, #3d3019 0%, #b79c64 24%, #f1e3bd 40%, #a48a55 62%, #4a3a1e 100%);
}
.case__coiffe::before {
  content: ""; position: absolute; left: 50%; bottom: 100%; width: calc(.26 * var(--u) * var(--r)); height: calc(.26 * var(--u) * var(--r));
  margin-left: calc(-.13 * var(--u) * var(--r)); margin-bottom: -1px; border-radius: 50%; border: 1px solid #b79c64;
}

/* Boules : des sphères sombres qui ne montrent que ce que le studio leur donne — la grande fenêtre, graduée,
   en haut à gauche, un contre-jour fin à droite, un rien de sol chaud en bas. Jamais d'arc dessiné.
   Fermées : chrome noir, laque sapin, rouge profond sur quelques-unes. L'or est réservé à la pièce du jour. */
.case__boule {
  position: absolute; inset: 0; border-radius: 50%;
  --teinte-1: #4a0a10; --teinte-2: #23050a; --teinte-3: #0a0203; --fenetre: .8; --contre-jour: .6;
  background:
    radial-gradient(ellipse 40% 27% at 31% 23%, rgba(255, 244, 226, var(--fenetre)) 0%, rgba(255, 244, 226, calc(var(--fenetre) * .5)) 38%, rgba(255, 244, 226, calc(var(--fenetre) * .1)) 72%, rgba(255, 244, 226, 0) 100%),
    radial-gradient(ellipse 70% 30% at 50% 100%, rgba(196, 150, 92, .2), rgba(196, 150, 92, 0) 80%),
    radial-gradient(circle at 40% 34%, var(--teinte-1) 0%, var(--teinte-2) 48%, var(--teinte-3) 82%, #020101 100%);
  box-shadow: inset calc(-.07 * var(--u)) calc(.02 * var(--u)) calc(.07 * var(--u)) calc(-.03 * var(--u)) rgba(255, 236, 208, var(--contre-jour));
}
.fini-vert .case__boule { --teinte-1: #0f3023; --teinte-2: #071a12; --teinte-3: #020806; }
.fini-chrome .case__boule { --teinte-1: #1c1d20; --teinte-2: #09090a; --teinte-3: #020202; --fenetre: .9; }

/* Chiffres : Saira, dorés et francs — ils se lisent d'un coup d'œil sur un téléphone. */
.case__num {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--sans); font-weight: 500; font-stretch: 105%; font-size: calc(.54 * var(--u) * var(--r)); line-height: 1; letter-spacing: 0;
  font-variant-numeric: lining-nums; color: #f1dca6;
}

/* ---- États ---- */
/* À venir : la pièce est fermée mais bien éclairée — on lit sa couleur et son chiffre sans effort. */
.case--futur .case__boule { filter: brightness(1.25) saturate(1.15); }
.case--futur .case__coiffe { filter: brightness(.8); }
.case--futur .case__fil { opacity: .7; }
.case--futur .case__num { color: #f1dca6; opacity: 1; text-shadow: 0 0 calc(.1 * var(--u)) rgba(0, 0, 0, .6); }

/* Du jour : la pièce la plus lumineuse de l'écran — or champagne satiné, halo lent. */
.case__halo {
  position: absolute; inset: -130%; border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 226, 180, .36) 0%, rgba(217, 192, 140, .14) 30%, rgba(217, 192, 140, .04) 52%, rgba(217, 192, 140, 0) 68%);
  animation: respire 4.8s ease-in-out infinite;
}
@keyframes respire { 0%, 100% { opacity: .62; transform: scale(.94); } 50% { opacity: 1; transform: scale(1.04); } }
.case--classique.case--jour .case__boule {
  background:
    radial-gradient(ellipse 42% 28% at 32% 24%, rgba(255, 246, 222, .82) 0%, rgba(255, 246, 222, .22) 50%, rgba(255, 246, 222, 0) 86%),
    radial-gradient(ellipse 80% 30% at 52% 100%, rgba(240, 200, 128, .34), rgba(240, 200, 128, 0) 80%),
    radial-gradient(circle at 39% 31%, #d2b473 0%, #a17f40 34%, #6a4f22 62%, #36260d 86%, #1c1306 100%);
  box-shadow: inset calc(-.07 * var(--u)) calc(.02 * var(--u)) calc(.08 * var(--u)) calc(-.03 * var(--u)) rgba(255, 244, 222, .7);
}
/* Gravure sombre creusée dans l'or, un filet de lumière sur sa lèvre basse. */
.case--classique.case--jour .case__num { color: #241906; font-weight: 400; text-shadow: 0 calc(.03 * var(--u)) 0 rgba(255, 240, 206, .34); }
.case--jour .case__coiffe { filter: brightness(1.15); }

/* Ouverte : une bulle de verre clair — un liseré, un reflet, et ce qu'elle garde : la miniature du produit
   (le noir de la photo fondu), ou une petite braise si la case est vide. Le chiffre descend au bas du verre. */
.case--ouverte .case__boule {
  background:
    radial-gradient(ellipse 54% 40% at 31% 23%, rgba(255, 246, 232, .22) 0%, rgba(255, 246, 232, .05) 56%, rgba(255, 246, 232, 0) 80%),
    radial-gradient(circle, rgba(255, 214, 160, .2) 0%, rgba(255, 214, 160, .07) 44%, rgba(255, 214, 160, 0) 68%),
    radial-gradient(circle, rgba(18, 15, 11, .22) 0%, rgba(18, 15, 11, .22) 76%, rgba(226, 204, 160, .1) 90%, rgba(232, 212, 170, .6) 99%, rgba(232, 212, 170, .2) 100%);
  box-shadow: inset calc(-.05 * var(--u)) calc(.02 * var(--u)) calc(.06 * var(--u)) calc(-.03 * var(--u)) rgba(255, 236, 208, .4);
}
.case--ouverte .case__coiffe { filter: brightness(.7); }
.case__mini {
  position: absolute; left: 9%; top: 6%; width: 82%; height: 82%; border-radius: 50%; object-fit: cover;
  mix-blend-mode: screen; opacity: .86;
  -webkit-mask-image: radial-gradient(circle, #000 44%, rgba(0, 0, 0, 0) 68%); mask-image: radial-gradient(circle, #000 44%, rgba(0, 0, 0, 0) 68%);
}
.case__braise {
  position: absolute; left: 50%; top: 47%; width: 26%; height: 34%; margin: -17% 0 0 -13%; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(255, 236, 198, .92) 0%, rgba(255, 204, 140, .34) 34%, rgba(255, 196, 130, 0) 70%);
}
.case--classique.case--ouverte .case__num {
  inset: auto 0 9% 0; font-size: calc(.3 * var(--u) * var(--r)); font-weight: 400; color: #cdb27a;
}
.case--ouverte.case--du-jour .case__boule {
  box-shadow: inset calc(-.05 * var(--u)) calc(.02 * var(--u)) calc(.06 * var(--u)) calc(-.03 * var(--u)) rgba(255, 236, 208, .7), 0 0 calc(.9 * var(--u)) rgba(217, 192, 140, .22);
}

/* Étoile (25) et bijoux (26–31). Une seule lumière : la fenêtre du studio, en haut à gauche. */
.case--etoile .case__corps {
  width: calc(3.44 * var(--u) * var(--r)); height: calc(3.44 * var(--u) * var(--r));
  margin: calc(-1.72 * var(--u) * var(--r)) 0 0 calc(-1.72 * var(--u) * var(--r));
}
.case--magique .case__corps {
  width: calc(1.48 * var(--u)); height: calc(2.08 * var(--u));
  margin: calc(-1.04 * var(--u)) 0 0 calc(-.74 * var(--u));
}
.case__dessin { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
/* Étoile : un corps de bronze très sombre, des arêtes d'or. */
.case__dessin--etoile .f0 { fill: #b79c64; } .case__dessin--etoile .f1 { fill: #6b5529; } .case__dessin--etoile .f2 { fill: #261d0f; } .case__dessin--etoile .f3 { fill: #110c06; }
/* Bijou : une pierre fumée presque noire ; ce sont ses arêtes qui brillent, pas ses faces. */
.case__dessin--bijou path { stroke: rgba(226, 204, 160, .62); stroke-width: 1.5; stroke-linejoin: round; }
.case__dessin--bijou .f0 { fill: #4a3b1f; } .case__dessin--bijou .f1 { fill: #2c2313; } .case__dessin--bijou .f2 { fill: #1a140b; } .case__dessin--bijou .f3 { fill: #0f0c07; }
.case__dessin--bijou .table { fill: #0a0805; stroke: rgba(226, 204, 160, .4); }
.case--etoile .case__fil { bottom: calc(100% - .02 * var(--u)); }
/* Le 25 pend sous l'étoile, sur une petite plaque d'or. */
.case--etoile .case__num {
  inset: calc(100% + .06 * var(--u)) auto auto 50%; width: calc(.54 * var(--u) * var(--r)); height: calc(.44 * var(--u) * var(--r)); margin-left: calc(-.27 * var(--u) * var(--r));
  border-radius: 1px; background: linear-gradient(160deg, #8f7444 0%, #5b4826 60%, #3d2f17 100%);
  font-size: calc(.3 * var(--u) * var(--r)); font-weight: 400; color: #f1e3bd;
}
.case--magique .case__num { font-size: calc(.42 * var(--u)); font-weight: 400; color: #e3cd9c; }
.case--futur .case__dessin--etoile { filter: brightness(.6); }
.case--futur .case__dessin--bijou { filter: brightness(.66); }
.case--etoile.case--futur .case__num { color: #f1dca6; opacity: 1; }
.case--magique.case--futur .case__num { color: #f1dca6; opacity: 1; }
.case--etoile.case--jour .case__dessin, .case--magique.case--jour .case__dessin,
.case--etoile.case--ouverte.case--du-jour .case__dessin, .case--magique.case--ouverte.case--du-jour .case__dessin {
  filter: brightness(1.5) drop-shadow(0 0 calc(.6 * var(--u)) rgba(241, 227, 189, .42));
}
.case--etoile.case--jour .case__num, .case--magique.case--jour .case__num { color: #fff3d6; }
.case--etoile .case__halo { inset: -36%; }
.case--magique .case__halo { inset: -64% -96%; }

/* Repli 2D, à la souris : la pièce visée s'éclaire un peu (en 3D, c'est la scène qui l'avance). */
@media (hover: hover) and (pointer: fine) {
  html:not(.mode-3d) .case:not([aria-disabled="true"]) .case__corps { transition: filter .3s var(--sortie), opacity .9s var(--sortie); }
  html:not(.mode-3d) .case:not([aria-disabled="true"]):hover .case__corps { filter: brightness(1.14); }
}

/* Balancement lent, frisson du refus */
html:not(.mode-3d) .case--classique .case__corps, html:not(.mode-3d) .case--etoile .case__corps {
  transform-origin: 50% calc(-1 * var(--fil) * var(--u)); animation: balance 6.4s ease-in-out var(--phase, 0s) infinite alternate;
}
@keyframes balance { from { transform: rotate(-.7deg); } to { transform: rotate(.7deg); } }
.case--frisson .case__corps { animation: frisson .62s var(--sortie) 1 !important; }
@keyframes frisson {
  0% { transform: translateX(0) rotate(0); } 18% { transform: translateX(-2.5px) rotate(-2.4deg); } 40% { transform: translateX(2px) rotate(1.8deg); }
  62% { transform: translateX(-1.2px) rotate(-1deg); } 82% { transform: translateX(.6px) rotate(.4deg); } 100% { transform: translateX(0) rotate(0); }
}
/* Ouverture en 2D : la case vient vers nous avant l'éclat */
.case--ouvre { z-index: 80 !important; }
.case--ouvre .case__corps { animation: avance .6s var(--entree-sortie) forwards !important; }
@keyframes avance { to { transform: scale(1.5); filter: brightness(1.5); } }

/* ------------------------------------------------------------ séquence d'ouverture */
.en-sequence .entete, .en-sequence .pied-sapin, .en-sequence .socle { opacity: 0; pointer-events: none; transition: opacity .5s var(--sortie); }
.en-sequence .cases { visibility: hidden; }
html:not(.mode-3d).en-sequence .cases { visibility: visible; }
.en-sequence .case { pointer-events: none; }
/* L'éclat qui couvre le passage du sapin à l'écrin (#eclat, .film-eclat) : css/film.css. */

/* Pendant que l'écrin couvre la page, plus rien ne s'anime dessous. */
.ecrin-ouvert .page *, .ecrin-ouvert .page *::before, .ecrin-ouvert .page *::after { animation-play-state: paused !important; }

/* ------------------------------------------------------------ tailles */
/* Grands téléphones : le logo prend sa pleine largeur. */
@media (min-width: 400px) and (min-height: 860px) {
  .marque img { width: 112px; }
  .entete { padding-top: max(18px, env(safe-area-inset-top)); }
  .socle { padding-bottom: max(14px, env(safe-area-inset-bottom)); }
  .cta { margin-top: 12px; }
}
/* Écrans bas (360×640) : tout se resserre d'un cran, rien ne disparaît. */
@media (max-height: 700px) {
  .entete { padding-top: max(10px, env(safe-area-inset-top)); padding-bottom: 2px; }
  .entete__titre { font-size: 1.0625rem; }
  .marque { margin-top: 0; padding: 5px 14px; }
  .marque img { width: 96px; }
  .socle__date { margin-top: 2px; font-size: clamp(.8125rem, 3.7vw, .9375rem); }
  .cta { margin-top: 7px; min-height: 50px; padding-top: 7px; padding-bottom: 7px; }
  .cta .bouton-principal__texte { gap: 1px; font-size: var(--t-s); }
  .socle__message { margin-top: 7px; min-height: 50px; font-size: 1.25rem; }
  .socle__pied { margin-top: 3px; }
  .socle__pied a { padding: 3px 12px; }
  .socle { padding-bottom: max(6px, env(safe-area-inset-bottom)); }
}
/* Très petits écrans (320×568) : le bouton à sa hauteur minimale, la ligne de pied s'efface pour laisser sa place au sapin. */
@media (max-height: 600px) {
  .entete { padding-top: max(8px, env(safe-area-inset-top)); padding-bottom: 0; }
  .entete__titre { font-size: 1rem; }
  .bandeau-test { padding: 1px 12px; }
  .marque { padding: 3px 14px; }
  .cta { min-height: 48px; margin-top: 5px; padding-top: 5px; padding-bottom: 5px; }
  .socle__message { min-height: 48px; margin-top: 5px; }
  .socle__pied { display: none; }                 /* le logo, juste au-dessus, mène déjà à la boutique */
  .socle { padding-bottom: max(10px, env(safe-area-inset-bottom)); }
}
/* Tablettes et ordinateurs : la colonne reste centrée ; la ligne de pied quitte la pile pour le coin de la page,
   ce qui rend sa hauteur au sapin. */
@media (min-width: 760px) {
  .page { padding: 0 44px; }
  .bandeau-test { margin: 0 -44px; }
  .entete { padding-top: 26px; padding-bottom: 6px; }
  .entete__titre { font-size: 1.375rem; font-weight: 350; }
  .marque { margin-top: 0; padding: 4px 18px 10px; }   /* main.js réserve déjà de l'air sous le sapin sur les grands écrans */
  .marque img { width: 132px; }
  .socle__date { margin-top: 6px; font-size: 1.0625rem; }
  .cta { margin-top: 14px; }
  .socle__message { margin-top: 12px; font-size: 1.625rem; }
  .socle { padding-bottom: 34px; }
  .socle__pied { display: block; position: absolute; right: 32px; bottom: 16px; margin: 0; }
}
/* Ordinateurs portables (1280×720, 1366×768 avec les barres du navigateur) : tout se resserre pour le sapin. */
@media (min-width: 760px) and (max-height: 800px) {
  .entete { padding-top: 16px; padding-bottom: 2px; }
  .entete__titre { font-size: 1.25rem; }
  .marque { padding: 0 18px 6px; }
  .marque img { width: 120px; }
  .socle__date { margin-top: 2px; font-size: var(--t-texte); }
  .cta { margin-top: 10px; min-height: 52px; padding-top: 8px; padding-bottom: 8px; }
  .cta .bouton-principal__texte { gap: 2px; font-size: var(--t-s); }
  .socle__message { margin-top: 8px; min-height: 52px; font-size: 1.5rem; }
  .socle { padding-bottom: 22px; }
  .socle__pied { bottom: 10px; }
}
/* Grand écran en paysage (ordinateur, tablette couchée) : une vraie composition large, comme l'écrin.
   À gauche le sapin sur toute la hauteur, le logo à son pied ; à droite, centrés sur lui, le titre, la date et le
   bouton, ferrés à gauche. main.js cadre le sapin dans la boîte de .sapin, où qu'elle soit. */
@media (min-width: 1024px) and (min-aspect-ratio: 5/4) and (min-height: 540px) {
  .page {
    display: grid; grid-template-columns: minmax(0, min(50vw, 88vh)) max-content; justify-content: center;
    grid-template-rows: auto minmax(0, .82fr) auto auto minmax(0, 1.18fr) auto;
    padding: 0 48px;
  }
  /* Le bandeau de test sort de la grille (il fausserait la largeur des colonnes) : une ligne en haut de la page. */
  .bandeau-test { position: absolute; top: 0; left: 0; right: 0; margin: 0; }
  .mode-test .page { padding-top: 26px; }
  .sapin { grid-column: 1; grid-row: 2 / 6; min-height: 0; margin-top: 18px; }
  .pied-sapin { grid-column: 1; grid-row: 6; padding-bottom: 22px; }
  .marque { margin-top: 0; padding: 2px 18px 8px; }
  .marque img { width: 132px; }
  .entete, .socle { grid-column: 2; padding: 0 0 0 clamp(20px, 3.4vw, 60px); }
  .entete { grid-row: 3; justify-content: flex-start; }
  .entete__titre { font-size: clamp(2.5rem, 3.5vw, 3.375rem); font-weight: 300; line-height: 1.07; letter-spacing: -.01em; text-align: left; }
  .entete__titre span { display: block; white-space: nowrap; }                      /* deux lignes : « Calendrier » / « de l’Avent » */
  .socle { grid-row: 4; align-items: flex-start; text-align: left; }
  .socle__date { justify-items: start; margin-top: 18px; font-size: 1.125rem; }
  .cta { margin-top: 30px; }
  .socle__message { justify-content: flex-start; margin-top: 22px; min-height: 0; font-size: 1.625rem; text-align: left; }
}
@media (min-width: 1024px) and (min-aspect-ratio: 5/4) and (min-height: 540px) and (max-height: 720px) {
  .sapin { margin-top: 10px; }
  .pied-sapin { padding-bottom: 12px; }
  .marque img { width: 112px; }
  .entete__titre { font-size: clamp(2.125rem, 3.1vw, 2.75rem); }
  .socle__date { margin-top: 12px; }
  .cta { margin-top: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01s !important; }
  .case__halo { opacity: .85; }
}
