/* ==========================================================================
   Samik Roy Choudhary — Portfolio
   Page styles. Tokens come from colors_and_type.css.
   ========================================================================== */

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: auto; }
body {
  background: var(--bg);
  color: var(--fg);
  cursor: none;
  overflow-x: hidden;
}
@media (hover: none) {
  body { cursor: auto; }
  .cursor-dot, .cursor-ring { display: none !important; }
}

::selection { background: var(--obsidian-black); color: var(--cream-white); }

img { display: block; max-width: 100%; }
button { font: inherit; cursor: none; }

/* ==========================================================================
   HOVER DESATURATE
   Colour drains out of the whole page while the cursor rests on something
   clickable, and washes back in as it leaves. The filter sits on <html> on
   purpose: the root element is exempt from the rule that a filtered element
   becomes the containing block for its fixed-position descendants, so the
   nav, cursor and overlays keep their positioning.

   The wash is deliberately slow and symmetrically eased: the decelerating
   curves used elsewhere on the site front-load almost all of the change into
   the first fraction of the duration, which reads as a snap however long the
   duration is. Colour returns a little slower than it drains, so leaving an
   element feels like a wash rather than a switch flipping back.
   ========================================================================== */
html {
  transition: filter 640ms var(--ease-wash);   /* colour washing back in */
}
html.ui-desaturate {
  filter: grayscale(1);
  transition-duration: 480ms;                  /* colour draining out */
}

/* Touch devices have no real hover state - never strand them in greyscale. */
@media (hover: none) {
  html.ui-desaturate { filter: none; }
}

/* ==========================================================================
   CUSTOM CURSOR
   ========================================================================== */
.cursor-dot, .cursor-ring {
  position: fixed; top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  will-change: transform;
  mix-blend-mode: difference;
}
.cursor-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #fff;
  transform: translate(-50%, -50%);
}
.cursor-ring {
  width: 30px; height: 30px;
  border-radius: 50%;
  border: 1px solid #fff;
  transform: translate(-50%, -50%);
  transition: width 320ms var(--ease-cinema),
              height 320ms var(--ease-cinema),
              opacity 320ms var(--ease-cinema);
}
.cursor-ring.hover { width: 56px; height: 56px; }
.cursor-ring.tile-hover { width: 72px; height: 72px; }

/* ==========================================================================
   TOP PROGRESS BAR
   ========================================================================== */
.progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 1.5px;
  width: 0%;
  background: var(--obsidian-black);
  z-index: 90;
  transition: opacity 320ms var(--ease-cinema);
  opacity: 0;
  pointer-events: none;
}
.progress-bar.visible { opacity: 1; }
.progress-bar.on-dark { background: var(--cream-white); }

/* ==========================================================================
   FIXED NAV
   ========================================================================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 32px;
  z-index: 60;
  background: rgba(247, 245, 240, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 0.5px solid var(--warm-sand);
  opacity: 0;
  pointer-events: none;
  transition: opacity 600ms var(--ease-cinema),
              background 400ms var(--ease-cinema),
              border-color 400ms var(--ease-cinema);
}
.nav.visible {
  opacity: 1;
  pointer-events: auto;
}
.nav.on-dark {
  background: rgba(17, 17, 17, 0.55);
  border-bottom: 0.5px solid rgba(247, 245, 240, 0.14);
}
.nav-links {
  display: flex;
  gap: 40px;
  align-items: center;
}
.nav-link {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--obsidian-black);
  border: 0;
  background: transparent;
  padding: 6px 0;
  position: relative;
  transition: color 320ms var(--ease-cinema), opacity 200ms;
}
.nav.on-dark .nav-link { color: var(--cream-white); }
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 200ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .nav-link:hover::after { transform: scaleX(1); transform-origin: left; }
}
.nav-link.active::after { transform: scaleX(1); transform-origin: left; }
.nav-link:active { transform: scale(0.96); }

/* Hamburger toggle + dropdown — the signature docks into this bar's left
   edge on scroll (see HeroStage) and measurably collides with an inline
   Work/About/Contact row on every phone width, so below 720px the links
   move into a dropdown instead of fighting the signature for space. */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  gap: 5px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: none;
}
.nav-burger span {
  width: 20px;
  height: 1.5px;
  background: currentColor;
  transition: transform 280ms var(--ease-cinema), opacity 200ms var(--ease-cinema), width 200ms var(--ease-cinema);
}
.nav-burger span:nth-child(2) { width: 14px; }
@media (hover: hover) and (pointer: fine) {
  .nav-burger:hover span { width: 20px; }
}
.nav.menu-open .nav-burger span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); width: 20px; }
.nav.menu-open .nav-burger span:nth-child(2) { opacity: 0; }
.nav.menu-open .nav-burger span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); width: 20px; }

