/* ÉCLAT No. 19 — object cinema, motion build */

:root {
  --black: #060607;
  --ink: #0b0b0d;
  --gunmetal: #2a2c30;
  --champagne: #d8bd8a;
  --champagne-dim: #a68f63;
  --white: #f4f1ea;
  --grey: #8d8b85;
  --ease-cinema: cubic-bezier(0.32, 0.72, 0, 1);
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Space Grotesk", "SF Mono", monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--serif);
  font-weight: 300;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--champagne); color: var(--black); }

sup { font-size: 0.45em; letter-spacing: 0.05em; }
img, video { max-width: 100%; display: block; }

/* ---------- fixed layers ---------- */

#grain {
  position: fixed; inset: 0; z-index: 40;
  width: 100%; height: 100%;
  pointer-events: none;
  opacity: 0.07;
  mix-blend-mode: soft-light;
}

/* ---------- chrome ---------- */

.chrome {
  position: fixed; z-index: 50;
  top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 2rem 2.5rem;
  mix-blend-mode: difference;
  pointer-events: none;
}
.chrome a { pointer-events: auto; }
.chrome__mark {
  font-family: var(--sans); font-size: 0.75rem; font-weight: 500;
  letter-spacing: 0.5em; color: var(--white); text-decoration: none;
}
.chrome__cta {
  font-family: var(--sans); font-size: 0.65rem; font-weight: 400;
  letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--white); text-decoration: none;
  border-bottom: 1px solid rgba(244, 241, 234, 0.3);
  padding-bottom: 0.35em;
  transition: border-color 0.7s var(--ease-cinema), letter-spacing 0.7s var(--ease-cinema);
}
.chrome__cta:hover { border-color: var(--white); letter-spacing: 0.38em; }

/* ---------- shared ---------- */

main { position: relative; z-index: 10; }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.62rem; font-weight: 400;
  letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--champagne-dim);
  margin-bottom: clamp(1.5rem, 3vh, 2.5rem);
}

.display {
  font-family: var(--serif);
  font-size: clamp(3rem, 7.5vw, 7rem);
  font-weight: 300;
  line-height: 0.98;
  letter-spacing: -0.015em;
}
.display em { font-style: italic; color: var(--champagne); font-weight: 300; }
.display--center { text-align: center; }

/* reveal states (JS-only; static without JS) */
.js [data-reveal] { opacity: 0; transform: translateY(3.5rem); filter: blur(6px); }

/* ---------- ACT 1 · hero — scrubbed calibre ---------- */

.hero { position: relative; }

.hero__stage {
  position: relative;
  height: 100vh; height: 100dvh;
  overflow: hidden;
}

.hero__poster,
.hero__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.8) contrast(1.05) brightness(0.75);
  transform: scale(1.18);
  transform-origin: 50% 58%;
}
.hero__video { opacity: 0; }
.hero__video.is-ready { opacity: 1; }
.hero__video.is-ready + .hero__shade + .hero__copy .hero__scroll { opacity: 1; }

.hero__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(6, 6, 7, 0.85) 0%, rgba(6, 6, 7, 0.3) 34%, rgba(6, 6, 7, 0.05) 60%),
    linear-gradient(105deg, rgba(6, 6, 7, 0.5) 0%, rgba(6, 6, 7, 0) 55%);
  pointer-events: none;
}

.hero__copy {
  position: absolute;
  left: clamp(1.5rem, 6vw, 7rem);
  right: clamp(1.5rem, 6vw, 7rem);
  bottom: 9vh;
}

.hero__title {
  font-weight: 300;
  line-height: 0.86;
  letter-spacing: -0.02em;
  margin-left: -0.06em;
  font-size: clamp(4.2rem, 13vw, 12rem);
  text-shadow: 0 2px 40px rgba(6, 6, 7, 0.5);
}
.hero__title em {
  font-style: italic;
  color: var(--champagne);
  font-size: 0.62em;
}

.hero__sub {
  margin-top: clamp(1.4rem, 3vh, 2.4rem);
  font-size: clamp(1.1rem, 1.7vw, 1.45rem);
  line-height: 1.5;
  color: rgba(244, 241, 234, 0.85);
  font-style: italic;
}

.hero__scroll {
  position: absolute;
  right: 0; bottom: 0.4rem;
  display: flex; align-items: center; gap: 1rem;
  font-family: var(--sans); font-size: 0.6rem;
  letter-spacing: 0.3em; text-transform: uppercase;
  color: rgba(244, 241, 234, 0.65);
}
.hero__scroll-line {
  display: block; width: 4rem; height: 1px;
  background: linear-gradient(90deg, transparent, var(--champagne-dim));
}

/* ---------- acts — full-bleed stages ---------- */

.act { position: relative; }

.act__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(to right, rgba(6, 6, 7, 0.78) 0%, rgba(6, 6, 7, 0.45) 45%, rgba(6, 6, 7, 0.15) 100%);
  pointer-events: none;
}

.act__head { margin-bottom: clamp(3rem, 8vh, 6rem); }

/* ---------- ACT 2 · calibre — pinned video, truths flow over ---------- */

