/* =====================================================================
   KOS VISUAL — styles du site (index.html + presentation.html)
   ---------------------------------------------------------------------
   Fond noir, texte blanc, typo Geist, un seul accent : le bleu (--blue).
   Les couleurs, tailles et vitesses générales sont réglées dans :root.

   SOMMAIRE (Ctrl+F sur le titre en majuscules)
     RÉGLAGES (:root) · BASE · NAV · BOUTONS · VISEUR (curseur, équerres,
     timeline) · ACCUEIL · APERÇU · INTRO · DOSSIER · PAGE PROJET ·
     LECTEUR · FENÊTRES (contact, Ayn Studio) · PRÉSENTATION ·
     CARTE TEXTE · INDEX DES ÉCRANS · VIDÉOS SOUS LES ÉCRANS · PAGE D'ERREUR
   ===================================================================== */

/* RÉGLAGES */

:root {
  --bg: #000000;
  --fg: #ffffff;
  --dim: rgba(255, 255, 255, .58);
  --faint: rgba(255, 255, 255, .26);
  --line: rgba(255, 255, 255, .14);
  --panel: #0d0d0d;
  --blue: #2743e3;

  --font: 'Geist', 'Helvetica Neue', Arial, sans-serif;
  --gutter: clamp(16px, 2.6vw, 36px);
  --nav-h: 84px;
  --focus: clamp(96px, 8.5vw, 136px);

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io: cubic-bezier(.7, 0, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); color-scheme: dark; }
html:has(dialog[open]) { overflow: hidden; }
body {
  margin: 0;
  background: var(--bg); color: var(--fg);
  font-family: var(--font); font-size: 15px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img, video, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 1px solid var(--fg); outline-offset: 4px; }
::selection { background: var(--blue); color: #fff; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.icon { width: 1em; height: 1em; flex: none; }
.num { font-variant-numeric: tabular-nums; }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } }
@keyframes inLeft { from { opacity: 0; transform: translateX(-28px); } }
@keyframes inRight { from { opacity: 0; transform: translateX(36px); } }

/* --------------------------------------------------------------- nav */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50;
  height: var(--nav-h);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 14px var(--gutter) 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, .8), rgba(0, 0, 0, 0));
}
.nav-left { display: flex; gap: 22px; justify-self: start; align-items: center; }
.nav-right { display: flex; gap: 8px; justify-self: end; align-items: center; }
.nav-link { font-size: 13px; color: var(--dim); transition: color .2s ease; }
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--fg); }
.nav-logo { justify-self: center; display: block; }
.nav-logo img { height: 28px; width: auto; }
.nav-studio {
  display: inline-flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 14px 0 16px; border-radius: 999px;
  background: var(--fg); color: var(--bg);
  font-size: 13px; font-weight: 500;
  transition: background-color .2s ease, color .2s ease;
}
.nav-studio:hover { background: var(--blue); color: #fff; }
.nav-studio .icon { width: 10px; height: 10px; }
.nav-menu-btn, .nav-panel { display: none; }
.nav-panel-cats { display: contents; }

@media (max-width: 720px) {
  .nav { grid-template-columns: auto 1fr auto; }
  .nav-left { display: none; }
  .nav-logo { grid-column: 1; grid-row: 1; justify-self: start; }
  .nav-logo img { height: 26px; }
  .nav-right { grid-column: 3; grid-row: 1; }
  .nav-menu-btn { display: inline-flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 40px; height: 40px; }
  .nav-menu-btn span { display: block; width: 18px; height: 1.5px; background: currentColor; transition: transform .25s ease; }
  .nav-menu-btn[aria-expanded="true"] span:first-child { transform: translateY(3.25px) rotate(45deg); }
  .nav-menu-btn[aria-expanded="true"] span:last-child { transform: translateY(-3.25px) rotate(-45deg); }
  .nav.is-open { background: var(--bg); }
  .nav-panel { position: fixed; top: var(--nav-h); left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; padding: 12px var(--gutter) 32px; background: var(--bg); overflow-y: auto; }
  .nav-panel[hidden] { display: none; }
  .nav-panel a, .nav-panel button { text-align: left; padding: 12px 0; font-size: 28px; letter-spacing: -.03em; border-bottom: 1px solid var(--line); }
  .nav-panel .n { font-size: 13px; color: var(--dim); vertical-align: super; margin-left: 6px; }
}

/* ------------------------------------------------------------ boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 42px; padding: 0 18px; border-radius: 999px;
  font-size: 14px; font-weight: 500; white-space: nowrap;
  transition: background-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.btn .icon { width: 12px; height: 12px; }
.btn-white { background: var(--fg); color: var(--bg); }
.btn-white:hover { background: var(--blue); color: #fff; }
.btn-line { box-shadow: inset 0 0 0 1px var(--faint); }
.btn-line:hover { box-shadow: inset 0 0 0 1px var(--fg); }

/* =====================================================================
   VISEUR — éléments communs
   ===================================================================== */
.dots {
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .55) 0 1px, transparent 1.5px);
  background-size: calc(100% / 8) calc(100% / 5);
  background-position: calc(100% / 16) calc(100% / 10);
  opacity: .5;
}
.brackets { position: absolute; pointer-events: none; }
.brackets::before, .brackets::after, .brackets > i::before, .brackets > i::after {
  content: ""; position: absolute; width: 14px; height: 14px; border: 0 solid var(--fg);
}
.brackets::before { top: 0; left: 0; border-top-width: 1px; border-left-width: 1px; }
.brackets::after { top: 0; right: 0; border-top-width: 1px; border-right-width: 1px; }
.brackets > i::before { bottom: 0; left: 0; border-bottom-width: 1px; border-left-width: 1px; }
.brackets > i::after { bottom: 0; right: 0; border-bottom-width: 1px; border-right-width: 1px; }

