/* =========================================================
   Evan Le Hénaff - Dossier technique
   Papier, encre, stylo rouge. Angles droits, ombres franches.
   ========================================================= */

@font-face {
  font-family: "Archivo";
  src: url("../assets/fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face {
  font-family: "Azeret Mono";
  src: url("../assets/fonts/azeret-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Azeret Mono";
  src: url("../assets/fonts/azeret-mono-700.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  --paper: #ebe7dc;
  --paper-2: #e1dccd;
  --paper-3: #d6d0be;
  --ink: #141413;
  --ink-2: #23221f;
  --ink-3: #2f2e2a;
  --graphite: #5c5951;
  --pen: #e0281f;
  --pen-dark: #b51c14;
  --rule: rgba(20, 20, 19, 0.16);
  --rule-strong: rgba(20, 20, 19, 0.85);
  --gutter: clamp(16px, 4vw, 56px);
  --max: 1360px;
  --mono: "Azeret Mono", ui-monospace, monospace;
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --header-h: 92px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--paper);
  /* papier millimétré : 5 mm / 1 mm */
  background-image:
    linear-gradient(var(--rule) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule) 1px, transparent 1px),
    linear-gradient(rgba(20, 20, 19, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 20, 19, 0.05) 1px, transparent 1px);
  background-size:
    60px 60px,
    60px 60px,
    12px 12px,
    12px 12px;
  background-position: -1px -1px;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  font-variant-ligatures: no-common-ligatures;
  font-stretch: 100%;
  overflow-x: hidden;
}

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

a {
  color: inherit;
}

::selection {
  background: var(--pen);
  color: var(--paper);
}

:focus-visible {
  outline: 3px solid var(--pen);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
}
.skip:focus {
  left: 8px;
}

/* ---------- En-tête ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
}
.top__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 12px var(--gutter);
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand__mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 800;
  font-stretch: 125%;
  font-size: 15px;
  letter-spacing: 0.04em;
  box-shadow: 4px 4px 0 var(--pen);
}
.brand__txt {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.brand__txt strong {
  font-weight: 800;
  font-stretch: 112%;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.brand__txt small {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--graphite);
  letter-spacing: 0.04em;
}
.nav {
  display: flex;
  gap: 4px;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
}
.nav a {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 8px 10px;
  text-decoration: none;
  white-space: nowrap;
}
.nav a span {
  color: var(--pen);
  font-size: 11px;
}
.nav a:hover,
.nav a.is-here {
  background: var(--ink);
  color: var(--paper);
}
.nav__cta {
  border: 1.5px solid var(--ink);
}

/* Pied à coulisse */
.caliper {
  position: relative;
  height: 22px;
  border-top: 1px solid var(--rule);
  background: var(--paper-2);
  overflow: hidden;
}
.caliper__scale {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.caliper__scale line {
  stroke: var(--ink);
  stroke-width: 1;
}
.caliper__jaw {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 3px;
  background: var(--pen);
  transform: translateX(var(--jaw, 0px));
  will-change: transform;
}
.caliper__read {
  position: absolute;
  top: 2px;
  left: 8px;
  padding: 1px 6px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.caliper__read i {
  font-style: normal;
  color: var(--pen);
}
.caliper.is-flip .caliper__read {
  left: auto;
  right: 8px;
}

/* ---------- Primitives ---------- */
.sheet {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(56px, 8vw, 120px) var(--gutter);
}
.kicker,
.sec-head__tab {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.sec-head__tab {
  display: flex;
  align-items: center;
  gap: 12px;
}
.sec-head__tab span {
  padding: 4px 8px;
  background: var(--pen);
  color: var(--paper);
  font-weight: 700;
}
.sec-head__tab::after {
  content: "";
  flex: 1;
  height: 2px;
  background: currentColor;
}
.sec-head h2,
.contact__title {
  margin: 0;
  max-width: 20ch;
  font-weight: 800;
  font-stretch: 108%;
  font-size: clamp(32px, 4.6vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.sec-head__sub {
  max-width: 58ch;
  margin: 18px 0 0;
  color: var(--graphite);
  font-size: 18px;
}
.sec-head {
  margin-bottom: clamp(36px, 5vw, 64px);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 22px;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  text-decoration: none;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}
.btn--ink {
  background: var(--ink);
  color: var(--paper);
  box-shadow: 5px 5px 0 var(--pen);
}
.btn--ink:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--pen);
}
.btn--ink:active {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 var(--pen);
}
.btn--line {
  border: 2px solid var(--ink);
  background: transparent;
}
.btn--line:hover {
  background: var(--paper-2);
}

mark {
  background: linear-gradient(transparent 58%, rgba(224, 40, 31, 0.28) 58%, rgba(224, 40, 31, 0.28) 92%, transparent 92%);
  color: inherit;
  padding: 0 2px;
}

/* ---------- Hero ---------- */
.hero {
  overflow-x: clip;
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
  padding-top: clamp(40px, 6vw, 88px);
}
.hero__name {
  margin: 0 0 24px;
  font-weight: 800;
  font-stretch: 125%;
  font-size: clamp(48px, 7.4vw, 112px);
  line-height: 0.88;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.hero__name span {
  display: block;
}
.hero__name span:last-child {
  margin-top: 0.2em;
  font-stretch: 70%;
  font-size: 1.08em;
  letter-spacing: -0.01em;
  color: var(--ink);
  -webkit-text-stroke: 0;
}
.hero__lead {
  max-width: 34ch;
  margin: 0 0 28px;
  font-size: clamp(18px, 1.6vw, 21px);
  line-height: 1.45;
}
.spec {
  margin: 0 0 32px;
  border-top: 2px solid var(--ink);
}
.spec div {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--rule-strong);
}
.spec dt {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--graphite);
  padding-top: 3px;
}
.spec dd {
  margin: 0;
  font-size: 16px;
  line-height: 1.4;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero__fig {
  position: relative;
  margin: 28px 28px 0 0;
}
.viewport {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--ink);
  border: 2px solid var(--ink);
  box-shadow: 10px 10px 0 var(--ink);
  overflow: hidden;
}
.viewport__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__fig figcaption {
  margin-top: 20px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--graphite);
}

/* Cotes de dessin technique autour de la vidéo */
.cote {
  position: absolute;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pen);
}
.cote--top {
  left: 0;
  right: 0;
  top: -26px;
  height: 14px;
  border-left: 1.5px solid var(--pen);
  border-right: 1.5px solid var(--pen);
}
.cote--top::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 7px;
  height: 1.5px;
  background: var(--pen);
}
.cote--top span {
  position: absolute;
  left: 50%;
  top: -3px;
  transform: translateX(-50%);
  padding: 0 10px;
  background: var(--paper);
}
.cote--side {
  top: 0;
  right: -28px;
  width: 14px;
  aspect-ratio: auto;
  height: calc(100% - 38px);
  border-top: 1.5px solid var(--pen);
  border-bottom: 1.5px solid var(--pen);
}
.cote--side::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 7px;
  width: 1.5px;
  background: var(--pen);
}
.cote--side span {
  position: absolute;
  top: 50%;
  left: 7px;
  transform: translate(-50%, -50%) rotate(90deg);
  padding: 0 10px;
  background: var(--paper);
  white-space: nowrap;
}