.act--calibre .act__media {
  position: absolute; inset: 0;
  height: 100vh; height: 100dvh;
  overflow: hidden;
  z-index: 0;
}
.js .act--calibre .act__media { position: relative; } /* JS pins it */
.act--calibre .act__media video {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.75) contrast(1.05) brightness(0.6);
}

.act--calibre .act__flow {
  position: relative; z-index: 1;
  padding: clamp(6rem, 14vh, 10rem) clamp(1.5rem, 6vw, 7rem);
  max-width: 74rem;
  display: flex; flex-direction: column;
  min-height: 300vh;
}
.act--calibre .truths { flex: 1; align-content: space-evenly; }
.js .act--calibre .act__flow { margin-top: -100vh; }

.truths {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(4rem, 12vh, 8rem) clamp(2.5rem, 6vw, 6rem);
  max-width: 62rem;
}
.truth { max-width: 24rem; }
.truth:nth-child(even) { transform: translateY(3rem); }

.truth__index {
  font-family: var(--serif); font-style: italic;
  color: var(--champagne-dim); font-size: 1rem;
  display: block; margin-bottom: 0.9rem;
}
.truth__stat {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  font-weight: 300; line-height: 1;
  letter-spacing: -0.01em;
  margin-bottom: 1rem;
  font-variant-numeric: tabular-nums;
}
.truth__stat small {
  font-family: var(--sans);
  font-size: 0.32em; font-weight: 300;
  letter-spacing: 0.25em; text-transform: uppercase;
  color: var(--champagne-dim);
  margin-left: 0.4em;
  white-space: nowrap;
}
.truth__body { font-size: 1.02rem; line-height: 1.65; color: #b8b5ae; }

/* ---------- ACT 3 · materials — pinned slide swap ---------- */

.mat-stage {
  position: relative;
  height: 100vh; height: 100dvh;
  overflow: hidden;
}

.mat-slide {
  position: absolute; inset: 0;
  opacity: 0;
}
.mat-slide.is-current { opacity: 1; }
.mat-slide img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.82) contrast(1.05) brightness(0.85);
}

.mat-copy {
  position: absolute; z-index: 2;
  left: clamp(1.5rem, 6vw, 7rem);
  bottom: 12vh;
  max-width: 34rem;
}

.mat-texts { position: relative; min-height: 24rem; }
.mat-text {
  position: absolute; top: 0; left: 0; right: 0;
  opacity: 0;
  visibility: hidden;
}
.mat-text.is-current { opacity: 1; visibility: visible; }

.mat-name {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(2.6rem, 5vw, 4.6rem);
  line-height: 1;
  margin-bottom: 0.8rem;
}
.mat-name em { font-style: italic; color: var(--champagne); }
.mat-spec {
  font-family: var(--sans); font-size: 0.62rem;
  letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--champagne-dim);
  margin-bottom: 1.4rem;
}
.mat-body { font-size: 1.08rem; line-height: 1.65; color: #c9c6bf; max-width: 28rem; }

.mat-index {
  margin-top: 2.2rem;
  font-family: var(--sans); font-size: 0.62rem;
  letter-spacing: 0.32em;
  color: var(--grey);
}
.mat-index__n { color: var(--champagne); }

/* ---------- ACT 4 · edition — pinned zoom ---------- */

.edition-stage {
  position: relative;
  min-height: 100vh; min-height: 100dvh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  text-align: center;
}

.edition__bg {
  position: absolute; inset: 0;
  opacity: 0.2;
}
.edition__bg img {
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(0.7) brightness(0.7);
  transform: scale(1.15);
}
.edition-stage::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 50% 50%, transparent 25%, var(--black) 92%);
}

.edition__content { position: relative; z-index: 1; padding: clamp(5rem, 10vh, 8rem) 1.5rem; }

.edition__number {
  font-family: var(--serif);
  font-weight: 300; font-style: italic;
  font-size: clamp(9rem, 28vw, 24rem);
  line-height: 0.8;
  color: transparent;
  -webkit-text-stroke: 1px rgba(216, 189, 138, 0.65);
  font-variant-numeric: tabular-nums;
}

.edition__body {
  margin-top: clamp(2rem, 4vh, 3rem);
  font-size: clamp(1.1rem, 1.7vw, 1.4rem);
  line-height: 1.7; color: #b8b5ae;
}
.edition__body em { color: var(--champagne); font-style: italic; }

.edition__grid {
  list-style: none;
  margin: clamp(2.5rem, 5vh, 4rem) auto 0;
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 0.9rem 1.6rem;
  max-width: 44rem;
  font-family: var(--sans); font-size: 0.72rem; font-weight: 300;
  letter-spacing: 0.18em;
  font-variant-numeric: tabular-nums;
}
.edition__grid li { color: var(--champagne); }
.edition__grid li.is-taken {
  color: rgba(141, 139, 133, 0.5);
  text-decoration: line-through;
  text-decoration-color: rgba(216, 189, 138, 0.4);
  text-decoration-thickness: 1px;
}

