/* ==========================================================================
   lemagnifique.studio — Magnifique Lapse (@studiolemagnifique)
   A24 / MUBI / Criterion Cinema Identity · Bahnschrift · Zero AI Slop
   ========================================================================== */

:root {
  /* Palette A (Default): 35mm Champagne — Criterion / A24 */
  --bg: #0A0A09;
  --surface: #141311;
  --surface-raised: #1B1917;
  --ink: #ECE8E1;
  --accent: #D4C5AE;
  --accent-dim: rgba(212, 197, 174, 0.36);
  --muted: #8E877D;
  --hairline: rgba(236, 232, 225, 0.11);
  --hairline-strong: rgba(236, 232, 225, 0.24);
  --on-accent: #0A0A09;

  /* Typography */
  --font-display: 'Bahnschrift', 'DIN Alternate', 'Barlow Semi Condensed', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Bahnschrift', 'Barlow Semi Condensed', 'Segoe UI', system-ui, sans-serif;

  /* Motion tokens (Emil Kowalski / animate skill) */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);

  /* Layout */
  --wrap-max: 1320px;
  --gutter: clamp(20px, 4vw, 48px);
  --nav-h: 72px;
}

/* Optional Palette B: Antique Bronze (set data-palette="bronze" on <html>) */
:root[data-palette="bronze"] {
  --bg: #0E0C0B;
  --surface: #191513;
  --surface-raised: #221D1A;
  --ink: #F0ECE4;
  --accent: #A88B67;
  --accent-dim: rgba(168, 139, 103, 0.40);
  --muted: #8C8074;
  --on-accent: #0E0C0B;
}

/* Optional Palette C: Pale Sand & Ash (set data-palette="sand" on <html>) */
:root[data-palette="sand"] {
  --bg: #0B0B0B;
  --surface: #161615;
  --surface-raised: #1F1F1D;
  --ink: #F3F1EC;
  --accent: #C2B5A3;
  --accent-dim: rgba(194, 181, 163, 0.38);
  --muted: #858079;
  --on-accent: #0B0B0B;
}

/* Reset & Platform Layer (mobile-native + craft-floor) */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  background-color: var(--bg);
  color: var(--ink);
  min-height: 100svh;
  overflow-x: clip;
}

/* Browser surfaces (craft-floor) */
::selection {
  background: var(--accent);
  color: var(--on-accent);
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg);
}
::-webkit-scrollbar-thumb {
  background: #2C2925;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}

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

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

a {
  color: inherit;
  text-decoration: none;
  touch-action: manipulation;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.tabular {
  font-variant-numeric: tabular-nums;
}

/* Skip link */
.skip-link {
  position: fixed;
  top: -100px;
  left: var(--gutter);
  z-index: 200;
  background: var(--accent);
  color: var(--on-accent);
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: transform 180ms var(--ease-out);
}
.skip-link:focus {
  top: 14px;
}

/* Equal-edge container */
.wrap {
  width: min(var(--wrap-max), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
}

/* ==========================================================================
   Navigation — Full-Bleed Editorial Hairline
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: calc(var(--nav-h) + env(safe-area-inset-top));
  padding-top: env(safe-area-inset-top);
  border-bottom: 1px solid transparent;
  transition: background-color 260ms var(--ease-out), border-color 260ms var(--ease-out);
}

.site-header.is-scrolled {
  background-color: rgba(10, 10, 9, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--hairline);
}

.nav-inner {
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  user-select: none;
}

.brand-mark {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

.brand-mark .bar {
  transform-box: fill-box;
  transform-origin: bottom;
}

@media (hover: hover) and (pointer: fine) {
  .brand-link:hover .bar-1 {
    animation: barPulse 420ms var(--ease-out) 0ms both;
  }
  .brand-link:hover .bar-2 {
    animation: barPulse 420ms var(--ease-out) 60ms both;
  }
  .brand-link:hover .bar-3 {
    animation: barPulse 420ms var(--ease-out) 110ms both;
  }
}

@keyframes barPulse {
  0% { transform: scaleY(0.45); }
  100% { transform: scaleY(1); }
}

.brand-wordmark {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  white-space: nowrap;
}

.brand-wordmark span {
  font-weight: 300;
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  position: relative;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 10px 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  transition: color 180ms ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 240ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .nav-links a:hover {
    color: var(--ink);
  }
  .nav-links a:hover::after {
    transform: scaleX(1);
  }
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Unified Button Pair (One System) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 22px;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 1px solid transparent;
  transition: transform 150ms var(--ease-out), background-color 180ms ease, color 180ms ease, border-color 180ms ease;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}

@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    background: var(--ink);
    border-color: var(--ink);
  }
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--hairline-strong);
}

@media (hover: hover) and (pointer: fine) {
  .btn-ghost:hover {
    border-color: var(--accent);
    color: var(--accent);
  }
}

.nav-cta {
  min-height: 40px;
  padding: 0 18px;
  font-size: 11.5px;
}

/* Mobile Menu Toggle */
.menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hairline-strong);
}

.menu-btn:active {
  transform: scale(0.96);
}

.menu-drawer {
  position: fixed;
  inset: 0;
  z-index: 150;
  height: 100dvh;
  background: var(--bg);
  padding: calc(var(--nav-h) + 28px + env(safe-area-inset-top)) var(--gutter) calc(32px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 240ms var(--ease-drawer), transform 240ms var(--ease-drawer), visibility 240ms;
}

.menu-drawer.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.drawer-close {
  position: absolute;
  top: calc(14px + env(safe-area-inset-top));
  right: var(--gutter);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hairline-strong);
  font-size: 20px;
}

.drawer-nav {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.drawer-nav a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--hairline);
}

