/* ============================================================
   HONGFEI — personal site
   Design system
   ------------------------------------------------------------
   palette   : ink #08090B / bone #F3EFE7 / orange #FF4D17
   type      : Bricolage Grotesque (display) / Instrument Serif
               (accent italic) / JetBrains Mono (data)
   space     : 4px base → 8 12 16 24 32 48 64 96 128 160
   radius    : 0 (sharp) except pills & the pointer ring
   motion    : cubic-bezier(.22,1,.36,1) · 220ms micro,
               700ms reveal, 1200ms cinematic
   ============================================================ */

/* ---------- tokens ---------- */
:root {
  --ink:        #08090B;
  --ink-2:      #0E1013;
  --ink-3:      #14171B;
  --bone:       #F3EFE7;
  --bone-2:     #E4DFD4;
  --orange:     #FF4D17;
  --orange-2:   #FF7A4D;
  --line:       rgba(243, 239, 231, .14);
  --line-strong:rgba(243, 239, 231, .28);

  --bg:         var(--ink);
  --bg-2:       var(--ink-2);
  --fg:         var(--bone);
  --fg-dim:     rgba(243, 239, 231, .62);
  --fg-dimmer:  rgba(243, 239, 231, .38);
  --accent:     var(--orange);

  --font-d:  "Bricolage Grotesque", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-s:  "Instrument Serif", "Songti SC", Georgia, serif;
  --font-m:  "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  --ease:    cubic-bezier(.22, 1, .36, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
  --dur:     .5s;

  --pad:     clamp(20px, 4.2vw, 72px);
  --maxw:    1560px;

  --nav-h:   84px;
}

html[data-theme="light"] {
  --bg:        #F3EFE7;
  --bg-2:      #E9E3D7;
  --fg:        #0A0B0D;
  --fg-dim:    rgba(10, 11, 13, .66);
  --fg-dimmer: rgba(10, 11, 13, .40);
  --line:      rgba(10, 11, 13, .14);
  --line-strong: rgba(10, 11, 13, .30);
  --accent:    #E23B08;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html:not(.js) .loader { display: none; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-d);
  font-size: 17px;
  line-height: 1.55;
  font-weight: 400;
  letter-spacing: -.01em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color .6s var(--ease), color .6s var(--ease);
}
html { overflow-x: clip; }
body.is-locked { overflow: hidden; }

img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 500; letter-spacing: -.035em; line-height: .98; }
::selection { background: var(--accent); color: #fff; }

.serif { font-style: normal; color: var(--accent); }
@supports (font-variation-settings: normal) { .serif { font-feature-settings: "kern" 1; } }
em.serif { font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-weight: 400; letter-spacing: -.02em; }
.mono  { font-family: var(--font-m); font-size: .72em; letter-spacing: .1em; text-transform: uppercase; }
.dim   { color: var(--fg-dim); }
.hl    { color: var(--accent); }
.mark  {
  white-space: nowrap;
  /* 一条压在基线下的粗下划线，不糊住字形 */
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% .12em;
  padding: 0 .04em .06em;
}

/* ---------- layers ---------- */
.gl {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
  opacity: .9;
  transition: opacity .8s var(--ease);
}
.gl.is-off { opacity: 0; }

.grain {
  position: fixed; inset: 0; z-index: 2; pointer-events: none;
  opacity: .16; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grainShift 6s steps(6) infinite;
}
html[data-theme="light"] .grain { opacity: .055; mix-blend-mode: multiply; }
@keyframes grainShift {
  0%,100% { transform: translate(0,0) }
  20% { transform: translate(-2%,1%) }
  40% { transform: translate(1%,-2%) }
  60% { transform: translate(-1%,-1%) }
  80% { transform: translate(2%,1%) }
}

.vignette {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 0%, transparent 40%, rgba(0,0,0,.55) 100%);
}
html[data-theme="light"] .vignette {
  background: radial-gradient(120% 90% at 50% 0%, transparent 45%, rgba(120,105,85,.14) 100%);
}

/* ---------- loader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--ink);
  display: grid; place-items: center;
  color: var(--bone);
  transition: opacity .8s var(--ease), visibility .8s;
}
.loader.is-done { opacity: 0; visibility: hidden; }
.loader__inner { width: min(440px, 76vw); }
.loader__row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 14px; }
.loader__label { font-family: var(--font-m); font-size: 11px; letter-spacing: .28em; }
.loader__pct { font-family: var(--font-m); font-size: 11px; color: var(--orange); letter-spacing: .1em; }
.loader__bar { height: 1px; background: rgba(243,239,231,.16); overflow: hidden; }
.loader__bar i { display: block; height: 100%; width: 0; background: var(--orange); }
.loader__meta {
  display: flex; justify-content: space-between; margin-top: 12px;
  font-family: var(--font-m); font-size: 9.5px; letter-spacing: .2em;
  color: rgba(243,239,231,.4);
}

/* ---------- cursor ---------- */
.cursor, .cursor-dot { position: fixed; top: 0; left: 0; z-index: 900; pointer-events: none; }
.cursor {
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  display: grid; place-items: center;
  transition: width .34s var(--ease), height .34s var(--ease),
              margin .34s var(--ease), background-color .3s, border-color .3s;
  backdrop-filter: invert(6%);
}
.cursor__label {
  font-family: var(--font-m); font-size: 9px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--bg);
  opacity: 0; transform: scale(.7); transition: opacity .2s, transform .3s var(--ease);
  white-space: nowrap;
}
.cursor-dot {
  width: 4px; height: 4px; margin: -2px 0 0 -2px;
  background: var(--accent); border-radius: 50%;
  transition: transform .2s, opacity .3s;
}
.cursor.is-view {
  width: 84px; height: 84px; margin: -42px 0 0 -42px;
  background: var(--accent); border-color: var(--accent);
}
.cursor.is-view .cursor__label { opacity: 1; transform: scale(1); color: #fff; }
.cursor.is-link { width: 56px; height: 56px; margin: -28px 0 0 -28px; border-color: var(--accent); }
.cursor.is-link .cursor-dot { transform: scale(0); }
.cursor.is-down { width: 26px; height: 26px; margin: -13px 0 0 -13px; }
@media (hover: none), (pointer: coarse) {
  .cursor, .cursor-dot { display: none; }
}

/* ---------- progress ---------- */
.progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 800; }
.progress i {
  display: block; height: 100%; width: 0;
  background: var(--accent);
  transform-origin: left;
}

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 600;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--pad);
  transition: transform .5s var(--ease), background-color .4s, backdrop-filter .4s, border-color .4s;
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  background: color-mix(in oklab, var(--bg) 78%, transparent);
  backdrop-filter: blur(18px) saturate(130%);
  border-bottom-color: var(--line);
}
.nav.is-hidden { transform: translateY(-101%); }

