:root {
  --ink: #090a0a;
  --ink-soft: #101211;
  --paper: #e9e4d8;
  --paper-muted: #b6b0a5;
  --line: rgba(233, 228, 216, 0.18);
  --red: #a32824;
  --aqua: #78a7a4;
  --gutter: clamp(1.25rem, 4vw, 4.5rem);
  --serif: "Cormorant Garamond", "Noto Serif TC", serif;
  --sans: "Manrope", sans-serif;
  --cjk: "Noto Serif TC", serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--ink);
}

body {
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 10% 20%, rgba(120, 167, 164, 0.05), transparent 22rem),
    var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

body::selection {
  background: var(--red);
  color: white;
}

a {
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

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

[data-en] {
  display: none;
}

html[data-language="en"] [data-zh] {
  display: none;
}

html[data-language="en"] [data-en] {
  display: initial;
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: 1rem;
  z-index: 2000;
  padding: 0.75rem 1rem;
  background: var(--paper);
  color: var(--ink);
  text-decoration: none;
  transform: translateY(-200%);
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-noise {
  position: fixed;
  inset: 0;
  z-index: 1500;
  pointer-events: none;
  opacity: 0.2;
  background:
    repeating-radial-gradient(circle at 20% 30%, transparent 0 1px, rgba(255, 255, 255, 0.05) 1px 2px),
    repeating-linear-gradient(93deg, transparent 0 3px, rgba(255, 255, 255, 0.015) 3px 4px);
  background-size: 7px 7px, 11px 11px;
  mix-blend-mode: soft-light;
}

.scroll-progress {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  z-index: 1600;
  background: transparent;
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 5.5rem;
  padding: 0 var(--gutter);
  border-bottom: 1px solid transparent;
  transition:
    min-height 300ms ease,
    background-color 300ms ease,
    border-color 300ms ease;
}

.site-header.is-scrolled {
  min-height: 4.5rem;
  background: rgba(9, 10, 10, 0.88);
  border-color: var(--line);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.brand {
  justify-self: start;
  display: flex;
  align-items: baseline;
  gap: 0.85rem;
  text-decoration: none;
  line-height: 1;
}

.brand-en {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
}

.brand-zh {
  color: var(--paper-muted);
  font-family: var(--cjk);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 2.7vw, 2.8rem);
}

.site-nav a {
  position: relative;
  color: rgba(233, 228, 216, 0.72);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.17em;
  text-decoration: none;
  text-transform: uppercase;
  transition: color 180ms ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.45rem;
  height: 1px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 220ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--paper);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.language-toggle {
  justify-self: end;
  min-width: 2.75rem;
  padding: 0.5rem 0.6rem;
  border: 1px solid rgba(233, 228, 216, 0.36);
  background: transparent;
  color: var(--paper);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  transition:
    background-color 180ms ease,
    color 180ms ease,
    border-color 180ms ease;
}

.language-toggle:hover,
.language-toggle:focus-visible {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

.hero {
  position: relative;
  display: grid;
  min-height: 100svh;
  overflow: hidden;
  background: var(--ink);
  isolation: isolate;
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-image {
  z-index: -3;
  background: url("/assets/hero.jpg") center 32% / cover no-repeat;
  transform: scale(1.045);
  animation: hero-breathe 14s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero-shade {
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(9, 10, 10, 0.46) 0%, rgba(9, 10, 10, 0.05) 34%, rgba(9, 10, 10, 0.25) 62%, rgba(9, 10, 10, 0.96) 100%),
    linear-gradient(90deg, rgba(9, 10, 10, 0.54), transparent 58%);
}

.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: 0;
  right: 0;
  bottom: 0;
  height: 18rem;
  background: linear-gradient(180deg, transparent, var(--ink));
}

.hero-copy {
  align-self: end;
  padding: 0 var(--gutter) clamp(7rem, 14vh, 10rem);
}

.eyebrow,
.section-label,
.person-role,
.contact-title > p {
  margin: 0;
  color: var(--aqua);
  font-size: clamp(0.62rem, 0.8vw, 0.72rem);
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.film-title {
  display: flex;
  align-items: flex-end;
  gap: clamp(1.2rem, 3vw, 3rem);
  margin: 1.4rem 0 0;
  line-height: 0.78;
}

.title-zh {
  font-family: var(--cjk);
  font-size: clamp(5.5rem, 16vw, 14rem);
  font-weight: 900;
  letter-spacing: -0.08em;
  text-shadow: 0 0 4rem rgba(0, 0, 0, 0.35);
}

.title-en {
  margin-bottom: 0.16em;
  color: rgba(233, 228, 216, 0.68);
  font-family: var(--serif);
  font-size: clamp(2rem, 6vw, 5.2rem);
  font-weight: 300;
  letter-spacing: -0.03em;
}

.hero-credit {
  margin: clamp(1.8rem, 4vh, 3.2rem) 0 0;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.hero-index {
  position: absolute;
  right: var(--gutter);
  top: 15vh;
  color: rgba(233, 228, 216, 0.18);
  font-family: var(--serif);
  font-size: clamp(5rem, 12vw, 11rem);
  font-weight: 300;
  line-height: 1;
}

.hero-location {
  position: absolute;
  right: var(--gutter);
  bottom: 2.5rem;
  margin: 0;
  color: rgba(233, 228, 216, 0.55);
  font-size: 0.58rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.hero-scroll {
  position: absolute;
  left: var(--gutter);
  bottom: 2.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  color: rgba(233, 228, 216, 0.72);
  font-size: 0.58rem;
  letter-spacing: 0.24em;
  text-decoration: none;
  text-transform: uppercase;
}

.hero-scroll i {
  position: relative;
  display: block;
  width: 4rem;
  height: 1px;
  overflow: hidden;
  background: rgba(233, 228, 216, 0.35);
}

.hero-scroll i::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--paper);
  transform: translateX(-100%);
  animation: line-sweep 2.6s ease-in-out infinite;
}

.section-shell {
  position: relative;
  padding: clamp(6rem, 13vw, 12rem) var(--gutter);
}

.section-shell::before {
  content: "";
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  top: 0;
  height: 1px;
  background: var(--line);
}

.section-number {
  position: absolute;
  top: 2rem;
  right: var(--gutter);
  color: rgba(233, 228, 216, 0.34);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
}

.section-label {
  margin-bottom: clamp(3rem, 7vw, 6.5rem);
}

.story-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(16rem, 0.75fr);
  gap: clamp(3rem, 10vw, 12rem);
  align-items: start;
}

.story-lead p {
  max-width: 18ch;
  margin: 0;
  font-family: var(--cjk);
  font-size: clamp(2.1rem, 5vw, 5.2rem);
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 1.35;
}

html[data-language="en"] .story-lead p {
  max-width: 17ch;
  font-family: var(--serif);
  font-size: clamp(2.8rem, 5.8vw, 6rem);
  line-height: 1.02;
}

.story-body {
  padding-top: 0.85rem;
  color: var(--paper-muted);
  font-family: var(--cjk);
  font-size: clamp(0.94rem, 1.4vw, 1.15rem);
  line-height: 2.05;
}

.story-body p {
  margin: 0 0 1.4rem;
}

html[data-language="en"] .story-body {
  font-family: var(--sans);
  line-height: 1.8;
}

.film-facts {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin: clamp(5rem, 11vw, 10rem) 0 0;
  padding: 0;
  border-top: 1px solid var(--line);
}

.film-facts > div {
  min-width: 0;
  padding: 1.5rem 1.2rem 0 0;
}

.film-facts dt {
  margin-bottom: 0.65rem;
  color: rgba(233, 228, 216, 0.42);
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.film-facts dd {
  margin: 0;
  font-family: var(--cjk);
  font-size: 0.88rem;
  letter-spacing: 0.04em;
}

.manifesto {
  position: relative;
  display: grid;
  min-height: min(88svh, 60rem);
  place-items: center;
  overflow: hidden;
  isolation: isolate;
}

.manifesto::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(9, 10, 10, 0.82), rgba(9, 10, 10, 0.26) 50%, rgba(9, 10, 10, 0.82)),
    linear-gradient(180deg, var(--ink), transparent 32%, transparent 68%, var(--ink));
}

.manifesto-image {
  position: absolute;
  inset: -5%;
  z-index: -2;
  background: url("/assets/still-portrait.jpg") center 34% / cover no-repeat;
  filter: saturate(0.7) contrast(1.12);
}

.manifesto blockquote {
  margin: 0;
  padding: 6rem var(--gutter);
  text-align: center;
}

.manifesto blockquote span {
  font-family: var(--cjk);
  font-size: clamp(2rem, 5.3vw, 5.8rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.45;
  text-shadow: 0 0.3rem 3rem rgba(0, 0, 0, 0.65);
}

html[data-language="en"] .manifesto blockquote span {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 6.5vw, 7rem);
  line-height: 1;
}

.stills-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1rem, 2.6vw, 2.5rem);
  align-items: start;
}

