/* ==========================================================================
   SHOWREEL STUDIO — Design System
   取自站点结构分析的视觉规范：
   亮底 #F0F0F0 / 正文灰阶 #606060→#000 / 详情页纯黑 #0b0b0b~#1a1a1a
   字标全大写无衬线，字距收紧；彩色只出现在作品缩略图上。
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  --bg:          #f0f0f0;
  --bg-soft:     #f8f8f8;
  --bg-sunk:     #e8e8e8;
  --ink:         #0a0a0a;
  --ink-2:       #606060;
  --ink-3:       #909090;
  --line:        #c8c8c8;
  --line-soft:   #dedede;

  --dark:        #0b0b0b;
  --dark-2:      #121212;
  --dark-3:      #1c1c1c;
  --dark-ink:    #f2ece6;
  --dark-ink-2:  #a6a6a6;

  --accent:      #d24b3a;
  --ok:          #2f7d55;
  --warn:        #b8791f;
  --danger:      #b5342a;

  --radius:      2px;
  --radius-lg:   4px;
  --shadow-1:    0 1px 2px rgba(0, 0, 0, .06);
  --shadow-2:    0 6px 24px rgba(0, 0, 0, .10);
  --shadow-3:    0 18px 60px rgba(0, 0, 0, .18);

  --pad:         clamp(16px, 3.4vw, 56px);
  --gap:         clamp(10px, 1.2vw, 20px);
  --maxw:        1560px;

  /* 栅格列数：桌面 5 栏，逐级降档 */
  --cols:        5;
  --work-cols:   3;

  --ease:        cubic-bezier(.22, .61, .36, 1);
  --dur:         .34s;

  --font: "Inter", "Helvetica Neue", Helvetica, Arial, "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "SF Mono", "JetBrains Mono", "Cascadia Mono", Consolas, monospace;
  /* 封面上的作者名与标语用衬线，更像印品 */
  --serif: "Songti SC", "Source Han Serif SC", "Noto Serif SC", Georgia,
           "Times New Roman", "SimSun", serif;
}

@media (max-width: 1280px) { :root { --cols: 4; } }
@media (max-width: 1024px) { :root { --cols: 3; } }
@media (max-width: 768px)  { :root { --cols: 2; --work-cols: 2; } }
@media (max-width: 520px)  { :root { --cols: 1; --work-cols: 1; } }

/* ---------- 1b. 深色主题（主页 / 封面） ----------
   这两页的背景是 PatternWaves（黑底 + 靛蓝的波浪图案），所以把整页的
   明暗 token 反过来：底变黑、字变亮、线变暗。所有组件都靠这几个 token 上色，
   在这里覆盖一次就够了 —— 不用逐个组件改。
   文字「适应背景颜色」靠的就是这一步：--ink 从 #0a0a0a 变成 #f4f4f4。 */
.page--dark {
  --bg:          #000000;
  --bg-soft:     #0b0b0b;
  --bg-sunk:     #161616;
  --ink:         #f4f4f4;
  --ink-2:       #9c9c9c;
  --ink-3:       #6c6c6c;
  --line:        #333333;
  --line-soft:   #1e1e1e;

  /* 黑底上的阴影要更重才看得出来 */
  --shadow-1:    0 1px 2px rgba(0, 0, 0, .7);
  --shadow-2:    0 6px 24px rgba(0, 0, 0, .6);
  --shadow-3:    0 18px 60px rgba(0, 0, 0, .75);

  background: var(--bg);
  color: var(--ink);
}
/* 导航栏与背景融合：原来是 --bg 88% 的浅色，在黑底上就是一条白带。
   压到 62% 并保留毛玻璃，滚上去的内容被糊掉，但图案还透得出来。 */
.page--dark .nav {
  background: color-mix(in srgb, var(--bg) 62%, transparent);
  border-bottom-color: transparent;
}
.page--dark .nav[data-stuck="1"] { border-bottom-color: var(--line-soft); }
/* 骨架屏原来写死了浅色 #f2f2f2 */
.page--dark .skeleton {
  background: linear-gradient(90deg, var(--bg-sunk) 25%, var(--bg-soft) 37%, var(--bg-sunk) 63%);
  background-size: 400% 100%;
}

/* ---------- 2. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, video, canvas, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: var(--radius);
}

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

/* ---------- 3. Layout ---------- */
.shell {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.page { min-height: 100dvh; display: flex; flex-direction: column; }
.page > main { flex: 1 1 auto; }

.stack     { display: flex; flex-direction: column; }
.row       { display: flex; align-items: center; }
.row-gap   { display: flex; align-items: center; gap: var(--gap); flex-wrap: wrap; }
.between   { justify-content: space-between; }
.grow      { flex: 1 1 auto; min-width: 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- 4. Typography ---------- */
.wordmark {
  --wm-ink: var(--ink);
  /* 注意：这里必须是 inline-block 而不是 flex。
     一旦成为 flex 容器，.wm-o 会被块级化，innerText/读屏会把 "SHOWREEL" 断成
     "SH / O / WREEL"，破坏 SEO 与可访问性。 */
  display: inline-block;
  color: var(--wm-ink);
  font-weight: 900;
  font-size: clamp(34px, 6.4vw, 104px);
  line-height: .86;
  letter-spacing: -.045em;
  text-transform: uppercase;
  white-space: nowrap;
}
.wordmark--sm { font-size: clamp(22px, 3.2vw, 40px); letter-spacing: -.035em; }

/* SH◎WREEL 的 O：字母本体保留在 DOM 里（SEO / 读屏能读到 "SHOWREEL"），
   但设为透明，用同心圆环叠加视觉表现。 */
.wm-o {
  position: relative;
  display: inline-block;
  width: .76em;
  height: .76em;
  margin-inline: .04em;
  font-size: 1em;
  line-height: 1;
  vertical-align: -.03em;
  text-align: center;
  color: transparent;
}
.wm-o::before {
  content: "";
  position: absolute;
  inset: 0;
  border: .085em solid var(--wm-ink, currentColor);
  border-radius: 50%;
}
.wm-o::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: .17em;
  height: .17em;
  background: var(--wm-ink, currentColor);
  border-radius: 50%;
}

.eyebrow {
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
  font-weight: 600;
}

.tagline-en {
  font-size: clamp(12px, 1.15vw, 16px);
  letter-spacing: .01em;
  color: var(--ink);
}
.tagline-zh {
  font-size: clamp(12px, 1.15vw, 16px);
  letter-spacing: .18em;
  color: var(--ink);
}
.muted { color: var(--ink-2); }
.tiny  { font-size: 12px; }
.mono  { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* ---------- 5. Top navigation ---------- */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 97%, transparent);
    /* 去掉毛玻璃：底下背景一直在动，是首页掉帧的主因 */
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease);
}
.nav[data-stuck="1"] { border-bottom-color: var(--line-soft); }
.nav__inner {
  display: flex; align-items: center; gap: var(--gap);
  min-height: 64px;
  justify-content: space-between;
}
.nav__links { display: flex; align-items: center; gap: clamp(10px, 1.6vw, 26px); }
.nav__link {
  font-size: 13px; font-weight: 600; color: var(--ink-2);
  padding: 6px 2px; position: relative; white-space: nowrap;
}
.nav__link:hover, .nav__link[aria-current="page"] { color: var(--ink); }
.nav__link[aria-current="page"]::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 2px; background: var(--ink);
}

