/* Direction : cinéma, image d'abord. Typo large et étirée, interface presque invisible.
   Les valeurs ci-dessous sont des défauts : js/app.js les remplace avec les réglages. */
:root {
  --bg: #0c0d0e;
  --fg: #efede8;
  --muted: rgba(239, 237, 232, 0.62);
  --line: rgba(239, 237, 232, 0.22);
  --panel: rgba(18, 19, 21, 0.94);
  --font-head: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Inter Tight', 'Helvetica Neue', Arial, sans-serif;
  --head-weight: 650;
  --head-width: 118;
  --tracking: -0.025em;
  --nav-size: 14px;
  --name-size: 7vw;
  --shade: 0.38;
  --grain: 0.06;
  --f-cols: 3;
  --f-gap: 10px;
  --f-ratio: 16 / 9;
  --p-cols: 3;
  --p-gap: 16px;
  --gutter-l: max(20px, env(safe-area-inset-left, 0px));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px));
  color-scheme: dark;
}
:root.light {
  --bg: #ffffff;
  --fg: #121212;
  --muted: rgba(18, 18, 18, 0.55);
  --line: rgba(18, 18, 18, 0.18);
  color-scheme: light;
}

* { box-sizing: border-box; margin: 0; }
html { background: var(--bg); }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.45;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; }

.head {
  font-family: var(--font-head);
  font-weight: var(--head-weight);
  font-variation-settings: 'wdth' var(--head-width);
  letter-spacing: var(--tracking);
}

/* ---------- Barre de navigation ---------- */
.bar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: calc(18px + env(safe-area-inset-top, 0px)) var(--gutter-r) 18px var(--gutter-l);
  font-size: var(--nav-size);
  opacity: 0;
  animation: fadein 0.9s 0.9s ease forwards;
}
.bar .mark { font-family: var(--font-head); font-weight: 800; font-variation-settings: 'wdth' 125; letter-spacing: 0.02em; }
.bar nav { display: flex; gap: clamp(18px, 3vw, 40px); margin-left: auto; }
.bar nav a, .bar nav button { position: relative; padding-bottom: 3px; }
.bar nav a::after, .bar nav button::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform 0.35s ease;
}
.bar nav a[aria-current='page']::after { transform: scaleX(1); }
@media (hover: hover) { .bar nav a:hover::after, .bar nav button:hover::after { transform: scaleX(1); } }
.bar.on-photo { mix-blend-mode: normal; }
@keyframes fadein { to { opacity: 1; } }

/* ---------- Accueil ---------- */
.hero { position: fixed; inset: 0; background: #000; overflow: hidden; }
.hero video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s ease; }
.hero video.ready { opacity: 1; }
.hero .shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, rgba(0, 0, 0, calc(var(--shade) * 1.7)) 0%, rgba(0, 0, 0, 0) 42%),
    linear-gradient(to bottom, rgba(0, 0, 0, calc(var(--shade) * 0.8)) 0%, rgba(0, 0, 0, 0) 22%);
}
.grain {
  position: absolute; inset: -50%; pointer-events: none; opacity: var(--grain);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 0.8s steps(4) infinite;
}
.no-grain .grain { display: none; }
@keyframes grain {
  0% { transform: translate(0, 0); } 25% { transform: translate(-3%, 2%); }
  50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -1%); } 100% { transform: translate(0, 0); }
}
.hero-foot {
  position: absolute; inset: auto 0 0 0; z-index: 5;
  padding: 0 var(--gutter-r) calc(26px + env(safe-area-inset-bottom, 0px)) var(--gutter-l);
  display: grid; gap: clamp(10px, 1.4vw, 20px);
}
.hero-namewrap { width: 100%; overflow: hidden; padding-bottom: 0.06em; }
.hero-name {
  display: inline-block; white-space: nowrap; line-height: 0.95;
  font-size: var(--name-size);
  transform: translateY(105%); animation: rise 1.25s 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
.upper .hero-name, .upper .page-title, .upper .contact h2 { text-transform: uppercase; }
@keyframes rise { to { transform: translateY(0); } }
.hero-meta {
  display: flex; justify-content: space-between; align-items: baseline; gap: 20px; flex-wrap: wrap;
  opacity: 0; animation: fadein 1s 1.2s ease forwards;
}
.hero-role { font-family: var(--font-head); font-weight: 400; font-variation-settings: 'wdth' 80; font-size: clamp(18px, 2.2vw, 32px); letter-spacing: 0; }
.hero-right { display: flex; gap: clamp(16px, 3vw, 40px); align-items: baseline; font-size: var(--nav-size); }
.hero-right .tc { font-variant-numeric: tabular-nums; color: var(--muted); letter-spacing: 0.02em; min-width: 11ch; }
.hero-right a { border-bottom: 1px solid var(--line); padding-bottom: 2px; transition: border-color 0.3s; }
.hero-right a:hover { border-color: var(--fg); }
.progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: rgba(255, 255, 255, 0.12); z-index: 6; }
.progress i { display: block; height: 100%; width: 0; background: var(--fg); }
.no-progress .progress { display: none; }
.no-tc .tc { display: none; }

