﻿:root {
  --ink: #070607;
  --black: #0f0d10;
  --panel: #161219;
  --ivory: #f8efe3;
  --muted: rgba(248, 239, 227, 0.68);
  --line: rgba(248, 239, 227, 0.16);
  --line-strong: rgba(215, 179, 106, 0.38);
  --gold: #d7b36a;
  --gold-bright: #f8df9c;
  --aqua: #9fd5d1;
  --violet: #8d62a3;
  --violet-deep: #4a3159;
  --purple-black: #211627;
  --rose: #d2a8bd;
  --amber: #c47f31;
  --glass: rgba(18, 14, 21, 0.62);
  --glass-strong: rgba(248, 239, 227, 0.085);
  --shadow: 0 34px 110px rgba(0, 0, 0, 0.56);
  --inner-glow: inset 0 1px 0 rgba(248, 239, 227, 0.14), inset 0 -1px 0 rgba(215, 179, 106, 0.16);
  --font-display: "ZCOOL XiaoWei", serif;
  --font-body: "Noto Sans SC", "PingFang SC", sans-serif;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  background:
    linear-gradient(110deg, rgba(141, 98, 163, 0.12), transparent 34%),
    linear-gradient(250deg, rgba(215, 179, 106, 0.08), transparent 38%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    var(--ink);
  background-size: auto, auto, 96px 96px, 96px 96px, auto;
  color: var(--ivory);
  font-family: var(--font-body);
  line-height: 1.78;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.105;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.48), rgba(7, 6, 7, 0.92)),
    url("assets/generated/ui-typography-mood.png") center / cover;
  filter: saturate(0.78) contrast(1.1) brightness(0.72);
}

main {
  position: relative;
  z-index: 1;
}

body.locked {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: 0;
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--gold);
  color: var(--ink);
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.13;
  mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.5'/%3E%3C/svg%3E");
}

.cursor-light {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 80;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  pointer-events: none;
  opacity: 0.18;
  background: radial-gradient(circle, rgba(215, 179, 106, 0.34), rgba(141, 98, 163, 0.17) 38%, transparent 70%);
  filter: blur(12px);
  transform: translate3d(calc(var(--cursor-x, -500px) - 50%), calc(var(--cursor-y, -500px) - 50%), 0);
}

.motion-field {
  position: absolute;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-auto-rows: 1fr;
  gap: 14px 10px;
  pointer-events: none;
  transform: translate3d(calc(var(--mx, 0) * 18px), calc(var(--my, 0) * 18px), 0);
}

.motion-line {
  width: clamp(18px, 2.2vw, 34px);
  height: 2px;
  align-self: center;
  justify-self: center;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(248, 223, 156, 0.82), rgba(159, 213, 209, 0.54), transparent);
  box-shadow: 0 0 18px rgba(215, 179, 106, 0.22);
  opacity: 0.68;
  transform: rotate(calc(var(--line-angle, -18deg) + var(--field-angle, 0deg))) scaleX(calc(var(--line-scale, 1) + var(--field-pulse, 0)));
  transition: transform 220ms ease, opacity 220ms ease;
}

.hero-motion {
  left: 5vw;
  top: 12vh;
  z-index: 4;
  width: min(420px, 32vw);
  height: 25vh;
  opacity: 0.22;
}

.codex-motion {
  right: 8vw;
  top: 150px;
  z-index: 0;
  width: min(420px, 30vw);
  height: 260px;
  opacity: 0.3;
}

.progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
}

.progress span {
  display: block;
  width: calc(var(--scroll-progress, 0) * 100%);
  height: 100%;
  background: linear-gradient(90deg, var(--aqua), var(--gold), var(--violet));
}

.topbar {
  position: fixed;
  top: 3px;
  left: 0;
  right: 0;
  z-index: 70;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 18px 34px 20px;
  mix-blend-mode: normal;
  background:
    linear-gradient(180deg, rgba(7, 6, 7, 0.9), rgba(7, 6, 7, 0.42) 62%, rgba(7, 6, 7, 0));
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(215, 179, 106, 0.12);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.22);
}

.mark {
  display: inline-grid;
  gap: 0;
  line-height: 1;
}

.mark span,
.hero h1,
.hero-wordmark-main,
.codex h2,
.identity h2,
.scrolly h2,
.anatomy h2,
.gallery h2,
.profile h2,
.finale h2,
.gallery-cell span,
.scene-label strong {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0;
}

.mark span {
  color: var(--gold-bright);
  font-size: 1.06rem;
  font-weight: 400;
  text-shadow: 0 0 22px rgba(215, 179, 106, 0.42);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.mark small,
.topbar nav,
.eyebrow,
.section-kicker,
.scene-label span,
.caption,
.finale-copy p {
  letter-spacing: 0;
  text-transform: none;
}

.mark small {
  margin-top: 5px;
  color: rgba(248, 239, 227, 0.58);
  font-size: 0.66rem;
  font-family: var(--font-body);
}

.topbar nav {
  display: flex;
  gap: 10px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-family: var(--font-body);
  font-weight: 500;
}

.topbar nav a {
  position: relative;
  min-height: 38px;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1px;
  min-width: 46px;
  padding: 4px 11px 6px;
  border: 1px solid rgba(248, 239, 227, 0.08);
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(248, 239, 227, 0.035), rgba(7, 6, 7, 0.18));
}

.topbar nav a::before {
  content: attr(data-nav);
  color: rgba(215, 179, 106, 0.62);
  font-family: var(--font-display);
  font-size: 0.64rem;
  line-height: 1;
}

.topbar .mobile-nav {
  display: none;
}

.topbar a {
  transition: opacity 180ms ease, transform 180ms ease;
}

.topbar a:hover,
.topbar a:focus-visible {
  opacity: 1;
  transform: translateY(-2px);
  border-color: rgba(215, 179, 106, 0.38);
  background:
    linear-gradient(180deg, rgba(248, 223, 156, 0.1), rgba(7, 6, 7, 0.24));
}

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  padding: 118px 5.8vw 66px;
  border-bottom: 1px solid var(--line);
  isolation: isolate;
}