/* ---------- 6. Buttons ---------- */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--bg);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px;
  background: var(--btn-bg); color: var(--btn-fg);
  border: 1px solid var(--btn-bg); border-radius: 999px;
  font-size: 13px; font-weight: 700; letter-spacing: .02em;
  cursor: pointer; white-space: nowrap;
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
              border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }

.btn--ghost { --btn-bg: transparent; --btn-fg: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--sm { padding: 7px 14px; font-size: 12px; }
.btn--danger { --btn-bg: transparent; --btn-fg: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); }
.btn--danger:hover { --btn-bg: var(--danger); --btn-fg: #fff; border-color: var(--danger); }
.btn--block { width: 100%; }

/* ---------- 7. Cover page ----------
   海报式构图：正中一张大唱片（带柔化光晕），四角与两侧散布元信息，
   大量留白 + 单色 + 纸感颗粒。字标的 O 正好落在唱片中心。 */
.cover {
  position: relative;
  min-height: 100dvh;
  /* 用 flex 而不是 grid：grid 的隐式轨道在窄屏下不一定被拉伸，
     会让中间这一组整体靠左（实测手机上偏了 32px）。 */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: clamp(22px, 5vh, 56px) var(--pad);
  /* 不设底色：让底下那层 ASCII 渐变背景透上来（没有 WebGL2 时看到的是 body 的 --bg） */
  background: transparent;
  isolation: isolate;
}
/* 纸感颗粒：极淡的一层噪点，靠它把"电子文档"变成"印品" */
.cover::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .42;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/><feColorMatrix type='saturate' values='0'/></filter><rect width='160' height='160' filter='url(%23n)' opacity='.5'/></svg>");
}
/* 四周压一点暗角，视线自然聚到中间 */
.cover::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%, rgba(0,0,0,0) 52%, rgba(0,0,0,.05) 100%);
}

/* ---- 四角 / 两侧元信息 ---- */
.cover__corner {
  position: absolute;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-width: min(34vw, 300px);
}
.cover__corner--tl { left: var(--pad); top: clamp(22px, 5vh, 56px); }
.cover__corner--tr { right: var(--pad); top: clamp(22px, 5vh, 56px); align-items: flex-end; }
.cover__corner--ml { left: var(--pad); top: 50%; transform: translateY(-58%); }
.cover__corner--mr { right: var(--pad); top: 50%; transform: translateY(-58%); align-items: flex-end; }
.cover__corner--bl { left: var(--pad); bottom: clamp(72px, 12vh, 108px); }
.cover__corner--br { right: var(--pad); bottom: clamp(72px, 12vh, 108px); }

.cover__kicker {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.cover__kicker--dim { opacity: .62; letter-spacing: .16em; }
.cover__name {
  font-family: var(--serif);
  font-size: clamp(20px, 2.6vw, 34px);
  font-weight: 700;
  letter-spacing: .04em;
  line-height: 1.1;
  margin: 2px 0 2px;
}
.cover__index {
  font-family: var(--mono);
  font-size: clamp(22px, 2.4vw, 34px);
  font-weight: 700;
  line-height: 1;
}
/* 参考图里序号下面那根短竖线 */
.cover__rule {
  display: block;
  width: 1px;
  height: clamp(26px, 6vh, 54px);
  margin-top: 10px;
  background: var(--ink);
  opacity: .85;
}
.cover__year {
  font-family: var(--mono);
  font-size: clamp(15px, 1.5vw, 20px);
  font-weight: 700;
  letter-spacing: .06em;
  writing-mode: vertical-rl;
  text-orientation: mixed;
}
.cover__tagline {
  font-family: var(--serif);
  font-size: clamp(13px, 1.15vw, 16px);
  line-height: 1.6;
  letter-spacing: .06em;
}
.cover__tagline--en {
  font-family: inherit;
  font-size: clamp(10px, .82vw, 11.5px);
  letter-spacing: .1em;
  color: var(--ink-2);
  max-width: 34ch;
  margin-top: 4px;
}
.cover__badge {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--line);
  display: grid; place-items: center;
  color: var(--ink-2);
}

/* ---- 中心：只有唱片 ---- */
.cover__center {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.cover__stage {
  position: relative;
  /* 下面这组是按当前封面插画（1632×1568，唱片半径 401.8、标签半径 93.9）实测的：
     唱片圆心 (773.0, 771.9)、标签圆心 (812.1, 813.6) —— 标签比唱片中心偏右下约 5%。 */
  --disc-scale: 1.803;      /* 图宽 / 唱片直径 = 1632 / 803.6 */
  /* 中心标签的几何：由 make-cover-disc.py 用最小二乘拟合出来的。
     注意标签圆心和唱片圆心**不重合**，差 6.6 个原图像素 ——
     圆窗必须对齐标签自己的圆心，否则标签是绕偏心点在转，图案会摆动、边缘露月牙。 */
  --label-ratio: 0.1790;    /* 标签直径 / 唱片直径 = 187.8 / 803.6 */
  --label-dx: 5.938%;       /* 标签圆心相对唱片圆心的偏移，占唱片直径 */
  --label-dy: 1.809%;
  --label-ox: 48.97%;       /* 标签圆心在封面图里的位置（占图宽/图高） */
  --label-oy: 48.01%;
  /* 唱片圆心在整张图里的位置是 47.36% / 49.23%，不在正中 ——
     把 disc 整体挪回来，唱片才会落在舞台中央 */
  --disc-dx: 7.79%;
  --disc-dy: 5.34%;
  /* 中间没有文字了，唱片就是唯一主体：占到视口高度的 ~58%，
     用 40vw 兜住窄屏，画布比唱片大所以还要留出唱臂的空间 */
  /* 这张插画四周留白多（图宽是唱片直径的 2.03 倍），舞台要给小一点，
     否则 2 倍大的底图会把唱臂顶出视口 */
  /* 这张插画四周留白 + 唱臂，图宽是唱片直径的 1.8 倍；舞台要给小一点，
     整块底图（含唱臂）才进得了视口 */
  width: clamp(180px, min(48vh, 30vw), 520px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  container-type: inline-size;
}
/* 柔化光晕：垫在唱片后面模拟失焦的边缘。
   封面图带唱臂，阴影已经由图片自身的 drop-shadow 承担，这里只留很淡的一层。 */
.cover__halo {
  position: absolute;
  inset: -14%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%,
    rgba(0, 0, 0, .20) 0%, rgba(0, 0, 0, .10) 45%, rgba(0, 0, 0, 0) 72%);
  filter: blur(30px);
}
.cover__disc {
  position: absolute;
  inset: 0;
  /* 不裁圆：封面图里带着唱臂，唱臂要伸到唱片外面。 */
}
/* 底图：唱片 + 唱臂，整张画布铺在舞台上，静止 */
/* 整张插画绕自己的中心匀速转（唱臂一起转） */
.cover__base--spin {
  transform-origin: 50% 50%;
  animation: cover-spin-whole 14s linear infinite;
}
@keyframes cover-spin-whole {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .cover__base--spin { animation: none; }
}

.cover__disc > img {
  /* 必须用绝对定位 + translate 居中。
     图比容器大（1.605 倍），而容器里的隐式轨道是从左上开始排的，
     靠 place-items:center 根本居不了中 —— 唱片会整体偏右下约 1/6 个直径。 */
  position: absolute;
  /* --disc-dx / --disc-dy：插画里的唱片圆心未必在图片正中，把底图挪一下，
     唱片才落在舞台中央。只挪底图 —— 标签圆窗是按唱片圆心定位的，跟着挪会重复偏移。 */
  left: calc(50% + var(--disc-dx, 0%));
  top: calc(50% + var(--disc-dy, 0%));
  transform: translate(-50%, -50%);
  width: calc(100% * var(--disc-scale));
  max-width: none;
  height: auto;
  display: block;
  /* 阴影跟着不透明轮廓走，唱臂也会带上 */
  filter: drop-shadow(0 16px 36px rgba(0, 0, 0, .24));
}
/* 中心标签的圆窗：**对齐标签自己的圆心**（不是唱片圆心），半径取拟合出的标签半径。
   窗口里放同一张图，放大 --disc-scale / --label-ratio 倍，
   并把图里标签的圆心挪到窗口中心 —— 这样旋转轴就是标签圆心，图案原地转、不摆动。 */
.cover__label {
  position: absolute;
  left: calc(50% + var(--label-dx));
  top: calc(50% + var(--label-dy));
  z-index: 1;
  width: calc(100% * var(--label-ratio));
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  transform: translate(-50%, -50%);
}
.cover__label img {
  position: absolute;
  /* 把"图里标签圆心"对准窗口中心：偏移量换算到窗口宽度要除以 --label-ratio */
  left: calc(50% - var(--label-dx) / var(--label-ratio));
  top: calc(50% - var(--label-dy) / var(--label-ratio));
  width: calc(100% * var(--disc-scale) / var(--label-ratio));
  max-width: none;
  height: auto;
  display: block;
  /* 旋转轴必须是**标签圆心**（不是图的心）：图里标签圆心与图心差 6.6 个原图像素，
     绕图心转的话图案会绕着偏心点摆。θ=0 时 transform 退化成纯 translate，
     所以 0° 依然与底图像素级重合。 */
  transform-origin: var(--label-ox) var(--label-oy);
  animation: cover-spin 5s linear infinite;
}
@keyframes cover-spin {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}
/* 没有自定义封面图时用内置黑胶（这个是纯圆，自己裁；整张一起转） */
.cover__disc .vinyl {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  box-shadow: 0 20px 48px rgba(0, 0, 0, .22);
}

/* 字标已从封面移除（只留唱片）。下面这组是给 404 之类的降级页面用的标题样式，
   封面本身不再有 .cover__titles / .cover__brand / .cover__sub。 */

/* ---- 进入作品集 ---- */
.cover__enter {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: clamp(18px, 3.4vh, 34px);
  transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--ink-2); background: none; border: 0; cursor: pointer;
  padding: 9px 16px; border-radius: 999px;
}
.cover__enter:hover { color: var(--ink); background: var(--bg-sunk); }
.cover__enter svg { animation: nudge 2.4s var(--ease) infinite; }
@keyframes nudge { 0%,100% { transform: translateY(0); } 50% { transform: translateY(4px); } }