/* ---------- Pages Films / Photos ---------- */
.page { padding: calc(96px + env(safe-area-inset-top, 0px)) var(--gutter-r) 80px var(--gutter-l); opacity: 0; animation: fadein 0.7s 0.1s ease forwards; }
.page-head { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 16px 32px; margin-bottom: clamp(20px, 3vw, 40px); }
.page-title { font-size: clamp(40px, 8vw, 120px); line-height: 0.9; text-wrap: balance; }
.filters { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: var(--nav-size); }
.filters button { padding: 4px 0; color: var(--muted); border-bottom: 1px solid transparent; transition: color 0.2s, border-color 0.2s; }
.filters button:hover { color: var(--fg); }
.filters button[aria-pressed='true'] { color: var(--fg); border-color: var(--fg); }
.filters .n { font-variant-numeric: tabular-nums; opacity: 0.55; margin-left: 4px; font-size: 0.85em; }

.grid {
  display: grid; grid-template-columns: repeat(var(--f-cols), minmax(0, 1fr));
  gap: calc(var(--f-gap) * 1.6) var(--f-gap); grid-auto-flow: dense;
}
.card { position: relative; display: block; min-width: 0; text-align: left; }
.card.wide { grid-column: span 2; }
[data-fcols='1'] .card.wide { grid-column: span 1; }
[data-fcols='3'] .card.wide, [data-fcols='4'] .card.wide, [data-fcols='5'] .card.wide { grid-row: span 2; display: flex; flex-direction: column; }
[data-fcols='3'] .card.wide .media, [data-fcols='4'] .card.wide .media, [data-fcols='5'] .card.wide .media { flex: 1; aspect-ratio: auto; min-height: 28vw; }
.media { position: relative; overflow: hidden; background: #17181a; aspect-ratio: var(--f-ratio); }
.media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.7; filter: saturate(0.85); transform: scale(1.001); transition: opacity 0.5s ease, transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.5s ease; }
.card:hover .media video, .card:focus-visible .media video { opacity: 1; filter: none; transform: scale(1.045); }
.meta { padding-top: 10px; display: flex; justify-content: space-between; gap: 12px; align-items: baseline; font-size: 14px; }
.meta h3 { font-weight: 500; font-size: 15px; }
.meta p { color: var(--muted); font-size: 13px; white-space: nowrap; }
.title-over .meta { position: absolute; inset: auto 0 0 0; padding: 36px 14px 12px; background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent); color: #efede8; pointer-events: none; }
.title-over .meta p { color: rgba(239, 237, 232, 0.7); }
.title-hidden .meta { display: none; }
.empty { color: var(--muted); padding: 60px 0; }

.masonry { column-count: var(--p-cols); column-gap: var(--p-gap); }
.shot { break-inside: avoid; margin-bottom: var(--p-gap); display: block; width: 100%; overflow: hidden; position: relative; }
.shot.full { column-span: all; }
.shot img { width: 100%; display: block; transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1); }
.shot:hover img { transform: scale(1.025); }
.photo-count { color: var(--muted); font-size: var(--nav-size); font-variant-numeric: tabular-nums; }