.drawer-foot {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.drawer-foot .btn {
  width: 100%;
}

/* ==========================================================================
   Section 1: Full-Bleed Cinema Hero (100svh)
   ========================================================================== */
.hero {
  position: relative;
  min-height: min(100svh, 980px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-top: calc(var(--nav-h) + 40px);
  padding-bottom: clamp(36px, 6vh, 76px);
  overflow: hidden;
  border-bottom: 1px solid var(--hairline);
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--bg);
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.68;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 10, 9, 0.65) 0%, rgba(10, 10, 9, 0.16) 44%, rgba(10, 10, 9, 0.90) 92%, #0A0A09 100%),
    linear-gradient(90deg, rgba(10, 10, 9, 0.74) 0%, rgba(10, 10, 9, 0.10) 58%, rgba(10, 10, 9, 0.42) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
  align-items: end;
  gap: 36px;
}

.hero-content > * {
  min-width: 0;
}

.hero-mark-lockup {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}

.hero-mark-svg {
  width: 44px;
  height: 44px;
}

.hero-mark-svg .bar {
  transform-box: fill-box;
  transform-origin: bottom;
  animation: slabRise 520ms var(--ease-out) both;
}
.hero-mark-svg .bar-1 { animation-delay: 80ms; }
.hero-mark-svg .bar-2 { animation-delay: 150ms; }
.hero-mark-svg .bar-3 { animation-delay: 205ms; }

@keyframes slabRise {
  0% { transform: scaleY(0.16); opacity: 0; }
  100% { transform: scaleY(1); opacity: 1; }
}

.hero-studio-label {
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: lowercase;
  color: var(--accent);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5.8vw, 5.1rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: 0.015em;
  max-width: 14ch;
  color: var(--ink);
}

.hero-lead {
  margin-top: 22px;
  font-size: clamp(1rem, 1.3vw, 1.2rem);
  line-height: 1.55;
  color: rgba(236, 232, 225, 0.82);
  max-width: 46ch;
}

.hero-actions {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-aside {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 20px;
}

.reel-hud {
  width: 100%;
  max-width: 390px;
  min-width: 0;
  border-top: 1px solid var(--hairline-strong);
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.reel-hud-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.reel-tc {
  color: var(--accent);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}

.reel-chapter {
  color: var(--ink);
  text-align: right;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.reel-progress {
  width: 100%;
  height: 2px;
  background: var(--hairline-strong);
  overflow: hidden;
}

.reel-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 120ms linear;
}

.reel-pips {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}

.reel-pip {
  min-height: 36px;
  border: 1px solid var(--hairline);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--muted);
  transition: border-color 180ms ease, color 180ms ease, background-color 180ms ease, transform 140ms var(--ease-out);
}

.reel-pip:active {
  transform: scale(0.96);
}

.reel-pip.is-active {
  border-color: var(--accent);
  color: var(--on-accent);
  background: var(--accent);
}

@media (hover: hover) and (pointer: fine) {
  .reel-pip:not(.is-active):hover {
    border-color: var(--hairline-strong);
    color: var(--ink);
  }
}

/* ==========================================================================
   Section 3: Blender (.blend) Download Table & About Lead
   ========================================================================== */
.download-table {
  border-top: 1px solid var(--hairline-strong);
}

.dl-row {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.7fr) minmax(0, 0.9fr) auto;
  gap: 16px 24px;
  align-items: center;
  padding: 20px 0;
  border-bottom: 1px solid var(--hairline);
}

.dl-head {
  padding: 12px 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.dl-name {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dl-name strong {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--ink);
  word-break: break-word;
}

.dl-name span {
  font-size: 13.5px;
  color: var(--muted);
}

.dl-meta {
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--accent);
}

.dl-btn {
  min-height: 40px;
  padding: 0 16px;
  font-size: 11.5px;
}

.dl-status {
  margin-top: 16px;
  min-height: 22px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--accent);
}