.nav-mobile-menu {
  display: none;
  position: absolute;
  top: 100%; left: 0; right: 0;
  flex-direction: column;
  padding: 8px 32px 20px;
  background: inherit;             /* continues the nav bar's own translucent fill */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 0.5px solid var(--warm-sand);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 240ms var(--ease-cinema), transform 240ms var(--ease-cinema);
}
.nav.on-dark .nav-mobile-menu { border-bottom-color: rgba(247, 245, 240, 0.14); }
.nav.menu-open .nav-mobile-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.nav-mobile-link {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: inherit;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 14px 0;
  border-top: 0.5px solid var(--border);
}
.nav.on-dark .nav-mobile-link { border-top-color: rgba(247, 245, 240, 0.14); }
.nav-mobile-link:first-child { border-top: 0; }
.nav-mobile-link:active { opacity: 0.6; }

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-burger { display: flex; }
  .nav-mobile-menu { display: flex; }
}

/* ==========================================================================
   HERO STAGE — fixed, single shared layer for phases 1–4
   ========================================================================== */
.hero-stage {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
}

/* The signature element transforms from large-centered → top-left nav slot */
.signature {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 85;
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--cream-white);
  line-height: 1;
  white-space: nowrap;
  transform-origin: top left;
  font-size: 96px;
  letter-spacing: 0;
  pointer-events: auto;
  cursor: none;
  will-change: transform, font-size, color;
  transition: color 600ms var(--ease-cinema);
  transform: translate(-50%, -50%);
}
@media (max-width: 720px) {
  /* The signature is position:fixed, so body's overflow-x:hidden can't clip it —
     at a flat 56px it runs 430px wide and drags a sideways scrollbar onto every
     phone narrower than that. Tying it to vw keeps it inside the viewport. */
  .signature { font-size: min(56px, 12vw); }
}
.signature.on-dark { color: var(--cream-white); }

/* Handwritten variant (SIGNATURE_MODE in app.jsx): sized by width instead of
   font-size; the aspect ratio matches assets/signature/signature.png so the
   scroll-docking maths has real dimensions before the art has loaded. */
.signature.is-handwritten {
  width: min(600px, 78vw);
  aspect-ratio: 1316 / 816;
  font-size: 0;
}
.signature.is-handwritten canvas,
.signature.is-handwritten img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.signature.is-handwritten [hidden] { display: none; }
/* The signature carries its own underline flourish. */
.sig-meta.is-handwritten .underline { display: none; }
.sig-meta.is-handwritten .director-label { transition-delay: 150ms; }

/* Eyebrow + animated underline that fades out as the signature flies away. */
.sig-meta {
  position: fixed;
  top: 50%; left: 50%;
  z-index: 84;
  transform: translate(-50%, calc(-50% + 64px));
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  will-change: opacity, transform;
}
.sig-meta .underline {
  width: 0;
  height: 1px;
  background: var(--cream-white);
  margin-bottom: 18px;
  transition: width 1400ms var(--ease-cinema) 700ms,
              background 600ms var(--ease-cinema);
}
.sig-meta.drawn .underline { width: 220px; }
.sig-meta .director-label {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--fg-muted);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 700ms var(--ease-cinema) 600ms,
              transform 700ms var(--ease-cinema) 600ms,
              color 600ms var(--ease-cinema);
}
.sig-meta.drawn .director-label {
  opacity: 1;
  transform: translateY(0);
}
@media (max-width: 720px) {
  .sig-meta.drawn .underline { width: 140px; }
}

