/* Layout: a cream infinite wall of black and white frames, chrome pinned to the four corners. */
:root {
  --cream: #F2ECE0;
  --cream-deep: #E8E0D0;
  --ink: #161616;
  --ink-soft: #6E675C;
  --frost: rgba(242, 236, 224, 0.86);
  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-flight: cubic-bezier(0.76, 0, 0.18, 1);
  --gutter: max(20px, env(safe-area-inset-left, 0px));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px));
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font);
  font-variation-settings: "wdth" 100;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; margin: -1px; padding: 0;
}

/* ---------- Preloader ---------- */
.loader {
  --mark-w: min(88vw, 1240px);
  position: fixed;
  inset: 0;
  z-index: 50;
  background: var(--cream);
  display: grid;
  place-items: center;
}
.loader.is-gone { display: none; }

.loader__mark {
  width: var(--mark-w);
  aspect-ratio: 1600 / 139;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  background: var(--ink);
  position: relative;
}
.loader__reel { position: absolute; inset: 0; }
.loader__reel img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  opacity: 0;
}
.loader__reel img.is-on { opacity: 1; }

.loader__foot {
  position: absolute;
  left: var(--gutter);
  bottom: max(22px, env(safe-area-inset-bottom, 0px));
}
.loader__count {
  font-size: clamp(48px, 6.6vw, 96px);
  font-weight: 600;
  font-variation-settings: "wdth" 72;
  line-height: 0.85;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

/* Film burn between the loader and the wall */
.burn {
  position: fixed;
  inset: 0;
  z-index: 70;
  pointer-events: none;
  background: #F4EFE6;
  opacity: 0;
  visibility: hidden;
}
.burn video { width: 100%; height: 100%; object-fit: cover; display: block; }
.burn.is-on { opacity: 1; visibility: visible; }
.burn.is-out { opacity: 0; visibility: visible; transition: opacity 380ms ease; }

/* ---------- Corner chrome ---------- */
.chrome {
  position: fixed;
  z-index: 20;
  color: var(--cream);
  mix-blend-mode: difference;
  pointer-events: none;
}
.chrome img { filter: invert(1) sepia(0.12); }
.chrome a, .chrome button { pointer-events: auto; }

.chrome--top {
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: max(20px, env(safe-area-inset-top, 0px)) var(--gutter-r) 0 var(--gutter);
}
.brand { display: block; width: clamp(170px, 19vw, 280px); }

.nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.4vw, 34px);
  font-size: 13px;
  font-weight: 600;
  font-variation-settings: "wdth" 112;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding-top: 2px;
}
.nav a { position: relative; padding: 4px 0; }
.nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 400ms var(--ease-out);
}
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }
.nav__ig::after { display: none; }
.nav__ig svg { width: 18px; height: 18px; display: block; fill: none; stroke: currentColor; stroke-width: 1.6; }
.nav__ig .dot { fill: currentColor; stroke: none; }
.nav a:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }

.chrome--bl {
  left: var(--gutter);
  bottom: max(26px, env(safe-area-inset-bottom, 0px));
  font-size: 11px;
  font-weight: 600;
  font-variation-settings: "wdth" 112;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.chrome--br {
  right: var(--gutter-r);
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
}
.chrome--br img { width: 46px; }

/* Chrome waits for the loader */
.chrome, .ic__toggle { opacity: 0; transition: opacity 600ms ease 500ms; }
body.is-ready .chrome, body.is-ready .ic__toggle, .chrome.is-on, .ic__toggle.is-shown { opacity: 1; }
body.is-quick .chrome, body.is-quick .ic__toggle { transition-delay: 0ms; }

/* ---------- Infinite canvas ---------- */
.ic {
  position: fixed;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  overscroll-behavior: contain;
  cursor: grab;
  outline: none;
}
.ic.is-dragging { cursor: grabbing; }
.ic:focus-visible::after {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--ink);
  pointer-events: none;
}

.ic__parallax { position: absolute; inset: 0; pointer-events: none; will-change: transform; }
.ic__world {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  will-change: transform;
  pointer-events: none;
  opacity: 0;
  transition: opacity 320ms ease;
}
.ic__world.is-shown { opacity: 1; }
.ic__world:not(.is-shown) .card { pointer-events: none; }

.card {
  position: absolute;
  z-index: 0;
  left: 0;
  top: 0;
  margin: 0;
  transform-origin: top left;
  pointer-events: auto;
}

.card__frame {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--cream-deep);
}
.card__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  filter: grayscale(1) contrast(1.04);
  transition: filter 450ms ease;
  -webkit-user-drag: none;
}
.card:hover { z-index: 2; }
.card:hover .card__img { filter: grayscale(0) contrast(1); transition-duration: 300ms; }

