/* Maquette privée — Dagan B. — lieu « L'appartement », univers Récit, tonalité ocre et matière.
   Chaux chaude et brun de terre pour la page, bleu profond (le sien) pour les actions. Police : Literata, une police de livre. */
:root {
  --bg: #ebe4db;
  --surface: #e0d5c8;
  --ink: #2b1b12;
  --muted: #6b5444;
  --bleu: #1f3a64;
  --bleu-fort: #2a4d82;
  --bleu-ink: #f5f1ec;
  --papier: #faf7f2;
  --papier-ink: #2b1b12;
  --sombre: #2b1b12;
  --sombre-2: #3a271b;
  --sombre-ink: #f1ebe3;
  --sombre-muted: #c9b39c;
  --fil: #a5342a;

  --step-small: clamp(0.875rem, 0.85rem + 0.1vw, 0.9375rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.05rem + 0.7vw, 1.625rem);
  --step-head: clamp(2.1rem, 1.4rem + 3vw, 4rem);
  --step-display: clamp(2.6rem, min(5.6vw, 10vh), 5.75rem);

  --m: clamp(16px, 2.4vw, 36px);
  --gap: clamp(120px, 13vw, 200px);
  --ease-out: cubic-bezier(.2, .7, .2, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --ease-soft: cubic-bezier(.25, .1, .25, 1);
  --t-press: 120ms;
  --t-hover: 200ms;

  --serif: 'Literata', 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--serif); font-size: var(--step-body); line-height: 1.55;
  font-optical-sizing: auto; overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, figure, dl, dd, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--bleu-fort); outline-offset: 3px; }
::selection { background: var(--bleu); color: var(--bleu-ink); }
em { font-style: italic; }

.head { font-size: var(--step-head); font-weight: 400; line-height: 1.02; letter-spacing: -0.02em; }
.lead { font-size: var(--step-lead); line-height: 1.42; }
.card-title { font-size: var(--step-head); font-weight: 400; line-height: 1.08; letter-spacing: -0.01em; }