/* Scroll hint at the bottom of phase 1 */
.scroll-hint {
  position: absolute;
  bottom: 36px; left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  font-family: var(--font-sans);
  font-size: 10px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  opacity: 0;
  transition: opacity 600ms var(--ease-cinema), color 400ms var(--ease-cinema);
  pointer-events: none;
}
.scroll-hint.visible { opacity: 1; }
.scroll-hint.on-dark { color: rgba(247,245,240,0.55); }
.scroll-hint .line {
  width: 1px; height: 40px;
  background: currentColor;
  opacity: 0.6;
  transform-origin: top;
  animation: hint-pulse 2.4s var(--ease-cinema) infinite;
}
@keyframes hint-pulse {
  0%, 100% { transform: scaleY(0.25); opacity: 0.2; }
  45% { transform: scaleY(1); opacity: 0.7; }
  60% { transform: scaleY(1); opacity: 0.7; }
}

/* ==========================================================================
   COLLAGE — asymmetric grid of 5 looping reels
   ========================================================================== */
.collage-bg {
  position: absolute;
  inset: 0;
  background: #000; /* pure black — matches directors-work sticky bg exactly */
  opacity: 0;
  will-change: opacity;
  transition: opacity 700ms var(--ease-cinema);
}
.collage-bg.visible { opacity: 1; }

/* --------------------------------------------------------------------------
   HERO COLLAGE
   Fills the whole screen behind the signature on load — a uniform contact
   sheet of prints, greyscaled and held at 25% so it reads as texture on the
   black rather than as pictures. 12 photos sit flush in a 4×3 grid, each
   filling its own cell exactly — no rotation, offset, or overlap.
   The container's opacity is driven by scroll (see HeroStage) and the tiles
   animate their own opacity on entry, so the two multiply together.
   -------------------------------------------------------------------------- */
.hero-collage {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 0;
  opacity: 0;                /* JS sets the real value on first scroll tick */
  filter: grayscale(1);
  overflow: hidden;          /* clip the spill at the screen edge */
  pointer-events: none;
  will-change: opacity;
}
.hero-collage-tile {
  width: 100%;
  height: 100%;
  overflow: hidden;
  opacity: 0;
  animation: collage-pop 900ms var(--ease-cinema) forwards;
}
.hero-collage-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;         /* fill the cell evenly whatever the source ratio */
  object-position: center;
  display: block;
}
/* Tall full-body shots: a centred crop pushes the face above the frame, so
   anchor to the top instead. See COLLAGE_FACE_NEAR_TOP in app.jsx. */
.hero-collage-tile img.face-top {
  object-position: center top;
}
@keyframes collage-pop {
  from { opacity: 0; transform: scale(1.05); }
  to   { opacity: 1; transform: scale(1); }
}

/* Portrait screens: 3 across, 4 down — same 12 tiles, still covered. */
@media (max-width: 720px) {
  .hero-collage {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-collage-tile {
    animation: none;
    opacity: 1;
  }
}

.collage {
  position: absolute;
  inset: 88px 32px 64px 32px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
  gap: 12px;
  opacity: 0;
  transform: scale(1.04);
  will-change: opacity, transform;
  transition: opacity 700ms var(--ease-cinema), transform 1200ms var(--ease-cinema);
}
.collage.visible {
  opacity: 1;
  transform: scale(1);
}
@media (max-width: 720px) {
  .collage { inset: 80px 16px 56px 16px; gap: 8px; }
}

.tile {
  position: relative;
  overflow: hidden;
  background: #1a1a1a;
  pointer-events: auto;
  cursor: none;
  transition: transform 700ms var(--ease-cinema);
}
.tile-large  { grid-column: 1 / span 2; grid-row: 1 / span 3; }
.tile-tr     { grid-column: 3 / span 2; grid-row: 1 / span 2; }
.tile-br     { grid-column: 3 / span 2; grid-row: 3 / span 2; }
.tile-bl1    { grid-column: 1 / span 1; grid-row: 4 / span 1; }
.tile-bl2    { grid-column: 2 / span 1; grid-row: 4 / span 1; }

.tile .still,
.tile video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.04) brightness(0.92);
}
.tile .still {
  background-size: cover;
  background-position: center;
  animation: kenburns 26s var(--ease-cinema) infinite alternate;
  transition: transform 1400ms var(--ease-cinema), filter 600ms var(--ease-cinema);
}
.tile video {
  opacity: 0;
  transition: opacity 700ms var(--ease-cinema), transform 1400ms var(--ease-cinema), filter 600ms var(--ease-cinema);
}
.tile:hover video {
  opacity: 1;
}
.tile.kb2 .still { animation-duration: 30s; animation-delay: -8s; }
.tile.kb3 .still { animation-duration: 28s; animation-delay: -16s; }
.tile.kb4 .still { animation-duration: 32s; animation-delay: -4s; }
.tile.kb5 .still { animation-duration: 26s; animation-delay: -20s; }
@keyframes kenburns {
  0%   { transform: scale(1.06) translate(-1.2%, -0.8%); }
  100% { transform: scale(1.18) translate(1.4%, 1%); }
}