/* curseur de l'accueil : cadre de sélection à 4 poignées (comme dans Figma) */
.selbox {
  position: absolute; width: var(--focus); height: var(--focus);
  border: 1px solid rgba(255, 255, 255, .7); border-radius: 6px;
  pointer-events: none;
  transition: opacity .4s ease;
}
.selbox > b { position: absolute; width: 5px; height: 5px; margin: -3px 0 0 -3px; background: var(--fg); border-radius: 50%; }
.selbox > b:nth-child(1) { left: 0; top: 0; }       .selbox > b:nth-child(2) { left: 100%; top: 0; }
.selbox > b:nth-child(3) { left: 100%; top: 100%; } .selbox > b:nth-child(4) { left: 0; top: 100%; }
.selbox-label { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; font-size: 12px; }
.selbox-label .plus { display: inline-flex; width: 18px; height: 18px; align-items: center; justify-content: center; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--fg); }
.selbox-label .plus .icon { width: 9px; height: 9px; }

/* timeline (règle graduée + tête de lecture) */
.ruler { position: relative; height: 34px; --p: 0%; }
.ruler-ticks, .ruler-fill { position: absolute; left: 0; bottom: 0; height: 8px; background: repeating-linear-gradient(90deg, var(--c) 0 1px, transparent 1px 9px); }
.ruler-ticks { right: 0; --c: var(--faint); }
.ruler-ticks::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 15px; background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .45) 0 1px, transparent 1px 90px); }
.ruler-fill { width: var(--p); --c: var(--fg); }
.ruler-head { position: absolute; left: var(--p); bottom: 0; width: 1px; height: 26px; background: var(--blue); }
.ruler-head::before { content: ""; position: absolute; top: -4px; left: -4px; width: 9px; height: 9px; background: var(--blue); border-radius: 2px; }
.ruler-marks { position: absolute; left: 0; right: 0; top: 0; height: 14px; }
.ruler-mark { position: absolute; top: 0; display: inline-flex; gap: 6px; font-size: 11px; color: var(--dim); white-space: nowrap; transition: color .2s ease; }
.ruler-mark:hover, .ruler-mark[aria-current="true"] { color: var(--fg); }

/* =====================================================================
   ACCUEIL — diaporama plein écran + aperçu en carrousel
   ===================================================================== */
/* une seule page : l'accueil (reel) et le dossier (desk) se relaient */
html.view-home, html.view-home body { overflow: hidden; }
.reel { position: fixed; inset: 0; z-index: 1; height: 100svh; min-height: 560px; overflow: hidden; background: var(--bg); touch-action: none; transition: opacity .5s ease; }
html.view-desk .reel:not(.is-under) { opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .5s ease, visibility 0s linear .5s; }
.reel.is-under { z-index: 1; }
.desk[hidden] { display: none !important; }
.desk { position: relative; z-index: 2; transition: opacity .4s ease; }
.desk.is-prep { opacity: 0; pointer-events: none; }
.stage-media.is-waiting, .desk.is-leaving .stage-media { opacity: 0; }
/* le visuel qui voyage d'une vue à l'autre */
.flyer { position: fixed; z-index: 45; overflow: hidden; background: var(--panel); pointer-events: none; }
.flyer > img, .flyer > video, .flyer > canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: none !important; animation: none !important; transition: none !important; }
.stage-media > canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* grain de pellicule, très léger, sur tout le site */
.grain {
  position: fixed; inset: -50%; z-index: 60; pointer-events: none; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}
@keyframes grain { 0% { transform: translate(0, 0); } 20% { transform: translate(-3%, 2%); } 40% { transform: translate(2%, -4%); } 60% { transform: translate(-4%, -2%); } 80% { transform: translate(3%, 4%); } 100% { transform: translate(0, 0); } }