/* ---------- Visionneuse ---------- */
.lb { position: fixed; inset: 0; z-index: 60; background: rgba(6, 7, 8, 0.96); color: #efede8; display: none; flex-direction: column; padding: calc(16px + env(safe-area-inset-top, 0px)) var(--gutter-r) calc(16px + env(safe-area-inset-bottom, 0px)) var(--gutter-l); }
.lb.open { display: flex; }
.lb-top { display: flex; justify-content: space-between; font-size: 14px; padding-bottom: 12px; }
.lb-stage { flex: 1; min-height: 0; display: grid; place-items: center; }
.lb-stage video, .lb-stage iframe, .lb-stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; }
.lb-stage iframe { width: min(100%, calc((100vh - 140px) * 16 / 9)); aspect-ratio: 16 / 9; border: 0; }
.lb-stage video { width: min(100%, calc((100vh - 140px) * 16 / 9)); }
.lb-bottom { display: flex; justify-content: space-between; gap: 16px; padding-top: 12px; font-size: 14px; color: rgba(239, 237, 232, 0.7); }
.lb-bottom strong { color: #efede8; font-weight: 500; }

/* ---------- Contact ---------- */
.contact { position: fixed; inset: 0; z-index: 50; background: rgba(8, 9, 10, 0.94); color: #efede8; display: none; align-items: end; padding: var(--gutter-l); padding-block: 40px; }
.contact.open { display: flex; }
.contact-in { width: 100%; max-width: 1100px; display: grid; gap: 28px; }
.contact h2 { font-size: clamp(34px, 7vw, 96px); line-height: 0.95; overflow-wrap: anywhere; }
.contact p { max-width: 46ch; color: rgba(239, 237, 232, 0.7); }
.contact-lines { display: grid; gap: 8px; font-size: 18px; }
.contact-lines a { border-bottom: 1px solid rgba(239, 237, 232, 0.3); width: fit-content; }
.contact-x { position: absolute; top: calc(18px + env(safe-area-inset-top, 0px)); right: var(--gutter-r); font-size: 14px; }
.copy { font-size: 13px; color: rgba(239, 237, 232, 0.6); margin-left: 12px; }

/* ---------- Mode édition ---------- */
.edit-pill { border: 0; cursor: pointer; position: fixed; z-index: 90; left: 50%; bottom: calc(14px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); padding: 8px 16px; border-radius: 99px; background: #efede8; color: #111; font-size: 13px; display: none; }
.editing .edit-pill { display: block; }
.panel {
  position: fixed; z-index: 80; top: 0; right: 0; bottom: 0; width: min(340px, 100vw);
  background: var(--panel); color: #efede8; border-left: 1px solid rgba(255, 255, 255, 0.12);
  overflow-y: auto; padding: calc(16px + env(safe-area-inset-top, 0px)) 16px 80px; display: none; font-size: 13px;
  backdrop-filter: blur(14px);
}
.editing .panel { display: block; }
.panel h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.panel .hint { color: rgba(239, 237, 232, 0.6); margin-bottom: 14px; }
.panel details { border-top: 1px solid rgba(255, 255, 255, 0.12); padding: 10px 0; }
.panel summary { cursor: pointer; font-weight: 600; padding: 2px 0; }
.panel .row { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center; margin-top: 10px; }
.panel .row label { color: rgba(239, 237, 232, 0.8); }
.panel .row output { font-variant-numeric: tabular-nums; color: rgba(239, 237, 232, 0.55); }
.panel .row > :nth-child(3), .panel .row.full > input, .panel .row.full > select { grid-column: 1 / -1; }
.panel input[type='range'] { width: 100%; accent-color: #efede8; }
.panel input[type='text'], .panel select, .panel textarea { width: 100%; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16); color: #efede8; border-radius: 6px; padding: 7px 9px; font: inherit; }
.panel input[type='color'] { width: 44px; height: 26px; padding: 0; border: 0; background: none; }
.panel .btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.panel .btn { background: #efede8; color: #111; border-radius: 6px; padding: 8px 12px; font-weight: 500; }
.panel .btn.ghost { background: transparent; color: #efede8; border: 1px solid rgba(255, 255, 255, 0.3); }
.panel textarea { height: 120px; margin-top: 10px; font-size: 11px; }
.toast { position: fixed; z-index: 95; left: 50%; bottom: calc(60px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: #efede8; color: #111; padding: 8px 14px; border-radius: 6px; font-size: 13px; display: none; }
.toast.show { display: block; }

.tools { position: absolute; z-index: 4; top: 8px; right: 8px; display: none; gap: 6px; }
.editing .tools { display: flex; }
.tools button { background: rgba(0, 0, 0, 0.72); color: #fff; border-radius: 6px; padding: 5px 9px; font-size: 12px; }
.editing .card, .editing .shot { cursor: grab; outline: 1px dashed rgba(128, 128, 128, 0.55); outline-offset: 3px; }
.dragging { opacity: 0.35; }
.drop-before { box-shadow: -6px 0 0 0 #efede8; }
.modal { position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, 0.6); display: none; align-items: center; justify-content: center; padding: 16px; }
.modal.open { display: flex; }
.modal .box { background: #17181a; color: #efede8; width: min(440px, 100%); max-height: 92vh; overflow-y: auto; border-radius: 10px; padding: 18px; font-size: 13px; }
.modal .row { display: grid; gap: 4px; margin-top: 10px; }
.modal input[type='text'], .modal select { width: 100%; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16); color: #efede8; border-radius: 6px; padding: 8px 10px; font: inherit; }
.modal .btns { display: flex; gap: 8px; margin-top: 16px; justify-content: space-between; }
.modal .btn { background: #efede8; color: #111; border-radius: 6px; padding: 8px 14px; font-weight: 500; }
.modal .btn.ghost { background: transparent; color: #efede8; border: 1px solid rgba(255, 255, 255, 0.3); }

/* ---------- Mobile ---------- */
/* Téléphone : ton choix de colonnes est respecté, plafonné à 2 pour rester lisible */
@media (max-width: 560px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  [data-fcols='1'] .grid { grid-template-columns: minmax(0, 1fr); }
  .grid .card.wide { grid-column: 1 / -1; grid-row: auto; display: block; }
  .grid .card.wide .media { aspect-ratio: var(--f-ratio); min-height: 0; }
  .masonry { column-count: 2; }
  [data-pcols='1'] .masonry { column-count: 1; }
  .hero-meta { gap: 8px; }
  .hero-right .tc { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .grain, .hero-name, .bar, .hero-meta, .page { animation: none; opacity: 1; transform: none; }
  .media video, .shot img { transition: none; }
}

.panel .panel-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; position: sticky; top: calc(-16px - env(safe-area-inset-top, 0px)); margin: calc(-16px - env(safe-area-inset-top, 0px)) -16px 8px; padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 12px; background: #121315; z-index: 2; }
.panel .panel-top h4 { margin: 0; }
.panel .where { font-weight: 400; color: rgba(239, 237, 232, 0.5); margin-left: 6px; font-size: 12px; }

.hero-play { position: absolute; z-index: 8; left: 50%; top: 50%; transform: translate(-50%, -50%); padding: 14px 28px; border-radius: 99px; background: rgba(0, 0, 0, 0.55); color: #efede8; border: 1px solid rgba(239, 237, 232, 0.5); font-size: 16px; backdrop-filter: blur(8px); }

/* ---------- Films : un projet par écran ---------- */
html.snap-page[data-snap='mandatory'] { scroll-snap-type: y mandatory; }
html.snap-page[data-snap='proximity'] { scroll-snap-type: y proximity; }
.bar-filters { display: flex; gap: clamp(14px, 2vw, 28px); font-size: var(--nav-size); }
.bar-filters button { padding-bottom: 3px; color: var(--muted); border-bottom: 1px solid transparent; transition: color 0.2s, border-color 0.2s; }
.bar-filters button:hover { color: var(--fg); }
.bar-filters button[aria-pressed='true'] { color: var(--fg); border-color: var(--fg); }

.slide { position: relative; height: 100vh; height: 100svh; height: 100dvh; overflow: hidden; cursor: pointer; scroll-snap-align: start; scroll-snap-stop: always; background: #000; }
.slide video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.9s ease; }
.slide video.ready { opacity: 1; }
.slide .shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, rgba(0, 0, 0, calc(var(--shade) * 2)) 0%, rgba(0, 0, 0, 0) 48%),
    linear-gradient(to bottom, rgba(0, 0, 0, calc(var(--shade) * 0.8)) 0%, rgba(0, 0, 0, 0) 20%);
}
.slide-info { position: absolute; z-index: 3; left: var(--gutter-l); right: var(--gutter-r); bottom: calc(26px + env(safe-area-inset-bottom, 0px)); display: grid; gap: clamp(8px, 1.2vw, 18px); color: #efede8; }
.slide-title { font-size: var(--f-title); line-height: 0.95; max-width: 15em; text-wrap: balance; padding-right: 48px; }
.slide-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px 28px; flex-wrap: wrap; font-size: var(--nav-size); }
.slide-left { display: flex; gap: 8px 28px; align-items: baseline; flex-wrap: wrap; min-width: 0; }
.slide-count { font-variant-numeric: tabular-nums; opacity: 0.75; }
.slide-type { opacity: 0.75; }
.slide-watch { border-bottom: 1px solid rgba(239, 237, 232, 0.5); padding-bottom: 2px; }
.cue, .next { display: flex; align-items: center; gap: 12px; color: #efede8; padding: 8px 0 8px 12px; margin-right: 44px; }
.cue { font-weight: 500; }
.next { opacity: 0.8; }
.arrow { flex: none; width: 10px; height: 10px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); }
.cue .arrow { animation: bob 1.5s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: rotate(45deg) translateY(-2px); } 50% { transform: rotate(45deg) translateY(2px) translate(3px, 3px); } }

.rail { position: fixed; z-index: 15; right: max(8px, env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; color: #efede8; mix-blend-mode: difference; }
.no-rail .rail { display: none; }
.tick { position: relative; width: 32px; height: 15px; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.tick::after { content: ''; position: absolute; right: 4px; top: 50%; height: 2px; width: 8px; background: currentColor; opacity: 0.55; transform: translateY(-50%); transition: width 0.3s ease, opacity 0.3s ease; }
.tick.on::after { width: 22px; opacity: 1; }
/* Survol : uniquement avec une souris (sur téléphone, un survol « collé » bloquait le tiret et annulait le toucher) */
@media (hover: hover) { .tick:hover::after { width: 22px; opacity: 1; } }
@media (hover: none) { .tick { width: 40px; height: 22px; } }
.slide .tools { top: calc(76px + env(safe-area-inset-top, 0px)); right: 56px; }

/* Téléphone en paysage : la fenêtre vidéo prend presque tout l'écran */
@media (max-height: 520px) {
  .lb { padding-top: calc(6px + env(safe-area-inset-top, 0px)); padding-bottom: calc(6px + env(safe-area-inset-bottom, 0px)); }
  .lb-top { padding-bottom: 4px; }
  .lb-bottom { padding-top: 4px; }
  .lb-stage iframe, .lb-stage video { width: min(100%, calc((100vh - 84px) * 16 / 9)); }
}

@media (max-width: 760px) {
  .bar-filters { display: none; }
  .slide-title { padding-right: 36px; }
  .cue, .next { margin-right: 30px; }
}
@media (prefers-reduced-motion: reduce) { .cue .arrow { animation: none; } .slide video { transition: none; } }

/* ---------- Accueil : nom discret, métier lisible ---------- */
.hero-foot { gap: 10px; }
.hero-name { font-family: var(--font-name); font-weight: 400; font-variation-settings: normal; letter-spacing: var(--name-tracking); text-transform: var(--name-transform); line-height: 1.15; }
.hero-role { font-family: var(--font-body); font-weight: 400; font-variation-settings: normal; letter-spacing: 0.01em; font-size: calc(var(--nav-size) + 2px); opacity: 0; animation: fadein 1s 1.2s ease forwards; }
@media (prefers-reduced-motion: reduce) { .hero-role { animation: none; opacity: 1; } }

/* ---------- Titres de projets : même famille que le nom ---------- */
.slide-title { font-family: var(--font-title); font-weight: var(--title-weight); font-variation-settings: normal; letter-spacing: var(--title-tracking); text-transform: var(--title-transform); line-height: 1.12; max-width: 22em; text-wrap: balance; }
.contact h2 { font-family: var(--font-name); font-weight: 400; font-variation-settings: normal; letter-spacing: var(--name-tracking); text-transform: var(--name-transform); font-size: clamp(20px, 3.4vw, 44px); line-height: 1.15; }
.contact-role { font-size: 18px; opacity: 0.8; margin-top: -14px; }
.lb-ext { border-bottom: 1px solid rgba(239, 237, 232, 0.4); }
@media (max-width: 560px) { .slide-title { font-size: max(var(--f-title), 15px); } }
.lb-msg { opacity: 0.7; font-size: 15px; text-align: center; }

.lb-stage:has(.lb-multi) { place-items: start center; overflow-y: auto; }
.lb-multi { width: min(100%, 1000px); display: grid; gap: 18px; padding-bottom: 12px; }
.lb-multi video { width: 100%; max-height: none; background: #000; }

/* ---------- Page Photos : une photo par écran, défilement sur le côté ---------- */
html.ph-page, html.ph-page body { overflow: hidden; height: 100%; }
.ph { position: fixed; inset: 0; display: flex; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; outline: none; -webkit-overflow-scrolling: touch; }
.ph::-webkit-scrollbar { display: none; }
.shot { position: relative; flex: 0 0 100%; width: 100%; height: 100%; box-sizing: border-box; scroll-snap-align: start; scroll-snap-stop: always; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); margin: 0; overflow: visible; cursor: pointer;
  padding: calc(max(var(--ph-pad), 76px) + env(safe-area-inset-top, 0px)) max(var(--ph-pad), 16px) calc(max(var(--ph-pad), 28px) + env(safe-area-inset-bottom, 0px)); }
.shot img { width: 100%; height: 100%; min-width: 0; min-height: 0; object-fit: contain; display: block; user-select: none; -webkit-user-drag: none; transition: none; }
.shot:hover img { transform: none; }
.pair:not(.fitted) { visibility: hidden; }
.pair { display: flex; align-items: center; justify-content: center; gap: var(--ph-pair); width: 100%; height: 100%; min-height: 0; min-width: 0; }
.shot .pair img { flex: none; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: fill; }
@media (max-aspect-ratio: 1/1) {
  .pair { flex-direction: column; }
  .shot { padding-left: 8px; padding-right: 8px; }
}
.ph-intro { position: fixed; inset: 0; z-index: 70; background: var(--bg); overflow: hidden; }
.ph-blur { position: absolute; inset: 0; overflow: hidden; }
.ph-scale { position: absolute; inset: 0; will-change: transform; transform-origin: 50% 50%; }
.ph-track { position: absolute; left: 0; top: 0; height: 100%; will-change: transform; }
.ph-fr { position: absolute; top: 0; height: 100%; box-sizing: border-box; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr);
  padding: calc(max(var(--ph-pad), 76px) + env(safe-area-inset-top, 0px)) 0 calc(max(var(--ph-pad), 28px) + env(safe-area-inset-bottom, 0px)); }
.ph-fr img { width: 100%; height: 100%; min-width: 0; min-height: 0; object-fit: contain; display: block; }
.ph-intro.out { opacity: 0; transition: opacity 0.35s ease; pointer-events: none; }
.ph-arrow { position: fixed; top: 50%; z-index: 20; width: 56px; height: 96px; margin-top: -48px; display: grid; place-items: center; color: var(--fg); opacity: 0.55; transition: opacity 0.2s; }
.ph-arrow:hover { opacity: 1; }
.ph-arrow.prev { left: 0; } .ph-arrow.next { right: 0; }
.ph-arrow i { width: 16px; height: 16px; border-top: 1.5px solid currentColor; border-right: 1.5px solid currentColor; transform: rotate(45deg); }
.ph-arrow.prev i { transform: rotate(-135deg); }
@media (hover: none) { .ph-arrow { display: none; } }
html.no-arrows .ph-arrow { display: none; }
.ph-bar { position: fixed; left: 0; right: 0; bottom: 0; height: 2px; z-index: 20; background: var(--line); }
.ph-bar i { display: block; height: 100%; width: 0; background: var(--fg); transition: width 0.35s ease; }
.ph .tools { top: calc(76px + env(safe-area-inset-top, 0px)); left: 50%; right: auto; transform: translateX(-50%); flex-wrap: wrap; justify-content: center; max-width: 90%; }
.editing .shot { cursor: default; outline: none; }
.editing .slide { cursor: default; }