.about-lead {
  font-size: clamp(1.05rem, 1.35vw, 1.25rem);
  line-height: 1.6;
  color: var(--ink);
  margin-bottom: 28px;
  max-width: 52ch;
}

.inline-link {
  color: var(--accent);
  border-bottom: 1px solid var(--accent-dim);
  transition: border-color 160ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .inline-link:hover {
    border-bottom-color: var(--accent);
  }
}

@media (max-width: 900px) {
  .dl-head {
    display: none;
  }
  .dl-row {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 22px 0;
  }
  .dl-btn {
    width: 100%;
    margin-top: 6px;
  }
}

.reel-toggle {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--hairline-strong);
  background: rgba(10, 10, 9, 0.56);
  backdrop-filter: blur(8px);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
  transition: border-color 180ms ease, color 180ms ease, transform 150ms var(--ease-out);
}

.reel-toggle:active {
  transform: scale(0.97);
}

@media (hover: hover) and (pointer: fine) {
  .reel-toggle:hover {
    border-color: var(--accent);
    color: var(--accent);
  }
}

/* Hero single-pass entrance (data-enter) */
[data-enter] .enter-1 {
  animation: heroEnter 540ms var(--ease-out) 0ms both;
}
[data-enter] .enter-2 {
  animation: heroEnter 540ms var(--ease-out) 85ms both;
}
[data-enter] .enter-3 {
  animation: heroEnter 540ms var(--ease-out) 150ms both;
}

@keyframes heroEnter {
  0% { opacity: 0; transform: translateY(14px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Section 2: Film Archive (5 Completed Blender 3D Monument Films)
   ========================================================================== */
.section {
  padding-block: clamp(72px, 10vh, 128px);
  border-bottom: 1px solid var(--hairline);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 28px;
  margin-bottom: 40px;
  border-bottom: 1px solid var(--hairline);
}

.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.4vw, 3rem);
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.05;
}

.section-note {
  font-size: 14px;
  color: var(--muted);
  max-width: 40ch;
  text-align: right;
}

/* Asymmetric Screening Grid: 1 flagship lead + 2x2 archive */
.film-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 44px 32px;
}

.film-item {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
  width: 100%;
  transition: transform 240ms var(--ease-out);
}

.film-item.is-featured {
  grid-column: 1 / -1;
}

@media (hover: hover) and (pointer: fine) {
  .film-item:hover {
    transform: translateY(-2px);
  }
}

.film-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--surface);
  overflow: hidden;
  border: 1px solid var(--hairline);
}

.film-item.is-featured .film-frame {
  aspect-ratio: 21 / 9;
}

.film-poster,
.film-preview {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 460ms var(--ease-out), opacity 280ms ease;
}

.film-preview {
  opacity: 0;
  pointer-events: none;
}

.film-item.is-playing .film-preview {
  opacity: 1;
}

@media (hover: hover) and (pointer: fine) {
  .film-item:hover .film-poster,
  .film-item:hover .film-preview {
    transform: scale(1.03);
  }
}

.film-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 58%, rgba(10, 10, 9, 0.62) 100%);
  pointer-events: none;
}

.film-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 5px 10px;
  background: rgba(10, 10, 9, 0.72);
  border: 1px solid var(--hairline-strong);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--ink);
  pointer-events: none;
}

.film-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-top: 4px;
  border-top: 1px solid var(--hairline);
}

.film-title {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 1.6vw, 1.5rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ink);
  transition: color 180ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .film-item:hover .film-title {
    color: var(--accent);
  }
}

.film-span {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.10em;
  color: var(--accent);
  white-space: nowrap;
}

/* ==========================================================================
   Section 3: Method — Real 3D Craft (Asymmetric Split, No SaaS Cards)
   ========================================================================== */
.method-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.method-list {
  list-style: none;
  border-top: 1px solid var(--hairline);
}

.method-row {
  padding: 24px 0;
  border-bottom: 1px solid var(--hairline);
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 16px;
  align-items: baseline;
}

.method-num {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--accent);
}

.method-row h3 {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.method-row p {
  font-size: 15px;
  color: var(--muted);
  max-width: 48ch;
}

.method-visual {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.method-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid var(--hairline);
  background: var(--surface);
}

.method-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.method-pledge {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}

.pledge-cell {
  padding: 18px 16px 18px 0;
  border-right: 1px solid var(--hairline);
}

.pledge-cell:not(:first-child) {
  padding-left: 18px;
}

.pledge-cell:last-child {
  border-right: none;
}

.pledge-k {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.pledge-v {
  margin-top: 5px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ink);
}

/* ==========================================================================
   Section 4: Pre-Footer Channel Band (Elevated Cinema Surface)
   ========================================================================== */
.channel-band {
  background: var(--surface);
  padding-block: clamp(72px, 11vh, 124px);
  border-bottom: 1px solid var(--hairline);
}

.channel-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 36px;
  align-items: center;
}