/* Réticule de mesure sur la vidéo */
.crosshair {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}
.viewport.is-measuring .crosshair {
  opacity: 1;
}
.crosshair__x,
.crosshair__y {
  position: absolute;
  background: rgba(235, 231, 220, 0.75);
}
.crosshair__x {
  left: 0;
  right: 0;
  height: 1px;
  top: var(--cy, 50%);
}
.crosshair__y {
  top: 0;
  bottom: 0;
  width: 1px;
  left: var(--cx, 50%);
}
.crosshair__read {
  position: absolute;
  left: var(--cx, 50%);
  top: var(--cy, 50%);
  transform: translate(10px, 10px);
  padding: 3px 6px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

/* Tampon encreur */
.stamp {
  position: absolute;
  right: 6px;
  top: calc(100% + 34px);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 18px 12px;
  border: 3px solid var(--pen);
  outline: 1.5px solid var(--pen);
  outline-offset: 3px;
  color: var(--pen);
  background: rgba(235, 231, 220, 0.9);
  transform: rotate(-7deg);
  text-transform: uppercase;
  line-height: 1.05;
  -webkit-mask-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='0.75' numOctaves='2' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1.3 1.5'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  mask-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='0.75' numOctaves='2' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1.3 1.5'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}
.stamp__top,
.stamp__bot {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
}
.stamp__mid {
  margin: 2px 0;
  font-weight: 900;
  font-stretch: 125%;
  font-size: 26px;
  letter-spacing: 0.02em;
}
.stamp.is-in {
  animation: thunk 0.42s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}
@keyframes thunk {
  0% {
    transform: rotate(-16deg) scale(1.9);
    opacity: 0;
  }
  60% {
    opacity: 1;
  }
  100% {
    transform: rotate(-7deg) scale(1);
    opacity: 1;
  }
}

/* Relevés de mesure */
.readouts {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin: clamp(24px, 4vw, 48px) 0 0;
  padding: 0;
  list-style: none;
  border: 2px solid var(--ink);
  background: var(--paper);
}
.readouts li {
  position: relative;
  padding: 20px 20px 22px;
  border-right: 1px solid var(--rule-strong);
}
.readouts li:last-child {
  border-right: 0;
}
.readouts li::before {
  /* graduation */
  content: "";
  position: absolute;
  left: 20px;
  right: 20px;
  top: 0;
  height: 9px;
  background: repeating-linear-gradient(90deg, var(--ink) 0 1px, transparent 1px 8px);
  opacity: 0.6;
}
.readouts b {
  display: inline-block;
  margin-top: 10px;
  font-weight: 800;
  font-stretch: 72%;
  font-size: clamp(34px, 3.4vw, 50px);
  line-height: 1;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.readouts b small {
  font-size: 1em;
  color: var(--pen);
}
.readouts i {
  margin-left: 6px;
  font-family: var(--mono);
  font-style: normal;
  font-size: 13px;
  font-weight: 700;
  color: var(--pen);
}
.readouts p {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--graphite);
}

/* ---------- 01 Profil ---------- */
.profil__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: start;
}
.prose p {
  max-width: 62ch;
  margin: 0 0 1.1em;
  font-size: 18px;
}
.prose__drop::first-letter {
  float: left;
  margin: 6px 12px 0 0;
  padding: 4px 10px 6px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 800;
  font-stretch: 125%;
  font-size: 54px;
  line-height: 0.9;
}
.photo {
  margin: 0;
}
.photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border: 2px solid var(--ink);
}
.photo figcaption,
.plate figcaption {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.45;
  color: var(--graphite);
}
.photo figcaption span,
.plate figcaption span {
  margin-right: 6px;
  color: var(--pen);
  font-weight: 700;
}
.photo--tilt img {
  object-position: 50% 78%;
}
.photo--tilt {
  transform: rotate(1.4deg);
  padding: 12px 12px 14px;
  background: var(--paper);
  box-shadow: 8px 8px 0 var(--ink);
  border: 1px solid var(--ink);
}