/* 窄屏：去掉两侧竖排，保留四角与中心 */
@media (max-width: 820px) {
  .cover__corner--ml,
  .cover__corner--mr { display: none; }
  .cover__stage { width: clamp(240px, min(58vh, 46vw), 420px); }
  .cover__corner--bl { bottom: clamp(66px, 13vh, 96px); }
}
@media (max-width: 520px) {
  .cover__corner { max-width: 46vw; }
  .cover__corner--tr { display: none; }
  .cover__tagline--en { display: none; }
  /* 手机上屏幕是唯一的约束，按宽度定；画布左右会溢出去一点，
     但唱片和唱臂的实际内容仍在屏内（E2E 按内容 bbox 校验） */
  .cover__stage { width: min(70vw, 300px); }
}

/* 黑胶唱片装饰 */
.vinyl {
  position: relative; border-radius: 50%;
  background:
    repeating-radial-gradient(circle at 50% 50%,
      #141414 0 2px, #1d1d1d 2px 3px, #101010 3px 4px);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.06), var(--shadow-3);
}
.vinyl::before {
  content: ""; position: absolute; inset: 31%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, var(--accent) 0 62%, #8e2f22 62% 100%);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.35);
}
.vinyl--spin { animation: spin 9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.vinyl--flat { animation: none; }

/* ---------- 8. Home：编辑式排版 ----------
   参考瑞士国际主义那一路：顶部小号大写元信息分栏、发丝分割线、
   大字标 + 圆形印章、作品带序号、大量留白。 */
.home { padding-block: clamp(20px, 3vw, 42px) clamp(30px, 5vw, 70px); }

/* 小号大写标签 */
.kicker {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink-2);
  white-space: nowrap;
}
.kicker--dim { opacity: .58; letter-spacing: .16em; }

/* 发丝分割线 */
.rule { display: block; height: 1px; background: var(--ink); opacity: .8; }
.rule--soft { background: var(--line); opacity: 1; }

/* ① 元信息行：左中右分栏 */
.home__meta {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: baseline;
  gap: var(--gap);
  margin-bottom: 9px;
}
.home__meta > :nth-child(2) { justify-self: center; }
.home__meta > :last-child { justify-self: end; }

/* ② 报头：大字标 + 圆印章 */
.home__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(16px, 3vw, 40px);
  padding-block: clamp(16px, 3vw, 40px) clamp(12px, 2.2vw, 28px);
}
.seal {
  position: relative;
  flex: 0 0 auto;
  width: clamp(72px, 8.2vw, 110px);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid var(--ink);
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 1px;
}
/* 内圈细环，做出印章的双环感 */
.seal::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 1px solid var(--line);
}
.seal__num {
  font-family: var(--mono);
  font-size: clamp(19px, 2vw, 27px);
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.seal__txt {
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-2);
  text-indent: .2em;
}

/* ③ 作者资料 */
.home__owner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: clamp(14px, 2vw, 26px);
  align-items: center;
  padding-block: clamp(16px, 2.4vw, 30px);
}
.profile__avatar {
  width: clamp(56px, 6.4vw, 84px);
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-sunk);
  border: 1px solid var(--line-soft);
  flex: 0 0 auto;
}
.profile__avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile__name { font-size: clamp(15px, 1.5vw, 19px); font-weight: 800; letter-spacing: -.01em; }
.profile__meta {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--ink-2); margin-top: 3px;
}
.profile__meta i { font-style: normal; color: var(--line); }
.profile__line { margin-top: 8px; font-size: 13px; color: var(--ink); }
.profile__actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ④ 作品区 */
.home__works { padding-block: clamp(18px, 2.6vw, 34px) 0; }
.home__works .section__title { font-size: clamp(16px, 1.8vw, 23px); }

.badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 700; letter-spacing: .06em;
  padding: 3px 8px; border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-2); text-transform: uppercase;
}

/* ---------- 8b. 网页背景：ASCII 渐变 ----------
   WebGL2 画的一层背景（js/gradient-ascii.js）。fixed 铺满视口，内容压在它上面。
   画布是半透明的，底下还是 body 的 --bg 底色；WebGL2 不可用时容器是空的，等于没有这层。 */
.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.bg canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}
/* 必需：静态元素会被 position:fixed + z-index:0 的背景盖住，内容要显式抬起来。
   .nav 自己有 z-index: 40，不动它。 */
.page > main,
.page > .footer { position: relative; z-index: 1; }

/* ---------- 9. Section / grids ---------- */
.section { padding-block: clamp(20px, 3vw, 44px); }
.section__head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: var(--gap); margin-bottom: clamp(12px, 1.6vw, 22px);
}
.section__title { font-size: clamp(15px, 1.6vw, 20px); font-weight: 800; letter-spacing: -.01em; }

.grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  gap: var(--gap);
}
.grid--works { grid-template-columns: repeat(var(--work-cols), minmax(0, 1fr)); }