/* lumière d'ambiance : le visuel en cours, très flouté, derrière tout */
.ambient { position: fixed; inset: -10%; z-index: -1; pointer-events: none; opacity: .32; filter: blur(70px) saturate(1.3); transition: opacity .8s ease; }
.ambient > * { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: fadeIn 1s ease both; }
.ambient > :not(:last-child) { animation: none; }
.ov-track { touch-action: pan-x; }
.stage { touch-action: pan-y; }
.strip { position: relative; }
.slide { position: absolute; inset: 0; display: block; opacity: 0; visibility: hidden; transition: opacity 1s ease, visibility 0s linear 1s; }
.slide.is-active { opacity: 1; visibility: visible; transition: opacity 1s ease, visibility 0s; z-index: 1; }
.slide-media { position: absolute; inset: 0; overflow: hidden; transform-origin: 50% 50%; will-change: transform; }
.slide-media img, .slide-media video { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 2.4s var(--ease-out); }
.slide.is-active .slide-media img, .slide.is-active .slide-media video { transform: scale(1); }
.slide-shade { position: absolute; inset: 0; pointer-events: none; transition: opacity .5s ease; background: linear-gradient(to top, rgba(0, 0, 0, .78), rgba(0, 0, 0, 0) 52%), linear-gradient(to bottom, rgba(0, 0, 0, .55), rgba(0, 0, 0, 0) 22%); }
.slide-info { position: absolute; z-index: 2; left: var(--gutter); right: var(--gutter); bottom: calc(34px + 44px); display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.slide-title { margin: 0; font-size: clamp(64px, 11vw, 188px); font-weight: 400; letter-spacing: -.055em; line-height: .86; overflow: hidden; padding: 0 .04em .2em 0; margin: 0 0 -.14em -.05em; }
.slide-title span { display: block; transform: translateY(130%); transition: transform 1.1s var(--ease-out) .15s; }
.slide.is-active .slide-title span { transform: none; }
/* sortie vers un dossier : le titre redescend, le visuel rejoint le cadre */
.reel.is-leaving .slide-title span { transform: translateY(130%); transition: transform .55s var(--ease-io); }
.reel.is-leaving .slide-shade { opacity: 0; transition: opacity .3s ease; }


.hud { position: absolute; inset: 0; z-index: 3; pointer-events: none; transition: opacity .4s ease; }
.hud .selbox { left: 0; top: 0; transform: translate3d(calc(50vw - var(--focus) / 2), calc(50svh - var(--focus) / 2), 0); will-change: transform; }
.reel.is-leaving .hud .selbox { opacity: 0; }

/* horloges Paris / Tunis au format timecode (les images défilent en bleu) */
.clock { display: inline-flex; align-items: baseline; gap: 18px; font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11px; letter-spacing: .02em; color: var(--dim); white-space: nowrap; font-variant-numeric: tabular-nums; }
.clock i { font-style: normal; margin-right: 7px; }
.clock b { font-weight: 400; color: var(--fg); }
.clock em { font-style: normal; color: var(--blue); }
.desk-foot .clock { padding-bottom: 6px; }
.proj-clock { position: fixed; z-index: 6; right: var(--gutter); bottom: 18px; opacity: 0; transition: opacity .4s ease .2s; }
.proj.is-in .proj-clock { opacity: 1; }
@media (max-width: 720px) {
  .clock span + span { display: none; }
}

/* le cadre de sélection remplace le curseur sur l'accueil */
.reel.has-cursor, .reel.has-cursor .slide { cursor: none; }
.reel.has-cursor .ruler-mark, .reel.has-cursor .ov-card { cursor: pointer; }
.reel.is-ctrl .hud .selbox, .reel.is-away .hud .selbox { opacity: 0; }
.slide-media { transition: transform 1.8s var(--ease-out); }
.reel.is-revealing .slide.is-active .slide-media { transform: scale(1.12); transition: none; }
.reel .ruler { position: absolute; z-index: 4; left: var(--gutter); right: var(--gutter); bottom: 20px; }
.reel.is-leaving .ruler { opacity: 0; transition: opacity .3s ease; }

/* aperçu (carrousel) */
.overview { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .45s ease, visibility 0s linear .45s; }
.reel.is-overview .overview { opacity: 1; visibility: visible; transition: opacity .45s ease, visibility 0s; }
.reel.is-overview .slide.is-active:not(.is-morph) { opacity: 0; visibility: hidden; transition: none; }
.slide.is-morph { z-index: 5; opacity: 1; visibility: visible; transition: none; }
.slide.is-morph .slide-info, .slide.is-morph .slide-shade, .reel.is-overview .slide-info { opacity: 0; transition: opacity .25s ease; }
.reel.is-overview .slide-info { opacity: 0; pointer-events: none; }
.ov-track {
  --card: clamp(240px, 30vw, 470px);
  display: flex; gap: clamp(16px, 2vw, 30px); align-items: flex-start;
  overflow-x: auto; overflow-y: hidden; scrollbar-width: none;
  padding: 0 calc(50vw - var(--card) / 2);
  scroll-snap-type: x mandatory;
}
.ov-track::-webkit-scrollbar { display: none; }
.ov-track.is-wheeling { scroll-snap-type: none; }
.ov-card { flex: none; width: var(--card); scroll-snap-align: center; text-align: left; }
.ov-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--panel); transform-origin: 0 0; }
.ov-media img, .ov-media video { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out), opacity .3s ease; pointer-events: none; }
.ov-card:hover .ov-media img, .ov-card:hover .ov-media video { transform: scale(1.04); }
.ov-card:not(.is-focus) .ov-media img, .ov-card:not(.is-focus) .ov-media video { opacity: .55; }
.ov-label { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13px; color: var(--dim); }
.ov-label b { color: var(--fg); font-weight: 400; font-size: 16px; letter-spacing: -.01em; }
.reel.is-overview .ov-card { animation: ovIn .8s var(--ease-out) both; animation-delay: calc(.12s + var(--k, 0) * 60ms); }
.reel.is-overview .ov-card.is-origin { animation: none; }
.reel.is-overview .ov-card.is-origin .ov-label { animation: fadeIn .5s ease .45s both; }
@keyframes ovIn { from { opacity: 0; transform: translateX(var(--from, 60px)); } }

/* =====================================================================
   INTRO (1re visite) : le logo s'écrit au centre, le chargement se remplit
   dessous, puis le rideau noir remonte sur l'accueil
   ===================================================================== */
