/* ==========================================================================
   PACDOWN CONSOLE · 「深空科技 HUD」设计系统 v2.0
   --------------------------------------------------------------------------
   设计主题：一台深空里的下载控制台
   - 底色：真空深空黑蓝（#04070f），两层缓慢漂移的全息雾光
   - 底纹：细网格 + 扫描光束（45s 巡场一圈），机器在呼吸
   - 品牌：全息青蓝渐变（#22d8f0 青 → #35f2c4 荧光绿），只给在线/激活元素
   - 卡片：切角玻璃（转角切 14px 斜口），四枚角标括弧，hover 浮现边框辉光
   - 字体：系统等宽栈做数字/时长/路径（时间码气质），中文正文保持系统黑体
   - 签名元素：顶部 HUD 走带光束——有任务时整条扫描带亮起、光针巡演
   ========================================================================== */

:root, [data-theme="dark"] {
  color-scheme: dark;

  /* 基调：真空深空 */
  --bg: #04070f;
  --bg-2: #070c18;
  --surface: rgba(148, 196, 255, .045);
  --surface-2: rgba(148, 196, 255, .085);
  --surface-solid: #0b1122;
  --border: rgba(148, 196, 255, .11);
  --border-hi: rgba(148, 196, 255, .3);

  /* 文字：冷灰白 */
  --text: #e8eefb;
  --text-2: #93a2c2;
  --text-3: #556386;

  /* 全息双色：全站品牌语言 */
  --holo-1: #22d8f0;       /* 全息青 */
  --holo-2: #35f2c4;       /* 荧光绿 */
  --holo-violet: #7c8cf8;  /* 辅助紫（数据次色） */
  --brand-1: var(--holo-1);
  --brand-2: #7df0e2;
  --brand-grad: linear-gradient(100deg, var(--holo-1) 0%, var(--holo-2) 100%);
  --brand-text-grad: linear-gradient(90deg, #6ff2ff 0%, #57f7cd 100%);
  --brand-glow: rgba(34, 216, 240, .38);
  --brand-dim: rgba(34, 216, 240, .12);
  --focus: rgba(34, 216, 240, .3);

  /* HUD 走带 */
  --playhead: #eafcff;

  /* 语义色 */
  --ok: #3ce6a0;
  --warn: #ffc24b;
  --err: #ff5d73;
  --cyan: var(--holo-1);

  --shadow-1: 0 1px 3px rgba(0, 0, 0, .45), 0 8px 28px rgba(0, 0, 0, .3);
  --shadow-2: 0 2px 10px rgba(0, 0, 0, .35), 0 20px 60px rgba(0, 0, 0, .6);
  --glow-card: 0 0 0 1px rgba(34, 216, 240, .22), 0 0 34px rgba(34, 216, 240, .1);

  --radius: 12px;
  --radius-sm: 8px;
  --cut: 14px;              /* 切角斜口尺寸 */

  /* 字体：数字/时长/路径/眉标用等宽（控制台气质）；不引 webfont */
  --font-num: ui-monospace, "Cascadia Code", "SF Mono", "JetBrains Mono", Consolas, monospace;
}

[data-theme="light"] {
  color-scheme: light;

  --bg: #eef2f9;
  --bg-2: #e2e8f4;
  --surface: rgba(255, 255, 255, .82);
  --surface-2: rgba(255, 255, 255, .97);
  --surface-solid: #ffffff;
  --border: rgba(10, 60, 90, .12);
  --border-hi: rgba(10, 60, 90, .3);

  --text: #0f1930;
  --text-2: #45608c;
  --text-3: #8ba3c8;

  --brand-1: #0899c2;
  --brand-2: #0e9a86;
  --brand-glow: rgba(8, 153, 194, .28);
  --brand-dim: rgba(8, 153, 194, .1);
  --focus: rgba(8, 153, 194, .24);
  --playhead: #0e7490;

  --shadow-1: 0 1px 3px rgba(20, 60, 100, .08), 0 8px 22px rgba(20, 60, 100, .09);
  --shadow-2: 0 2px 8px rgba(20, 60, 100, .12), 0 18px 48px rgba(20, 60, 100, .18);
  --glow-card: 0 0 0 1px rgba(8, 153, 194, .22), 0 0 26px rgba(8, 153, 194, .1);
}

/* ---------- 基础 ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html, body { height: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background .35s ease, color .35s ease;
}

/* ==========================================================================
   背景层：全息雾光 + 网格 + 扫描光束（科技感底噪，克制不抢戏）
   ========================================================================== */
.bg-glow {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(ellipse 90% 60% at 50% -10%, rgba(34, 216, 240, .06), transparent 60%),
    var(--bg);
}
/* 两团全息雾缓慢漂移 */
.bg-glow::before, .bg-glow::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(100px);
  animation: holo-drift 30s ease-in-out infinite alternate;
}
.bg-glow::before {
  width: 48vw; height: 48vw; left: -14vw; top: -20vw;
  background: radial-gradient(circle, rgba(34, 216, 240, .14), transparent 65%);
}
.bg-glow::after {
  width: 54vw; height: 54vw; right: -18vw; bottom: -24vw;
  background: radial-gradient(circle, rgba(53, 242, 196, .09), transparent 65%);
  animation-delay: -15s;
}
[data-theme="light"] .bg-glow {
  background:
    radial-gradient(ellipse 90% 60% at 50% -10%, rgba(34, 216, 240, .12), transparent 60%),
    var(--bg);
}
[data-theme="light"] .bg-glow::before { background: radial-gradient(circle, rgba(34, 216, 240, .16), transparent 65%); }
[data-theme="light"] .bg-glow::after { background: radial-gradient(circle, rgba(53, 242, 196, .12), transparent 65%); }
@keyframes holo-drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(5vw, 4vh) scale(1.1); }
}

/* 中央垂直雾柱（第二景深层次） */
.bg-glow .glow-mid {
  position: absolute; left: 32%; top: -28%; width: 44vw; height: 58vh;
  background: radial-gradient(ellipse 50% 50% at 50% 40%, rgba(124, 140, 248, .08), transparent 70%);
  filter: blur(70px); animation: holo-drift 38s ease-in-out infinite alternate-reverse;
}

/* HUD 底纹：细网格 + 扫描光束（JS 或静态挂到 body 末尾的 .bg-hud 元素） */
.bg-hud {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
}
/* 细网格：双色 linear-gradient 画十字线 */
.bg-hud::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(148, 196, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 196, 255, .05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 100% 90% at 50% 0%, #000 30%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 100% 90% at 50% 0%, #000 30%, transparent 85%);
}
[data-theme="light"] .bg-hud::before {
  background-image:
    linear-gradient(rgba(10, 60, 90, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(10, 60, 90, .06) 1px, transparent 1px);
}
/* 扫描光束：一道淡光 45s 巡场一圈 */
.bg-hud::after {
  content: ""; position: absolute; left: 0; right: 0; top: -12vh; height: 12vh;
  background: linear-gradient(180deg, transparent, rgba(34, 216, 240, .05) 60%, rgba(34, 216, 240, .09));
  animation: hud-scan 45s linear infinite;
}
@keyframes hud-scan {
  from { transform: translateY(0); }
  to { transform: translateY(130vh); }
}

.num { font-variant-numeric: tabular-nums; font-family: var(--font-num); font-size: .93em; letter-spacing: -.01em; }
.h-dur, .task-speed, .child-item .num { font-family: var(--font-num); }

/* ==========================================================================
   播放头（签名元素）：顶部 HUD 走带光束
   —— 常驻一线微光；有任务时整条扫描带亮起流动、光针巡演、红点呼吸
   ========================================================================== */
.playhead {
  position: fixed; top: 0; left: 228px; right: 0; height: 3px; z-index: 50;
  pointer-events: none;
}
.playhead-track {
  position: absolute; inset: 0;
  background: var(--border); opacity: .55;
  transition: opacity .3s;
}
.playhead.on .playhead-track {
  background: var(--brand-grad);
  background-size: 200% 100%;
  opacity: 1;
  animation: beam-flow 2.8s linear infinite;
  box-shadow: 0 0 16px var(--brand-glow), 0 1px 3px rgba(34, 216, 240, .5);
}
@keyframes beam-flow {
  from { background-position: 0 0; }
  to { background-position: -200% 0; }
}
.playhead-line {
  position: absolute; top: -1px; height: 5px; width: 2px;
  background: var(--playhead);
  box-shadow: 0 0 10px rgba(234, 252, 255, .95), 0 0 26px var(--brand-glow);
  animation: playhead-move 20s linear infinite;
  opacity: 0; transition: opacity .3s;
}
.playhead-line::before {
  content: ""; position: absolute; top: 0; bottom: 0; right: 2px; width: 110px;
  background: linear-gradient(270deg, rgba(34, 216, 240, .4), transparent);
}
.playhead-line::after {
  content: ""; position: absolute; bottom: -2px; left: -3.5px;
  border: 5px solid transparent; border-bottom: 6px solid var(--playhead);
}
.playhead.on .playhead-line { opacity: 1; }
.playhead .rec-dot {
  position: absolute; right: 14px; top: -3.5px; width: 7px; height: 7px;
  border-radius: 50%; background: var(--err); opacity: 0; transition: opacity .3s;
  box-shadow: 0 0 10px var(--err);
}
.playhead.on .rec-dot { opacity: 1; animation: breath 1.4s ease-in-out infinite; }
@keyframes playhead-move {
  from { left: 0; } to { left: calc(100% - 2px); }
}

/* ==========================================================================
   布局骨架：左侧控制台轨 + 主工作区
   ========================================================================== */
.sidebar {
  position: fixed; z-index: 40; left: 0; top: 0; bottom: 0;
  width: 228px; display: flex; flex-direction: column;
  padding: 22px 14px 18px;
  border-right: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-2) 88%, transparent);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: background .35s;
}
.main {
  position: relative; z-index: 1;
  margin-left: 228px;
  padding: 46px 46px 76px;
  max-width: 1560px;
}