.brand { display: flex; align-items: center; gap: 11px; }
.brand__mark { width: 26px; height: 26px; color: var(--fg); }
.brand__mark svg { width: 100%; height: 100%; fill: currentColor; }
.brand__mark .brand__cut { fill: var(--accent); }
.brand__text {
  font-size: 15px; font-weight: 600; letter-spacing: .02em;
  display: flex; align-items: flex-start; gap: 2px;
}
.brand__text em { font-style: normal; font-size: 8px; opacity: .6; margin-top: 2px; }

.nav__links { display: flex; gap: 34px; }
.nav__links a {
  position: relative; display: block;
  height: 20px; overflow: hidden;
  font-size: 13.5px; letter-spacing: .02em;
}
.nav__links a span,
.nav__links a i {
  display: block; transition: transform .42s var(--ease);
  font-style: normal;
}
.nav__links a i {
  font-family: var(--font-m); font-size: 10.5px; letter-spacing: .12em;
  color: var(--accent); padding-top: 2px;
}
.nav__links a:hover span,
.nav__links a:focus-visible span { transform: translateY(-22px); }
.nav__links a:hover i,
.nav__links a:focus-visible i { transform: translateY(-20px); }

.nav__side { display: flex; align-items: center; gap: 6px; }
.nav__clock {
  font-family: var(--font-m); font-size: 11px; letter-spacing: .1em;
  color: var(--fg-dim); margin-right: 12px;
  font-variant-numeric: tabular-nums;
}
.iconbtn {
  width: 38px; height: 38px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 50%;
  transition: border-color .3s, background-color .3s, transform .3s var(--ease);
}
.iconbtn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; }
.iconbtn:hover { border-color: var(--fg); background: color-mix(in oklab, var(--fg) 8%, transparent); }
.iconbtn:active { transform: scale(.93); }
.iconbtn .i-sun { display: none; }
html[data-theme="light"] .iconbtn .i-sun { display: block; }
html[data-theme="light"] .iconbtn .i-moon { display: none; }
.iconbtn--k { display: none; }
@media (min-width: 900px) { .iconbtn--k { display: grid; } }

.burger { display: none; width: 38px; height: 38px; position: relative; }
.burger span {
  position: absolute; left: 9px; width: 20px; height: 1.5px;
  background: var(--fg); transition: transform .4s var(--ease), opacity .3s;
}
.burger span:first-child { top: 16px; }
.burger span:last-child { top: 22px; }
.burger.is-on span:first-child { transform: translateY(3px) rotate(45deg); }
.burger.is-on span:last-child { transform: translateY(-3px) rotate(-45deg); }

@media (max-width: 1023px) {
  .nav__links, .nav__clock { display: none; }
  .burger { display: block; }
}

/* ---------- mobile menu ---------- */
.menu {
  position: fixed; inset: 0; z-index: 550;
  display: none; flex-direction: column; justify-content: center;
  padding: calc(var(--nav-h) + 20px) var(--pad) 40px;
  clip-path: circle(0% at calc(100% - 40px) 42px);
  transition: clip-path .7s var(--ease-io);
}
.menu.is-open { clip-path: circle(150% at calc(100% - 40px) 42px); }
.menu__bg {
  position: absolute; inset: 0; z-index: -1;
  background: var(--bg-2);
  border-bottom: 1px solid var(--line);
}
.menu__list { display: flex; flex-direction: column; }
.menu__list a {
  display: flex; align-items: baseline; gap: 14px;
  padding: 14px 0; border-bottom: 1px solid var(--line);
  font-size: clamp(28px, 8vw, 44px); font-weight: 500; letter-spacing: -.03em;
  opacity: 0; transform: translateY(18px);
  transition: opacity .5s var(--ease), transform .5s var(--ease), color .3s;
}
.menu.is-open .menu__list a { opacity: 1; transform: none; }
.menu.is-open .menu__list a:nth-child(1) { transition-delay: .12s; }
.menu.is-open .menu__list a:nth-child(2) { transition-delay: .17s; }
.menu.is-open .menu__list a:nth-child(3) { transition-delay: .22s; }
.menu.is-open .menu__list a:nth-child(4) { transition-delay: .27s; }
.menu.is-open .menu__list a:nth-child(5) { transition-delay: .32s; }
.menu__list a:hover { color: var(--accent); }
.menu__idx { font-family: var(--font-m); font-size: 11px; color: var(--accent); letter-spacing: .1em; }
.menu__list a i { font-style: normal; font-family: var(--font-m); font-size: 10px; letter-spacing: .16em; color: var(--fg-dimmer); margin-left: auto; }
.menu__foot {
  margin-top: auto; padding-top: 32px;
  display: flex; flex-direction: column; gap: 6px;
  font-family: var(--font-m); font-size: 11px; letter-spacing: .08em; color: var(--fg-dim);
}