.boot { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: #000; cursor: pointer; }
.boot-center { display: flex; flex-direction: column; align-items: center; gap: clamp(26px, 4vh, 40px); transition: opacity .4s ease, transform .6s var(--ease-out), filter .4s ease; }
.boot.is-out .boot-center { opacity: 0; transform: translateY(-12px); filter: blur(6px); }
/* le logo se dessine de gauche à droite, comme une signature */
.boot-logo { width: clamp(170px, 18vw, 270px); height: auto; opacity: 0; }
.boot.is-ready .boot-logo { animation: signIn 1.3s var(--ease-io) .1s both; }
@keyframes signIn { from { clip-path: inset(0 100% 0 0); opacity: .3; } to { clip-path: inset(0 -4% 0 0); opacity: 1; } }
.mono { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11px; letter-spacing: .02em; }
/* chargement en petits carrés */
.boot-progress { display: flex; align-items: center; gap: 14px; color: var(--dim); opacity: 0; }
.boot.is-ready .boot-progress { opacity: 1; animation: fadeIn .6s ease .4s both; }
.boot-squares { display: flex; gap: 3px; }
.boot-squares i { width: 6px; height: 6px; box-shadow: inset 0 0 0 1px var(--faint); transition: background-color .15s ease; }
.boot-squares i.on { background: var(--fg); box-shadow: none; }
html.is-booting .nav { opacity: 0; }
.boot-done .nav { animation: fadeIn .8s ease .5s both; }

@media (max-width: 720px) {
  .slide-info { bottom: calc(34px + 90px); }
  .ruler-mark .t { display: none; }
  .ov-track { --card: 72vw; }
}

/* =====================================================================
   DOSSIER — table de visionnage
   ===================================================================== */
.desk {
  height: 100svh; min-height: 600px;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(0, 4.4fr) minmax(96px, 128px);
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 0 clamp(20px, 3vw, 48px);
  padding: calc(var(--nav-h) + 16px) var(--gutter) 20px;
  overflow: hidden;
}
.desk-side { display: flex; flex-direction: column; justify-content: center; gap: 36px; min-width: 0; }
.back { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; color: var(--dim); transition: color .2s ease; position: absolute; z-index: 2; top: calc(var(--nav-h) + 4px); left: var(--gutter); }
.back:hover { color: var(--fg); }
.back .ic, .proj-back .ic { display: inline-flex; width: 26px; height: 26px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--faint); align-items: center; justify-content: center; }
.back .icon, .proj-back .icon { width: 10px; height: 10px; }
.cats { display: flex; flex-direction: column; gap: 4px; }
.cats a { display: inline-flex; align-items: center; gap: 10px; font-size: clamp(18px, 1.6vw, 24px); letter-spacing: -.02em; color: var(--faint); transition: color .2s ease; }
.cats a:hover { color: var(--dim); }
.cats a[aria-current="page"] { color: var(--fg); }
.cats .n { display: inline-flex; min-width: 20px; height: 18px; padding: 0 5px; align-items: center; justify-content: center; border-radius: 3px; font-size: 11px; box-shadow: inset 0 0 0 1px currentColor; }
.cats a[aria-current="page"] .n { background: var(--fg); color: var(--bg); box-shadow: none; }
/* sous-dossiers du dossier ouvert (UI/UX : Gaming, Website, Application mobile) */
.subcats { display: grid; grid-template-rows: 0fr; width: min(100%, 230px); margin: -4px 0 0 4px; opacity: 0; transition: grid-template-rows .5s var(--ease-io), margin .5s var(--ease-io), opacity .3s ease; }
.subcats.is-open { grid-template-rows: 1fr; margin: 8px 0 12px 4px; opacity: 1; transition: grid-template-rows .6s var(--ease-out), margin .6s var(--ease-out), opacity .2s ease; }
.subcats-in { position: relative; min-height: 0; overflow: hidden; display: flex; flex-direction: column; gap: 1px; padding-left: 14px; }
/* le trait de l'arborescence se dessine de haut en bas */
.subcats-in::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 1px; background: var(--line); transform: scaleY(0); transform-origin: top; transition: transform .3s ease; }
.subcats.is-open .subcats-in::before { transform: none; transition: transform .7s var(--ease-out) .1s; }
.subcats button { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 5px 0; font-size: 13px; color: var(--dim); text-align: left; opacity: 0; transform: translateX(-14px); transition: color .2s ease, opacity .2s ease, transform .3s ease; }
.subcats.is-open button { opacity: 1; transform: none; transition: color .2s ease, opacity .45s ease calc(.15s + var(--j, 0) * 70ms), transform .6s var(--ease-out) calc(.15s + var(--j, 0) * 70ms); }
/* à l'entrée dans le dossier, le volet attend que la liste soit arrivée */
.desk.is-enter .subcats.is-open { transition-delay: .5s; }
.desk.is-enter .subcats.is-open .subcats-in::before { transition-delay: .6s; }
.desk.is-enter .subcats.is-open button { transition-delay: 0s, calc(.65s + var(--j, 0) * 70ms), calc(.65s + var(--j, 0) * 70ms); }
.subcats button .num { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11px; color: var(--faint); transition: color .2s ease; }
.subcats button:hover, .subcats button[aria-pressed="true"], .subcats button[aria-pressed="true"] .num { color: var(--fg); }
.subcats button[aria-pressed="true"]::before { content: ""; position: absolute; left: -14px; top: 50%; width: 1px; height: 16px; transform: translateY(-50%); background: var(--fg); }
.stage { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; min-width: 0; min-height: 0; }
.stage .dots { inset: 0 -20px; opacity: .3; }
.stage-box { position: relative; --ar: 16 / 9; --arn: 1.7778; width: min(100%, calc((100svh - var(--nav-h) - 190px) * var(--arn))); aspect-ratio: var(--ar); }
.stage-box .brackets { inset: -14px; }
.stage-media { position: absolute; inset: 0; overflow: hidden; background: var(--panel); border-radius: 2px; cursor: zoom-in; }
.stage-media::before, .proj-frame::before { content: "Chargement"; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: 12px; color: var(--faint); }
.stage-media img, .stage-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: shot .45s ease both; }
@keyframes shot { from { opacity: 0; transform: scale(1.025); } }
.stage-cap { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; width: min(100%, calc((100svh - var(--nav-h) - 190px) * var(--arn))); min-width: min(100%, 420px); }
.stage-cap .stage-title { font-size: clamp(22px, 2vw, 30px); letter-spacing: -.03em; }
.stage-title { margin: 0; font-size: 20px; font-weight: 400; letter-spacing: -.02em; }