/* Logo：全息方块 + 渐变品牌字 + 状态微光 */
.logo { display: flex; align-items: center; gap: 10px; padding: 2px 10px 20px; }
.logo-mark {
  position: relative;
  width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center;
  background: var(--brand-grad); color: #02181c;
  box-shadow: 0 0 18px var(--brand-glow), inset 0 1px 0 rgba(255, 255, 255, .4);
}
.logo-mark::after {
  content: ""; position: absolute; inset: -3px; border-radius: 10px;
  border: 1px solid rgba(34, 216, 240, .3);
  animation: logo-pulse 3.2s ease-in-out infinite;
}
@keyframes logo-pulse {
  0%, 100% { opacity: .35; transform: scale(1); }
  50% { opacity: .9; transform: scale(1.05); }
}
.logo-mark svg { width: 16px; height: 16px; }
.logo-text { font-size: 17px; font-weight: 800; letter-spacing: .6px; }
.logo-text em {
  font-style: normal;
  background: var(--brand-text-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}

/* 导航：控制台分组轨 */
.nav-group {
  font-family: var(--font-num);
  font-size: 10px; font-weight: 600; letter-spacing: 3px;
  color: var(--text-3); padding: 16px 12px 7px; text-transform: uppercase;
  display: flex; align-items: center; gap: 8px;
}
.nav-group::after {
  content: ""; flex: 1; height: 1px;
  background: linear-gradient(90deg, var(--border), transparent);
}
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-item {
  position: relative; display: flex; align-items: center; gap: 11px;
  padding: 9px 12px; border: 0; border-radius: 8px; cursor: pointer;
  background: transparent; color: var(--text-2);
  font: inherit; font-weight: 500; text-align: left;
  transition: background .18s, color .18s, transform .18s;
}
.nav-item svg { width: 18px; height: 18px; flex: none; opacity: .8; transition: opacity .18s, filter .18s; }
.nav-item:hover { background: var(--surface-2); color: var(--text); transform: translateX(2px); }
.nav-item.active { color: var(--text); font-weight: 600; background: var(--brand-dim); }
.nav-item.active svg {
  opacity: 1; color: var(--holo-1);
  filter: drop-shadow(0 0 5px rgba(34, 216, 240, .7));
}
/* 激活指示：左侧全息竖条 */
.nav-item.active::before {
  content: ""; position: absolute; left: -14px; top: 18%; bottom: 18%; width: 3px;
  border-radius: 0 3px 3px 0; background: var(--brand-grad);
  box-shadow: 0 0 12px var(--brand-glow);
}
.nav-dot {
  width: 6px; height: 6px; border-radius: 50%; margin-left: auto;
  background: var(--err);
  animation: breath 1.6s ease-in-out infinite;
}

.sidebar-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.foot-row { display: flex; gap: 8px; width: 100%; justify-content: center; }
.foot-row .app-dl-link, .foot-row .donate-btn { flex: 1; justify-content: center; white-space: nowrap; }
.ver { font-size: 11px; color: var(--text-3); letter-spacing: .4px; font-family: var(--font-num); }
.app-dl-link {
  display: flex; align-items: center; gap: 7px; padding: 7px 10px;
  border-radius: 999px; border: 1px solid rgba(34, 216, 240, .4);
  color: var(--brand-2); background: var(--brand-dim);
  font-size: 12px; text-decoration: none; transition: all .18s;
}
.app-dl-link:hover { background: rgba(34, 216, 240, .2); color: var(--text); box-shadow: 0 0 14px rgba(34, 216, 240, .2); }
.app-dl-link svg { width: 14px; height: 14px; flex: none; }
.theme-toggle {
  width: 36px; height: 36px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); display: grid; place-items: center;
  transition: color .2s, border-color .2s, box-shadow .2s;
}
.theme-toggle:hover { color: var(--brand-2); border-color: rgba(34, 216, 240, .45); box-shadow: 0 0 12px rgba(34, 216, 240, .15); }
.theme-toggle svg { width: 16px; height: 16px; }
[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }
[data-theme="light"] .icon-moon { display: block; }

/* ==========================================================================
   页面：切换即「全息浮现」——上浮 + 轻度增亮
   ========================================================================== */
.page { display: none; }
.page.active { display: block; animation: page-holo .38s cubic-bezier(.2, .75, .25, 1); }
@keyframes page-holo {
  from { opacity: 0; transform: translateY(14px); filter: brightness(1.7) saturate(1.5); }
  60% { filter: brightness(1.16) saturate(1.15); }
  to { opacity: 1; transform: translateY(0); filter: none; }
}

/* 页面头：等宽眉标 + 扫描线 + 标题（带终端光标）+ 副注释 */
.page-head { margin-bottom: 26px; }
.page-head .eyebrow {
  font-family: var(--font-num); font-size: 10px; letter-spacing: 3px;
  color: var(--text-3); text-transform: uppercase; font-weight: 600;
  display: flex; align-items: center; gap: 10px; margin-bottom: 6px;
}
.page-head .eyebrow::before {
  content: ""; width: 22px; height: 2px;
  background: var(--brand-grad);
  box-shadow: 0 0 8px var(--brand-glow);
}
.page-head .eyebrow::after {
  content: ""; flex: 1; max-width: 190px; height: 1px;
  background: repeating-linear-gradient(90deg, var(--border) 0 5px, transparent 5px 10px);
}
.page-head h1 {
  font-size: 27px; font-weight: 800; letter-spacing: .5px;
  display: flex; align-items: baseline; gap: 2px;
}
/* 终端光标：标题后一小块闪烁光标，控制台脉搏 */
.page-head h1::after {
  content: ""; width: 10px; height: 22px; margin-left: 7px; align-self: center;
  background: var(--brand-grad);
  box-shadow: 0 0 10px var(--brand-glow);
  animation: caret-blink 1.15s steps(2, start) infinite;
}
@keyframes caret-blink { to { visibility: hidden; } }
.page-head .sub { color: var(--text-2); margin-top: 4px; font-size: 13.5px; }

.section-head {
  display: flex; align-items: center; justify-content: space-between;
  margin: 30px 0 14px;
}
.section-head h2 {
  font-size: 15px; font-weight: 700; letter-spacing: .3px;
  display: flex; align-items: center; gap: 9px;
}
/* 节标题前的 HUD 角标 */
.section-head h2::before {
  content: ""; width: 8px; height: 8px; flex: none;
  background: linear-gradient(135deg, var(--holo-1) 50%, transparent 50%);
  box-shadow: 0 0 6px rgba(34, 216, 240, .55);
}
.section-actions { display: flex; align-items: center; gap: 14px; }

/* ==========================================================================
   卡片：切角玻璃 + 四角 HUD 括弧 + hover 辉光扫描
   ========================================================================== */
.glass {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow-1);
  overflow: hidden;
}
/* 顶部全息发丝线 */
.glass::before {
  content: ""; position: absolute; top: 0; left: 12%; right: 12%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(34, 216, 240, .6), transparent);
  pointer-events: none; z-index: 1;
}
.glass-strong {
  position: relative;
  background: var(--surface-solid);
  border: 1px solid var(--border-hi);
  border-radius: 14px;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: var(--shadow-2);
}

/* 切角变体：重大交互卡（输入卡/解锁卡/授权卡）可加 .holo-cut 切去对角 */
.holo-cut {
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  border-radius: 0;
}
.holo-cut::before { left: 8%; right: 8%; }

/* hover 辉光扫描：一道光从左扫到右（通用交互反馈） */
.scan-hover { position: relative; }
.scan-hover::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  background: linear-gradient(105deg, transparent 42%, rgba(34, 216, 240, .08) 50%, transparent 58%);
  background-size: 260% 100%; background-position: 120% 0;
  transition: background-position .7s ease;
}
.scan-hover:hover::after { background-position: -60% 0; }

/* ==========================================================================
   数据载入浮现：renderReveal 挂 .rv，逐条延迟入网
   ========================================================================== */
.rv { animation: rv-in .34s cubic-bezier(.2, .75, .25, 1) backwards; animation-delay: var(--rv-d, 0ms); }
@keyframes rv-in {
  from { opacity: 0; transform: translateY(10px); filter: brightness(1.5); }
  to { opacity: 1; transform: none; filter: none; }
}

/* ==========================================================================
   按钮：主按钮全息填充 + 流光；幽灵按钮描边 + hover 点亮
   ========================================================================== */
.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border: 1px solid transparent; border-radius: 8px; cursor: pointer;
  font: inherit; font-weight: 600; padding: 9px 16px;
  transition: transform .15s, box-shadow .22s, background .2s, border-color .2s, opacity .2s, color .2s;
  white-space: nowrap;
}
.btn svg { width: 15px; height: 15px; }
.btn:active { transform: scale(.96); }

/* 全息渐变只属于主按钮：整个界面最亮的可点目标 */
.btn-primary {
  overflow: hidden;
  background: var(--brand-grad); color: #03222a;
  box-shadow: 0 0 20px var(--brand-glow), inset 0 1px 0 rgba(255, 255, 255, .4);
}
.btn-primary::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .3) 50%, transparent 70%);
  background-size: 220% 100%; background-position: 130% 0;
  transition: background-position .55s ease;
  pointer-events: none;
}
.btn-primary:hover {
  box-shadow: 0 0 30px rgba(34, 216, 240, .55), inset 0 1px 0 rgba(255, 255, 255, .4);
  transform: translateY(-1px);
}
.btn-primary:hover::after { background-position: -40% 0; }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; transform: none; }

.btn-ghost {
  background: var(--surface); color: var(--text-2); border-color: var(--border);
}
.btn-ghost:hover {
  color: var(--brand-2); border-color: rgba(34, 216, 240, .5);
  background: var(--brand-dim);
  box-shadow: 0 0 14px rgba(34, 216, 240, .12);
}
.btn-danger { background: rgba(255, 93, 115, .1); color: var(--err); border-color: rgba(255, 93, 115, .35); }
.btn-danger:hover { background: rgba(255, 93, 115, .2); box-shadow: 0 0 14px rgba(255, 93, 115, .15); }
.btn-sm { padding: 5px 11px; font-size: 12.5px; border-radius: 7px; }

/* ==========================================================================
   徽章：平台品牌色编码 + 状态灯
   ========================================================================== */
