/* ============================================================
   Monochrome system — hierarchy comes from weight, width, size & space,
   never from colour. Greys are white at reduced opacity.
   Display face: Anybody, whose wdth (50–150) and wght (100–900) axes are
   pushed to their extremes and morph on interaction.
   ============================================================ */
:root {
  --bg: #000;
  --bg-2: #0a0a0a;
  --fg: #fff;
  --fg-2: rgba(255, 255, 255, .64);
  --fg-3: rgba(255, 255, 255, .40);
  --fg-4: rgba(255, 255, 255, .18);
  --line: rgba(255, 255, 255, .14);
  /* Per-language CJK faces (overridden below for ko / ja) */
  --cjk: "Noto Sans SC";
  --cjk-display: "Noto Sans SC";   /* Black (900): heavy, dense gothic in the spirit of Dela Gothic One */
  --cjk-weight: 900;
  --cjk-track: -.03em;
  --sans: "Inter Tight", var(--cjk), "PingFang SC", system-ui, sans-serif;
  --mono: "JetBrains Mono", var(--cjk), ui-monospace, monospace;
  --display: "Anybody", "Inter Tight", var(--cjk), sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --morph: font-stretch .7s var(--ease), font-weight .7s var(--ease), letter-spacing .7s var(--ease);
  --gutter: clamp(16px, 3.2vw, 48px);
  --radius: 6px;   /* grid thumbnails only — list rows stay square */
  --rail-w: clamp(163px, 14.4vw, 228px);
  --rail-gap: 16px;
}
:root[data-lang="ko"] { --cjk: "Noto Sans KR"; --cjk-display: "Black Han Sans"; --cjk-weight: 400; --cjk-track: .02em; }
:root[data-lang="ja"] { --cjk: "Noto Sans JP"; --cjk-display: "Dela Gothic One"; --cjk-weight: 400; --cjk-track: .02em; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
/* Film grain over everything */
body::after {
  content: ""; position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -4%); }
  60% { transform: translate(-4%, -1%); }
  80% { transform: translate(3%, 3%); }
}
@keyframes rise { to { transform: none; } }
@keyframes fadeUp { to { opacity: 1; transform: none; } }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes scan { 0% { transform: translateX(-100%); } 60%, 100% { transform: translateX(100%); } }

::selection { background: var(--fg); color: var(--bg); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
img, video { display: block; max-width: 100%; }
:focus-visible { outline: 1px solid var(--fg); outline-offset: 4px; }

.mono {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: .06em;
  text-transform: uppercase;
}

/* ---------- Custom cursor (fine pointers only) ---------- */
.cursor { display: none; }
@media (pointer: fine) {
  .has-cursor, .has-cursor a, .has-cursor button, .has-cursor [data-i] { cursor: none; }
  .cursor {
    display: flex; align-items: center; justify-content: center;
    position: fixed; top: 0; left: 0; z-index: 200; pointer-events: none;
    width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%;
    background: #fff; mix-blend-mode: difference;
    transition: width .45s var(--ease), height .45s var(--ease), margin .45s var(--ease), opacity .3s;
    will-change: transform;
  }
  .cursor span {
    font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase;
    color: #000; opacity: 0; transition: opacity .2s;
  }
  .cursor.is-link { width: 36px; height: 36px; margin: -18px 0 0 -18px; }
  .cursor.is-label { width: 84px; height: 84px; margin: -42px 0 0 -42px; mix-blend-mode: normal; }
  .cursor.is-label span { opacity: 1; transition-delay: .1s; }
  .cursor.is-hidden { opacity: 0; }
}

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 22px var(--gutter);
  mix-blend-mode: difference;
  pointer-events: none;
  transition: transform .7s var(--ease);
}
.nav.nav-hidden { transform: translateY(-110%); }
.nav > * { pointer-events: auto; }
/* keep the nav clear of the rail on the hero */
@media (min-width: 901px) { .nav { padding-right: calc(var(--rail-w) + var(--gutter)); } }

/* Language switch: one rectangle, four cells, a white slab slides to the active one */
.lang-switch {
  position: relative; display: grid; grid-template-columns: repeat(4, 1fr);
  width: 280px; height: 34px; border: 1px solid var(--fg);
  isolation: isolate; flex: none;
}
.lang-thumb {
  position: absolute; top: 0; bottom: 0; left: 0; width: 25%; z-index: -1;
  background: var(--fg);
  transform: translateX(calc(var(--i, 0) * 100%));
  transition: transform .55s var(--ease);
}
.lang-switch button { font-size: 12px; font-weight: 500; transition: color .45s var(--ease), opacity .3s; }
.lang-switch button[lang="en"] { font-family: var(--display); font-stretch: 80%; text-transform: uppercase; letter-spacing: .08em; font-size: 11px; }
.lang-switch button[lang="zh-CN"] { font-family: "Noto Sans SC", var(--sans); }
.lang-switch button[lang="ko"] { font-family: "Noto Sans KR", var(--sans); }
.lang-switch button[lang="ja"] { font-family: "Noto Sans JP", var(--sans); }
.lang-switch button[aria-checked="true"] { color: var(--bg); font-weight: 700; }
.lang-switch button[aria-checked="false"]:hover { opacity: .6; }
.lang-switch .short { display: none; }