/* ---------- 10. Cards ---------- */
/* 作品卡已改成「环形轮播」（js/circular-carousel.js），纯 CSS 3D、不需要 WebGL。
   .card__frame / __title / __sub 保留，落地页的作品集列表还在用。 */
.card__frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--bg-sunk);
  box-shadow: var(--shadow-1);
}
.card__frame img,
.card__frame video { width: 100%; height: 100%; object-fit: cover; }

.card__title {
  font-size: 13.5px; font-weight: 600; letter-spacing: .01em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; line-height: 1.45;
}
.card__sub { font-size: 12px; color: var(--ink-2); }

/* 收藏（只有机主看得到） */
.card__fav {
  width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  background: rgba(0,0,0,.42); color: #fff; border: 0;
  transition: opacity var(--dur) var(--ease), background var(--dur) var(--ease);
}
.card__fav[aria-pressed="true"] { color: #ffd24a; }
.card__fav svg { width: 14px; height: 14px; }

/* ---------- 10b. 作品弧形画廊（CircularGallery） ---------- */
.works {
  position: relative;
}

.works__stage {
  position: relative;
  width: 100%;
  height: clamp(340px, 56vh, 560px);
  overflow: hidden;
  cursor: grab;
  outline: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: pan-y;
}
.works__stage[data-dragging] { cursor: grabbing; }
.works__stage:focus-visible {
  box-shadow: inset 0 0 0 2px var(--line);
  border-radius: var(--radius-lg);
}

.circular-gallery {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  outline: none;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.circular-gallery[data-dragging] { cursor: grabbing; }
.circular-gallery__track { position: absolute; inset: 0; }

.circular-gallery__card {
  position: absolute;
  left: 50%;
  top: 50%;
  display: block;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  transform-origin: 50% 50%;
  will-change: transform, opacity;
  -webkit-tap-highlight-color: transparent;
}
.circular-gallery__frame {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
  border-radius: calc(var(--cg-radius, 0.05) * 100%);
  background: #141414;
  box-shadow: 0 calc(18px * var(--cg-shadow, 0.25)) calc(44px * var(--cg-shadow, 0.25))
    rgba(0, 0, 0, calc(0.55 * var(--cg-shadow, 0.25)));
}
.circular-gallery__frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}
.circular-gallery__title {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 10px);
  display: block;
  font-size: 13px;
  line-height: 1.3;
  text-align: center;
  color: var(--cg-text, #fff);
  opacity: .82;
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 说明区：轮播下方 */
.works__caption {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 20px;
  text-align: center;
  pointer-events: none;
}
.works__caption-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.35;
  color: var(--ink);
}
.works__caption-sub { font-weight: 400; opacity: .6; }
.works__caption-count {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  opacity: .5;
  color: var(--ink);
}
.works__caption-digits { display: inline-flex; }
.works__caption-digit { display: inline-block; height: 1em; overflow: hidden; }
.works__caption-reel {
  display: flex;
  flex-direction: column;
  transition: transform 600ms cubic-bezier(.22, 1, .36, 1);
}
.works__caption-reel > span { height: 1em; }
.works__caption-slash { opacity: .6; }

.works__caption-fav { display: flex; justify-content: center; margin-top: 10px; }
.works__caption-fav:empty { display: none; }

/* 无障碍 / 降级 */
.works__a11y {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  list-style: none;
}
.works__a11y--visible {
  position: static;
  width: auto; height: auto;
  margin: 0; padding: 0;
  overflow: visible;
  clip: auto;
  display: grid;
  grid-template-columns: repeat(var(--work-cols, 3), minmax(0, 1fr));
  gap: var(--gap);
  list-style: none;
}
.works__a11y--visible a {
  display: block;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  font-size: 13px;
  color: var(--ink);
  text-decoration: none;
}
.works__a11y--visible a:hover { border-color: var(--ink); }
.works__stage--fallback { height: auto; }

.works__live {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  .works__caption-reel { transition: none; }
}

/* 栏目卡样式已随「栏目」模块一起移除（主页现在只有「全部作品」）。
   栏目数据本身还在：作品仍归属栏目，剪辑台的栏目编辑器、作品详情里的栏目名都照常。 */

/* 栏目卡样式已随「栏目」模块一起移除（主页现在只有「全部作品」）。
   栏目数据本身还在：作品仍归属栏目，剪辑台的栏目编辑器、作品详情里的栏目名都照常。 */

/* ---------- 11. Work detail ---------- */
.detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(280px, 26vw, 380px);
  /* 固定成"一屏高（减顶栏和播放条）"：
     左舞台与右信息栏始终齐平，播放条常驻底部，右栏内容超高时在栏内滚动。
     之前舞台写死 height，横屏时比右栏矮一截，下面就露出一条空带。 */
  height: calc(100dvh - 64px - 62px);
  min-height: 460px;
  background: var(--dark);
  color: var(--dark-ink);
}
.detail__stage {
  position: relative;
  display: grid;
  /* 第 1 行媒体、第 2 行缩略图条。
     这样"待播放的素材"永远在自己的行里，不会盖住正在展示的素材。 */
  grid-template-rows: minmax(0, 1fr) auto;
  background: #000;
  min-height: 0;          /* 跟随 grid 行高，不自己撑高 */
  --media-poster: none;
}

/* 媒体容器：占据舞台第 1 行，并为绝对定位的媒体提供定位上下文 */
.stage__media {
  position: relative;
  grid-row: 1;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  display: grid;
  place-items: center;
}

/* 模糊背景：竖屏视频两侧、横屏视频上下不再是大黑边 */
.stage__media::before {
  content: "";
  position: absolute;
  inset: -8%;
  background-image: var(--media-poster);
  background-position: center;
  background-size: cover;
  filter: blur(46px) saturate(150%) brightness(.38);
  opacity: .95;
  pointer-events: none;
}
/* 竖屏素材两侧留白很大，把模糊背景再压暗一点，避免喧宾夺主 */
.detail__stage[data-orient="portrait"] .stage__media::before {
  filter: blur(54px) saturate(140%) brightness(.26);
}

/* 注意 1：媒体必须绝对定位。
   在 grid + place-items:center 的容器里，`height:100%` 会因行高不确定而退化成 auto，
   竖屏视频就按宽度算出一个超高元素（实测 1051x1401 撑破 744 高的舞台，画面被上下裁掉）。
   绝对定位后百分比相对 .stage__media 的确定高度解析，contain 才真正生效。
   注意 2：必须用 `>` 限定直接子元素。之前写成后代选择器，
   缩略图条里的 <img> 也被拉成整条大小，十几张缩略图叠在一起把主画面糊住了。 */
.detail__stage > .stage__media > video,
.detail__stage > .stage__media > img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent;
}

/* 缩略图条：独占第 2 行，横向滚动，永远不会压到主画面 */
.stage__strip {
  grid-row: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  background: #101010;
  border-top: 1px solid rgba(255, 255, 255, .07);
  scrollbar-width: thin;
}
.stage__thumb {
  flex: 0 0 auto;
  width: 56px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 3px;
  overflow: hidden;
  background: #000;
  cursor: pointer;
  opacity: .6;
  transition: opacity var(--dur) var(--ease), border-color var(--dur) var(--ease),
              transform var(--dur) var(--ease);
}
.stage__thumb:hover { opacity: 1; }
.stage__thumb[aria-selected="true"] {
  opacity: 1;
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
  transform: translateY(-1px);
}
.stage__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.detail__stage--cover img,
.detail__stage--cover video { object-fit: cover; }