/* Tableau de correspondance BUT → atelier */
.bridge {
  margin-top: clamp(48px, 7vw, 96px);
  border-top: 2px solid var(--ink);
}
.bridge__head {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 0 clamp(80px, 10vw, 160px);
  padding: 12px 0;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--graphite);
  border-bottom: 1px solid var(--rule-strong);
}
.bridge__rows {
  margin: 0;
  padding: 0;
  list-style: none;
}
.bridge__rows li {
  position: relative;
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 0 clamp(80px, 10vw, 160px);
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
}
.bridge__rows li > span:first-child {
  font-weight: 800;
  font-stretch: 118%;
  font-size: 20px;
  text-transform: uppercase;
}
.bridge__rows li > span:last-child {
  font-size: 17px;
}
.bridge__rows i {
  position: absolute;
  left: 270px;
  width: clamp(80px, 10vw, 160px);
  top: 50%;
  height: 2px;
  padding: 0 14px;
  background: var(--pen) content-box;
  transform-origin: left;
  transform: scaleX(var(--draw, 1));
  transition: transform 0.7s cubic-bezier(0.6, 0, 0.2, 1);
}
.bridge__rows i::after {
  content: "";
  position: absolute;
  right: 10px;
  top: -5px;
  border-left: 10px solid var(--pen);
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
}
.bridge__rows li:hover {
  background: var(--paper-2);
}