.nav-links { display: flex; gap: clamp(18px, 2.6vw, 40px); }
.nav-links a {
  position: relative; display: inline-flex; align-items: baseline; gap: 6px;
  font-family: var(--display); font-size: 13px; font-weight: 600; font-stretch: 80%;
  letter-spacing: .05em; text-transform: uppercase; transition: var(--morph);
}
.nav-links a:hover, .nav-links a.active { font-stretch: 130%; font-weight: 800; }
.nav-links i { font-style: normal; font-family: var(--mono); font-size: 10px; color: var(--fg-3); }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease);
}
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); transform-origin: left; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  height: 100vh; height: 100svh; min-height: 640px;
  display: grid; grid-template-columns: minmax(0, 1fr) var(--rail-w);
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; background: #000; }
.hero-media video, .hero-media canvas, .hero-media iframe { opacity: .5; }
.hero-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, #000 0%, rgba(0,0,0,.55) 30%, rgba(0,0,0,0) 60%),
    linear-gradient(to right, rgba(0,0,0,.55) 0%, rgba(0,0,0,0) 55%);
}
.hero-main {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 96px var(--gutter) 36px;
  min-width: 0;
}
/* Crop marks (トンボ) at the four corners of the type area */
.hero-main::before {
  --m: var(--fg-3);
  content: ""; position: absolute; pointer-events: none;
  inset: 78px calc(var(--gutter) - 14px) 16px;
  background:
    linear-gradient(var(--m), var(--m)) top left / 16px 1px,  linear-gradient(var(--m), var(--m)) top left / 1px 16px,
    linear-gradient(var(--m), var(--m)) top right / 16px 1px, linear-gradient(var(--m), var(--m)) top right / 1px 16px,
    linear-gradient(var(--m), var(--m)) bottom left / 16px 1px,  linear-gradient(var(--m), var(--m)) bottom left / 1px 16px,
    linear-gradient(var(--m), var(--m)) bottom right / 16px 1px, linear-gradient(var(--m), var(--m)) bottom right / 1px 16px;
  background-repeat: no-repeat;
}
.hero-kicker { display: flex; align-items: center; gap: 10px; color: var(--fg-2); margin-bottom: clamp(16px, 2.4vh, 28px); }
.tag { border: 1px solid var(--fg-3); padding: 4px 8px 3px; line-height: 1; }
/* Registration target */
.reg {
  width: 15px; height: 15px; margin-right: 6px; border: 1px solid var(--fg-2); border-radius: 50%;
  background:
    linear-gradient(var(--fg-2), var(--fg-2)) center / 1px 100% no-repeat,
    linear-gradient(var(--fg-2), var(--fg-2)) center / 100% 1px no-repeat;
}
/* Vertical colophon (tategaki) down the right edge of the type area */
.hero-vert {
  position: absolute; top: 104px; right: var(--gutter);
  writing-mode: vertical-rl;
  display: flex; align-items: center; gap: 14px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .24em; text-transform: uppercase; color: var(--fg-3);
}
.hero-vert::after { content: ""; width: 1px; height: 56px; background: var(--fg-3); }

/* Name: heavy-extended words against a light-condensed initial; size set by fitName() */
.hero-name {
  align-self: flex-start;
  font-family: var(--display);
  line-height: .9; letter-spacing: -.005em; text-transform: uppercase;
  margin-left: -.03em;
}
.hero-name .line { display: block; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
.hero-name .line > span { display: inline-block; white-space: nowrap; transform: translateY(105%); animation: rise 1.2s var(--ease) forwards; }
.hero-name .line:nth-child(2) > span { animation-delay: .08s; }
.hero-name .word { white-space: nowrap; }
.hero-name .word[data-s="0"] { font-weight: 900; font-stretch: 150%; }
.hero-name .word[data-s="1"] { font-weight: 320; font-stretch: 50%; }
.hero-name .gap { display: inline-block; width: .22em; }
.hero-name .ch { display: inline-block; }

/* Role sits where a credit line would: a rule, then DIRECTOR */
.hero-role {
  display: flex; align-items: center; gap: .9em;
  margin-top: clamp(14px, 2vh, 22px);
  font-family: var(--display); font-size: clamp(14px, 1.35vw, 19px);
  font-weight: 600; font-stretch: 125%; letter-spacing: .55em; text-transform: uppercase;
  opacity: 0; transform: translateY(10px); animation: fadeUp 1s .3s var(--ease) forwards;
}
.hero-role::before { content: ""; width: 2.4em; height: 1px; background: var(--fg); }

/* Category shortcuts: each one jumps to Work with that filter on */
.hero-cats { display: flex; flex-wrap: wrap; gap: 8px clamp(20px, 3vw, 44px); margin-top: clamp(22px, 4vh, 44px); }
.hero-cats a {
  position: relative; display: inline-flex; align-items: baseline; gap: 10px;
  font-family: var(--display); font-size: clamp(18px, 1.8vw, 26px);
  font-weight: 500; font-stretch: 62%; letter-spacing: .04em; text-transform: uppercase;
  opacity: 0; transform: translateY(14px); animation: fadeUp 1s var(--ease) forwards;
  transition: var(--morph);
}
.hero-cats a i { font-style: normal; font-family: var(--mono); font-size: 10px; color: var(--fg-3); letter-spacing: .04em; }
.hero-cats a sup { position: relative; top: -.9em; font-size: 9px; color: var(--fg-3); vertical-align: baseline; }
.hero-cats a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform .6s var(--ease);
}
.hero-cats a:hover { font-weight: 850; font-stretch: 125%; }
.hero-cats a:hover::after { transform: scaleX(1); transform-origin: left; }