/* ---------- shared section ---------- */
main { position: relative; z-index: 3; }
.section {
  position: relative;
  padding: clamp(72px, 9vw, 148px) var(--pad);
  max-width: var(--maxw); margin: 0 auto;
}
.section__label {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-m); font-size: 10.5px; letter-spacing: .2em;
  text-transform: uppercase; margin-bottom: 34px;
}
.section__label::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}
.section__label .dim { color: var(--accent); }
.section__head { max-width: 760px; margin-bottom: clamp(40px, 5vw, 68px); }
.section__head--row {
  max-width: none; display: flex; justify-content: space-between;
  align-items: flex-end; gap: 48px; flex-wrap: wrap;
}
.section__title {
  font-size: clamp(34px, 5.4vw, 72px);
  letter-spacing: -.04em; line-height: 1.06;
}
.section__title .serif { color: var(--accent); }
.section__note {
  margin-top: 22px; max-width: 46ch;
  color: var(--fg-dim); font-size: 15px; line-height: 1.65;
  text-wrap: pretty;
}
.section__note--right { margin: 0 0 6px; max-width: 34ch; flex: 0 1 340px; }

/* reveal */
[data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
  transition-delay: calc(var(--d, 0) * 90ms);
}
[data-reveal].is-in { opacity: 1; transform: none; }
[data-reveal][data-delay="1"] { --d: 1 }
[data-reveal][data-delay="2"] { --d: 2 }
[data-reveal][data-delay="3"] { --d: 3 }

/* 字符拆分 */
.split-line { display: block; overflow: hidden; }
.split-word { display: inline-block; white-space: nowrap; }
.split-char {
  display: inline-block;
  will-change: transform, opacity;
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  padding: calc(var(--nav-h) + clamp(30px, 6vh, 80px)) var(--pad) 28px;
  max-width: var(--maxw); margin: 0 auto;
  display: flex; flex-direction: column;
}
.hero__split {
  display: grid; grid-template-columns: 1.55fr .85fr;
  gap: clamp(24px, 4vw, 72px); align-items: end;
  flex: 1;
}
.hero__left { padding-bottom: 12px; }

.eyebrow {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-m); font-size: 10px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--fg-dim);
  margin-bottom: clamp(14px, 2.2vh, 26px);
}
.eyebrow__sep { opacity: .4 }
.pulse {
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
  position: relative; flex: none;
}
.pulse::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 1px solid var(--accent);
  animation: pulseRing 2.6s var(--ease) infinite;
}
.pulse--sm::after { animation-duration: 2s }
@keyframes pulseRing {
  0%   { transform: scale(.6); opacity: .9 }
  70%  { transform: scale(1.9); opacity: 0 }
  100% { opacity: 0 }
}

.hero__title {
  font-size: clamp(44px, min(9.2vw, 13.4vh), 140px);
  line-height: .86;
  letter-spacing: -.045em;
  font-weight: 500;
  margin-bottom: clamp(16px, 2.4vh, 32px);
}
.hero__title .line { display: block; overflow: hidden; }
.hero__title .line__in { display: block; will-change: transform; }
.hero__title em {
  color: var(--accent);
  font-size: 1.04em;
  padding-right: .06em;
}
.caret {
  display: inline-block; width: .46em; height: .09em;
  background: var(--accent); vertical-align: .12em; margin-left: .1em;
  animation: blink 1.4s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0 } }

.hero__sub {
  max-width: 40ch; color: var(--fg-dim);
  font-size: clamp(15px, 1.28vw, 18px); line-height: 1.62;
  text-wrap: pretty;
}
.hero__actions { display: flex; gap: 12px; margin-top: clamp(18px, 2.4vh, 30px); flex-wrap: wrap; }

/* buttons */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 26px;
  border-radius: 100px; overflow: hidden;
  font-size: 14.5px; font-weight: 500; letter-spacing: .01em;
  border: 1px solid var(--line-strong);
  transition: color .4s var(--ease), border-color .4s;
  isolation: isolate;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--fg);
  transform: translateY(101%);
  transition: transform .5s var(--ease);
}
.btn:hover::before { transform: translateY(0); }
.btn--solid { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn--solid::before { background: var(--fg); }
.btn--solid:hover { color: var(--bg); border-color: var(--fg); }
.btn--ghost { background: transparent; color: var(--fg); }
.btn--ghost:hover { color: var(--bg); }
.btn__arrow { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }
.btn__dot { width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }

/* hero right */
.hero__right { padding-bottom: 12px; }
.card-stack { display: flex; flex-direction: column; gap: 14px; }
.now-card {
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--bg-2) 82%, transparent);
  backdrop-filter: blur(12px);
  padding: 18px 20px 16px;
  transform-style: preserve-3d;
  transition: border-color .4s, transform .1s linear;
}
.now-card:hover { border-color: var(--line-strong); }
.now-card__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.now-list { display: flex; flex-direction: column; gap: 9px; }
.now-list li { display: flex; align-items: flex-start; gap: 9px; font-size: 13.5px; line-height: 1.45; color: var(--fg); }
.now-list i { font-style: normal; color: var(--accent); }
.now-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--accent); flex: none; margin-top: 7px; }
.now-dot--idle { background: var(--fg-dimmer); }
.now-card__foot {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line);
}
.now-card__foot .mono:last-child { font-size: 13px; color: var(--accent); font-variant-numeric: tabular-nums; }