.tile::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(17,17,17,0) 38%, rgba(17,17,17,0.78) 100%);
  pointer-events: none;
  transition: opacity 500ms var(--ease-cinema);
}
.tile:hover::after { opacity: 0.65; }
.tile:hover .still,
.tile:hover video {
  transform: scale(1.06);
  filter: saturate(0.95) contrast(1.06) brightness(1);
}
.tile:hover video {
  opacity: 1;
}

.tile-index {
  position: absolute;
  top: 14px; left: 18px;
  z-index: 2;
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: rgba(247,245,240,0.55);
}
.tile-caption {
  position: absolute;
  left: 18px; right: 18px; bottom: 16px;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  color: var(--cream-white);
}
.tile-title {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(18px, 1.6vw, 26px);
  line-height: 1.05;
  letter-spacing: -0.005em;
}
.tile-meta {
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  opacity: 0.78;
  white-space: nowrap;
  text-align: right;
}
.tile.tile-bl1 .tile-title,
.tile.tile-bl2 .tile-title { font-size: clamp(16px, 1.2vw, 18px); }

/* ==========================================================================
   SCROLL TRACK — keeps enough room for the slow cream→black hero transition
   ========================================================================== */
.scroll-track {
  height: calc(240px + 62vh);
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* Cross-fade veil */
.fade-veil {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: #000;
  opacity: 0;
  pointer-events: none;
  will-change: opacity;
}

/* ==========================================================================
   CONTENT (sections after the hero)
   ========================================================================== */
.content {
  position: relative;
  z-index: 30;
  background: var(--bg);
}
.section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 96px 32px;
}
@media (min-width: 900px) {
  .section { padding: 128px 64px; }
}
@media (min-width: 1280px) {
  .section { padding: 160px 96px; }
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 18px;
  border-bottom: 0.5px solid var(--border);
  margin-bottom: 56px;
}
/* Side by side, the tracked-out meta ("Press · Festivals · Development")
   collapses into a cramped stack jammed against the right edge on a phone. */
@media (max-width: 560px) {
  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
}
.section-title {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: clamp(28px, 3.6vw, 48px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0;
}
.section-meta {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

/* ----- Selected works (editorial list) ----- */
.films-list {
  display: flex;
  flex-direction: column;
  border-top: 0.5px solid var(--warm-sand);
}
.film-row {
  display: grid;
  grid-template-columns: 56px 1fr 180px 90px;
  gap: 24px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 0.5px solid var(--warm-sand);
  position: relative;
  cursor: none;
  transition: padding 420ms var(--ease-cinema);
}
.film-row:hover { padding-left: 16px; padding-right: 16px; }
.film-row .num {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.32em;
  color: var(--fg-subtle);
}
.film-row .title {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: clamp(20px, 2.2vw, 30px);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.film-row .title em {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 0.78em;
  font-style: italic;
  letter-spacing: 0;
  text-transform: none;
  color: var(--fg-muted);
  margin-left: 14px;
}
.film-row .meta {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-muted);
  text-align: left;
}
.film-row .arrow {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  color: var(--obsidian-black);
  text-align: right;
  opacity: 0.4;
  transition: opacity 320ms var(--ease-cinema), transform 420ms var(--ease-cinema);
}
.film-row:hover .arrow { opacity: 1; transform: translateX(8px); }

/* Floating still that follows the cursor over the film list */
.row-preview {
  position: fixed;
  width: 360px;
  aspect-ratio: 3 / 2;
  background-size: cover;
  background-position: center;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.92);
  transition: opacity 320ms var(--ease-cinema), transform 600ms var(--ease-cinema);
  z-index: 35;
  box-shadow: 0 30px 60px -20px rgba(17,17,17,0.4);
  filter: saturate(0.85) contrast(1.04);
}
.row-preview.visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}
@media (max-width: 900px) {
  .row-preview { display: none; }
  .film-row { grid-template-columns: 36px 1fr; gap: 12px; }
  .film-row .meta, .film-row .arrow { display: none; }
}

