/* ---------------------------------------------------------------------------
   Base — socle partagé par tous les thèmes.
   Ne contient aucune décision d'identité : uniquement la mécanique, les
   polices, les états et les surfaces du navigateur.
--------------------------------------------------------------------------- */

@font-face {
  font-family: "Archivo";
  src: url("../assets/fonts/archivo-100900-0.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face {
  font-family: "Bricolage";
  src: url("../assets/fonts/bricolage-200800-0.woff2") format("woff2-variations");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("../assets/fonts/spectral-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("../assets/fonts/spectral-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("../assets/fonts/instrument-serif-normal-1.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("../assets/fonts/spectral-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("../assets/fonts/spectral-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("../assets/fonts/instrument-serif-italic-0.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Anton";
  src: url("../assets/fonts/anton-400-0.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Spline Mono";
  src: url("../assets/fonts/spline-mono-400-0.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Spline Mono";
  src: url("../assets/fonts/spline-mono-500-1.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* Le rebond élastique reste, le tirer-pour-recharger s'arrête ici. */
  overscroll-behavior-y: contain;
}

body {
  margin: 0;
  min-height: 100svh;
  overscroll-behavior-y: contain;
  font-synthesis-weight: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

picture {
  display: contents;
}

/* Protection des photos : pas de menu d'enregistrement à l'appui long.
   Le texte reste sélectionnable (aucun user-select:none global). */
img,
picture {
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--select-bg, currentColor);
  color: var(--select-ink, Canvas);
}

:focus-visible {
  outline: 2px solid var(--focus, currentColor);
  outline-offset: 3px;
  border-radius: 1px;
}

* {
  scrollbar-color: var(--bar, #777) transparent;
  scrollbar-width: thin;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--skip-bg, #111);
  color: var(--skip-ink, #fff);
  font-size: 13px;
  text-decoration: none;
  transform: translateY(-160%);
}
.skip:focus-visible {
  transform: none;
}

/* Conteneur d'image : le LQIP est porté par le parent, l'image le recouvre. */
.frame {
  position: relative;
  overflow: hidden;
  background-color: var(--tint, #1a1a1a);
  background-size: cover;
  background-position: center;
}
.frame img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  color: transparent;
}

/* Révélation au défilement : visible par défaut, animée seulement si JS. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--delay, 0ms);
}
.js [data-reveal].in {
  opacity: 1;
  transform: none;
}

/* Réglages d'aperçu. */
.no-lightbox [data-lb] {
  cursor: default;
}


.no-intro .intro {
  display: none !important;
}

.no-captions figcaption,
.no-captions .lb-cap,
.no-captions .cap,
.no-captions .cap-no,
.no-captions .cap-row,
.no-captions .fr-cap,
.no-captions .shot-cap,
.no-captions .spread-caption,
.no-captions .tile-cap,
.no-captions .project-hero-cap,
.no-captions .shot figcaption,
.no-captions .plate figcaption,
.no-captions .fr figcaption {
  display: none !important;
}

/* Lightbox commune. */
dialog.lb {
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--lb-bg, #0a0a0a);
  color: var(--lb-ink, #f2f2f2);
  overscroll-behavior: contain;
}
dialog.lb::backdrop {
  background: rgb(0 0 0 / 0.6);
}
.lb[open] {
  display: grid;
  grid-template-rows: auto 1fr auto;
}
.lb-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  font-size: 12px;
}
.lb-stage {
  display: grid;
  place-items: center;
  min-height: 0;
  padding: 0 18px;
}
.lb-stage img {
  max-width: 100%;
  max-height: calc(100svh - 150px);
  width: auto;
  height: auto;
  object-fit: contain;
}
.lb-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 18px 22px;
  font-size: 12px;
}
.lb button {
  background: none;
  border: 1px solid currentColor;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
}
.lb button:disabled {
  opacity: 0.35;
  cursor: default;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] {
    opacity: 1;
    transform: none;
  }
}


/* Atelier */
/* ---------------------------------------------------------------------------
   Atelier — éditorial aéré : grande typographie, marges larges, air.
--------------------------------------------------------------------------- */

:root {
  --bg: #f7f4ed;
  --ink: #221f19;
  --muted: #6f6a5e;
  --rule: #ddd7c9;
  --pad: clamp(20px, 5vw, 72px);
  --gap: clamp(64px, 10vw, 170px);
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --mono: "Spline Mono", ui-monospace, monospace;
  --focus: #221f19;
  --select-bg: #221f19;
  --select-ink: #f7f4ed;
  --bar: #c9c2b2;
}

html[data-mode="dark"] {
  --bg: #17150f;
  --ink: #f2ecdf;
  --muted: #a89f8e;
  --rule: #3a352c;
  --focus: #f2ecdf;
  --select-bg: #f2ecdf;
  --select-ink: #17150f;
  --bar: #4a4437;
}

body {
  margin: 0;
  padding: 0 var(--pad);
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
}

/* --- Bandeau ------------------------------------------------------------ */

.top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding: 26px 0 16px;
  border-bottom: 1px solid var(--rule);
}

.wordmark {
  margin: 0;
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1;
  color: inherit;
  text-decoration: none;
}

.top-role {
  margin: 0;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.top-nav {
  display: flex;
  gap: 18px;
}

.top-nav a {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2px;
}

.top-nav a:hover {
  border-color: var(--ink);
}

/* --- Accueil ------------------------------------------------------------ */

.hero {
  padding: clamp(60px, 11vw, 190px) 0 clamp(50px, 8vw, 120px);
  max-width: 1180px;
}

.hero h1 {
  margin: 0 0 clamp(22px, 3vw, 40px);
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(52px, 10.5vw, 168px);
  line-height: 0.92;
  letter-spacing: -0.02em;
}

.hero-tag {
  margin: 0 0 22px;
  max-width: 30ch;
  font-family: var(--serif);
  font-size: clamp(22px, 2.6vw, 34px);
  line-height: 1.25;
}

.hero-meta {
  margin: 0;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* --- Planches ----------------------------------------------------------- */

.plates {
  display: grid;
  gap: var(--gap);
  padding-bottom: var(--gap);
}

.plate {
  display: grid;
  gap: clamp(18px, 2.4vw, 32px);
}

.plate-media {
  display: block;
  width: min(100%, 1120px);
  margin: 0 auto;
}

html[data-width="narrow"] .plate-media {
  width: min(100%, 820px);
}

.plate-img {
  display: block;
  aspect-ratio: var(--ar);
  background-color: var(--rule);
  background-size: cover;
  background-position: center;
}

.plate-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.plate-media:hover .plate-img img {
  transform: scale(1.012);
}

.plate-text {
  width: min(100%, 640px);
}

.plate-text h2 {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(26px, 3vw, 40px);
  line-height: 1.05;
}

.plate-text h2 a {
  color: inherit;
  text-decoration: none;
}

.plate-text h2 a:hover {
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1px;
}

.plate-meta {
  margin: 0 0 12px;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.plate-sum {
  margin: 0 0 14px;
  max-width: 52ch;
  font-size: 14.5px;
  line-height: 1.65;
  color: color-mix(in srgb, var(--ink) 78%, var(--bg));
}

.plate-link {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2px;
}

.plate-link:hover {
  border-color: var(--ink);
}

/* --- Page série --------------------------------------------------------- */

.serie-head {
  padding: clamp(70px, 10vw, 150px) 0 clamp(40px, 6vw, 80px);
  max-width: 900px;
}

.serie-no {
  margin: 0 0 14px;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.serie-head h1 {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(46px, 8vw, 128px);
  line-height: 0.94;
  letter-spacing: -0.02em;
}

.serie-meta {
  margin: 0 0 20px;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.serie-sum {
  margin: 0;
  max-width: 54ch;
  font-size: 15px;
  line-height: 1.7;
}

.shots {
  display: grid;
  gap: clamp(44px, 7vw, 110px);
  padding: clamp(20px, 4vw, 50px) 0 var(--gap);
}

.shot {
  margin: 0;
  display: grid;
  gap: 10px;
  justify-items: center;
}

.shot-img {
  display: block;
  max-width: min(100%, 940px);
  background-color: var(--rule);
  background-size: cover;
  background-position: center;
}

.shot-img img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 82svh;
}

.shot figcaption {
  max-width: min(100%, 940px);
  font-family: var(--mono);
  font-size: 9.5px;
  line-height: 1.55;
  color: var(--muted);
  text-align: center;
}

.next {
  padding: clamp(30px, 5vw, 60px) 0;
  border-top: 1px solid var(--rule);
}

.next .mono {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.next a {
  font-family: var(--serif);
  font-size: clamp(32px, 5vw, 64px);
  line-height: 1;
  color: inherit;
  text-decoration: none;
}

.next a:hover {
  color: var(--muted);
}

/* --- Pied --------------------------------------------------------------- */

.foot {
  display: grid;
  gap: 8px;
  padding: clamp(40px, 6vw, 80px) 0 clamp(40px, 5vw, 70px);
  border-top: 1px solid var(--rule);
}

.foot-mail {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: clamp(26px, 3.6vw, 44px);
  line-height: 1;
}

.foot-mail a {
  color: inherit;
  text-decoration: none;
}

.foot-mail a:hover {
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1px;
}

.foot-meta {
  margin: 0;
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.foot-meta a {
  color: inherit;
  text-decoration: none;
}

/* --- Intro -------------------------------------------------------------- */

.intro {
  position: fixed;
  inset: 0;
  z-index: 95;
  display: grid;
  place-content: center;
  background: var(--bg);
  pointer-events: none;
  animation: intro-out 0.8s cubic-bezier(0.76, 0, 0.24, 1) 1.1s forwards;
}

.intro-name {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(34px, 6vw, 72px);
  line-height: 1;
  animation: intro-in 0.9s 0.1s both;
}

@keyframes intro-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}

@keyframes intro-out {
  to {
    opacity: 0;
    transform: translateY(-6px);
  }
}

/* --- Palettes ----------------------------------------------------------- */

html[data-palette="argile"][data-mode="light"] {
  --bg: #f3e9dd;
  --ink: #2a211a;
  --muted: #6e5f52;
  --rule: #ddcebc;
}

html[data-palette="argile"][data-mode="dark"] {
  --bg: #1c1410;
  --ink: #f4e8dc;
  --muted: #b39c8c;
  --rule: #3d2f26;
}

html[data-palette="sauge"][data-mode="light"] {
  --bg: #eef0e8;
  --ink: #1f241c;
  --muted: #5f6659;
  --rule: #d3d8c9;
}

html[data-palette="sauge"][data-mode="dark"] {
  --bg: #131611;
  --ink: #e9eddf;
  --muted: #9aa58f;
  --rule: #333a2c;
}

/* --- Adaptations -------------------------------------------------------- */

@media (max-width: 760px) {
  .top {
    flex-wrap: wrap;
    gap: 6px 16px;
  }

  .top-role {
    order: 3;
    flex-basis: 100%;
  }

  .hero {
    padding-top: 56px;
  }

  .plate-text {
    width: 100%;
  }

  .shot figcaption {
    text-align: left;
  }
}