.stat-strip {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
}
.stat {
  padding: 14px 12px;
  display: flex; flex-direction: column; gap: 3px;
  border-right: 1px solid var(--line);
}
.stat:last-child { border-right: 0; }
.stat b {
  font-size: clamp(20px, 2.1vw, 27px); font-weight: 500;
  letter-spacing: -.03em; font-variant-numeric: tabular-nums;
}
.stat span { color: var(--fg-dimmer); font-size: 9px; letter-spacing: .14em; }

.hero__foot {
  display: flex; justify-content: space-between; align-items: flex-end;
  padding-top: clamp(14px, 2vh, 24px); margin-top: auto;
}
.scrollcue { display: flex; align-items: center; gap: 12px; color: var(--fg-dim); font-size: 9.5px; letter-spacing: .18em; }
.scrollcue__line { display: block; width: 44px; height: 1px; background: var(--line-strong); position: relative; overflow: hidden; }
.scrollcue__line i { position: absolute; inset: 0; background: var(--accent); transform: translateX(-100%); animation: cueSlide 2.4s var(--ease) infinite; }
@keyframes cueSlide { 0% { transform: translateX(-100%) } 55%,100% { transform: translateX(100%) } }
.hero__coords { display: flex; gap: 10px; font-size: 9.5px; letter-spacing: .14em; }
.hero__coords-sep { opacity: .35 }

@media (max-width: 900px) {
  .hero { min-height: auto; padding-bottom: 18px; }
  .hero__split { grid-template-columns: 1fr; align-items: start; gap: 0; flex: 0 0 auto; }
  .hero__right { display: none; }
  .hero__title { font-size: clamp(42px, 12.2vw, 82px); margin-bottom: 22px; }
  .hero__sub { max-width: 34ch; }
  .hero__foot { padding-top: 34px; }
  .hero__coords { display: none; }
  .scrollcue { margin-left: 0; }
}

@media (max-width: 620px) {
  .hero__actions { gap: 10px; }
  .btn { height: 48px; padding: 0 18px; font-size: 13.5px; }
  .btn svg { width: 15px; height: 15px; }
}

/* ---------- marquee ---------- */
.marquee {
  position: relative; z-index: 3;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden; padding: 15px 0;
  background: color-mix(in oklab, var(--bg-2) 60%, transparent);
}
.marquee__track {
  display: flex; align-items: center; gap: 26px;
  width: max-content;
  animation: marq 38s linear infinite;
  will-change: transform;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__track span {
  font-size: clamp(15px, 1.7vw, 21px); font-weight: 500;
  letter-spacing: -.02em; white-space: nowrap;
  text-transform: uppercase;
}
.marquee__track i { color: var(--accent); font-style: normal; font-size: 11px; }
@keyframes marq { to { transform: translateX(-50%) } }
body.motion-off .marquee__track { animation: none; }

/* ---------- work / cases ---------- */
.cases {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(16px, 2.2vw, 34px);
}
.case {
  position: relative;
  display: flex; flex-direction: column;
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--bg-2) 55%, transparent);
  overflow: hidden;
  transition: border-color .5s var(--ease), transform .6s var(--ease);
}
.case:hover { border-color: var(--line-strong); }
.case__visual {
  position: relative; overflow: hidden;
  aspect-ratio: 4 / 3;
  display: grid; place-items: center;
}
.case__art {
  position: absolute; inset: 0;
  transition: transform .8s var(--ease), filter .6s;
}
.case:hover .case__art { transform: scale(1.045); }
.case__tag, .case__num {
  position: absolute; z-index: 2; top: 16px;
  font-size: 9px; letter-spacing: .18em;
  color: rgba(255,255,255,.86);
  background: rgba(10,11,13,.72);
  border: 1px solid rgba(255,255,255,.22);
  padding: 5px 9px; backdrop-filter: blur(10px) saturate(1.1);
}
.case__tag { left: 16px; }
.case__num { right: 16px; }

/* 6 张演示图形 —— 全部纯 CSS，没有图片依赖 */
/* 频谱：一排竖条，高度像音频，长短交错 —— 不做渐变糊脸 */
.art-1 {
  background: #0a0b0e;
  display: flex; align-items: flex-end; justify-content: center;
  gap: 4px; padding: 14% 9% 18%;
}
.art-1::before {
  content: ""; flex: 1 1 auto; height: 100%;
  background: repeating-linear-gradient(90deg,
      rgba(255,77,23,.92) 0 3px,
      transparent 3px 7px);
  clip-path: polygon(
    0 62%, 3% 48%, 6% 70%, 9% 34%, 12% 58%, 15% 22%, 18% 74%,
    21% 44%, 24% 66%, 27% 30%, 30% 52%, 33% 12%, 36% 68%, 39% 40%,
    42% 80%, 45% 28%, 48% 60%, 51% 18%, 54% 72%, 57% 46%, 60% 86%,
    63% 32%, 66% 58%, 69% 20%, 72% 66%, 75% 42%, 78% 76%, 81% 26%,
    84% 54%, 87% 36%, 90% 70%, 93% 48%, 96% 58%, 100% 44%,
    100% 100%, 0 100%);
  animation: specPulse 4.2s var(--ease) infinite;
}
.art-1::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(10,11,14,.85) 0%, transparent 26%),
    radial-gradient(70% 50% at 50% 100%, rgba(255,77,23,.20), transparent 70%);
  pointer-events: none;
}
@keyframes specPulse {
  0%, 100% { transform: scaleY(.92) }
  50% { transform: scaleY(1.06) }
}