.badge {
  display: inline-flex; align-items: center; padding: 1.5px 9px;
  border-radius: 999px; font-size: 11.5px; font-weight: 600; letter-spacing: .3px;
  border: 1px solid transparent; white-space: nowrap;
}
.badge-bilibili { color: #fb7299; background: rgba(251, 114, 153, .1); border-color: rgba(251, 114, 153, .3); }
.badge-douyin { color: #fe4d6f; background: rgba(254, 44, 85, .1); border-color: rgba(254, 44, 85, .3); }
.badge-kuaishou { color: #ff9b3d; background: rgba(255, 155, 61, .1); border-color: rgba(255, 155, 61, .3); }
.badge-xiaohongshu { color: #ff5170; background: rgba(255, 36, 66, .1); border-color: rgba(255, 36, 66, .3); }
.badge-generic, .badge-direct { color: var(--holo-1); background: rgba(34, 216, 240, .1); border-color: rgba(34, 216, 240, .3); }
[data-theme="light"] .badge-bilibili { color: #e0407a; }
[data-theme="light"] .badge-douyin { color: #e01341; }
[data-theme="light"] .badge-xiaohongshu { color: #e01338; }

/* 状态徽章：彩色信号灯 + 呼吸 */
.st {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500;
  padding: 2px 10px; border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.st::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor;
  box-shadow: 0 0 7px currentColor;
}
.st-pending { color: var(--text-2); background: var(--surface-2); }
.st-parsing, .st-working { color: var(--holo-1); background: rgba(34, 216, 240, .12); }
.st-parsing::before, .st-working::before { animation: breath 1.2s ease-in-out infinite; }
.st-downloading { color: var(--cyan); background: rgba(34, 216, 240, .1); }
.st-downloading::before, .st-pending::before { animation: breath 1.2s ease-in-out infinite; }
.st-processing { color: var(--warn); background: rgba(255, 194, 75, .1); }
.st-done { color: var(--ok); background: rgba(60, 230, 160, .1); }
.st-failed { color: var(--err); background: rgba(255, 93, 115, .1); }
.st-duplicate { color: var(--warn); background: rgba(255, 194, 75, .1); }
@keyframes breath { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }

/* ==========================================================================
   输入区：切角全息输入卡 + 焦点辉光
   ========================================================================== */
.input-card { padding: 20px; }
.input-row { display: flex; gap: 16px; }
#url-input {
  flex: 1; resize: vertical; min-height: 100px;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  background: var(--bg-2); color: var(--text);
  font: inherit; padding: 13px 15px; outline: none;
  transition: border-color .2s, box-shadow .2s;
  line-height: 1.7;
}
[data-theme="light"] #url-input { background: var(--surface-solid); border-color: var(--border); }
#url-input:focus { border-color: rgba(34, 216, 240, .55); box-shadow: 0 0 0 3px var(--focus), 0 0 18px rgba(34, 216, 240, .12); }
#url-input::placeholder { color: var(--text-3); }
.input-actions { display: flex; flex-direction: column; gap: 10px; justify-content: flex-start; }

.input-meta {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 14px; flex-wrap: wrap; gap: 10px;
}
.dir-select {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  color: var(--text-2); max-width: 60%;
}
.dir-select svg { width: 15px; height: 15px; flex: none; color: var(--holo-1); }
.dir-label {
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 12px; font-family: var(--font-num); letter-spacing: .2px;
}
#dir-select {
  position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%;
  color: var(--text); background-color: var(--surface-solid);
}
.quick-opts { display: flex; gap: 8px; flex-wrap: wrap; }

/* 选项胶囊：选中 = 点亮指示灯 */
.opt-chip {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  padding: 4px 12px; border-radius: 999px; font-size: 12.5px; color: var(--text-2);
  border: 1px solid var(--border); background: var(--surface);
  transition: color .2s, border-color .2s, background .2s, box-shadow .2s;
  user-select: none;
}
.opt-chip input { display: none; }
.opt-chip:hover { border-color: var(--border-hi); color: var(--text); }
.opt-chip:has(input:checked) {
  color: var(--brand-2); border-color: rgba(34, 216, 240, .55);
  background: var(--brand-dim);
  box-shadow: 0 0 12px rgba(34, 216, 240, .14), inset 0 0 8px rgba(34, 216, 240, .06);
}

/* ==========================================================================
   解析结果：全息数据行 + 封面微亮 hover
   ========================================================================== */
.parse-results { animation: page-holo .4s cubic-bezier(.2, .75, .25, 1); }
.parse-list { display: flex; flex-direction: column; gap: 9px; }
.parse-item {
  display: flex; gap: 14px; align-items: center; padding: 12px 14px;
  border-radius: var(--radius); border: 1px solid var(--border);
  background: var(--surface);
  transition: border-color .18s, background .18s, box-shadow .25s;
  animation: rv-in .3s cubic-bezier(.2, .75, .25, 1) backwards;
}
.parse-item:hover {
  border-color: rgba(34, 216, 240, .4); background: var(--surface-2);
  box-shadow: 0 0 0 1px rgba(34, 216, 240, .12), 0 0 22px rgba(34, 216, 240, .07);
}
.parse-item.error { border-color: rgba(255, 93, 115, .4); }
.parse-item .pcheck { width: 16px; height: 16px; accent-color: var(--holo-1); cursor: pointer; flex: none; }
.parse-cover {
  width: 106px; height: 62px; border-radius: 7px; object-fit: cover; flex: none;
  background: var(--surface-2); border: 1px solid var(--border);
  transition: filter .25s, border-color .2s;
}
.parse-item:hover .parse-cover { filter: brightness(1.14); border-color: rgba(34, 216, 240, .35); }
.parse-info { flex: 1; min-width: 0; }
.parse-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.parse-meta { display: flex; align-items: center; gap: 10px; color: var(--text-2); font-size: 12.5px; margin-top: 3px; flex-wrap: wrap; }
.parse-err { color: var(--err); font-size: 12.5px; margin-top: 3px; }

.check-all { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); cursor: pointer; font-size: 13px; }
.check-all input { accent-color: var(--holo-1); }

/* 批量型解析结果：主页 / 合集 / 分P 可展开子列表 */
.parse-item.batch { flex-direction: column; align-items: stretch; gap: 0; }
.parse-item.batch .parse-row { display: flex; gap: 14px; align-items: center; }
.parse-item.batch .expand-btn { flex: none; }
.children {
  margin-top: 10px; border-top: 1px dashed var(--border); padding-top: 8px;
  max-height: 380px; overflow-y: auto;
}
.child-section + .child-section { margin-top: 10px; }
.child-label {
  font-size: 12px; color: var(--text-3); font-weight: 600; letter-spacing: .3px;
  padding: 4px 2px 6px; font-family: var(--font-num);
}
.child-item {
  display: flex; align-items: center; gap: 10px; padding: 5px 6px;
  border-radius: 8px; cursor: pointer; font-size: 13px;
  transition: background .15s;
}
.child-item:hover { background: rgba(34, 216, 240, .07); }
.child-item .ccheck { width: 14px; height: 14px; accent-color: var(--holo-1); flex: none; }
.child-cover {
  width: 64px; height: 38px; border-radius: 5px; object-fit: cover; flex: none;
  background: var(--surface-2); border: 1px solid var(--border);
}
.child-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.child-idx { color: var(--brand-2); margin-right: 6px; }
.child-item .num { color: var(--text-3); font-size: 12px; flex: none; }
.coll-btn { margin-top: 8px; align-self: flex-start; }

/* ==========================================================================
   任务列表：数据轨道行 + 全息进度条（条纹流光 + 扫描头）
   ========================================================================== */
.task-summary { color: var(--text-2); font-size: 13px; }
.task-list { display: flex; flex-direction: column; gap: 9px; }
.task-item {
  padding: 13px 16px; border-radius: var(--radius); border: 1px solid var(--border);
  background: var(--surface); display: flex; flex-direction: column; gap: 9px;
  animation: rv-in .3s backwards;
  transition: border-color .18s, background .18s, box-shadow .22s;
}
.task-item.task-out { opacity: 0; transform: translateX(26px); transition: opacity .4s ease, transform .4s ease; }
.task-item.task-view { cursor: pointer; }
.task-item.task-view:hover {
  border-color: rgba(34, 216, 240, .45); background: var(--surface-2);
  box-shadow: 0 0 0 1px rgba(34, 216, 240, .14), 0 0 26px rgba(34, 216, 240, .08);
}
.task-top { display: flex; align-items: center; gap: 10px; }
.task-title {
  flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-weight: 600; font-size: 13.5px;
}
.task-author { color: var(--text-3); font-size: 12.5px; flex: none; }
.task-speed { color: var(--cyan); font-size: 12px; flex: none; text-shadow: 0 0 10px rgba(34, 216, 240, .4); }
.task-err { color: var(--err); font-size: 12.5px; }

/* 进度：全息能量条 + 流光扫过 */
.progress {
  height: 6px; border-radius: 999px; overflow: hidden;
  background: var(--surface-2); position: relative;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .35);
}
.progress-bar {
  height: 100%; border-radius: 999px;
  background: var(--brand-grad);
  box-shadow: 0 0 10px rgba(34, 216, 240, .5);
  position: relative; overflow: hidden;
  transition: width .5s cubic-bezier(.3, .7, .3, 1);
}
.progress-bar.indeterminate {
  width: 100% !important;
  background: transparent; box-shadow: none; position: relative;
}
.progress-bar.indeterminate::after {
  content: ""; position: absolute; inset: 0; border-radius: 999px;
  background: linear-gradient(90deg, transparent 0%,
              var(--holo-1) 30%, var(--holo-2) 55%, transparent 85%);
  opacity: .6;
  animation: slide 1.8s cubic-bezier(.45, .05, .55, .95) infinite;
}
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.progress-bar.striped::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .22) 50%, transparent 70%);
  background-size: 60px 100%;
  animation: shimmer 1.7s linear infinite;
}
@keyframes shimmer { from { background-position: -60px 0; } to { background-position: 200px 0; } }
.progress.ok .progress-bar { background: linear-gradient(90deg, #3ce6a0, #22b07a); box-shadow: 0 0 10px rgba(60, 230, 160, .45); }
.progress.err .progress-bar { background: linear-gradient(90deg, #ff5d73, #d93a50); box-shadow: 0 0 10px rgba(255, 93, 115, .4); width: 100% !important; }

/* ==========================================================================
   统计卡片：全息数据仪表行
   ========================================================================== */
.stat-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px;
  margin-bottom: 20px;
}
.stat-card {
  position: relative; padding: 16px 20px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface); overflow: hidden;
  transition: border-color .2s, box-shadow .25s;
  animation: rv-in .32s cubic-bezier(.2, .75, .25, 1) backwards;
}
.stat-card:hover { border-color: rgba(34, 216, 240, .35); box-shadow: var(--glow-card); }
.stat-card::before {
  content: ""; position: absolute; top: 0; left: 0; width: 34px; height: 2px;
  background: var(--brand-grad); box-shadow: 0 0 8px var(--brand-glow);
}
.stat-label { color: var(--text-2); font-size: 12.5px; display: flex; align-items: center; gap: 7px; }
.stat-label svg { width: 14px; height: 14px; opacity: .85; color: var(--holo-1); }
.stat-value {
  font-size: 26px; font-weight: 800; margin-top: 6px; letter-spacing: .3px;
  font-variant-numeric: tabular-nums;
  background: var(--brand-text-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  filter: drop-shadow(0 0 14px rgba(34, 216, 240, .25));
}
.stat-sub { color: var(--text-3); font-size: 12px; margin-top: 1px; }

/* ==========================================================================
   工具栏：控制台条
   ========================================================================== */
.toolbar { display: flex; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; align-items: center; }
.toolbar-spacer { flex: 1; }
.search-box {
  display: flex; align-items: center; gap: 8px; padding: 0 12px;
  border: 1px solid var(--border); border-radius: 9px; background: var(--surface);
  flex: 1; min-width: 180px; max-width: 320px;
  transition: border-color .2s, box-shadow .2s;
}
.search-box:focus-within {
  border-color: rgba(34, 216, 240, .55);
  box-shadow: 0 0 0 3px var(--focus), 0 0 16px rgba(34, 216, 240, .1);
}
.search-box svg { width: 15px; height: 15px; color: var(--holo-1); flex: none; }
.search-box input { border: 0; background: transparent; color: var(--text); font: inherit; padding: 9px 0; outline: none; width: 100%; }
.select, .field input, #sub-url {
  border: 1px solid var(--border); border-radius: 9px;
  background-color: var(--surface-solid); color: var(--text);
  font: inherit; padding: 8px 12px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.select:focus, .field input:focus, #sub-url:focus {
  border-color: rgba(34, 216, 240, .55);
  box-shadow: 0 0 0 3px var(--focus), 0 0 16px rgba(34, 216, 240, .1);
}
.select option, #dir-select option { background-color: var(--surface-solid); color: var(--text); }

/* ==========================================================================
   片库网格：全息片段墙 + 卡片入网浮现
   ========================================================================== */
.history-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(228px, 1fr)); gap: 13px; }
.group-block { display: block; margin-bottom: 6px; }
.group-head {
  display: flex; align-items: baseline; gap: 12px;
  margin: 18px 0 12px; padding-bottom: 9px;
  border-bottom: 1px solid var(--border);
}
.group-block:first-child .group-head { margin-top: 4px; }
.group-label { font-size: 14.5px; font-weight: 700; letter-spacing: .3px; }
.group-meta { color: var(--text-3); font-size: 12px; }
.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(228px, 1fr)); gap: 13px; }