.still {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: var(--ink-soft);
}

.still img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.72) contrast(1.05);
  transition:
    transform 900ms cubic-bezier(0.2, 0.8, 0.2, 1),
    filter 450ms ease;
}

.still:hover img {
  transform: scale(1.025);
  filter: saturate(0.95) contrast(1.02);
}

.still figcaption {
  position: absolute;
  right: 0.9rem;
  bottom: 0.65rem;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.56rem;
  letter-spacing: 0.16em;
}

.still-wide {
  grid-column: 1 / span 9;
  aspect-ratio: 16 / 9;
}

.still-portrait {
  grid-column: 7 / -1;
  aspect-ratio: 1.25 / 1;
  margin-top: clamp(3rem, 8vw, 8rem);
}

.still-prayer {
  grid-column: 2 / span 6;
  aspect-ratio: 1.25 / 1;
  margin-top: clamp(-4rem, -4vw, -1rem);
}

.people-list {
  display: grid;
  gap: clamp(5rem, 10vw, 10rem);
}

.person {
  display: grid;
  gap: clamp(1.4rem, 2.4vw, 2.6rem);
}

.person-featured {
  grid-template-columns: minmax(16rem, 0.68fr) 1fr;
  align-items: center;
  max-width: 72rem;
}

.person-image {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--ink-soft);
}