.art-2 {
  background: linear-gradient(160deg, #efe9dc, #ded4c2 60%, #cdbfa8);
}
.art-2::before {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, transparent 49.6%, rgba(20,15,10,.28) 49.6% 50.4%, transparent 50.4%),
    repeating-linear-gradient(0deg, rgba(20,15,10,.10) 0 1px, transparent 1px 26px);
  mask-image: linear-gradient(180deg, transparent, #000 18% 82%, transparent);
}
.art-2::after {
  content: ""; position: absolute; width: 42%; aspect-ratio: 1;
  border-radius: 50%; left: 50%; top: 50%; translate: -50% -50%;
  border: 1px solid rgba(20,15,10,.35);
  box-shadow: 0 0 0 14px rgba(20,15,10,.05), 0 0 0 40px rgba(20,15,10,.04);
  animation: breathe 7s var(--ease) infinite;
}
@keyframes breathe { 50% { scale: 1.18; opacity: .6 } }

.art-3 {
  background:
    radial-gradient(circle at 50% 50%, #12161d 0%, #080a0e 70%),
    #080a0e;
}
.art-3::before, .art-3::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  border-radius: 50%; border: 1px solid rgba(120,170,255,.34);
  translate: -50% -50%;
  animation: orbit 16s linear infinite;
}
.art-3::before { width: 46%; aspect-ratio: 1; }
.art-3::after { width: 78%; aspect-ratio: 1; border-color: rgba(255,77,23,.3); animation-duration: 26s; animation-direction: reverse; }
@keyframes orbit { to { rotate: 360deg } }

.art-4 {
  background: linear-gradient(140deg, #241a2e, #3d2233 45%, #1a1016);
}
.art-4::before {
  content: ""; position: absolute; inset: 12% 22%;
  background: linear-gradient(120deg, #f6f1e6, #d8cfc0);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  transform: perspective(600px) rotateY(-24deg) rotateX(6deg);
  box-shadow: 24px 24px 60px rgba(0,0,0,.55);
  transition: transform 1s var(--ease);
}
.case:hover .art-4::before { transform: perspective(600px) rotateY(-8deg) rotateX(2deg); }
.art-4::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(60% 60% at 75% 20%, rgba(255,77,23,.35), transparent 70%);
}

.art-5 {
  background: #0a0d12;
}
.art-5::before {
  content: ""; position: absolute; inset: 0;
  background:
    repeating-linear-gradient(0deg, rgba(80,200,160,.16) 0 1px, transparent 1px 18px),
    repeating-linear-gradient(90deg, rgba(80,200,160,.10) 0 1px, transparent 1px 18px);
}
.art-5::after {
  content: ""; position: absolute; left: 8%; right: 8%; bottom: 24%; height: 46%;
  background: linear-gradient(90deg, transparent, rgba(80,230,180,.55), transparent);
  clip-path: polygon(0 72%, 8% 40%, 16% 58%, 24% 22%, 32% 66%, 40% 34%, 48% 78%, 56% 46%, 64% 62%, 72% 18%, 80% 54%, 88% 30%, 100% 70%, 100% 100%, 0 100%);
  animation: signalPulse 3.6s var(--ease) infinite;
}
@keyframes signalPulse { 50% { opacity: .55 } }

/* 图集：不齐整的照片墙 —— 高低错落，密度不同 */
.art-6 {
  background: #12100d;
}
/* 照片墙用内联 SVG 画：百分比背景定位会把图层往中间压，矩形位置必须精确 */
.art-6::before {
  content: ""; position: absolute; inset: 7% 7%;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns=%27http://www.w3.org/2000/svg%27%20viewBox=%270%200%20400%20300%27%20preserveAspectRatio=%27none%27%3E%3Cdefs%3E%3ClinearGradient%20id=%27a%27%20x1=%270%27%20y1=%270%27%20x2=%27.7%27%20y2=%271%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%239c8a68%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%23564a3a%27/%3E%3C/linearGradient%3E%3ClinearGradient%20id=%27b%27%20x1=%270%27%20y1=%271%27%20x2=%27.6%27%20y2=%270%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%233c3329%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%236d5c47%27/%3E%3C/linearGradient%3E%3ClinearGradient%20id=%27c%27%20x1=%270%27%20y1=%270%27%20x2=%271%27%20y2=%27.8%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%23b8a37e%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%236d5f4c%27/%3E%3C/linearGradient%3E%3ClinearGradient%20id=%27d%27%20x1=%27.2%27%20y1=%270%27%20x2=%27.8%27%20y2=%271%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%234a4034%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%232b241c%27/%3E%3C/linearGradient%3E%3ClinearGradient%20id=%27e%27%20x1=%270%27%20y1=%270%27%20x2=%271%27%20y2=%271%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%238a7658%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%23463b2d%27/%3E%3C/linearGradient%3E%3ClinearGradient%20id=%27f%27%20x1=%270%27%20y1=%27.1%27%20x2=%27.9%27%20y2=%271%27%3E%3Cstop%20offset=%270%27%20stop-color=%27%2375634b%27/%3E%3Cstop%20offset=%271%27%20stop-color=%27%233a3126%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect%20x=%270%27%20y=%270%27%20width=%27116%27%20height=%27148%27%20fill=%27url(%23a)%27/%3E%3Crect%20x=%27122%27%20y=%270%27%20width=%27110%27%20height=%27210%27%20fill=%27url(%23b)%27/%3E%3Crect%20x=%27238%27%20y=%270%27%20width=%27162%27%20height=%27112%27%20fill=%27url(%23c)%27/%3E%3Crect%20x=%270%27%20y=%27154%27%20width=%27116%27%20height=%27146%27%20fill=%27url(%23d)%27/%3E%3Crect%20x=%27122%27%20y=%27216%27%20width=%27110%27%20height=%2784%27%20fill=%27url(%23e)%27/%3E%3Crect%20x=%27238%27%20y=%27118%27%20width=%27162%27%20height=%27182%27%20fill=%27url(%23f)%27/%3E%3C/svg%3E");
  background-size: 100% 100%;
  background-repeat: no-repeat;
  transition: transform .9s var(--ease);
}
.case:hover .art-6::before { transform: scale(1.035); }
.art-6::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, transparent 78%, rgba(0,0,0,.34)),
    radial-gradient(60% 45% at 30% 12%, rgba(255,77,23,.10), transparent 70%);
}
.case__info { padding: 20px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.case__line { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; }
.case__title { font-size: clamp(18px, 1.9vw, 24px); letter-spacing: -.03em; line-height: 1.1; }
.case__title em { color: var(--accent); font-size: .92em; }
.case__year { color: var(--fg-dimmer); font-size: 9.5px; }
.case__desc { color: var(--fg-dim); font-size: 13.5px; line-height: 1.6; text-wrap: pretty; }
.case__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 12px; }
.case__tags li {
  font-family: var(--font-m); font-size: 9px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--fg-dim); border: 1px solid var(--line);
  padding: 4px 8px; border-radius: 100px;
}
.case__go {
  position: absolute; right: 16px; bottom: 16px;
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 50%; background: var(--accent);
  transform: scale(0) rotate(-30deg);
  transition: transform .5s var(--ease);
  z-index: 3;
}
.case__go svg { width: 16px; height: 16px; fill: none; stroke: #fff; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.case:hover .case__go { transform: scale(1) rotate(0); }
.case__info { padding-right: 64px; }

@media (max-width: 760px) {
  .cases { grid-template-columns: 1fr; }
}

.work__foot { margin-top: clamp(30px, 4vw, 52px); }
.link-arrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: clamp(17px, 1.8vw, 23px); letter-spacing: -.02em;
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
  transition: border-color .4s, gap .4s var(--ease);
}
.link-arrow span { color: var(--accent); }
.link-arrow svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.link-arrow:hover { gap: 20px; border-color: var(--fg); }