.channel-inner h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.4rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: 0.02em;
  max-width: 16ch;
}

.channel-copy {
  margin-top: 16px;
  font-size: 16px;
  color: var(--muted);
  max-width: 48ch;
}

.channel-cta-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
}

.channel-handle {
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--accent);
}

/* ==========================================================================
   Footer — Sitemap + Full-Width Signature Wordmark
   ========================================================================== */
.site-footer {
  padding-top: 64px;
  padding-bottom: calc(36px + env(safe-area-inset-bottom));
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 0.7fr));
  gap: 36px;
  padding-bottom: 52px;
  border-bottom: 1px solid var(--hairline);
}

.footer-desc {
  margin-top: 14px;
  font-size: 14px;
  color: var(--muted);
  max-width: 36ch;
}

.footer-col h3 {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-col a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  font-size: 14px;
  color: var(--muted);
  transition: color 160ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .footer-col a:hover {
    color: var(--ink);
  }
}

.credits-disclosure {
  border-bottom: 1px solid var(--hairline);
  padding: 18px 0;
}

.credits-disclosure summary {
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  user-select: none;
  transition: color 160ms ease;
}

.credits-disclosure summary::-webkit-details-marker {
  display: none;
}

.credits-disclosure summary::after {
  content: "+";
  font-size: 16px;
  color: var(--accent);
}

.credits-disclosure[open] summary::after {
  content: "−";
}

@media (hover: hover) and (pointer: fine) {
  .credits-disclosure summary:hover {
    color: var(--ink);
  }
}

.credits-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 16px;
  padding-bottom: 8px;
}

.credits-grid strong {
  display: block;
  font-size: 12px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}

.credits-grid p {
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}

@media (max-width: 900px) {
  .credits-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.footer-signature {
  padding-top: 28px;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 10.6vw, 9.2rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 0.92;
  color: rgba(236, 232, 225, 0.08);
  user-select: none;
  text-align: center;
  overflow: hidden;
}

.footer-bottom {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

/* ==========================================================================
   Screening Room Modal (Keyboard & Screen-Reader Accessible)
   ========================================================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 220;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 40px);
  background: rgba(6, 6, 5, 0.88);
  backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 220ms var(--ease-out), visibility 220ms;
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
}

.modal-panel {
  width: min(980px, 100%);
  max-height: calc(100dvh - 48px);
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--hairline-strong);
  transform: scale(0.96);
  transition: transform 240ms var(--ease-out);
}

.modal.is-open .modal-panel {
  transform: scale(1);
}

.modal-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--hairline);
}

.modal-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.modal-close {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hairline-strong);
  font-size: 20px;
}

.modal-video-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--bg);
}

.modal-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-body {
  padding: 24px 24px 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 28px;
  align-items: end;
}

.modal-span {
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 8px;
}

.modal-summary {
  font-size: 15px;
  color: rgba(236, 232, 225, 0.84);
  line-height: 1.6;
}

.modal-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

/* ==========================================================================
   Responsive Breakpoints (1024 / 768 / 390 / 320)
   ========================================================================== */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .hero-aside {
    align-items: flex-start;
  }
  .method-grid,
  .channel-inner,
  .modal-body {
    grid-template-columns: 1fr;
  }
  .channel-cta-col,
  .modal-actions {
    align-items: flex-start;
  }
  .footer-top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .nav-links,
  .nav-cta {
    display: none;
  }
  .menu-btn {
    display: inline-flex;
  }
  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }
  .section-note {
    text-align: left;
  }
  .film-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .film-item.is-featured .film-frame {
    aspect-ratio: 16 / 9;
  }
  .method-pledge {
    grid-template-columns: 1fr;
  }
  .pledge-cell {
    border-right: none;
    border-bottom: 1px solid var(--hairline);
    padding: 14px 0 !important;
  }
  .pledge-cell:last-child {
    border-bottom: none;
  }
  .footer-top {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .hero-actions .btn,
  .channel-cta-col .btn {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .brand-wordmark {
    font-size: 12px;
    letter-spacing: 0.12em;
  }
  .reel-hud {
    max-width: 100%;
  }
  .reel-hud-top {
    font-size: 10px;
  }
  .hero h1 {
    font-size: 2.3rem;
  }
}

/* Reduced Motion (animate + choreograph + taste-skill) */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