.person-image::after {
  content: "";
  position: absolute;
  inset: 0;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  pointer-events: none;
}

.person-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.66) contrast(1.05);
  transition:
    transform 800ms cubic-bezier(0.2, 0.8, 0.2, 1),
    filter 450ms ease;
}

.person:hover .person-image img {
  transform: scale(1.025);
  filter: saturate(0.9) contrast(1.02);
}

.person-copy {
  align-self: end;
}

.person-role {
  color: var(--red);
}

.person-copy h2 {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.65rem;
  margin: 0.8rem 0 1.15rem;
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3.2vw, 3.6rem);
  font-weight: 300;
  letter-spacing: -0.03em;
  line-height: 1;
}

.person-copy h2 span {
  font-family: var(--cjk);
  font-size: 0.43em;
  font-weight: 400;
  letter-spacing: 0.08em;
}

.person-copy > p:not(.person-role) {
  max-width: 33rem;
  margin: 0;
  color: var(--paper-muted);
  font-family: var(--cjk);
  font-size: 0.82rem;
  line-height: 1.8;
}

html[data-language="en"] .person-copy > p:not(.person-role) {
  font-family: var(--sans);
}

.people-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.6vw, 2.8rem);
}

.people-grid .person:nth-child(even) {
  margin-top: clamp(2.5rem, 6vw, 6rem);
}

.contact {
  min-height: 76svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.6fr;
  gap: clamp(3rem, 8vw, 9rem);
  align-items: end;
}

.contact-title h2 {
  margin: 1.25rem 0 0;
  font-family: var(--serif);
  font-size: clamp(5rem, 16vw, 14rem);
  font-weight: 300;
  letter-spacing: -0.08em;
  line-height: 0.58;
}