.hero::after {
  content: "LUNARIA";
  position: absolute;
  right: -4vw;
  bottom: -2vh;
  z-index: 2;
  color: transparent;
  -webkit-text-stroke: 1px rgba(248, 239, 227, 0.09);
  font-family: var(--font-display);
  font-size: clamp(8rem, 24vw, 24rem);
  font-weight: 800;
  line-height: 0.72;
  pointer-events: none;
  opacity: 0.82;
}

.hero-bg,
.hero-shade,
.hero-figure {
  position: absolute;
  inset: 0;
}

.hero-bg {
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.98), rgba(7, 6, 7, 0.7) 42%, rgba(7, 6, 7, 0.1)),
    linear-gradient(0deg, rgba(7, 6, 7, 0.98), transparent 46%, rgba(7, 6, 7, 0.36)),
    url("assets/generated/hero-bg.png") center / cover;
  filter: saturate(0.48) brightness(0.34) contrast(1.34);
  transform: scale(1.08) translate3d(calc(var(--mx, 0) * -12px), calc(var(--my, 0) * -8px), 0);
}

.hero-figure {
  left: auto;
  right: 0;
  z-index: 1;
  width: min(82vw, 1340px);
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  mix-blend-mode: normal;
  filter: saturate(1.08) contrast(1.04) brightness(1.03);
  clip-path: polygon(13% 0, 100% 0, 100% 100%, 0 100%);
  box-shadow: -80px 0 120px rgba(0, 0, 0, 0.82);
  transform: translate3d(calc(var(--mx, 0) * 22px), calc(var(--my, 0) * 14px), 0);
}

.hero-shade {
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.98), rgba(7, 6, 7, 0.64) 42%, rgba(7, 6, 7, 0.02) 70%, rgba(7, 6, 7, 0.24)),
    linear-gradient(0deg, rgba(7, 6, 7, 0.98), transparent 52%, rgba(7, 6, 7, 0.2));
}

.hero-orbit {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

.hero-orbit span {
  position: absolute;
  right: min(17vw, 260px);
  top: 14vh;
  width: min(42vw, 610px);
  aspect-ratio: 1;
  border: 1px solid rgba(215, 179, 106, 0.16);
  border-radius: 999px;
  transform: rotate(-18deg);
  box-shadow: 0 0 56px rgba(215, 179, 106, 0.08);
}

.hero-orbit span:nth-child(2) {
  right: min(12vw, 180px);
  top: 22vh;
  width: min(29vw, 420px);
  border-color: rgba(159, 213, 209, 0.28);
  transform: rotate(18deg);
}

.hero-orbit span:nth-child(3) {
  right: min(29vw, 430px);
  top: 9vh;
  width: min(16vw, 230px);
  border-color: rgba(141, 98, 163, 0.22);
  transform: rotate(44deg);
}

.hero-copy {
  position: relative;
  z-index: 6;
  width: min(880px, 70vw);
}

.hero-title-backdrop {
  position: absolute;
  left: -2.4vw;
  right: min(10vw, 150px);
  top: 44px;
  bottom: -42px;
  z-index: -1;
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.84), rgba(7, 6, 7, 0.42) 58%, transparent),
    linear-gradient(0deg, rgba(215, 179, 106, 0.06), transparent 52%);
  filter: blur(0.4px);
  clip-path: polygon(0 0, 86% 0, 74% 100%, 0 100%);
}

.eyebrow,
.section-kicker {
  width: fit-content;
  margin: 0 0 18px;
  padding: 0 0 0 12px;
  border: 0;
  border-left: 1px solid rgba(215, 179, 106, 0.5);
  border-radius: 0;
  background: transparent;
  color: var(--gold-bright);
  font-size: 0.76rem;
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: none;
  text-shadow: 0 0 16px rgba(215, 179, 106, 0.22);
}

.hero-wordmark {
  position: relative;
  z-index: 4;
  display: grid;
  width: min(760px, 72vw);
  margin: 4px 0 0;
  padding: 12px 0 8px;
  isolation: isolate;
}

.hero-wordmark::before {
  content: "";
  position: absolute;
  left: -16px;
  right: 20%;
  top: 12px;
  bottom: 8px;
  z-index: -1;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.64), rgba(7, 6, 7, 0.16));
  clip-path: polygon(0 0, 95% 0, 86% 100%, 0 100%);
  box-shadow: 0 28px 88px rgba(0, 0, 0, 0.34);
}

.hero-wordmark-main {
  position: relative;
  display: block;
  color: var(--gold-bright);
  background:
    linear-gradient(94deg, #fff7df 0%, #c08a31 31%, #fff1be 48%, #8b5ca4 72%, #f8df9c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 0.55px rgba(255, 247, 223, 0.28);
  font-size: clamp(5.8rem, 17.5vw, 17.2rem);
  font-weight: 400;
  line-height: 0.72;
  text-shadow:
    0 26px 90px rgba(0, 0, 0, 0.96),
    0 0 34px rgba(215, 179, 106, 0.3);
}

.hero-wordmark-main::before {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(100deg, transparent 0%, rgba(255, 255, 255, 0.92) 12%, transparent 25%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  mix-blend-mode: screen;
  animation: wordmark-shine 5.4s ease-in-out infinite;
  pointer-events: none;
}

.hero-wordmark-main::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  z-index: -1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(215, 179, 106, 0.18);
  transform: translate3d(0.035em, 0.035em, 0);
}

.hero-wordmark-rule {
  display: block;
  width: min(610px, 66vw);
  height: 12px;
  margin: 7px 0 0 8px;
  background:
    radial-gradient(circle at 50% 50%, rgba(141, 98, 163, 0.82) 0 4px, transparent 5px),
    linear-gradient(90deg, transparent, rgba(215, 179, 106, 0.92), transparent) center / 100% 1px no-repeat;
  filter: drop-shadow(0 0 16px rgba(215, 179, 106, 0.22));
}

.hero-wordmark-sub {
  display: inline-grid;
  grid-template-columns: auto;
  align-items: end;
  gap: 0;
  width: fit-content;
  margin: 2px 0 0 9px;
  padding: 0;
  border-left: 1px solid rgba(215, 179, 106, 0.52);
  color: rgba(248, 239, 227, 0.82);
  background: transparent;
  font-family: var(--font-body);
}

.hero-wordmark-sub b {
  padding-left: 12px;
  font-weight: 600;
}

.hero h1::after,
.identity h2::after,
.scrolly h2::after,
.anatomy h2::after,
.gallery h2::after,
.profile h2::after,
.finale h2::after {
  content: "";
  display: block;
  width: min(420px, 44vw);
  height: 1px;
  margin-top: 0.16em;
  background: linear-gradient(90deg, transparent, rgba(215, 179, 106, 0.82), rgba(141, 98, 163, 0.62), transparent);
  box-shadow: 0 0 18px rgba(215, 179, 106, 0.22);
}

.hero-line {
  position: relative;
  z-index: 4;
  max-width: 520px;
  display: block;
  margin: 18px 0 0 20px;
  padding: 0 0 0 16px;
  border-left: 1px solid rgba(215, 179, 106, 0.52);
  border-top: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  color: rgba(248, 239, 227, 0.9);
  font-size: clamp(1rem, 1.18vw, 1.18rem);
  line-height: 1.78;
  box-shadow: none;
}

.hero-actions {
  position: relative;
  z-index: 4;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0 0 20px;
}

.hero-actions a {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 0;
  min-width: 126px;
  min-height: 44px;
  padding: 7px 18px 8px;
  border: 1px solid rgba(215, 179, 106, 0.34);
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(248, 239, 227, 0.055), rgba(7, 6, 7, 0.42)),
    var(--glass);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.24);
  font-family: var(--font-body);
  font-weight: 600;
  transition: background 180ms ease, color 180ms ease, transform 180ms ease;
}