.desk-strip { position: relative; min-height: 0; display: flex; flex-direction: column; justify-content: center; }
.strip { list-style: none; margin: 0; padding: 10px 6px; overflow-y: auto; scrollbar-width: none; display: flex; flex-direction: column; gap: 10px; max-height: 100%; -webkit-mask-image: linear-gradient(to bottom, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(to bottom, transparent, #000 8%, #000 92%, transparent); }
.strip::-webkit-scrollbar { display: none; }
.thumb { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; background: var(--panel); border-radius: 2px; opacity: .5; transition: opacity .25s ease; }
.thumb.is-portrait { aspect-ratio: 9 / 16; width: 56%; margin: 0 auto; }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.thumb:hover { opacity: .85; }
.thumb[aria-current="true"] { opacity: 1; outline: 1px solid var(--fg); outline-offset: 3px; }

.desk-foot { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto auto; align-items: end; gap: 28px; padding-top: 18px; }
.step { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--dim); padding-bottom: 6px; transition: color .2s ease; }
.step:hover { color: var(--fg); }
.step .icon { width: 10px; height: 10px; }
.desk-count { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--dim); padding-bottom: 6px; }
.desk-count b { color: var(--fg); font-weight: 400; }
.desk-count .bar { width: 32px; height: 1px; background: var(--faint); }
.desk-foot .ruler { min-width: 0; }
.desk-foot .ruler-head { transition: left .5s var(--ease-out); }
.desk-foot .ruler-fill { transition: width .5s var(--ease-out); }

/* entrée dans un dossier : la liste arrive de la gauche, les vignettes de la droite */
.desk.is-enter .back, .desk.is-enter .cats a { animation: inLeft .8s var(--ease-out) both; animation-delay: calc(.25s + var(--k, 0) * 70ms); }
.desk.is-enter .strip li { animation: inRight .8s var(--ease-out) both; animation-delay: calc(.2s + var(--k, 0) * 45ms); }
.desk.is-enter .stage-cap, .desk.is-enter .desk-foot { animation: fadeUp .7s var(--ease-out) .45s both; }
.desk.is-enter .stage-box .brackets { animation: bracketsIn .9s var(--ease-out) .05s both; }
.desk.is-enter .stage .dots { animation: fadeIn 1.2s ease .2s both; }
.desk.is-cold .stage-media { animation: reveal 1s var(--ease-io) both; }
@keyframes bracketsIn { from { opacity: 0; inset: -46px; } }
/* changement de dossier sans rechargement : l'image entre en volet, les vignettes glissent */
.desk.is-switch .stage-media > * { animation: wipeIn .75s var(--ease-io) both; }
.desk.is-switch .strip li { animation: inRight .7s var(--ease-out) both; animation-delay: calc(.12s + var(--k, 0) * 40ms); }
.desk.is-switch .stage-cap { animation: fadeUp .6s var(--ease-out) .25s both; }
@keyframes wipeIn { from { clip-path: inset(100% 0 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes reveal { from { clip-path: inset(50% 50% 50% 50%); } to { clip-path: inset(0 0 0 0); } }
.desk.is-leaving .back, .desk.is-leaving .desk-side, .desk.is-leaving .desk-strip, .desk.is-leaving .desk-foot, .desk.is-leaving .stage-cap, .desk.is-leaving .stage .dots, .desk.is-leaving .stage-box .brackets { opacity: 0; transition: opacity .3s ease; }

@media (max-width: 900px) {
  .desk > * { min-width: 0; }
  .stage .dots { inset: 0; }
  .desk { height: auto; min-height: 100svh; overflow: visible; overflow-x: clip; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; gap: 22px; padding-top: calc(var(--nav-h) + 52px); }
  .back { top: calc(var(--nav-h) + 6px); }
  .desk-side { gap: 14px; justify-content: flex-start; }
  .cats { flex-direction: row; flex-wrap: wrap; gap: 6px 18px; }
  .cats a { font-size: 20px; }
  .subcats { order: 99; flex-basis: 100%; width: auto; margin: -6px 0 0; }
  .subcats.is-open { margin: 4px 0 0; }
  .subcats-in { flex-direction: row; flex-wrap: wrap; gap: 6px; padding: 0; }
  .subcats-in::before { display: none; }
  .subcats button { gap: 8px; padding: 6px 11px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
  .subcats button[aria-pressed="true"] { background: var(--fg); color: var(--bg); box-shadow: none; }
  .subcats button[aria-pressed="true"] .num { color: var(--bg); }
  .subcats button[aria-pressed="true"]::before { display: none; }
  .stage-box { width: 100%; }
  .stage-box.is-portrait-box { width: min(100%, 360px); }
  .stage-cap { width: 100%; min-width: 0; }
  .strip { flex-direction: row; overflow-x: auto; overflow-y: hidden; padding: 6px 4px; -webkit-mask-image: none; mask-image: none; }
  .thumb, .thumb.is-portrait { flex: none; width: 108px; margin: 0; }
  .thumb.is-portrait { width: 44px; }
  .desk-strip { order: 3; }
  .desk-foot { grid-template-columns: 1fr auto; padding-top: 0; padding-bottom: 8px; order: 4; }
  .desk-foot .ruler { display: none; }
  .desk-count { justify-content: center; }
}

/* =====================================================================
   PAGE PROJET — s'ouvre par-dessus le dossier et se fait défiler
   ===================================================================== */
.proj {
  position: fixed; inset: 0;
  width: 100vw; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: rgba(0, 0, 0, 0); color: var(--fg);
  overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain;
  transition: background-color .45s ease;
}
.proj::backdrop { background: transparent; }
.proj.is-in { background: #000; }
.proj-bar {
  position: sticky; top: 0; z-index: 5;
  height: var(--nav-h);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 0 var(--gutter);
  background: linear-gradient(to bottom, #000 55%, rgba(0, 0, 0, 0));
  opacity: 0; transition: opacity .4s ease .1s;
}
.proj.is-in .proj-bar { opacity: 1; }
.proj-back { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; color: var(--dim); justify-self: start; transition: color .2s ease; }
.proj-back:hover { color: var(--fg); }
.proj-steps { justify-self: end; display: flex; gap: 22px; }
.proj-progress { position: absolute; left: 0; bottom: 10px; height: 1px; width: var(--sp, 0%); background: var(--blue); }

/* colonne de gauche : les autres projets du dossier restent visibles */
.proj-layout { display: grid; grid-template-columns: clamp(170px, 15vw, 230px) minmax(0, 1fr); gap: 0 clamp(24px, 3.4vw, 60px); padding: 0 var(--gutter); max-width: 1760px; margin: 0 auto; }
.proj-rail { position: sticky; top: calc(var(--nav-h) + 8px); align-self: start; max-height: calc(100svh - var(--nav-h) - 24px); overflow-y: auto; scrollbar-width: none; padding: 6px 4px 24px; margin-left: -4px; animation: inLeft .8s var(--ease-out) .2s both; }
.proj-rail::-webkit-scrollbar { display: none; }
.rail-head { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 12px; margin-bottom: 8px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--dim); }
.rail-head b { color: var(--fg); font-weight: 400; }
.rail-head .num { white-space: nowrap; }
.rail-head b span { display: block; color: var(--dim); }
.rail-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.rail-item { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 12px; align-items: center; width: 100%; padding: 7px 0; text-align: left; color: var(--faint); transition: color .2s ease; }
.rail-item .rt { position: relative; width: 58px; aspect-ratio: 16 / 9; overflow: hidden; background: var(--panel); opacity: .45; transition: opacity .2s ease; }
.rail-item .rt img, .rail-item .rt video { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.rail-item b { display: block; font-size: 14px; font-weight: 400; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail-item span { display: block; font-size: 11px; }
.rail-item:hover { color: var(--dim); }
.rail-item:hover .rt { opacity: .8; }
.rail-item[aria-current="true"] { color: var(--fg); }
.rail-item[aria-current="true"] .rt { opacity: 1; outline: 1px solid var(--fg); outline-offset: 2px; }
.proj-main { min-width: 0; }
.proj-hero {
  display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 40px clamp(28px, 4vw, 72px); align-items: center;
  min-height: calc(100svh - var(--nav-h));
  padding: 0 0 56px;
}
.proj-text > * { opacity: 0; }
.proj.is-in .proj-text > * { opacity: 1; animation: fadeUp .8s var(--ease-out) both; animation-delay: calc(.3s + var(--k, 0) * 70ms); }
.proj.is-out .proj-text > *, .proj.is-out .proj-section, .proj.is-out .player, .proj.is-out .proj-fw > .brackets { opacity: 0; transition: opacity .25s ease; animation: none; }
.proj-title { margin: 0; font-size: clamp(46px, 6.4vw, 112px); font-weight: 400; letter-spacing: -.055em; line-height: .9; overflow-wrap: break-word; }
.proj-title.is-long { font-size: clamp(40px, 4.4vw, 80px); }
.proj-type { margin: 18px 0 0; font-size: 15px; color: var(--dim); max-width: 34ch; }
.proj-meta { margin: 34px 0 0; display: grid; max-width: 420px; }
.proj-meta div { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 13px; }
.proj-meta div:last-child { border-bottom: 1px solid var(--line); }
.proj-meta dt { color: var(--dim); }
.proj-meta dd { margin: 0; }
.proj-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 30px; }

.proj-visual { position: relative; min-width: 0; }
.proj-fw { position: relative; --ar: 16 / 9; --arn: 1.7778; width: min(100%, calc((100svh - var(--nav-h) - 170px) * var(--arn))); margin-left: auto; }
.proj-fw > .brackets { inset: -14px; }
.proj-fw.is-portrait { margin: 0 auto; }
.proj-frame { position: relative; aspect-ratio: var(--ar); width: 100%; background: var(--panel); overflow: hidden; transform-origin: 0 0; }
.proj-frame > img, .proj-frame > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.proj-frame .zoomable { cursor: zoom-in; }

/* lecteur vidéo aux couleurs du site */
.player {
  display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto auto; gap: 14px; align-items: center;
  width: 100%; margin-top: 18px;
  animation: fadeUp .7s var(--ease-out) .5s both;
}
.pl-btn { width: 34px; height: 34px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--faint); display: inline-flex; align-items: center; justify-content: center; transition: box-shadow .2s ease, background-color .2s ease; }
.pl-btn:hover { box-shadow: inset 0 0 0 1px var(--fg); }
.pl-btn .icon { width: 12px; height: 12px; }
.pl-time { font-size: 12px; color: var(--dim); min-width: 92px; }
.pl-time b { color: var(--fg); font-weight: 400; }
.pl-ruler { height: 28px; cursor: pointer; touch-action: none; }
.pl-ruler:focus-visible { outline-offset: 6px; }
.proj-frame video { cursor: pointer; }

/* comparateur avant / après (étalonnage) */
.compare-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--x, 50%)) 0 0); pointer-events: none; }
.compare-before video { width: 100%; height: 100%; object-fit: cover; }
/* sans fichier « avant » : rendu LOG simulé (désaturé, contraste écrasé, noirs relevés) */
.compare-before.is-sim video { filter: saturate(.32) contrast(.6) brightness(1.18) sepia(.12) hue-rotate(-8deg); }
.player.is-silent { grid-template-columns: auto auto minmax(0, 1fr) auto; }
.compare-line { position: absolute; top: 0; bottom: 0; left: var(--x, 50%); width: 1px; background: var(--fg); pointer-events: none; }
.compare-handle { position: absolute; top: 50%; left: var(--x, 50%); width: 38px; height: 38px; margin: -19px 0 0 -19px; border-radius: 50%; background: var(--fg); color: var(--bg); display: inline-flex; align-items: center; justify-content: center; cursor: ew-resize; touch-action: none; }
.compare-handle .icon { width: 16px; height: 16px; }
.compare-tag { position: absolute; top: 12px; font-size: 12px; padding: 3px 8px; border-radius: 3px; background: rgba(0, 0, 0, .55); pointer-events: none; }
.compare-tag.l { left: 12px; } .compare-tag.r { right: 12px; }

.proj-section { padding: clamp(40px, 6vw, 90px) 0 0; animation: fadeIn .8s ease .6s both; }
.proj-sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 16px; border-top: 1px solid var(--line); margin-bottom: clamp(24px, 3vw, 40px); }
.proj-sec-head h3 { margin: 0; font-size: clamp(22px, 2.2vw, 32px); font-weight: 400; letter-spacing: -.03em; }
.proj-sec-head span { font-size: 13px; color: var(--dim); }
.screens { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); align-items: start; }
.screen { margin: 0; }
.screen.is-land { grid-column: span 2; }
.screen-btn { position: relative; display: block; width: 100%; background: var(--panel); cursor: zoom-in; }
.screen.is-portrait .screen-btn { max-width: 520px; margin: 0 auto; }
.screen-btn img { width: 100%; height: auto; }
.screen figcaption { display: flex; justify-content: space-between; margin-top: 10px; font-size: 12px; color: var(--dim); }
.proj-end { height: clamp(60px, 8vw, 120px); }