/* ---------- about ---------- */
.about__grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: clamp(32px, 5vw, 90px); }
.about__title { font-size: clamp(28px, 4.2vw, 56px); line-height: 1.06; letter-spacing: -.04em; }
.about__title .serif { color: var(--accent); }
.mark::after { content: none; }
.about__body { margin-top: clamp(26px, 3vw, 40px); display: flex; flex-direction: column; gap: 18px; max-width: 52ch; }
.about__body p { color: var(--fg-dim); font-size: 15.5px; line-height: 1.72; text-wrap: pretty; }
.about__body .hl { color: var(--fg); border-bottom: 1px solid var(--accent); }

.about__side { display: flex; flex-direction: column; gap: 26px; }
.factlist { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.fact {
  display: grid; grid-template-columns: 96px 1fr; gap: 16px;
  padding: 14px 0; border-bottom: 1px solid var(--line);
  font-size: 13px; line-height: 1.55;
}
.fact p { color: var(--fg); }
.fact__links { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.fact__links a { border-bottom: 1px solid var(--line-strong); transition: color .3s, border-color .3s; }
.fact__links a:hover { color: var(--accent); border-color: var(--accent); }

.portrait { margin: 0; }
.portrait__ph {
  position: relative; aspect-ratio: 4 / 5;
  border: 1px dashed var(--line-strong);
  display: grid; place-content: center; text-align: center; gap: 8px;
  background:
    repeating-linear-gradient(45deg, transparent 0 12px, color-mix(in oklab, var(--fg) 3%, transparent) 12px 24px);
  transition: border-color .4s;
}
a.portrait__ph:hover, .portrait:hover .portrait__ph { border-color: var(--accent); }
.portrait__ph-label { color: var(--fg-dim); font-size: 10px; letter-spacing: .14em; }
.portrait__ph-note { font-size: 11.5px; color: var(--fg-dimmer); max-width: 20ch; margin: 0 auto; line-height: 1.5; }
.portrait figcaption { margin-top: 10px; font-size: 9px; letter-spacing: .16em; color: var(--fg-dimmer); }

@media (max-width: 900px) {
  .about__grid { grid-template-columns: 1fr; }
  .portrait { max-width: 300px; }
}

/* ---------- services ---------- */
.svc-list { border-top: 1px solid var(--line-strong); }
.svc {
  display: grid;
  grid-template-columns: 48px minmax(140px, 1.1fr) 2fr auto;
  gap: clamp(14px, 3vw, 40px);
  align-items: baseline;
  padding: clamp(20px, 2.6vw, 34px) 0;
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 0;
  transition: padding-left .5s var(--ease);
}
.svc::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: color-mix(in oklab, var(--fg) 5%, transparent);
  transform: scaleY(0); transform-origin: bottom;
  transition: transform .5s var(--ease);
}
.svc:hover::before { transform: scaleY(1); }
.svc:hover { padding-left: 12px; }
.svc__idx { font-size: 10px; color: var(--accent); letter-spacing: .12em; }
.svc__title { font-size: clamp(20px, 2.4vw, 30px); letter-spacing: -.03em; }
.svc__desc { color: var(--fg-dim); font-size: 13.8px; line-height: 1.62; max-width: 54ch; text-wrap: pretty; }
.svc__meta { display: flex; flex-direction: column; gap: 4px; text-align: right; color: var(--fg-dimmer); font-size: 9px; letter-spacing: .12em; white-space: nowrap; }

.svc-cta {
  margin-top: clamp(34px, 4vw, 56px);
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
  padding: clamp(22px, 3vw, 34px);
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--bg-2) 60%, transparent);
}
.svc-cta p { font-size: clamp(16px, 1.7vw, 21px); letter-spacing: -.02em; }

@media (max-width: 860px) {
  .svc { grid-template-columns: 32px 1fr; row-gap: 8px; }
  .svc__desc { grid-column: 2; }
  .svc__meta { grid-column: 2; flex-direction: row; gap: 16px; text-align: left; margin-top: 4px; }
}

