/* ============================================================================
   Vector · 作者页 / Credits Stage
   单屏剧场：巨大的 Nell 缓慢打字，幕后名单在背景里随机游走。
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; height: 100dvh; min-height: 100svh;
  overflow: hidden; overscroll-behavior: none;

  --bg: #f2f5f1;
  --bg-2: #e8eee9;
  --ink: #0b1512;
  --muted: rgba(11, 21, 18, 0.52);
  --muted-2: rgba(11, 21, 18, 0.32);
  --line: rgba(11, 21, 18, 0.13);
  --line-strong: rgba(11, 21, 18, 0.22);
  --accent: #059669;
  --accent-soft: rgba(5, 150, 105, 0.10);
  --dust: 11, 21, 18;

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", "Songti SC", "STSong", "Noto Serif SC", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  background: var(--bg); color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.5s ease, color 0.5s ease;
}
body:not(.light) {
  --bg: #050908;
  --bg-2: #0a1210;
  --ink: #e9f7f0;
  --muted: rgba(233, 247, 240, 0.50);
  --muted-2: rgba(233, 247, 240, 0.28);
  --line: rgba(233, 247, 240, 0.13);
  --line-strong: rgba(233, 247, 240, 0.22);
  --accent: #22f5a3;
  --accent-soft: rgba(34, 245, 163, 0.10);
  --dust: 233, 247, 240;
}

::selection { background: var(--accent); color: var(--bg); }

/* ---------------------------- 背景层 ---------------------------- */
.au-grid {
  position: fixed; inset: -8%; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 84px 84px;
  opacity: 0.42;
  mask-image: radial-gradient(ellipse 66% 62% at 50% 46%, #000 0%, transparent 76%);
  -webkit-mask-image: radial-gradient(ellipse 66% 62% at 50% 46%, #000 0%, transparent 76%);
}
.au-dust { position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: 0.9; }
.au-glow {
  position: fixed; left: 50%; top: 46%; z-index: 0; pointer-events: none;
  width: min(76vw, 920px); aspect-ratio: 1; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, var(--accent-soft), transparent 62%);
  filter: blur(34px);
  animation: au-breathe 9s ease-in-out infinite;
}
@keyframes au-breathe {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(0.96); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.04); }
}