.hero-bottom {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
  margin-top: clamp(28px, 6vh, 72px); padding-top: 18px; border-top: 1px solid var(--line);
  opacity: 0; animation: fadeUp 1s .5s var(--ease) forwards;
}
.hero-tagline { max-width: 34ch; font-size: 14px; color: var(--fg-2); line-height: 1.5; }
.hero-scroll { display: inline-flex; align-items: center; gap: 12px; color: var(--fg-2); white-space: nowrap; }
.hero-scroll-line { position: relative; width: 48px; height: 1px; background: var(--fg-4); overflow: hidden; }
.hero-scroll-line::after {
  content: ""; position: absolute; inset: 0; background: var(--fg);
  animation: scan 2.4s var(--ease-in-out) infinite;
}

/* ---------- Rail (auto-scrolling works sidebar) ---------- */
.rail {
  position: relative; z-index: 2;
  display: flex; flex-direction: column; min-height: 0;
  border-left: 1px solid var(--line);
  background: rgba(0, 0, 0, .38);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  opacity: 0; animation: fadeIn 1.4s .3s var(--ease) forwards;
}
.rail-head, .rail-foot {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 22px 14px; color: var(--fg-2); flex: none; font-size: 10px;
}
.rail-head { border-bottom: 1px solid var(--line); }
.rail-foot { color: var(--fg-3); border-top: 1px solid var(--line); padding: 14px; line-height: 1.5; }
.rail-hint-touch { display: none; }
.rail-viewport {
  position: relative; flex: 1; min-height: 0; overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 12%, #000 88%, transparent 100%);
          mask-image: linear-gradient(to bottom, transparent 0, #000 12%, #000 88%, transparent 100%);
}
.rail-track { display: flex; flex-direction: column; gap: var(--rail-gap); padding: 18px 14px; will-change: transform; }
.rail-set { display: flex; flex-direction: column; gap: var(--rail-gap); }
.rail-item {
  display: block; width: 100%; text-align: left; opacity: .42;
  transition: opacity .6s var(--ease), transform .7s var(--ease);
}
.rail-viewport:hover .rail-item { opacity: .22; }
.rail-viewport .rail-item:hover,
.rail-viewport .rail-item:focus-visible { opacity: 1; transform: scale(1.06); }
/* Height comes from sizeRail() so ~5 works fit; falls back to 16:10 when unset (mobile) */
.rail-thumb { position: relative; width: 100%; height: var(--rail-thumb-h, auto); aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-2); }
.rail-thumb > * { width: 100%; height: 100%; object-fit: cover; }
.rail-cap { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-top: 8px; }
.rail-title {
  font-family: var(--display); font-size: 12px; font-weight: 700; font-stretch: 85%;
  letter-spacing: .03em; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rail-cap .mono { color: var(--fg-3); flex: none; }
.rail-detail { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease); }
.rail-detail > div { overflow: hidden; }
.rail-item:hover .rail-detail, .rail-item:focus-visible .rail-detail { grid-template-rows: 1fr; }
.rail-detail-inner { padding-top: 10px; }
.rail-detail .alt { font-size: 12px; font-weight: 300; color: var(--fg-2); }
.rail-detail dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 14px; margin-top: 10px; font-size: 12px; }
.rail-detail dt { font-family: var(--mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-3); padding-top: 2px; }
.rail-detail dd { font-weight: 500; }
.rail-detail .desc { margin-top: 10px; font-size: 12px; color: var(--fg-2); line-height: 1.45; }
.rail-cta {
  display: inline-flex; gap: 8px; margin-top: 12px; padding-bottom: 2px; border-bottom: 1px solid var(--fg);
  font-family: var(--display); font-size: 11px; font-weight: 700; font-stretch: 90%;
  letter-spacing: .05em; text-transform: uppercase;
}

/* ---------- Sections ---------- */
section.work, section.about, section.contact {
  position: relative; isolation: isolate;
  padding: clamp(96px, 14vw, 200px) var(--gutter) 0;
}
section.work, section.about { padding-bottom: clamp(110px, 13vw, 200px); }

/* Full-bleed looping video per section (never two side by side). Pinned while the
   section scrolls past, then the next band cuts in. overflow: clip (not hidden) trims the
   oversized cover iframes without creating a scroll container, so position: sticky keeps
   working and the iframes can't widen the mobile layout viewport. */
.sec-media { position: absolute; inset: 0; z-index: -1; overflow: clip; clip-path: inset(0); pointer-events: none; }
.sec-media-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; }
.sec-media-host { position: absolute; inset: 0; background: #000; }
.sec-media-host video, .sec-media-host canvas { filter: grayscale(.2) contrast(1.05); }
/* Work stacks one layer per filter; the active one cross-fades in */
.media-layer { position: absolute; inset: 0; opacity: 0; transition: opacity 1.2s var(--ease); }
.media-layer.on { opacity: 1; }
/* Dim + vignette so type always wins over picture */
.sec-media-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(0,0,0,.55) 0%, rgba(0,0,0,0) 35%, rgba(0,0,0,0) 70%, rgba(0,0,0,.6) 100%),
    rgba(0, 0, 0, .58);
}
.sec-media-cap { position: absolute; left: var(--gutter); bottom: 22px; max-width: 40ch; color: var(--fg-2); }
.sec-media-cap:empty { display: none; }