.zoom { position: fixed; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; padding: var(--gutter); background: rgba(0, 0, 0, .96); cursor: zoom-out; animation: fadeIn .25s ease; }
.zoom img { max-width: 100%; max-height: 100%; object-fit: contain; }

@media (max-width: 900px) {
  .proj-hero { grid-template-columns: 1fr; min-height: 0; padding-top: 16px; }
  .proj-visual { order: -1; }
  .proj-fw { width: 100%; }
  .proj-fw.is-portrait { width: min(100%, 340px); margin: 0 auto; }
  .proj-fw > .brackets { inset: -10px; }
  .proj-bar { grid-template-columns: 1fr auto; }
  .proj-layout { grid-template-columns: minmax(0, 1fr); }
  .proj-rail { position: relative; top: 0; max-height: none; overflow: visible; padding: 0 0 8px; }
  .rail-head { display: none; }
  .rail-list { flex-direction: row; gap: 12px; overflow-x: auto; scrollbar-width: none; padding: 4px 2px; }
  .rail-item { grid-template-columns: 1fr; width: 104px; flex: none; gap: 6px; }
  .rail-item .rt { width: 100%; }
  .screens { grid-template-columns: 1fr; }
  .screen.is-land { grid-column: auto; }
  .player { grid-template-columns: auto auto minmax(0, 1fr) auto; }
  .pl-full { display: none; }
}