/* Liens et boutons */
.link { text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); text-underline-offset: 0.22em; text-decoration-thickness: 0.07em; transition: text-decoration-color var(--t-hover) ease; }
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px; font: inherit; font-size: var(--step-body); line-height: 1;
  border: 0; border-radius: 0; cursor: pointer; text-decoration: none;
  transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease, color var(--t-hover) ease;
}
.button:active { transform: scale(0.97); }
.button--bleu { background: var(--bleu); color: var(--bleu-ink); }
.button--papier { background: var(--papier); color: var(--papier-ink); }
.button--sombre { background: var(--sombre-2); color: var(--sombre-ink); }
.button--clair { background: var(--surface); color: var(--ink); }
.button--full { width: 100%; min-height: 52px; }
.button--grand { min-height: 56px; padding: 0 34px; font-size: var(--step-lead); }
@media (hover: hover) and (pointer: fine) {
  .link:hover { text-decoration-color: var(--fil); }
  .button--bleu:hover { background: var(--bleu-fort); }
  .button--papier:hover { background: #ffffff; }
  .button--sombre:hover { background: #4a3324; }
  .button--clair:hover { background: #dcc8b1; }
}

/* Barre */
.bar { position: absolute; z-index: 10; inset: 0 0 auto 0; display: flex; align-items: center; gap: 28px; padding: clamp(16px, 2.4vw, 36px) var(--m); }
.wordmark { font-size: var(--step-lead); text-decoration: none; margin-right: auto; font-weight: 500; }
/* La signature de Dagan B. (le logo de son site, tracé tel quel), à l'encre sombre sur le fond clair de l'en-tête */
.wordmark img { height: clamp(48px, 4vw, 64px); width: auto; margin-block: -8px; } /* le dessin occupe environ 60 % de sa boîte */
.bar-links { display: flex; gap: 26px; }
.bar-links .link { text-decoration-color: transparent; }
.bar-links .link, .salle-menu .link { white-space: nowrap; }
.bar-action { min-height: 44px; }

/* 1. Le vestibule */
html:not(.js) [data-js] { display: none !important; }
.vestibule {
  min-height: 100vh; /* taste-skill-ignore : repli avant svh */ min-height: 100svh;
  display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: center;
  padding: clamp(96px, 14vh, 140px) var(--m) clamp(40px, 7vh, 72px);
}
.vest-texte { grid-column: 1 / 8; }
.vest-titre { font-size: var(--step-display); font-weight: 400; line-height: 0.98; letter-spacing: -0.022em; }
.vest-phrase { margin: clamp(24px, 4vh, 40px) 0 0; max-width: 34ch; font-size: var(--step-lead); }
.vest-phrase p { line-height: 1.36; text-wrap: pretty; }
.vest-signature { margin-top: 12px; font-size: var(--step-small); color: var(--muted); }
.vest-note { font-size: var(--step-small); color: var(--muted); margin-top: 12px; }
.vest-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 30px; margin-top: clamp(30px, 5vh, 52px); }
.vest-oeuvre { grid-column: 8 / 13; width: 100%; display: grid; gap: 12px; justify-items: end; }
.vest-cadre { width: 100%; display: flex; justify-content: flex-end; }
.vest-cadre img { width: auto; height: auto; max-width: 100%; max-height: calc(100svh - 210px); }
.vest-oeuvre figcaption { font-size: var(--step-small); color: var(--muted); text-align: right; }
@media (prefers-reduced-motion: no-preference) {
  .vest-titre { animation: arrivee 700ms var(--ease-out) both; }
  .vest-phrase { animation: arrivee 800ms 120ms var(--ease-out) both; }
  @keyframes arrivee { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
}

/* 2. L'appartement en 3D */
.hero { position: relative; height: 420vh; /* taste-skill-ignore : repli avant svh */ height: 420svh; background: var(--sombre); }
.hero-pin { position: sticky; top: 0; height: 100vh; /* taste-skill-ignore : repli avant svh */ height: 100svh; min-height: 560px; overflow: hidden; }
@media (prefers-reduced-motion: reduce) { .hero { height: auto; } }
.hero-stage { position: absolute; inset: 0; }
.hero-fallback, .hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-fallback { object-fit: cover; }
.hero-canvas { opacity: 0; transition: opacity 900ms var(--ease-soft); }
.hero.is-live .hero-canvas { opacity: 1; }


/* La porte d'un appartement ancien : deux battants de bois sombre, à panneaux moulurés */
.battants { position: absolute; inset: 0; z-index: 2; pointer-events: none; display: grid; grid-template-columns: 1fr 1fr; }
.battant { position: relative; display: block; background: #4a2f1f; transition: transform 80ms linear; }
.battant::before, .battant::after { content: ''; position: absolute; left: 14%; right: 14%; background: #573823; outline: 10px solid #432a1b; outline-offset: -10px; }
.battant::before { top: 8%; height: 50%; }
.battant::after { top: 64%; height: 28%; }
.poignee { position: absolute; top: 52%; width: 14px; height: 14px; border-radius: 50%; background: #c49a5a; }
.battant--g .poignee { right: 26px; }
.battant--d .poignee { left: 26px; }
.battant--g { transform: translateX(calc(var(--ouverture, 0) * -100%)); }
.battant--d { transform: translateX(calc(var(--ouverture, 0) * 100%)); }
.hero.is-open .battants { visibility: hidden; }
html:not(.js) .battants { display: none; }
@media (prefers-reduced-motion: reduce) { .battants { display: none; } }

.salle-bar {
  position: absolute; z-index: 4; left: 0; right: 0; top: 0;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px clamp(16px, 2.4vw, 36px); background: var(--sombre); color: var(--sombre-ink);
}
.salle-titre { font-size: var(--step-lead); font-weight: 400; line-height: 1.2; }
.salle-piece { color: var(--sombre-muted); font-style: italic; }
.salle-menu { display: flex; gap: 22px; margin-left: auto; }
.salle-menu-tel { display: none; position: relative; }
.salle-menu-tel summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; }
.salle-menu-tel:not([open]) nav { display: none; }
.salle-menu-tel[open] nav { position: absolute; right: 0; top: 100%; z-index: 6; display: grid; gap: 12px; min-width: 190px; padding: 14px 18px; background: var(--sombre); }
.salle-cmd { display: flex; gap: 10px; flex-wrap: wrap; }
/* Écrans moyens (portables) : le menu se replie pour que la barre tienne sur une ligne */
@media (max-width: 1680px) and (min-width: 1001px) {
  .salle-menu { display: none; }
  .salle-menu-tel { display: block; margin-left: auto; }
  .salle-titre { white-space: nowrap; }
  .salle-cmd { flex-wrap: nowrap; }
}
.salle-cmd .button { min-height: 44px; padding: 0 18px; }
.salle-aide {
  position: absolute; z-index: 3; left: 50%; bottom: var(--m); transform: translateX(-50%);
  background: var(--papier); color: var(--papier-ink); padding: 10px 16px;
  opacity: var(--aide, 0); pointer-events: none; white-space: nowrap;
}
.hero.is-near .salle-aide { opacity: 0; }

.passage {
  position: absolute; left: var(--m); bottom: calc(var(--m) + 8px);
  display: grid; gap: 4px; max-width: 36ch; pointer-events: none; visibility: hidden;
  background: var(--papier); color: var(--papier-ink); padding: 14px 20px 16px;
  opacity: var(--legende, 0); transform: translateY(calc((1 - var(--legende, 0)) * 12px));
}
.passage-piece, .cartel-piece { font-size: var(--step-small); color: var(--muted); }
.passage-titre { font-size: var(--step-lead); font-style: italic; line-height: 1.18; }
.passage-phrase { font-size: var(--step-small); font-style: italic; margin-top: 4px; }
.passage-phrase[hidden] { display: none; }
.hero.is-near .passage { opacity: 0; }
.encart-3d {
  position: absolute; z-index: 3; right: var(--m); bottom: calc(var(--m) + 8px); max-width: 30ch;
  font-size: var(--step-small); color: var(--sombre-ink); background: var(--sombre); padding: 10px 14px;
  opacity: var(--encart, 0); pointer-events: none;
}
.hero.is-near .encart-3d { opacity: 0; }

.cartel {
  position: absolute; z-index: 5; left: var(--m); bottom: var(--m);
  width: min(400px, calc(100% - 2 * var(--m)));
  background: var(--papier); color: var(--papier-ink); padding: 20px 24px 22px;
}
.cartel[hidden] { display: none; }
.cartel-titre { font-size: var(--step-lead); font-style: italic; line-height: 1.18; margin-top: 4px; }
.cartel-ligne { margin-top: 8px; }
.cartel-ligne, .passage-ligne { display: grid; gap: 1px; font-size: var(--step-small); line-height: 1.4; }
.cartel-ligne > span { display: block; }
/* La légende de passage (pendant la marche) dit la même chose que le cartel, en deux lignes au plus : elle ne couvre pas la toile. */
.passage-ligne { display: block; }
.passage-ligne > span + span::before { content: ' · '; }
.passage-ligne > span:nth-child(3) { white-space: nowrap; }
/* L'œuvre visée dans la 3D (souris) : un liseré clair, cerné de brun pour se lire sur tous les murs, et un mot dessous */
.survol { /* taste-skill-ignore : liseré de survol, un état et non un décor ; le cerne brun le rend lisible sur les murs clairs comme sombres */ position: absolute; z-index: 3; left: 0; top: 0; pointer-events: none; border: 2px solid rgba(250, 247, 242, 0.92); box-shadow: 0 0 0 1px rgba(43, 27, 18, 0.5); }
.survol[hidden] { display: none; }
.survol-tag { position: absolute; left: 50%; top: calc(100% + 8px); transform: translateX(-50%); padding: 4px 10px; background: var(--papier); color: var(--papier-ink); font-size: var(--step-small); line-height: 1.3; white-space: nowrap; }
@media (prefers-reduced-motion: no-preference) {
  .survol:not([hidden]) { animation: survol-in 180ms var(--ease-out); }
  @keyframes survol-in { from { opacity: 0; } to { opacity: 1; } }
}
.aide-doigt { display: none; }
@media (hover: none) { .aide-souris { display: none; } .aide-doigt { display: inline; } }
.cartel-phrase { margin-top: 8px; font-size: var(--step-small); font-style: italic; max-width: 36ch; }
.cartel-phrase[hidden] { display: none; }
.cartel-actions { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.cartel-actions .button { min-height: 44px; padding: 0 14px; font-size: var(--step-small); }
.capture .vestibule, .capture .bar, .capture .salle-bar, .capture .salle-aide, .capture .battants, .capture .encart-3d { display: none; }

/* 3. Œuvres : chaque série est un chapitre, avec son fond (tiré de la tonalité ocre et matière), sa phrase et sa mise en page */
.oeuvres { padding-top: var(--gap); }
.oeuvres-tete { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: end; padding: 0 var(--m); margin-bottom: clamp(64px, 8vw, 112px); }
.oeuvres-tete .head { grid-column: 1 / 7; }
.oeuvres-tete .lead { grid-column: 8 / 13; max-width: 34ch; }
.serie {
  --fond: var(--bg); --encre: var(--ink); --doux: var(--muted);
  background: var(--fond); color: var(--encre);
  display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: start;
  padding: clamp(96px, 11vw, 168px) var(--m);
  position: relative;
}
.serie--memoire { --fond: #231b16; --encre: #efe7dc; --doux: #c1ad97; }
.serie--amusement { --fond: #d8ae63; --encre: #2b1b12; --doux: #5b3f22; }
.serie--temps { --fond: #1b2b47; --encre: #eef0f3; --doux: #b8c3d4; }
.serie--etre { --fond: #ebe4db; --encre: #2b1b12; --doux: #6b5444; }
.serie--cadres { --fond: #6a3322; --encre: #f6ede3; --doux: #e2c6b1; }
.serie--afrique { --fond: #c6a586; --encre: #2b1b12; --doux: #553a28; }
.serie--erotico { --fond: #3b2431; --encre: #f4eaee; --doux: #d3b8c3; }
.serie--autres { --fond: #d6d0c6; --encre: #2b1b12; --doux: #5b4e44; }
.serie-nom { font-size: var(--step-display); font-weight: 400; line-height: 0.98; letter-spacing: -0.025em; }
.serie-phrase { font-size: var(--step-lead); font-style: italic; line-height: 1.35; margin-top: 16px; max-width: 28ch; }
.serie-sous { font-size: var(--step-small); color: var(--doux); margin-top: 14px; }
.serie-texte { margin-top: 18px; max-width: 34ch; }
.serie-oeuvres { display: grid; gap: clamp(28px, 3.5vw, 56px); }
.oeuvre { display: grid; gap: 12px; align-content: start; }
.oeuvre img { width: auto; max-width: 100%; height: auto; max-height: 76vh; }
.oeuvre figcaption { display: grid; gap: 2px; }
.o-titre { font-weight: 500; line-height: 1.3; }
.o-ligne { font-size: var(--step-small); color: var(--doux); }
.o-demande { font-size: var(--step-small); justify-self: start; margin-top: 4px; }
.provisoire { font-weight: 400; font-size: var(--step-small); color: var(--doux); font-style: italic; white-space: nowrap; }
.provisoire::before { content: '· '; }

/* A — La mémoire : le titre reste à gauche, les toiles s'alignent à droite sur une même ligne de base */
/* L'en-tête reste visible pendant qu'on regarde les toiles, puis s'arrête avant le mur de la série */
.mise-a .serie-col { grid-column: 1 / 5; align-self: stretch; }
.mise-a .serie-tete, .mise-c .serie-tete { position: sticky; top: 14vh; }
.mise-a .serie-oeuvres { grid-column: 5 / 13; grid-template-columns: 0.55fr 1fr 1.5fr; align-items: end; }
/* Sur ordinateur, aucun texte de série n'est seul : chaque présentation a une toile à côté d'elle.
   Sur tablette et téléphone, la série se lit d'un bloc et les toiles viennent sous le texte. */
@media (min-width: 1001px) {
  /* B — Amusement : le titre en grand, centré, au-dessus ; puis le texte à gauche des toiles, celle du milieu plus haute */
  .mise-b .serie-tete { display: contents; }
  .mise-b .serie-nom { grid-column: 1 / 13; grid-row: 1; text-align: center; }
  .mise-b .serie-phrase { grid-column: 3 / 11; grid-row: 2; justify-self: center; text-align: center; margin-bottom: clamp(56px, 6vw, 96px); }
  .mise-b .serie-corps { grid-column: 1 / 5; grid-row: 3; align-self: center; }
  .mise-b .serie-oeuvres { grid-column: 5 / 13; grid-row: 3; grid-template-columns: 1fr 1.2fr 1fr; align-items: center; justify-items: center; }
  /* D — Être : le texte à gauche de la grande toile, puis les trois autres en dessous, décalées */
  .mise-d .serie-tete { grid-column: 1 / 6; grid-row: 1; align-self: end; }
  .mise-d .serie-oeuvres { display: contents; }
  .mise-d .o-une { grid-column: 7 / 13; grid-row: 1; align-self: end; }
  .mise-d .o-deux { grid-column: 2 / 5; grid-row: 2; margin-top: clamp(64px, 7vw, 112px); }
  .mise-d .o-trois { grid-column: 6 / 10; grid-row: 2; align-self: end; }
  .mise-d .o-quatre { grid-column: 10 / 13; grid-row: 2; margin-top: clamp(64px, 7vw, 112px); }
  /* E — Cadres : la première toile à gauche du texte, puis les deux autres descendent en escalier */
  .mise-e .serie-tete { grid-column: 8 / 13; grid-row: 1; align-self: center; }
  .mise-e .serie-oeuvres { display: contents; }
  .mise-e .oeuvre:nth-child(1) { grid-column: 1 / 7; grid-row: 1; }
  .mise-e .oeuvre:nth-child(2) { grid-column: 3 / 8; grid-row: 2; margin-top: clamp(64px, 7vw, 120px); }
  .mise-e .oeuvre:nth-child(3) { grid-column: 8 / 13; grid-row: 2; margin-top: clamp(128px, 14vw, 240px); }
  /* G — Érotico-humoristique : le texte à gauche, la seule toile à droite, haute */
  .mise-g .serie-tete { grid-column: 1 / 6; grid-row: 1; align-self: center; }
  .mise-g .serie-oeuvres { grid-column: 7 / 12; grid-row: 1; justify-items: start; }
  /* H — Autres toiles : le texte à gauche, deux toiles décalées à droite */
  .mise-h .serie-tete { grid-column: 1 / 5; grid-row: 1; align-self: start; }
  .mise-h .serie-oeuvres { grid-column: 6 / 13; grid-row: 1; grid-template-columns: 1fr 1fr; align-items: start; }
  .mise-h .oeuvre:nth-child(2) { margin-top: clamp(96px, 10vw, 180px); }
}
.mise-b .o-haute img { max-height: 86vh; }
/* C — Le Temps : les toiles en grille à gauche, le texte à droite */
.mise-c .serie-oeuvres { grid-column: 1 / 9; grid-row: 1; grid-template-columns: 1fr 1fr; align-items: end; }
.mise-c .serie-col { grid-column: 10 / 13; grid-row: 1; align-self: stretch; }
/* F — Voyage africain : le titre à gauche, une grande toile au centre, deux plus petites à droite */
.mise-f .serie-tete { grid-column: 1 / 4; }
.mise-f .serie-oeuvres { grid-column: 4 / 13; grid-template-columns: 1.7fr 1fr; grid-template-rows: auto auto; }
.mise-f .o-une { grid-row: 1 / 3; align-self: center; }

/* Le mur de la série : les toiles sur une cimaise, à leurs tailles relatives réelles (1 cm = --cm), centrées sur
   une même ligne d'horizon, au-dessus d'un sol de parquet. L'œuvre courante est à gauche (épinglé) ou au centre (bande), sa légende à sa droite ;
   les voisines sont coupées par les bords de l'écran. Une ligne discrète en haut à gauche (série, nombre d'œuvres),
   les flèches et le compteur en bas à gauche. Sans JavaScript, le mur défile quand même (doigt, pavé tactile). */
.serie--memoire { --paroi: #3a2d24; --cimaise: #574435; --corde: #7a6553; --sol: #261c16; }
.serie--amusement { --paroi: #e6c587; --cimaise: #b58b45; --corde: #8a6534; --sol: #9c733a; }
.serie--temps { --paroi: #2a3f66; --cimaise: #435a86; --corde: #6479a0; --sol: #17233d; }
.serie--etre { --paroi: #f3eee7; --cimaise: #c9b9a5; --corde: #a8957e; --sol: #b9a68e; }
.serie--cadres { --paroi: #84452f; --cimaise: #a05a40; --corde: #b77a61; --sol: #52271a; }
.serie--afrique { --paroi: #dcc2a8; --cimaise: #a88968; --corde: #8f6f50; --sol: #957556; }
.serie--erotico { --paroi: #4b2f3e; --cimaise: #6b4859; --corde: #8d6b7c; --sol: #2a1820; }
.serie--autres { --paroi: #e4dfd7; --cimaise: #b5aa9b; --corde: #95897b; --sol: #8f8377; }
/* Le mur passe devant l'en-tête collant de la série quand on descend : il a son propre fond. */
.mur { grid-column: 1 / -1; position: relative; z-index: 2; margin-top: clamp(72px, 8vw, 128px); background: var(--fond); }
/* Seule l'œuvre courante montre sa légende ; les voisines, coupées au bord, restent muettes. */
.js .mur-item:not(.est-courant) .mur-cartel { opacity: 0; visibility: hidden; transition: opacity 200ms ease, visibility 0s 200ms; }
.js .mur-item.est-courant .mur-cartel { transition: opacity 260ms ease; }
.js .mur.glisse .mur-cartel { opacity: 0; visibility: hidden; transition: opacity 120ms ease, visibility 0s 120ms; }
/* La paroi va d'un bord à l'autre de l'écran. */
.mur-paroi {
  --cm: 2.6px; --cartel: 12rem; --haut: 96px; --sol-h: 64px;
  position: relative; margin-inline: calc(-1 * var(--m)); background: var(--paroi);
}
/* La cimaise, et le sol de parquet (une texture claire et transparente posée sur la couleur du sol de la série) */
.mur-paroi::before { content: ''; position: absolute; z-index: 1; left: 0; right: 0; top: var(--cim, 66px); height: 7px; background: var(--cimaise); pointer-events: none; }
.mur-paroi::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: var(--sol-h); border-top: 4px solid var(--cimaise); background: var(--sol) url('img/sol.png') repeat-x left top / auto 100%; pointer-events: none; }
.mur-titre { position: absolute; z-index: 2; left: var(--m); top: 22px; font-size: var(--step-small); font-weight: 400; line-height: 1.3; color: var(--doux); }
.mur-serie { color: var(--encre); font-style: italic; }
.mur-series { position: absolute; z-index: 2; right: var(--m); top: 18px; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0 28px; }
.mur-prec, .mur-passer { min-height: 44px; display: inline-flex; align-items: center; font-size: var(--step-small); color: var(--doux); }
@media (hover: hover) and (pointer: fine) { .mur-prec:hover, .mur-passer:hover { color: var(--encre); } }
.v-toute { pointer-events: auto; color: var(--encre); }
.mur-piste {
  display: flex; gap: calc(var(--cm) * 34); margin: 0; padding: 0 calc(50% - 7rem);
  overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scrollbar-width: none;
}
.mur-piste::-webkit-scrollbar { display: none; }
.mur-piste:focus-visible { outline-offset: -4px; }
.mur-item { position: relative; flex: none; width: calc(var(--w) * var(--cm) + 22px + var(--cartel)); height: calc(var(--haut) + 120 * var(--cm) + 36px + var(--sol-h)); }
.mur-toile { position: absolute; left: 0; top: calc(var(--haut) + (60 - var(--h) / 2) * var(--cm)); width: calc(var(--w) * var(--cm)); height: calc(var(--h) * var(--cm)); display: block; isolation: isolate; cursor: zoom-in; }
.mur-toile img { width: 100%; height: 100%; max-width: none; object-fit: cover; }
/* Le fil d'accrochage, de la cimaise au haut de la toile */
.mur-toile::before { content: ''; position: absolute; left: 50%; bottom: 100%; width: 2px; margin-left: -1px; height: calc(var(--haut) - var(--cim, 66px) - 7px + (60 - var(--h) / 2) * var(--cm)); background: var(--corde); }
/* L'ombre portée douce d'une toile accrochée : une forme sombre et floue, derrière elle */
.mur-toile::after { content: ''; position: absolute; z-index: -1; inset: 5% -1.5% -3.5% 3%; background: rgba(14, 8, 4, 0.36); filter: blur(12px); }
/* La légende à droite de la toile, calée sur son bord bas : titre, année, technique, dimensions */
.mur-cartel { position: absolute; left: calc(var(--w) * var(--cm) + 22px); width: var(--cartel); top: calc(var(--haut) + (60 + var(--h) / 2) * var(--cm)); transform: translateY(-100%); display: grid; gap: 2px; font-size: var(--step-small); line-height: 1.35; color: var(--doux); }
.mur-nom { color: var(--encre); font-weight: 500; }
.mur-nom .provisoire { font-weight: 400; }
/* La carte de fin, discrète, à la hauteur de l'horizon */
.mur-fin { position: relative; flex: none; width: 15rem; text-align: center; }
.mur-fin p { position: absolute; left: 0; right: 0; top: calc(var(--haut) + 52 * var(--cm)); font-size: var(--step-small); line-height: 1.4; color: var(--doux); text-wrap: balance; }
/* En bas à gauche : flèches et compteur */
.mur-nav { position: absolute; z-index: 2; left: var(--m); bottom: calc((var(--sol-h) - 44px) / 2); display: flex; align-items: center; gap: 4px; color: var(--encre); }
.mur-fleche { width: 44px; height: 44px; padding: 0; border: 0; background: none; color: inherit; font: inherit; font-size: var(--step-lead); line-height: 1; cursor: pointer; transition: transform var(--t-press) var(--ease-out), opacity var(--t-hover) ease; }
.mur-fleche:active { transform: scale(0.94); }
.mur-fleche:disabled { opacity: 0.35; cursor: default; transform: none; }
.mur-position { min-width: 3.4em; text-align: center; font-size: var(--step-small); font-variant-numeric: tabular-nums; }
@media (hover: hover) and (pointer: fine) {
  .mur-toile img { transition: opacity var(--t-hover) ease; }
  .mur-toile:hover img { opacity: 0.88; }
  .mur-fleche:not(:disabled):hover { opacity: 0.7; }
}

/* Sur ordinateur et tablette, le mur des chapitres est une scène épinglée de la hauteur de l'écran :
   le défilement vertical le fait glisser d'une œuvre à l'autre (environ 900 px par œuvre).
   Une toile de 120 cm y occupe environ 58 % de la hauteur de l'écran ; le sol en occupe 13 %. */
@media (min-width: 761px) {
  .js .serie .mur { height: calc((var(--arrets, 1) - 1) * var(--pas, 900px) + 100svh); }
  .js .serie .mur-epingle { position: sticky; top: 0; height: 100svh; overflow: hidden; margin-inline: calc(-1 * var(--m)); }
  /* L'œuvre courante est dans la partie gauche de l'écran, son cartel à sa droite ; l'œuvre suivante commence après
     le cartel, à un écart régulier compté de bord à bord (de l'ordre de la largeur du texte du cartel, jamais plus d'un cinquième de l'écran) :
     les tailles réelles sont gardées, et une grande œuvre suivante dépasse au bord droit. */
  .js .serie .mur-epingle .mur-paroi {
    margin-inline: 0; height: 100%;
    --gauche: var(--m); --cartel: clamp(12rem, 19vw, 18.5rem); --ecart: clamp(24px, 2.6vw, 44px);
    --espace: min(var(--cartel) * 0.7, 14vw); /* compté depuis la boîte du cartel, plus large que son texte */
    --cm: min(100svh * 0.58 / 120, (100vw - 2 * var(--gauche) - var(--ecart) - var(--cartel) - 40px) / 120);
    --sol-h: 13svh;
    --haut: calc((87svh - 120 * var(--cm)) / 2 + 30px);
  }
  .js .serie .mur-piste { overflow: visible; gap: var(--espace); padding: 0 0 0 var(--gauche); will-change: transform; }
  .js .serie .mur-item { height: 100%; }
  .js .serie .mur-item:not(.mur-fin) { width: calc(var(--w) * var(--cm) + var(--ecart) + var(--cartel)); }
  .js .serie .mur-epingle .mur-cartel { left: calc(var(--w) * var(--cm) + var(--ecart)); gap: 3px; }
  .js .serie .mur-epingle .mur-nom { font-size: var(--step-lead); font-weight: 400; font-style: italic; line-height: 1.2; margin-bottom: 8px; text-wrap: balance; }
  /* La carte de fin ne se montre qu'une fois arrivée au centre (au bord droit, elle serait coupée). */
  .js .serie .mur-fin p { transition: opacity 260ms ease; }
  .js .serie .mur-fin:not(.est-courant) p { opacity: 0; }
}

/* Le Kronaute du mur (kro.js), en folioscope : img/kro-folioscope.png est une planche de 7 cases de 234 × 382 px
   (de vrais Kronautes peints, détourés) ; dans chaque case, le bassin est à 134 px du bord gauche et le sol à 380 px
   du haut. kro.js ne fait que choisir la case (--image) et le sens (.kro-gauche). Debout, il mesure 316 px dans la
   planche ; à l'écran, 16 % de la hauteur moins 8 px : il reste sous le bas des toiles. */
.kro, .kro-sol, .kro-ombre { display: none; }
.kro { position: absolute; z-index: 2; width: calc(234 * var(--k)); height: calc(382 * var(--k)); pointer-events: none;
  background: url('img/kro-folioscope.png') no-repeat calc(var(--image, 0) * -234 * var(--k)) 0 / calc(7 * 234 * var(--k)) 100%;
  transform-origin: calc(134 * var(--k)) 100%; }
.kro-gauche { transform: scaleX(-1); } /* il remonte : retourné d'un coup, comme une page qu'on tourne */
/* Sur les murs sombres, un léger liseré clair détache ses traits peints du parquet. */
.serie--memoire .kro-mur, .serie--temps .kro-mur, .serie--cadres .kro-mur, .serie--erotico .kro-mur { filter: drop-shadow(0 0 1.5px rgba(236, 220, 194, 0.7)); } /* taste-skill-ignore : sans ce liseré, les traits bruns peints disparaissent sur les parquets sombres */
/* Son ombre au sol, douce, sous le bassin. */
.kro-ombre { position: absolute; z-index: 2; width: calc(150 * var(--k)); height: calc(24 * var(--k)); border-radius: 50%; background: rgba(20, 10, 4, 0.4); filter: blur(7px); pointer-events: none; }
/* Le parquet qui glisse avec le mur : une tuile de plus que l'écran, à la place de la texture fixe. */
.kro-sol { position: absolute; z-index: 1; left: 0; bottom: 0; height: calc(var(--sol-h) - 4px); pointer-events: none; background: url('img/sol.png') repeat-x left top / auto 100%; }
/* Il n'existe que sur le mur épinglé (ordinateur, tablette), sur le parquet, sous le cartel de l'œuvre : jamais devant
   une toile ni devant un texte. Ses pieds sont posés dans le parquet. */
@media (min-width: 761px) {
  .js .serie .mur-paroi.kro-on::after { background-image: none; }
  .js .serie .kro-sol { display: block; width: calc(100% + 4 * (var(--sol-h) - 4px)); }
  .js .serie .kro-mur, .js .serie .kro-ombre { display: block; --k: calc((16svh - 8px) / 316); }
  .js .serie .kro-mur { left: calc(40% - 134 * var(--k)); bottom: calc(var(--sol-h) * 0.4 - 2 * var(--k)); }
  .js .serie .kro-ombre { left: calc(40% - 75 * var(--k)); bottom: calc(var(--sol-h) * 0.4 - 12 * var(--k)); }
}

/* La grande image d'une œuvre : l'image et ses outils à gauche, la fiche à droite */
.visionneuse { border: 0; padding: 0; width: min(1240px, calc(100vw - 32px)); max-width: none; max-height: calc(100svh - 32px); overflow: auto; background: var(--papier); color: var(--papier-ink); }
.visionneuse::backdrop { background: rgba(26, 16, 10, 0.86); }
.v-corps { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 340px); }
.v-gauche { display: grid; grid-template-rows: auto auto; align-content: center; background: var(--sombre); container-type: inline-size; }
.v-scene { position: relative; height: min(74svh, 720px); }
/* L'œuvre entière, jamais recadrée : la case de la grille a la taille exacte du cadre (minmax(0, 1fr)), sinon elle
   grandit avec l'image et « max-height: 100% » ne retient plus rien. La loupe seule grossit. */
.v-cadre { position: absolute; inset: 0; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; padding: 20px; overflow: hidden; }
.v-image { max-width: 100%; max-height: 100%; width: auto; height: auto; }
.v-loupe-on .v-cadre { touch-action: none; }
/* La loupe : un rond qui suit directement le pointeur (aucun retard, aucun ressort) */
/* Le verre cerclé deux fois (sombre puis clair) pour se lire sur toutes les œuvres ; l'image grossie part du bord du cercle,
   si bien que le point grossi est exactement sous le pointeur. Le manche part en bas à gauche. */
.v-loupe { position: absolute; left: 0; top: 0; width: 180px; height: 180px; border-radius: 50%; border: 5px solid var(--sombre); outline: 2px solid var(--papier); background-repeat: no-repeat; background-origin: border-box; background-color: var(--sombre); pointer-events: none; will-change: transform; }
.v-loupe[hidden] { display: none; }
.v-loupe-manche { position: absolute; left: 50%; top: 50%; width: 12px; height: 50px; margin-left: -6px; border-radius: 4px; background: var(--sombre); outline: 2px solid var(--papier); transform-origin: 50% 0; transform: rotate(45deg) translateY(92px); }
/* Le grossissement, écrit sous le verre : il change à la molette, aux touches + et −, et aux boutons de la barre. */
.v-loupe-z { position: absolute; left: 50%; top: calc(100% + 10px); padding: 3px 9px; transform: translateX(-50%); background: var(--sombre); color: var(--sombre-ink); font-size: var(--step-small); line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
.v-loupe-on .v-cadre.vise { cursor: none; }
.v-cadre:focus-visible { outline: 2px solid var(--papier); outline-offset: -6px; }
/* La barre d'outils est calée sur l'œuvre (page.js donne la largeur de l'image) : même axe, ses deux groupes aux deux
   bords de l'image ; plus large que l'image seulement quand l'œuvre est très étroite. */
.v-outils { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; width: max-content; min-width: var(--image-w, 0px); max-width: calc(100% - 40px); margin-inline: auto; padding: 2px 0 20px; }
.v-groupe { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.v-groupe + .v-groupe { margin-left: auto; } /* replié sur deux lignes (téléphone, loupe active), il reste à droite */
/* Sur le fond sombre, des boutons du même brun, un ton plus clair : ils ne disputent pas l'œuvre. Un outil actif
   s'allume (papier, encre sombre). */
.v-outils .button { min-height: 44px; padding: 0 16px; font-size: var(--step-small); background: var(--sombre-2); color: var(--sombre-ink); }
.v-outils .button[aria-pressed="true"] { background: var(--papier); color: var(--papier-ink); }
@media (hover: hover) and (pointer: fine) { .v-outils .button:not([aria-pressed="true"]):hover { background: #4a3324; } }
.v-zoom { display: flex; align-items: center; gap: 4px; color: var(--sombre-ink); font-size: var(--step-small); font-variant-numeric: tabular-nums; }
.v-zoom[hidden] { display: none; }
.v-zoom .button { min-width: 44px; padding: 0; }
.v-zoom span { min-width: 3.2em; text-align: center; }
/* Voir au mur : l'œuvre à l'échelle sur un mur clair de salon, au-dessus d'un canapé de 2 m, à côté d'une personne
   de 1,70 m, avec ses cotes (page.js place tout en centimètres). */
.v-scene.au-mur { height: min(78svh, 780px, 100cqw * 0.62); }
.v-mur { position: absolute; inset: 0; overflow: hidden; background: #ece6dd; color: #4a3a2e; }
.v-mur[hidden] { display: none; }
.v-mur-sol { position: absolute; left: 0; right: 0; bottom: 0; height: var(--sol-px, 40px); background: #c4a785 url('img/sol.png') repeat-x left top / auto 100%; border-top: 5px solid #f7f2eb; }
.v-silhouette { position: absolute; fill: #b0a596; }
.v-canape { position: absolute; overflow: visible; }
.v-canape .c-dos { fill: #8e927e; } .v-canape .c-assise { fill: #858973; } .v-canape .c-coussin { fill: #9a9e89; }
.v-canape .c-bras { fill: #7d816c; } .v-canape .c-pied { fill: #4a3a2c; }
.v-mur-toile { /* taste-skill-ignore : l'ombre d'une toile accrochée, qui la détache du mur comme dans une pièce */ position: absolute; max-width: none; box-shadow: 2px 6px 14px rgba(43, 27, 18, 0.28); }
.v-cote { position: absolute; color: #4a3a2e; font-size: 0.8125rem; line-height: 1.2; font-variant-numeric: tabular-nums; }
.v-cote::before { content: ''; position: absolute; }
.v-cote--l { height: 9px; border-inline: 1px solid; }
.v-cote--l::before { left: 0; right: 0; top: 4px; border-top: 1px solid; } /* taste-skill-ignore : ligne de cote, une mesure */
.v-cote--l span { position: absolute; left: 50%; bottom: calc(100% + 3px); transform: translateX(-50%); white-space: nowrap; }
.v-cote--h { width: 9px; border-block: 1px solid; }
.v-cote--h::before { top: 0; bottom: 0; left: 4px; border-left: 1px solid; } /* taste-skill-ignore : ligne de cote, une mesure */
.v-cote--h span { position: absolute; left: calc(100% + 6px); top: 50%; transform: translateY(-50%); white-space: nowrap; }
.v-mur-legende { position: absolute; left: 16px; top: 12px; max-width: 36ch; font-size: 0.8125rem; line-height: 1.35; color: #5e4b3d; }
.v-fiche { display: grid; align-content: start; gap: 14px; padding: 32px 28px 28px; }
.v-serie { justify-self: start; font-size: var(--step-small); }
.v-titre { font-size: clamp(1.75rem, 1.2rem + 1.6vw, 2.6rem); font-weight: 400; font-style: italic; line-height: 1.1; letter-spacing: -0.01em; }
.v-donnees { display: grid; gap: 10px; margin-top: 8px; }
.v-donnees div { display: grid; grid-template-columns: 6.6em 1fr; gap: 10px; padding: 8px 12px; background: #f1ebe3; }
.v-donnees dt { color: var(--muted); font-size: var(--step-small); }
.v-donnees dd { margin: 0; font-size: var(--step-small); }
.v-hl { white-space: nowrap; }
.v-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.v-actions .button[hidden] { display: none; }
/* Le formulaire de demande, dans la fiche, sous ses données */
.v-demande { display: grid; gap: 6px; margin-top: 6px; padding-top: 14px; scroll-margin-top: 16px; }
/* Sur ordinateur, quand la fiche s'allonge (formulaire ouvert), l'œuvre reste à l'écran à côté d'elle. */
@media (min-width: 761px) {
  .v-corps { background: var(--sombre); }
  .v-fiche { background: var(--papier); }
  .v-gauche { position: sticky; top: 0; align-self: start; }
  .v-plein .v-gauche { position: static; }
}
.v-demande[hidden] { display: none; }
.v-demande-titre { font-size: var(--step-lead); font-weight: 400; line-height: 1.2; }
.v-demande-titre:focus { outline: none; }
.vd-oeuvre { display: grid; gap: 2px; margin-top: 6px; padding: 10px 14px; background: #f1ebe3; font-size: var(--step-small); color: var(--muted); }
.vd-oeuvre em { font-size: var(--step-body); color: var(--ink); }
.vd-boutons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.vd-boutons .button { margin-top: 0; }
.v-quitter { position: fixed; z-index: 2; top: 16px; right: 16px; min-height: 44px; font-size: var(--step-small); }
.v-quitter[hidden] { display: none; }
/* Sur téléphone, la fiche est longue : un « Fermer » reste toujours à portée du pouce, en haut à droite. */
.v-fermer-haut { display: none; }
/* La fiche de l'œuvre occupe tout l'écran ; on y descend vers les autres œuvres de la même série */
.visionneuse { width: 100vw; height: 100svh; max-width: none; max-height: none; margin: 0; overflow-y: auto; overscroll-behavior: contain; }
.v-scene { height: min(78svh, 780px, (100cqw - 40px) / var(--ratio, 1.4) + 40px); }
.v-suite { background: var(--fond, var(--bg)); color: var(--encre, var(--ink)); padding: clamp(48px, 6vw, 88px) var(--m) clamp(56px, 6vw, 96px); }
.v-suite-titre { font-size: var(--step-lead); font-weight: 400; line-height: 1.2; }
.v-suite-tete { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.v-suite-tete .v-toute { font-size: var(--step-small); }
.v-suite .mur { margin-top: 18px; }
.mur-ici { color: var(--encre); font-weight: 500; }
.cartel-actions .button--papier { background: var(--surface); }

/* Plein écran : l'image seule */
.visionneuse.v-plein { width: 100vw; height: 100svh; max-height: none; background: var(--sombre); }
.v-plein .v-corps { display: block; height: 100%; }
.v-plein .v-gauche { height: 100%; display: block; }
.v-plein .v-scene { height: 100%; }
.v-plein .v-outils, .v-plein .v-fiche, .v-plein .v-suite { display: none; }
.o-ouvre { cursor: zoom-in; }
@media (prefers-reduced-motion: no-preference) {
  .visionneuse[open] { animation: ouvre 280ms var(--ease-out); }
  .visionneuse[open]::backdrop { animation: voile 280ms ease; }
  @keyframes ouvre { from { opacity: 0; transform: translateY(14px) scale(0.985); } to { opacity: 1; transform: none; } }
  @keyframes voile { from { opacity: 0; } to { opacity: 1; } }
}


/* 4. Démarche : portrait, texte, atelier (portrait et atelier facultatifs) */
.histoire { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; row-gap: clamp(72px, 8vw, 128px); align-items: center; padding: var(--gap) var(--m) 0; }
.portrait { grid-column: 1 / 5; display: grid; gap: 10px; }
.portrait img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.portrait figcaption, .atelier figcaption { font-size: var(--step-small); color: var(--muted); }
.histoire-texte { grid-column: 6 / 13; display: grid; gap: 22px; }
.histoire-texte p:not(.lead) { max-width: 46ch; }
.histoire:not(:has(.portrait)) .histoire-texte { grid-column: 1 / 7; }
.histoire-oeuvre { grid-column: 8 / 13; display: grid; gap: 10px; }
.histoire-oeuvre img { width: 100%; height: auto; }
.histoire-oeuvre figcaption { font-size: var(--step-small); color: var(--muted); }
.histoire-cols { grid-column: 1 / 13; display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; row-gap: 28px; align-items: start; }
.histoire-col { display: grid; gap: 16px; align-content: start; }
.histoire-col:first-child { grid-column: 1 / 6; }
.histoire-col:nth-child(2) { grid-column: 7 / 12; }
.histoire-col p { max-width: 54ch; }
.col-titre { font-size: var(--step-lead); font-weight: 400; line-height: 1.2; }
.histoire-note { grid-column: 1 / 13; }
.atelier { grid-column: 1 / 13; display: grid; gap: 12px; }
.atelier img { width: 100%; max-height: 82vh; object-fit: cover; }

/* Emplacements à compléter (portrait, atelier) : un aplat calme qui dit ce qui manque, sans faux contenu */
.manque { display: grid; }
.manque-cadre { display: grid; align-content: center; justify-items: center; gap: 8px; padding: 32px; text-align: center; background: var(--surface); }
.manque-titre { font-size: var(--step-lead); font-style: italic; line-height: 1.25; }
.manque-texte { font-size: var(--step-small); color: var(--muted); max-width: 30ch; }
.manque--atelier { grid-column: 1 / 13; }
.manque--atelier .manque-cadre { aspect-ratio: 21 / 8; }
.manque--portrait .manque-cadre { aspect-ratio: 4 / 5; }
/* 4 bis. Qui suis-je ? : le portrait à gauche, la biographie à droite */
.qui { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: start; padding: var(--gap) var(--m) 0; }
.qui .manque--portrait { grid-column: 1 / 5; position: sticky; top: 14vh; }
.qui-texte { grid-column: 6 / 13; display: grid; gap: 22px; }
.qui-corps { display: grid; gap: 16px; }
.qui-corps p { max-width: 58ch; }
/* Le reste du parcours, sous la liste des expositions */
.cv { display: grid; gap: 10px; margin-top: 56px; }
.cv div { display: grid; grid-template-columns: 7.5em 1fr; gap: 12px; padding: 10px 14px; background: var(--surface); }
.cv dt { font-size: var(--step-small); color: var(--muted); }
.cv dd { margin: 0; font-size: var(--step-small); max-width: 52ch; }
/* La série sans images en ligne : citée après les chapitres, sans mur */
.oeuvres-coda { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; padding: clamp(72px, 8vw, 128px) var(--m); }
.oeuvres-coda > * { grid-column: 1 / 7; }
.oeuvres-coda > .coda-liste { grid-column: 8 / 13; grid-row: 1 / span 4; align-self: start; display: grid; gap: 6px; }
.coda-liste li { display: flex; justify-content: space-between; gap: 16px; padding: 10px 14px; background: var(--surface); }
.coda-liste span { font-size: var(--step-small); color: var(--muted); white-space: nowrap; }
/* Les mentions longues peuvent passer à la ligne */
.cv .ac, .row-text .ac, .qui-corps .ac, .serie-texte .ac, .serie-sous .ac { white-space: normal; }
.coda-nom { font-size: var(--step-head); font-weight: 400; line-height: 1.02; letter-spacing: -0.02em; }
.coda-texte { margin-top: 18px; max-width: 46ch; }

/* 5. Le livre : sur le brun de terre, la couverture jaune ressort */
.livre { margin-top: var(--gap); background: var(--sombre); color: var(--sombre-ink); display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: center; padding: var(--gap) var(--m) clamp(64px, 7vw, 112px); }
.livre-couv { grid-column: 1 / 7; }
.livre-texte { grid-column: 8 / 13; display: grid; gap: 20px; }
.livre-sous { color: var(--sombre-muted); font-size: var(--step-small); }
.livre-texte p { max-width: 40ch; }
.livre-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; margin-top: 8px; }
.livre .button--bleu { background: var(--papier); color: var(--papier-ink); }
@media (hover: hover) and (pointer: fine) { .livre .button--bleu:hover { background: #ffffff; } }
.livre-isbn { font-size: var(--step-small); color: var(--sombre-muted); }

/* 6. Mes expositions */
.list { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; padding: var(--gap) var(--m); }
.list-photo { grid-column: 1 / 6; position: sticky; top: 14vh; align-self: start; display: grid; }
.list-photo img { grid-area: 1 / 1; width: 100%; height: auto; max-height: 70vh; object-fit: contain; object-position: left top; opacity: 0; transition: opacity 300ms ease; }
.list-photo img.is-on { opacity: 1; }
.list-body { grid-column: 7 / 13; }
.list-body .head { margin-bottom: 44px; }
.row button {
  width: 100%; min-height: 58px; display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
  background: none; border: 0; padding: 14px 0; cursor: pointer; text-align: left;
  font: inherit; font-size: var(--step-lead); color: var(--muted); transition: color var(--t-hover) ease;
}
.row-year { font-size: var(--step-body); font-variant-numeric: tabular-nums; white-space: nowrap; }
.row.is-active button { color: var(--ink); }
.row.is-active .row-name { font-style: italic; }
.row-text { display: none; max-width: 40ch; padding: 0 0 18px; }
.row.is-active .row-text { display: block; }
@media (hover: hover) and (pointer: fine) { .row button:hover { color: var(--ink); } }

/* 7. Contact */
/* L'œuvre reste entière : à gauche, le formulaire à droite */
.contact { background: var(--surface); }
.contact-oeuvre img { width: 100%; height: auto; }
.contact { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: center; padding: var(--gap) var(--m) clamp(64px, 7vw, 112px); }
.contact-oeuvre { grid-column: 1 / 8; }
.visit { grid-column: 8 / 13; position: relative; background: var(--papier); color: var(--papier-ink); padding: 32px; display: flex; flex-direction: column; gap: 16px; }
.visit-mail { font-size: var(--step-lead); overflow-wrap: anywhere; }

/* Les marques « à confirmer » : une petite mention, jamais un code de source */
.ac { font-size: var(--step-small); font-style: normal; opacity: 0.75; white-space: nowrap; }
.ac::before { content: '('; }
.ac::after { content: ')'; }
.serie-note { font-size: var(--step-small); color: var(--doux, var(--muted)); margin-top: 14px; }
.o-phrase { font-size: var(--step-small); font-style: italic; max-width: 46ch; margin-top: 4px; }

/* Les Kronautes découpés dans La Vie (livre, pied de page) : petits, sur une carte claire, immobiles */
.livre-couv .kro-livre, .kro-fin { width: auto; max-width: none; background: var(--papier); padding: 10px 12px; }
.livre-couv { display: grid; }
.livre-couv .kro-livre { order: 2; justify-self: end; height: 96px; margin-top: 18px; }
.kro-fin { grid-column: 8 / 9; justify-self: end; align-self: end; height: 64px; }

/* 6. Vidéos */
.videos { padding: 0 var(--m); display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; row-gap: 44px; }
.videos .head { grid-column: 1 / 13; }
.video-carte { grid-column: 1 / 13; display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: end; }
.video-carte img { grid-column: 1 / 8; width: 100%; height: auto; }
.video-texte { grid-column: 9 / 13; display: grid; gap: 14px; justify-items: start; }
.video-titre { font-size: var(--step-lead); line-height: 1.25; }

/* Le formulaire de contact */
.formulaire { display: grid; gap: 6px; }
.formulaire label { font-size: var(--step-small); color: var(--muted); margin-top: 8px; }
.formulaire input, .formulaire select, .formulaire textarea { font: inherit; color: inherit; width: 100%; min-height: 46px; padding: 10px 12px; background: #f1ebe3; border: 0; border-bottom: 2px solid #b9a493; border-radius: 0; }
.formulaire textarea { resize: vertical; }
.formulaire input:focus-visible, .formulaire select:focus-visible, .formulaire textarea:focus-visible { outline: 2px solid var(--bleu); outline-offset: 2px; }
.formulaire .button { margin-top: 16px; }
.formulaire[hidden], .f-merci[hidden], .f-erreur[hidden] { display: none; }
.formulaire input[type="checkbox"], .formulaire input[type="radio"] { flex: none; width: 22px; height: 22px; min-height: 0; margin: 0; padding: 0; accent-color: var(--bleu); }
.formulaire [aria-invalid="true"] { border-bottom-color: #9b2c22; background: #f6e7e2; }
.f-erreur { font-size: var(--step-small); color: #9b2c22; }
.f-facultatif { color: var(--muted); }
.formulaire .f-accord { display: flex; align-items: flex-start; gap: 12px; margin-top: 14px; min-height: 44px; color: var(--ink); cursor: pointer; }
.f-accord input { margin-top: 2px !important; }
.f-choix { display: grid; gap: 6px; margin: 4px 0 0; padding: 0; border: 0; min-width: 0; }
.f-choix legend { padding: 0; margin-bottom: 6px; font-size: var(--step-small); color: var(--muted); }
.formulaire .f-option { display: flex; align-items: center; gap: 12px; min-height: 48px; margin: 0; padding: 6px 14px; background: #f1ebe3; color: var(--ink); font-size: var(--step-body); line-height: 1.3; cursor: pointer; transition: background-color var(--t-hover) ease; }
.formulaire .f-option:has(input:checked) { background: #e3d5c3; }
@media (hover: hover) and (pointer: fine) { .formulaire .f-option:hover { background: #eadfd2; } }
.f-merci { display: grid; gap: 12px; justify-items: start; padding: 20px; background: #f1ebe3; }
.f-merci:focus { outline: none; }
.f-merci-titre { font-size: var(--step-lead); font-style: italic; line-height: 1.25; }
.visit-ou { font-size: var(--step-small); }
.nowrap { white-space: nowrap; }

/* Pied de page */
.fin { background: var(--sombre); color: var(--sombre-ink); padding: clamp(96px, 10vw, 160px) var(--m) var(--m); display: grid; gap: clamp(48px, 6vw, 88px); }
.fin-haut { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: end; }
.fin-nom { grid-column: 1 / 8; font-size: var(--step-display); font-weight: 400; line-height: 1; letter-spacing: -0.025em; }
.fin-message { grid-column: 9 / 13; max-width: 36ch; }
.fin-cols { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; }
.fin-contact { grid-column: 1 / 6; display: grid; gap: 10px; font-size: var(--step-lead); }
.fin-nav { grid-column: 9 / 13; display: grid; gap: 10px; align-content: start; }
.fin-admin { font-size: var(--step-small); color: var(--sombre-muted); }
.imprint { max-width: 64ch; font-size: var(--step-small); color: var(--sombre-muted); }

/* Au doigt, chaque lien hors des phrases offre une cible d'au moins 44 px de haut. */
@media (pointer: coarse) {
  .bar-links .link, .vest-lien, .salle-menu-tel .link, .o-demande, .livre-actions .link, .fin-contact .link, .fin-nav .link,
  .fin-admin .link, .v-serie, .v-toute, .wordmark { display: inline-flex; align-items: center; min-height: 44px; }
  .salle-menu-tel[open] nav { gap: 0; }
  .fin-nav, .fin-contact { gap: 0; }
}

/* Rideau sur l'œuvre d'entrée et entrées des sections */
@media (prefers-reduced-motion: no-preference) {
  .js .serie { clip-path: inset(0 6% 0 6%); transition: clip-path 1000ms var(--ease-in-out); }
  .js .serie.is-in { clip-path: inset(0 0 0 0); }
  .js .serie .serie-nom { opacity: 0; transform: translateX(-40px); transition: opacity 800ms 250ms var(--ease-out), transform 900ms 250ms var(--ease-out); }
  .js .serie.is-in .serie-nom { opacity: 1; transform: none; }
  .js .serie .serie-phrase, .js .serie .serie-sous, .js .serie .serie-texte { opacity: 0; transition: opacity 700ms 500ms ease; }
  .js .serie.is-in .serie-phrase, .js .serie.is-in .serie-sous, .js .serie.is-in .serie-texte { opacity: 1; }
  .js .serie .oeuvre { opacity: 0; transform: translateY(28px); transition: opacity 700ms var(--ease-out), transform 800ms var(--ease-out); }
  .js .serie.is-in .oeuvre { opacity: 1; transform: none; }
  .js .serie.is-in .oeuvre:nth-child(2) { transition-delay: 120ms; }
  .js .serie.is-in .oeuvre:nth-child(3) { transition-delay: 240ms; }
  .js .serie.is-in .oeuvre:nth-child(4) { transition-delay: 360ms; }
}

.shutter { overflow: hidden; }
@media (prefers-reduced-motion: no-preference) {
  .js .shutter { clip-path: inset(0 0 100% 0); transition: clip-path 1100ms var(--ease-in-out); }
  .js .shutter img { transform: scale(1.08); transition: transform 1500ms var(--ease-soft); }
  .js .shutter.is-in { clip-path: inset(0); }
  .js .shutter.is-in img { transform: none; }
  .js [data-in] { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out); transition-delay: var(--d, 0ms); }
  .js [data-in].is-in { opacity: 1; transform: none; }
  .js [data-drift] img { transform: scale(1.06); transition: transform 6s var(--ease-soft); }
  .js [data-drift].is-in img { transform: scale(1); }
}

/* Tablette */
@media (max-width: 1000px) {
  .serie { display: block; }
  .serie .serie-tete, .mise-a .serie-tete, .mise-c .serie-tete { position: static; margin: 0 0 48px; text-align: left; justify-items: start; }
  .serie-oeuvres { grid-template-columns: 1fr 1fr !important; align-items: end; }
  .serie-oeuvres .oeuvre { grid-column: auto !important; grid-row: auto !important; margin-top: 0 !important; }
  .mise-d .o-une, .mise-f .o-une, .mise-a .o-large { grid-column: 1 / -1 !important; }
  .vestibule { display: block; padding-top: 104px; }
  .vest-oeuvre { margin-top: 48px; justify-items: start; }
  .vest-cadre { justify-content: flex-start; }
  .vest-oeuvre figcaption { text-align: left; }
  .livre { display: block; }
  .livre-texte { margin-top: 48px; max-width: 640px; }
  .salle-bar { flex-wrap: wrap; gap: 4px 12px; padding: 10px var(--m); }
  .salle-menu { display: none; }
  .salle-menu-tel { display: block; margin-left: auto; }
  .contact { display: block; }
  .visit { max-width: 560px; margin: 40px 0 0; }
  .mur-paroi { --cm: 2.5px; }
  .qui { display: block; }
  .qui .manque--portrait { position: static; max-width: 360px; margin-bottom: 48px; }
  .oeuvres-coda > *, .oeuvres-coda > .coda-liste { grid-column: 1 / -1; grid-row: auto; }
  .coda-liste { margin-top: 32px; }
  .bar-links { display: none; }
}

/* Téléphone : une composition à part */
@media (max-width: 760px) {
  .bar { gap: 12px; }
  .bar-links { display: none; }
  .bar-action { padding: 0 16px; }
  .vestibule { display: block; padding-top: 92px; }
  .vest-titre, .fin-nom, .serie-nom { font-size: clamp(2.3rem, 11vw, 3.2rem); }
  .serie-nom, .card-title { font-size: var(--step-head); }
  .salle-titre, .row button, .visit-mail { font-size: var(--step-lead); }
  .vest-oeuvre { margin-top: 40px; justify-items: start; }
  .vest-cadre { justify-content: flex-start; }
  .vest-cadre img { max-height: 62svh; }
  .vest-oeuvre figcaption { text-align: left; }
  .button--grand { width: 100%; }
  .salle-bar { flex-wrap: wrap; gap: 4px 12px; padding: 10px var(--m); }
  .salle-menu { display: none; }
  .salle-menu-tel { display: block; margin-left: auto; }
  .salle-cmd { width: 100%; }
  .salle-cmd .button { flex: 1; padding: 0 10px; font-size: var(--step-small); }
  .salle-aide { white-space: normal; width: calc(100% - 2 * var(--m)); text-align: center; bottom: 16px; }
  .passage { left: var(--m); right: var(--m); max-width: none; bottom: 16px; }
  .encart-3d { display: none; }
  .oeuvres-tete { display: block; }
  .oeuvres-tete .lead { margin-top: 18px; }
  .serie-oeuvres { grid-template-columns: 1fr !important; gap: 48px; }
  .oeuvre img { max-height: 70svh; }

  .histoire, .livre, .list { display: block; }
  .portrait { max-width: 320px; margin-bottom: 40px; }
  .atelier { margin-top: 56px; }
  .livre-texte { margin-top: 40px; }
  .list-photo { position: relative; top: auto; height: 36svh; overflow: hidden; display: block; margin-bottom: 28px; }
  .list-photo img { position: absolute; inset: 0; width: 100%; height: 100%; max-height: none; object-fit: contain; object-position: left center; }
  .list-photo img:not(.is-on) { visibility: hidden; }
  .visit { margin-top: 32px; padding: 24px; }
  .fin-haut, .fin-cols { display: block; }
  .fin-message { margin-top: 20px; }
  .kro-fin { display: block; margin-top: 28px; }
  .mur-paroi { --cm: 1.9px; --haut: 124px; --sol-h: 56px; --cim: 98px; } /* la cimaise descend sous les liens de série */
  .v-corps { grid-template-columns: 1fr; }
  .v-scene { height: min(62svh, (100cqw - 40px) / var(--ratio, 1.4) + 40px); } /* un portrait y garde une taille lisible, toujours entier */
  .v-fiche { padding: 22px 20px; }
  .v-fermer-haut { display: inline-flex; position: fixed; z-index: 3; top: 10px; right: 10px; min-height: 44px; padding: 0 16px; font-size: var(--step-small); }
  .v-plein .v-fermer-haut { display: none; }
  .mur-item { width: max(calc(var(--w) * var(--cm)), 11rem); }
  .mur-cartel { left: 0; width: auto; right: 0; top: calc(var(--haut) + (60 + var(--h) / 2) * var(--cm) + 12px); transform: none; }
  .mur-item { height: calc(var(--haut) + 120 * var(--cm) + 120px + var(--sol-h)); }
  .mur-piste { padding: 0 calc(50% - 7rem); }
  .histoire-cols { display: block; margin-top: 48px; }
  .histoire-oeuvre { margin-top: 40px; }
  .histoire-col + .histoire-col { margin-top: 44px; }
  .videos, .video-carte { display: block; }
  .videos .head { margin-bottom: 32px; }
  .video-texte { margin-top: 24px; }
  .fin-nav { margin-top: 32px; }
  .manque--atelier { margin-top: 56px; }
  .manque--atelier .manque-cadre { aspect-ratio: 4 / 3; }
  .qui .manque--portrait { max-width: 280px; }
  .cv div { grid-template-columns: 1fr; gap: 2px; }
  .mur-series { right: auto; left: var(--m); top: 46px; justify-content: flex-start; gap: 0 20px; }
  .v-scene.au-mur { height: min(70svh, 100cqw * 0.95); }
}