/* ----- About ----- */
.about {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 900px) {
  .about { grid-template-columns: 1fr; gap: 32px; }
}
.about-portrait-wrap {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.about-portrait {
  aspect-ratio: 4 / 5;
  background-size: cover;
  background-position: center;
  filter: saturate(0.85) contrast(1.04);
}
.about-know-more {
  align-self: flex-start;
  display: inline-block;
  text-align: center;
  width: 100%;
}
.about-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(24px, 2.6vw, 36px);
  line-height: 1.25;
  margin: 0 0 36px;
  color: var(--fg);
}
.about-body p {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 15px;
  line-height: 1.7;
  color: var(--fg);
  margin: 0 0 18px;
  max-width: 56ch;
  text-wrap: pretty;
}
.about-body p em { font-style: italic; color: var(--fg); }
.about-meta {
  margin-top: 36px;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 8px 24px;
  border-top: 0.5px solid var(--border);
  padding-top: 24px;
}
.about-meta dt {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin: 0;
}
.about-meta dd {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 400;
  color: var(--fg);
  margin: 0;
}

/* ----- About section reveal animations ----- */
.about-anim {
  opacity: 0;
  transform: translateY(20px);
}
@media (prefers-reduced-motion: reduce) {
  .about-anim {
    transform: none;
  }
}

/* ----- Contact ----- */
.contact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: end;
  padding: 32px 0 64px;
}
@media (max-width: 900px) {
  .contact { grid-template-columns: 1fr; gap: 32px; }
}
.contact-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(28px, 3.4vw, 48px);
  line-height: 1.18;
  margin: 0;
  max-width: 14ch;
  text-wrap: balance;
}
.contact-right {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contact-email {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: clamp(22px, 2.4vw, 32px);
  letter-spacing: 0.04em;
  color: var(--fg);
  border-bottom: 0.5px solid var(--border-strong);
  padding-bottom: 6px;
  align-self: flex-start;
  transition: opacity 320ms var(--ease-cinema);
}
.contact-email:hover { opacity: 0.6; }
.contact-meta {
  display: flex;
  gap: 36px;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-top: 8px;
}
.contact-cta {
  display: inline-flex;
  gap: 12px;
  margin-top: 16px;
}
.btn {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  padding: 16px 28px;
  background: var(--cream-white);
  color: var(--obsidian-black);
  border: 0.5px solid var(--cream-white);
  transition: background 200ms var(--ease-out), color 200ms var(--ease-out),
              transform 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: transparent; color: var(--cream-white); }
  .btn-secondary:hover { background: var(--cream-white); color: var(--obsidian-black); }
}
.btn:active { transform: scale(0.97); }
.btn-secondary {
  background: transparent;
  color: var(--cream-white);
  border-color: var(--btn-secondary-bd);
}