/* =====================================================================
   PRÉSENTATION — une fiche sur un seul écran : photo cadrée, nom, dossiers,
   trois infos, un bouton. Pas de long texte.
   ===================================================================== */
.idcard {
  position: relative; z-index: 0; isolation: isolate; overflow-x: clip;
  min-height: 100svh; max-width: 1560px; margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: center; gap: 40px clamp(40px, 6vw, 110px);
  padding: calc(var(--nav-h) + 24px) var(--gutter) 72px;
}
.idcard > .dots { opacity: .22; }
.id-photo { position: relative; margin: 0; justify-self: end; width: min(100%, calc((100svh - var(--nav-h) - 150px) * .8)); }
.id-photo .brackets { inset: -14px; animation: bracketsIn 1s var(--ease-out) .1s both; }
.id-photo-img { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--panel); animation: reveal 1.2s var(--ease-io) both; }
.id-photo-img img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); animation: idZoom 2.2s var(--ease-out) both; }
/* au survol, la 2e photo (en couleur) apparaît en fondu */
.id-photo-img img.is-alt { position: absolute; inset: 0; object-position: 72% 50%; opacity: 0; transition: opacity .8s ease; }
.id-photo:hover .id-photo-img img.is-alt { opacity: 1; }
@keyframes idZoom { to { transform: none; } }
.id-body > * { animation: fadeUp .9s var(--ease-out) both; animation-delay: calc(.35s + var(--k, 0) * 90ms); }
.id-name { margin: 0; font-size: clamp(64px, 9vw, 160px); font-weight: 400; letter-spacing: -.06em; line-height: .86; margin-left: -.04em; }
.id-eyebrow { margin: 0 0 18px; color: var(--dim); text-transform: uppercase; }
.id-role { margin: 22px 0 0; font-size: clamp(20px, 1.8vw, 26px); letter-spacing: -.02em; }
/* métiers : une ligne compacte, séparés par de fins traits */
.id-skills { display: flex; flex-wrap: wrap; gap: 6px 0; max-width: 560px; margin: 14px 0 0; padding: 0; list-style: none; font-size: 15px; color: var(--dim); }
.id-skills li { display: inline-flex; align-items: center; }
.id-skills li + li::before { content: ""; width: 1px; height: 12px; margin: 0 12px; background: var(--faint); }
/* 2e ligne : direction artistique, réalisation, caméra */
.id-skills li.is-br { flex-basis: 100%; height: 0; }
.id-skills li.is-br::before, .id-skills li.is-row::before { display: none; }
/* sur téléphone : les métiers en petites pastilles (pas de trait en début de ligne) */
@media (max-width: 720px) {
  .id-skills { gap: 6px; font-size: 13px; }
  .id-skills li { padding: 4px 10px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
  .id-skills li + li::before, .id-skills li.is-br { display: none; }
}
.id-folders { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.id-folders a { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--fg); transition: color .2s ease; }
.id-folders a:hover { color: var(--blue); }
.id-folders .n { font-size: 11px; color: var(--dim); font-family: 'Geist Mono', ui-monospace, monospace; }
.id-facts { margin: clamp(30px, 4.5vh, 50px) 0 0; max-width: 560px; }
.id-facts div { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 14px; }
.id-facts div:last-child { border-bottom: 1px solid var(--line); }
.id-facts dt { color: var(--dim); padding-top: 2px; }
.id-facts dd { margin: 0; }
.id-facts dd .mono { display: block; margin-top: 4px; color: var(--dim); line-height: 1.6; }
.id-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: clamp(28px, 4vh, 44px); }
.id-foot { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 22px; display: flex; justify-content: space-between; gap: 16px; color: var(--dim); }
.id-foot a:hover { color: var(--fg); }
@media (max-width: 900px) {
  .idcard { grid-template-columns: 1fr; align-items: start; padding-top: calc(var(--nav-h) + 28px); padding-bottom: 90px; }
  .id-photo { justify-self: start; width: min(100%, 340px); }
  .id-foot { position: static; grid-column: 1; margin-top: 12px; flex-wrap: wrap; }
}

/* ------------------------------------------------------------ contact */
/* panneau aux couleurs du site (noir, blanc, filets fins), angles droits, typo forte */
.sheet { --ink: var(--fg); --ink-dim: var(--dim); --ink-line: var(--line);
  width: min(460px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--line); border-radius: 0; background: var(--panel); color: var(--ink); }