/* Shared media sizing: videos/canvases cover; iframes are sized by coverIframe() */
.hero-media video, .hero-media canvas, .sec-media-host video, .sec-media-host canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.hero-media iframe, .sec-media-host iframe, .live iframe {
  position: absolute; top: 50%; left: 50%; border: 0; pointer-events: none;
  transform: translate(-50%, -50%);
}

/* Section heads: towering ultra-condensed word, asymmetric side note */
.sec-head {
  position: relative;
  display: grid; grid-template-columns: auto auto minmax(0, 1fr);
  align-items: end; gap: clamp(14px, 2.4vw, 40px);
  padding: clamp(28px, 3vw, 44px) 0 clamp(18px, 2vw, 28px);
  border-bottom: 1px solid var(--line);
}
/* Section marker: a short heavy bar opening the block, Japanese-editorial style */
.sec-head::before { content: ""; position: absolute; left: 0; top: 0; width: 56px; height: 3px; background: var(--fg); }
.sec-head h2 {
  font-family: var(--display);
  font-size: clamp(6rem, 21vw, 22rem);
  font-weight: 900; font-stretch: 50%;
  line-height: .74; letter-spacing: -.012em; text-transform: uppercase;
  margin: 0 0 -.035em -.03em;
  white-space: nowrap;
}
.js .sec-head h2 { font-weight: 100; letter-spacing: .06em; transition: font-weight 1.6s var(--ease), letter-spacing 1.6s var(--ease); }
.js .sec-head.in h2 { font-weight: 900; letter-spacing: -.012em; }
.sec-head h2 sup {
  position: relative; top: .5em; margin-left: .6em; vertical-align: top;
  font-size: 12px; color: var(--fg-2);
}
/* Vertical label set beside the big word */
.sec-vert {
  align-self: start; margin-top: .6em;
  writing-mode: vertical-rl; display: flex; align-items: center; gap: 10px;
  font-size: 10px; letter-spacing: .3em; color: var(--fg-3);
}
.sec-vert::before { content: ""; width: 6px; height: 6px; background: var(--fg); }
.sec-side { justify-self: end; display: grid; gap: 10px; max-width: 30ch; text-align: right; padding-bottom: .3em; }
.sec-index { color: var(--fg-3); }
.sec-desc {
  font-family: var(--display); font-size: clamp(15px, 1.35vw, 20px); line-height: 1.15;
  font-weight: 300; font-stretch: 75%; color: var(--fg-2);
  text-wrap: balance;
}

/* ---------- Work ---------- */
.work-bar {
  display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap;
  padding: 22px 0 clamp(28px, 4vw, 56px);
}
/* Filters: condensed caps; the active one goes black & extended */
.filters { display: flex; flex-wrap: wrap; gap: 6px clamp(16px, 2vw, 30px); }
.filters button {
  position: relative; display: inline-flex; align-items: baseline; gap: 6px; padding: 4px 0;
  font-family: var(--display); font-size: clamp(14px, 1.15vw, 17px);
  font-weight: 400; font-stretch: 75%; letter-spacing: .04em; text-transform: uppercase;
  color: var(--fg-3); transition: color .35s, var(--morph);
}
.filters button small { position: relative; top: -.6em; font-family: var(--mono); font-size: 10px; letter-spacing: .02em; }
.filters button:hover { color: var(--fg-2); }
.filters button.active { color: var(--fg); font-weight: 850; font-stretch: 130%; }
.filters button::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--fg);
  transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease);
}
.filters button.active::after { transform: scaleX(1); }
.view-toggle { display: flex; gap: 8px; color: var(--fg-4); }
.view-toggle button { color: var(--fg-3); letter-spacing: inherit; font-size: inherit; text-transform: inherit; transition: color .3s; }
.view-toggle button.active, .view-toggle button:hover { color: var(--fg); }

/* List view: credit-roll caps that stretch out when hovered */
.list { border-bottom: 1px solid var(--line); }
.row {
  position: relative; display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 150px 190px 64px 24px;
  align-items: center; gap: 16px;
  padding: clamp(18px, 2.2vw, 30px) 0;
  border-top: 1px solid var(--line);
  transition: opacity .5s var(--ease);
  animation: fadeUp .7s var(--ease) both;
}
.list:hover .row { opacity: .3; }
.list .row:hover, .list .row:focus-visible { opacity: 1; }
.row-idx { color: var(--fg-3); }
.row-title { display: flex; align-items: baseline; gap: 16px; min-width: 0; transition: transform .6s var(--ease); }
.row:hover .row-title { transform: translateX(10px); }
.row-title b {
  font-family: var(--display); font-size: clamp(22px, 3.1vw, 46px);
  font-weight: 700; font-stretch: 105%; letter-spacing: -.005em; line-height: 1; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transition: var(--morph);
}
.row:hover .row-title b, .row:focus-visible .row-title b { font-weight: 900; font-stretch: 135%; }
.row-title span { font-weight: 300; font-size: 12px; color: var(--fg-3); white-space: nowrap; }
.row-cat {
  font-family: var(--display); font-size: 13px; font-weight: 600; font-stretch: 70%;
  letter-spacing: .06em; text-transform: uppercase;
}
.row-role { font-size: 14px; font-weight: 300; color: var(--fg-2); }
.row-year { color: var(--fg-2); text-align: right; }
.row-arrow { font-size: 18px; text-align: right; transform: translate(-6px, 6px); opacity: 0; transition: transform .5s var(--ease), opacity .4s; }
.row:hover .row-arrow { transform: none; opacity: 1; }
.row-thumb { display: none; }