.contact-details {
  padding-bottom: 0.6rem;
}

.contact-copy {
  margin: 0 0 2.2rem;
  color: var(--paper-muted);
  font-family: var(--cjk);
  font-size: 0.9rem;
}

html[data-language="en"] .contact-copy {
  font-family: var(--sans);
}

.contact-details a {
  display: inline-block;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--paper);
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.5vw, 2.4rem);
  text-decoration: none;
  transition:
    border-color 180ms ease,
    color 180ms ease;
}

.contact-details a:hover,
.contact-details a:focus-visible {
  border-color: var(--red);
  color: var(--aqua);
}

.contact-details > p:last-child {
  margin: 2.2rem 0 0;
  color: rgba(233, 228, 216, 0.42);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  padding: 2rem var(--gutter);
  border-top: 1px solid var(--line);
  color: rgba(233, 228, 216, 0.45);
  font-size: 0.56rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.site-footer p {
  margin: 0;
}

.site-footer p:nth-child(2) {
  text-align: center;
}

.site-footer a {
  justify-self: end;
  text-decoration: none;
  transition: color 180ms ease;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  color: var(--paper);
}

.reveal {
  opacity: 0;
  transform: translateY(2rem);
  transition:
    opacity 900ms cubic-bezier(0.2, 0.8, 0.2, 1),
    transform 900ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.hero .reveal {
  animation: reveal-in 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero .film-title {
  animation-delay: 160ms;
}

.hero .hero-credit {
  animation-delay: 320ms;
}

@keyframes reveal-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes hero-breathe {
  to {
    transform: scale(1);
  }
}

@keyframes line-sweep {
  0%,
  15% {
    transform: translateX(-100%);
  }
  60%,
  100% {
    transform: translateX(100%);
  }
}

@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .site-nav {
    display: none;
  }

  .story-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .story-body {
    max-width: 38rem;
  }

  .film-facts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 1.75rem;
  }

  .person-featured {
    grid-template-columns: 0.8fr 1fr;
  }

  .people-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-details {
    padding-bottom: 0;
  }

  .site-footer {
    grid-template-columns: 1fr 1fr;
  }

  .site-footer p:nth-child(2) {
    display: none;
  }
}

@media (max-width: 620px) {
  .site-header {
    min-height: 4.8rem;
  }

  .brand-zh {
    display: none;
  }

  .hero-copy {
    padding-bottom: 8.5rem;
  }

  .film-title {
    display: block;
  }

  .title-zh {
    display: block;
    font-size: clamp(5.2rem, 32vw, 8.8rem);
  }

  .title-en {
    display: block;
    margin-top: 1rem;
    font-size: clamp(2.25rem, 12vw, 4rem);
  }

  .hero-index {
    top: 18vh;
    font-size: 5rem;
  }

  .hero-location {
    display: none;
  }

  .section-shell {
    padding-top: 7rem;
    padding-bottom: 7rem;
  }

  .story-lead p {
    font-size: clamp(2rem, 10.5vw, 3.3rem);
  }

  html[data-language="en"] .story-lead p {
    font-size: clamp(2.6rem, 13vw, 4rem);
  }

  .film-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .manifesto {
    min-height: 70svh;
  }

  .manifesto-image {
    background-position: 58% 35%;
  }

  .stills-grid {
    display: block;
  }

  .still {
    margin: 0 0 1rem;
    aspect-ratio: 16 / 10;
  }

  .person-featured,
  .people-grid {
    grid-template-columns: 1fr;
  }

  .person-featured {
    max-width: 100%;
  }

  .person-featured .person-image {
    max-width: 82%;
  }

  .people-grid {
    gap: 4.5rem;
  }

  .people-grid .person:nth-child(even) {
    margin-top: 0;
  }

  .person-copy h2 {
    font-size: 2.5rem;
  }

  .contact-title h2 {
    font-size: clamp(5rem, 28vw, 8rem);
  }

  .site-footer {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  .site-footer a {
    align-self: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
