:root {
  color-scheme: dark;
  --ink: #f4f1ed;
  --muted: #aaa9a8;
  --line: rgba(255, 255, 255, 0.16);
  --bg: #111212;
  --accent: #a8d4e6;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family: "Helvetica Neue", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

.scroll-progress {
  position: fixed;
  z-index: 100;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
}

.scroll-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--accent);
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  width: 100%;
  padding: 24px clamp(22px, 4vw, 64px);
  mix-blend-mode: difference;
}

.brand, nav a, .scroll-cue, footer a {
  color: #fff;
  text-decoration: none;
}

.brand { display: grid; gap: 3px; margin-left: 48px; }
.brand-mark { font-size: 12px; font-weight: 700; letter-spacing: 0; }
.brand-sub { color: #aaa; font-size: 9px; letter-spacing: 0; }

nav { display: flex; gap: clamp(16px, 3vw, 42px); }
nav a { font-size: 10px; transition: opacity .25s ease; }
nav a:hover { opacity: .55; }

.hero {
  position: relative;
  min-height: 100svh;
  height: min(100svh, 1080px);
  overflow: hidden;
  background: #272727;
}

.hero > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  animation: hero-in 1.4s cubic-bezier(.2,.7,.2,1) both;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.58) 0%, rgba(0,0,0,.12) 42%, rgba(0,0,0,.04) 70%), linear-gradient(0deg, rgba(0,0,0,.38), transparent 35%);
}

.hero-copy {
  position: absolute;
  left: clamp(24px, 7vw, 120px);
  bottom: clamp(92px, 15vh, 160px);
}

.eyebrow { margin: 0 0 14px; color: #ffefd1; font-size: 10px; font-weight: 600; }
.hero h1 { margin: 0; font-family: "Songti SC", "STSong", serif; font-size: clamp(48px, 8vw, 126px); font-weight: 400; line-height: .95; }
.hero-en { margin: 16px 0 0; color: rgba(255,255,255,.65); font-family: Georgia, serif; font-size: clamp(15px, 1.4vw, 22px); }

.scroll-cue {
  position: absolute;
  left: clamp(24px, 7vw, 120px);
  bottom: 34px;
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 9px;
}

.scroll-cue i { position: relative; width: 52px; height: 1px; overflow: hidden; background: rgba(255,255,255,.35); }
.scroll-cue i::after { position: absolute; content: ""; inset: 0; background: #fff; animation: cue 1.8s infinite ease-in-out; }
.hero-index { position: absolute; right: clamp(22px, 4vw, 64px); bottom: 31px; margin: 0; font: 11px Georgia, serif; }

.work-section {
  width: min(100% - 44px, 1420px);
  margin: 0 auto;
  padding: clamp(92px, 13vw, 190px) 0 0;
}

.section-heading {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: start;
  width: min(100%, 1040px);
  margin: 0 auto 38px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.section-number { margin: 5px 0 0; color: var(--accent); font: 11px Georgia, serif; }
.section-heading h2 { margin: 0; font-family: "Songti SC", "STSong", serif; font-size: clamp(28px, 4vw, 54px); font-weight: 400; line-height: 1.1; }
.section-heading div > p { margin: 8px 0 0; color: var(--muted); font: 13px Georgia, serif; }

.artwork {
  position: relative;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #292a2a;
  color: white;
  cursor: zoom-in;
}

.artwork-portrait { width: min(100%, 1060px); margin-inline: auto; }
.artwork img { display: block; width: 100%; height: auto; transition: transform .8s cubic-bezier(.2,.7,.2,1), filter .5s ease; }
.artwork:hover img { transform: scale(1.012); filter: brightness(.82); }
.view-hint { position: absolute; right: 20px; bottom: 18px; opacity: 0; font-size: 9px; transition: opacity .3s ease; }
.artwork:hover .view-hint { opacity: 1; }

.render-section { padding-bottom: clamp(100px, 14vw, 190px); }

footer {
  display: flex;
  justify-content: space-between;
  padding: 28px clamp(22px, 4vw, 64px);
  border-top: 1px solid var(--line);
  color: #777;
  font-size: 9px;
}

.lightbox {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 40px;
  border: 0;
  background: rgba(7, 8, 8, .96);
}

.lightbox::backdrop { background: rgba(0,0,0,.9); }
.lightbox img { display: block; width: 100%; height: 100%; object-fit: contain; }
.lightbox-close { position: fixed; z-index: 2; top: 18px; right: 24px; width: 40px; height: 40px; padding: 0; border: 0; background: transparent; color: #fff; font: 300 32px/1 Arial; cursor: pointer; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.is-visible { opacity: 1; transform: none; }

@keyframes cue { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
@keyframes hero-in { from { opacity: 0; transform: scale(1.035); } to { opacity: 1; transform: scale(1); } }

@media (max-width: 700px) {
  .site-header { padding-top: 18px; }
  nav { display: none; }
  .hero { height: 88svh; min-height: 620px; }
  .hero > img { object-position: 57% center; }
  .hero-shade { background: linear-gradient(0deg, rgba(0,0,0,.62), transparent 62%); }
  .hero-copy { bottom: 104px; }
  .hero h1 { font-size: 56px; }
  .work-section { width: calc(100% - 28px); padding-top: 92px; }
  .section-heading { grid-template-columns: 38px 1fr; margin-bottom: 24px; }
  .section-heading h2 { font-size: 32px; }
  .artwork-portrait { width: 100%; }
  .lightbox { padding: 16px; }
  footer { gap: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
/* Return to the portfolio homepage. */
.portfolio-close{position:fixed;top:24px;left:24px;z-index:1000;display:grid;place-items:center;width:48px;height:48px;border:1px solid rgba(255,255,255,.45);border-radius:50%;background:rgba(20,20,20,.72);color:#fff;text-decoration:none;font:300 34px/1 Arial,sans-serif;backdrop-filter:blur(10px);transition:background .2s,transform .2s}.portfolio-close:hover{background:#111;transform:scale(1.05)}