.hero-actions a span {
  position: relative;
  z-index: 2;
}

.hero-actions a span {
  font-weight: 700;
}

.hero-actions a::after {
  content: none;
}

.hero-actions a:first-child {
  background:
    linear-gradient(95deg, #f7df9b, #c99a3f 50%, #f3dda3);
  color: var(--ink);
  border-color: var(--gold);
  box-shadow: 0 0 26px rgba(215, 179, 106, 0.16), 0 14px 34px rgba(0, 0, 0, 0.3);
}

.hero-actions a:hover,
.hero-actions a:focus-visible {
  transform: translateY(-3px);
  background: var(--ivory);
  color: var(--ink);
}

.codex {
  position: relative;
  overflow: hidden;
  padding: 82px 5.8vw 94px;
  background:
    radial-gradient(circle at 78% 16%, rgba(215, 179, 106, 0.1), transparent 28%),
    radial-gradient(circle at 18% 72%, rgba(141, 98, 163, 0.16), transparent 34%),
    linear-gradient(180deg, #080708, #120d15 54%, #070607);
  border-top: 1px solid rgba(215, 179, 106, 0.18);
  border-bottom: 1px solid rgba(215, 179, 106, 0.18);
}

.codex::before {
  content: "";
  position: absolute;
  inset: 22px 4vw 28px;
  border: 1px solid rgba(215, 179, 106, 0.16);
  border-radius: 8px;
  pointer-events: none;
  box-shadow:
    inset 0 0 0 1px rgba(248, 239, 227, 0.04),
    0 0 70px rgba(215, 179, 106, 0.05);
}

.codex::after {
  content: "";
  position: absolute;
  right: 6vw;
  top: 68px;
  width: min(280px, 22vw);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(215, 179, 106, 0.42));
  pointer-events: none;
}

.codex > :not(.motion-field) {
  position: relative;
  z-index: 1;
}

.display-title > span {
  display: block;
}

.display-title {
  position: relative;
  text-wrap: balance;
}

.display-title::before {
  content: "";
  position: absolute;
  left: -0.18em;
  top: 0.08em;
  width: 0.06em;
  height: 0.82em;
  background: linear-gradient(180deg, var(--gold-bright), rgba(141, 98, 163, 0.45), transparent);
  box-shadow: 0 0 26px rgba(215, 179, 106, 0.24);
}

.display-title > span:nth-child(2) {
  color: var(--rose);
  background: linear-gradient(105deg, #fff5dc 0%, #d7b36a 33%, #d2a8bd 78%, #8d62a3 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.codex-head {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(280px, 0.42fr);
  gap: 38px;
  align-items: end;
  max-width: 1120px;
}

.codex-head .section-kicker {
  grid-column: 1 / -1;
}

.codex-head h2 {
  max-width: 860px;
  font-size: clamp(2.75rem, 4.8vw, 5.45rem);
  line-height: 0.98;
}

.codex-lede {
  position: relative;
  margin: 0;
  padding: 0 0 0 18px;
  border: 0;
  border-left: 1px solid rgba(215, 179, 106, 0.64);
  border-radius: 0;
  background: transparent;
  color: rgba(248, 239, 227, 0.82);
  font-size: 1rem;
  line-height: 1.82;
  box-shadow: none;
}

.codex-lede span {
  display: block;
  margin-bottom: 7px;
  color: var(--gold-bright);
  font-family: var(--font-display);
  font-size: 1.12rem;
  line-height: 1;
}

.codex-lede::after {
  content: none;
}

.codex-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.48fr);
  gap: 44px;
  align-items: center;
  margin-top: 36px;
}

.codex-atlas {
  position: relative;
  min-height: 620px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(215, 179, 106, 0.3);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 239, 227, 0.04), rgba(7, 6, 7, 0.58)),
    rgba(7, 6, 7, 0.64);
  box-shadow:
    0 34px 92px rgba(0, 0, 0, 0.44),
    0 0 46px rgba(141, 98, 163, 0.08);
  transform: translate3d(0, calc(var(--float-y, 0) * 1px), 0);
  transition: transform 220ms ease, border-color 220ms ease;
}

.codex-atlas::before,
.codex-atlas::after {
  content: "";
  position: absolute;
  z-index: 2;
  pointer-events: none;
}

.codex-atlas::before {
  inset: 18px;
  border: 1px solid rgba(248, 223, 156, 0.22);
  border-radius: 5px;
}

.codex-atlas::after {
  content: none;
}

.codex-atlas img {
  width: 100%;
  height: 100%;
  min-height: 620px;
  object-fit: cover;
  border-radius: 7px;
  filter: saturate(1.08) contrast(1.05) brightness(0.92);
}