/* Grid view */
.grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: clamp(16px, 2.4vw, 36px); row-gap: clamp(48px, 6vw, 96px);
}
.grid .card:nth-child(even) { margin-top: clamp(0px, 9vw, 160px); }
.card { display: block; text-align: left; animation: fadeUp .8s var(--ease) both; }
.card-thumb { position: relative; isolation: isolate; aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--radius); background: var(--bg-2); }
.card-thumb > * {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) brightness(.85);
  transition: transform 1.2s var(--ease), filter .6s;
}
.card:hover .card-thumb > * { transform: scale(1.05); filter: none; }
/* Live preview layer: sits over the still, fades in (in colour) once the film is running */
.live { position: absolute; inset: 0; overflow: hidden; opacity: 0; transition: opacity .6s var(--ease), transform 1.2s var(--ease), filter .6s; }
.live.on { opacity: 1; filter: none; }
.card-info { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding-top: 16px; }
.card-info .mono { color: var(--fg-3); }
.card-title b {
  display: block; font-family: var(--display); font-size: clamp(20px, 2vw, 28px);
  font-weight: 800; font-stretch: 112%; line-height: 1.1; text-transform: uppercase;
  transition: var(--morph);
}
.card:hover .card-title b { font-stretch: 140%; }
.card-title span { display: block; margin-top: 4px; font-size: 13px; font-weight: 300; color: var(--fg-2); }
.card-side { text-align: right; }
.card-side b { display: block; font-family: var(--display); font-size: 13px; font-weight: 600; font-stretch: 70%; letter-spacing: .06em; text-transform: uppercase; }
.card-side span { display: block; color: var(--fg-3); }

.empty { padding: 64px 0; color: var(--fg-3); font-size: 18px; font-weight: 300; border-top: 1px solid var(--line); }

/* Placeholder cover */
.ph { position: relative; display: block; }
.ph::after {
  content: attr(data-l); position: absolute; left: 6%; bottom: 4%;
  font-family: var(--display); font-weight: 900; font-stretch: 50%;
  font-size: clamp(48px, 9vw, 140px); line-height: .8; text-transform: uppercase;
  color: rgba(255, 255, 255, .07);
}
.rail-thumb .ph::after { font-size: 64px; }

/* Cursor-follow preview for list view */
.hover-preview {
  --w: clamp(240px, 24vw, 380px);
  position: fixed; top: 0; left: 0; z-index: 70; pointer-events: none;
  width: var(--w); aspect-ratio: 16 / 10;
  margin: calc(var(--w) * -.3125) 0 0 calc(var(--w) * -.5);
  will-change: transform;
}
.hover-preview-inner {
  position: relative; width: 100%; height: 100%; overflow: hidden; background: var(--bg-2);
  clip-path: inset(50% 50% 50% 50%);
  transition: clip-path .7s var(--ease);
}
.hover-preview.show .hover-preview-inner { clip-path: inset(0 0 0 0); }
.hover-preview-inner > * { width: 100%; height: 100%; object-fit: cover; }