/* Corner brackets, Explore only. Counter-scaled so they read the same on every frame. */
.card__brackets { display: none; }
.ic__world .card__brackets {
  --k: calc(1 / (var(--size) * var(--scale)));
  --t: calc(1.5px * var(--k));
  --l: calc(15px * var(--k));
  --o: calc(-9px * var(--k));
  display: block;
  position: absolute;
  inset: var(--o);
  pointer-events: none;
  background:
    linear-gradient(var(--ink), var(--ink)) left top / var(--l) var(--t) no-repeat,
    linear-gradient(var(--ink), var(--ink)) left top / var(--t) var(--l) no-repeat,
    linear-gradient(var(--ink), var(--ink)) right top / var(--l) var(--t) no-repeat,
    linear-gradient(var(--ink), var(--ink)) right top / var(--t) var(--l) no-repeat,
    linear-gradient(var(--ink), var(--ink)) left bottom / var(--l) var(--t) no-repeat,
    linear-gradient(var(--ink), var(--ink)) left bottom / var(--t) var(--l) no-repeat,
    linear-gradient(var(--ink), var(--ink)) right bottom / var(--l) var(--t) no-repeat,
    linear-gradient(var(--ink), var(--ink)) right bottom / var(--t) var(--l) no-repeat;
  transition: inset 350ms var(--ease-out);
}
.ic__world .card:hover .card__brackets { inset: calc(var(--o) * 1.7); }

/* Caption sits under the bottom-left corner after a short rest */
.card__cap {
  position: absolute;
  left: 0;
  top: 100%;
  display: grid;
  gap: 5px;
  padding-top: 12px;
  transform-origin: top left;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  translate: 0 4px;
  transition: opacity 160ms ease, translate 160ms ease;
}
/* Captions are counter-scaled so the type is always its true size */
.ic__world .card__cap { transform: scale(calc(1 / (var(--size) * var(--scale)))); }
.card:hover .card__cap {
  opacity: 1;
  translate: 0 0;
  transition: opacity 200ms ease 90ms, translate 200ms ease 90ms;
}
.ic.is-dragging .card__cap, .ic.is-moving .card__cap { opacity: 0; transition: none; }
.card__client {
  font-size: 10.5px;
  font-weight: 600;
  font-variation-settings: "wdth" 115;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
}
.card__title {
  font-size: 19px;
  font-weight: 500;
  font-variation-settings: "wdth" 88;
  line-height: 1.05;
  letter-spacing: -0.005em;
  color: var(--ink);
}
.card__role {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
}

/* ---------- List: an index of every film ---------- */
.ic__list {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  visibility: hidden;
  cursor: auto;
  scrollbar-width: none;
}
.ic__list::-webkit-scrollbar { display: none; }
.index {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(110px, 14vh, 150px) var(--gutter-r) 160px var(--gutter);
}
.index__head,
.row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1.05fr) minmax(0, 2.6fr) minmax(0, 1.2fr) 92px;
  gap: 20px;
  align-items: center;
}
.index__head {
  padding: 0 18px 12px;
  font-size: 10.5px;
  font-weight: 600;
  font-variation-settings: "wdth" 115;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.index__rows { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid rgba(22, 22, 22, 0.16); }
.row {
  width: 100%;
  min-height: 86px;
  padding: 16px 18px;
  border: 0;
  border-top: 1px solid rgba(22, 22, 22, 0.16);
  background: transparent;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease;
}
.row:hover, .row:focus-visible { background: var(--ink); color: var(--cream); outline: none; }
.row__num {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
}
.row:hover .row__num, .row:focus-visible .row__num { color: rgba(242, 236, 224, 0.6); }
.row__client, .row__role, .row__cta {
  font-size: 11px;
  font-weight: 600;
  font-variation-settings: "wdth" 115;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  line-height: 1.5;
}
.row__title {
  font-size: clamp(22px, 2.5vw, 38px);
  font-weight: 650;
  font-variation-settings: "wdth" 76;
  line-height: 1;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  text-wrap: balance;
}
.row__cta { display: flex; align-items: center; justify-content: flex-end; gap: 10px; opacity: 0.4; transition: opacity 200ms ease; }
.row__cta svg { width: 16px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.4; transition: transform 300ms var(--ease-out); }
.row:hover .row__cta, .row:focus-visible .row__cta { opacity: 1; }
.row:hover .row__cta svg { transform: translateX(4px); }

/* Rows cascade in when the List opens */
.ic__list .index { opacity: 0; transition: opacity 220ms ease; }
.ic.is-list-in .ic__list .index { opacity: 1; }
.ic.is-list-in .row { animation: rowIn 560ms var(--ease-out) both; animation-delay: calc(var(--k) * 22ms); }
@keyframes rowIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* The frame that follows the cursor over the list */
.index__peek {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 30;
  width: clamp(200px, 20vw, 300px);
  aspect-ratio: 16 / 9;
  pointer-events: none;
  opacity: 0;
  scale: 0.92;
  transition: opacity 220ms ease, scale 320ms var(--ease-out);
  will-change: transform;
}
.index__peek.is-on { opacity: 1; scale: 1; }
.index__peek img { width: 100%; height: 100%; object-fit: cover; display: block; max-width: none; }
.ic:not(.is-list) ~ .index__peek, .ic:not(.is-list) .index__peek { opacity: 0; }

/* The wall steps back while the list is up */
.ic.is-list .ic__world { opacity: 0; transition: opacity 300ms ease; }

/* Explore / List / Hello bar, shared by both pages */
.ic__toggle {
  position: fixed;
  z-index: 3;
  left: 50%;
  bottom: max(28px, calc(env(safe-area-inset-bottom, 0px) + 12px));
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: var(--frost);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 0 0 1px rgba(22, 22, 22, 0.08);
  transform: translateX(-50%);
}
.ic__toggle button, .ic__toggle a {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 34px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 11.5px;
  font-weight: 600;
  font-variation-settings: "wdth" 115;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transition: background-color 250ms ease, color 250ms ease;
}
.ic__toggle svg { fill: currentColor; }
.ic__toggle .is-active { background: var(--ink); color: var(--cream); }
.ic__toggle button:not(.is-active):hover, .ic__toggle a:not(.is-active):hover { background: rgba(22, 22, 22, 0.07); }
.ic__toggle a:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; }
.ic__sep { width: 1px; align-self: stretch; margin: 7px 2px; background: rgba(22, 22, 22, 0.16); }
.ic__toggle button:disabled { cursor: progress; }
.ic__toggle button:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; }