.detail__panel {
  padding: clamp(22px, 3vw, 44px) clamp(18px, 2.4vw, 36px);
  display: flex; flex-direction: column; gap: 18px;
  background: linear-gradient(160deg, var(--dark-2), var(--dark-3));
  overflow-y: auto;
  min-height: 0;          /* 允许收缩，超出时栏内滚动而不是把整行撑高 */
  scrollbar-width: thin;
}
.detail__panel h1 { font-size: clamp(17px, 1.9vw, 24px); font-weight: 800; letter-spacing: -.01em; }

.vinyl-mini { width: clamp(88px, 9vw, 132px); aspect-ratio: 1; }

.credits { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; }
.credits__row { display: flex; gap: 8px; }
.credits__role { color: var(--dark-ink-2); min-width: 3.2em; }
.credits__val { color: var(--dark-ink); }

.detail__block { display: flex; flex-direction: column; gap: 6px; font-size: 13px; line-height: 1.72; }
.detail__block .en { color: var(--dark-ink-2); font-size: 12.5px; }
.detail__rule { height: 1px; background: rgba(242, 236, 230, .16); }

.quote {
  border-left: 2px solid var(--accent);
  padding-left: 12px;
  font-size: 12.5px;
  color: var(--dark-ink-2);
}
.quote b { color: var(--dark-ink); font-weight: 700; }

/* 详情页底部播放条 */
.player-bar {
  /* 之前是 sticky bottom，压住作品内容；现在跟在作品下面，随页面一起走 */
  position: relative;
  z-index: 20;
  display: flex; align-items: center; gap: clamp(10px, 2vw, 26px);
  padding: 12px clamp(12px, 2vw, 22px);
  background: #000;
  border-top: 1px solid rgba(255, 255, 255, .08);
  color: var(--dark-ink);
}
.icon-btn {
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  background: transparent; border: 0; color: inherit;
  transition: background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.icon-btn:hover { background: rgba(255,255,255,.12); }
.icon-btn svg { width: 18px; height: 18px; }
.player-bar__note { font-size: 12.5px; color: var(--dark-ink-2); }
.player-bar__note b { color: var(--dark-ink); font-weight: 600; }

/* 波形 */
.wave { display: flex; align-items: center; gap: 2px; height: 24px; }
.wave i { width: 2px; background: currentColor; border-radius: 1px; opacity: .8; }
.wave--live i { animation: pulse 1.1s var(--ease) infinite; }
@keyframes pulse { 0%,100% { transform: scaleY(.45); } 50% { transform: scaleY(1); } }

/* ---------- 12. Studio ---------- */
.studio { display: grid; grid-template-columns: minmax(0, 1fr) clamp(300px, 26vw, 400px); min-height: calc(100dvh - 64px); }
.studio__main { padding: clamp(16px, 2.4vw, 34px) var(--pad); display: flex; flex-direction: column; gap: clamp(14px, 2vw, 24px); min-width: 0; }
.studio__side {
  border-left: 1px solid var(--line-soft);
  background: var(--bg-soft);
  padding: clamp(14px, 2vw, 24px);
  display: flex; flex-direction: column; gap: 14px;
  min-width: 0;
}

.panel {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  background: var(--bg-soft);
  padding: clamp(12px, 1.6vw, 20px);
}
.panel--flat { background: transparent; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); }
.input, .textarea, .select {
  width: 100%;
  padding: 9px 11px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 13.5px;
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
  min-width: 0;
}
.input:focus, .textarea:focus, .select:focus {
  outline: none; border-color: var(--ink);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ink) 10%, transparent);
}
.textarea { resize: vertical; min-height: 68px; line-height: 1.6; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }

.dropzone {
  border: 1.5px dashed var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(18px, 3vw, 34px);
  text-align: center;
  background: var(--bg-soft);
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
  cursor: pointer;
}
.dropzone:hover, .dropzone[data-over="1"] { border-color: var(--ink); background: var(--bg-sunk); }
.dropzone__icon { font-size: 26px; line-height: 1; margin-bottom: 8px; }
.dropzone__hint { font-size: 12px; color: var(--ink-2); margin-top: 4px; }

.assets { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px; overflow-y: auto; padding-right: 2px; }
.asset {
  position: relative; border: 1px solid var(--line-soft); border-radius: var(--radius);
  overflow: hidden; background: #fff; cursor: grab;
}
.asset:active { cursor: grabbing; }
.asset[data-selected="1"] { border-color: var(--ink); box-shadow: 0 0 0 2px color-mix(in srgb, var(--ink) 22%, transparent); }
.asset__thumb { aspect-ratio: 1; background: var(--bg-sunk); position: relative; }
.asset__thumb img, .asset__thumb video { width: 100%; height: 100%; object-fit: cover; }
.asset__name {
  font-size: 10.5px; padding: 5px 6px; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; color: var(--ink-2);
}
.asset__meta {
  position: absolute; left: 4px; bottom: 4px;
  font-family: var(--mono); font-size: 10px; padding: 1px 4px;
  background: rgba(0,0,0,.66); color: #fff; border-radius: 2px;
}
.asset__del {
  position: absolute; right: 4px; top: 4px;
  width: 22px; height: 22px; border-radius: 50%; border: 0; cursor: pointer;
  display: grid; place-items: center;
  background: rgba(0,0,0,.55); color: #fff; opacity: 0;
  transition: opacity var(--dur) var(--ease);
}
.asset:hover .asset__del { opacity: 1; }

.work-item {
  display: grid; grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 12px; align-items: center;
  padding: 10px; border: 1px solid var(--line-soft);
  border-radius: var(--radius); background: #fff;
}
.work-item[data-dragging="1"] { opacity: .5; }
.work-item[data-over="1"] { border-color: var(--ink); }
.work-item__thumb { width: 64px; aspect-ratio: 4/3; border-radius: var(--radius); overflow: hidden; background: var(--bg-sunk); }
.work-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.work-item__body { min-width: 0; }
.work-item__title { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.work-item__sub { font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.work-item__tools { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }

.toolbar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  justify-content: space-between;
}
/* 素材库分类标签：数量会随类型增加（全部/视频/图片/音乐/文档/需转码），
   必须允许换行，否则窄一点就顶出横向滚动条 */
.tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--line-soft); }
.tab {
  padding: 8px 12px; font-size: 13px; font-weight: 600; color: var(--ink-2);
  background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer;
  white-space: nowrap;
}
.tab[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }

/* ---------- 13. 播放器：可拖动进度条 ---------- */
.pbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 auto;
  min-width: 0;
}
.pbar__track {
  position: relative;
  flex: 1 1 auto;
  min-width: 60px;
  height: 22px;
  display: flex;
  align-items: center;
  cursor: pointer;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}