.codex-atlas figcaption {
  position: absolute;
  left: 30px;
  right: auto;
  bottom: 30px;
  z-index: 3;
  max-width: 220px;
  padding: 0 0 0 12px;
  border-left: 1px solid rgba(215, 179, 106, 0.62);
  background: transparent;
  color: rgba(248, 239, 227, 0.7);
  font-size: 0.82rem;
  line-height: 1.7;
}

.codex-notes {
  display: grid;
  gap: 0;
  border-left: 1px solid rgba(215, 179, 106, 0.22);
}

.codex-note {
  position: relative;
  overflow: hidden;
  min-height: auto;
  display: grid;
  grid-template-columns: 48px 1fr;
  column-gap: 18px;
  align-items: start;
  padding: 22px 0 22px 22px;
  border: 0;
  border-bottom: 1px solid rgba(215, 179, 106, 0.18);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.codex-note::before,
.gallery-cell::before,
.hero-actions a::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  background: radial-gradient(
    circle at var(--spot-x, 50%) var(--spot-y, 50%),
    rgba(248, 223, 156, 0.28),
    rgba(141, 98, 163, 0.12) 32%,
    transparent 62%
  );
  transition: opacity 180ms ease;
}

.codex-note:hover::before,
.gallery-cell:hover::before,
.hero-actions a:hover::before,
.codex-note:focus-within::before,
.gallery-cell:focus-visible::before,
.hero-actions a:focus-visible::before {
  opacity: 1;
}

.codex-note::before {
  display: none;
}

.codex-note::after {
  content: none;
}

.codex-note span {
  grid-row: span 3;
  color: rgba(215, 179, 106, 0.82);
  font-family: var(--font-display);
  font-size: 1.85rem;
  line-height: 0.9;
}

.codex-note h3 {
  margin: 0 0 8px;
  color: var(--gold-bright);
  font-size: clamp(1.18rem, 1.35vw, 1.5rem);
  line-height: 1.15;
}

.codex-note p {
  margin: 0;
  color: rgba(248, 239, 227, 0.72);
  font-size: 0.94rem;
  line-height: 1.72;
}

.codex-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: min(520px, 100%);
  margin: 16px 0 0 auto;
  opacity: 0.48;
}

.codex-slice {
  min-height: 42px;
  border: 1px solid rgba(215, 179, 106, 0.24);
  border-radius: 4px;
  background-image:
    linear-gradient(180deg, rgba(7, 6, 7, 0.36), rgba(7, 6, 7, 0.66)),
    url("assets/generated/ui-typography-mood.png");
  background-size: auto, 760px 760px;
  box-shadow: none;
  animation: none;
}

.codex-slice.wordmark {
  background-position: center, 0 64px;
}

.codex-slice.portrait {
  background-position: center, -520px -16px;
}

.codex-slice.symbols {
  background-position: center, -520px -470px;
}

.identity {
  position: relative;
  overflow: hidden;
  padding: 84px 6vw 96px;
  background:
    linear-gradient(90deg, rgba(141, 98, 163, 0.13), transparent 48%),
    var(--black);
}

.identity::before {
  content: "";
  position: absolute;
  right: -8vw;
  top: -16vh;
  width: min(58vw, 840px);
  height: 118%;
  background:
    linear-gradient(90deg, rgba(15, 13, 16, 0.94), transparent 38%),
    url("assets/character/scene-03.jpg") center / cover;
  opacity: 0.24;
  filter: saturate(0.9) brightness(0.9);
  pointer-events: none;
}

.identity > * {
  position: relative;
  z-index: 1;
}

.identity h2,
.codex h2,
.scrolly h2,
.anatomy h2,
.gallery h2,
.profile h2,
.finale h2 {
  max-width: 980px;
  margin: 0;
  color: var(--gold-bright);
  background: linear-gradient(105deg, #fff5dc 0%, #cfa450 42%, #f6e4b2 58%, #8d62a3 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: clamp(2.55rem, 6.4vw, 7.1rem);
  font-weight: 400;
  line-height: 0.96;
  text-shadow:
    0 18px 70px rgba(0, 0, 0, 0.86),
    0 0 28px rgba(215, 179, 106, 0.16);
}

.identity-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 36px;
}

.identity-item {
  position: relative;
  overflow: hidden;
  min-height: 382px;
  display: grid;
  grid-template-rows: auto auto auto 1fr;
  align-content: start;
  padding: 10px 12px 20px;
  border: 1px solid rgba(215, 179, 106, 0.18);
  border-radius: 6px;
  background:
    radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 42%), rgba(248, 223, 156, 0.1), transparent 34%),
    linear-gradient(180deg, rgba(248, 239, 227, 0.045), rgba(0, 0, 0, 0.38)),
    rgba(248, 239, 227, 0.035);
  box-shadow:
    0 22px 58px rgba(0, 0, 0, 0.28);
}

.identity-item::before {
  content: none;
}

.identity-item:nth-child(1)::before {
  content: none;
}

.identity-item:nth-child(2)::before {
  content: none;
}

.identity-item:nth-child(3)::before {
  content: none;
}

.identity-item:nth-child(4)::before {
  content: none;
}

.identity-item::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  z-index: 3;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), var(--aqua), var(--violet), transparent);
  opacity: 0.9;
}

.identity-visual {
  position: relative;
  z-index: 2;
  height: 228px;
  overflow: hidden;
  margin-bottom: 14px;
  border: 1px solid rgba(248, 239, 227, 0.14);
  border-radius: 4px;
  background: var(--panel);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.32);
}

.identity-visual::before {
  content: "";
  position: absolute;
  inset: 8px;
  z-index: 2;
  border: 1px solid rgba(215, 179, 106, 0.24);
  border-radius: 3px;
  pointer-events: none;
}

.identity-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, transparent 42%, rgba(7, 6, 7, 0.76)),
    linear-gradient(90deg, rgba(7, 6, 7, 0.42), transparent 48%, rgba(7, 6, 7, 0.18));
  pointer-events: none;
}