/* ---------- Player ---------- */
.player {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: var(--ink);
  color: var(--cream);
  display: grid;
  grid-template-rows: auto 1fr auto;
  padding: max(18px, env(safe-area-inset-top, 0px)) var(--gutter-r) max(18px, env(safe-area-inset-bottom, 0px)) var(--gutter);
  opacity: 0;
  transition: opacity 380ms ease;
}
.player.is-open { opacity: 1; }
.player__bar { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; }
.player__meta { display: grid; gap: 6px; min-width: 0; }
.player__client {
  font-size: 11px; font-weight: 600; font-variation-settings: "wdth" 115;
  letter-spacing: 0.14em; text-transform: uppercase;
}
.player__title {
  font-size: clamp(22px, 3vw, 36px); font-weight: 500; font-variation-settings: "wdth" 85;
  line-height: 1.05; text-wrap: balance;
}
.player__role { font-size: 13px; color: rgba(242, 236, 224, 0.6); }
.player__close {
  display: flex; align-items: center; gap: 10px;
  background: none; border: 0; padding: 8px 0; cursor: pointer;
  font-size: 11.5px; font-weight: 600; font-variation-settings: "wdth" 115;
  letter-spacing: 0.16em; text-transform: uppercase;
}
.player__close svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 1.6; fill: none; }
.player__close:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }
.player__stage { display: grid; place-items: center; min-height: 0; padding: 20px 0; }
.player__frame {
  width: min(100%, calc((100vh - 220px) * 16 / 9));
  aspect-ratio: 16 / 9;
  background: #000;
  transform: scale(0.97);
  transition: transform 600ms var(--ease-out);
}
.player.is-open .player__frame { transform: none; }
.player__frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.player__out { position: relative; display: block; width: 100%; height: 100%; }
.player__out img { width: 100%; height: 100%; object-fit: cover; opacity: 0.55; }
.player__out span {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  padding: 14px 26px; border-radius: 999px; background: var(--cream); color: var(--ink);
  font-size: 12px; font-weight: 600; font-variation-settings: "wdth" 115; letter-spacing: 0.16em; text-transform: uppercase;
}
.player__link {
  justify-self: start;
  font-size: 11.5px; font-weight: 600; font-variation-settings: "wdth" 115;
  letter-spacing: 0.16em; text-transform: uppercase;
  border-bottom: 1px solid currentColor; padding-bottom: 3px;
}

/* ---------- Star cursor ---------- */
.star {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 60;
  width: 26px;
  height: 26px;
  pointer-events: none;
  mix-blend-mode: difference;
  opacity: 0;
  transition: opacity 200ms ease;
  will-change: transform;
}
.star svg { width: 100%; height: 100%; display: block; fill: var(--cream); }
.star.is-visible { opacity: 1; }

@media (hover: hover) and (pointer: fine) {
  body.has-star, body.has-star * { cursor: none !important; }
}

/* ---------- Small screens ---------- */
@media (max-width: 760px) {
  .index__head { display: none; }
  .row { grid-template-columns: 30px minmax(0, 1fr) auto; grid-template-areas: "num client cta" "num title title" "num role role"; row-gap: 6px; min-height: 0; padding: 18px 8px; }
  .row__num { grid-area: num; align-self: start; padding-top: 2px; }
  .row__client { grid-area: client; }
  .row__title { grid-area: title; font-size: 24px; }
  .row__role { grid-area: role; color: var(--ink-soft); }
  .row__cta { grid-area: cta; }
  .brand { width: 160px; }
  .nav { gap: 14px; font-size: 11px; letter-spacing: 0.1em; }
  .chrome--bl { display: none; }
  .chrome--br { display: none; }
  .ic__toggle button, .ic__toggle a { padding: 0 13px; gap: 8px; letter-spacing: 0.12em; }
}


@media (prefers-reduced-motion: reduce) {
  .loader, .loader__mark, .ic__world, .ic__list .index { transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .ic.is-list-in .row { animation: none; }
}