.pbar__track::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 4px;
  border-radius: 2px;
  background: currentColor;
  opacity: .24;
}
.pbar__buffered,
.pbar__played {
  position: absolute;
  left: 0;
  height: 4px;
  border-radius: 2px;
  width: 0;
  pointer-events: none;
}
.pbar__buffered { background: currentColor; opacity: .38; }
.pbar__played   { background: currentColor; opacity: 1; }
.pbar__thumb {
  position: absolute;
  left: 0;
  width: 13px; height: 13px;
  margin-left: -6.5px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.pbar:hover .pbar__thumb,
.pbar:focus-visible .pbar__thumb,
.pbar[data-dragging="1"] .pbar__thumb { opacity: 1; }
.pbar[data-dragging="1"] .pbar__thumb { transform: scale(1.25); }
.pbar[data-dragging="1"] .pbar__track { cursor: grabbing; }
.pbar__tip {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 0;
  transform: translateX(-50%);
  padding: 2px 6px;
  border-radius: 3px;
  background: rgba(0, 0, 0, .82);
  color: #fff;
  font-size: 11px;
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  pointer-events: none;
}
.pbar__time {
  display: flex;
  gap: 3px;
  font-size: 11.5px;
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  opacity: .82;
  white-space: nowrap;
}
.pbar[data-disabled="1"] { opacity: .38; pointer-events: none; }
.pbar:focus-visible { outline: none; }
.pbar:focus-visible .pbar__track::before {
  box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 45%, transparent);
}

/* ---------- 14. 栏目预览播放浮层 ---------- */
body.no-scroll { overflow: hidden; }

.pvl {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: clamp(8px, 3vw, 40px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s var(--ease);
}
.pvl[data-open="1"] { opacity: 1; pointer-events: auto; }
.pvl__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 4, 4, .84);
  backdrop-filter: blur(6px);
}
.pvl__box {
  position: relative;
  width: min(1200px, 100%);
  max-height: min(92dvh, 920px);
  display: flex;
  flex-direction: column;
  background: #000;
  color: var(--dark-ink);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--shadow-3);
  transform: translateY(12px) scale(.994);
  transition: transform .22s var(--ease);
}
.pvl[data-open="1"] .pvl__box { transform: none; }
.pvl__head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: linear-gradient(160deg, var(--dark-2), var(--dark-3));
}
.pvl__cat {
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--dark-ink-2);
  margin-bottom: 2px;
}
.pvl__title { font-size: clamp(15px, 1.6vw, 20px); font-weight: 800; letter-spacing: -.01em; }
.pvl__tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.pvl__tools .btn--ghost { --btn-fg: var(--dark-ink); border-color: rgba(242, 236, 230, .32); }
.pvl__tools .btn--ghost:hover { border-color: var(--dark-ink); }
.pvl__close { color: var(--dark-ink); }
.pvl__close:hover { background: rgba(255, 255, 255, .14); }

.pvl__stage {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  place-items: center;
  background: #000;
  --media-poster: none;
}
.pvl__stage::before {
  content: "";
  position: absolute;
  inset: -10%;
  background-image: var(--media-poster);
  background-position: center;
  background-size: cover;
  filter: blur(44px) saturate(150%) brightness(.36);
  opacity: .95;
  pointer-events: none;
}
.pvl__stage video,
.pvl__stage img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  max-height: min(64dvh, 640px);
  object-fit: contain;
  background: transparent;
}
.pvl__stage video { cursor: pointer; }
.pvl__empty { padding: 64px 20px; color: var(--dark-ink-2); font-size: 13px; }

.pvl__bar {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.4vw, 16px);
  padding: 12px clamp(10px, 1.6vw, 18px);
  background: linear-gradient(to top, rgba(0, 0, 0, .62), rgba(0, 0, 0, .2));
}
.pvl__progress { flex: 1 1 auto; min-width: 0; display: flex; }

/* 图片轮播进度条（视频用 .pbar，图片用这个） */
.slide-bar {
  position: relative;
  flex: 1 1 auto;
  min-width: 60px;
  height: 22px;
  display: flex;
  align-items: center;
}
.slide-bar::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 4px;
  border-radius: 2px;
  background: currentColor;
  opacity: .24;
}
.slide-bar > i {
  position: relative;
  z-index: 1;
  display: block;
  height: 4px;
  width: 0;
  border-radius: 2px;
  background: currentColor;
}
.slide-bar[hidden], .pbar[hidden] { display: none; }
.pvl__play { background: rgba(255, 255, 255, .16); }
.pvl__play:hover { background: rgba(255, 255, 255, .26); }
.pvl__count { font-size: 12px; color: var(--dark-ink-2); white-space: nowrap; }

@media (max-width: 640px) {
  .pvl { padding: 0; }
  .pvl__box {
    width: 100%;
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
  }
  .pvl__head { padding: 10px 12px; }
  .pvl__stage { flex: 0 0 auto; }
  .pvl__stage video,
  .pvl__stage img { max-height: 46dvh; }
  .pvl__bar {
    flex-wrap: wrap;
    row-gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  }
  .pvl__progress { order: 3; flex: 1 0 100%; }
  .pvl__count { margin-left: auto; }
  .pvl__tools .btn--ghost { padding: 6px 10px; font-size: 11.5px; }
}

/* ---------- 15. Modal / Toast ---------- */
.modal {
  position: fixed; inset: 0; z-index: 90;
  display: grid; place-items: center; padding: var(--pad);
  background: rgba(6, 6, 6, .55); backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none; visibility: hidden;
  transition: opacity var(--dur) var(--ease), visibility 0s linear var(--dur);
}
.modal[data-open="1"] {
  opacity: 1; pointer-events: auto; visibility: visible;
  transition: opacity var(--dur) var(--ease), visibility 0s;
}
.modal__box {
  width: min(720px, 100%); max-height: min(86dvh, 900px); overflow-y: auto;
  background: var(--bg); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-3);
  padding: clamp(16px, 2.4vw, 28px);
  transform: translateY(10px) scale(.99);
  transition: transform var(--dur) var(--ease);
}
.modal[data-open="1"] .modal__box { transform: none; }
.modal__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.modal__title { font-size: 16px; font-weight: 800; }