/* ---------- lab ---------- */
.lab-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(14px, 1.8vw, 24px); }
.lab-card {
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--bg-2) 55%, transparent);
  display: flex; flex-direction: column;
  transition: border-color .4s;
}
.lab-card:hover { border-color: var(--line-strong); }
.lab-card__head {
  display: flex; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px solid var(--line);
  font-size: 9px; letter-spacing: .16em;
}
.lab-card__stage {
  position: relative; height: clamp(250px, 23vw, 360px); overflow: hidden;
  touch-action: pan-y;
}
.lab-card__stage canvas { width: 100%; height: 100%; }
.lab-card__hint {
  position: absolute; left: 12px; bottom: 10px;
  font-size: 8.5px; letter-spacing: .12em; color: var(--fg-dimmer);
  pointer-events: none;
}
.lab-card__foot { padding: 14px; border-top: 1px solid var(--line); margin-top: auto; }
.lab-card__foot h3 { font-size: 15px; letter-spacing: -.01em; margin-bottom: 5px; }
.lab-card__foot p { font-size: 12.5px; color: var(--fg-dim); line-height: 1.55; text-wrap: pretty; }

.lab-card__stage--type, .lab-card__stage--drag { display: grid; place-items: center; }
.scramble {
  font-family: var(--font-m); font-weight: 500;
  font-size: clamp(13px, 1.35vw, 17px); letter-spacing: .14em;
  user-select: none;
}
.lab-card__stage--drag { overflow: hidden; }
.drag-row {
  display: flex; gap: 8px; padding: 0 14px;
  cursor: grab; will-change: transform;
}
.drag-row:active { cursor: grabbing; }
.chip {
  flex: none;
  font-size: 13px; padding: 7px 14px;
  border: 1px solid var(--line-strong); border-radius: 100px;
  white-space: nowrap; user-select: none;
  transition: border-color .3s, color .3s, background-color .3s;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }

.lab-note { margin-top: 22px; font-size: 9.5px; letter-spacing: .14em; }

@media (max-width: 900px) { .lab-grid { grid-template-columns: 1fr; } }

/* ---------- process ---------- */
.proc { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.proc__item {
  background: var(--bg); padding: clamp(18px, 2.4vw, 28px);
  display: flex; flex-direction: column; gap: 9px;
  position: relative; overflow: hidden;
  transition: background-color .5s;
}
.proc__item:hover { background: color-mix(in oklab, var(--fg) 5%, var(--bg)); }
.proc__n { font-size: 10px; color: var(--accent); letter-spacing: .16em; }
.proc__item h3 { font-size: clamp(19px, 2vw, 25px); }
.proc__item p { font-size: 13px; color: var(--fg-dim); line-height: 1.6; text-wrap: pretty; }
.proc__bar { position: relative; margin-top: auto; padding-top: 18px; display: block; }
.proc__bar::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line); }
.proc__bar i { position: absolute; left: 0; bottom: 0; height: 1px; width: 0; background: var(--accent); transition: width 1.3s var(--ease) .2s; }
.proc__item.is-in .proc__bar i { width: var(--w); }

@media (max-width: 860px) { .proc { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .proc { grid-template-columns: 1fr; } }

/* ---------- contact ---------- */
.contact {
  position: relative; z-index: 3;
  padding: clamp(84px, 10vw, 168px) var(--pad);
  border-top: 1px solid var(--line);
  background:
    radial-gradient(70% 100% at 50% 100%, color-mix(in oklab, var(--accent) 9%, transparent), transparent 70%);
}
.contact__inner { max-width: var(--maxw); margin: 0 auto; }
.contact__title {
  font-size: clamp(44px, 9.4vw, 138px);
  line-height: 1.02; letter-spacing: -.04em;
  margin: clamp(16px, 2vw, 26px) 0 clamp(22px, 3vw, 34px);
}
.contact__title .line { display: block; overflow: hidden; padding-bottom: .04em; }
.contact__title .line__in { display: block; }
.contact__title .serif { color: var(--accent); }
.contact__sub { max-width: 38ch; color: var(--fg-dim); font-size: 15.5px; line-height: 1.66; text-wrap: pretty; }

.contact__mail {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  margin: clamp(30px, 4vw, 52px) 0 clamp(34px, 4vw, 60px);
  padding-bottom: 18px; border-bottom: 1px solid var(--line-strong);
}
.mailto {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: clamp(21px, 3.6vw, 44px); letter-spacing: -.03em;
  position: relative;
}
.mailto__text { position: relative; }
.mailto__text::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .04em; height: .06em;
  background: var(--accent);
  transform: scaleX(0); transform-origin: right;
  transition: transform .55s var(--ease);
}
.mailto:hover .mailto__text::after { transform: scaleX(1); transform-origin: left; }
.mailto svg { width: .5em; height: .5em; fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease); }
.mailto:hover svg { transform: translate(3px, -3px); }
.copybtn {
  display: inline-flex; align-items: center; gap: 7px;
  height: 38px; padding: 0 14px; border-radius: 100px;
  border: 1px solid var(--line-strong);
  font-family: var(--font-m); font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--fg-dim); transition: color .3s, border-color .3s, background-color .3s;
}
.copybtn:hover { color: var(--fg); border-color: var(--fg); }
.copybtn svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.copybtn .i-check { display: none; }
.copybtn.is-ok { color: var(--accent); border-color: var(--accent); }
.copybtn.is-ok .i-copy { display: none; }
.copybtn.is-ok .i-check { display: block; }

.contact__meta {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px;
  max-width: 640px;
}
.contact__meta > div { display: flex; flex-direction: column; gap: 5px; }
.contact__meta p { font-size: 13px; color: var(--fg); }
.contact__meta a { border-bottom: 1px solid var(--line-strong); transition: color .3s, border-color .3s; }
.contact__meta a:hover { color: var(--accent); border-color: var(--accent); }
@media (max-width: 620px) { .contact__meta { grid-template-columns: 1fr 1fr; gap: 18px; } }