/* ----- Footer ----- */
.footer {
  border-top: 0.5px solid var(--border);
  padding: 48px 32px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  align-items: center;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-muted);
}
@media (min-width: 900px) {
  .footer { padding: 56px 64px; }
}
@media (max-width: 720px) {
  .footer { grid-template-columns: 1fr; text-align: center; }
}
.footer-brand {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 28px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--cream-white);
}
.footer-signature {
  height: 72px;
  width: auto;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;          /* four tracked-out links can't fit one line on a phone,
                               and unwrapped they blow the grid column past the viewport */
  gap: 16px 28px;
  justify-content: center;
}
.footer-links a {
  color: var(--fg-muted);
  border-bottom: 0;
  transition: color 320ms var(--ease-cinema);
}
.footer-links a:hover { color: var(--cream-white); opacity: 1; }
.footer-right { text-align: right; }
@media (max-width: 720px) {
  .footer-right { text-align: center; }
}

/* ==========================================================================
   FILM DETAIL OVERLAY
   ========================================================================== */
.film-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  overflow-y: auto;
  opacity: 0;
  transform: scale(0.98);
  pointer-events: none;
  transition: opacity 380ms var(--ease-out), transform 380ms var(--ease-out);
}
.film-overlay.visible {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}
.film-overlay-close {
  position: fixed;
  top: 24px; right: 32px;
  z-index: 210;
  background: transparent;
  border: 0;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--cream-white);
  padding: 10px 16px;
  transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .film-overlay-close:hover { opacity: 0.6; }
}
.film-overlay-close:active { transform: scale(0.95); }
.film-detail-hero {
  height: 70vh;
  min-height: 480px;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  filter: saturate(0.85) contrast(1.04) brightness(0.78);
}
.film-detail-hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.film-detail-hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 30%, rgba(0,0,0,0.7) 100%);
}
.film-detail-overlay-text {
  position: absolute;
  bottom: 56px; left: 32px; right: 32px;
  z-index: 2;
  color: var(--cream-white);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.film-overlay.visible .film-detail-eyebrow {
  animation: credit-in 300ms var(--ease-out) 60ms both;
}
.film-overlay.visible .film-detail-title {
  animation: credit-in 360ms var(--ease-out) 100ms both;
}
.film-overlay.visible .trailer-btn {
  animation: credit-in 320ms var(--ease-out) 160ms both;
}
@media (min-width: 900px) {
  .film-detail-overlay-text { left: 64px; right: 64px; bottom: 72px; }
}
.film-detail-eyebrow {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  opacity: 0.78;
}
.film-detail-title {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: clamp(40px, 6vw, 88px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
  line-height: 1;
}
.film-detail-body {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 64px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 96px 32px;
}
@media (max-width: 900px) {
  .film-detail-body { grid-template-columns: 1fr; gap: 32px; padding: 64px 24px; }
}
.film-detail-credits dl {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
.film-detail-credits dl > div {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 16px;
  border-top: 0.5px solid var(--border);
  padding-top: 14px;
  opacity: 0;
  transform: translateY(6px);
  animation: credit-in 320ms var(--ease-out) forwards;
}
@keyframes credit-in {
  to { opacity: 1; transform: translateY(0); }
}
.film-overlay.visible .film-detail-credits dl > div:nth-child(1) { animation-delay: 120ms; }
.film-overlay.visible .film-detail-credits dl > div:nth-child(2) { animation-delay: 170ms; }
.film-overlay.visible .film-detail-credits dl > div:nth-child(3) { animation-delay: 220ms; }
.film-overlay.visible .film-detail-credits dl > div:nth-child(4) { animation-delay: 270ms; }
.film-overlay.visible .film-detail-credits dl > div:nth-child(5) { animation-delay: 320ms; }
.film-overlay.visible .film-detail-credits dl > div:nth-child(6) { animation-delay: 370ms; }
.film-detail-credits dt {
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}
.film-detail-credits dd {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 300;
  color: var(--fg);
  margin: 0;
}
.film-detail-prose p {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.7;
  color: var(--fg-muted);
  margin: 0 0 22px;
  max-width: 60ch;
  text-wrap: pretty;
}
.film-detail-prose blockquote {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.3;
  margin: 32px 0;
  color: var(--fg);
  padding-left: 24px;
  border-left: 1px solid var(--border-strong);
}

/* Watch Trailer button */
.trailer-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding: 10px 18px;
  background: transparent;
  border: 1px solid rgba(247, 245, 240, 0.55);
  color: var(--cream-white);
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: none;
  transition: background 320ms var(--ease-cinema),
              border-color 320ms var(--ease-cinema);
}
@media (hover: hover) and (pointer: fine) {
  .trailer-btn:hover {
    background: rgba(247, 245, 240, 0.12);
    border-color: rgba(247, 245, 240, 0.9);
  }
}
.trailer-btn:active {
  transform: scale(0.97);
  background: rgba(247, 245, 240, 0.18);
}
.trailer-btn-play {
  font-size: 9px;
  opacity: 0.8;
}

/* Trailer video lightbox */
.trailer-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transform: scale(1);
  transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out);

  @starting-style {
    opacity: 0;
    transform: scale(0.97);
  }
}
.trailer-modal-close {
  position: absolute;
  top: 24px; right: 32px;
  background: transparent;
  border: 0;
  color: rgba(247, 245, 240, 0.7);
  font-size: 20px;
  cursor: none;
  transition: color 160ms var(--ease-out), transform 160ms var(--ease-out);
  z-index: 510;
  padding: 8px;
}
@media (hover: hover) and (pointer: fine) {
  .trailer-modal-close:hover { color: var(--cream-white); }
}
.trailer-modal-close:active { transform: scale(0.93); }
.trailer-modal-video {
  width: 88vw;
  max-width: 1200px;
  max-height: 80vh;
  outline: none;
  box-shadow: 0 24px 80px rgba(0,0,0,0.7);
}
/* YouTube embed — same footprint as the <video> lightbox, locked to 16:9
   since an iframe has no intrinsic size of its own. */
