:root {
  --paper: #f7f3e8;
  --milk: #fffaf0;
  --ink: #11100f;
  --muted: rgba(17, 16, 15, 0.64);
  --line: rgba(17, 16, 15, 0.12);
  --accent: #ef3215;
  --accent-soft: #7be8d8;
  --ease: cubic-bezier(0.19, 1, 0.22, 1);
}
* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); font-size: 62.5%; scroll-behavior: smooth; }
body {
  min-width: 32rem;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 12% 8%, color-mix(in srgb, var(--accent) 17%, transparent), transparent 31%),
    radial-gradient(circle at 88% 17%, color-mix(in srgb, var(--accent-soft) 20%, transparent), transparent 34%),
    linear-gradient(135deg, #fffaf1, var(--paper) 58%, #fff8ee);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 1.6rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
body.theme-yaya { --accent: #649df0; --accent-soft: #f7a7b6; --paper: #f3f8ff; --milk: #fffafb; }
body.theme-goodboy { --accent: #f1b632; --accent-soft: #5b9af4; --paper: #fff8e7; --milk: #fffdf7; }
body.theme-lingfu { --accent: #4f9c89; --accent-soft: #d7bd81; --paper: #f1f7ef; --milk: #fffaf0; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.grain {
  position: fixed;
  inset: -20%;
  z-index: 20;
  pointer-events: none;
  opacity: 0.028;
  background-image: linear-gradient(0deg, rgba(17,16,15,.55) 1px, transparent 1px), linear-gradient(90deg, rgba(17,16,15,.42) 1px, transparent 1px);
  background-size: 3px 3px;
}
.topbar {
  position: fixed;
  top: 2rem;
  left: 2rem;
  right: 2rem;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  min-height: 6rem;
  padding: 1rem 1.2rem 1rem 2rem;
  border: 1px solid rgba(17,16,15,.1);
  border-radius: 999px;
  background: rgba(255,250,240,.76);
  box-shadow: 0 18px 58px rgba(17,16,15,.1);
  backdrop-filter: blur(18px);
}
.topbar strong { font-size: 1.28rem; font-weight: 900; letter-spacing: .02em; text-transform: uppercase; }
.topbar nav { display: flex; gap: .8rem; }
.topbar a {
  display: inline-flex;
  align-items: center;
  min-height: 4rem;
  padding: 0 1.35rem;
  border: 1px solid rgba(17,16,15,.1);
  border-radius: 999px;
  background: rgba(255,255,255,.5);
  font-size: 1.2rem;
  font-weight: 850;
  transition: transform 280ms var(--ease), background 280ms ease;
}
.topbar a:hover { transform: translateY(-2px); background: var(--milk); }
.detail-hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 100svh;
  padding: 11rem min(6.8vw,9.6rem) 7rem;
  overflow: hidden;
}
.detail-hero::before {
  content: "";
  position: absolute;
  width: min(58rem,48vw);
  aspect-ratio: 1;
  right: -12vw;
  top: 8vh;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 30%, color-mix(in srgb,var(--accent-soft) 54%,white), transparent 66%);
  opacity: .52;
  animation: float-orb 8s ease-in-out infinite;
}
.detail-hero::after {
  content: "";
  position: absolute;
  width: min(20rem,20vw);
  aspect-ratio: 1;
  left: 35%;
  bottom: 6%;
  border-radius: 50%;
  background: var(--accent);
  opacity: .09;
  animation: float-orb 6s ease-in-out -2s infinite reverse;
}
.detail-hero__inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0,1.2fr) minmax(31rem,.8fr);
  gap: clamp(4.8rem,7vw,10rem);
  align-items: center;
  width: 100%;
  max-width: 150rem;
  margin: 0 auto;
}
.detail-hero__copy { min-width: 0; }
.kicker { display: inline-flex; align-items: center; gap: 1.2rem; margin-bottom: 2.2rem; color: color-mix(in srgb,var(--accent) 74%,var(--ink)); font-family: Georgia,"Times New Roman",serif; font-style: italic; }
.kicker::before { content: ""; width: 5.8rem; height: 1px; background: currentColor; }
.detail-hero h1 { margin: 0; max-width: 104rem; font-size: clamp(5.4rem,8.8vw,13.4rem); font-weight: 950; line-height: .86; letter-spacing: -.052em; text-transform: uppercase; text-wrap: balance; }
.detail-hero h1 em { display: block; margin-top: .28em; color: var(--accent); font-family: Georgia,"Times New Roman",serif; font-size: .38em; font-style: italic; font-weight: 540; line-height: 1.05; letter-spacing: .06em; text-transform: none; }
.detail-hero__intro { max-width: 72rem; margin: 3rem 0 0; color: var(--muted); font-size: clamp(1.7rem,1.25vw,2.1rem); line-height: 1.9; }
.detail-hero__side { position: relative; min-width: 0; padding: 3rem 0 3rem clamp(2.4rem,3.6vw,4.8rem); border-left: 1px solid var(--line); }
.detail-hero__side::before { content: ""; position: absolute; left: -1px; top: 3rem; width: 2px; height: 9rem; border-radius: 999px; background: linear-gradient(var(--accent),var(--accent-soft)); }
.detail-hero__index { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin-bottom: 2.8rem; color: rgba(17,16,15,.43); font-size: 1.12rem; font-weight: 900; letter-spacing: .16em; text-transform: uppercase; }
.detail-hero__index b { color: var(--ink); font-size: 4.6rem; line-height: 1; }
.detail-hero__label { margin: 0 0 1.6rem; color: var(--accent); font-size: 1.16rem; font-weight: 950; letter-spacing: .14em; text-transform: uppercase; }
.detail-meta { display: grid; gap: 1.5rem; margin: 0; }
.detail-meta div { display: grid; grid-template-columns: 7.8rem minmax(0,1fr); gap: 1.6rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); }
.detail-meta dt { color: rgba(17,16,15,.42); font-size: 1.08rem; font-weight: 950; letter-spacing: .13em; text-transform: uppercase; }
.detail-meta dd { margin: 0; color: rgba(17,16,15,.75); font-size: 1.48rem; line-height: 1.7; font-weight: 650; }
.detail-tags { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.4rem; }
.detail-tags span { display: inline-flex; align-items: center; min-height: 3.4rem; padding: 0 1.15rem; border: 1px solid color-mix(in srgb,var(--accent) 32%,transparent); border-radius: 999px; background: rgba(255,255,255,.44); font-size: 1.16rem; font-weight: 850; }
.scroll-tip { position: absolute; z-index: 2; left: min(6.8vw,9.6rem); bottom: 3rem; color: var(--muted); font-size: 1.1rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.gallery-wrap { position: relative; z-index: 2; padding: 7rem min(6.8vw,9.6rem) 12rem; background: linear-gradient(180deg,rgba(255,255,255,.58),var(--milk)); }
.gallery-head { display: flex; align-items: end; justify-content: space-between; gap: 3rem; max-width: 150rem; margin: 0 auto 4rem; }
.gallery-head h2 { margin: 0; font-size: clamp(4.8rem,7vw,10rem); font-weight: 950; line-height: .84; letter-spacing: -.055em; text-transform: uppercase; }
.gallery-head h2 em { color: var(--accent); font-family: Georgia,"Times New Roman",serif; font-style: italic; font-weight: 520; }
.gallery-head p { max-width: 48rem; margin: 0; color: var(--muted); line-height: 1.82; }
.gallery { max-width: 150rem; margin: 0 auto; }
.gallery--cards { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 2.2rem; }
.page-card { position: relative; margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 2.2rem; background: #fff; box-shadow: 0 24px 72px rgba(17,16,15,.11); opacity: 1; transform: none; transition: transform 400ms var(--ease), box-shadow 420ms var(--ease); }
.page-card.is-visible { opacity: 1; transform: translateY(0); }
.page-card:hover { transform: translateY(-.7rem); box-shadow: 0 36px 98px rgba(17,16,15,.16); }
.page-card img { display: block; width: 100%; height: auto; background: #fff; }
.page-card b { position: absolute; z-index: 2; top: 1.4rem; left: 1.4rem; display: grid; place-items: center; min-width: 4.6rem; height: 3.2rem; padding: 0 1rem; border-radius: 999px; background: rgba(255,250,240,.86); box-shadow: 0 8px 24px rgba(17,16,15,.1); backdrop-filter: blur(10px); font-size: 1.1rem; letter-spacing: .08em; }
.gallery-wrap--seamless { padding-bottom: 0; }
.gallery--seamless { display: grid; gap: 0; overflow: hidden; border-radius: 2.4rem 2.4rem 0 0; background: #fff; box-shadow: 0 30px 90px rgba(17,16,15,.12); }
.gallery--seamless figure { margin: 0; }
.gallery--seamless img { display: block; width: 100%; height: auto; margin: 0; }
.project-video-section { padding: 7rem min(6.8vw,9.6rem); }
.project-video-card { max-width: 150rem; margin: 0 auto; overflow: hidden; border: 1px solid var(--line); border-radius: 2.2rem; background: #fff; }
.project-video-card video { display: block; width: 100%; max-height: 76vh; aspect-ratio: 16 / 9; object-fit: contain; background: #111; }
.project-video-card figcaption { display: flex; justify-content: space-between; gap: 2rem; padding: 1.8rem 2rem; color: var(--muted); font-size: 1.4rem; }
.gallery-wrap, .project-video-section { scroll-margin-top: 10rem; }
.footer { padding: 5rem min(6.8vw,9.6rem); background: var(--ink); color: var(--milk); }
.footer__inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; max-width: 150rem; margin: 0 auto; }
.footer a { display: inline-flex; align-items: center; min-height: 4.4rem; padding: 0 1.4rem; border: 1px solid rgba(255,255,255,.28); border-radius: 999px; }
@keyframes float-orb { 50% { transform: translate3d(-2rem,2.5rem,0) scale(1.06); } }
@media (max-width: 980px) {
  .detail-hero { min-height: auto; padding: 11rem 2.4rem 7rem; }
  .detail-hero__inner { grid-template-columns: 1fr; gap: 4rem; }
  .detail-hero__side { padding: 2.8rem 0 0; border-top: 1px solid var(--line); border-left: 0; }
  .detail-hero__side::before { top: -1px; left: 0; width: 16rem; height: 2px; background: linear-gradient(90deg,var(--accent),var(--accent-soft)); }
  .scroll-tip { position: static; margin: 3rem 0 0; }
  .gallery-wrap { padding: 6rem 2.4rem 9rem; }
  .gallery-wrap--seamless { padding-bottom: 0; }
}
@media (max-width: 720px) {
  .detail-hero { padding-top: 15rem; }
  .gallery-wrap, .project-video-section { scroll-margin-top: 14rem; }
  .topbar { top: 1rem; left: 1rem; right: 1rem; align-items: flex-start; border-radius: 2rem; }
  .topbar strong { padding-top: 1.1rem; }
  .topbar nav { flex-wrap: wrap; justify-content: flex-end; }
  .detail-hero h1 { font-size: clamp(4.6rem,16vw,7.5rem); line-height: .92; }
  .detail-hero h1 em { font-size: .48em; }
  .topbar a { min-height: 4.4rem; }
  .grain { display: none; }
  .detail-hero::before, .detail-hero::after { animation: none; }
  .project-video-section { padding: 5rem 2.4rem; }
  .project-video-card figcaption { display: grid; gap: .6rem; }
  .page-card:hover { transform: none; }
  .detail-meta div { grid-template-columns: 1fr; gap: .4rem; }
  .gallery-head { display: grid; }
  .gallery--cards { grid-template-columns: 1fr; }
  .gallery--seamless { border-radius: 1.6rem 1.6rem 0 0; }
  .footer__inner { display: grid; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .page-card { opacity: 1; transform: none; }
}
