/* Aperçu 3D, en plus de style.css. */
.media3d [hidden], .showroom [hidden] { display: none !important; }

/* Bandeau pour passer d'une maquette à l'autre */
.apercu {
  position: fixed; z-index: 20; right: 12px; bottom: 12px; display: flex; align-items: center; gap: 4px; max-width: calc(100% - 24px); overflow-x: auto;
  padding: 4px; background: rgb(11 11 12 / .92); border: 1px solid var(--line); font: 600 .8rem/1 var(--display); text-transform: uppercase; letter-spacing: .06em;
}
.apercu span { color: var(--muted); padding: 0 6px; }
.apercu a { text-decoration: none; padding: 8px 10px; border: 1px solid transparent; white-space: nowrap; }
.apercu a:hover { border-color: var(--line); }
.apercu a[aria-current] { background: var(--neon); color: #000; }
.footer { padding-bottom: 80px; }
.note3d { margin: 10px 0 0; color: var(--muted); font-size: .8rem; line-height: 1.45; }

/* Accueil : léger mouvement des cartes seulement avec une souris et sans réduction des animations */
@media (hover: none), (prefers-reduced-motion: reduce) {
  .board:hover, .board:hover .board__img img { transform: none; }
}

/* ---------- Fiche : photos puis 3D dans la même zone ---------- */
.media3d { position: sticky; top: 88px; }
.media3d .product__media { position: static; display: block; padding: 0; }
.scene { position: relative; width: 100%; height: min(calc(var(--h) * 66), 680px); background: #000; overflow: hidden; }
.scene > img { position: absolute; inset: 0; width: 100%; height: 100%; max-height: none; object-fit: contain; padding: 24px; }
.scene > img:not(.scene__photo) { animation: none; }
.scene model-viewer { position: absolute; inset: 0; width: 100%; height: 100%; background: transparent; --poster-color: transparent; }
.scene:not(.scene--photo) > :is(.scene__photo, .scene__zoom), .scene--photo > :not(.scene__photo, .scene__zoom) { display: none !important; }
/* Photo agrandie : déplacement au doigt (la page ne défile plus sur la photo tant qu'elle est zoomée). */
.scene__photo { transition: scale .25s cubic-bezier(.2, .8, .2, 1), translate .25s cubic-bezier(.2, .8, .2, 1); }
.zoome .scene__photo { touch-action: none; cursor: grab; }
.deplace .scene__photo { transition: none; cursor: grabbing; }
.scene__zoom { position: absolute; right: 8px; bottom: 8px; display: flex; gap: 6px; }
.scene__zoom button { min-width: 40px; min-height: 40px; cursor: pointer; color: var(--text); background: rgb(11 11 12 / .8); border: 1px solid var(--line); font: 600 1.15rem/1 var(--display); }
.scene__zoom button:hover { border-color: var(--neon); }
/* Couverture pendant le chargement : même cadre que le lecteur, réduite comme le champ de vision de départ
   (tan 15° / tan 19° = 0,78 : cadrage automatique à 30°, fiche à 38°). */
.scene > .scene__couverture { padding: 0; scale: .78; }
.scene__etat { position: absolute; left: 50%; bottom: 16px; translate: -50% 0; margin: 0; padding: .4em .8em; background: rgb(0 0 0 / .75); color: var(--muted); font-size: .9rem; white-space: nowrap; }
.scene__erreur { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; padding: 24px; text-align: center; background: rgb(11 11 12 / .9); }
.scene__erreur p { margin: 0 0 12px; max-width: 32ch; }
.scene__vues, .showroom__vues { position: absolute; left: 8px; right: 8px; bottom: 8px; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.scene__vues button, .showroom__vues button, .showroom__nav {
  min-width: 40px; min-height: 40px; padding: 0 .8em; cursor: pointer; color: var(--text); background: rgb(11 11 12 / .8); border: 1px solid var(--line);
  font: 600 .85rem/1 var(--display); text-transform: uppercase; letter-spacing: .08em;
}
.scene__vues button:hover, .showroom__vues button:hover, .showroom__nav:hover { border-color: var(--neon); }
.scene__vues [data-vue=initiale], .scene__vues [data-zoom] { font-size: 1.15rem; }
.miniatures { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.miniature { position: relative; width: 64px; height: 88px; padding: 4px; cursor: pointer; background: #000; border: 1px solid var(--line); }
.miniature img { width: 100%; height: 100%; object-fit: contain; }
.miniature[aria-pressed=true] { border-color: var(--neon); box-shadow: inset 0 0 0 1px var(--neon); }
/* vidéo ajoutée dans l'atelier : lue dans le cadre de la photo */
.scene__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
.scene:not(.scene--video) > :is(.scene__video, .reel__barre, .reel__lecture), .scene--video > :not(.scene__video, .reel__barre, .reel__lecture) { display: none !important; }
/* Mode reel (27/11/2026) : affiche floutée derrière la vidéo verticale, barre de progression, pause au toucher */
.scene--video::before { content: ""; position: absolute; z-index: 0; inset: -12%; background: var(--reel-fond, none) center / cover; filter: blur(28px) brightness(.5); }
.scene--video .scene__video { z-index: 1; background: transparent; cursor: pointer; pointer-events: auto; }
.reel__barre { position: absolute; z-index: 2; left: 12px; right: 12px; top: 12px; height: 3px; background: rgb(255 255 255 / .3); pointer-events: none; }
.reel__barre i { display: block; height: 100%; background: var(--neon); scale: 0 1; transform-origin: left; }
.reel__lecture { position: absolute; z-index: 2; left: 50%; top: 50%; width: 72px; height: 72px; translate: -50% -50%; border: 0; border-radius: 50%; background: rgb(0 0 0 / .45); opacity: 0; transition: opacity .2s; cursor: pointer; }
.reel__lecture::before { content: ""; position: absolute; left: 29px; top: 22px; border-style: solid; border-width: 14px 0 14px 22px; border-color: transparent transparent transparent #fff; }
.reel--pause .reel__lecture, .reel__lecture:focus-visible { opacity: 1; }
.miniature video { width: 100%; height: 100%; object-fit: cover; }
.miniature--video span { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 1.2rem; text-shadow: 0 0 6px #000; }
.miniature--3d span { position: absolute; left: 3px; top: 3px; padding: 3px 5px; background: var(--neon); color: #000; font: 700 .75rem/1 var(--display); letter-spacing: .08em; }

/* ---------- Accueils 3D : éléments communs ---------- */
.showroom { --accent: var(--c-jaune); }
.showroom__scene { --haut: 4%; --bas: 4%; }
/* Image et lecteur 3D partagent le même cadre (--haut, --bas) et la même hauteur : la planche y a la même taille et la même place. */
.showroom__planche { position: absolute; left: 50%; top: var(--haut); height: calc(100% - var(--haut) - var(--bas)); width: auto; max-width: none; translate: -50% 0; transition: left .65s cubic-bezier(.2, .8, .2, 1), scale .65s cubic-bezier(.2, .8, .2, 1), opacity .4s; }
.showroom__planche[data-place=gauche] { left: 9%; scale: .55; opacity: .3; cursor: pointer; }
.showroom__planche[data-place=droite] { left: 91%; scale: .55; opacity: .3; cursor: pointer; }
.showroom__planche[data-place=cache] { opacity: 0; }
.showroom__planche[data-place=gauche]:hover, .showroom__planche[data-place=droite]:hover { opacity: .55; }
/* Un lecteur par planche : seul le visible apparaît. L'échange se fait quand les planches sont vues par la tranche,
   d'où un fondu court. La couverture centrale ne se voit que pendant un chargement. */
.pret:not(.charge, .sans3d, .glisse) > .showroom__planche[data-place=centre] { opacity: 0; transition-duration: .65s, .65s, .25s; }
.showroom__scene model-viewer { position: absolute; inset: var(--haut) 22% var(--bas); width: auto; height: auto; background: transparent; opacity: 0; pointer-events: none; transition: opacity .25s ease-out; }
.showroom__scene model-viewer.visible { opacity: 1; pointer-events: auto; }
.glisse > model-viewer.visible { opacity: 0; transition-duration: .15s; }
.sans3d model-viewer, .sans3d .showroom__vues, .sans3d .showroom__aide { display: none; }

/* Fond de la scène : une lumière blanche venue d'en haut, rien d'autre (21/11/2026). */
.showroom .showroom__scene { background:
  radial-gradient(ellipse 45% 60% at 50% 30%, rgb(255 255 255 / .075), transparent 70%) var(--bg); }

/* ---------- Accueil « showroom » ---------- */
.showroom__onglets { display: flex; gap: clamp(18px, 3vw, 44px); border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.showroom__onglets button {
  position: relative; padding: 0 0 12px; cursor: pointer; background: none; border: 0; color: var(--muted); white-space: nowrap;
  font: 800 clamp(1.4rem, 2.3vw, 1.9rem)/1 var(--display); text-transform: uppercase; transition: color .3s;
}
.showroom__onglets small { font: 500 .7rem var(--display); letter-spacing: .14em; margin-right: 8px; vertical-align: .6em; }
.showroom__onglets button::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--accent); scale: 0 1; transform-origin: left; transition: scale .45s cubic-bezier(.2, .8, .2, 1); }
.showroom__onglets [aria-selected=true] { color: var(--text); }
.showroom__onglets [aria-selected=true]::after { scale: 1 1; }
.showroom__grille { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: clamp(20px, 3vw, 48px); align-items: center; }
.showroom__scene { --bas: 60px; }
.showroom__scene { position: relative; height: clamp(420px, calc(var(--h) * 64), 700px); overflow: hidden; }
.showroom__aide { position: absolute; z-index: 1; left: 50%; top: 14px; translate: -50% 0; margin: 0; padding: 7px 12px; border: 1px solid var(--line); background: rgb(11 11 12 / .6); color: var(--muted); font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; pointer-events: none; transition: opacity .5s; }
.touche .showroom__aide { opacity: 0; }
.showroom__nav { position: absolute; top: 50%; translate: 0 -50%; z-index: 1; font-size: 1.4rem; }
.showroom__nav[data-pas="-1"] { left: 0; }
.showroom__nav[data-pas="1"] { right: 0; }
.showroom__fiche { display: grid; gap: 14px; animation: up .5s cubic-bezier(.2, .7, .2, 1) both; }
.showroom__fiche h3 { font-size: clamp(3.4rem, 6vw, 5rem); font-style: italic; }
.showroom__fiche .board__tag { margin: -8px 0 0; }
.showroom__fiche .lead { font-size: 1rem; margin: 0; }
.showroom__fiche .btn { justify-self: start; margin-top: 8px; }
.showroom__label { margin: 0; color: var(--muted); font-size: .8125rem; letter-spacing: .16em; text-transform: uppercase; }
.showroom__tailles { display: flex; flex-wrap: wrap; gap: 8px; margin-top: -6px; }
.showroom__tailles span { padding: .45em .9em; border: 1px solid var(--line); font-variant-numeric: tabular-nums; }

/* ---------- Accueil « défilement » ---------- */

@media (max-width: 760px) {
  .apercu span { display: none; }
  .apercu a { padding: 8px; }
  .scene__vues { gap: 4px; left: 4px; right: 4px; }
  .scene__vues button { min-width: 36px; padding: 0 .55em; font-size: .75rem; }
  .showroom__grille { grid-template-columns: 1fr; }
  .showroom__scene { height: calc(var(--h) * 64); margin: 12px -16px 0; }
  /* Téléphone : pas de voisines tronquées sur les bords ; la nouvelle planche entre depuis le bord, du côté choisi. */
  .showroom__planche[data-place=gauche] { left: -40%; scale: .7; opacity: 0; }
  .showroom__planche[data-place=droite] { left: 140%; scale: .7; opacity: 0; }
  .showroom__scene { --haut: 0%; --bas: 52px; }
  .showroom__scene model-viewer { left: 6%; right: 6%; }
  /* Téléphone : la planche reste collée en haut de l'écran et tourne ; les textes défilent dessous à vitesse normale. */
}
@media (max-width: 400px) {
  .media3d { position: static; }
  .scene { height: calc(var(--h) * 62); }
}
@media (prefers-reduced-motion: reduce) {
  .showroom__fiche { animation: none; }
}

/* ---------- Maquette « mixte » : showroom + cartes photos sur ordinateur, défilement sur téléphone ---------- */
.mixte__mobile { display: none; }
@media (max-width: 760px) {
  .mixte__ordi { display: none; }
  .mixte__mobile { display: block; }
}
.mixte__ordi .showroom__scene { height: clamp(400px, calc(calc(var(--h) * 100) - 64px - 330px), 680px); }
/* sous le showroom : les 4 coloris de la planche choisie ; un clic recolore la planche 3D (aria-pressed = coloris affiché) */
.showroom__photos { margin-top: 10px; }
.showroom__photos > div { display: flex; gap: 10px; }
.showroom__photos > div[hidden] { display: none; }
.showroom__photos .coloris { display: grid; justify-items: center; gap: 6px; padding: 8px 10px 6px; background: var(--bg-2); border: 1px solid var(--line); color: var(--muted); cursor: pointer; transition: border-color .2s, color .2s; }
.showroom__photos .coloris img { height: clamp(72px, calc(var(--h) * 10.5), 110px); width: auto; }
.showroom__photos .coloris span { font: 600 .8125rem/1 var(--display); letter-spacing: .12em; text-transform: uppercase; }
.showroom__photos .coloris:hover, .showroom__photos .coloris[aria-pressed=true] { border-color: var(--accent, var(--neon)); color: var(--text); }
.showroom__photos .coloris:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
/* navigateur sans 3D (WebGL désactivé) : on le dit, plutôt que de laisser croire que la planche devrait tourner */
.showroom__sans3d { display: none; }
.sans3d .showroom__sans3d { display: block; position: absolute; z-index: 2; left: 50%; top: 12px; translate: -50% 0; max-width: 80%; margin: 0; padding: 8px 12px; background: rgb(11 11 12 / .8); border: 1px solid var(--line); color: var(--muted); font-size: .8rem; text-align: center; }
.sans3d .showroom__aide { display: none; }
/* la planche affichée dans le showroom est surlignée parmi les cartes */
.mixte__ordi .board.actif { border-color: var(--accent, var(--neon)); }

/* ---------- Pied de page de la maquette « collage » (Postillon, SIL OFL 1.1) ---------- */
@font-face { font-family: "Postillon"; src: url("fonts/Postillon.ttf") format("truetype"); font-display: swap; size-adjust: 116%; }
/* Retours TNT du 22/11/2026 : le grand nom dans la typo du titre « Built light. » (Barlow Condensed) ; son jaune descend
   dans tout le pied de page, infos de contact en noir. */
.pied, .grand-nom { --t: var(--display); }
.pied { background: var(--neon); color: #000; overflow: hidden; }
.pied a { text-decoration: none; color: #000; }
.pied a:hover { text-decoration: underline; text-underline-offset: .25em; }
.pied__contact { width: var(--wrap); margin: 0 auto; padding: clamp(48px, 7vw, 88px) 0 40px; }
.pied .eyebrow { color: #000; opacity: .8; } /* .8 au plus bas : 4,5 de contraste sur le rose et le rouge des fiches (26/11/2026, .65 = 3,9) */
.pied h2 { color: #000; }
.pied .lead { color: #000; opacity: .8; max-width: 36em; }
.pied .contact-grid { margin-top: 32px; }
.pied .contact-card { background: transparent; border: 2px solid #000; color: #000; transition: background .2s, color .2s; }
.pied .contact-card small { color: rgb(0 0 0 / .8); }
.pied .contact-card:hover { background: #000; color: var(--neon); text-decoration: none; }
.pied .contact-card:hover small { color: color-mix(in srgb, var(--neon) 70%, transparent); } /* la couleur de la page, plus le jaune fixe (27/11/2026) */
.pied__legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 20px; width: var(--wrap); margin: 0 auto; color: rgb(0 0 0 / .8); font-size: .9rem; }
.pied__legal nav { display: flex; gap: 20px; }
/* zone de toucher de 44 px de haut sans changer la mise en page (audit du 24/11/2026 : 23 px) */
.pied__legal nav a { padding-block: 11px; margin-block: -11px; }
.pied__legal { padding-bottom: 28px; }
/* Grand nom : un rang au-dessus du pied de page, à la fin du bloc du dessus (sur le fond de la page), à la même place
   sur ordinateur et sur téléphone (demande du 21/11/2026). Il pose sa ligne de base sur le filet du pied. */
.grand-nom { font: 800 14.6vw/.8 var(--t); text-transform: uppercase; text-align: center; white-space: nowrap; color: var(--neon);
  margin: 96px 0 0; padding: 0; overflow: hidden; } /* collé en bas du bloc : la ligne de base touche le filet du pied */
/* text-box ramène la boîte du texte au haut des capitales et à la ligne de base (navigateurs récents ; sinon un léger jour en bas) */
@supports (text-box: trim-both cap alphabetic) { .grand-nom { text-box: trim-both cap alphabetic; line-height: 1; } }
/* téléphone : le nom sur deux lignes, plus gros, posé sur le pied jaune (TNT, 22/11/2026) */
@media (max-width: 760px) {
  .grand-nom { font-size: 21vw; line-height: .86; white-space: normal; }
  .grand-nom span { display: block; white-space: nowrap; }
  .pied .contact-card { padding: 20px; }
  .pied .contact-card span { font-size: 1.3rem; }
}

/* le pied de page se pose directement sous « Notre histoire » */
main:has(.story--fin) + .grand-nom { margin-top: 0; background: #000; } /* même fond que « Notre histoire » : le nom en fait partie */


/* ---------- Défilement mobile : à droite de la planche, un petit encart des % de la planche affichée ;
   le bloc de texte en dessous n'a plus les % (gardés pour les lecteurs d'écran), il est plus court (demande du 20/11/2026) ---------- */
@media (max-width: 760px) {
  /* la planche et l'encart forment un groupe centré : la planche à gauche du centre, l'encart juste à sa droite */
  /* le nom et l'accroche restent à l'écran avec la planche, au-dessus des % */
}

/* planche et texte dans un même bloc : sur ordinateur, il ne compte pas dans la mise en page (grille à deux colonnes) */

/* ---------- Défilement 3D sur téléphone, version « fixe » (choisie le 20/11/2026) : planche, nom, %, texte et bouton
   restent à l'écran ; le défilement fait tourner la planche puis passe à la suivante. La zone de texte a une hauteur fixe,
   texte et bouton y sont calés en bas : le bouton est au même endroit pour chaque planche, sans vide sous lui ---------- */


/* ---------- Accueil, téléphone (essai du 21/11/2026) : les planches en vidéo qui tournent, une carte sous l'autre ;
   ordinateur : le showroom. */
.planches-video { display: none; }
@media (max-width: 760px) {
  :root .planches-video { display: grid; gap: 14px; }
  /* Une carte = un écran, sous l'en-tête (retours des 22 et 23/11/2026, iPhone : la planche, ses stats et le bouton coupés en deux) :
     trait de couleur juste sous l'en-tête, bouton en bas de l'écran, la vidéo prend la place qui reste sans rogner la planche.
     Pas d'aimant de défilement (essayé le 22/11 : défilement saccadé sur iPhone).
     Cartes empilées essayées le 23/11/2026 puis retirées (« pas cette animation ») : défilement normal, une carte sous l'autre.
     Hauteur = l'écran mesuré une fois au chargement (--h, barres du navigateur affichées) : le bouton tombe en bas de l'écran.
     Pas de lvh/svh : Firefox sur iPhone redimensionne la page quand sa barre se cache ou revient, la carte changeait de
     hauteur et la planche rétrécissait / grossissait en plein défilement (23/11/2026). */
  .planches-video__carte { position: relative; display: flex; flex-direction: column;
    height: calc(var(--h) * 100 - 64px);
    background: var(--bg-2); border-top: 3px solid var(--accent); }
  .planches-video__ecran { position: relative; flex: 1; min-height: 0; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
  .planches-video__ecran :is(video, canvas, img) { display: block; width: 100%; height: 100%; object-fit: contain; background: var(--bg-2); }
  .planches-video__ecran canvas { position: absolute; inset: 0; height: 100%; opacity: 0; pointer-events: none; }
  .planches-video__ecran.en-main canvas { opacity: 1; }
  .planches-video__aide { position: absolute; bottom: 10px; left: 0; right: 0; margin: 0; text-align: center; font: 600 .68rem/1 var(--display);
    letter-spacing: .16em; text-transform: uppercase; color: var(--muted); pointer-events: none; transition: opacity .3s; }
  .planches-video__ecran.touche .planches-video__aide { opacity: 0; }
  .planches-video__num { position: absolute; top: 14px; left: 16px; font: 600 .75rem/1 var(--display); letter-spacing: .16em; color: var(--muted); }
  .planches-video__corps { display: grid; gap: 8px; padding: 0 18px 18px; }
  .planches-video__corps :is(h3, .h3) { font-size: 2.4rem; font-style: italic; }
  .planches-video__corps .board__tag { margin: -4px 0 0; }
  .planches-video__corps .board__meta { margin: 0; }
  .planches-video__corps .btn { justify-self: start; margin-top: 6px; font-size: .88rem; } /* même taille que les boutons du premier écran (23/11/2026) */
}
/* planche sans modèle 3D (ajoutée dans l'atelier, 23/11/2026) : sa photo, sans les commandes de la 3D */
.photo-seule :is(.showroom__aide, .showroom__vues) { display: none; }
/* Fiche : la couleur de la page suit le coloris choisi, en fondu (27/11/2026). --neon enregistrée comme couleur pour pouvoir la faire glisser. */
@property --neon { syntax: '<color>'; inherits: true; initial-value: #e6ff00; }
body.fiche-coloris { transition: --neon .45s ease; }
body.coloris-fonce .btn:not(.btn--ghost) { background: var(--c-klein); border-color: var(--c-klein); color: #fff; }
@media (prefers-reduced-motion: reduce) { body.fiche-coloris { transition: none; } }
/* Accueil, téléphone : le bouton de chaque planche à sa couleur (27/11/2026) ; Klein : vrai bleu, texte blanc */
.planches-video__carte .btn { background: var(--accent); border-color: var(--accent); color: #000; }
.planches-video__carte[data-couleur=klein] .btn { color: #fff; }
/* Fiche en Bleu Klein : pied de page et grand nom dans le même bleu que les boutons (le bleu éclairci des textes ne va pas
   en aplat), textes du pied en blanc (27/11/2026) */
body.coloris-fonce .pied { background: var(--c-klein); }
body.coloris-fonce .grand-nom { color: var(--c-klein); }
body.coloris-fonce .pied :is(a, .eyebrow, h2, .lead), body.coloris-fonce .pied .contact-card { color: #fff; }
body.coloris-fonce .pied .contact-card { border-color: #fff; }
body.coloris-fonce .pied :is(.contact-card small, .pied__legal), body.coloris-fonce .pied__legal { color: rgb(255 255 255 / .85); }
body.coloris-fonce .pied .contact-card:hover { background: #fff; color: var(--c-klein); }
body.coloris-fonce .pied .contact-card:hover small { color: rgb(0 47 167 / .8); }