/* ---------- About ---------- */
.about-body {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 120px);
  padding-top: clamp(32px, 4vw, 64px);
}
.about-photo {
  position: sticky; top: 96px;
  aspect-ratio: 4 / 5; background: var(--bg-2) center / cover no-repeat;
  filter: grayscale(1) contrast(1.05);
}
.about-photo:empty:not([style*="background-image"])::after {   /* placeholder only when no photo is set */
  content: "Portrait"; display: flex; height: 100%; align-items: flex-end; padding: 18px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-4);
}
.about-lead {
  font-family: var(--display); font-size: clamp(28px, 3.5vw, 54px);
  font-weight: 300; font-stretch: 72%; line-height: 1.04; letter-spacing: -.005em;
  text-wrap: pretty;
}
.about-lead b { font-weight: 900; font-stretch: 125%; }
.about-text { margin: clamp(28px, 3.5vw, 52px) 0 0 auto; max-width: 58ch; }
.about-text p { font-size: 16px; color: var(--fg-2); margin-bottom: 1.1em; }
.about-list { margin-top: clamp(40px, 5vw, 80px); }
.about-list-label { color: var(--fg-3); padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.about-list ul { list-style: none; }
.about-list li {
  display: grid; grid-template-columns: 80px 1fr; gap: 16px;
  padding: 16px 0; border-bottom: 1px solid var(--line); font-size: 15px;
}
.about-list li .mono { color: var(--fg-3); padding-top: 3px; }
.about-list li span:last-child { font-family: var(--display); font-weight: 600; font-stretch: 85%; letter-spacing: .01em; }

/* ---------- Contact ---------- */
/* Statement: a three-step staircase of contrasting cuts */
.contact-statement {
  font-family: var(--display); font-size: clamp(44px, 8vw, 136px);
  line-height: .9; letter-spacing: -.01em;
  padding: clamp(32px, 4vw, 64px) 0 clamp(48px, 6vw, 96px);
}
.contact-statement > * { display: block; }
.contact-statement span:first-child { font-weight: 300; font-stretch: 50%; font-size: 1.3em; line-height: .85; }
.contact-statement b { font-weight: 900; font-stretch: 150%; padding-left: .9em; }
.contact-statement span:last-child { font-weight: 300; font-style: italic; padding-left: 2.2em; }
.contact-body {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 120px);
  padding-bottom: clamp(96px, 12vw, 180px);
}
.contact-info { container-type: inline-size; }
.contact-info .mono { color: var(--fg-3); }
.email-link {
  position: relative; display: inline-block; margin-top: 10px; white-space: nowrap;
  font-family: var(--display); font-size: min(30px, 4.5cqi);   /* hover stretch (135%) still fits on one line */
  font-weight: 700; font-stretch: 112%; letter-spacing: -.005em;
  transition: var(--morph);
}
.email-link:hover { font-stretch: 135%; }
.email-link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: currentColor;
  transform-origin: right; transition: transform .6s var(--ease);
}
.email-link:hover::after { transform: scaleX(0); }
.contact-info dl { margin-top: 44px; border-top: 1px solid var(--line); }
.contact-info dl > div { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.contact-info dd { font-weight: 500; }
.contact-info dd a { transition: opacity .3s; }
.contact-info dd a:hover { opacity: .55; }
/* Socials: three hairline tiles that invert on hover */
.socials-label { margin-top: 44px; }
.socials { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 12px; border: 1px solid var(--line); }
.socials li + li { border-left: 1px solid var(--line); }
.socials a {
  position: relative; isolation: isolate; display: flex; flex-direction: column; justify-content: space-between; gap: 28px;
  height: 100%; padding: 16px 16px 14px; overflow: hidden; transition: color .5s var(--ease);
}
.socials a::before {
  content: ""; position: absolute; inset: 0; background: var(--fg);
  transform: translateY(101%); transition: transform .5s var(--ease); z-index: -1;
}
.socials a:hover { color: var(--bg); }
.socials a:hover::before { transform: none; }
.social-icon { display: block; width: 26px; height: 26px; }
.social-icon svg { display: block; width: 100%; height: 100%; }
.social-name {
  font-family: var(--display); font-size: 15px; font-weight: 600; font-stretch: 100%;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: var(--morph);
}
.socials a:hover .social-name { font-stretch: 125%; }
.social-arrow { position: absolute; top: 14px; right: 14px; font-size: 13px; transition: transform .5s var(--ease); }
.socials a:hover .social-arrow { transform: translate(2px, -2px); }

.contact-form { display: flex; flex-direction: column; gap: 4px; }
.contact-form label { display: block; border-bottom: 1px solid var(--line); padding: 16px 0 6px; transition: border-color .3s; }
.contact-form label:focus-within { border-color: var(--fg); }
.contact-form label .mono { display: block; color: var(--fg-3); }
.contact-form input, .contact-form textarea {
  width: 100%; background: transparent; border: 0; outline: none; resize: vertical;
  color: var(--fg); font-family: var(--display); font-size: clamp(18px, 1.6vw, 22px); font-weight: 500; font-stretch: 90%;
  padding: 8px 0 6px;
}
.form-actions { display: flex; align-items: center; gap: 24px; margin-top: 32px; flex-wrap: wrap; }
.contact-form button {
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; gap: 14px; align-items: center;
  border: 1px solid var(--fg); border-radius: 999px; padding: 16px 28px;
  font-family: var(--display); font-size: 13px; font-weight: 800; font-stretch: 90%;
  letter-spacing: .08em; text-transform: uppercase;
  transition: color .5s var(--ease);
}
.contact-form button::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--fg); border-radius: inherit;
  transform: translateY(101%); transition: transform .5s var(--ease);
}
.contact-form button:hover { color: var(--bg); }
.contact-form button:hover::before { transform: none; }
.form-status { color: var(--fg-2); }

/* ---------- Footer: one hairline row at the foot of the Contact page ---------- */
.footer { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 22px 0; border-top: 1px solid var(--line); color: var(--fg-3); }
.footer a:hover { color: var(--fg); }

/* ---------- Modal ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100; background: #000;
  display: flex; align-items: center; justify-content: center;
  padding: 72px var(--gutter) 40px; overflow-y: auto;
  opacity: 0; visibility: hidden; transition: opacity .5s var(--ease), visibility 0s .5s;
}
.modal.open { opacity: 1; visibility: visible; transition: opacity .5s var(--ease); }
.modal-inner { width: min(1280px, 100%); margin: auto; transform: translateY(24px); transition: transform .8s var(--ease); }
.modal.open .modal-inner { transform: none; }
.modal-player { position: relative; aspect-ratio: 16 / 9; background: var(--bg-2); }
.modal-player iframe, .modal-player video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.modal-player .ph { position: absolute; inset: 0; }
.modal-player .soon { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--fg-3); }
.modal-close { position: fixed; top: 22px; right: var(--gutter); z-index: 2; color: var(--fg-2); transition: color .3s; }
.modal-close:hover { color: var(--fg); }
.modal-meta {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px;
  margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line);
}
.modal-meta h3 {
  font-family: var(--display); font-size: clamp(28px, 4vw, 56px);
  font-weight: 900; font-stretch: 125%; line-height: .95; letter-spacing: -.005em; text-transform: uppercase;
}
.modal-meta .alt { color: var(--fg-2); margin-top: 10px; font-weight: 300; }
.modal-meta dl { display: grid; grid-template-columns: repeat(4, auto); gap: 4px 28px; justify-content: start; margin-bottom: 20px; }
.modal-meta dt { grid-row: 1; font-family: var(--mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-3); }
.modal-meta dd { grid-row: 2; font-size: 14px; font-weight: 500; }
.modal-meta .desc { color: var(--fg-2); }
.modal-meta .credits { color: var(--fg-3); font-size: 13px; margin-top: 12px; }

/* ---------- Loader ----------
   First load / refresh only. Gaussian blur over the page with the CST / 传声筒 mark at the
   optical centre (a touch above the geometric middle). The mark is a pre-keyed white sprite
   (images/loader-sprite.png, 18 frames stacked vertically, built from images/loader.gif)
   that main.js steps through at 1.7x speed (one loop ≈ 1.31 s), cut after 0.67 s.
   In:  the blur builds, then the mark rises in.
   Out: the mark softens — fades, defocuses, settles a little — while the blur slowly
        dissolves back into the page on a long, gentle curve. */