.h-card {
  border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border);
  background: var(--surface); cursor: pointer;
  transition: transform .22s, border-color .2s, box-shadow .25s;
  animation: rv-in .34s cubic-bezier(.2, .75, .25, 1) backwards;
}
.history-grid.no-anim .h-card { animation: none; }
.h-card:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 216, 240, .45);
  box-shadow: var(--glow-card), 0 14px 34px rgba(0, 0, 0, .4);
}
.h-cover { position: relative; aspect-ratio: 16/9.5; background: var(--bg-2); overflow: hidden; }
.h-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s cubic-bezier(.2, .7, .3, 1), filter .3s; }
.h-card:hover .h-cover img { transform: scale(1.05); filter: brightness(1.08); }
.h-cover::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(2,6,14,.2) 0%, transparent 30%, transparent 66%, rgba(2,6,14,.38) 100%);
}
.h-dur {
  position: absolute; right: 7px; bottom: 7px; font-size: 11px;
  background: rgba(2, 8, 16, .7); color: var(--brand-2); padding: 1px 7px; border-radius: 5px;
  border: 1px solid rgba(34, 216, 240, .25);
  font-variant-numeric: tabular-nums;
  display: inline-flex; align-items: center; gap: 3px;
}
.h-status { position: absolute; left: 8px; top: 8px; }
.h-body { padding: 11px 13px 13px; }
.h-title {
  font-weight: 600; font-size: 13.5px; line-height: 1.45; height: 2.9em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.h-meta { display: flex; align-items: center; gap: 8px; margin-top: 7px; color: var(--text-2); font-size: 12px; }
.h-meta .author { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h-meta .size { margin-left: auto; flex: none; color: var(--text-3); font-variant-numeric: tabular-nums; }

/* 片库：收藏星 / 标签 / 批量管理 */
.h-fav { position: absolute; right: 8px; top: 8px; color: #ffd166; font-size: 15px; text-shadow: 0 1px 4px rgba(0, 0, 0, .5); }
.h-tags { display: flex; gap: 5px; margin-top: 6px; flex-wrap: wrap; }
.h-tag {
  font-size: 11px; color: var(--brand-2); background: var(--brand-dim);
  border: 1px solid rgba(34, 216, 240, .2);
  border-radius: 999px; padding: 1px 8px;
}
.h-card.managing { cursor: pointer; }
.h-card.sel { border-color: var(--holo-1); box-shadow: 0 0 0 1px var(--holo-1), 0 0 20px rgba(34, 216, 240, .2); }
.h-check {
  position: absolute; right: 8px; bottom: 8px; width: 22px; height: 22px;
  border-radius: 50%; border: 2px solid rgba(255, 255, 255, .8);
  background: rgba(2, 8, 16, .55); color: #fff; font-size: 13px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.h-check.on { background: var(--holo-1); border-color: var(--holo-1); color: #03222a; }
#btn-fav-filter.on, #btn-manage.on {
  color: var(--brand-2); border-color: rgba(34, 216, 240, .55); background: var(--brand-dim);
}
.manage-bar {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px; padding: 10px 16px;
  border-radius: 999px; z-index: 60; box-shadow: var(--shadow-2);
  animation: manage-in .3s cubic-bezier(.2, .8, .3, 1.15);
}
@keyframes manage-in { from { opacity: 0; transform: translate(-50%, 14px); } }
.manage-bar span { font-size: 13px; color: var(--text-2); }

/* 详情弹窗：标题行 / 收藏 / 标签编辑 */
.modal-title-row { display: flex; align-items: flex-start; gap: 10px; margin-top: 12px; }
.modal-title-row h3 { flex: 1; min-width: 0; margin: 0; }
.fav-btn {
  border: 1px solid var(--border); background: var(--surface); cursor: pointer;
  color: var(--text-3); font-size: 19px; line-height: 1; border-radius: 9px;
  padding: 4px 9px; transition: all .18s; flex: none;
}
.fav-btn:hover { color: #ffd166; border-color: #ffd166; }
.fav-btn.on { color: #ffd166; border-color: #ffd166; background: rgba(255, 209, 102, .1); box-shadow: 0 0 12px rgba(255, 209, 102, .18); }
.detail-tags { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 10px; }
.detail-tags-label { font-size: 12px; color: var(--text-3); }

/* 片库：列表视图 */
.h-list { display: flex; flex-direction: column; gap: 8px; }
.h-row {
  display: flex; align-items: center; gap: 12px; padding: 8px 12px;
  border-radius: 12px; border: 1px solid var(--border); background: var(--surface);
  transition: border-color .18s, background .18s, box-shadow .22s; cursor: pointer;
}
.h-row:hover {
  border-color: rgba(34, 216, 240, .35); background: var(--surface-2);
  box-shadow: 0 0 0 1px rgba(34, 216, 240, .1);
}
.h-row.sel { border-color: var(--holo-1); box-shadow: 0 0 0 1px var(--holo-1); }
.h-row-cover {
  width: 88px; height: 52px; border-radius: 7px; object-fit: cover; flex: none;
  background: var(--surface-2); border: 1px solid var(--border);
}
.h-row-main { flex: 1; min-width: 0; }
.h-row-title { font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h-fav-inline { color: #ffd166; }
.h-row-sub { display: flex; align-items: center; gap: 8px; margin-top: 4px; color: var(--text-2); font-size: 12px; flex-wrap: wrap; }
.h-row-side {
  display: flex; flex-direction: column; align-items: flex-end; gap: 2px;
  color: var(--text-3); font-size: 12px; flex: none; min-width: 86px;
}
.h-check-static {
  width: 20px; height: 20px; flex: none; border-radius: 50%;
  border: 2px solid var(--border-hi); color: #fff; font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.h-check-static.on { background: var(--holo-1); border-color: var(--holo-1); color: #03222a; }

.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 22px; }
.page-btn {
  min-width: 32px; height: 32px; padding: 0 8px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: inherit;
  font-variant-numeric: tabular-nums;
  transition: all .18s;
}
.page-btn:hover:not(:disabled) { color: var(--text); border-color: rgba(34, 216, 240, .45); }
.page-btn.cur { background: var(--brand-grad); color: #03222a; border-color: transparent; font-weight: 700; box-shadow: 0 0 12px rgba(34, 216, 240, .3); }
.page-btn:disabled { opacity: .4; cursor: default; }

/* ==========================================================================
   空状态 / 骨架
   ========================================================================== */
.empty {
  text-align: center; padding: 52px 20px; color: var(--text-3);
  border: 1px dashed var(--border); border-radius: var(--radius);
}
.empty svg { width: 42px; height: 42px; opacity: .5; margin-bottom: 10px; }
.empty p { font-size: 13.5px; }

.skeleton { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); background: var(--surface); }
.sk-cover { aspect-ratio: 16/9.5; }
.sk-line { height: 12px; border-radius: 6px; margin: 10px 13px; }
.sk-cover, .sk-line {
  background: linear-gradient(100deg, var(--surface-2) 40%, rgba(34, 216, 240, .08) 50%, var(--surface-2) 60%);
  background-size: 200% 100%;
  animation: sk 1.35s linear infinite;
}
@keyframes sk { from { background-position: 120% 0; } to { background-position: -80% 0; } }

/* ==========================================================================
   订阅：全息头像卡
   ========================================================================== */
.sub-add { display: flex; gap: 12px; padding: 14px 16px; margin-bottom: 20px; flex-wrap: wrap; align-items: center; }
#sub-url { flex: 1; min-width: 240px; }
.sub-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 13px; }
.sub-card {
  padding: 16px; border-radius: var(--radius); display: flex; gap: 13px; align-items: center;
  transition: border-color .2s, box-shadow .25s;
  animation: rv-in .3s cubic-bezier(.2, .75, .25, 1) backwards;
}
.sub-card:nth-child(2) { animation-delay: 40ms; }
.sub-card:nth-child(3) { animation-delay: 80ms; }
.sub-card:nth-child(4) { animation-delay: 120ms; }
.sub-card:hover { border-color: rgba(34, 216, 240, .35); box-shadow: var(--glow-card); }
.sub-avatar {
  width: 46px; height: 46px; border-radius: 50%; flex: none; object-fit: cover;
  border: 2px solid rgba(34, 216, 240, .35); background: var(--surface-2);
  box-shadow: 0 0 12px rgba(34, 216, 240, .15);
}
.sub-info { flex: 1; min-width: 0; }
.sub-name { font-weight: 600; display: flex; align-items: center; gap: 8px; }
.sub-meta { color: var(--text-3); font-size: 12px; margin-top: 3px; }
.sub-err { color: var(--err); font-size: 12px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sub-actions { display: flex; flex-direction: column; gap: 6px; }
.sub-paused { opacity: .55; }

/* ==========================================================================
   作者数据：全息档案卡 + 描边走近动画
   ========================================================================== */
#author-url {
  flex: 1; border: 1px solid transparent; border-radius: var(--radius-sm);
  background: var(--bg-2); color: var(--text);
  font: inherit; padding: 12px 15px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
[data-theme="light"] #author-url { background: var(--surface-solid); border-color: var(--border); }
#author-url:focus { border-color: rgba(34, 216, 240, .55); box-shadow: 0 0 0 3px var(--focus), 0 0 18px rgba(34, 216, 240, .12); }
#author-url::placeholder { color: var(--text-3); }

#author-panel { animation: page-holo .38s cubic-bezier(.2, .75, .25, 1); }

.author-head {
  position: relative; overflow: hidden;
  display: flex; align-items: center; gap: 18px; padding: 24px;
  margin-bottom: 14px; flex-wrap: wrap;
}
.author-head::before {
  content: ""; position: absolute; top: 0; left: 12%; right: 12%; height: 1px;
  background: var(--brand-grad);
  filter: drop-shadow(0 0 6px var(--brand-glow));
}
.author-avatar {
  width: 72px; height: 72px; border-radius: 50%; flex: none; object-fit: cover;
  border: 2px solid transparent;
  background: linear-gradient(var(--surface-solid), var(--surface-solid)) padding-box,
              var(--brand-grad) border-box;
  box-shadow: 0 0 22px rgba(34, 216, 240, .35);
}
.author-meta { flex: 1; min-width: 220px; }
.author-name-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.author-name { font-size: 19px; font-weight: 800; letter-spacing: .3px; }
.author-sign {
  color: var(--text-3); font-size: 12.5px; margin-top: 5px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.author-home {
  display: inline-block; color: var(--brand-2); font-size: 12px;
  margin-top: 4px; text-decoration: none; max-width: 100%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom;
}
.author-home:hover { text-decoration: underline; }
.author-stats { display: flex; margin-left: auto; }
.author-stat { text-align: center; padding: 2px 24px; }
.author-stat + .author-stat { border-left: 1px solid var(--border); }
.author-stat b {
  display: block; font-family: var(--font-num); font-size: 22px; font-weight: 800;
  line-height: 1.25;
  background: var(--brand-text-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 12px rgba(34, 216, 240, .3));
}
.author-stat span { font-size: 11.5px; color: var(--text-3); letter-spacing: 2px; }

.author-trend { margin-bottom: 14px; padding: 16px 18px; }
.author-trend-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.author-trend-delta { font-size: 13px; font-weight: 700; }
.author-trend-delta.up { color: var(--ok); text-shadow: 0 0 10px rgba(60, 230, 160, .4); }
.author-trend-delta.down { color: var(--err); }
.author-trend-chart { min-height: 90px; }
.author-trend-diff { margin-top: 10px; font-size: 12.5px; color: var(--text-2); }

.author-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 12px; flex-wrap: wrap;
}
.author-tabs { display: flex; gap: 7px; }
.author-tab {
  padding: 7px 20px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-2); cursor: pointer; font: inherit;
  font-size: 13px; transition: all .18s;
}
.author-tab:hover { color: var(--text); border-color: rgba(34, 216, 240, .4); }
.author-tab.active {
  background: var(--brand-grad); border-color: transparent; color: #03222a;
  font-weight: 700;
  box-shadow: 0 0 16px rgba(34, 216, 240, .4), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.author-tab.off { opacity: .38; cursor: not-allowed; }
.author-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.author-limit { font-size: 12px; padding: 6px 8px; }

.author-box { padding: 8px 10px; }
.author-note { font-size: 12px; color: var(--warn); padding: 10px 12px 2px; }
.author-rows {
  display: flex; flex-direction: column;
  max-height: 560px; overflow-y: auto; padding: 2px;
}
.author-row {
  display: flex; align-items: center; gap: 12px; padding: 9px 12px;
  border-radius: 10px; text-decoration: none; color: var(--text);
  transition: background .15s, transform .15s;
}
.author-row:hover { background: rgba(34, 216, 240, .08); transform: translateX(3px); }
.author-row > img {
  width: 58px; height: 36px; border-radius: 7px; object-fit: cover; flex: none;
  background: var(--surface-2); border: 1px solid var(--border);
}
.author-row > img.a-avatar { width: 36px; height: 36px; border-radius: 50%; }
.a-idx { font-family: var(--font-num); font-size: 11.5px; color: var(--text-3); min-width: 38px; text-align: right; flex: none; }
.a-title {
  flex: 1.4; min-width: 0; font-size: 13.5px; color: inherit; text-decoration: none;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
a.a-title:hover { color: var(--brand-2); }
.a-actions { display: flex; gap: 6px; flex: none; }

/* 作品预览弹窗 */
.author-pv-head { display: flex; align-items: flex-start; gap: 10px; }
.author-pv-head h3 { flex: 1; min-width: 0; margin: 0; }
.author-pv-meta { color: var(--text-3); font-size: 12.5px; margin-top: 2px; }
.author-pv-note { color: var(--brand-2); }
.author-preview {
  display: block; width: 100%; aspect-ratio: 16 / 9;
  border-radius: 12px; border: 1px solid var(--border);
  background: #000; margin-top: 14px;
}
.author-preview-img { object-fit: contain; background: var(--surface-2); }
.a-name { flex: .8; min-width: 0; font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.a-meta { color: var(--text-3); font-size: 12px; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: right; }
.a-sign { text-align: left; }
.a-uid { flex: none; font-family: var(--font-num); }
.author-foot {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  padding: 12px; border-top: 1px solid var(--border);
}
.author-count { font-family: var(--font-num); font-size: 12px; color: var(--text-3); }

@media (max-width: 720px) {
  .author-stats { margin-left: 0; width: 100%; justify-content: space-around; }
  .author-stat { padding: 2px 12px; }
  .a-sign { display: none; }
}

/* ==========================================================================
   工具箱：加工流水线
   ========================================================================== */
.notice {
  display: flex; align-items: center; gap: 10px; padding: 11px 16px;
  margin-bottom: 18px; color: var(--warn); font-size: 13px;
  border-color: rgba(255, 194, 75, .35) !important;
}
.notice svg { width: 17px; height: 17px; flex: none; }

.tools-layout { display: grid; grid-template-columns: 330px 1fr; gap: 16px; align-items: start; }
.tools-picker { padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.picker-tabs { display: flex; gap: 6px; }
.picker-tab {
  flex: 1; padding: 7px 0; border-radius: 9px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-2); cursor: pointer; font: inherit;
  font-size: 13px; transition: all .18s;
}
.picker-tab.active {
  color: var(--brand-2); border-color: rgba(34, 216, 240, .55); background: var(--brand-dim);
  box-shadow: 0 0 12px rgba(34, 216, 240, .12);
}
.tools-source-list { display: flex; flex-direction: column; gap: 6px; max-height: 420px; overflow-y: auto; }
.tools-upload { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tools-upload-name { font-size: 12px; color: var(--text-2); word-break: break-all; }

.tools-form { padding: 16px; }
.tool-kind-row { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.tool-group-label { font-size: 12px; color: var(--text-3); margin: 0 2px 0 6px; font-family: var(--font-num); }
.tool-group-label:first-child { margin-left: 0; }
.tool-chip {
  padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-2); cursor: pointer; font: inherit;
  font-size: 12.5px; transition: all .18s;
}
.tool-chip:hover { border-color: rgba(34, 216, 240, .4); color: var(--text); }
.tool-chip.active {
  color: #03222a; background: var(--brand-grad); border-color: transparent; font-weight: 700;
  box-shadow: 0 0 14px rgba(34, 216, 240, .35);
}
.tool-params {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 11px 12px; margin-top: 14px;
}
.tool-params .field-inline {
  display: flex; flex-direction: column; align-items: stretch; gap: 6px;
  font-size: 12px; color: var(--text-3); letter-spacing: .3px;
}
.tool-params .field-inline:has(input:disabled) { opacity: .55; }
.tool-params input, .tool-params select {
  width: 100%; max-width: none; box-sizing: border-box;
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--bg-2); color: var(--text); font: inherit; font-size: 13px;
  padding: 8px 11px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
[data-theme="light"] .tool-params input,
[data-theme="light"] .tool-params select { background: var(--surface-solid); }
.tool-params input:focus, .tool-params select:focus {
  border-color: rgba(34, 216, 240, .55); box-shadow: 0 0 0 3px var(--focus);
}
.tool-run-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--border);
}
.tool-src-tip { font-size: 12.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60%; }

.tool-jobs { display: flex; flex-direction: column; gap: 9px; margin-top: 4px; }
.tool-job { padding: 12px 14px; transition: border-color .2s, box-shadow .22s; }
.tool-job:hover { border-color: rgba(34, 216, 240, .3); box-shadow: 0 0 0 1px rgba(34, 216, 240, .08); }
.tj-head { display: flex; align-items: center; gap: 10px; }
.tj-kind { font-weight: 600; font-size: 13.5px; }
.tj-time { color: var(--text-3); font-size: 12px; }
.tj-actions { margin-left: auto; display: flex; gap: 6px; }
.tool-job .progress { margin-top: 10px; }
.tool-job .task-err { margin-top: 8px; }

/* ==========================================================================
   搬运工作台
   ========================================================================== */
.repost-layout { display: grid; grid-template-columns: 300px 1fr; gap: 14px; align-items: start; }
.repost-picker { padding: 12px; }
.repost-video-list { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; max-height: 460px; overflow-y: auto; }
.rp-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px;
  border-radius: 9px; cursor: pointer; border: 1px solid transparent;
  transition: background .15s, border-color .15s, transform .15s;
}
.rp-item:hover { background: rgba(34, 216, 240, .07); transform: translateX(2px); }
.rp-item.sel { background: var(--brand-dim); border-color: rgba(34, 216, 240, .5); }
.rp-item.missing { opacity: .45; cursor: not-allowed; }
.rp-thumb { width: 52px; height: 34px; border-radius: 6px; object-fit: cover; flex: none; background: var(--surface-2); border: 1px solid var(--border); }
.rp-info { flex: 1; min-width: 0; }
.rp-title { font-size: 12.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-meta { font-size: 11px; color: var(--text-3); margin-top: 1px; font-family: var(--font-num); }

.repost-video-card { padding: 14px 16px; margin-bottom: 13px; }
.repost-video-card .rv-title { font-weight: 600; font-size: 15px; }
.repost-video-card .rv-desc {
  color: var(--text-2); font-size: 13px; margin-top: 8px; white-space: pre-wrap;
  max-height: 90px; overflow-y: auto; line-height: 1.7;
}

.repost-gen { padding: 16px 18px; }
.gen-opts { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.field-inline { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; color: var(--text-2); }
#gen-result { margin-top: 16px; animation: page-holo .34s; }
#gen-desc {
  width: 100%; border: 1px solid var(--border); border-radius: 9px;
  background: var(--bg-2); color: var(--text); font: inherit;
  padding: 10px 13px; outline: none; resize: vertical; line-height: 1.7;
  transition: border-color .2s, box-shadow .2s;
}
[data-theme="light"] #gen-desc { background: var(--surface-solid); }
#gen-desc:focus { border-color: rgba(34, 216, 240, .55); box-shadow: 0 0 0 3px var(--focus); }
.tag-editor { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 11px; border-radius: 999px; font-size: 12.5px;
  background: var(--brand-dim); color: var(--brand-2); border: 1px solid rgba(34, 216, 240, .3);
}
.tag-chip .tag-x { cursor: pointer; color: var(--text-3); font-size: 13px; }
.tag-chip .tag-x:hover { color: var(--err); }
.tag-add {
  border: 1px dashed var(--border-hi); background: none; color: var(--text-3);
  padding: 3px 11px; border-radius: 999px; font: inherit; font-size: 12.5px; cursor: pointer;
}
.tag-add:hover { color: var(--text); }
.gen-actions { display: flex; gap: 10px; margin-top: 14px; align-items: center; flex-wrap: wrap; }

/* 快捷加工区 */
.quick-tools {
  display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
  margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--border);
}
.quick-tools-label {
  font-size: 10.5px; font-weight: 600; letter-spacing: 2px; font-family: var(--font-num);
  color: var(--text-3); text-transform: uppercase; margin-right: 2px;
}
.quick-tools-hint { font-size: 11.5px; color: var(--text-3); margin-left: auto; }

.repost-history { display: flex; flex-direction: column; gap: 8px; }
.rh-item {
  padding: 11px 15px; border-radius: var(--radius); border: 1px solid var(--border);
  background: var(--surface); display: flex; align-items: center; gap: 12px;
  transition: border-color .18s;
}
.rh-item:hover { border-color: rgba(34, 216, 240, .3); }
.rh-title { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rh-desc { flex: 2; min-width: 0; color: var(--text-2); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rh-time { color: var(--text-3); font-size: 11.5px; flex: none; font-family: var(--font-num); }
.rh-copy { flex: none; }

/* ==========================================================================
   设置：控制台面板组
   ========================================================================== */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.setting-group { padding: 20px 22px; }
.setting-group h3 {
  font-size: 15px; margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.setting-group h3::before {
  content: ""; width: 8px; height: 8px; flex: none;
  background: linear-gradient(135deg, var(--holo-1) 50%, transparent 50%);
  box-shadow: 0 0 6px rgba(34, 216, 240, .55);
}
.tag {
  font-size: 11px; font-weight: 500; color: var(--text-3);
  border: 1px solid var(--border); padding: 1px 8px; border-radius: 999px;
}
.field { margin-bottom: 14px; flex: 1; }
.field label { display: block; font-size: 12.5px; color: var(--text-2); margin-bottom: 6px; font-weight: 500; }
.field input { width: 100%; }
.field-row { display: flex; gap: 14px; }
.hint { color: var(--text-3); font-size: 12px; margin-top: 5px; }
.settings-save { margin-top: 20px; display: flex; align-items: center; gap: 12px; }
.saved-tip { color: var(--ok); font-size: 13px; opacity: 0; transition: opacity .3s; }
.saved-tip.show { opacity: 1; }

/* 自动规则 */
.rule-add { display: flex; flex-direction: column; gap: 12px; margin-bottom: 6px; }
.rule-match-row { display: flex; gap: 8px; }
.rule-match-row select { flex: none; width: 130px; }
.rule-match-row input { flex: 1; }
.rule-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.rule-list { display: flex; flex-direction: column; gap: 9px; margin-top: 10px; }
.rule-card { display: flex; align-items: center; gap: 12px; padding: 11px 14px; }
.rule-card.off { opacity: .55; }
.rule-info { flex: 1; min-width: 0; }
.rule-name { font-weight: 600; font-size: 13.5px; }
.rule-meta { display: flex; align-items: center; gap: 6px; margin-top: 5px; flex-wrap: wrap; color: var(--text-3); font-size: 12px; }
.rule-meta .act { color: var(--cyan); }
.rule-ops { display: flex; gap: 6px; flex: none; }

/* 账号 chip */
.user-chip {
  display: flex; align-items: center; gap: 6px; max-width: 100%;
  padding: 5px 12px; border-radius: 999px; border: 1px solid rgba(34, 216, 240, .3);
  background: var(--brand-dim); color: var(--brand-2); font: inherit; font-size: 12px;
}
.user-chip svg { width: 13px; height: 13px; flex: none; }
.user-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-line { display: flex; align-items: center; gap: 10px; }
.account-line b { font-size: 14px; }
#form-account .opt-chip input { display: none; }

/* ==========================================================================
   管理统计面板
   ========================================================================== */
.stat-unlock {
  position: relative; max-width: 420px; margin: 9vh auto 0; padding: 38px 34px 30px;
  text-align: center; overflow: hidden;
}
.stat-unlock::before {
  content: ""; position: absolute; top: 0; left: 16%; right: 16%; height: 1px;
  background: var(--brand-grad);
  filter: drop-shadow(0 0 6px var(--brand-glow));
}
.unlock-icon {
  width: 54px; height: 54px; margin: 0 auto 14px; border-radius: 14px;
  display: grid; place-items: center; color: var(--brand-2);
  background: var(--brand-dim);
  border: 1px solid rgba(34, 216, 240, .35);
  box-shadow: 0 0 0 5px rgba(34, 216, 240, .06), 0 0 22px rgba(34, 216, 240, .28);
  animation: unlock-glow 3s ease-in-out infinite;
}
@keyframes unlock-glow {
  0%, 100% { box-shadow: 0 0 0 5px rgba(34, 216, 240, .06), 0 0 22px rgba(34, 216, 240, .28); }
  50% { box-shadow: 0 0 0 7px rgba(34, 216, 240, .1), 0 0 34px rgba(34, 216, 240, .45); }
}
.unlock-icon svg { width: 22px; height: 22px; }
.unlock-title { font-size: 16.5px; font-weight: 800; }
.unlock-hint { color: var(--text-2); font-size: 12.5px; margin: 6px 0 20px; }
.unlock-row {
  display: flex; gap: 4px; padding: 4px;
  border: 1px solid var(--border); border-radius: 11px; background: var(--bg-2);
  transition: border-color .2s, box-shadow .2s;
}
.unlock-row:focus-within {
  border-color: rgba(34, 216, 240, .55); box-shadow: 0 0 0 3px var(--focus), 0 0 18px rgba(34, 216, 240, .12);
}
.unlock-row input {
  flex: 1; min-width: 0; border: 0; background: transparent;
  padding: 8px 12px; outline: none; color: var(--text); font: inherit;
}
.unlock-row input::placeholder { color: var(--text-3); }
.unlock-row .btn { flex: none; border-radius: 8px; padding: 8px 20px; }

.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px; margin-top: 14px;
}
.stats-card { padding: 16px 18px; }
.stats-card.wide { grid-column: 1 / -1; }
.stats-card-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; }
.stats-card-head h3 { font-size: 14px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.stats-card-head h3::before {
  content: ""; width: 6px; height: 6px; flex: none;
  background: linear-gradient(135deg, var(--holo-1) 50%, transparent 50%);
}
.stats-card-head .num { font-size: 12px; color: var(--text-3); }

.chart { width: 100%; height: auto; display: block; }
.chart .axis { fill: var(--text-3); font-size: 9px; font-family: inherit; }
.chart .axis.peak { font-size: 10px; font-weight: 700; fill: var(--text-2); }
.chart .grid { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 4; }
.chart .grid.base { stroke-dasharray: none; opacity: .8; }
.chart-empty { text-align: center; color: var(--text-3); font-size: 13px; padding: 28px 0; }

.hours-grid { display: flex; gap: 3px; align-items: flex-end; height: 130px; padding-top: 6px; }
.hour-col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; }
.hour-bar { width: 100%; border-radius: 3px 3px 0 0; min-height: 3px; opacity: .85; }
.hour-label { font-size: 9.5px; color: var(--text-3); margin-top: 4px; }

.dist-list { display: flex; flex-direction: column; gap: 9px; }
.dist-row { display: grid; grid-template-columns: 110px 1fr 44px; gap: 10px; align-items: center; font-size: 12.5px; }
.dist-k { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); }
.dist-bar { height: 7px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.dist-bar i { display: block; height: 100%; border-radius: 4px; opacity: .85; box-shadow: 0 0 6px rgba(34, 216, 240, .3); }
.dist-row b { text-align: right; color: var(--text-3); font-weight: 600; }

.donut-flex { display: flex; align-items: center; gap: 22px; }
.donut-svg { width: 132px; height: 132px; flex: none; }
.donut-num { fill: var(--text); font-size: 7px; font-weight: 700; }
.donut-sub { fill: var(--text-3); font-size: 3px; }
.legend { flex: 1; display: flex; flex-direction: column; gap: 7px; }
.legend-row { display: grid; grid-template-columns: 12px 1fr 40px 40px; gap: 8px; align-items: center; font-size: 12.5px; }
.legend-row i { width: 10px; height: 10px; border-radius: 3px; }
.legend-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); }
.legend-row b { text-align: right; }
.legend-row .pct { color: var(--text-3); font-weight: 400; }

.table-wrap { overflow-x: auto; }
.stats-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.stats-table th {
  text-align: left; color: var(--text-3); font-weight: 600; padding: 6px 10px;
  border-bottom: 1px solid var(--border); white-space: nowrap;
  font-family: var(--font-num); font-size: 11px; letter-spacing: 1px;
}
.stats-table td { padding: 7px 10px; border-bottom: 1px solid var(--border); color: var(--text-2); }
.stats-table tr:last-child td { border-bottom: 0; }
.stats-table tr { transition: background .15s; }
.stats-table tbody tr:hover { background: rgba(34, 216, 240, .05); }
.stats-table .err-cell { max-width: 380px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--err); }

/* ==========================================================================
   弹窗：全息舱门（玻璃罩 + 舱体展开）
   ========================================================================== */
.modal-mask {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(2, 5, 12, .68); backdrop-filter: blur(8px);
  display: grid; place-items: center; padding: 24px;
  animation: fadein .2s ease;
}
.modal-mask[hidden] { display: none; }
@keyframes fadein { from { opacity: 0; } }
.modal {
  position: relative;
  width: min(760px, 100%); max-height: 86vh; overflow-y: auto; padding: 28px 30px;
  animation: modal-in .32s cubic-bezier(.2, .85, .3, 1.1);
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(18px) scale(.97); filter: brightness(1.6); }
}
.modal h3 { font-size: 17px; line-height: 1.5; padding-right: 30px; }
.modal-close {
  position: absolute; right: 16px; top: 14px; width: 30px; height: 30px;
  border-radius: 8px; border: 0; cursor: pointer; background: var(--surface-2);
  color: var(--text-2); display: grid; place-items: center; font-size: 16px;
  transition: all .18s;
}
.modal-close:hover { color: var(--text); background: rgba(255, 93, 115, .15); }
.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 18px; margin-top: 14px; }
.kv { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; padding: 7px 0; border-bottom: 1px dashed var(--border); }
.kv b { color: var(--text-2); font-weight: 500; flex: none; }
.kv span { text-align: right; word-break: break-all; }
.modal-actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.modal-raw { margin-top: 12px; }
.modal-raw summary { cursor: pointer; color: var(--text-2); font-size: 12.5px; }
.modal-raw pre {
  margin-top: 8px; padding: 12px; border-radius: 9px; font-size: 11.5px;
  background: var(--bg-2); border: 1px solid var(--border);
  max-height: 240px; overflow: auto; color: var(--text-2); line-height: 1.5;
}

/* 预览 */
.modal-cover {
  width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius);
  margin: 14px 0 16px; border: 1px solid var(--border); cursor: zoom-in;
  transition: box-shadow .25s, border-color .2s;
}
.modal-cover:hover { box-shadow: 0 0 0 3px var(--focus), 0 0 26px rgba(34, 216, 240, .16); border-color: rgba(34, 216, 240, .4); }
.preview-video {
  width: 100%; max-height: 380px; border-radius: var(--radius); margin: 14px 0 6px;
  background: #000; border: 1px solid var(--border); outline: none; display: block;
}
.preview-audio { width: 100%; margin: 12px 0 4px; }
.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 0 6px; }
.gallery-item {
  position: relative; aspect-ratio: 1; border-radius: 9px; overflow: hidden;
  cursor: zoom-in; border: 1px solid var(--border); background: var(--surface-2);
  transition: transform .18s, border-color .18s, box-shadow .22s;
}
.gallery-item:hover { transform: translateY(-2px) scale(1.02); border-color: rgba(34, 216, 240, .45); box-shadow: 0 0 18px rgba(34, 216, 240, .14); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-item .g-idx {
  position: absolute; right: 5px; bottom: 5px; font-size: 10.5px;
  background: rgba(2, 8, 16, .65); color: #fff; padding: 0 6px; border-radius: 5px;
  font-variant-numeric: tabular-nums;
}
.preview-hint { display: flex; align-items: center; gap: 6px; color: var(--text-3); font-size: 12px; margin-bottom: 10px; }

/* 详情文案 / 评论 */
.desc-block {
  margin-top: 14px; padding: 13px 15px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
}
.desc-label {
  font-family: var(--font-num);
  font-size: 11px; color: var(--text-3); font-weight: 600; letter-spacing: 2px; margin-bottom: 7px;
  display: flex; align-items: center; gap: 7px; text-transform: uppercase;
}
.desc-label::before { content: ""; width: 3px; height: 12px; border-radius: 2px; background: var(--brand-grad); box-shadow: 0 0 6px var(--brand-glow); }
.desc-text { font-size: 13px; color: var(--text-2); line-height: 1.75; white-space: pre-wrap; word-break: break-word; max-height: 180px; overflow-y: auto; }
.comments-block { margin-top: 12px; }
.comments-block summary {
  cursor: pointer; color: var(--text-2); font-size: 13px; font-weight: 600;
  padding: 9px 14px; border-radius: 9px; background: var(--surface);
  border: 1px solid var(--border); user-select: none;
  transition: color .2s, border-color .2s;
}
.comments-block summary:hover { color: var(--text); border-color: rgba(34, 216, 240, .4); }
.comment-list { margin-top: 8px; display: flex; flex-direction: column; gap: 8px; max-height: 320px; overflow-y: auto; padding-right: 2px; }
.comment-item { padding: 10px 13px; border-radius: 9px; background: var(--surface); border: 1px solid var(--border); }
.comment-head { display: flex; align-items: baseline; gap: 10px; }
.comment-user { font-size: 12.5px; font-weight: 600; color: var(--cyan); }
.comment-meta { font-size: 11.5px; color: var(--text-3); margin-left: auto; }
.comment-text { font-size: 13px; color: var(--text-2); margin-top: 4px; line-height: 1.6; word-break: break-word; }

/* ==========================================================================
   灯箱：全屏沉浸
   ========================================================================== */
.lightbox {
  position: fixed; inset: 0; z-index: 150;
  background: rgba(1, 4, 10, .92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  display: grid; place-items: center;
  animation: fadein .2s ease;
}
.lightbox[hidden] { display: none; }
.lb-stage { max-width: min(92vw, 1200px); max-height: 86vh; display: flex; align-items: center; justify-content: center; }
.lb-stage img {
  max-width: 92vw; max-height: 86vh; border-radius: 10px;
  box-shadow: 0 20px 80px rgba(0, 0, 0, .6), 0 0 40px rgba(34, 216, 240, .08);
  animation: lbzoom .26s cubic-bezier(.2, .8, .3, 1.1);
}
@keyframes lbzoom { from { opacity: 0; transform: scale(.94); } }
.lb-stage video {
  max-width: 92vw; max-height: 86vh; border-radius: 12px;
  background: #000; box-shadow: 0 20px 80px rgba(0, 0, 0, .6); outline: none;
}
.lb-close, .lb-nav {
  position: fixed; z-index: 2; border: 1px solid rgba(148, 196, 255, .18);
  background: rgba(148, 196, 255, .07); color: #e8eefb; cursor: pointer;
  display: grid; place-items: center; backdrop-filter: blur(8px);
  transition: background .2s, border-color .2s;
}
.lb-close:hover, .lb-nav:hover { background: rgba(34, 216, 240, .16); border-color: rgba(34, 216, 240, .45); }
.lb-close { top: 18px; right: 20px; width: 38px; height: 38px; border-radius: 10px; font-size: 15px; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 44px; height: 64px; font-size: 26px; border-radius: 12px; }
.lb-prev { left: 18px; }
.lb-next { right: 18px; }
.lb-caption {
  position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
  color: rgba(232, 238, 251, .75); font-size: 13px; max-width: 80vw;
  text-align: center; text-shadow: 0 1px 6px rgba(0, 0, 0, .8);
  font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   Toast：信号弹片
   ========================================================================== */
#toast-root { position: fixed; right: 20px; top: 20px; z-index: 200; display: flex; flex-direction: column; gap: 10px; max-width: 340px; }
.toast {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 16px; border-radius: 11px; font-size: 13.5px;
  background: var(--surface-solid); border: 1px solid var(--border-hi);
  box-shadow: var(--shadow-2);
  animation: toastin .3s cubic-bezier(.2, .9, .3, 1.2);
}
@keyframes toastin { from { opacity: 0; transform: translateX(30px); } }
.toast.out { opacity: 0; transform: translateX(30px); transition: all .3s; }
.toast .t-icon { width: 17px; height: 17px; flex: none; margin-top: 1px; }
.toast .t-body { flex: 1; min-width: 0; }
.t-action {
  flex: none; border: 1px solid rgba(255, 209, 102, .5); background: rgba(255, 209, 102, .1);
  color: #ffd166; border-radius: 999px; font: inherit; font-size: 12px;
  padding: 4px 12px; cursor: pointer; transition: all .18s; white-space: nowrap;
}
.t-action:hover { background: rgba(255, 209, 102, .22); }
.toast.ok { border-left: 3px solid var(--ok); box-shadow: inset 6px 0 14px -8px rgba(60, 230, 160, .4), var(--shadow-2); }
.toast.ok .t-icon { color: var(--ok); }
.toast.err { border-left: 3px solid var(--err); box-shadow: inset 6px 0 14px -8px rgba(255, 93, 115, .4), var(--shadow-2); }
.toast.err .t-icon { color: var(--err); }
.toast.warn { border-left: 3px solid var(--warn); box-shadow: inset 6px 0 14px -8px rgba(255, 194, 75, .4), var(--shadow-2); }
.toast.warn .t-icon { color: var(--warn); }

/* ==========================================================================
   通知中心：铃铛 + 抽屉
   ========================================================================== */
.topbar { display: flex; align-items: center; justify-content: space-between; }
.bell {
  position: relative; border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); width: 34px; height: 34px; border-radius: 10px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all .18s; flex: none;
}
.bell:hover { color: var(--brand-2); border-color: rgba(34, 216, 240, .45); box-shadow: 0 0 12px rgba(34, 216, 240, .14); }
.bell svg { width: 17px; height: 17px; }
.bell-badge {
  position: absolute; top: -6px; right: -6px; min-width: 17px; height: 17px;
  border-radius: 999px; background: var(--err); color: #fff; font-size: 10.5px;
  font-weight: 700; display: flex; align-items: center; justify-content: center;
  padding: 0 4px; font-style: normal;
  box-shadow: 0 0 10px rgba(255, 93, 115, .5);
}
.notif-mask { position: fixed; inset: 0; z-index: 90; }
.notif-mask[hidden], .notif-drawer[hidden], .manage-bar[hidden] { display: none; }
.notif-drawer {
  position: fixed; top: 16px; right: 16px; bottom: 16px; width: 340px;
  z-index: 100; display: flex; flex-direction: column; overflow: hidden;
  animation: toastin .25s ease;
}
.notif-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--border); font-weight: 700;
}
.notif-list { flex: 1; overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.notif-item {
  display: flex; gap: 10px; padding: 10px 12px; border-radius: 10px;
  border: 1px solid transparent;
  transition: background .18s, border-color .18s;
}
.notif-item.unread { background: var(--brand-dim); border-color: rgba(34, 216, 240, .22); }
.notif-icon { flex: none; font-size: 15px; }
.notif-body { flex: 1; min-width: 0; }
.notif-title { font-size: 13px; font-weight: 600; }
.notif-text { font-size: 12px; color: var(--text-2); margin-top: 2px; word-break: break-all; }
.notif-time { font-size: 11px; color: var(--text-3); margin-top: 4px; }

/* ==========================================================================
   教程页
   ========================================================================== */
.guide-toc {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px;
  position: sticky; top: 14px; z-index: 20;
}
.toc-chip {
  padding: 5px 14px; border-radius: 999px; font-size: 12.5px;
  border: 1px solid var(--border); background: var(--surface-solid);
  color: var(--text-2); text-decoration: none; transition: all .18s;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.toc-chip:hover { color: var(--brand-2); border-color: rgba(34, 216, 240, .5); box-shadow: 0 0 12px rgba(34, 216, 240, .12); }

.guide-body { display: flex; flex-direction: column; gap: 16px; max-width: 980px; }
.guide-sec { padding: 22px 24px; scroll-margin-top: 70px; }
.guide-sec h2 { font-size: 17px; font-weight: 800; margin-bottom: 14px; display: flex; align-items: center; gap: 9px; }
.guide-sec h2::before {
  content: ""; width: 8px; height: 8px; flex: none;
  background: linear-gradient(135deg, var(--holo-1) 50%, transparent 50%);
  box-shadow: 0 0 6px rgba(34, 216, 240, .55);
}
.guide-sec h4 { font-size: 14px; font-weight: 700; margin-bottom: 6px; }
.guide-sec p, .guide-sec li { font-size: 13.5px; color: var(--text-2); line-height: 1.75; }
.guide-sec ul { padding-left: 18px; display: flex; flex-direction: column; gap: 6px; margin: 8px 0; }
.guide-sec b { color: var(--text); font-weight: 600; }
.guide-sec code {
  font-family: var(--font-num); font-size: 11.5px; color: var(--brand-2);
  background: var(--brand-dim); border: 1px solid rgba(34, 216, 240, .18);
  border-radius: 5px; padding: 1px 6px;
}
.guide-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.guide-cols h4 { padding-bottom: 6px; border-bottom: 1px dashed var(--border); }

.guide-steps { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.g-step { display: flex; gap: 13px; align-items: flex-start; }
.g-no {
  width: 26px; height: 26px; border-radius: 8px; flex: none;
  display: grid; place-items: center; font-weight: 800; font-size: 13px;
  font-family: var(--font-num); color: #03222a;
  background: var(--brand-grad); box-shadow: 0 0 12px rgba(34, 216, 240, .4);
}
.g-step h4 { margin: 2px 0 3px; }
.g-step p { font-size: 13px; }

.guide-shot { margin: 16px 0; }
.guide-shot img {
  width: 100%; border-radius: 10px; border: 1px solid var(--border);
  cursor: zoom-in; display: block;
  transition: border-color .2s, box-shadow .25s;
}
.guide-shot img:hover { border-color: rgba(34, 216, 240, .45); box-shadow: 0 0 24px rgba(34, 216, 240, .1); }
.guide-shot figcaption {
  font-size: 12px; color: var(--text-3); margin-top: 7px; text-align: center;
  font-family: var(--font-num);
}

.guide-tip {
  margin-top: 12px; padding: 9px 13px; border-radius: 9px;
  background: rgba(34, 216, 240, .06); border: 1px solid rgba(34, 216, 240, .22);
  font-size: 12.5px !important; color: var(--text-2);
}
.guide-donate { text-align: center; }
.guide-donate p { max-width: 520px; margin: 0 auto 16px; }
.guide-donate img {
  width: 168px; height: 168px; object-fit: contain; border-radius: 14px;
  background: #fff; border: 1px solid var(--border); cursor: zoom-in;
  transition: box-shadow .22s;
}
.guide-donate img:hover { box-shadow: var(--shadow-2), 0 0 24px rgba(34, 216, 240, .12); }
.guide-faq { border-bottom: 1px solid var(--border); padding: 4px 0; }
.guide-faq:last-child { border-bottom: 0; }
.guide-faq summary {
  cursor: pointer; padding: 10px 2px; font-size: 13.5px; font-weight: 600;
  list-style: none; display: flex; align-items: center; gap: 8px;
}
.guide-faq summary::before {
  content: "+"; font-family: var(--font-num); color: var(--brand-2);
  font-size: 15px; transition: transform .2s; flex: none;
}
.guide-faq[open] summary::before { transform: rotate(45deg); }
.guide-faq p { padding: 0 2px 12px 22px; }
.guide-faq a { color: var(--brand-2); }

@media (max-width: 960px) {
  .guide-cols { grid-template-columns: 1fr; }
  .guide-toc { top: 10px; }
}

/* ==========================================================================
   登录 / 注册：全息授权舱
   ========================================================================== */
.auth-mask {
  position: fixed; inset: 0; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(ellipse 80% 55% at 50% -8%, rgba(34, 216, 240, .09), transparent 62%),
    var(--bg);
  overflow-y: auto;
}
.auth-mask .bg-hud { position: fixed; opacity: .7; }
.auth-card {
  width: 380px; max-width: calc(100vw - 32px); padding: 38px 34px 30px;
  animation: auth-in .5s cubic-bezier(.16, .8, .28, 1.08);
}
@keyframes auth-in {
  from { opacity: 0; transform: translateY(26px) scale(.96); filter: brightness(2); }
}
.auth-logo { display: flex; align-items: center; gap: 10px; justify-content: center; margin-bottom: 8px; }
.auth-title { font-size: 21px; font-weight: 800; font-family: var(--font-num); letter-spacing: .5px; }
.auth-title em {
  font-style: normal;
  background: var(--brand-text-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.auth-sub { text-align: center; color: var(--text-3); font-size: 12px; margin-bottom: 22px; letter-spacing: 2.5px; font-family: var(--font-num); text-transform: uppercase; }
.auth-tabs { display: flex; border-bottom: 1px solid var(--border); margin-bottom: 18px; }
.auth-tab {
  flex: 1; padding: 9px 0; background: none; border: 0; cursor: pointer;
  color: var(--text-3); font: inherit; font-size: 13.5px; font-weight: 600;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: color .2s, border-color .2s;
}
.auth-tab.active { color: var(--text); border-bottom-color: var(--holo-1); text-shadow: 0 0 12px rgba(34, 216, 240, .35); }
.auth-form { display: flex; flex-direction: column; gap: 12px; }
.auth-form input {
  border: 1px solid var(--border); border-radius: 10px; background: var(--bg-2);
  color: var(--text); font: inherit; padding: 11px 13px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.auth-form input:focus {
  border-color: rgba(34, 216, 240, .55);
  box-shadow: 0 0 0 3px var(--focus), 0 0 18px rgba(34, 216, 240, .12);
}
.auth-btn { width: 100%; padding: 11px; font-size: 14px; }
.auth-err {
  color: var(--err); font-size: 12.5px; background: rgba(255, 93, 115, .08);
  border: 1px solid rgba(255, 93, 115, .28); border-radius: 9px; padding: 8px 12px;
}
.auth-hint { text-align: center; color: var(--text-3); font-size: 12px; margin-top: 12px; }

/* ==========================================================================
   赞赏
   ========================================================================== */
.donate-btn {
  display: flex; align-items: center; gap: 6px; padding: 7px 12px;
  border-radius: 999px; border: 1px solid #ffd166; color: #ffd166;
  background: rgba(255, 209, 102, .08); font: inherit; font-size: 12px;
  cursor: pointer; transition: all .18s;
}
.donate-btn:hover { background: rgba(255, 209, 102, .18); color: #ffe1a1; box-shadow: 0 0 14px rgba(255, 209, 102, .18); }
.donate-btn svg { width: 14px; height: 14px; flex: none; }
[data-theme="light"] .donate-btn {
  border-color: #b97f1f; color: #8a5d0a; background: rgba(217, 156, 43, .12);
}
[data-theme="light"] .donate-btn:hover { background: rgba(217, 156, 43, .24); color: #6b4a06; }
.donate-card {
  position: relative; max-width: 360px; margin: 8vh auto; padding: 30px 28px 24px;
  text-align: center; border-radius: 20px;
}
.donate-card .modal-close { position: absolute; right: 12px; top: 12px; }
.donate-card h3 { font-size: 17px; margin-bottom: 8px; }
.donate-text { color: var(--text-2); font-size: 13px; line-height: 1.7; margin-bottom: 16px; }
.donate-card img {
  width: 240px; height: 240px; object-fit: contain; border-radius: 14px;
  background: #fff; border: 1px solid var(--border); cursor: zoom-in;
  transition: box-shadow .22s;
}
.donate-card img:hover { box-shadow: 0 0 28px rgba(34, 216, 240, .18); }
.donate-hint { color: var(--text-3); font-size: 12px; margin-top: 12px; }

/* 连播开关胶囊（详情弹窗预览提示行内） */
.auto-next-chip {
  display: inline-flex; align-items: center; gap: 5px; margin-left: 10px;
  cursor: pointer; font-size: 12px; color: var(--text-3);
  padding: 2px 10px; border-radius: 999px; border: 1px solid var(--border);
}
.auto-next-chip input { display: none; }
.auto-next-chip:has(input:checked) {
  color: var(--brand-2); border-color: rgba(34, 216, 240, .55); background: var(--brand-dim);
}

/* ==========================================================================
   焦点 / 滚动条
   ========================================================================== */
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(148, 196, 255, .22); border-radius: 6px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: rgba(34, 216, 240, .38); background-clip: content-box; border: 2px solid transparent; }
::-webkit-scrollbar-track { background: transparent; }

/* ==========================================================================
   响应式
   ========================================================================== */
@media (max-width: 960px) {
  .playhead { left: 0; }
  .sidebar {
    position: sticky; width: 100%; bottom: auto; height: auto; flex-direction: row;
    align-items: center; padding: 10px 16px; border-right: 0;
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  }
  .logo { padding: 0 10px 0 0; }
  .logo-mark { width: 30px; height: 30px; }
  .logo-mark::after { display: none; }
  .logo-text { display: none; }
  .nav-group { display: none; }
  .nav { flex-direction: row; flex: 1; gap: 0; }
  .nav-item { flex: 1; justify-content: center; padding: 8px; transform: none !important; }
  .nav-item span { display: none; }
  .nav-item.active { background: transparent; }
  .nav-item.active svg { filter: drop-shadow(0 0 6px rgba(34, 216, 240, .8)); }
  .nav-item.active::before { left: 20%; right: 20%; top: auto; bottom: -10px; width: auto; height: 3px; border-radius: 3px 3px 0 0; }
  .sidebar-foot { margin: 0 0 0 auto; flex-direction: row; }
  .foot-row { display: none; }   /* 手机顶栏不显示客户端/赞赏 pill */
  .ver { display: none; }
  .main { margin-left: 0; padding: 22px 18px 46px; }
  .input-row { flex-direction: column; }
  .input-actions { flex-direction: row; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .settings-grid { grid-template-columns: 1fr; }
  .field-row { flex-direction: column; gap: 0; }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .lb-nav { display: none; }
  .repost-layout { grid-template-columns: 1fr; }
  .tools-layout { grid-template-columns: 1fr; }
  .rh-desc { display: none; }
  .page-head h1 { font-size: 23px; }
  .page-head h1::after { height: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .playhead-line { left: 0; }
  .bg-hud::after { display: none; }
}