.toasts {
  position: fixed; right: var(--pad); bottom: var(--pad); z-index: 120;
  display: flex; flex-direction: column; gap: 8px; pointer-events: none;
  max-width: min(360px, calc(100vw - 2 * var(--pad)));
}
.toast {
  pointer-events: auto;
  display: flex; align-items: flex-start; gap: 8px;
  padding: 10px 14px; border-radius: var(--radius);
  background: var(--ink); color: var(--bg); font-size: 13px;
  box-shadow: var(--shadow-2);
  animation: toast-in .28s var(--ease);
}
.toast[data-kind="error"] { background: var(--danger); }
.toast[data-kind="ok"] { background: var(--ok); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

/* ---------- 16. Misc ---------- */

/* 形象图预览 */
.figure-preview {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.figure-preview__item {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  margin: 0; flex: 0 0 auto;
}
.figure-preview__box {
  width: 84px; height: 84px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg-sunk);
  display: grid; place-items: center;
  overflow: hidden; padding: 4px; text-align: center;
}
.figure-preview__box img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.figure-preview__item:nth-child(2) .figure-preview__box {
  width: 118px; height: 84px; border-radius: var(--radius-lg);
}

/* 提示条 */
.notice {
  display: flex; flex-direction: column; gap: 8px;
  padding: 10px 12px;
  border-radius: var(--radius);
  border: 1px solid color-mix(in srgb, var(--warn) 45%, transparent);
  background: color-mix(in srgb, var(--warn) 10%, #fff);
  font-size: 12.5px;
  line-height: 1.5;
}
.notice strong { font-size: 13px; }
.notice .btn { align-self: flex-start; }

/* 素材卡：需转码 / 转码中 */
.asset--bad { border-color: color-mix(in srgb, var(--warn) 55%, transparent); }
.asset__badge {
  position: absolute; left: 4px; top: 4px; z-index: 3;
  font-size: 10px; font-weight: 700; letter-spacing: .04em;
  padding: 2px 6px; border-radius: 3px;
  background: var(--warn); color: #fff;
}
.asset__badge--err { background: var(--danger); }
.asset__fix {
  position: absolute; right: 4px; bottom: 26px; z-index: 3;
  font-size: 10.5px; font-weight: 700;
  padding: 3px 8px; border-radius: 3px; border: 0; cursor: pointer;
  background: var(--ink); color: var(--bg);
}
.asset__fix:hover { background: #000; }
.asset__prog {
  position: absolute; left: 0; right: 0; bottom: 0; height: 3px; z-index: 3;
  background: rgba(0, 0, 0, .14);
}
.asset__prog > i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .3s linear; }

/* ---------- 17. 片段顺序编辑器（作品弹窗内） ---------- */
.clip-list {
  display: flex; flex-direction: column; gap: 6px;
  max-height: 280px; overflow-y: auto;
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 8px; background: #fff;
}
.clip {
  display: grid;
  grid-template-columns: 20px 52px minmax(0, 1fr) auto;
  gap: 10px; align-items: center;
  padding: 6px 8px;
  border: 1px solid var(--line-soft); border-radius: var(--radius);
  background: var(--bg-soft);
  cursor: grab;
  transition: border-color var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.clip:active { cursor: grabbing; }
.clip[data-dragging="1"] { opacity: .45; }
.clip[data-over="1"] { border-color: var(--ink); }
.clip__no { font-size: 11px; color: var(--ink-2); text-align: right; }
.clip__thumb {
  width: 52px; aspect-ratio: 4 / 3; border-radius: 3px;
  overflow: hidden; background: var(--bg-sunk);
}
.clip__thumb img { width: 100%; height: 100%; object-fit: cover; }
.clip__thumb--audio {
  display: grid; place-items: center;
  background: var(--bg-sunk);
  color: var(--ink-2);
  font-size: 20px;
}
.asset__note {
  display: grid; place-items: center;
  width: 100%; height: 100%;
  background: linear-gradient(150deg, var(--bg-sunk), #dcdcdc);
  color: var(--ink-2);
  font-size: 28px;
}
/* PDF 文档的占位块 */
.asset__note--pdf {
  background: linear-gradient(150deg, #f4e3e0, #e8cdc7);
  color: #8e3b2c;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: .08em;
}
.chip--audio { flex-direction: row; gap: 6px; justify-content: flex-start; }
.chip__note {
  display: grid; place-items: center;
  width: 22px; height: 22px; flex: 0 0 auto;
  border-radius: 3px;
  background: var(--bg-sunk);
  color: var(--ink-2);
}
.clip__body { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.clip__name {
  font-size: 12.5px; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.clip__meta { font-size: 11px; color: var(--ink-2); }
.clip__tools { display: flex; gap: 4px; }

.clip-picker {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
  gap: 8px;
  max-height: 190px; overflow-y: auto;
  padding: 8px;
  border: 1px dashed var(--line); border-radius: var(--radius);
}
.chip {
  display: flex; flex-direction: column; gap: 4px; align-items: center;
  padding: 4px; min-width: 0;
  border: 1px solid var(--line-soft); border-radius: var(--radius);
  background: #fff; cursor: pointer;
  font-size: 10.5px; color: var(--ink-2);
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 2px; }
.chip span { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- 18. 分享面板 / 只读模式 ---------- */
.share {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(14px, 2.4vw, 26px);
  align-items: start;
}
.share__qr {
  width: 168px;
  height: 168px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  display: grid;
  place-items: center;
}
.share__qr svg { width: 100%; height: auto; display: block; }
.share__side {
  display: flex; flex-direction: column; gap: 8px;
  min-width: 0;
}
.share__side .input { width: 100%; font-size: 12px; }
.share__lan { line-height: 1.6; }

@media (max-width: 720px) {
  .share { grid-template-columns: minmax(0, 1fr); }
  .share__qr { width: 140px; height: 140px; margin: 0 auto; }
}

/* 编辑入口默认藏起来，确认是机主后才显示 ——
   访客全程看不到，也不会"先闪一下再消失"（/api/session 是异步的） */
html:not([data-owner="1"]) [data-owner-only] { display: none !important; }

/* 分段选择器（播放按钮外观） */
.seg {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
}
.seg__item {
  padding: 7px 15px;
  border: 0;
  background: transparent;
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}
.seg__item + .seg__item { border-left: 1px solid var(--line); }
.seg__item:hover { color: var(--ink); }
.seg__item[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

/* 播放按钮外观预览（不转，方便看清样子） */
.bgm-preview {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px 5px 7px;
  border: 1px dashed var(--line);
  border-radius: 999px;
}
.bgm-preview .bgm { pointer-events: none; }
.bgm-preview .bgm__disc { animation: none; }
.bgm--image .bgm__disc { background-size: cover; background-position: center; }

/* 外观选择里的图片库 */
#m-btn-images { max-height: 172px; }
#m-btn-images .chip[aria-pressed="true"] {
  border-color: var(--ink);
  box-shadow: 0 0 0 1px var(--ink);
  color: var(--ink);
}
#m-btn-images .chip img { width: 100%; aspect-ratio: 1; object-fit: cover; }

/* 分享按钮：导航栏里一枚，封面页（无导航）用浮动版 */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.4;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease),
              background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.share-btn:hover { background: var(--ink); color: var(--bg); }
.share-btn:active { transform: scale(.96); }

/* 封面页没有导航栏，用浮动版；做成带文字的胶囊，别让人认不出这是个按钮 */
.share-btn--float {
  position: fixed;
  right: var(--pad);
  bottom: calc(var(--pad) + 64px);
  z-index: 60;
  padding: 0 16px;
  height: 46px;
  gap: 7px;
  font-size: 13px;
  background: color-mix(in srgb, var(--bg) 97%, transparent);
    /* 去掉毛玻璃：底下的 WebGL 背景一直在动 */
  box-shadow: var(--shadow-2);
}

/* 手机上「分享」二字也要留着 —— 只留个图标没人认得出 */
@media (max-width: 520px) {
  .share-btn { padding: 5px 10px; gap: 5px; font-size: 12px; }
  .share-btn--float { height: 42px; padding: 0 14px; bottom: calc(var(--pad) + 58px); }
  .share-btn svg { width: 14px; height: 14px; }
}

/* ---------- 19. 背景音乐控件 ---------- */
.field-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.switch {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 600; color: var(--ink-2);
  cursor: pointer; user-select: none;
}
.switch input { width: 15px; height: 15px; accent-color: var(--ink); cursor: pointer; }
.switch:has(input:checked) { color: var(--ink); }
.range {
  width: 100%;
  accent-color: var(--ink);
  cursor: pointer;
}

.bgm {
  position: relative;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform var(--dur) var(--ease);
}
.bgm:hover { transform: scale(1.06); }
.bgm:active { transform: scale(.97); }

/* 黑胶碟片：沟槽 + 红色片心 + 中心孔 */
.bgm__disc {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle at 50% 50%,
      #141414 0 2px, #1d1d1d 2px 3px, #101010 3px 4px);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .09),
    0 1px 4px rgba(0, 0, 0, .28);
  /* 始终挂着动画，靠 play-state 控制：暂停时停在当前角度而不是回弹 */
  animation: bgm-spin 3.2s linear infinite;
  animation-play-state: paused;
}

/* 自定义图片外观：图片当唱片，只留一圈细边和中心孔 */
.bgm--image .bgm__disc {
  background-size: cover;
  background-position: center;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .3),
    inset 0 0 0 3px rgba(0, 0, 0, .35),
    0 1px 4px rgba(0, 0, 0, .28);
}
.bgm--image .bgm__disc::after { display: none; }
.bgm--image .bgm__disc::before {
  width: 7px;
  height: 7px;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, .45);
}

/* 音符外观：不做旋转，靠底色/强调色区分播放状态 */
.bgm--note .bgm__disc {
  background: color-mix(in srgb, var(--ink) 86%, transparent);
  color: var(--bg);
  animation: none;
}
.bgm--note .bgm__disc::after,
.bgm--note .bgm__disc::before { display: none; }
.bgm--note[aria-pressed="true"] .bgm__disc {
  background: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 45%, transparent);
}
.bgm__disc::after {
  content: "";
  position: absolute;
  inset: 31%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, var(--accent) 0 62%, #8e2f22 62% 100%);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .35);
}
.bgm__disc::before {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--bg);
  z-index: 1;
}
.bgm[aria-pressed="true"] .bgm__disc { animation-play-state: running; }
.bgm[aria-pressed="true"] .bgm__disc {
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .16),
    0 0 0 2px color-mix(in srgb, var(--accent) 55%, transparent),
    0 2px 8px rgba(0, 0, 0, .3);
}
@keyframes bgm-spin { to { transform: rotate(360deg); } }

/* 悬停时在旁边浮出曲名（不占导航宽度） */
.bgm__name {
  position: absolute;
  right: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  max-width: 34ch;
  padding: 4px 10px;
  border-radius: 4px;
  background: var(--ink);
  color: var(--bg);
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur) var(--ease);
}
.bgm:hover .bgm__name,
.bgm:focus-visible .bgm__name { opacity: 1; }

.bgm--float {
  position: fixed;
  right: var(--pad);
  bottom: var(--pad);
  z-index: 60;
  width: 52px;
  height: 52px;
  box-shadow: var(--shadow-2);
  border-radius: 50%;
  background: color-mix(in srgb, var(--bg) 94%, transparent);
      /* 去掉毛玻璃：底图在转，每帧都要重算背景模糊 */
  padding: 6px;
}
.bgm--float .bgm__name {
  right: 0;
  top: auto;
  bottom: calc(100% + 8px);
  transform: none;
}

@media (max-width: 520px) {
  .bgm { width: 32px; height: 32px; }
  .bgm--float { width: 46px; height: 46px; }
  .bgm__name { max-width: 22ch; }
}

@media (prefers-reduced-motion: reduce) {
  .bgm__disc { animation: none !important; }
}

/* 手机上压缩主页头尾 ——
   报头（大字标 + 圆印章）整块收起来：大字标和导航栏的字标重复，
   印章里的作品数在「全部作品 05 / 05」旁边已经有了。
   元信息行中间的 "SELECTED WORKS" 在窄屏放不下，也收起来。
   手机访问一定是访客（机主只能从本机 localhost 打开），所以这就是"别人手机上看的样子"。 */
@media (max-width: 640px) {
  #brand-section { display: none; }
  .home__meta > :nth-child(2) { display: none; }
  .home__meta { grid-template-columns: 1fr 1fr; }
  .home__owner { grid-template-columns: auto minmax(0, 1fr); row-gap: 14px; }
  .home__owner .profile__actions { grid-column: 1 / -1; }
}

/* ---------- 20. Responsive ---------- */
.empty {
  display: grid; place-items: center; gap: 8px;
  padding: clamp(28px, 6vw, 64px) 16px;
  border: 1px dashed var(--line); border-radius: var(--radius-lg);
  color: var(--ink-2); font-size: 13px; text-align: center;
}
.skeleton {
  background: linear-gradient(90deg, var(--bg-sunk) 25%, #f2f2f2 37%, var(--bg-sunk) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: var(--radius);
}
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

.progress { height: 4px; background: var(--bg-sunk); border-radius: 999px; overflow: hidden; }
.progress > i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .2s linear; }

.divider { height: 1px; background: var(--line-soft); border: 0; margin: 0; }

.footer {
  padding: clamp(20px, 3vw, 40px) var(--pad);
  border-top: 1px solid var(--line-soft);
  display: flex; justify-content: space-between; gap: var(--gap); flex-wrap: wrap;
  font-size: 12px; color: var(--ink-2);
}


@media (max-width: 1024px) {
  .detail { grid-template-columns: minmax(0, 1fr); height: auto; min-height: 0; }
  /* 竖屏视频在窄屏上应该占满宽度、按比例撑高，而不是被压进一个矮框。
     窄屏舞台是 auto 高度，`1fr` 行会塌成 0，所以媒体要回到正常流。 */
  .detail__stage {
    grid-template-rows: auto auto;
    height: auto;
    min-height: clamp(220px, 46vw, 420px);
  }
  .detail__stage > .stage__media > video,
  .detail__stage > .stage__media > img {
    position: static;
    width: 100%;
    height: auto;
    max-height: 76dvh;
  }
  .stage__strip { padding: 8px 10px; gap: 6px; }
  .stage__thumb { width: 48px; height: 34px; }
  .detail__panel { overflow: visible; }
  .studio { grid-template-columns: minmax(0, 1fr); }
  .studio__side { border-left: 0; border-top: 1px solid var(--line-soft); }
  .profile { grid-template-columns: auto minmax(0, 1fr); }
  .profile__actions { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  body { font-size: 14.5px; }
  .nav__inner { min-height: 56px; }
  .nav__links { gap: 10px; overflow-x: auto; scrollbar-width: none; }
  .nav__links::-webkit-scrollbar { display: none; }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .work-item { grid-template-columns: 52px minmax(0, 1fr); }
  .work-item__thumb { width: 52px; }
  .work-item__tools { grid-column: 1 / -1; justify-content: flex-start; }
  .player-bar { flex-wrap: wrap; }
  /* 注意：这里原来有一条 .cover { justify-content: flex-start } —— 那是旧版封面
     （底部有页脚、要贴顶排）留下的。封面改成"整组垂直居中"后它会顶掉居中，
     在手机上还会让中间那一组整体偏左 32px，必须去掉。 */
}

@media (max-width: 520px) {
  .profile { grid-template-columns: minmax(0, 1fr); }
  .profile__avatar { width: 56px; }
  .btn { padding: 10px 16px; }
  .assets { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
  .detail__panel { padding: 20px 16px 26px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

@media print {
  .nav, .cover__foot, .player-bar, .toasts { display: none !important; }
  .detail { background: #fff; color: #000; }
}

/* ---------- 21. 动效（motion.js） ----------
   只动 transform / opacity，全部走合成层。 */
.mo-mask {
  overflow: hidden;
  /* 给上下留一点余量，遮罩不会切掉字母的下缘和重音符号 */
  padding-block: 0.06em;
  margin-block: -0.06em;
  vertical-align: bottom;
}

/* 作品卡片：进场前先压扁一点，避免"凭空出现" */
.mo-card-enter {
  transform: translate3d(0, 34px, 0) scale(0.96);
  opacity: 0;
}

/* 首屏各块在 opening 之前的初始状态（motion.js 关掉时不会加这个类） */
html.mo-ready .home__meta,
html.mo-ready .home__owner,
html.mo-ready .profile__actions > * {
  opacity: 0;
}
html.mo-opened .home__meta,
html.mo-opened .home__owner,
html.mo-opened .profile__actions > * {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  html.mo-ready .home__meta,
  html.mo-ready .home__owner,
  html.mo-ready .profile__actions > * { opacity: 1; }
  .mo-card-enter { transform: none; opacity: 1; }
}