.loader {
  --soft: cubic-bezier(.45, 0, .15, 1);
  position: fixed; inset: 0; z-index: 150;
  display: grid; place-items: center;
  background: rgba(0, 0, 0, 0);
  -webkit-backdrop-filter: blur(0); backdrop-filter: blur(0);
  visibility: hidden; pointer-events: none;
  transition: backdrop-filter 1.82s var(--soft) .26s, -webkit-backdrop-filter 1.82s var(--soft) .26s,
              background 1.82s var(--soft) .26s, visibility 0s 2.08s;
}
.loader.is-on {
  background: rgba(0, 0, 0, .35);
  -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px);
  visibility: visible; pointer-events: auto;
  transition: backdrop-filter .6s var(--ease), -webkit-backdrop-filter .6s var(--ease), background .6s var(--ease);
}
.loader-mark {
  translate: 0 -4vh;
  opacity: 0; scale: .94; filter: blur(8px);
  transition: opacity 1.04s var(--soft), scale 1.43s var(--soft), filter 1.04s var(--soft);
}
.loader.is-on .loader-mark {
  opacity: 1; scale: 1; filter: blur(0);
  transition: opacity .45s var(--ease) .25s, scale .8s var(--ease) .25s, filter .45s var(--ease) .25s;
}
.loader-sprite {
  width: clamp(112px, 9vw, 150px); aspect-ratio: 300 / 131;
  background: url("images/loader-sprite.png") 0 0 / 100% 1800% no-repeat;
}

/* ---------- Motion helpers ---------- */
main { transition: opacity .28s var(--ease), filter .28s var(--ease); }
main.lang-out { opacity: 0; filter: blur(6px); }
.js [data-reveal] { opacity: 0; transform: translateY(32px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); }
.js [data-reveal].in { opacity: 1; transform: none; }

/* ============================================================
   Chinese / Korean / Japanese — Japanese-style typesetting
   Page-language text uses that language's sans (var(--cjk)); big display
   moments use its heavy gothic (var(--cjk-display)). Proportional glyph
   spacing (palt) on display type, roomy leading for running text, and the
   contact statement set vertically (tategaki) on the Chinese & Japanese pages.
   Work titles and the name stay Latin except on the Chinese page.
   ============================================================ */
html.cjk { text-spacing-trim: trim-start; text-autospace: normal; hanging-punctuation: allow-end; }
[data-lang="ja"] body { line-break: strict; }
[data-lang="ko"] body { word-break: keep-all; }   /* Korean breaks between words, never inside one */
.cjk .mono { letter-spacing: .04em; }
.cjk .tag { padding-top: 5px; }
.cjk .hero-role { font-family: var(--cjk); font-weight: 500; letter-spacing: .8em; }
.cjk .hero-vert { font-family: var(--cjk); font-size: 11px; letter-spacing: .4em; }
.cjk .sec-vert { font-family: var(--cjk); font-size: 11px; }
.cjk .nav-links a,
.cjk .hero-cats a,
.cjk .filters button,
.cjk .row-cat,
.cjk .card-side b,
.cjk .sec-desc,
.cjk .about-lead,
.cjk .about-list li span:last-child,
.cjk .contact-form button,
.cjk .social-name,
.cjk .rail-cta { font-family: var(--cjk), var(--sans); letter-spacing: .04em; font-feature-settings: "palt"; }
.cjk .nav-links a:hover, .cjk .nav-links a.active { letter-spacing: .14em; }
.cjk .hero-cats a:hover { letter-spacing: .18em; }
.cjk .about-lead { line-height: 1.45; }
.cjk .about-lead b { font-family: var(--display); }
.cjk .about-text p, .cjk .rail-detail .desc, .cjk .modal-meta .desc { line-height: 1.95; letter-spacing: .04em; }
.cjk .sec-side { max-width: 20em; }

/* Display: heavy gothic, tight proportional spacing. Single-weight faces (ko / ja) are
   pinned to 400 so the browser never fakes a bold. */