.sheet[open] { animation: sheetIn .35s var(--ease-out); }
.sheet::backdrop { background: rgba(0, 0, 0, .6); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
@keyframes sheetIn { from { opacity: 0; transform: translateY(14px); } }
.sheet-inner { position: relative; padding: clamp(24px, 4vw, 30px); }
.sheet-x { position: absolute; top: 20px; right: 20px; width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; color: var(--ink); }
.sheet-x .icon { width: 12px; height: 12px; }
.sheet-kicker { margin: 0 0 10px; font-size: 11px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-dim); }
.sheet-title { margin: 0; font-size: clamp(40px, 9vw, 52px); font-weight: 600; letter-spacing: -.035em; line-height: .95; text-transform: uppercase; }
.sheet-lead { margin: 12px 0 0; max-width: 34ch; font-size: 15px; line-height: 1.45; color: var(--ink-dim); }
/* lignes de liens : libellé | valeur | flèche */
.sheet-list { display: flex; flex-direction: column; margin-top: 22px; border-bottom: 1px solid var(--ink-line); }
.sheet-row { display: grid; grid-template-columns: 104px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 17px 4px; border-top: 1px solid var(--ink-line); transition: background-color .2s ease; }
.sheet-row:hover { background: rgba(255, 255, 255, .04); }
.sheet-label { font-size: 11px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-dim); }
.sheet-row b { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-row .go { width: 11px; height: 11px; }
/* bouton blanc carré (Ayn Studio), bleu au survol */
.sheet-cta { display: inline-flex; align-items: center; gap: 16px; margin-top: 24px; padding: 15px 18px; background: var(--fg); color: var(--bg); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; transition: background-color .2s ease; }
.sheet-cta:hover { background: var(--blue); color: #fff; }
.sheet-cta .go { width: 11px; height: 11px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0s !important; transition-duration: 1ms !important; transition-delay: 0s !important; }
}

/* =====================================================================
   CARTE TEXTE (projet « Bientôt », ou projet index sans couverture)
   ===================================================================== */
.tcard { position: absolute; inset: 0; container-type: inline-size; display: grid; grid-template-rows: auto 1fr auto; padding: 4.5% 5%; background: var(--panel); color: var(--fg); text-align: left; overflow: hidden; }
.stage-media .tcard { animation: shot .45s ease both; }
/* grille fine en fond */
.tcard::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .7;
  background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
  background-size: 6cqw 6cqw; background-position: center; }
.tcard > * { position: relative; }
.tcard .tcard-row { display: flex; justify-content: space-between; gap: 12px; font-size: max(10px, 1.45cqw); color: var(--dim); text-transform: uppercase; }
.tcard .tcard-body { display: flex; flex-direction: column; justify-content: center; gap: 2.2cqw; }
.tcard .tcard-title { display: block; font-size: 13cqw; line-height: .88; letter-spacing: -.055em; font-weight: 400; white-space: nowrap; }
.tcard .tcard-sub { display: block; font-size: 3.4cqw; letter-spacing: -.02em; color: var(--dim); }
/* version miniature (vignettes, liste des projets) */
.tcard.is-small { padding: 0 8%; }
.tcard.is-small::before { background-size: 14cqw 14cqw; }
.tcard.is-small .tcard-row, .tcard.is-small .tcard-sub { display: none; }
.tcard.is-small .tcard-body { grid-row: 1 / -1; }
.tcard.is-small .tcard-title { font-size: 19cqw; letter-spacing: -.04em; }
.tcard.is-small.is-soon .tcard-sub { display: block; font-size: 9cqw; margin-top: 3cqw; }
/* bouton inactif (projet « Bientôt ») */
.btn:disabled { opacity: .4; cursor: default; pointer-events: none; }

/* =====================================================================
   INDEX DES ÉCRANS (applications mobiles : Netflix, Vestij)
   la liste en haut de la page projet, chaque ligne descend vers son écran ;
   tous les écrans sont affichés côte à côte en dessous
   ===================================================================== */
.pindex { width: 100%; }
.pindex-head { display: flex; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid var(--line); color: var(--dim); text-transform: uppercase; animation: fadeIn .6s ease .25s both; }
.pindex ol { list-style: none; margin: 0; padding: 0; }
.pindex li { border-bottom: 1px solid var(--line); animation: fadeUp .7s var(--ease-out) both; animation-delay: calc(.35s + var(--k, 0) * 90ms); }
.pindex-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto 14px; align-items: center; gap: 16px; width: 100%; padding: 20px 0; text-align: left; color: var(--dim); transition: color .25s ease, padding .45s var(--ease-out); }
.pindex-row b { font-weight: 400; font-size: clamp(16px, 1.5vw, 22px); letter-spacing: -.025em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pindex-row .mono { color: var(--faint); transition: color .25s ease; }
.pindex-row .icon { width: 12px; height: 12px; opacity: 0; transition: opacity .25s ease; }
.pindex-row:hover { color: var(--fg); padding-left: 12px; }
.pindex-row:hover .mono { color: var(--dim); }
.pindex-row:hover .icon { opacity: 1; }
.screens.is-phones { grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); align-items: start; }
.screens.is-phones .screen.is-land { grid-column: auto; }
.screens.is-phones .screen.is-portrait .screen-btn { max-width: none; }
/* marge quand un bouton fait défiler la page projet jusqu'à une section */
.proj .proj-section, .proj .screen { scroll-margin-top: 80px; }
@media (max-width: 900px) { .screens.is-phones { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* =====================================================================
   VIDÉOS SOUS LES ÉCRANS (clips, projets liés en vidéo)
   en grand, l'une après l'autre ; chargées seulement à l'approche
   ===================================================================== */
.clips { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(16px, 2vw, 28px); }
.clip { margin: 0; }
.clip-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--panel); border-radius: 2px; }
.clip-frame video { width: 100%; height: 100%; object-fit: contain; cursor: zoom-in; }
.clip figcaption { display: flex; justify-content: space-between; margin-top: 10px; font-size: 12px; color: var(--dim); }

/* message si JavaScript est désactivé */
.noscript { position: fixed; inset: auto 0 40px; text-align: center; color: var(--fg); }

/* =====================================================================
   PAGE D'ERREUR (404.html) : comme l'intro, le logo s'écrit au centre,
   une ligne en dessous et un lien vers l'accueil
   ===================================================================== */
.err { min-height: 100svh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: clamp(22px, 3.5vh, 34px); padding: var(--gutter); text-align: center; }
.err-logo { width: clamp(170px, 18vw, 270px); height: auto; animation: signIn 1.3s var(--ease-io) .1s both; }
.err-line { margin: 0; color: var(--dim); text-transform: uppercase; animation: fadeIn .6s ease .9s both; }
.err-link { font-size: 13px; color: var(--fg); border-bottom: 1px solid var(--faint); padding-bottom: 2px; transition: border-color .2s ease; animation: fadeIn .6s ease 1.1s both; }
.err-link:hover { border-color: var(--fg); }