.identity-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.98) contrast(1.04) brightness(0.84);
  transform: scale(1.06);
  transition: transform 640ms ease, filter 640ms ease;
}

.identity-item:nth-child(1) .identity-visual img {
  object-position: 48% 24%;
}

.identity-item:nth-child(2) .identity-visual img {
  object-position: 55% 36%;
}

.identity-item:nth-child(3) .identity-visual img {
  object-position: 52% 34%;
}

.identity-item:nth-child(4) .identity-visual img {
  object-position: 52% 24%;
}

.identity-visual span {
  position: absolute;
  left: 14px;
  bottom: 12px;
  z-index: 3;
  color: rgba(248, 239, 227, 0.86);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.86);
}

.identity-visual span::before {
  content: "✦";
  margin-right: 8px;
  color: var(--gold);
}

.identity-item > span,
.scene-step span,
.profile-row span {
  position: relative;
  z-index: 2;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 2rem;
}

.identity-item > span {
  margin-bottom: 4px;
  color: rgba(215, 179, 106, 0.78);
  font-size: 1.18rem;
  line-height: 1;
}

.identity-item h3,
.scene-step h3,
.profile-row h3 {
  position: relative;
  z-index: 2;
  margin: 8px 0 9px;
  color: #fff4d8;
  font-size: 1.32rem;
  font-family: var(--font-display);
  font-weight: 400;
  text-shadow: 0 0 18px rgba(215, 179, 106, 0.12);
}

.identity-item p,
.scene-step p,
.profile-row p,
.anatomy-notes p {
  position: relative;
  z-index: 2;
  margin: 0;
  color: var(--muted);
  font-family: var(--font-body);
}

.identity-item p {
  margin-top: 6px;
  padding-top: 0;
  border-top: 0;
  font-size: 0.94rem;
  line-height: 1.76;
}

.identity h2 {
  max-width: 720px;
  font-size: clamp(2.65rem, 4.6vw, 5.05rem);
}

.codex .codex-head h2 {
  max-width: 860px;
  font-size: clamp(2.75rem, 4.55vw, 5.18rem);
  line-height: 0.98;
}

.identity-item:hover .identity-visual img {
  transform: scale(1.12);
  filter: saturate(1.08) contrast(1.08) brightness(0.98);
}

.scrolly {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(360px, 0.88fr);
  gap: 5vw;
  padding: 110px 6vw;
  background: var(--ink);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.scrolly-stage {
  position: sticky;
  top: 90px;
  height: calc(100svh - 130px);
  align-self: start;
}

.scene-frame {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.scene-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--focus-x, 50%) var(--focus-y, 50%);
  opacity: 1;
  transform: scale(1.02);
  transition: opacity 260ms ease, transform 700ms ease;
}

.scene-image.is-changing {
  opacity: 0;
  transform: scale(1.08);
}

.scanline {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, transparent, rgba(7, 6, 7, 0.26)),
    repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.045) 0 1px, transparent 1px 8px);
  mix-blend-mode: overlay;
  opacity: 0.32;
}

.scene-label {
  position: absolute;
  left: 18px;
  bottom: 18px;
  display: grid;
  gap: 2px;
  padding: 13px 16px;
  border: 1px solid rgba(215, 179, 106, 0.28);
  border-radius: 5px;
  background:
    linear-gradient(145deg, rgba(248, 239, 227, 0.08), rgba(7, 6, 7, 0.76)),
    rgba(7, 6, 7, 0.72);
  backdrop-filter: blur(14px);
  box-shadow: var(--inner-glow), 0 20px 42px rgba(0, 0, 0, 0.42);
}

.scene-label span {
  color: rgba(248, 239, 227, 0.56);
  font-size: 0.68rem;
}

.scene-label strong {
  color: var(--gold-bright);
  font-size: 1.15rem;
  font-family: var(--font-display);
  font-weight: 400;
  text-shadow: 0 0 22px rgba(215, 179, 106, 0.28);
}

.scrolly-copy {
  padding: 10vh 0 18vh;
}

.scene-step {
  min-height: 64vh;
  display: grid;
  align-content: center;
  padding: 28px 28px 28px 0;
  border-top: 1px solid rgba(215, 179, 106, 0.18);
  opacity: 0.66;
  transition: opacity 220ms ease, transform 220ms ease;
}

.scene-step.is-active {
  opacity: 1;
  transform: translateX(8px);
}

.scene-step h3 {
  max-width: 720px;
  color: #fff7e7;
  font-size: clamp(2rem, 4.4vw, 5.2rem);
  font-weight: 900;
  line-height: 0.96;
  text-shadow:
    0 18px 42px rgba(0, 0, 0, 0.76),
    0 0 20px rgba(215, 179, 106, 0.18);
}

.scene-step h3::after {
  content: "";
  display: block;
  width: min(260px, 42vw);
  height: 1px;
  margin-top: 18px;
  background: linear-gradient(90deg, rgba(215, 179, 106, 0.9), rgba(141, 98, 163, 0.5), transparent);
}

.scene-step p {
  max-width: 540px;
  padding-left: 18px;
  border-left: 1px solid rgba(215, 179, 106, 0.28);
  font-size: 1.02rem;
  line-height: 1.95;
}

.anatomy {
  display: grid;
  grid-template-columns: 0.72fr 1.2fr;
  gap: 5vw;
  padding: 124px 6vw;
  background:
    linear-gradient(90deg, rgba(159, 213, 209, 0.1), transparent 34%),
    #101115;
}

.anatomy-copy {
  align-self: start;
  position: sticky;
  top: 110px;
}

.anatomy-copy h2 {
  font-size: clamp(2.4rem, 5.2vw, 5.6rem);
}

.anatomy-board {
  position: relative;
  min-height: 720px;
  overflow: hidden;
  border: 1px solid rgba(215, 179, 106, 0.24);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow), var(--inner-glow);
}

.anatomy-board img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.94) contrast(1.05) brightness(0.9);
}

.anatomy-board::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.08) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255,255,255,0.08) 1px, transparent 1px);
  background-size: 33.333% 33.333%;
  mix-blend-mode: overlay;
  pointer-events: none;
}

.ring,
.line,
.caption {
  position: absolute;
  z-index: 2;
  pointer-events: none;
}