/* ---------- 02 Dossier (établi sombre) ---------- */
.bench {
  position: relative;
  padding: clamp(56px, 8vw, 120px) var(--gutter);
  background-color: var(--ink);
  background-image:
    linear-gradient(rgba(235, 231, 220, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(235, 231, 220, 0.06) 1px, transparent 1px);
  background-size: 60px 60px;
  color: var(--paper);
}
.bench > * {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}
.sec-head--dark .sec-head__sub {
  color: #b7b2a4;
}

.binder {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
}
.binder__tabs {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(235, 231, 220, 0.25);
}
.binder__tabs button {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 11px 12px;
  border: 0;
  border-bottom: 1px solid rgba(235, 231, 220, 0.18);
  background: transparent;
  color: #c9c4b5;
  font-family: var(--sans);
  font-size: 15px;
  text-align: left;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s,
    padding 0.2s;
}
.binder__tabs button b {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--pen);
}
.binder__tabs button:hover {
  color: var(--paper);
  background: var(--ink-3);
}
.binder__tabs button[aria-selected="true"] {
  padding-left: 22px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 600;
}

.binder__sheets {
  min-width: 0;
}
.fiche {
  background: var(--paper);
  color: var(--ink);
  border: 2px solid var(--paper);
  box-shadow:
    8px 8px 0 var(--paper-3),
    16px 16px 0 #8f8a7c;
}
.fiche[hidden] {
  display: none;
}
.fiche.is-in {
  animation: slip 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes slip {
  from {
    transform: translateY(18px) rotate(0.6deg);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.fiche__head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: stretch;
  border-bottom: 2px solid var(--ink);
}
.fiche__id {
  display: grid;
  place-items: center;
  padding: 0 18px;
  background: var(--pen);
  color: var(--paper);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 15px;
}
.fiche__head h3 {
  margin: 0;
  padding: 16px 20px;
  font-weight: 800;
  font-stretch: 110%;
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.1;
  text-transform: uppercase;
}
.fiche__no {
  display: grid;
  place-items: center;
  padding: 0 18px;
  border-left: 1px solid var(--rule-strong);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--graphite);
  white-space: nowrap;
}
.fiche__body {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  align-items: start;
  gap: clamp(20px, 3vw, 40px);
  padding: clamp(20px, 3vw, 36px);
}
.steps {
  margin: 0;
}
.steps dt {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pen);
}
.steps dt:first-child {
  margin-top: 0;
}
.steps dt::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
}
.steps dd {
  margin: 6px 0 0;
  font-size: 16px;
  line-height: 1.5;
}
.ticks {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ticks li {
  position: relative;
  padding: 3px 0 3px 26px;
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 8px;
  width: 12px;
  height: 7px;
  border-left: 2.5px solid var(--pen);
  border-bottom: 2.5px solid var(--pen);
  transform: rotate(-45deg);
}

.plates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-content: start;
}
.plate {
  margin: 0;
  cursor: zoom-in;
}
.plate--wide,
.plate--fill {
  grid-column: 1 / -1;
}
.fiche__col {
  min-width: 0;
}
.plates--aside:not(:empty) {
  margin-top: clamp(24px, 3vw, 36px);
}
.plates .plate--fill img {
  aspect-ratio: 16 / 10;
}
.plate img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1.5px solid var(--ink);
  transition: filter 0.2s;
}
.plate--wide img {
  aspect-ratio: 16 / 10;
}
.plate:hover img {
  filter: contrast(1.08);
}
.plates--2 .plate:not(.plate--wide) img {
  aspect-ratio: 16 / 10;
}
.plate--ab {
  position: relative;
}
.plate--ab::before,
.plate--ab::after {
  position: absolute;
  top: 8px;
  z-index: 1;
  padding: 3px 7px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
}
.plate--ab::before {
  content: "AVANT";
  left: 8px;
}
.plate--ab::after {
  content: "APRÈS";
  left: 52%;
  background: var(--pen);
}