.edition__note {
  margin-top: 2.2rem;
  font-family: var(--sans); font-size: 0.62rem;
  letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--champagne-dim);
}

/* ---------- ACT 5 · atelier — full-bleed bench ---------- */

.act--atelier {
  min-height: 100vh; min-height: 100dvh;
  display: flex; align-items: center;
  overflow: hidden;
}

.atelier__bg {
  position: absolute; inset: -12% 0;
}
.atelier__bg img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.08) brightness(0.42);
}
.act--atelier::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(6, 6, 7, 0.85) 0%, rgba(6, 6, 7, 0.5) 55%, rgba(6, 6, 7, 0.2) 100%);
}

.atelier__content {
  position: relative; z-index: 1;
  padding: clamp(6rem, 14vh, 10rem) clamp(1.5rem, 6vw, 7rem);
}

.notes {
  display: flex; flex-direction: column;
  gap: clamp(2.5rem, 6vh, 4.5rem);
  max-width: 30rem;
}
.note { display: flex; gap: 2rem; align-items: baseline; }
.note__date {
  font-family: var(--sans); font-size: 0.62rem;
  letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--champagne-dim);
  min-width: 5.5rem;
}
.note__body {
  font-size: clamp(1.15rem, 1.8vw, 1.5rem);
  line-height: 1.55; font-style: italic;
}

/* ---------- ACT 6 · allocation ---------- */

.allocation {
  position: relative;
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  min-height: 90vh;
  justify-content: center;
  padding: clamp(6rem, 14vh, 11rem) clamp(1.5rem, 6vw, 7rem);
}

.allocation__body {
  margin-top: clamp(2rem, 4vh, 3rem);
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
  line-height: 1.75; color: var(--grey);
}

.allocation__cta { margin-top: clamp(3rem, 6vh, 4.5rem); }

.magnet {
  display: inline-block;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.45rem;
  background: rgba(244, 241, 234, 0.04);
  border: 1px solid rgba(216, 189, 138, 0.22);
  will-change: transform;
}
.magnet__inner {
  display: flex; align-items: center; gap: 1.4rem;
  border-radius: 999px;
  padding: 1.05rem 0.55rem 1.05rem 2.2rem;
  background: linear-gradient(135deg, rgba(216, 189, 138, 0.14), rgba(216, 189, 138, 0.05));
  box-shadow: inset 0 1px 1px rgba(244, 241, 234, 0.12);
  transition: background 0.7s var(--ease-cinema);
}
.magnet:hover .magnet__inner {
  background: linear-gradient(135deg, rgba(216, 189, 138, 0.22), rgba(216, 189, 138, 0.08));
}
.magnet__label {
  font-family: var(--sans); font-size: 0.72rem; font-weight: 400;
  letter-spacing: 0.34em; text-transform: uppercase;
  color: var(--white);
  padding-right: 0.6rem;
}
.magnet__ring {
  width: 2.9rem; height: 2.9rem; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  background: var(--champagne);
  color: var(--black);
  transition: transform 0.7s var(--ease-cinema);
}
.magnet:hover .magnet__ring { transform: translate(3px, -1px) scale(1.06); }
.magnet__arrow { font-size: 1rem; transform: rotate(-45deg); transition: transform 0.7s var(--ease-cinema); }
.magnet:hover .magnet__arrow { transform: rotate(0deg); }
.magnet:active { transform: scale(0.98); }

.allocation__mail {
  margin-top: 2.4rem;
  font-family: var(--sans); font-size: 0.62rem;
  letter-spacing: 0.32em;
  color: var(--grey);
}

/* ---------- footer ---------- */

.foot {
  position: relative; z-index: 10;
  display: flex; justify-content: space-between; gap: 1.5rem;
  padding: 2.2rem clamp(1.5rem, 6vw, 7rem) 2.6rem;
  border-top: 1px solid rgba(244, 241, 234, 0.07);
  font-family: var(--sans); font-size: 0.6rem; font-weight: 300;
  letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--grey);
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .truths { grid-template-columns: 1fr; gap: 3.5rem; }
  .truth:nth-child(even) { transform: none; }
  .mat-copy { left: 1.25rem; right: 1.25rem; bottom: 9vh; }
  .mat-texts { min-height: 26rem; }
}

@media (max-width: 768px) {
  .chrome { padding: 1.4rem 1.25rem; }
  .hero__copy { left: 1.25rem; right: 1.25rem; }
  .hero__scroll { position: static; margin-top: 2.2rem; }
  .act--calibre .act__flow, .atelier__content { padding-left: 1.25rem; padding-right: 1.25rem; }
  .note { flex-direction: column; gap: 0.7rem; }
  .foot { flex-direction: column; gap: 0.9rem; }
  .br-desk { display: none; }
}

/* ---------- reduced motion: freeze on posters, no pins ---------- */

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; filter: none; }
  .hero__video { display: none; }
  .js .act--calibre .act__flow { margin-top: 0; }
  .js .act--calibre .act__media { position: absolute; }
  .act--calibre .act__media video { display: none; }
  .act--calibre .act__media {
    background: url("../assets/calibre-poster.jpg") center / cover no-repeat;
  }
}