.ring-face {
  left: 40%;
  top: 19%;
  width: 18%;
  aspect-ratio: 1;
  border: 1px solid rgba(215, 179, 106, 0.96);
  border-radius: 999px;
  box-shadow: 0 0 32px rgba(215, 179, 106, 0.32);
}

.line-diagonal {
  left: 8%;
  top: 57%;
  width: 88%;
  height: 1px;
  background: rgba(159, 213, 209, 0.88);
  transform: rotate(-32deg);
  transform-origin: left center;
}

.line-vertical {
  right: 17%;
  top: 0;
  width: 1px;
  height: 100%;
  background: rgba(141, 98, 163, 0.76);
}

.caption {
  padding: 6px 8px;
  border: 1px solid rgba(215, 179, 106, 0.32);
  border-radius: 4px;
  background: rgba(7, 6, 7, 0.72);
  color: rgba(248, 239, 227, 0.86);
  font-size: 0.68rem;
  font-family: var(--font-body);
  box-shadow: var(--inner-glow);
}

.cap-face {
  left: 58%;
  top: 22%;
}

.cap-line {
  right: 10%;
  top: 51%;
}

.cap-light {
  left: 10%;
  top: 10%;
}

.anatomy-notes {
  grid-column: 2;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.anatomy-notes p {
  padding: 22px;
  border: 1px solid rgba(215, 179, 106, 0.22);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(248, 239, 227, 0.06), rgba(7, 6, 7, 0.16)),
    rgba(248, 239, 227, 0.035);
  box-shadow: var(--inner-glow);
}

.gallery {
  padding: 120px 6vw;
  background: var(--black);
  border-top: 1px solid var(--line);
}

.gallery-head {
  margin-bottom: 54px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-auto-flow: dense;
  gap: 12px;
}

.gallery-cell {
  position: relative;
  grid-column: span 4;
  min-height: 420px;
  overflow: hidden;
  padding: 0;
  border: 1px solid rgba(215, 179, 106, 0.2);
  border-radius: 8px;
  background: var(--panel);
  cursor: zoom-in;
  box-shadow: var(--inner-glow), 0 26px 66px rgba(0, 0, 0, 0.26);
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.gallery-cell.wide {
  grid-column: span 8;
}

.gallery-cell.tall {
  grid-row: span 2;
  min-height: 640px;
}

.gallery-cell img {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
  object-position: var(--focus-x, 50%) var(--focus-y, 50%);
  filter: saturate(0.92) brightness(0.86);
  transition: transform 620ms ease, filter 620ms ease;
}

.gallery-cell::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 45%, rgba(7, 6, 7, 0.9)),
    linear-gradient(90deg, rgba(215, 179, 106, 0.12), transparent 34%);
  pointer-events: none;
}

.gallery-cell span {
  position: absolute;
  left: 16px;
  bottom: 14px;
  z-index: 2;
  color: var(--gold-bright);
  font-size: 1.28rem;
  text-shadow:
    0 8px 28px rgba(0, 0, 0, 0.8),
    0 0 22px rgba(215, 179, 106, 0.24);
}

.gallery-cell:hover img,
.gallery-cell:focus-visible img {
  transform: scale(1.07);
  filter: saturate(1.06) brightness(1);
}

.identity-item,
.gallery-cell,
.hero-actions a {
  transform-style: preserve-3d;
}

.identity-item:hover,
.gallery-cell:hover {
  border-color: rgba(248, 223, 156, 0.54);
  box-shadow: var(--inner-glow), 0 34px 88px rgba(0, 0, 0, 0.4), 0 0 28px rgba(215, 179, 106, 0.12);
  transform: translateY(-4px) rotateX(calc(var(--tilt-y, 0) * -0.025deg)) rotateY(calc(var(--tilt-x, 0) * 0.025deg));
}

.profile {
  position: relative;
  overflow: hidden;
  min-height: 100svh;
  background:
    linear-gradient(90deg, rgba(141, 98, 163, 0.12), transparent 44%),
    var(--ink);
  border-top: 1px solid var(--line);
}

.profile-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.95), rgba(7, 6, 7, 0.76) 44%, rgba(7, 6, 7, 0.9)),
    url("assets/generated/hero-bg.png") center / cover;
  filter: saturate(0.72) brightness(0.62);
}

.profile-inner {
  position: relative;
  z-index: 1;
  width: min(1180px, 88vw);
  margin: 0 auto;
  padding: 118px 0;
}

.profile h2 {
  max-width: 760px;
  font-size: clamp(2.55rem, 5.15vw, 5.72rem);
}

.profile-stage {
  display: grid;
  grid-template-columns: minmax(320px, 0.84fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  margin-top: 54px;
}

.profile-portrait {
  position: relative;
  overflow: hidden;
  margin: 0;
  min-height: 580px;
  border: 1px solid rgba(215, 179, 106, 0.24);
  border-radius: 8px;
  box-shadow: 0 34px 92px rgba(0, 0, 0, 0.42);
}

.profile-portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 18px solid rgba(7, 6, 7, 0.3);
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(248, 223, 156, 0.18);
}

.profile-portrait img {
  width: 100%;
  height: 100%;
  min-height: 580px;
  object-fit: cover;
  object-position: 50% 36%;
  filter: saturate(0.95) contrast(1.04) brightness(0.84);
}

.profile-portrait figcaption {
  position: absolute;
  left: 28px;
  bottom: 26px;
  z-index: 2;
  padding-left: 12px;
  border-left: 1px solid rgba(215, 179, 106, 0.62);
  color: rgba(248, 239, 227, 0.72);
  font-family: var(--font-display);
  font-size: 1.1rem;
}

.profile-list {
  display: grid;
  gap: 0;
  margin-top: 0;
  border-top: 1px solid rgba(215, 179, 106, 0.24);
}

.profile-row {
  display: grid;
  grid-template-columns: 142px minmax(0, 1fr);
  gap: 26px;
  align-items: start;
  padding: 34px 0;
  border-top: 0;
  border-bottom: 1px solid rgba(215, 179, 106, 0.24);
}

.profile-row:last-child {
  border-bottom: 1px solid rgba(215, 179, 106, 0.24);
}