.binder__pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 36px;
  font-family: var(--mono);
}
.pager {
  min-height: 44px;
  padding: 0 16px;
  border: 1.5px solid rgba(235, 231, 220, 0.6);
  background: transparent;
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.pager:hover {
  background: var(--paper);
  color: var(--ink);
}
.pager__count {
  font-size: 13px;
  color: #b7b2a4;
}

/* ---------- 03 Atelier ---------- */
.atelier__grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: start;
}
.register {
  margin: 0;
  padding: 0;
  list-style: none;
  columns: 2;
  column-gap: 28px;
  border-top: 2px solid var(--ink);
}
.register li {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--rule-strong);
  break-inside: avoid;
  font-weight: 800;
  font-stretch: 116%;
  font-size: 21px;
  text-transform: uppercase;
}
.register span {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--pen);
}
.strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 1fr);
  gap: 14px;
  margin-top: clamp(36px, 5vw, 64px);
  padding-bottom: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-color: var(--ink) var(--paper-2);
}
.strip figure {
  margin: 0;
  scroll-snap-align: start;
  cursor: zoom-in;
}
.strip img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border: 1.5px solid var(--ink);
  filter: grayscale(0.35);
  transition: filter 0.25s;
}
.strip figure:hover img {
  filter: none;
}
.strip figcaption {
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------- 04 Parcours ---------- */
.parcours {
  border-top: 2px solid var(--ink);
}
.gantt {
  --months: 72;
  position: relative;
  margin-bottom: clamp(40px, 6vw, 72px);
  padding: 34px 0 6px;
  border-bottom: 2px solid var(--ink);
}
.gantt__scale {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  pointer-events: none;
}
.gantt__scale span {
  position: relative;
  padding-left: 8px;
  border-left: 1.5px solid var(--ink);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  background-image: repeating-linear-gradient(90deg, rgba(20, 20, 19, 0.35) 0 1px, transparent 1px calc(100% / 12));
  background-size: 100% 8px;
  background-repeat: no-repeat;
  background-position: 0 100%;
}
.gantt__row {
  position: relative;
  height: 46px;
  margin: 8px 0;
}
.gantt__row i {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--from) / var(--months) * 100%);
  width: calc((var(--to) - var(--from)) / var(--months) * 100%);
  background: var(--ink);
  transform-origin: left;
  transform: scaleX(var(--draw, 1));
  transition: transform 0.9s cubic-bezier(0.6, 0, 0.2, 1);
}
.gantt__row b {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: calc(var(--from) / var(--months) * 100% + 12px);
  transform: translateY(-50%);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.g-but { --from: 8; --to: 44; }
.g-alt { --from: 20; --to: 44; }
.g-civic { --from: 0; --to: 58; }
.g-next { --from: 57; --to: 72; }
.gantt__row--next i {
  background: repeating-linear-gradient(-45deg, var(--pen) 0 8px, transparent 8px 14px);
  border: 2px solid var(--pen);
}
.gantt__row--next b {
  left: auto;
  right: calc(100% - var(--from) / var(--months) * 100% + 12px);
  color: var(--pen);
}
.cv {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 6vw, 96px);
}
.cv__title {
  margin: 0 0 8px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.entry {
  padding: 18px 0;
  border-bottom: 1px solid var(--rule-strong);
}
.entry h4 {
  margin: 0;
  font-weight: 800;
  font-stretch: 108%;
  font-size: 21px;
  line-height: 1.2;
}
.entry__date {
  margin: 0 0 6px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--pen);
}
.entry__org {
  margin: 4px 0 0;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--graphite);
}
.entry p:last-child:not(.entry__org):not(.entry__date) {
  margin: 8px 0 0;
  font-size: 16px;
}