.cjk .sec-head h2,
.cjk .contact-statement b,
[data-lang="cn"] .hero-name,
[data-lang="cn"] .row-title b,
[data-lang="cn"] .card-title b,
[data-lang="cn"] .modal-meta h3,
[data-lang="ko"] [data-loc]:not(.rail-title), [data-lang="ja"] [data-loc]:not(.rail-title),
[data-lang="cn"] .about-lead b {
  font-family: var(--cjk-display), var(--cjk); font-weight: var(--cjk-weight); font-stretch: 100%;
  letter-spacing: var(--cjk-track); font-feature-settings: "palt";
}
.cjk .sec-head h2 { font-size: clamp(5rem, 15vw, 15rem); line-height: .92; }
html.js.cjk .sec-head h2 { letter-spacing: .3em; }
html.js.cjk .sec-head.in h2 { letter-spacing: var(--cjk-track); font-weight: var(--cjk-weight); }
[data-lang="cn"] .hero-name { line-height: 1.05; }
[data-lang="cn"] .rail-title, .cjk .rail-title[data-loc] { font-family: var(--cjk), var(--sans); letter-spacing: .04em; }
[data-lang="cn"] .row:hover .row-title b { letter-spacing: .08em; font-weight: var(--cjk-weight); }
[data-lang="cn"] .card:hover .card-title b { letter-spacing: .08em; }

/* Contact statement */
.cjk .contact-statement { line-height: 1.12; }
.cjk .contact-statement b { font-size: 1.12em; }
.cjk .contact-statement span { font-family: var(--cjk), var(--sans); font-style: normal; font-weight: 200; font-size: 1em; }
/* Chinese & Japanese: vertical, three columns stepping down right-to-left */
[data-lang="cn"] .contact-statement,
[data-lang="ja"] .contact-statement {
  writing-mode: vertical-rl;
  width: fit-content; margin-left: auto;
  font-size: clamp(40px, 6.4vw, 108px); line-height: 1.25;
}
[data-lang="cn"] .contact-statement b, [data-lang="ja"] .contact-statement b { padding: .8em 0 0; font-size: 1.08em; }
[data-lang="cn"] .contact-statement span:last-child, [data-lang="ja"] .contact-statement span:last-child { padding: 2em 0 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .row { grid-template-columns: 44px minmax(0, 1fr) 130px 56px 20px; }
  .row-role { display: none; }
}
@media (max-width: 900px) {
  /* Phones / tablets: no works rail — the hero is just name, role, categories over the showreel */
  .hero { grid-template-columns: minmax(0, 1fr); height: 100svh; min-height: 560px; }
  .hero-main { padding-top: 120px; padding-bottom: 28px; }
  .hero-bottom { margin-top: 28px; }
  .rail { display: none; }

  .sec-head { grid-template-columns: auto 1fr; gap: 18px 14px; }
  .sec-head h2 { font-size: clamp(5rem, 27vw, 14rem); }
  .sec-vert { justify-self: start; }
  .sec-side { grid-column: 1 / -1; justify-self: start; text-align: left; grid-template-columns: auto 1fr; align-items: baseline; max-width: none; }
  .sec-side .sec-desc { grid-column: 1 / -1; grid-row: 1; }

  .row { grid-template-columns: 44px minmax(0, 1fr) auto; row-gap: 12px; align-items: start; }
  .list:hover .row { opacity: 1; }
  .row-title { flex-direction: column; gap: 4px; }
  .row-title b { white-space: normal; }
  .row:hover .row-title { transform: none; }
  .row-cat { grid-column: 2; grid-row: 2; color: var(--fg-2); }
  .row-year { grid-column: 3; grid-row: 1; }
  .row-arrow { display: none; }
  .row-thumb { position: relative; display: block; grid-column: 2 / -1; width: 84%; aspect-ratio: 16 / 9; overflow: hidden; background: var(--bg-2); }
  .row-thumb > * { width: 100%; height: 100%; object-fit: cover; }

  .grid { grid-template-columns: 1fr; }
  .grid .card { width: 88%; }   /* slightly inset thumbnails, staggered left / right */
  .grid .card:nth-child(even) { margin-top: 0; justify-self: end; }

  .about-body, .contact-body { grid-template-columns: 1fr; }
  .about-photo { position: relative; top: 0; max-width: 420px; }
  .about-text { margin-left: 0; }
  .contact-statement b { padding-left: .5em; }
  .contact-statement span:last-child { padding-left: 1.2em; }
  .modal-meta { grid-template-columns: 1fr; }
  .modal-meta dl { grid-template-columns: repeat(2, auto); }
  .modal-meta dt, .modal-meta dd { grid-row: auto; }
}
@media (max-width: 600px) {
  .lang-switch { width: 132px; height: 30px; }
  .lang-switch .full { display: none; }
  .lang-switch .short { display: inline; }
  .lang-switch button { font-size: 11px; }
  .nav-links { gap: 12px; }
  .nav-links i { display: none; }
  .nav-links a { font-size: 11px; letter-spacing: .03em; }
  .hero-vert { display: none; }
  .hero-bottom { flex-direction: column; align-items: flex-start; }
  .contact-statement { font-size: 10.5vw; }
  .contact-statement b { font-size: .8em; padding-left: .3em; }
  .contact-statement span:last-child { padding-left: .9em; }
  .cjk .contact-statement b { font-size: 1em; }
  [data-lang="cn"] .contact-statement, [data-lang="ja"] .contact-statement { font-size: 12vw; }
  [data-lang="cn"] .contact-statement b, [data-lang="ja"] .contact-statement b { padding-left: 0; }
  [data-lang="cn"] .contact-statement span:last-child, [data-lang="ja"] .contact-statement span:last-child { padding-left: 0; }
}
@media (hover: none) {
  .rail-hint-desktop { display: none; }
  .rail-hint-touch { display: inline; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
  body::after { animation: none; }
}