.au-names {
  position: fixed; inset: 0; z-index: 2; overflow: hidden; pointer-events: none;
  transform: translate3d(calc(var(--mx, 0) * 12px), calc(var(--my, 0) * 9px), 0);
  mask-image: radial-gradient(ellipse 58% 50% at 50% 47%, transparent 30%, #000 62%);
  -webkit-mask-image: radial-gradient(ellipse 58% 50% at 50% 47%, transparent 30%, #000 62%);
}
.au-cred {
  position: absolute; left: 0; top: 0;
  display: inline-flex; align-items: baseline; gap: 0.7em;
  font-family: var(--mono);
  font-size: var(--fs, 0.72rem);
  letter-spacing: 0.24em; text-transform: uppercase;
  white-space: nowrap; color: var(--ink);
  opacity: 0; filter: blur(5px);
  transition: opacity 1.1s ease, filter 1.1s ease;
  will-change: transform;
}
.au-cred.in { opacity: var(--op, 0.5); filter: blur(0); }
.au-cred .idx { font-size: 0.64em; letter-spacing: 0.08em; color: var(--accent); opacity: 0.9; }
.au-cred .nm { opacity: 0.9; }

.au-grain {
  position: fixed; inset: 0; z-index: 3; pointer-events: none; opacity: 0.4;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 160px 160px;
  animation: au-grain 1.4s steps(2) infinite;
}
body:not(.light) .au-grain { mix-blend-mode: screen; opacity: 0.16; }
@keyframes au-grain {
  0% { transform: translate(0, 0); }
  50% { transform: translate(-2%, 1%); }
  100% { transform: translate(1%, -1%); }
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: 3; pointer-events: none;
  background: radial-gradient(ellipse 82% 72% at 50% 46%, transparent 52%, rgba(5, 9, 8, 0.07) 100%);
}
body:not(.light)::after {
  background: radial-gradient(ellipse 82% 72% at 50% 46%, transparent 40%, rgba(0, 0, 0, 0.62) 100%);
}

/* 内框 + 角标 */
.au-frame {
  position: fixed; inset: clamp(12px, 1.8vw, 26px); z-index: 4; pointer-events: none;
  border: 1px solid var(--line); opacity: 0.75;
}
.au-plus {
  position: absolute; font-family: var(--mono); font-style: normal;
  font-size: 0.6rem; line-height: 1; color: var(--muted-2);
}
.p1 { left: 0; top: 0; transform: translate(-50%, -50%); }
.p2 { right: 0; top: 0; transform: translate(50%, -50%); }
.p3 { left: 0; bottom: 0; transform: translate(-50%, 50%); }
.p4 { right: 0; bottom: 0; transform: translate(50%, 50%); }

/* ---------------------------- 顶部 ---------------------------- */
.au-top {
  position: fixed; z-index: 6;
  top: clamp(22px, 3.4vh, 38px);
  left: clamp(24px, 3.6vw, 50px);
  right: clamp(24px, 3.6vw, 50px);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.au-logo {
  display: inline-flex; align-items: center; gap: 0.55rem;
  color: var(--ink); text-decoration: none;
  font-size: 1rem; font-weight: 700; letter-spacing: -0.01em;
}
.au-logo img { width: 22px; height: 22px; display: block; }
.au-top-actions { display: inline-flex; align-items: center; gap: clamp(0.9rem, 1.8vw, 1.5rem); }
.au-theme {
  width: 34px; height: 34px; padding: 0; border-radius: 50%;
  border: 1px solid var(--line-strong); background: transparent; color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
  transition: border-color 0.3s, color 0.3s, transform 0.3s;
}
.au-theme:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.au-theme svg { width: 15px; height: 15px; }
.au-theme .au-ic-sun { display: none; }
body:not(.light) .au-theme .au-ic-moon { display: none; }
body:not(.light) .au-theme .au-ic-sun { display: block; }
.au-back {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.22em;
  text-transform: uppercase; text-decoration: none; color: var(--muted);
  transition: color 0.3s;
}
.au-back i { font-style: normal; transition: transform 0.3s; }
.au-back:hover { color: var(--accent); }
.au-back:hover i { transform: translate(2px, -2px); }

/* ---------------------------- 主舞台 ---------------------------- */
.au-stage {
  position: relative; z-index: 5;
  height: 100dvh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  padding: 0 clamp(1.2rem, 4vw, 3rem);
}
.au-eyebrow {
  margin: 0; display: inline-flex; align-items: center; gap: 0.8em;
  font-family: var(--mono); font-size: 0.58rem; letter-spacing: 0.4em;
  text-transform: uppercase; color: var(--muted);
  opacity: 0; animation: au-fade-up 1.5s cubic-bezier(0.2, 0.7, 0.2, 1) 0.15s forwards;
}
.au-eyebrow-dot {
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}
.au-name {
  position: relative; margin: clamp(0.6rem, 2.4vh, 1.6rem) 0 0;
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(5.6rem, min(25vw, 34vh), 19rem);
  line-height: 0.88; letter-spacing: -0.055em; color: var(--ink);
  user-select: none;
  text-shadow: 0 26px 90px rgba(5, 150, 105, 0.08);
  opacity: 0; animation: au-fade-up 1.2s cubic-bezier(0.2, 0.7, 0.2, 1) 0.1s forwards;
}
body:not(.light) .au-name { text-shadow: 0 0 90px rgba(34, 245, 163, 0.16); }
.au-type { display: inline-block; white-space: nowrap; }
.au-ch {
  display: inline-block;
  opacity: 0; transform: translateY(0.14em); filter: blur(12px);
  transition: opacity 0.55s ease, transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.55s ease;
}
.au-ch.on { opacity: 1; transform: none; filter: blur(0); }
.au-caret {
  position: absolute; bottom: 0.13em; width: 2px; height: 0.62em;
  background: var(--accent); opacity: 0;
  box-shadow: 0 0 14px var(--accent);
  transition: left 0.16s ease, opacity 0.35s ease;
}
.au-caret.blink { opacity: 1; animation: au-blink 1.15s steps(1) infinite; }
@keyframes au-blink { 0%, 54% { opacity: 1; } 55%, 100% { opacity: 0; } }

.au-hair {
  width: 0; height: 1px; margin: clamp(1.2rem, 4.4vh, 2.6rem) 0 clamp(0.9rem, 2.6vh, 1.7rem);
  background: linear-gradient(90deg, transparent, var(--line-strong) 18%, var(--line-strong) 82%, transparent);
  transition: width 1.3s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.au-hair.on { width: min(340px, 44vw); }

.au-thanks {
  margin: 0; max-width: 34rem;
  font-family: var(--serif); font-size: clamp(0.98rem, 1.15vw, 1.16rem);
  line-height: 1.95; letter-spacing: 0.06em; color: var(--muted);
  opacity: 0; transform: translateY(14px);
  transition: opacity 1.1s ease, transform 1.1s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.au-thanks.on { opacity: 1; transform: none; }
.au-thanks-en {
  display: inline-block; margin-top: 0.6rem;
  font-family: var(--mono); font-size: 0.58rem; letter-spacing: 0.3em;
  text-transform: uppercase; color: var(--muted-2);
}

@keyframes au-fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

/* ---------------------------- 底部 ---------------------------- */
.au-foot {
  position: fixed; z-index: 6; left: clamp(24px, 3.6vw, 50px); right: clamp(24px, 3.6vw, 50px);
  bottom: clamp(20px, 3vh, 32px);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  font-family: var(--mono); font-size: 0.56rem; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--muted-2);
}
.au-meta-mid { color: var(--muted); }
.au-meta-link { color: var(--muted); text-decoration: none; transition: color 0.3s; }
.au-meta-link:hover { color: var(--accent); }

/* ---------------------------- 响应式 ---------------------------- */
@media (max-width: 640px) {
  .au-name { font-size: clamp(4.6rem, 30vw, 8.6rem); letter-spacing: -0.05em; }
  .au-eyebrow { font-size: 0.5rem; letter-spacing: 0.32em; }
  .au-thanks { font-size: 0.9rem; line-height: 1.92; max-width: 20rem; letter-spacing: 0.03em; }
  .au-thanks-en { font-size: 0.5rem; letter-spacing: 0.22em; }
  .au-hair { margin: 1rem 0 0.8rem; }
  .au-hair.on { width: min(200px, 56vw); }
  .au-top { top: 18px; left: 18px; right: 18px; }
  .au-foot { left: 18px; right: 18px; bottom: 18px; font-size: 0.46rem; letter-spacing: 0.14em; }
  .au-frame { inset: 10px; }
  .au-logo span { font-size: 0.95rem; }
  .au-back { gap: 0.32rem; font-size: 0.5rem; letter-spacing: 0.12em; }
  .au-back span { font-size: 0.5rem; }
  .au-back i { font-size: 0.78rem; }
  .au-theme { width: 32px; height: 32px; }
}
@media (max-height: 620px) {
  .au-name { font-size: clamp(3.8rem, min(22vw, 30vh), 8rem); }
  .au-hair { margin: 0.8rem 0 0.6rem; }
  .au-thanks { font-size: 0.82rem; line-height: 1.8; }
  .au-eyebrow { font-size: 0.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  .au-glow, .au-grain { animation: none; }
  .au-ch { transition: none; }
  .au-cred { transition: none; }
  .au-hair, .au-thanks { transition: none; }
  .au-eyebrow, .au-name { animation-duration: 0.01s; }
}