/* ---------- 05 Fiche de contrôle ---------- */
.table-wrap {
  overflow-x: auto;
  border: 2px solid var(--ink);
  background: var(--paper);
  box-shadow: 10px 10px 0 var(--ink);
}
.check {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}
.check th,
.check td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--rule-strong);
  text-align: left;
  vertical-align: middle;
}
.check thead th {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.check thead abbr {
  text-decoration: none;
}
.check tbody th {
  width: 22%;
  font-weight: 800;
  font-stretch: 112%;
  font-size: 17px;
  text-transform: uppercase;
}
.check tbody td:nth-child(3) {
  width: 22%;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
}
.check tbody td:last-child {
  width: 64px;
  text-align: center;
}
.check tbody tr:last-child > * {
  border-bottom: 0;
}
.check tbody tr:hover {
  background: var(--paper-2);
}
.check a {
  display: inline-block;
  margin: 2px 4px 2px 0;
  padding: 2px 6px;
  border: 1.5px solid var(--ink);
  text-decoration: none;
}
.check a:hover {
  background: var(--pen);
  border-color: var(--pen);
  color: var(--paper);
}
.ok {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 2px solid var(--pen);
  border-radius: 50%;
  color: var(--pen);
  transform: rotate(-8deg);
}
.ok::after {
  content: "C";
  font-family: var(--mono);
  font-weight: 700;
  font-size: 14px;
}

/* ---------- 06 Contact ---------- */
.contact {
  padding: clamp(64px, 10vw, 140px) var(--gutter);
  background: var(--pen-dark);
  color: var(--paper);
}
.contact__inner {
  max-width: var(--max);
  margin: 0 auto;
}
.sec-head__tab--light span {
  background: var(--ink);
}
.contact__title {
  max-width: 18ch;
  font-size: clamp(36px, 6vw, 88px);
  font-stretch: 112%;
}
.contact__title em {
  display: block;
  font-style: normal;
  color: var(--ink);
}
.contact__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: clamp(36px, 5vw, 64px);
  border-top: 2px solid var(--paper);
}
.line-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px 20px 22px 0;
  border-bottom: 2px solid var(--paper);
  text-decoration: none;
}
.line-item + .line-item {
  padding-left: 20px;
  border-left: 1px solid rgba(235, 231, 220, 0.5);
}
.line-item span {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.85;
}
.line-item strong {
  font-weight: 700;
  font-stretch: 100%;
  font-size: clamp(18px, 1.9vw, 26px);
  overflow-wrap: anywhere;
}
a.line-item:hover strong {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}
.copy {
  margin-top: 28px;
  min-height: 48px;
  padding: 0 18px;
  border: 2px solid var(--paper);
  background: transparent;
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
}
.copy:hover,
.copy.is-done {
  background: var(--paper);
  color: var(--pen-dark);
}

/* ---------- Cartouche ---------- */
.cartouche {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin: 0;
  background: var(--paper);
  border-top: 2px solid var(--ink);
}
.cartouche div {
  padding: 14px var(--gutter) 16px 16px;
  border-right: 1px solid var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}
.cartouche div:first-child {
  padding-left: var(--gutter);
}
.cartouche div:last-child {
  border-right: 0;
}
.cartouche span {
  display: block;
  margin-bottom: 4px;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--graphite);
}