.trailer-modal-frame {
  width: 88vw;
  max-width: 1200px;
  max-height: 80vh;
  aspect-ratio: 16 / 9;
  border: 0;
  outline: none;
  box-shadow: 0 24px 80px rgba(0,0,0,0.7);
}

/* ==========================================================================
   DIRECTOR'S WORK — tabbed landscape carousel (Films / Commercials)
   ========================================================================== */
.work-carousel {
  position: relative;
  width: 100%;
  padding: 92px 0 104px;   /* no side padding — the slide runs full-bleed */
}
@media (min-width: 900px) {
  .work-carousel { padding: 104px 0 120px; }
}

/* ----- Header: title + category tabs (kept inset from the edges) ----- */
.wc-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding: 0 24px 20px;
  border-bottom: 0.5px solid var(--border);
  margin: 0 24px 30px;
}
@media (min-width: 900px) {
  .wc-head { padding: 0 48px 20px; margin: 0 48px 30px; }
}
.wc-title {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: clamp(24px, 3.4vw, 44px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0;
  color: var(--fg);
}
.wc-tabs {
  display: flex;
  gap: 8px;
}
.wc-tab {
  position: relative;
  background: transparent;
  border: 0;
  padding: 8px 4px 10px;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  cursor: none;
  transition: color 320ms var(--ease-cinema);
}
.wc-tab + .wc-tab { margin-left: 24px; }
.wc-tab::after {
  content: "";
  position: absolute;
  left: 4px; right: 4px; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 260ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .wc-tab:hover { color: var(--fg-muted); }
  .wc-tab:hover::after { transform: scaleX(1); transform-origin: left; }
}
.wc-tab.active { color: var(--fg); }
.wc-tab.active::after { transform: scaleX(1); transform-origin: left; }

/* ----- Stage: full-bleed slide with arrows overlaid on its edges ----- */
.wc-stage {
  position: relative;
  width: 100%;
}
/* Sized viewport that holds the stacked, cross-fading slides */
.wc-slides {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 78vh;         /* keep header + slide + dots within the viewport */
  overflow: hidden;
  background: var(--bg-elevated);
}
/* Each slide is layered on top of the others and cross-dissolves in/out */
.wc-slide {
  position: absolute;
  inset: 0;
  cursor: none;
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
  will-change: opacity, transform;
  /* Symmetric ease → both slides blend evenly through the midpoint (film dissolve) */
  transition: opacity 1200ms cubic-bezier(0.45, 0, 0.55, 1),
              transform 1800ms var(--ease-cinema);
}
.wc-slide.active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
  z-index: 1;
}