/* ---------- footer ---------- */
.foot {
  position: relative; z-index: 3;
  padding: 26px var(--pad) 0;
  border-top: 1px solid var(--line);
  overflow: hidden;
}
.foot__top { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 9.5px; letter-spacing: .14em; }
.foot__top-link { color: var(--fg-dim); transition: color .3s; }
.foot__top-link:hover { color: var(--accent); }
.foot__big {
  font-size: clamp(64px, 19vw, 300px);
  line-height: .78; font-weight: 600; letter-spacing: -.06em;
  color: transparent;
  -webkit-text-stroke: 1px var(--line-strong);
  margin-top: 18px; margin-bottom: -2vw;
  text-align: center; user-select: none;
}

/* ---------- command palette ---------- */
.cmdk {
  position: fixed; inset: 0; z-index: 950;
  display: none; align-items: flex-start; justify-content: center;
  padding-top: min(18vh, 160px);
}
.cmdk.is-open { display: flex; }
.cmdk__backdrop { position: absolute; inset: 0; background: rgba(4,5,7,.62); backdrop-filter: blur(6px); animation: fade .3s var(--ease); }
@keyframes fade { from { opacity: 0 } }
.cmdk__panel {
  position: relative; width: min(560px, 92vw);
  background: var(--bg-2); border: 1px solid var(--line-strong);
  box-shadow: 0 30px 80px rgba(0,0,0,.5);
  animation: cmdkIn .38s var(--ease);
  overflow: hidden;
}
@keyframes cmdkIn { from { opacity: 0; transform: translateY(-14px) scale(.985) } }
.cmdk__inputRow { display: flex; align-items: center; gap: 10px; padding: 15px 16px; border-bottom: 1px solid var(--line); }
.cmdk__ico { width: 16px; height: 16px; fill: none; stroke: var(--fg-dimmer); stroke-width: 1.6; }
.cmdk__inputRow input {
  flex: 1; background: none; border: 0; outline: 0;
  color: var(--fg); font-size: 15px; font-family: var(--font-d);
}
.cmdk__inputRow input::placeholder { color: var(--fg-dimmer); }
.cmdk__inputRow kbd {
  font-family: var(--font-m); font-size: 9px; letter-spacing: .1em;
  border: 1px solid var(--line); padding: 3px 6px; color: var(--fg-dimmer);
}
.cmdk__list { max-height: 44vh; overflow-y: auto; padding: 6px; }
.cmdk__list li {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px; font-size: 14px; cursor: pointer;
  border-radius: 2px; color: var(--fg-dim);
  transition: background-color .16s, color .16s;
}
.cmdk__list li .mono { color: var(--fg-dimmer); margin-left: auto; font-size: 8.5px; }
.cmdk__list li.is-active { background: color-mix(in oklab, var(--accent) 16%, transparent); color: var(--fg); }
.cmdk__list li.is-active .mono { color: var(--accent); }
.cmdk__foot { display: flex; gap: 16px; padding: 9px 16px; border-top: 1px solid var(--line); font-size: 8.5px; letter-spacing: .1em; }
.cmdk__empty { padding: 22px 12px; text-align: center; color: var(--fg-dimmer); font-size: 13px; }

/* ---------- tweaks ---------- */
.tweaks { position: fixed; right: 18px; bottom: 18px; z-index: 700; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.tweaks__toggle {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--bg-2); border: 1px solid var(--line-strong);
  box-shadow: 0 8px 26px rgba(0,0,0,.28);
  transition: transform .4s var(--ease), border-color .3s;
}
.tweaks__toggle:hover { border-color: var(--accent); }
.tweaks__toggle svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; }
.tweaks.is-open .tweaks__toggle { transform: rotate(90deg); }
.tweaks__panel {
  width: 232px; padding: 14px;
  background: var(--bg-2); border: 1px solid var(--line-strong);
  box-shadow: 0 18px 50px rgba(0,0,0,.4);
  display: none; flex-direction: column; gap: 12px;
}
.tweaks.is-open .tweaks__panel { display: flex; animation: cmdkIn .3s var(--ease); }
.tweaks__row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tweaks__row .mono { font-size: 9px; letter-spacing: .14em; color: var(--fg-dim); }
.seg { display: flex; border: 1px solid var(--line); }
.seg button {
  padding: 4px 10px; font-family: var(--font-m); font-size: 9px;
  letter-spacing: .1em; color: var(--fg-dim);
  border-right: 1px solid var(--line);
  transition: background-color .25s, color .25s;
}
.seg button:last-child { border-right: 0; }
.seg button.is-on { background: var(--accent); color: #fff; }
.tweaks__hint { font-size: 8px; letter-spacing: .1em; opacity: .6; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; translate: -50% 0;
  z-index: 980; padding: 10px 18px;
  background: var(--fg); color: var(--bg);
  font-family: var(--font-m); font-size: 10px; letter-spacing: .1em;
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.toast.is-on { opacity: 1; transform: none; }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
  .hero__title .line__in { transform: none !important; }
}
body.motion-lite .grain { animation: none; }
body.motion-off .gl,
body.motion-off .grain { display: none; }
body.motion-off .marquee__track,
body.motion-off .pulse::after,
body.motion-off .caret,
body.motion-off .art-1::after,
body.motion-off .art-2::after,
body.motion-off .art-3::before,
body.motion-off .art-3::after,
body.motion-off .art-5::after { animation: none; }

/* ---------- focus ---------- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---------- print-ish safety for very small screens ---------- */
@media (max-width: 400px) {
  body { font-size: 16px; }
  .stat span { font-size: 8px; }
}