/* ---------- Visionneuse ---------- */
.lightbox {
  width: min(1100px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  padding: 14px;
  border: 2px solid var(--ink);
  background: var(--paper);
  box-shadow: 12px 12px 0 var(--pen);
}
.lightbox::backdrop {
  background: rgba(20, 20, 19, 0.82);
}
.lightbox img {
  width: 100%;
  max-height: calc(100vh - 140px);
  object-fit: contain;
  background: var(--ink);
}
.lightbox__cap {
  margin: 10px 0 0;
  font-family: var(--mono);
  font-size: 13px;
}
.lightbox__bar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}
.lightbox__close {
  min-height: 36px;
  padding: 0 12px;
  border: 1.5px solid var(--ink);
  background: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.lightbox__close:hover {
  background: var(--ink);
  color: var(--paper);
}

/* ---------- Apparition au défilement ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 0.6s ease,
    transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}
.js .bridge__rows i,
.js .gantt__row i {
  --draw: 0;
}
.js .is-in .bridge__rows i,
.js .gantt.is-in .gantt__row i {
  --draw: 1;
}
.js .bridge__rows li:nth-child(2) i { transition-delay: 0.08s; }
.js .bridge__rows li:nth-child(3) i { transition-delay: 0.16s; }
.js .bridge__rows li:nth-child(4) i { transition-delay: 0.24s; }
.js .bridge__rows li:nth-child(5) i { transition-delay: 0.32s; }
.js .bridge__rows li:nth-child(6) i { transition-delay: 0.4s; }
.js .gantt__row:nth-of-type(3) i { transition-delay: 0.12s; }
.js .gantt__row:nth-of-type(4) i { transition-delay: 0.24s; }
.js .gantt__row:nth-of-type(5) i { transition-delay: 0.36s; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav a {
    padding: 8px 7px;
  }
  .nav a span {
    display: none;
  }
  .readouts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .readouts li:nth-child(3) {
    border-right: 0;
  }
  .readouts li:nth-child(n + 4) {
    border-top: 1px solid var(--rule-strong);
  }
  .binder {
    grid-template-columns: 1fr;
  }
  .binder__tabs {
    position: sticky;
    top: var(--header-h);
    z-index: 5;
    flex-direction: row;
    overflow-x: auto;
    margin: 0 calc(var(--gutter) * -1);
    padding: 0 var(--gutter);
    background: var(--ink);
    border-top: 0;
    border-bottom: 1px solid rgba(235, 231, 220, 0.25);
    scrollbar-width: none;
  }
  .binder__tabs::-webkit-scrollbar {
    display: none;
  }
  .binder__tabs button {
    flex: 0 0 auto;
    flex-direction: column;
    gap: 2px;
    border-bottom: 0;
    border-right: 1px solid rgba(235, 231, 220, 0.18);
    font-size: 13px;
  }
  .binder__tabs button[aria-selected="true"] {
    padding-left: 12px;
  }
}

@media (max-width: 860px) {
  :root {
    --header-h: 128px;
  }
  .top__bar {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding-top: 10px;
    padding-bottom: 8px;
  }
  .nav {
    overflow-x: auto;
    margin: 0 calc(var(--gutter) * -1);
    padding: 0 var(--gutter);
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar {
    display: none;
  }
  .hero {
    grid-template-columns: 1fr;
  }
  .hero__fig {
    margin: 34px 12px 0 0;
  }
  .cote--side {
    display: none;
  }
  .hero__name {
    font-size: clamp(48px, 15vw, 96px);
  }
  .stamp {
    position: relative;
    top: auto;
    right: auto;
    margin: 22px 0 0 auto;
    width: max-content;
  }
  .profil__grid,
  .atelier__grid,
  .cv,
  .fiche__body {
    grid-template-columns: 1fr;
  }
  .photo--tilt {
    max-width: 420px;
  }
  .bridge__head {
    display: none;
  }
  .bridge__rows li {
    grid-template-columns: 1fr;
    gap: 6px;
    padding-left: 0;
  }
  .bridge__rows i {
    display: none;
  }
  .bridge__rows li > span:last-child::before {
    content: "→ ";
    color: var(--pen);
    font-weight: 700;
  }
  .contact__grid {
    grid-template-columns: 1fr;
  }
  .line-item + .line-item {
    padding-left: 0;
    border-left: 0;
  }
  .cartouche {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .cartouche div {
    padding-left: var(--gutter);
    border-bottom: 1px solid var(--ink);
  }
  .cartouche div:nth-child(2n) {
    border-right: 0;
  }
  .gantt__row b {
    font-size: 11px;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 16px;
  }
  .readouts {
    grid-template-columns: 1fr 1fr;
  }
  .readouts li,
  .readouts li:nth-child(3) {
    border-right: 1px solid var(--rule-strong);
    border-top: 1px solid var(--rule-strong);
  }
  .readouts li:nth-child(2n) {
    border-right: 0;
  }
  .readouts li:nth-child(-n + 2) {
    border-top: 0;
  }
  .readouts li:last-child {
    grid-column: 1 / -1;
  }
  .spec div {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  .register {
    columns: 1;
  }
  .fiche__head {
    grid-template-columns: auto 1fr;
  }
  .fiche__no {
    display: none;
  }
  .plates {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .gantt__scale span {
    font-size: 10px;
    padding-left: 4px;
  }
  .gantt__row {
    height: auto;
    margin: 12px 0;
  }
  .gantt__row b {
    position: static;
    display: block;
    margin-bottom: 4px;
    transform: none;
    color: var(--ink);
    font-size: 11px;
  }
  .gantt__row--next b {
    color: var(--pen);
    text-align: right;
  }
  .gantt__row i {
    position: relative;
    display: block;
    left: auto;
    height: 16px;
    margin-left: calc(var(--from) / var(--months) * 100%);
  }
  .hero__fig {
    margin-right: 10px;
  }
}

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

@media print {
  .top,
  .crosshair,
  .binder__tabs,
  .binder__pager,
  .copy,
  .lightbox {
    display: none !important;
  }
  .fiche[hidden] {
    display: block !important;
  }
  .fiche {
    break-inside: avoid;
    margin-bottom: 24px;
    box-shadow: none;
    border: 1px solid #000;
  }
  .bench {
    background: #fff;
    color: #000;
  }
}

/* ---------- Page 404 ---------- */
.notfound {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.notfound h1 {
  margin: 0;
  font-weight: 800;
  font-stretch: 108%;
  font-size: clamp(36px, 6vw, 80px);
  line-height: 1.02;
}
.notfound .btn {
  margin-top: 32px;
}