.wc-slide-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background-size: cover;
  background-position: center;
  filter: saturate(0.92) contrast(1.04);
}
/* Gentle, continuous drift on the visible slide so it never feels frozen */
.wc-slide.active .wc-slide-media:not(.wc-contain) {
  animation: wc-drift 14s ease-in-out infinite alternate;
}

/* Portrait posters — letterboxed on a blurred fill of themselves */
.wc-slide-media.wc-contain {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: none;
  background: #050505;
}
.wc-slide-blur {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(48px) saturate(0.7) brightness(0.34);
  transform: scale(1.2);
}
.wc-slide-poster {
  position: relative;
  z-index: 1;
  height: 94%;
  width: auto;
  max-width: 78%;
  object-fit: contain;
  box-shadow: 0 30px 70px -20px rgba(0, 0, 0, 0.85);
}
/* Scrim for text legibility — layered, matches reference's dim centre */
.wc-slide-scrim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 90% at 50% 45%, rgba(0,0,0,0) 30%, rgba(0,0,0,0.42) 100%),
    linear-gradient(180deg, rgba(0,0,0,0.28) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0.35) 100%);
  pointer-events: none;
}
.wc-slide-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
  color: var(--cream-white);
  padding: 24px;
  pointer-events: none;
}
/* Poster slides already show their own title — sit the View button low so it
   doesn't cover the poster's focal art. */
.wc-slide-content.no-title {
  justify-content: flex-end;
  padding-bottom: 7%;
}
.wc-slide-title {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: clamp(24px, 3.4vw, 46px);
  letter-spacing: 0.08em;
  line-height: 1.1;
  margin: 0;
  text-shadow: 0 2px 30px rgba(0,0,0,0.4);
}
.wc-slide-sub {
  font-family: var(--font-sans);
  font-size: clamp(11px, 1vw, 13px);
  font-weight: 400;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: rgba(247, 245, 240, 0.72);
  margin: 0;
}
.wc-view {
  pointer-events: auto;
  margin-top: 22px;
  padding: 12px 34px;
  background: transparent;
  border: 1px solid rgba(247, 245, 240, 0.6);
  color: var(--cream-white);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  cursor: none;
  transition: background 260ms var(--ease-out), border-color 260ms var(--ease-out),
              transform 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .wc-view:hover {
    background: rgba(247, 245, 240, 0.12);
    border-color: rgba(247, 245, 240, 0.95);
  }
}
.wc-view:active { transform: scale(0.97); }

/* ----- Arrows: overlaid on the slide edges ----- */
.wc-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
  color: rgba(247, 245, 240, 0.7);
  font-size: 24px;
  line-height: 1;
  cursor: none;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.6);
  transition: color 260ms var(--ease-out), transform 260ms var(--ease-out);
}
.wc-arrow-prev { left: 18px; }
.wc-arrow-next { right: 18px; }
@media (hover: hover) and (pointer: fine) {
  .wc-arrow:hover { color: var(--cream-white); }
  .wc-arrow-prev:hover { transform: translateY(-50%) translateX(-4px); }
  .wc-arrow-next:hover { transform: translateY(-50%) translateX(4px); }
}
.wc-arrow:active { transform: translateY(-50%) scale(0.9); }
@media (max-width: 720px) {
  .wc-arrow { width: 40px; font-size: 20px; }
  .wc-arrow-prev { left: 6px; }
  .wc-arrow-next { right: 6px; }
}

/* ----- Dots ----- */
.wc-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 34px;
}
.wc-dot {
  width: 7px;
  height: 7px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  background: rgba(247, 245, 240, 0.28);
  cursor: none;
  transition: background 260ms var(--ease-out), transform 260ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .wc-dot:hover { background: rgba(247, 245, 240, 0.6); }
}
.wc-dot.active {
  background: var(--cream-white);
  transform: scale(1.25);
}

/* Slow ambient zoom on the active slide so a held frame stays alive */
@keyframes wc-drift {
  from { transform: scale(1.008); }
  to   { transform: scale(1.06); }
}

/* ==========================================================================
   Reduced motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .tile .still { animation: none !important; }
}