.profile-row h3,
.profile-row p {
  margin: 0;
}

.profile-row h3 {
  color: var(--gold-bright);
  font-size: clamp(1.32rem, 2.2vw, 2.1rem);
  line-height: 1.1;
  text-shadow: 0 0 18px rgba(215, 179, 106, 0.16);
}

.profile-row p {
  max-width: 560px;
  color: rgba(248, 239, 227, 0.78);
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.9;
}

@keyframes codex-glow {
  0%,
  100% {
    filter: brightness(0.9) saturate(0.94);
    box-shadow: var(--inner-glow), 0 24px 68px rgba(0, 0, 0, 0.28);
  }
  50% {
    filter: brightness(1.05) saturate(1.08);
    box-shadow: var(--inner-glow), 0 24px 68px rgba(0, 0, 0, 0.28), 0 0 34px rgba(215, 179, 106, 0.18);
  }
}

@keyframes wordmark-shine {
  0%,
  22% {
    background-position: 170% 0;
  }
  58%,
  100% {
    background-position: -70% 0;
  }
}

.finale {
  position: relative;
  min-height: 94svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--ink);
}

.finale img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.48) saturate(0.82);
}

.finale::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 7, 0.9), rgba(7, 6, 7, 0.2), rgba(7, 6, 7, 0.9)),
    linear-gradient(0deg, rgba(7, 6, 7, 0.94), transparent 52%, rgba(7, 6, 7, 0.68));
}

.finale-copy {
  position: relative;
  z-index: 1;
  width: min(780px, 86vw);
  text-align: center;
}

.finale-copy p {
  margin: 0 0 18px;
  color: var(--gold-bright);
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.1vw, 2.25rem);
  font-weight: 400;
  text-shadow: 0 0 24px rgba(215, 179, 106, 0.34);
}

.finale h2 {
  max-width: 780px;
  margin: 0 auto;
  width: max-content;
  font-family: var(--font-body);
  font-size: clamp(2.2rem, 4.8vw, 5.6rem);
  font-weight: 800;
  line-height: 1.08;
  white-space: nowrap;
  word-break: keep-all;
}

.finale-copy span {
  display: block;
  max-width: 560px;
  margin: 28px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(215, 179, 106, 0.28);
  color: rgba(248, 239, 227, 0.76);
  font-size: clamp(1rem, 1.25vw, 1.15rem);
  line-height: 1.86;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(7, 6, 7, 0.92);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.lightbox[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.lightbox img {
  max-width: min(1120px, 92vw);
  max-height: 84vh;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(248, 239, 227, 0.24);
  border-radius: 5px;
  background: rgba(248, 239, 227, 0.08);
  cursor: pointer;
  font-size: 2rem;
  line-height: 1;
}

.reveal {
  opacity: 0;
  filter: blur(12px);
  transform: translateY(36px) scale(0.985);
  transition: opacity 760ms ease, filter 760ms ease, transform 760ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.reveal.is-visible {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
}

.char {
  display: inline-block;
  opacity: 0;
  filter: blur(14px);
  color: var(--gold-bright);
  background: linear-gradient(105deg, #fff5dc 0%, #cfa450 42%, #f6e4b2 58%, #8d62a3 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  transform: translateY(0.58em) rotateX(52deg) scale(0.96);
  transform-origin: 50% 80%;
  transition:
    opacity 720ms ease,
    filter 720ms ease,
    transform 900ms cubic-bezier(0.18, 0.88, 0.22, 1);
  transition-delay: calc(var(--char-index, 0) * 14ms);
  will-change: transform, filter, opacity;
}

.display-title > span:nth-child(2) .char {
  background: linear-gradient(105deg, #fff5dc 0%, #d7b36a 33%, #d2a8bd 78%, #8d62a3 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

.is-visible .char,
.reveal.is-visible .char {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) rotateX(0) scale(1);
}

html.qa-ready .reveal,
html.qa-ready .char {
  opacity: 1 !important;
  filter: none !important;
  transform: none !important;
  transition: none !important;
}

@media (max-width: 1100px) {
  .hero-figure {
    right: -18vw;
    width: 104vw;
  }

  .identity-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .codex-layout {
    grid-template-columns: 1fr;
  }

  .codex-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .codex-atlas {
    min-height: auto;
  }

  .codex-atlas img {
    min-height: 0;
    aspect-ratio: 1;
  }

  .identity-item {
    min-height: 390px;
  }

  .scrolly,
  .anatomy {
    grid-template-columns: 1fr;
  }

  .anatomy-copy {
    position: relative;
    top: auto;
  }

  .scrolly-stage {
    top: 74px;
    height: min(56svh, 560px);
  }

  .anatomy-notes {
    grid-column: auto;
  }

  .gallery-cell,
  .gallery-cell.wide {
    grid-column: span 6;
  }
}

@media (max-width: 760px) {
  .cursor-light {
    display: none;
  }

  .topbar {
    position: absolute;
    align-items: start;
    padding: 16px;
    mix-blend-mode: normal;
  }

  .topbar .desktop-nav {
    display: none;
  }

  .topbar .mobile-nav {
    display: flex;
    gap: 8px;
    margin-top: 2px;
  }

  .topbar .mobile-nav a {
    min-width: 52px;
    min-height: 46px;
    padding: 6px 10px 7px;
    border: 1px solid rgba(248, 239, 227, 0.22);
    border-radius: 5px;
    background: rgba(7, 6, 7, 0.58);
    color: rgba(248, 239, 227, 0.86);
    backdrop-filter: blur(14px);
    font-size: 0.72rem;
  }

  .hero {
    min-height: 100svh;
    padding: 122px 18px 34px;
  }

  .hero::after {
    right: -34vw;
    bottom: 20vh;
    font-size: clamp(6.4rem, 37vw, 10rem);
  }

  .hero-bg {
    background:
      linear-gradient(0deg, rgba(7, 6, 7, 0.98), rgba(7, 6, 7, 0.28) 52%, rgba(7, 6, 7, 0.72)),
      url("assets/generated/hero-bg.png") center / cover;
  }

  .hero-figure {
    inset: auto 0 auto 0;
    top: 104px;
    width: 100vw;
    height: 36svh;
    opacity: 0.94;
    object-fit: cover;
    object-position: 50% 42%;
    clip-path: polygon(0 0, 100% 0, 100% 86%, 0 100%);
    box-shadow: 0 34px 84px rgba(0, 0, 0, 0.8);
    transform: none;
  }

  .hero-orbit span {
    right: -33vw;
    top: 12vh;
    width: 124vw;
  }

  .hero-orbit span:nth-child(2) {
    right: -5vw;
    top: 17vh;
    width: 78vw;
  }

  .hero-orbit span:nth-child(3) {
    display: none;
  }

  .hero-copy {
    width: 100%;
    margin-top: 32svh;
  }

  .hero-wordmark {
    width: 100%;
    padding-top: 14px;
  }

  .hero-wordmark::before {
    left: -12px;
    right: -8px;
    clip-path: polygon(0 0, 100% 0, 94% 100%, 0 100%);
  }

  .hero-wordmark-main {
    font-size: clamp(3.75rem, 18vw, 5.9rem);
    line-height: 0.76;
    -webkit-text-stroke: 0.35px rgba(255, 247, 223, 0.24);
  }

  .hero-wordmark-rule {
    width: min(76vw, 420px);
    margin-top: 7px;
  }

  .hero-wordmark-sub {
    grid-template-columns: 1fr;
    gap: 3px;
    font-size: 0.78rem;
  }

  .hero-title-backdrop {
    left: -18px;
    right: -10px;
    top: 38px;
    bottom: -22px;
    background: linear-gradient(90deg, rgba(7, 6, 7, 0.92), rgba(7, 6, 7, 0.62) 72%, transparent);
  }

  .hero-line {
    width: min(92vw, 520px);
    display: block;
    grid-template-columns: none;
    gap: 0;
    margin: 12px 0 0 10px;
    padding: 0 0 0 12px;
    font-size: 0.86rem;
    line-height: 1.72;
  }

  .eyebrow {
    max-width: 83vw;
    padding: 8px 12px;
    border-radius: 7px;
    background:
      linear-gradient(90deg, rgba(215, 179, 106, 0.16), rgba(7, 6, 7, 0.7) 54%, rgba(141, 98, 163, 0.14)),
      rgba(7, 6, 7, 0.62);
    font-size: 0.69rem;
    line-height: 1.48;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 15px 0 0 10px;
  }

  .hero-actions a {
    width: auto;
    justify-content: center;
    min-width: 0;
    min-height: 54px;
    padding: 7px 8px 8px;
    font-size: 0.88rem;
    text-align: center;
  }

  .identity,
  .codex,
  .anatomy,
  .gallery {
    padding: 76px 18px;
  }

  .codex::before {
    inset: 14px;
    border-radius: 12px;
  }

  .codex::after {
    right: 20px;
    top: 26px;
    font-size: 1.2rem;
  }

  .hero-motion,
  .codex-motion {
    display: none;
  }

  .codex-head {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .codex .codex-head h2 {
    font-size: clamp(2.2rem, 11vw, 3.55rem);
  }

  .codex-lede {
    padding: 0 0 0 14px;
    font-size: 0.92rem;
  }

  .codex-layout {
    margin-top: 34px;
  }

  .codex-atlas {
    padding: 8px;
    border-radius: 12px;
  }

  .codex-atlas::before {
    inset: 16px;
  }

  .codex-atlas figcaption {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    margin-top: 10px;
    background: transparent;
  }

  .codex-strip {
    display: none;
  }

  .codex-note {
    min-height: auto;
    grid-template-columns: 54px 1fr;
    padding: 18px 17px;
  }

  .codex-note span {
    font-size: 2.35rem;
  }

  .codex-slice {
    min-height: 28px;
    background-size: auto, 720px 720px;
  }

  .codex-slice.wordmark {
    background-position: center, 0 40px;
  }

  .codex-slice.portrait {
    background-position: center, -360px -10px;
  }

  .codex-slice.symbols {
    background-position: center, -360px -326px;
  }

  .scrolly {
    padding: 34px 18px 72px;
  }

  .identity h2,
  .codex h2,
  .scrolly h2,
  .anatomy h2,
  .gallery h2,
  .profile h2,
  .finale h2 {
    line-height: 1.04;
  }

  .identity-grid,
  .anatomy-notes,
  .profile-row {
    grid-template-columns: 1fr;
  }

  .identity-item {
    min-height: auto;
  }

  .identity-visual {
    height: 188px;
  }

  .scrolly {
    gap: 18px;
  }

  .scrolly-stage {
    position: sticky;
    top: 58px;
    z-index: 8;
    height: min(42svh, 370px);
  }

  .scrolly-copy {
    padding: 0;
  }

  .scene-step {
    min-height: 42vh;
    padding: 18px 0;
  }

  .scene-step.is-active {
    transform: none;
  }

  .scene-step p {
    padding-left: 14px;
    font-size: 0.94rem;
    line-height: 1.82;
  }

  .scrolly h2 {
    font-size: clamp(2.08rem, 9.4vw, 3.12rem);
  }

  .scene-step h3 {
    font-size: clamp(1.55rem, 7.6vw, 2.5rem);
    line-height: 1.1;
  }

  .anatomy-board {
    min-height: 520px;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .gallery-cell,
  .gallery-cell.wide,
  .gallery-cell.tall {
    grid-column: auto;
    grid-row: auto;
    min-height: 430px;
  }

  .profile-inner {
    width: calc(100% - 36px);
    padding: 86px 0;
  }

  .profile-stage {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-top: 32px;
  }

  .profile-portrait {
    min-height: 420px;
  }

  .profile-portrait img {
    min-height: 420px;
  }

  .profile-row {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 24px 0;
  }

  .finale-copy {
    width: calc(100% - 36px);
  }

  .finale h2 {
    max-width: 100%;
    font-size: clamp(1.9rem, 8vw, 2.7rem);
  }

  .finale-copy span {
    margin-top: 22px;
    font-size: 0.95rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
  }

  .reveal {
    opacity: 1;
    filter: none;
    transform: none;
  }

  .char {
    opacity: 1;
    filter: none;
    transform: none;
    transition: none;
  }
}




