/* ==========================================================================
   闪创 Flashora — Design System V3.1（曜石黑 × 暖白 × 活力橙）
   1. Tokens  2. Base  3. Layout  4. Components  5. Page patterns
   6. Tech accents  7. Responsive
   品牌色只做识别与主操作；业务状态色独立成一套，两者互不借用。
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  color-scheme: light;

  /* Ink — 曜石黑体系。全中性去蓝紫，暖白底上不发灰；
     950 即品牌规范主文字 #171717，600 承担次级正文，500 是白底 4.9:1 的弱化下限 */
  --ink-950: #171717; /* 17.4 on white — 主标题 / 主文字 */
  --ink-900: #242424; /* 14.6 on white — 正文 */
  --ink-800: #3A3A3A; /* 10.8 on white */
  --ink-700: #4A4741; /* 9.3 on white */
  --ink-600: #55524C; /* 7.8 on white — 次级文字（暖中性） */
  --ink-500: #635E56; /* 6.4 on white / 6.0 on 暖白 — 弱化文字下限 */
  --ink-400: #6B665E; /* 5.7 on white / 5.3 on 暖白 / 4.6 on surface-4 — 图标、占位、极短提示 */
  --ink-300: #BEB9B0; /* 描边、禁用 */
  --ink-200: #D8D3CA;
  --ink-100: #EAE7E1;

  /* Surfaces — 暖白纸感 #F7F6F2 + 纯白内容面 */
  --paper: #F7F6F2;
  --paper-deep: #F1EFE9;
  --surface: #FFFFFF;
  --surface-2: #FBFAF7;
  --surface-3: #F3F1EC;
  --surface-4: #EAE7E1;
  --line: #EAE7E1;
  --line-strong: #D8D3C9;
  /* 输入框普通态：浅灰描边。比卡片描边略深一档，
     白底白框才不会糊在一起；聚焦时换成品牌橙 */
  --field-line: #E3DED5;
  /* 进度条轨道：中性底，颜色只由填充部分表达状态 */
  --track: #EFEBE3;

  /* Brand — 活力橙 #F36B45。只做品牌识别、主操作、选中态与关键强调，
     不做大面积底色；文字场景降一档用 --brand-ink 保证对比度 */
  --brand: #F36B45;
  --brand-600: #D94D2F;  /* 深橙：hover 底、强调块 */
  --brand-500: #F36B45;
  --brand-400: #FF8A67;
  --brand-ink: #A83820;  /* 橙色文字：白底 6.5:1，浅橙底 5.2:1 */
  --brand-soft: #FFF0E9; /* 浅橙：选中底、标签底 */
  --brand-tint: #FFF8F4;

  /* Accent — 深橙做第二层强调，仅小面积 */
  --accent: #D94D2F;
  --accent-soft: #FFF0E9;

  /* 中性点缀：替代原来的彩色点缀，保持画面克制 */
  --sand: #E7E0D4;
  --sand-soft: #F5F1E9;

  /* 视频画布 — 曜石黑沉浸舞台，与品牌橙无关，保持深色。
     V3.1 规范值 #151515；2/3 层只做同一色阶上的分层，不引入蓝调 */
  --stage: #151515;
  --stage-2: #1E1E1E;
  --stage-3: #2A2A2A;
  --stage-text: rgba(255, 255, 255, 0.92);
  --stage-sub: rgba(255, 255, 255, 0.56);
  --stage-line: rgba(255, 255, 255, 0.12);

  /* Status — 五种业务状态，与品牌橙彻底分离。
     色相刻意拉开：待确认偏橙、进行中偏蓝、生成中偏琥珀、完成偏绿、失败偏红，
     即便在 11px 的小标签上也能一眼分辨；底色一律浅、文字一律深，保证 4.5:1 以上 */
  --st-pending: #A9451E; /* 5.1 on st-pending-soft */
  --st-pending-soft: #FCEAE0;
  --st-pending-line: #F6D4C4;

  --info: #2A5B99; /* 6.0 on st-info-soft */
  --info-soft: #E9F1FB;
  --info-line: #D2E2F6;

  --warn: #7E5510; /* 5.8 on st-progress-soft */
  --warn-soft: #FBF0DA;
  --warn-line: #F2DFB4;
  --warn-500: #E5A13A; /* 规范警告黄，用于圆点、进度等图形 */

  --success: #1A7A58; /* 4.7 on success-soft */
  --success-500: #229B70; /* 规范成功绿，用于圆点、进度等图形 */
  --success-soft: #E7F5EF;
  --success-line: #C9EBDD;

  --danger: #C13A3A; /* 4.7 on danger-soft */
  --danger-500: #DE4D4D;
  --danger-soft: #FBECEC;
  --danger-line: #F2C9C5;

  --mock: #7E5510;
  --mock-soft: #FBF0DA;

  /* Type — 英文 Inter，中文落在系统黑体 */
  --font-sans: "Inter", "Inter Variable", -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "HarmonyOS Sans SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", "Roboto Mono", Menlo, monospace;

  /* Radii — 卡片 12～16px，大容器 20px */
  --r-xs: 8px;
  --r-sm: 10px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 20px;
  --r-2xl: 24px;
  --r-full: 999px;

  /* Shadows — 靠细边框分层，阴影只做极轻浮起 */
  --shadow-xs: 0 1px 2px rgba(23, 23, 23, 0.04);
  --shadow-sm: 0 1px 2px rgba(23, 23, 23, 0.04), 0 1px 3px rgba(23, 23, 23, 0.03);
  --shadow-md: 0 10px 28px -14px rgba(23, 23, 23, 0.14), 0 2px 6px rgba(23, 23, 23, 0.04);
  --shadow-lg: 0 28px 64px -28px rgba(23, 23, 23, 0.22), 0 6px 16px rgba(23, 23, 23, 0.05);
  --glow-brand: 0 8px 20px -12px rgba(243, 107, 69, 0.34);

  --sidebar-w: 236px;
  --topbar-h: 62px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink-900);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* 页面上不再叠加装饰性光晕：暖白纸感本身就是底色，橙色只出现在该出现的地方 */
body::before { display: none; }

body::after { display: none; }

h1, h2, h3, h4, h5 { margin: 0; font-weight: 700; letter-spacing: -0.028em; line-height: 1.22; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
img { display: block; max-width: 100%; }
svg { display: block; flex: none; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
::selection { background: rgba(243, 107, 69, 0.16); color: var(--ink-950); }

* { scrollbar-width: thin; scrollbar-color: #D8D3C9 transparent; }
*::-webkit-scrollbar { width: 9px; height: 9px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: #DDD8CE; border-radius: 99px; border: 2px solid transparent; background-clip: content-box; }
*::-webkit-scrollbar-thumb:hover { background: #C6C0B4; background-clip: content-box; }

.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-500); }
.dim { color: var(--ink-500); }
.tiny { font-size: 12px; }
.small { font-size: 13px; }
.strong { font-weight: 600; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 11.5px;
  letter-spacing: 0.02em;
  color: var(--brand-ink);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
}
.eyebrow::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

/* 3. Layout --------------------------------------------------------------- */
.app { display: flex; min-height: 100vh; position: relative; z-index: 1; }

.sidebar {
  width: var(--sidebar-w);
  flex: none;
  background: var(--surface);
  border-right: 1px solid var(--line);
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  z-index: 40;
}
.sidebar__brand {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  flex: none;
}
.brandmark {
  /* 品牌符号：纯橙实心，不用渐变。白描边符号在橙底上 3.0:1，符合图形元素对比要求 */
  width: 30px; height: 30px; border-radius: 9px;
  background: var(--brand);
  color: #ffffff;
  display: grid; place-items: center;
  flex: none;
  box-shadow: 0 3px 10px -6px rgba(217, 77, 47, 0.55);
}
.brandmark svg { width: 16px; height: 16px; stroke: #ffffff; }
/* 品牌文字：中文曜石黑、英文辅助灰，靠字距与字重区分层级 */
.brandword b { font-weight: 700; }
.brandword { display: flex; flex-direction: column; line-height: 1.15; }
.brandword b { font-size: 14.5px; letter-spacing: -0.02em; color: var(--ink-950); }
.brandword span { font-size: 11px; letter-spacing: 0.14em; color: var(--ink-500); font-family: var(--font-mono); }

.sidebar__workspace {
  margin: 4px 12px 10px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  display: flex; align-items: center; gap: 8px;
  background: var(--surface-2);
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}
.sidebar__workspace:hover { border-color: var(--line-strong); background: var(--surface-3); }
.workspace-avatar {
  width: 24px; height: 24px; border-radius: 7px;
  background: var(--brand-soft); color: var(--brand-ink);
  display: grid; place-items: center; font-size: 11px; font-weight: 700;
  flex: none;
  border: 1px solid #FBE2D8;
}
.sidebar__workspace .ws-meta { flex: 1; min-width: 0; }
.sidebar__workspace .ws-meta b { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-900); }
.sidebar__workspace .ws-meta span { display: block; font-size: 11px; color: var(--ink-500); }

.sidebar__nav { flex: 1; overflow-y: auto; padding: 6px 12px 16px; }
.nav-group { margin-top: 18px; }
.nav-group:first-child { margin-top: 2px; }
.nav-group__label {
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--ink-500);
  padding: 0 10px 7px;
  font-weight: 500;
}
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  color: var(--ink-700);
  font-size: 13px;
  position: relative;
  transition: background 0.14s var(--ease), color 0.14s var(--ease);
  width: 100%;
  text-align: left;
}
.nav-item svg { width: 17px; height: 17px; opacity: 0.75; }
.nav-item:hover { background: var(--surface-3); color: var(--ink-950); }
/* 选中态：浅橙底 + 深橙文字（4.6:1），左侧一条品牌橙竖条做识别锚点 */
.nav-item.is-active {
  background: var(--brand-soft);
  color: var(--brand-ink);
  font-weight: 600;
}
.nav-item.is-active svg { opacity: 1; color: var(--brand-ink); }
.nav-item.is-active::before {
  content: ""; display: block;
  position: absolute; left: 0; top: 8px; bottom: 8px;
  width: 2.5px; border-radius: 0 3px 3px 0;
  background: var(--brand);
}
.nav-item .nav-count {
  margin-left: auto; font-size: 11px;
  color: var(--ink-500); background: var(--surface-3); border-radius: var(--r-full);
  padding: 0 7px; min-width: 20px; text-align: center; font-variant-numeric: tabular-nums;
}
.nav-item.is-active .nav-count { background: #FBE2D8; color: var(--brand-ink); }

.sidebar__foot { flex: none; padding: 10px 12px 12px; border-top: 1px solid var(--line); }
.quota-card { padding: 12px; border-radius: var(--r-md); background: var(--brand-tint); border: 1px solid #F9E4DB; }
.quota-card__top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.quota-card__top b { font-family: var(--font-sans); font-size: 17px; color: var(--ink-950); letter-spacing: -0.02em; }
.quota-card__top span { font-size: 11px; color: var(--ink-500); }
.quota-bar { height: 5px; border-radius: 4px; background: #FAE5DC; overflow: hidden; }
.quota-bar i { display: block; height: 100%; border-radius: 4px; background: var(--brand); }
.quota-card__link { margin-top: 9px; font-size: 11.5px; color: var(--brand-ink); display: flex; align-items: center; gap: 4px; width: 100%; font-weight: 500; padding: 3px 0; margin-bottom: -3px; }
.quota-card__link:hover { color: var(--brand-600); }
.sidebar-user { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 6px 8px; border-radius: var(--r-sm); }
.sidebar-user:hover { background: var(--surface-3); }
.sidebar-user .su-meta { flex: 1; min-width: 0; }
.sidebar-user .su-meta b { display: block; font-size: 12px; font-weight: 600; color: var(--ink-900); }
.sidebar-user .su-meta span { display: block; font-size: 11px; color: var(--ink-500); }
.sidebar-user .icon-btn { width: 26px; height: 26px; }
.sidebar-user .icon-btn:hover { color: var(--danger); background: var(--danger-soft); }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: var(--topbar-h);
  flex: none;
  display: flex; align-items: center; gap: 14px;
  padding: 0 26px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px) saturate(1.1);
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
  position: sticky; top: 0; z-index: 30;
}
.topbar__crumbs { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--ink-500); min-width: 0; white-space: nowrap; overflow: hidden; }
.topbar__crumbs a, .topbar__crumbs b { white-space: nowrap; }
/* 面包屑链接只有 20px 高，低于 24px 的最小点击区；
   上下 padding 扩点击区、负 margin 抵消视觉间距，版面不变。 */
.topbar__crumbs a { display: inline-flex; align-items: center; min-height: 24px; padding: 3px 0; margin: -3px 0; }
.topbar__crumbs a:hover { color: var(--brand-ink); }
.topbar__crumbs b { color: var(--ink-950); font-weight: 600; }
.topbar__spacer { flex: 1; }
.topbar__actions { display: flex; align-items: center; gap: 8px; }
.mode-pill {
  display: inline-flex; align-items: center; gap: 6px;
  height: 28px; padding: 0 10px; border-radius: var(--r-full);
  border: 1px solid var(--line); background: var(--surface-2);
  font-size: 11.5px; color: var(--ink-600); white-space: nowrap;
}
.mode-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--warn-500); }
.mode-pill.is-live i { background: var(--danger-500); }
.crumb-divider { color: var(--ink-400); }
.mobile-menu { display: none; }

.view { flex: 1; min-width: 0; }
.icp-footer {
  flex: none;
  margin-top: auto;
  padding: 14px 0 18px;
  text-align: center;
  font-size: 11.5px;
  color: var(--ink-400);
}
.icp-footer a { color: inherit; text-decoration: none; }
.icp-footer a:hover { color: var(--ink-600); }
body.is-auth .icp-footer { position: static; }
.view--flush { display: flex; flex-direction: column; min-height: calc(100vh - var(--topbar-h)); }
.page { padding: 26px 28px 56px; max-width: 1480px; margin: 0 auto; width: 100%; }
.page--narrow { max-width: 1080px; }
.page--wide { max-width: none; }

/* 4. Components ----------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 36px; padding: 0 15px;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  font-size: 13px; font-weight: 600;
  white-space: nowrap;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease), transform 0.1s var(--ease);
  user-select: none;
}
.btn svg { width: 15px; height: 15px; }
.btn:active { transform: translateY(0.5px) scale(0.995); }
/* 主操作：活力橙实心 + 近黑文字。
   橙底配白字只有 3.0:1，达不到正文可读标准；配 #171717 是 6.0:1，
   既保留品牌橙的冲击力，又保证按钮文字清晰——这也是橙色系品牌系统的通行做法。 */
.btn--primary {
  background: var(--brand);
  color: var(--ink-950);
  font-weight: 650;
  border-color: rgba(23, 23, 23, 0.10);
  /* 内高光 + 内底影：橙色块有受光面与厚度，才像按钮而不是高亮标签 */
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42), inset 0 -1px 0 rgba(120, 35, 12, 0.16),
    0 4px 12px -6px rgba(217, 77, 47, 0.55);
}
.btn--primary:hover { background: #E85C33; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34), 0 8px 20px -10px rgba(217, 77, 47, 0.55); }
.btn--primary:active { background: var(--brand-600); }
.btn--brand {
  background: var(--brand);
  color: var(--ink-950);
  font-weight: 650;
  border-color: rgba(23, 23, 23, 0.10);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42), inset 0 -1px 0 rgba(120, 35, 12, 0.16),
    0 4px 12px -6px rgba(217, 77, 47, 0.55);
}
.btn--brand:hover { background: #E85C33; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34), 0 8px 20px -10px rgba(217, 77, 47, 0.55); }
.btn--brand:active { background: var(--brand-600); }
.btn--secondary { background: var(--surface); border-color: var(--line-strong); color: var(--ink-700); }
.btn--secondary:hover { border-color: #D8D3C9; background: var(--surface-2); color: var(--ink-950); }
.btn--quiet { color: var(--ink-600); }
.btn--quiet:hover { background: var(--surface-3); color: var(--ink-950); }
.btn--danger { background: var(--danger-soft); border-color: var(--danger-line); color: var(--danger); }
.btn--danger:hover { background: #F8DCD8; border-color: #E9B4AE; }
.btn--ghost { border-color: var(--line); color: var(--ink-600); background: transparent; }
.btn--ghost:hover { background: var(--surface-2); color: var(--ink-950); border-color: var(--line-strong); }
.btn--sm { height: 30px; padding: 0 11px; font-size: 12px; border-radius: var(--r-xs); gap: 5px; }
.btn--sm svg { width: 13px; height: 13px; }
.btn--lg { height: 46px; padding: 0 22px; font-size: 14px; border-radius: var(--r-md); }
.btn--block { width: 100%; }
.btn:disabled, .btn.is-disabled { opacity: 0.42; cursor: not-allowed; box-shadow: none; }
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.4); border-top-color: #ffffff;
  border-radius: 50%; animation: spin 0.7s linear infinite;
}
.btn--secondary.is-loading::after, .btn--ghost.is-loading::after, .btn--quiet.is-loading::after { border-color: var(--line-strong); border-top-color: var(--brand); }
@keyframes spin { to { transform: rotate(360deg); } }

.icon-btn {
  width: 30px; height: 30px; border-radius: var(--r-xs);
  display: inline-grid; place-items: center; color: var(--ink-500);
  transition: background 0.14s var(--ease), color 0.14s var(--ease);
}
.icon-btn:hover { background: var(--surface-3); color: var(--ink-950); }
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn.is-danger:hover { background: var(--danger-soft); color: var(--danger); }

.badge {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 8px; border-radius: var(--r-full);
  font-size: 11px; font-weight: 600; white-space: nowrap;
  background: var(--surface-3); color: var(--ink-600);
  border: 1px solid transparent;
}
.badge svg { width: 11px; height: 11px; }
.badge i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
/* 业务状态：待确认 / 进行中 / 生成中 / 已完成 / 失败，一态一色 */
.badge--pending { background: var(--st-pending-soft); color: var(--st-pending); border-color: var(--st-pending-line); }
.badge--info { background: var(--info-soft); color: var(--info); border-color: var(--info-line); }
.badge--progress,
.badge--warn { background: var(--warn-soft); color: var(--warn); border-color: var(--warn-line); }
.badge--success { background: var(--success-soft); color: var(--success); border-color: var(--success-line); }
.badge--danger { background: var(--danger-soft); color: var(--danger); border-color: var(--danger-line); }
.badge--mock { background: var(--mock-soft); color: var(--mock); border-color: var(--warn-line); }
/* 品牌标签：只表示「本站标记 / 已选 / 推荐」，不承担任何业务状态 */
.badge--brand { background: var(--brand-soft); color: var(--brand-ink); border-color: #FBE2D8; }
.badge--outline { background: var(--surface); border-color: var(--line-strong); color: var(--ink-500); }
.badge--dot i { animation: pulse 1.6s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 27px; padding: 0 11px; border-radius: var(--r-full);
  border: 1px solid var(--line); background: var(--surface);
  font-size: 11.5px; color: var(--ink-600);
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease), color 0.14s var(--ease);
}
.chip--soft { background: var(--surface-3); border-color: transparent; }
.chip--brand { background: var(--brand-soft); border-color: #FBE2D8; color: var(--brand-ink); font-weight: 600; }
.chip button { display: inline-grid; place-items: center; color: var(--ink-400); }
.chip button:hover { color: var(--danger); }
.chip:hover { border-color: var(--line-strong); color: var(--ink-800); }
.chip--brand:hover { border-color: #F6D2C4; color: var(--brand-600); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xs);
}
.card--pad { padding: 20px; }
.card--hover { transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease); }
.card--hover:hover {
  border-color: #E2DCD2;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.card__head {
  display: flex; align-items: center; gap: 12px;
  padding: 15px 18px; border-bottom: 1px solid var(--line);
}
.card__head h3 { font-size: 14px; letter-spacing: -0.015em; }
.card__head .spacer { flex: 1; }
.card__body { padding: 18px; }
.card__foot { padding: 13px 18px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 10px; }

.section-head { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 16px; }
.section-head h2 { font-size: 19px; letter-spacing: -0.03em; font-weight: 700; color: var(--ink-950); }
.section-head p { font-size: 12.5px; color: var(--ink-500); margin-top: 3px; }
.section-head .spacer { flex: 1; }

.page-head { display: flex; align-items: flex-start; gap: 20px; margin-bottom: 24px; }
.page-head h1 { font-size: 30px; letter-spacing: -0.035em; font-weight: 700; color: var(--ink-950); }
.page-head p { color: var(--ink-500); font-size: 13px; margin-top: 6px; max-width: 640px; }
.page-head .spacer { flex: 1; }
.page-head__actions { display: flex; align-items: center; gap: 8px; flex: none; }

.panel { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; }
.panel--brand { background: var(--brand-tint); border-color: #F9E4DB; }
.panel--warn { background: var(--warn-soft); border-color: #F3E2C6; }
.panel--mock { background: var(--mock-soft); border-color: #EFDFC7; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field > label, .field__label {
  font-size: 12px; font-weight: 500; color: var(--ink-600);
  display: flex; align-items: center; gap: 6px;
}
.field__hint { font-size: 11.5px; color: var(--ink-500); line-height: 1.5; }
.field__error { font-size: 11.5px; color: var(--danger); }
.req { color: var(--brand-ink); }

.input, .textarea, .select {
  width: 100%;
  border: 1px solid var(--field-line);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 8px 11px;
  font-size: 13px;
  color: var(--ink-900);
  transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease), background 0.14s var(--ease);
  min-height: 36px;
}
/* 普通态浅灰 → 悬停加深一档 → 聚焦品牌橙（只换边框色，不改尺寸，避免跳动） */
.input:hover, .textarea:hover, .select:hover { border-color: var(--line-strong); }
.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--brand);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(243, 107, 69, 0.14);
}
.input::placeholder, .textarea::placeholder { color: var(--ink-400); }
.textarea { resize: vertical; min-height: 78px; line-height: 1.65; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%237F7796' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 9px center; padding-right: 30px; cursor: pointer; }
.select option { background: var(--surface); color: var(--ink-900); }
.input--sm { min-height: 30px; padding: 4px 9px; font-size: 12px; }
.input-group { display: flex; align-items: stretch; }
.input-group .input { border-radius: var(--r-sm) 0 0 var(--r-sm); }
.input-group .btn { border-radius: 0 var(--r-sm) var(--r-sm) 0; border-left: 0; height: 36px; }
input[type="color"] { background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-sm); padding: 2px; }

.segmented { display: inline-flex; background: var(--surface-3); border: 1px solid transparent; border-radius: var(--r-sm); padding: 3px; gap: 2px; }
.segmented button {
  padding: 5px 12px; border-radius: 7px; font-size: 12px; color: var(--ink-500);
  transition: all 0.14s var(--ease);
}
.segmented button:hover { color: var(--ink-800); }
.segmented button.is-active { background: var(--surface); color: var(--ink-950); box-shadow: var(--shadow-xs); font-weight: 600; }
.segmented--block { display: flex; width: 100%; flex-wrap: wrap; }
.segmented--block button { flex: 1; }

.switch { position: relative; width: 34px; height: 20px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch span {
  position: absolute; inset: 0; border-radius: 999px;
  background: #E4DED4;
  transition: background 0.18s var(--ease), box-shadow 0.18s var(--ease); cursor: pointer;
}
.switch span::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px; border-radius: 50%; background: #ffffff;
  box-shadow: 0 1px 3px rgba(23, 20, 31, 0.24); transition: transform 0.18s var(--ease);
}
.switch input:checked + span { background: var(--brand); }
.switch input:checked + span::after { transform: translateX(14px); background: #ffffff; }
.switch input:disabled + span { opacity: 0.4; cursor: not-allowed; }

.check { display: flex; align-items: flex-start; gap: 8px; font-size: 12.5px; color: var(--ink-600); cursor: pointer; }
.check input { margin: 3px 0 0; accent-color: var(--brand); width: 14px; height: 14px; }

.option-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; }
.option {
  border: 1px solid var(--line); background: var(--surface); border-radius: var(--r-sm);
  padding: 10px 12px; text-align: left; transition: all 0.14s var(--ease);
  display: flex; flex-direction: column; gap: 2px;
}
.option:hover { border-color: #D8D3C9; background: var(--surface-2); }
.option b { font-size: 12.5px; font-weight: 500; color: var(--ink-900); }
.option span { font-size: 11px; color: var(--ink-400); }
.option.is-active {
  border-color: var(--brand);
  background: var(--brand-tint);
  box-shadow: 0 0 0 1px rgba(243, 107, 69, 0.2);
}
.option.is-active b { color: var(--brand-ink); }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.table th {
  text-align: left; font-weight: 500; color: var(--ink-500);
  font-size: 11px; letter-spacing: 0.02em;
  padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
  background: var(--surface-2);
}
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; color: var(--ink-800); }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background 0.12s var(--ease); }
.table tbody tr:hover { background: var(--surface-2); }
.table .cell-main { font-weight: 600; color: var(--ink-950); }
.table .row-actions { display: flex; gap: 4px; justify-content: flex-end; }

/* 进度条：全站同一套尺寸与圆角，颜色只表达状态。
   默认（数据占比等非状态场景）用品牌橙；
   生成中走琥珀、已完成走绿、有失败走红——与状态标签同色，扫一眼就能对上 */
.progress { height: 5px; border-radius: 4px; background: var(--track); overflow: hidden; width: 100%; }
.progress i {
  display: block; height: 100%; border-radius: 4px;
  background: var(--brand);
  transition: width 0.5s var(--ease);
}
.progress--sm { height: 3px; }
.progress--progress i { background: var(--warn-500); }
.progress--success i { background: var(--success-500); }
.progress--warn i { background: var(--warn-500); }
.progress--danger i { background: var(--danger-500); }

.avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--brand-soft); color: var(--brand-600);
  display: inline-grid; place-items: center; font-size: 11px; font-weight: 700;
  flex: none; border: 1px solid #FBE2D8;
}
.avatar--lg { width: 42px; height: 42px; font-size: 14px; }
.avatar--xl { width: 60px; height: 60px; font-size: 19px; }

/* 卡通头像：SVG 铺满圆形容器 */
.avatar--pic {
  overflow: hidden; padding: 0;
  background: var(--surface-3);
  border: 1px solid var(--line);
  line-height: 0;
}
.avatar--pic svg { width: 100%; height: 100%; display: block; }
.avatar--pic:hover { border-color: #F6D2C4; }

.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: thin; }
.tabs::-webkit-scrollbar { height: 4px; }
.tabs::-webkit-scrollbar-thumb { background: #DDD8CE; border-radius: 2px; }
.tab {
  padding: 10px 14px; font-size: 13px; color: var(--ink-500);
  border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap;
  transition: color 0.14s var(--ease);
}
.tab:hover { color: var(--ink-800); }
.tab.is-active { color: var(--ink-950); border-color: var(--brand); font-weight: 600; }

.ratio-box { position: relative; overflow: hidden; background: var(--surface-3); }
.ratio-box > img, .ratio-box > video { width: 100%; height: 100%; object-fit: cover; }
/* 镜头缩略：取景框统一 16:9，画面按原比例居中显示。
   竖屏镜头放进方形格子里不会被裁掉上半张脸，也不会被拉扁 */
.shot-media { position: relative; aspect-ratio: 16 / 9; background: var(--stage); overflow: hidden; }
.shot-media > img,
.shot-media > video { width: 100%; height: 100%; object-fit: contain; }
.ratio-box--9x16 { aspect-ratio: 9 / 16; }
.ratio-box--1x1 { aspect-ratio: 1 / 1; }
.ratio-box--4x5 { aspect-ratio: 4 / 5; }
.ratio-box--16x9 { aspect-ratio: 16 / 9; }

.empty {
  text-align: center; padding: 44px 24px; border: 1px dashed var(--line-strong);
  border-radius: var(--r-lg); background: var(--surface-2);
}
.empty__icon {
  width: 46px; height: 46px; border-radius: var(--r-md); margin: 0 auto 12px;
  display: grid; place-items: center; background: var(--brand-tint);
  border: 1px solid #F9E4DB; color: var(--brand);
}
.empty h4 { font-size: 14px; margin-bottom: 4px; color: var(--ink-900); }
.empty p { font-size: 12.5px; color: var(--ink-500); max-width: 380px; margin: 0 auto 14px; }

.skeleton {
  background: linear-gradient(90deg, #EFEBE4 25%, #F8F6F1 37%, #EFEBE4 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: var(--r-xs);
}
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }
.skeleton--line { height: 11px; margin-bottom: 8px; }
.skeleton--block { border-radius: var(--r-md); }

/* Toast */
.toast-root { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 9px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--ink-900);
  padding: 10px 15px; border-radius: var(--r-sm);
  font-size: 12.5px; box-shadow: var(--shadow-lg);
  animation: toast-in 0.22s var(--ease);
  max-width: 460px;
}
.toast svg { width: 15px; height: 15px; }
.toast--success svg { color: var(--success); }
.toast--error svg { color: var(--danger); }
.toast--warn svg { color: var(--warn); }
.toast--mock svg { color: var(--mock); }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* Modal */
.scrim {
  position: fixed; inset: 0; z-index: 150; display: grid; place-items: center; padding: 24px;
  background: rgba(23, 20, 31, 0.28);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: fade 0.16s var(--ease);
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  width: 100%; max-width: 520px;
  max-height: calc(100vh - 48px); display: flex; flex-direction: column;
  animation: modal-in 0.2s var(--ease);
}
@keyframes modal-in { from { opacity: 0; transform: translateY(10px) scale(0.985); } to { opacity: 1; transform: none; } }
.modal--wide { max-width: 780px; }
.modal__head { padding: 18px 20px 12px; display: flex; align-items: flex-start; gap: 12px; }
.modal__head h3 { font-size: 16px; letter-spacing: -0.02em; }
.modal__head p { font-size: 12.5px; color: var(--ink-500); margin-top: 3px; }
.modal__head .icon-btn { margin-left: auto; }
.modal__body { padding: 6px 20px 18px; overflow-y: auto; }
.modal__foot { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; align-items: center; }

/* 5. Page patterns -------------------------------------------------------- */
/* Hero / home */
.home-hero {
  display: grid; grid-template-columns: 1.08fr 0.92fr; gap: 18px;
  margin-bottom: 26px;
}
.hero-copy {
  position: relative;
  padding: 40px 38px;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  display: flex; flex-direction: column; justify-content: center;
  overflow: hidden;
  background: var(--surface);
}
.hero-copy::after {
  content: "";
  position: absolute;
  width: 420px; height: 420px;
  right: -170px; top: -190px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(243, 107, 69, 0.1), transparent 66%);
  pointer-events: none;
}
.hero-copy > * { position: relative; z-index: 1; }
.hero-copy h1 {
  font-size: clamp(30px, 3.2vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.04em;
  font-weight: 700;
  margin: 14px 0 12px;
  color: var(--ink-950);
}
.hero-copy h1 em { font-style: normal; color: var(--brand-ink); white-space: nowrap; }
.hero-copy > p { color: var(--ink-600); font-size: 13.5px; max-width: 470px; line-height: 1.75; }
.hero-start { margin-top: 26px; display: flex; gap: 10px; flex-wrap: wrap; }
.hero-visual { position: relative; border-radius: var(--r-xl); overflow: hidden; min-height: 320px; background: var(--surface-3); border: 1px solid var(--line); }
.hero-visual img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; transition: transform 0.7s var(--ease); }
.hero-visual:hover img { transform: scale(1.03); }
.hero-visual__overlay {
  position: absolute; inset: 0; padding: 20px; display: flex; flex-direction: column; justify-content: space-between;
  background: linear-gradient(180deg, rgba(18, 18, 18, 0.06) 40%, rgba(18, 18, 18, 0.72) 100%);
  color: #fff;
}
.hero-visual__tag {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #fff; font-size: 11px; padding: 5px 10px; border-radius: var(--r-full);
  display: inline-flex; gap: 6px; align-items: center;
}
.hero-visual__cap b { display: block; font-size: 15px; }
.hero-visual__cap span { font-size: 11.5px; opacity: 0.82; }

.stat-strip {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden;
}
.stat { background: var(--surface); padding: 16px 18px; position: relative; }
.stat b {
  display: block; font-family: var(--font-sans); font-size: 22px; letter-spacing: -0.03em;
  color: var(--ink-950); font-weight: 700;
}
.stat span { font-size: 11px; color: var(--ink-500); }
.stat:first-child b { color: var(--brand-ink); }

.grid { display: grid; gap: 14px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }

/* Main + aside split layouts (collapse on tablet) */
.split { display: grid; gap: 18px; align-items: start; grid-template-columns: minmax(0, 1fr) 300px; }
.split--lg { grid-template-columns: minmax(0, 1fr) 320px; }
.split--xl { grid-template-columns: minmax(0, 1fr) 340px; }
.split--wide { grid-template-columns: 1.5fr 1fr; }
.split--even { grid-template-columns: 1.4fr 1fr; gap: 16px; }
@media (max-width: 1080px) { .split { grid-template-columns: minmax(0, 1fr); } }

/* Product card */
.product-card { overflow: hidden; display: flex; flex-direction: column; background: var(--surface); border-radius: var(--r-lg); }
.product-card__media { position: relative; aspect-ratio: 4 / 3; background: var(--surface-3); overflow: hidden; min-height: 0; }
.product-card__media > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.55s var(--ease); }
.product-card:hover .product-card__media > img { transform: scale(1.045); }
.product-card__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 62%, rgba(18, 18, 18, 0.34)); pointer-events: none; }
.product-card__ratio { position: absolute; left: 10px; top: 10px; z-index: 1; }
.product-card__body { padding: 14px 15px 15px; display: flex; flex-direction: column; gap: 3px; flex: 1; }
.product-card__body h4 { font-size: 13.5px; color: var(--ink-950); }
.product-card__meta { font-size: 11.5px; color: var(--ink-500); display: flex; align-items: center; gap: 6px; }
.product-card__foot { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }

/* 极简创作临时档案：默认折叠的收容区，不占主列表的位置 */
.adhoc { margin-top: 18px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-2); overflow: hidden; }
.adhoc__head {
  width: 100%; display: flex; align-items: center; gap: 8px; flex-wrap: nowrap;
  padding: 10px 14px; border: 0; background: none; font: inherit; text-align: left; cursor: pointer;
}
.adhoc__head:hover { background: var(--surface-3); }
.adhoc__title { display: inline-flex; align-items: center; gap: 6px; flex: none; font-size: 12.5px; font-weight: 600; color: var(--ink-800); }
.adhoc__title svg { color: var(--ink-400); }
.adhoc__hint { font-size: 11px; color: var(--ink-400); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adhoc__head > svg:last-child { flex: none; color: var(--ink-400); transition: transform 0.18s var(--ease); }
.adhoc__head.is-open > svg:last-child { transform: rotate(180deg); }
.adhoc__body { padding: 4px 8px; background: var(--surface); border-top: 1px solid var(--line); }
.adhoc__row { display: flex; align-items: center; gap: 10px; padding: 7px 6px; border-radius: var(--r-sm); }
.adhoc__row + .adhoc__row { border-top: 1px solid var(--line); border-radius: 0; }
.adhoc__row:hover { background: var(--surface-2); }
.adhoc__thumb {
  width: 34px; height: 34px; flex: none; display: grid; place-items: center; overflow: hidden;
  border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); color: var(--ink-300);
}
.adhoc__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.adhoc__main { min-width: 0; }
.adhoc__name { display: block; font-size: 12.5px; font-weight: 550; color: var(--ink-900); }
.adhoc__name:hover { color: var(--brand); }
.adhoc-note { align-items: flex-start; flex-wrap: wrap; }
.adhoc-note > svg { flex: none; margin-top: 1px; }
.adhoc-note > div { flex: 1; min-width: 220px; line-height: 1.65; }
@media (max-width: 640px) {
  .adhoc__hint { display: none; }
  .adhoc__row { flex-wrap: wrap; }
}

/* Template card */
.template-card { overflow: hidden; display: flex; flex-direction: column; cursor: pointer; background: var(--surface); border-radius: var(--r-lg); }
/* 底色用深色：标题是白字，图片没加载出来时（占位底）也不能变成白底白字 */
.template-card__media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: #232323; }
.template-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease); }
.template-card:hover .template-card__media img { transform: scale(1.045); }
.template-card__veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(18, 18, 18, 0.02) 40%, rgba(18, 18, 18, 0.86)); }
.template-card__num { position: absolute; right: 12px; top: 10px; font-family: var(--font-mono); font-size: 11px; color: #fff; letter-spacing: 0.06em; background: rgba(18, 18, 18, 0.82); padding: 2px 7px; border-radius: 6px; backdrop-filter: blur(6px); }
.template-card__title { position: absolute; left: 14px; bottom: 12px; right: 14px; color: #fff; }
.template-card__title b { display: block; font-size: 15px; letter-spacing: -0.01em; }
.template-card__title span { font-size: 11px; opacity: 0.84; }
.template-card__body { padding: 13px 14px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.template-card__body p { font-size: 11.5px; color: var(--ink-500); line-height: 1.6; }
.template-card__foot { margin-top: auto; display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--ink-400); flex-wrap: wrap; }

/* Showcase cards（优秀案例：真实成片，悬停播放） */
.case-band { margin-bottom: 32px; }
.case-shelf + .case-shelf { margin-top: 14px; }
.case-shelf__head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.case-grid { display: grid; gap: 12px; }
.case-grid--v { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.case-grid--h { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.case-card {
  position: relative;
  border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden;
  background: var(--surface); cursor: pointer;
  transition: border-color 0.18s var(--ease), transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.case-card:hover, .case-card:focus-visible {
  border-color: #E2DCD2; transform: translateY(-2px);
  box-shadow: var(--shadow-md); outline: none;
}
/* 同上：案例卡的画幅标签是白字，图片缺失时也要保证可读 */
.case-card__media { position: relative; overflow: hidden; background: #232323; }
.case-grid--v .case-card__media { aspect-ratio: 4 / 5; }
.case-grid--h .case-card__media { aspect-ratio: 16 / 9; }
.case-card__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.case-card__media video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 0.22s var(--ease);
}
.case-card.is-playing .case-card__media video { opacity: 1; }
.case-card__media::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(18, 18, 18, 0.22) 0%, rgba(18, 18, 18, 0) 34%, rgba(18, 18, 18, 0.5) 100%);
}
.case-card__play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.9); border: 1px solid rgba(255, 255, 255, 0.6); color: var(--ink-950);
  box-shadow: 0 4px 12px -4px rgba(18, 18, 18, 0.4);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}
.case-card:hover .case-card__play, .case-card.is-playing .case-card__play { opacity: 0; transform: translate(-50%, -50%) scale(0.85); }
.case-card__ratio {
  position: absolute; left: 9px; bottom: 8px; z-index: 1;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.04em;
  color: #fff; background: rgba(21, 21, 27, 0.82); padding: 2px 6px; border-radius: 5px;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.case-card__badge {
  position: absolute; right: 9px; top: 8px; z-index: 1;
  padding: 2px 7px; border-radius: 5px; font-size: 11px; line-height: 1.5;
  background: rgba(255, 255, 255, 0.94); color: var(--brand-ink); font-weight: 600;
}
.case-card__body { padding: 11px 12px 12px; display: flex; flex-direction: column; gap: 6px; }
.case-card__name { font-size: 13px; color: var(--ink-950); letter-spacing: -0.01em; font-weight: 600; }
.case-card__tag { font-size: 11.5px; color: var(--ink-500); line-height: 1.5; }
.case-card__foot { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.case-card__foot .truncate { min-width: 0; }
.case-card__copy {
  display: inline-flex; align-items: center; gap: 4px; flex: none;
  font-size: 11.5px; color: var(--brand-ink); font-weight: 600;
  padding: 4px 2px; margin: -2px 0;
}
.case-card__copy:hover { color: var(--brand-600); }

/* 案例详情 */
.case-detail { display: grid; grid-template-columns: minmax(220px, 40%) 1fr; gap: 16px; align-items: start; }
.case-detail__player {
  display: grid; place-items: center; background: var(--stage);
  border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden;
}
.case-detail__player video { display: block; width: 100%; max-height: 54vh; object-fit: contain; background: #000; }
.case-detail__info { min-width: 0; }
.case-shot {
  display: flex; gap: 9px; align-items: flex-start;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-2);
}
.case-shot__n { font-size: 11px; color: var(--ink-400); padding-top: 2px; }
.case-shot b { font-size: 12px; color: var(--ink-900); }
.case-shot .tiny { line-height: 1.5; }
.tpl-band .section-head { margin-bottom: 14px; }
@media (max-width: 1180px) {
  .case-grid--v { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-grid--h { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .case-grid--v { grid-template-columns: minmax(0, 1fr); }
  .case-detail { grid-template-columns: minmax(0, 1fr); }
  .case-detail__player video { max-height: 46vh; }
}


/* Flow steps */
.flow-steps { display: flex; align-items: center; gap: 0; margin-bottom: 22px; flex-wrap: wrap; row-gap: 8px; }
.flow-step { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-500); }
.flow-step__dot {
  width: 21px; height: 21px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line-strong); font-family: var(--font-sans); font-size: 11px; font-weight: 600;
  background: var(--surface);
  transition: all 0.16s var(--ease);
}
.flow-step.is-done { color: var(--ink-700); }
.flow-step.is-done .flow-step__dot { background: var(--brand-soft); border-color: #F9DCCF; color: var(--brand-ink); }
.flow-step.is-current { color: var(--ink-950); font-weight: 600; }
.flow-step.is-current .flow-step__dot {
  background: var(--brand); border-color: var(--brand); color: var(--ink-950);
  box-shadow: 0 0 0 3px rgba(243, 107, 69, 0.14);
}
.flow-sep { width: 24px; height: 1px; background: var(--line-strong); margin: 0 8px; }

/* Workbench */
.wb { display: flex; flex-direction: column; min-height: calc(100vh - var(--topbar-h)); }
.wb__head {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 24px; border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  position: sticky; top: var(--topbar-h); z-index: 20;
}
.wb__head h2 { font-size: 16px; letter-spacing: -0.02em; color: var(--ink-950); }
.wb__head .meta { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--ink-400); }
.wb__body { flex: 1; display: flex; min-height: 0; }
/* 底部操作条是 sticky，悬浮在内容之上；不给内容区留底，
   右栏最后一组（模型行等）会被压在操作条底下点不到。 */
.wb__body--footpad { padding-bottom: 64px; }
/* 底部操作条横跨全宽会压住右栏底部的「生成模型」选择行，
   而那一行正是当前镜头要用的模型，浮在它上面点不到。
   让操作条只覆盖左栏与中栏，右栏整列始终可读可点。 */
.wb__foot--aside { width: calc(100% - 320px); }
.tab.is-disabled { opacity: .4; cursor: not-allowed; }
.tab.is-disabled:hover { opacity: .4; }
.shot-media__time {
  position: absolute; right: 8px; top: 8px;
  font-family: var(--font-mono); font-size: 11px; color: #fff;
  background: rgba(11, 12, 14, .82); padding: 2px 5px; border-radius: 3px;
}
.wb__col { min-width: 0; overflow-y: auto; overflow-x: hidden; }
.wb__aside { width: 320px; flex: none; border-left: 1px solid var(--line); background: var(--surface); }
.wb__left { width: 268px; flex: none; border-right: 1px solid var(--line); background: var(--surface); }
.wb__center { flex: 1; background: var(--paper); }
.wb__foot {
  position: sticky; bottom: 0; z-index: 20;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 24px; border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.wb__foot .spacer { flex: 1; }
.wb__foot .cost { font-size: 11.5px; color: var(--ink-500); display: flex; align-items: center; gap: 6px; }
.save-bar { position: fixed; left: var(--sidebar-w); right: 0; bottom: 0; z-index: 25; display: none; }
.save-bar.is-visible { display: flex; }
@media (max-width: 900px) { .save-bar { left: 0; } }

.col-head {
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; letter-spacing: 0.02em;
  color: var(--ink-500); font-weight: 600;
  position: sticky; top: 0; background: var(--surface-2); z-index: 2;
}
.col-head .spacer { flex: 1; }

/* Shot list */
.shot-item {
  display: flex; gap: 10px; padding: 11px 14px; cursor: pointer;
  border-bottom: 1px solid var(--line); position: relative;
  transition: background 0.12s var(--ease);
}
.shot-item:hover { background: var(--surface-2); }
.shot-item.is-active { background: var(--brand-tint); }
.shot-item.is-active::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
  background: var(--brand);
}
.shot-item__idx { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); padding-top: 2px; width: 16px; flex: none; }
.shot-item__thumb { width: 46px; height: 30px; border-radius: 6px; overflow: hidden; background: var(--surface-3); flex: none; position: relative; border: 1px solid var(--line); }
.shot-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.shot-item__main { min-width: 0; flex: 1; }
.shot-item__main b { display: block; font-size: 12px; font-weight: 500; color: var(--ink-900); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shot-item__main span { font-size: 11px; color: var(--ink-400); display: flex; gap: 6px; align-items: center; margin-top: 2px; }
.shot-item__status { width: 6px; height: 6px; border-radius: 50%; flex: none; margin-top: 5px; background: var(--ink-300); }
.shot-item__status.is-done { background: var(--success-500); }
.shot-item__status.is-running { background: var(--warn-500); animation: pulse 1.4s infinite; }
.shot-item__status.is-failed { background: var(--danger-500); }
.shot-item__drag { opacity: 0; color: var(--ink-300); cursor: grab; align-self: center; }
.shot-item:hover .shot-item__drag { opacity: 1; }
.shot-item.is-dragging { opacity: 0.4; }
.shot-item.is-drop-target { box-shadow: inset 0 2px 0 var(--brand); }

.shot-form { padding: 24px 28px 40px; max-width: 760px; }
.shot-form__title { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.shot-form__title h3 { font-size: 18px; letter-spacing: -0.025em; color: var(--ink-950); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-block { margin-bottom: 16px; }

/* Preview stage（成片预览保持深色画布：让视频成为画面里最亮的元素） */
.stage { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; position: relative; display: flex; flex-direction: column; }
.stage__screen { position: relative; background: var(--stage); display: grid; place-items: center; overflow: hidden; }
.stage__screen img { width: 100%; height: 100%; object-fit: cover; }
/* 成片预览：竖屏 / 方图 / 横屏都按原比例放进画布，宁可留边也不裁切、不拉伸 */
.stage__screen video { object-fit: contain !important; background: var(--stage); }
.stage__overlay { position: absolute; inset: 0; pointer-events: none; }
.stage__empty { color: var(--ink-400); font-size: 12px; text-align: center; padding: 30px; }
.stage__hud { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; padding: 10px 12px; color: #fff; font-size: 11px; font-family: var(--font-mono); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5); }
.stage__hud .row { display: flex; justify-content: space-between; align-items: center; }
.stage__sub { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); width: 88%; text-align: center; font-size: 12px; color: #fff; line-height: 1.45; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8); }
.stage__logo { position: absolute; right: 12px; top: 12px; display: flex; align-items: center; gap: 5px; color: rgba(255, 255, 255, 0.86); font-size: 11px; letter-spacing: 0.08em; }
.stage__logo i { width: 12px; height: 12px; border: 1px solid currentColor; border-radius: 3px; display: block; }
.stage__caption { font-size: 11px; color: var(--ink-500); padding: 8px 4px 0; display: flex; justify-content: space-between; }

/* Timeline */
.timeline { background: var(--surface); border-top: 1px solid var(--line); }
.timeline__toolbar { display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-bottom: 1px solid var(--line); font-size: 11px; color: var(--ink-500); }
/* 编辑器顶部操作区：辅助 / 次级 / 主操作用分隔线分组，避免一排同权重按钮 */
.ed-actions { display: flex; align-items: center; gap: 6px; }
.ed-actions__sep { width: 1px; height: 18px; background: var(--line); margin: 0 4px; flex: none; }
.timeline__ruler { display: flex; padding: 0 0 0 0; height: 20px; border-bottom: 1px solid var(--line); position: relative; margin: 0 14px; }
.timeline__ruler span { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); border-left: 1px solid var(--line); padding-left: 3px; flex: 1; }
.timeline__track { display: flex; align-items: center; gap: 3px; padding: 9px 14px; overflow-x: auto; }
/* 画面轨的片段是连续的：3 段 × 5s 拼成 15s，
   中间留缝会被读成「素材缺失」，这里让片段紧贴。 */
#tl-track { gap: 0; }
#tl-track .tl-clip + .tl-clip { border-left: 0; }
.tl-clip {
  position: relative; flex: none; border-radius: 6px; overflow: hidden;
  border: 1px solid var(--line); background: var(--surface-3);
  height: 54px; min-width: 68px; cursor: pointer;
  transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.tl-clip img { width: 100%; height: 100%; object-fit: cover; }
.tl-clip:hover { border-color: var(--line-strong); }
.tl-clip.is-selected { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(243, 107, 69, 0.18); }
.tl-clip__label { position: absolute; left: 4px; bottom: 2px; font-size: 11px; color: #fff; font-family: var(--font-mono); }
.tl-clip__label { background: rgba(18, 16, 26, 0.66); padding: 1px 5px; border-radius: 4px; text-shadow: none; z-index: 1; }
.tl-clip.is-dragging { opacity: 0.4; }
.tl-clip.is-over { box-shadow: inset 3px 0 0 var(--brand); }
.tl-track-label {
  width: 42px; flex: none; font-size: 11px; color: var(--ink-500);
  font-family: var(--font-mono); letter-spacing: 0.04em;
  display: flex; align-items: center; gap: 5px;
}
/* 三轨用色标区分：画面=品牌主色，音频=信息蓝，字幕=中性灰 */
.tl-track-label::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--ink-300); flex: none;
}
.tl-track--video .tl-track-label::before { background: var(--brand); }
.tl-track--audio .tl-track-label::before { background: var(--info); }
.tl-track--text  .tl-track-label::before { background: var(--ink-400); }
/* 音频轨用信息蓝：橙色是本产品的品牌主色，也是错误/警告的邻近色，
   波形再用橙红会被误读成「出错了」。 */
.tl-audio {
  height: 22px; border-radius: 6px; flex: 1; border: 1px solid var(--info-line);
  background: repeating-linear-gradient(90deg, rgba(42, 91, 153, 0.20) 0 3px, transparent 3px 6px);
  display: flex; align-items: center; padding: 0 8px; font-size: 11px; color: var(--info);
}

/* 字幕轨：中性灰，作为时间轴里最弱的一层；左侧色条标识「有字幕」 */
.tl-sub { flex: 1; display: flex; gap: 3px; overflow: hidden; }
.tl-sub__item {
  flex: 1; min-width: 0; height: 20px; border-radius: 3px;
  background: var(--surface-3); border: 1px solid var(--line);
  border-left: 2px solid var(--ink-400);
  font-size: 11px; color: var(--ink-600); padding: 0 5px;
  display: flex; align-items: center; overflow: hidden; white-space: nowrap;
}
/* 片段还没有视频素材时给占位标识，避免只剩一块空白灰板 */
.tl-clip__empty {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; color: var(--ink-400);
}

/* Creative cards */
.creative-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.creative {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden;
  transition: border-color 0.16s var(--ease), box-shadow 0.16s var(--ease), transform 0.16s var(--ease);
}
.creative:hover { border-color: #E2DCD2; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.creative.is-selected {
  border-color: var(--brand);
  box-shadow: 0 0 0 1px rgba(243, 107, 69, 0.24), var(--shadow-md);
}
.creative__head { padding: 15px 16px; border-bottom: 1px solid var(--line); display: flex; gap: 10px; align-items: flex-start; }
.creative__head h4 { font-size: 13.5px; line-height: 1.45; color: var(--ink-950); }
.creative__head .idx { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }
.creative__body { padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.creative__seg b { display: block; font-size: 11px; letter-spacing: 0.04em; color: var(--ink-400); margin-bottom: 3px; font-weight: 600; }
.creative__seg p { font-size: 12px; line-height: 1.65; color: var(--ink-700); }
.creative__script { border: 1px solid var(--line); border-radius: var(--r-sm); overflow: hidden; background: var(--surface-2); }
.script-line { display: grid; grid-template-columns: 42px 1fr; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.script-line:last-child { border-bottom: 0; }
.script-line .t { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); padding-top: 2px; }
.script-line .vo { font-size: 11.5px; line-height: 1.55; color: var(--ink-800); }
.script-line .os { font-size: 11px; color: var(--ink-400); margin-top: 2px; }
.creative__foot { padding: 11px 14px; border-top: 1px solid var(--line); display: flex; gap: 6px; align-items: center; }
.creative__foot .spacer { flex: 1; }

/* Models */
.model-row { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); transition: border-color 0.14s var(--ease), background 0.14s var(--ease); }
.model-row:hover { border-color: var(--line-strong); background: var(--surface-2); }
.model-row.is-recommended { border-color: #F9DCCF; background: var(--brand-tint); }
.model-row__logo { width: 30px; height: 30px; border-radius: 8px; background: var(--surface-3); display: grid; place-items: center; font-family: var(--font-mono); font-size: 11px; color: var(--ink-500); flex: none; border: 1px solid var(--line); }
.model-row__main { flex: 1; min-width: 0; }
.model-row__main b { font-size: 12.5px; display: flex; align-items: center; gap: 6px; color: var(--ink-900); }
.model-row__main span { font-size: 11px; color: var(--ink-400); }
.model-row__cost { text-align: right; font-family: var(--font-mono); font-size: 11px; color: var(--ink-600); flex: none; }
.model-row__cost small { display: block; font-size: 11px; color: var(--ink-400); font-family: var(--font-sans); }
.model-row__note { font-size: 11px; color: var(--ink-400); line-height: 1.5; }

/* Misc */
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--ink-400); }
.kv b { font-weight: 500; text-align: right; }
.hr { height: 1px; background: var(--line); margin: 16px 0; }
.row { display: flex; align-items: center; gap: 10px; }
.row--wrap { flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack--sm { gap: 8px; }
.spacer { flex: 1; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 4px; } .mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; } .mt-5 { margin-top: 24px; }
.mb-1 { margin-bottom: 4px; } .mb-2 { margin-bottom: 8px; } .mb-3 { margin-bottom: 12px; } .mb-4 { margin-bottom: 16px; }
.text-right { text-align: right; }
.brand-text { color: var(--brand-ink); }
.link { color: var(--brand-ink); font-size: 12px; display: inline-flex; align-items: center; gap: 3px; padding: 3px 0; margin: -3px 0; }
.link:hover { text-decoration: underline; }
.divider-v { width: 1px; height: 18px; background: var(--line); }
.media-thumb { border-radius: var(--r-sm); overflow: hidden; background: var(--surface-3); border: 1px solid var(--line); }
.media-thumb img { width: 100%; height: 100%; object-fit: cover; }
.media-thumb--sm { width: 34px; height: 34px; }
.media-thumb--md { width: 52px; height: 52px; }
.image-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.image-tile { position: relative; border-radius: var(--r-sm); overflow: hidden; aspect-ratio: 1; border: 1px solid var(--line); background: var(--surface-3); }
.image-tile img { width: 100%; height: 100%; object-fit: cover; }
.image-tile__tag {
  position: absolute; left: 5px; top: 5px; font-size: 11px; padding: 1px 5px; border-radius: 4px;
  background: rgba(255, 255, 255, 0.9); color: var(--ink-800); border: 1px solid rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.image-tile__del {
  position: absolute; right: 4px; top: 4px; width: 24px; height: 24px; border-radius: 6px;
  background: rgba(255, 255, 255, 0.92); display: grid; place-items: center; opacity: 0;
  transition: opacity 0.14s; color: var(--ink-600); border: 1px solid var(--line);
}
.image-tile:hover .image-tile__del { opacity: 1; }
.image-tile__del:hover { color: var(--danger); border-color: #F0B9C4; }
.image-tile--add { display: grid; place-items: center; border-style: dashed; color: var(--ink-400); font-size: 11px; gap: 4px; transition: border-color 0.14s var(--ease), background 0.14s var(--ease), color 0.14s var(--ease); }
.image-tile--add:hover { border-color: #F6D2C4; color: var(--brand); background: var(--brand-tint); }
.image-tile--add.is-drag { border-color: var(--brand); color: var(--brand); background: var(--brand-tint); box-shadow: inset 0 0 0 2px var(--brand-soft); }
.image-tile--add.is-uploading { border-style: solid; border-color: #F6D2C4; color: var(--brand); background: var(--brand-tint); cursor: progress; }
.im-add__idle, .im-add__busy { display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; }
.im-add__busy { display: none; }
.im-add__idle small, .im-add__busy small { font-size: 11px; color: var(--ink-400); }
.image-tile--add.is-uploading .im-add__idle { display: none; }
.image-tile--add.is-uploading .im-add__busy { display: flex; }
.im-add__busy svg { animation: im-pulse 1.1s ease-in-out infinite; }
@keyframes im-pulse { 0%, 100% { opacity: 0.45; } 50% { opacity: 1; } }

.upload-zone {
  border: 1px dashed var(--line-strong); border-radius: var(--r-md);
  padding: 24px; text-align: center; background: var(--surface-2);
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.upload-zone:hover { border-color: #F3CDBE; background: var(--brand-tint); }
.upload-zone svg { margin: 0 auto 8px; color: var(--ink-400); }
.upload-zone b { display: block; font-size: 13px; color: var(--ink-900); }
.upload-zone span { font-size: 11.5px; color: var(--ink-400); }

.alert { display: flex; gap: 10px; padding: 12px 14px; border-radius: var(--r-sm); font-size: 12px; line-height: 1.6; border: 1px solid; }
.alert svg { width: 15px; height: 15px; flex: none; margin-top: 1px; }
.alert--info { background: var(--info-soft); border-color: var(--info-line); color: var(--info); }
.alert--warn { background: var(--warn-soft); border-color: var(--warn-line); color: var(--warn); }
.alert--danger { background: var(--danger-soft); border-color: var(--danger-line); color: var(--danger); }
/* 说明型提示条保持中性底，橙色只在图标上点一下，避免大面积橙底 */
.alert--brand { background: var(--surface-2); border-color: var(--line); color: var(--ink-700); }
.alert--brand svg { color: var(--brand); }
.alert--mock { background: var(--mock-soft); border-color: var(--warn-line); color: var(--mock); }
.alert b { font-weight: 600; color: var(--ink-950); }

/* 6. Tech accents --------------------------------------------------------- */
/* Gradient hairline on feature surfaces */
.hero-copy::before,
.modal::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(243, 107, 69, 0.5), rgba(243, 107, 69, 0.28) 45%, transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
.hero-copy > * { position: relative; z-index: 1; }

/* Section title accent */
.section-head h2::after {
  content: "";
  display: block;
  width: 28px; height: 2px;
  margin-top: 7px;
  border-radius: 2px;
  background: var(--brand);
}

/* Live status dot on running tasks */
.badge--dot i,
.mode-pill i { box-shadow: 0 0 9px currentColor; }

/* Big numeric metrics */
.mono.num,
.quota-card__top b { letter-spacing: -0.02em; }

/* Subtle top highlight on cards */
.card::after {
  content: "";
  position: absolute;
  left: 16px; right: 16px; top: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  border-radius: 1px;
  pointer-events: none;
  opacity: 0.9;
}
.card { position: relative; }

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



/* 模型选择：未接入的置灰不可选 */
.model-row.is-disabled { opacity: 0.45; cursor: not-allowed; }
.model-row.is-disabled:hover { border-color: var(--line); transform: none; box-shadow: none; }

/* 真实接入状态与不确定进度 */
.mode-pill.is-ok { border-color: var(--success-line); color: var(--success); background: var(--success-soft); }
.mode-pill.is-ok i { background: var(--success-500); }

.progress--indeterminate i {
  width: 38% !important;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
  animation: indet 1.5s linear infinite;
}
.progress--indeterminate.progress--progress i,
.progress--indeterminate.progress--warn i {
  background: linear-gradient(90deg, transparent, var(--warn-500), transparent);
}
@keyframes indet {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(300%); }
}

/* 缩略图按格子裁切；只有成片画布保持原比例（见上方 .stage__screen video） */
.media-thumb video,
.shot-item__thumb video,
.tl-clip video { width: 100%; height: 100%; object-fit: cover; display: block; }
.stage__screen video { width: 100%; height: 100%; display: block; }

.media-ph { display: grid; place-items: center; width: 100%; height: 100%; background: var(--surface-3); color: var(--ink-300); }


/* 登录 / 注册 / 后台 */
body.is-auth .sidebar,
body.is-auth .topbar { display: none !important; }
body.is-auth .app { display: block; }
body.is-auth .main { min-height: 100vh; display: flex; flex-direction: column; }

.auth-wrap {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 16px; padding: 32px 20px;
}
/* 登录卡：暖白面 + 一道极淡的橙色顶边。不再用整卡渐变，卡片越"平"越显得轻 */
.auth-card {
  width: 100%; max-width: 412px;
  padding: 32px 34px 28px;
  border-radius: var(--r-xl);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}
.auth-brand { display: flex; align-items: center; gap: 9px; margin-bottom: 26px; }
.auth-brand b { font-size: 14.5px; letter-spacing: -0.01em; }
.auth-brand span:last-child { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em; color: var(--ink-400); display: block; margin-top: 1px; }
.auth-card h1 { font-size: 26px; letter-spacing: -0.035em; line-height: 1.25; }
.auth-sub { font-size: 13px; color: var(--ink-500); margin-top: 7px; line-height: 1.6; }
/* 表单与标题之间留一口气，别让输入框贴着副标题 */
.auth-form { margin-top: 26px; gap: 14px; }
.auth-error { color: var(--danger); font-size: 12px; min-height: 0; }
.auth-error:empty { display: none; }
.auth-hint { display: block; margin-top: 6px; }
.auth-hint[hidden] { display: none; }
.auth-switch { margin-top: 18px; font-size: 12.5px; color: var(--ink-500); text-align: center; }
.auth-switch a { color: var(--brand-ink); display: inline-flex; align-items: center; gap: 3px; }
.auth-switch a:hover { text-decoration: underline; }
.auth-foot { font-size: 11.5px; color: var(--ink-400); }

/* 7. Responsive ----------------------------------------------------------- */
@media (max-width: 1280px) {
  .creative-list { grid-template-columns: 1fr; }
  .home-hero { grid-template-columns: 1fr; }
  .hero-visual { min-height: 240px; }
  .wb__aside { width: 288px; }
  .wb__left { width: 232px; }
}

@media (max-width: 1080px) {
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .wb__aside { display: none; }
  .wb__aside.is-open { display: block; position: fixed; right: 0; top: var(--topbar-h); bottom: 0; z-index: 50; box-shadow: var(--shadow-lg); }
}

@media (max-width: 900px) {
  :root { --topbar-h: 56px; }
  .sidebar {
    position: fixed; left: 0; top: 0; bottom: 0;
    transform: translateX(-100%);
    transition: transform 0.24s var(--ease);
    box-shadow: var(--shadow-lg);
    width: 260px;
  }
  .sidebar.is-open { transform: none; }
  .mobile-menu { display: inline-grid; }
  .topbar { padding: 0 16px; }
  .page { padding: 18px 16px 48px; }
  .page-head { flex-direction: column; align-items: stretch; }
  .page-head__actions { justify-content: flex-start; }
  .page-head h1 { font-size: 23px; }
  .hero-copy { padding: 24px; }
  .hero-copy h1 { font-size: 27px; }
  .wb__body { flex-direction: column; }
  .wb__left { width: 100%; border-right: 0; border-bottom: 1px solid var(--line); max-height: 210px; }
  .wb__center { min-height: auto; }
  .form-row { grid-template-columns: 1fr; }
  .flow-steps { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  .flow-step { white-space: nowrap; }
  .topbar__crumbs { max-width: 52vw; overflow: hidden; }
  .topbar__crumbs a, .topbar__crumbs .crumb-divider { display: none; }
  .topbar__crumbs b { overflow: hidden; text-overflow: ellipsis; }
  .mode-pill span.long { display: none; }
  .grid--2 { grid-template-columns: 1fr; }
  .creative-list { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .wb__foot { flex-wrap: wrap; row-gap: 8px; }
  .wb__foot .spacer { display: none; }
  .wb__foot .cost { flex: 1 1 auto; }
  .timeline__toolbar { flex-wrap: wrap; row-gap: 6px; }
}

@media (max-width: 640px) {
  .grid--3, .grid--4, .grid--auto { grid-template-columns: 1fr; }
  .mode-pill span { display: none; }
  .mode-pill { padding: 0 9px; }
  .hide-sm { display: none !important; }
  .stat-strip { grid-template-columns: 1fr 1fr; }
  .page-head__actions { width: 100%; flex-wrap: wrap; }
  .page-head__actions .btn { flex: 1; }
  .modal { max-height: calc(100vh - 32px); }
  .scrim { padding: 16px; }
  .wb__head { padding: 10px 14px; flex-wrap: wrap; }
  .wb__foot { padding: 10px 14px; }
  .shot-form { padding: 16px; }
  .image-grid { grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); }
}

/* ------------------------- 首页精简版（三步起步 / 播放角标） ------------------------- */
.start-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}
.start-step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 16px 18px 16px 54px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(243, 107, 69, 0.05), rgba(255, 255, 255, 0.015));
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease), background 0.2s var(--ease);
}
.start-step:hover {
  border-color: rgba(243, 107, 69, 0.5);
  transform: translateY(-2px);
  background: linear-gradient(180deg, rgba(243, 107, 69, 0.1), rgba(255, 255, 255, 0.02));
}
.start-step b { font-size: 14px; color: var(--ink-900); }
.start-step span:last-child { font-size: 12px; color: var(--ink-500); line-height: 1.5; }
.start-step__no {
  position: absolute;
  left: 16px;
  top: 16px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-mono, monospace);
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
  background: var(--brand);
}

.play-badge {
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(6, 7, 10, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  font-size: 11.5px;
  font-weight: 500;
  backdrop-filter: blur(6px);
}
.hero-visual video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.92;
  transition: transform 0.7s var(--ease);
}
.hero-visual:hover video { transform: scale(1.03); }

@media (max-width: 900px) {
  .start-steps { grid-template-columns: 1fr; }
}
.product-card__media > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
button.link { background: none; border: 0; padding: 3px 0; margin: -3px 0; cursor: pointer; font: inherit; min-height: 24px; }

/* 登录页：双通道 */
.btn-ico { display: inline-flex; align-items: center; margin-right: 8px; }
.btn-ico svg { width: 17px; height: 17px; }
.code-row { display: flex; gap: 8px; align-items: stretch; }
.code-row .input { flex: 1; min-width: 0; }
.code-row .btn { white-space: nowrap; }
.auth-note {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--ink-400);
  text-align: center;
}

/* 登录页帮助：默认只是一行文字按钮，点开才展开四条排查建议。
   收件问题属于低频信息，不该在主表单下面先铺一段"帮助文档"。 */
.auth-help-toggle {
  display: flex; align-items: center; gap: 5px;
  margin: 16px auto 0;
  padding: 4px 2px;
  border: 0; background: none; cursor: pointer;
  font-family: inherit; font-size: 12px; color: var(--ink-500);
}
.auth-help-toggle b { font-weight: 500; color: var(--brand-ink); }
.auth-help-toggle svg { color: var(--ink-400); transition: transform 0.18s var(--ease); }
.auth-help-toggle:hover b { text-decoration: underline; }
.auth-help-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.auth-help {
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface-2);
}
.auth-help[hidden] { display: none; }
.auth-help__list {
  display: grid;
  gap: 5px;
  list-style: none;
  margin: 0;
  padding: 0;
}
/* 逐条列出而不是排成一排胶囊：四条建议读起来像清单，不像一堆标签 */
.auth-help__list li {
  position: relative;
  padding-left: 13px;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--ink-500);
}
.auth-help__list li::before {
  content: '';
  position: absolute; left: 3px; top: 8px;
  width: 3px; height: 3px; border-radius: 50%;
  background: var(--ink-300);
}

/* ==========================================================================
   LIGHT STUDIO — 视觉升级 2026-11
   浅灰白画布 + 白色内容面 + #F36B45 单一主色；轻边框分层，阴影只做极轻浮起。
   本层只覆盖颜色与质感，以及新组件的骨架，不改任何业务尺寸与交互行为。
   ========================================================================== */

/* 清理上一版遗留的装饰层：渐变描边、卡片顶部高光、标题下划线、弹窗屏光 */
.hero-copy::before,
.modal::before,
.card::after,
.section-head h2::after { display: none; }

/* 顶栏 / 侧栏 */
.topbar { border-bottom-color: var(--line); }
.mode-pill i { box-shadow: none; }
.nav-item.is-active .nav-count { background: #FBE2D8; color: var(--brand-ink); }

/* 卡片与浮层 */
.card { box-shadow: var(--shadow-xs); }
.card--hover:hover { border-color: #E2DCD2; }
.panel { background: var(--surface-2); }

/* 按钮 */
.btn--primary { background: var(--brand); }
.btn--primary:hover { background: var(--brand-600); }
.btn--brand { background: var(--brand); }
.btn.is-loading::after { border-color: rgba(255, 255, 255, 0.45); border-top-color: #fff; }
.btn--secondary.is-loading::after,
.btn--ghost.is-loading::after,
.btn--quiet.is-loading::after { border-color: var(--line-strong); border-top-color: var(--brand); }

/* 表单 */
.input:focus, .textarea:focus, .select:focus { box-shadow: 0 0 0 3px rgba(243, 107, 69, 0.14); }
.switch input:checked + span { box-shadow: none; }

/* 压图徽标：白色玻璃底，比暗色胶囊更干净 */
.product-card__media .badge,
.product-card__media .play-badge,
.template-card__media .badge {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(255, 255, 255, 0.7);
  color: var(--ink-800);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.play-badge {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: var(--ink-900);
}

/* 压在图片上的操作徽标：统一白玻璃底，避免深色块打断浅色界面 */
.overlay-btn {
  position: absolute; right: 10px; top: 10px; z-index: 2;
  display: inline-flex; align-items: center; gap: 4px;
  height: 26px; padding: 0 10px; border-radius: var(--r-full);
  font-size: 11px; font-weight: 600;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.72);
  color: var(--ink-900);
  box-shadow: 0 4px 12px -6px rgba(18, 18, 18, 0.42);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  transition: background 0.14s var(--ease), transform 0.14s var(--ease);
}
.overlay-btn:hover { background: #fff; transform: translateY(-1px); }
.overlay-btn--pick {
  left: 8px; right: auto; top: 8px; width: 20px; height: 20px; padding: 0;
  border-radius: 6px; justify-content: center;
  background: rgba(255, 255, 255, 0.86); color: transparent;
}
.overlay-btn--pick.is-on { background: var(--brand); border-color: var(--brand); color: var(--ink-950); }

/* 首页起步卡 */
.start-step { background: var(--surface); border-color: var(--line); }
.start-step:hover { background: var(--surface); border-color: #F6D2C4; box-shadow: var(--shadow-md); }
.start-step__no { background: var(--brand-soft); color: var(--brand-600); }
.start-step b { color: var(--ink-950); }

/* 登录 */
.auth-brand b { color: var(--ink-950); }
/* 帮助块要比白卡深一档才看得出是"另开的抽屉"，用页面底色而不是近白 */
.auth-help { background: var(--paper); }

/* 工作台右栏预览区在浅色下同样用纸感底 */
.wb__center { background: var(--paper); }
.wb__foot { box-shadow: 0 -1px 0 var(--line); }

/* ==========================================================================
   新人友好：可折叠的「更多设置」
   折叠按钮上直接显示当前值，让用户不展开也知道系统替他填了什么。
   ========================================================================== */
.more-toggle .btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px dashed var(--line-strong); border-radius: var(--r-sm);
  background: var(--surface-2); padding: 10px 14px;
}
.more-toggle .btn:hover { border-color: rgba(243, 107, 69, 0.55); background: var(--brand-tint); }
.more-toggle .btn .tiny { flex: 1; text-align: left; color: var(--ink-500); }
.more-toggle .btn svg:last-of-type { transition: transform 0.18s var(--ease); color: var(--ink-400); }
.more-toggle .btn.is-open { border-style: solid; }
.more-toggle .btn.is-open svg:last-of-type { transform: rotate(180deg); }

/* 7. 商品图创作工作台 ----------------------------------------------------- */
.pi-aside { border-right: 1px solid var(--line); }
.pi-aside.is-drag { outline: 2px dashed rgba(243, 107, 69, 0.6); outline-offset: -6px; background: var(--brand-tint); }
/* 商品图创作左栏表单密集、右栏内容少：左栏给足宽度，
   右栏内容限宽居中，空白分到两侧而不是全堆在右边。 */
.pi-aside { width: 420px !important; }
.pi-stage > * { max-width: 860px; margin-left: auto; margin-right: auto; }
.pi-pane { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.pi-pane:last-child { border-bottom: 0; }
.pi-pane__label {
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-400); font-weight: 600; margin-bottom: 10px;
}

.pi-drop { cursor: pointer; width: 100%; display: block; }
.pi-drop svg { color: var(--ink-400); }

.pi-preview { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-3); }
.pi-preview img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pi-preview__x {
  position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; border-radius: 7px;
  background: rgba(255, 255, 255, 0.94); color: var(--ink-700); display: grid; place-items: center;
  border: 1px solid var(--line);
}
.pi-preview__x:hover { color: var(--danger); border-color: rgba(224, 112, 138, 0.5); }

/* 场景模板改成了下拉（10 个模板摊成卡片太占左栏），卡片样式一并删掉 */

/* 出图方式：保真合成 / AI 创意 */
.pi-mode { display: grid; gap: 8px; }
.pi-mode__item {
  display: flex; flex-direction: column; gap: 2px; text-align: left;
  padding: 9px 11px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface-2); cursor: pointer;
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease);
}
.pi-mode__item:hover { border-color: var(--line-strong); background: var(--surface-3); }
.pi-mode__item.is-active {
  border-color: rgba(243, 107, 69, 0.62); background: var(--brand-tint);
  box-shadow: inset 0 0 0 1px rgba(243, 107, 69, 0.22);
}
.pi-mode__item b { font-size: 12.5px; font-weight: 500; color: var(--ink-900); }
.pi-mode__item span { font-size: 11px; color: var(--ink-400); line-height: 1.5; }

.pi-stage { padding: 20px 24px 30px; min-width: 0; }
.pi-stage__head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
/* min-width:0 是关键：图片的固有宽度会参与 grid 列的 min-content 计算，
   不压住它，一张 1024 的图就能把整行撑成一列，六类图会被拉成一条竖长条。 */
/* 六类图两列排开：每类通常 1–2 张，单列会让一屏只放得下两类。
   两列之后同一屏能看到四类，且卡片仍是竖版缩略图的正常比例。 */
.pi-kits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 14px; }
@media (max-width: 1180px) { .pi-kits { grid-template-columns: minmax(0, 1fr); } }

/* 卡片宽度固定、横向排开：一套图里每类只有 1–4 张，用 grid 分列会让远不满行的行
   留出大块空白。固定宽度 + wrap 既保证缩略图大小一致，也能排满一行。 */
.pi-res { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-start; }
.pi-res__card { width: 232px; max-width: 100%; flex: none; }
@media (max-width: 900px) { .pi-res__card { width: 168px; } }
.pi-res__card { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface-2); position: relative; min-width: 0; }
.pi-res__img { width: 100%; display: block; cursor: zoom-in; background: var(--surface-3); }
.pi-res__bar { display: flex; align-items: center; gap: 4px; padding: 7px 8px; border-top: 1px solid var(--line); background: var(--surface); }

/* 每张图自己说明"这张是什么类型、什么构图、什么保真档"，
   用户不必回头翻左侧配置才知道这六张分别按什么规则生成的 */
.pi-res__tags {
  display: flex; align-items: center; gap: 4px; flex-wrap: wrap;
  padding: 7px 8px 0;
}
.pi-tag {
  font-size: 11px; line-height: 1.6;
  padding: 1px 6px; border-radius: 4px;
  color: var(--ink-500); background: var(--surface); border: 1px solid var(--line);
  white-space: nowrap;
}
/* 质检行：通过的用中性提示，未通过的才允许出现颜色 */
.pi-qc-line {
  display: flex; align-items: center; gap: 4px;
  margin: 6px 8px 0; padding: 3px 6px; border-radius: 5px;
  font-size: 11px; line-height: 1.5;
}
.pi-qc-line svg { flex: none; }
.pi-qc-line span { min-width: 0; }
.pi-qc-line.is-ok { color: var(--ink-500); background: var(--surface); }
.pi-qc-line.is-bad { color: var(--danger); background: var(--danger-soft); border: 1px solid var(--danger-line); }
.pi-res__card.is-flagged { border-color: var(--danger-line); }
/* 单张重做中的卡片：压住画面，避免用户以为卡住了 */
.pi-res__card.is-busy .pi-res__img,
.pi-res__card.is-busy .pi-copywrap { opacity: 0.35; filter: saturate(0.6); }
.pi-res__card.is-busy::after {
  content: '重新生成中…';
  position: absolute; left: 0; right: 0; top: 42%;
  text-align: center; font-size: 12px; color: var(--ink-700);
}

.pi-kit__goal { font-size: 11px; color: var(--ink-400); margin-left: 2px; }

.pi-empty { max-width: 560px; margin: 5vh auto 0; text-align: center; }
.pi-empty h3 { font-size: 18px; letter-spacing: -0.02em; margin: 20px 0 8px; }
.pi-empty p { color: var(--ink-500); font-size: 13px; line-height: 1.75; }
.pi-empty__steps { display: flex; justify-content: center; gap: 26px; }
.pi-empty__steps div { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.pi-empty__steps b {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: var(--brand-tint); color: var(--brand-ink); font-size: 14px;
  border: 1px solid rgba(243, 107, 69, 0.3);
}
.pi-empty__steps span { font-size: 12px; color: var(--ink-400); }
.pi-note {
  display: flex; gap: 9px; text-align: left; margin-top: 22px; padding: 12px 14px;
  border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line);
  color: var(--ink-500); font-size: 11.5px; line-height: 1.7;
}
.pi-note svg { flex: none; margin-top: 2px; color: var(--ink-400); }

@media (max-width: 1080px) {
  .pi-aside { width: 100% !important; border-right: 0; border-bottom: 1px solid var(--line); }
  .wb__body:has(.pi-aside) { flex-direction: column; }
}

.pi-lib { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.pi-lib__item {
  display: flex; align-items: center; gap: 10px; text-align: left; width: 100%;
  padding: 8px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface-2); cursor: pointer;
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease);
}
.pi-lib__item:hover { border-color: rgba(243, 107, 69, 0.55); background: var(--brand-tint); }
.pi-lib__thumb {
  width: 52px; height: 52px; flex: none; border-radius: 8px; overflow: hidden;
  background: var(--surface-3); display: grid; place-items: center; color: var(--ink-400);
}
.pi-lib__thumb img { width: 100%; height: 100%; object-fit: cover; }
.pi-lib__meta { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pi-lib__meta b { font-size: 12.5px; font-weight: 500; color: var(--ink-900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 表格与卡片里的文字链接：点击区统一扩到 ≥24px，
   负外边距抵消视觉间距，不改变版面 */
.table td a.small, .table td a.small.truncate { padding: 3px 0; margin: -3px 0; display: inline-block; }
/* 这条链接在 flex 列容器里：负 margin 会把 padding 抵消掉，点击区扩不上去。
   改用 min-height + 居中，视觉不变而点击区达到 24px。 */
.product-card__body > a { display: flex; align-items: center; min-height: 24px; }

/* 窄屏下任务表优先留「进度 / 状态 / 操作」：
   模型、模式、费用属于次要信息，继续占宽度会把状态整个挤出屏幕。 */
@media (max-width: 640px) {
  .table th.col-model, .table td.col-model,
  .table th.col-mode, .table td.col-mode,
  .table th.col-cost, .table td.col-cost { display: none; }
  .table th, .table td { padding: 9px 8px; }
  .table-wrap { -webkit-overflow-scrolling: touch; }
}

/* ---------------------- 商品图创作：套图工作台 ---------------------- */
.pi-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px 14px 0; }
.pi-tab {
  position: relative; height: 34px; border-radius: 9px; border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink-700); font-size: 12px; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.pi-tab:hover { border-color: var(--line-strong); color: var(--ink-900); }
.pi-tab.is-active {
  background: var(--brand); border-color: transparent;
  /* 橙底配白字只有 3.0:1，达不到正文可读标准；配墨色是 6.1:1 */
  color: var(--ink-950); font-weight: 600; box-shadow: 0 6px 18px -8px rgba(243, 107, 69, .9);
}
.pi-tab.is-soon { opacity: .5; cursor: not-allowed; }
.pi-tab__soon {
  position: absolute; top: -6px; right: -4px; font-size: 11px; padding: 1px 5px; border-radius: 6px;
  background: var(--surface-4); color: var(--ink-500); border: 1px solid var(--line);
}
.pi-subnote { padding: 10px 16px 0; font-size: 11.5px; color: var(--ink-500); line-height: 1.6; }
.pi-pane__count { float: right; font-size: 11px; font-weight: 400; color: var(--ink-400); letter-spacing: 0; text-transform: none; }

.pi-shots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pi-shot {
  position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--line); background: var(--surface-3); padding: 0;
}
.pi-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pi-shot.is-main { border-color: rgba(243, 107, 69, .85); box-shadow: 0 0 0 1px rgba(243, 107, 69, .45) inset; }
.pi-shot__badge {
  position: absolute; left: 4px; bottom: 4px; font-size: 11px; padding: 1px 5px; border-radius: 5px;
  background: rgba(243, 107, 69, .92); color: var(--ink-950);
}
.pi-shot__x {
  position: absolute; top: 3px; right: 3px; width: 18px; height: 18px; border-radius: 50%;
  display: grid; place-items: center; border: 1px solid rgba(255, 255, 255, .8);
  background: rgba(255, 255, 255, .94); color: var(--ink-800); cursor: pointer; padding: 0;
}
.pi-shot__x:hover { background: var(--danger-500); border-color: transparent; }
.pi-shot--add {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  border-style: dashed; color: var(--ink-400); font-size: 11px; cursor: pointer;
}
.pi-shot--add:hover { border-color: rgba(243, 107, 69, .55); color: var(--ink-700); background: var(--brand-tint); }

.pi-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

.pi-step {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2);
  margin-bottom: 6px;
}
.pi-step.is-off { opacity: .45; }
.pi-step__main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pi-step__main b { font-size: 12.5px; font-weight: 500; color: var(--ink-900); }
.pi-step__main span { font-size: 11px; color: var(--ink-400); line-height: 1.4; }
.pi-step__ctrl { display: flex; align-items: center; gap: 6px; flex: none; }
.pi-step__btn {
  width: 24px; height: 24px; border-radius: 6px; border: 1px solid var(--line);
  background: var(--surface-3); color: var(--ink-700); font-size: 14px; line-height: 1; cursor: pointer;
}
.pi-step__btn:hover:not(:disabled) { border-color: rgba(243, 107, 69, .6); color: #fff; }
.pi-step__btn:disabled { opacity: .35; cursor: not-allowed; }
.pi-step__n { width: 16px; text-align: center; font-size: 12.5px; color: var(--ink-900); font-variant-numeric: tabular-nums; }

.pi-suite-preview { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 20px 0 4px; text-align: left; }
.pi-suite-preview__cell {
  border: 1px dashed var(--line-strong); border-radius: 10px; padding: 10px 12px;
  background: var(--surface-2);
}
.pi-suite-preview__cell span { display: block; font-size: 12.5px; color: var(--ink-900); font-weight: 500; }
.pi-suite-preview__cell em { display: block; font-style: normal; font-size: 11px; color: var(--ink-400); margin-top: 3px; }

.pi-kit { margin-bottom: 18px; }
.pi-kit__head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.pi-kit__head b { font-size: 13px; color: var(--ink-900); letter-spacing: -0.01em; }

.pi-copywrap { position: relative; }
.pi-copycanvas { position: absolute; inset: 0; width: 100%; height: 100%; display: none; }
.pi-copycanvas.is-ready { display: block; }
/* 叠字画好后只把原图「藏起来」而不移除：它还要继续撑开容器高度，
   否则绝对定位的 canvas 会随着父级塌成 0 高，整张图在列表里就消失了。 */
.pi-res__img.pi-img--off { visibility: hidden; }

/* ---------------------- 商品图创作：详情页与爆款复刻 ---------------------- */
.is-hidden { display: none !important; }

/* 详情页模块列表：一张一行，左侧是序号与用途，右侧是成图 */
.pi-long { display: flex; flex-direction: column; gap: 14px; }
.pi-long__row {
  display: grid; grid-template-columns: 96px 1fr 96px; gap: 12px; align-items: start;
  padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2);
}
.pi-long__meta { display: flex; flex-direction: column; gap: 2px; padding-top: 2px; }
.pi-long__meta b { font-size: 15px; color: var(--ink-900); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.pi-long__meta span { font-size: 12px; color: var(--ink-700); }
.pi-long__meta em { font-size: 11px; color: var(--ink-400); font-style: normal; }
.pi-long__shot {
  border-radius: 8px; overflow: hidden; background: var(--surface-3); display: grid; place-items: center;
  max-height: 420px;
}
.pi-long__shot .pi-res__img { max-height: 420px; width: auto; max-width: 100%; display: block; }
.pi-long__shot .pi-copycanvas { max-height: 420px; width: auto; max-width: 100%; }
.pi-long__acts { display: flex; flex-direction: column; gap: 6px; }
.pi-long__acts .btn { justify-content: flex-start; }

/* 参考图分析摘要：色卡 + 四个量化指标 */
.pi-analyze {
  margin-top: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--surface-2);
}
.pi-analyze__head {
  display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--ink-400);
  letter-spacing: .04em; text-transform: uppercase; margin-bottom: 8px;
}
.pi-swatches { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.pi-swatch {
  display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--ink-400);
  font-variant-numeric: tabular-nums;
}
.pi-swatch i {
  width: 14px; height: 14px; border-radius: 4px; border: 1px solid var(--line-strong); display: block;
}
.pi-analyze__rows {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; font-size: 11.5px; color: var(--ink-400);
}
.pi-analyze__rows b { color: var(--ink-900); font-weight: 600; }

/* ==========================================================================
   STUDIO 组件层 V2.0 — Modern Creative × AI Studio
   首页 / 灵感广场 / 我的作品 / 视频创作工作台 / 个人中心
   命名约定：块__元素--变体，不新增全局工具类
   ========================================================================== */

/* ---------- 1. 首页主视觉 ---------- */
.studio-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: 14px;
  margin-bottom: 16px;
}
.studio-hero__copy {
  position: relative;
  padding: 36px 40px 32px;
  border: 1px solid var(--line);
  border-radius: var(--r-2xl);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}
/* 唯一的装饰：右上两圈极淡的品牌色弧线，不铺渐变 */
.studio-hero__copy::before,
.studio-hero__copy::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(243, 107, 69, 0.12);
  pointer-events: none;
}
.studio-hero__copy::before { right: -132px; top: -168px; width: 396px; height: 396px; }
.studio-hero__copy::after { right: -74px; top: -104px; width: 300px; height: 300px; border-color: rgba(243, 107, 69, 0.07); }
.studio-hero__copy > * { position: relative; z-index: 1; }

.studio-hero__brandline { display: flex; align-items: center; gap: 10px; }
.studio-hero__brand {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-950);
}
.studio-hero__brand i {
  width: 15px; height: 15px; border-radius: 5px;
  background: var(--brand); flex: none;
  box-shadow: 0 3px 8px -3px rgba(243, 107, 69, 0.7);
}
.studio-hero__brandline .rule { flex: 1; height: 1px; background: var(--line); min-width: 16px; }
.studio-hero__issue {
  font-family: var(--font-mono); font-size: 11px;
  letter-spacing: 0.06em; color: var(--ink-400); white-space: nowrap;
}
.studio-hero__title {
  font-size: clamp(30px, 3.2vw, 44px);
  line-height: 1.12; letter-spacing: -0.045em;
  color: var(--ink-950); margin: 18px 0 14px; font-weight: 700;
}
.studio-hero__title span { display: block; }
.studio-hero__title em { font-style: normal; color: var(--brand-600); }
.studio-hero__title .mark {
  font-style: normal; color: var(--ink-950);
  background: linear-gradient(180deg, transparent 58%, var(--accent-soft) 58%);
  padding: 0 2px;
}
.studio-hero__sub {
  font-size: 13.5px; color: var(--ink-600);
  line-height: 1.8; max-width: 452px;
}
/* Hero 里的次级动作弱化为文字按钮，把实心橙留给唯一的主操作 */
.studio-hero__actions .btn--secondary {
  background: transparent;
  border-color: transparent;
  color: var(--ink-700);
  padding-left: 10px; padding-right: 12px;
}
.studio-hero__actions .btn--secondary:hover {
  background: var(--surface-3);
  border-color: transparent;
  color: var(--ink-950);
}
.studio-hero__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 24px; }
.studio-hero__meta {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line);
}
.studio-hero__meta span { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; color: var(--ink-500); }
.studio-hero__meta b { color: var(--ink-950); font-weight: 650; font-variant-numeric: tabular-nums; }
.studio-hero__meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--ink-300); }

/* 右侧沉浸式预览：深色舞台铺满，信息压在画面底部 */
.studio-hero__stage {
  position: relative; overflow: hidden;
  border-radius: var(--r-2xl); background: var(--stage);
  min-height: 366px; cursor: pointer;
}
.studio-hero__stage video,
.studio-hero__stage img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: 0.95;
  transition: transform 0.9s var(--ease), opacity 0.3s var(--ease);
}
.studio-hero__stage:hover video,
.studio-hero__stage:hover img { transform: scale(1.035); opacity: 1; }
.studio-hero__stage::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(21, 21, 27, 0.42) 0%, rgba(21, 21, 27, 0) 30%, rgba(21, 21, 27, 0.9) 100%);
}
.studio-hero__stage-top {
  position: absolute; left: 15px; right: 15px; top: 14px; z-index: 2;
  display: flex; align-items: center; gap: 7px;
}
.studio-hero__tag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 23px; padding: 0 9px; border-radius: var(--r-full);
  font-size: 11px; font-weight: 600; color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.studio-hero__dot {
  width: 5px; height: 5px; border-radius: 50%; background: #5BE49B;
  box-shadow: 0 0 0 3px rgba(91, 228, 155, 0.18);
}
.studio-hero__stage-no {
  margin-left: auto; font-family: var(--font-mono);
  font-size: 11px; color: rgba(255, 255, 255, 0.55); letter-spacing: 0.06em;
}
.studio-hero__info { position: absolute; left: 18px; right: 18px; bottom: 16px; z-index: 2; color: #fff; }
.studio-hero__info b { display: block; font-size: 14px; font-weight: 650; letter-spacing: -0.01em; }
.studio-hero__info span { font-size: 11px; color: rgba(255, 255, 255, 0.6); line-height: 1.6; display: block; margin-top: 3px; max-width: 86%; }
.studio-hero__timeline {
  margin-top: 11px; height: 3px; border-radius: 2px;
  background: rgba(255, 255, 255, 0.22); overflow: hidden;
}
.studio-hero__timeline i { display: block; height: 100%; width: 34%; background: #fff; border-radius: 2px; }
.studio-hero__play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 2;
  width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.94); color: var(--ink-950);
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, 0.8);
  transition: transform 0.2s var(--ease);
}
.studio-hero__stage:hover .studio-hero__play { transform: translate(-50%, -50%) scale(1.07); }

/* ---------- 2. 三个创作入口 + 极简创作 ---------- */
.entry-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.entry {
  position: relative; display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); overflow: hidden; text-align: left;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease);
}
.entry:hover { border-color: var(--art-line); box-shadow: 0 10px 28px -12px rgba(23, 23, 32, 0.18); transform: translateY(-3px); }
.entry__art {
  position: relative; height: 108px; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: var(--art-bg, var(--surface-3));
  border-bottom: 1px solid var(--line); overflow: hidden;
}
/* 插画用内联 SVG：盒子在浅底上会糊成一片，矢量图形才稳定 */
.entry__art svg { display: block; width: 100%; height: 96px; }
.entry__art rect,
.entry__art circle {
  fill: #fff; stroke: var(--art-line, rgba(23, 23, 32, 0.22)); stroke-width: 1.5;
  transition: transform 0.26s var(--ease);
}
.entry__art .f { stroke: none; }
.entry__art .c-brand { fill: var(--brand); }
.entry__art .c-brand-soft { fill: #FBE3DA; }
.entry__art .c-accent { fill: var(--brand-600); }
.entry__art .c-blue { fill: #4E7BE6; }
.entry__art .c-blue-soft { fill: #E6EDFB; }
.entry__art .c-green { fill: #2FA98A; }
.entry__art .c-green-soft { fill: #E2F2EC; }
.entry__art .c-ink { fill: #4A4A4A; }
.entry:hover .entry__art .lift { transform: translateY(-2px); }
.entry__art svg .c-brand-soft,
.entry__art svg .c-blue-soft,
.entry__art svg .c-green-soft { transition: transform 0.26s var(--ease); }
.entry:hover .entry__art svg .c-brand-soft,
.entry:hover .entry__art svg .c-blue-soft,
.entry:hover .entry__art svg .c-green-soft { transform: scale(1.04); }

/* 三个入口的插画底色可以不同，但行动色必须是同一个：
   同一屏出现橙/蓝/绿三个饱和 CTA 会把注意力摊薄，用户不知道该点哪个。 */
.entry--video { --art-bg: linear-gradient(135deg, #FCEBE3 0%, #FDF6F1 100%); --art-line: rgba(217, 77, 47, 0.30); --go: var(--brand-ink); }
.entry--image { --art-bg: linear-gradient(135deg, #EAF0FC 0%, #F5F7FD 100%); --art-line: rgba(78, 123, 230, 0.26); --go: var(--brand-ink); }
.entry--ad { --art-bg: linear-gradient(135deg, #E2F2EC 0%, #F2F9F6 100%); --art-line: rgba(47, 169, 138, 0.26); --go: var(--brand-ink); }
.entry--remix { --art-bg: linear-gradient(135deg, #EDE7DC 0%, #F7F3EB 100%); --art-line: rgba(23, 23, 23, 0.24); --go: var(--brand-ink); }

.entry__body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.entry__title { display: flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 650; color: var(--ink-950); letter-spacing: -0.01em; }
.entry__title svg { color: var(--ink-400); }
.entry__desc { font-size: 11.5px; color: var(--ink-500); line-height: 1.6; }
.entry__go {
  margin-top: auto; padding-top: 9px;
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11.5px; font-weight: 600; color: var(--go, var(--brand-ink));
}
.entry__go svg { transition: transform 0.18s var(--ease); }
.entry:hover .entry__go svg { transform: translateX(3px); }

/* ---------- 2.1 极简创作：一行说完就出片 ---------- */
.quick {
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); box-shadow: var(--shadow-xs);
  padding: 13px 15px 11px; margin-bottom: 26px;
}
.quick__head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 11px; }
.quick__title {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13.5px; font-weight: 650; color: var(--ink-950); letter-spacing: -0.01em;
}
.quick__title svg { color: var(--brand); }
.quick__hint { font-size: 11.5px; color: var(--ink-500); }
.quick__cost {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; color: var(--ink-600);
}
.quick__cost svg { color: var(--ink-400); }
.quick__cost b { color: var(--ink-950); font-size: 13px; font-weight: 700; }

.quick__body { display: flex; align-items: flex-end; gap: 8px; }

/* 商品图位：极简不代表可以不要图，所有视频模型都是图生视频 */
.quick__img {
  flex: none; width: 54px; height: 54px; padding: 0;
  display: grid; place-items: center; overflow: hidden;
  border: 1px dashed var(--field-line); border-radius: var(--r-md);
  background: var(--surface-2); cursor: pointer;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}
.quick__img:hover { border-color: var(--brand); background: var(--brand-tint); }
.quick__img.need { border-color: var(--danger); background: var(--danger-soft); }
.quick__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.quick__img-ph { display: grid; place-items: center; gap: 1px; color: var(--ink-400); }
.quick__img-ph svg { display: block; }
.quick__img-ph em { font-style: normal; font-size: 11px; letter-spacing: 0.02em; }

.quick__field { min-width: 0; }
.quick__field--grow { flex: 1 1 auto; }
.quick__input {
  width: 100%; height: 54px; min-height: 54px; resize: none;
  padding: 8px 11px; font-size: 12.5px; line-height: 1.55;
}

.quick__pick { flex: none; display: flex; flex-direction: column; gap: 3px; }
.quick__pick > span { font-size: 11px; color: var(--ink-400); padding-left: 2px; letter-spacing: 0.02em; }
.quick__pick .select {
  height: 34px; min-height: 34px; padding: 0 26px 0 9px;
  font-size: 12px; border-radius: var(--r-sm);
}
.quick__pick--wide .select { max-width: 172px; }
.quick__go { flex: none; height: 40px; padding: 0 18px; }

.quick__foot { display: flex; align-items: center; gap: 6px; margin-top: 9px; }
.quick__foot .link { font-size: 11px; }

/* ---------- 3. 区块标题（杂志目录感） ---------- */
.studio-section { margin-top: 26px; }
.studio-section__head { display: flex; align-items: flex-end; gap: 12px; margin-bottom: 13px; }
.studio-section__head h2 {
  display: flex; align-items: center; gap: 9px;
  font-size: 17px; font-weight: 700; letter-spacing: -0.025em; color: var(--ink-950);
}
.studio-section__no {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-400); letter-spacing: 0.08em; padding-top: 2px;
}
.studio-section__head p { font-size: 12px; color: var(--ink-500); margin-top: 3px; }
.studio-section__head .spacer { flex: 1; }

/* ---------- 4. 热门模板：一大四小 ---------- */
.tpl-board { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 12px; }
.tpl-feat {
  position: relative; display: block; min-height: 246px;
  border-radius: var(--r-lg); overflow: hidden; background: var(--stage); cursor: pointer;
}
.tpl-feat img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: 0.92;
  transition: transform 0.8s var(--ease), opacity 0.3s var(--ease);
}
.tpl-feat:hover img { transform: scale(1.045); opacity: 1; }
.tpl-feat::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(21, 21, 27, 0.06) 24%, rgba(21, 21, 27, 0.9) 100%);
}
.tpl-feat__no {
  position: absolute; right: 16px; top: 14px; z-index: 2;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
}
.tpl-feat__body { position: absolute; left: 18px; right: 18px; bottom: 16px; z-index: 2; color: #fff; }
.tpl-feat__kicker {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em;
  text-transform: uppercase; color: rgba(255, 255, 255, 0.62);
}
.tpl-feat__name { font-size: 18px; font-weight: 700; letter-spacing: -0.025em; margin-top: 6px; }
.tpl-feat__desc { font-size: 11.5px; color: rgba(255, 255, 255, 0.66); line-height: 1.6; margin-top: 5px; }
.tpl-feat__go {
  margin-top: 12px; display: inline-flex; align-items: center; gap: 5px;
  height: 30px; padding: 0 13px; border-radius: var(--r-full);
  background: #fff; color: var(--ink-950); font-size: 11.5px; font-weight: 600;
  transition: gap 0.18s var(--ease);
}
.tpl-feat:hover .tpl-feat__go { gap: 8px; }

.tpl-list {
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); overflow: hidden; display: flex; flex-direction: column;
}
.tpl-row {
  display: grid; grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center; gap: 10px;
  padding: 0 14px; flex: 1; min-height: 52px;
  border-bottom: 1px solid var(--line); cursor: pointer; text-align: left;
  transition: background 0.15s var(--ease);
}
.tpl-row:last-child { border-bottom: 0; }
.tpl-row:hover { background: var(--brand-tint); }
.tpl-row__no { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }
.tpl-row b { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-950); line-height: 1.5; }
.tpl-row em { display: block; font-style: normal; font-size: 11px; color: var(--ink-500); margin-top: 1px; line-height: 1.5; }
.tpl-row__meta { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); white-space: nowrap; }
.tpl-row__meta svg { display: none; }
.tpl-row:hover .tpl-row__meta { color: var(--brand-ink); }
.tpl-row:hover .tpl-row__meta svg { display: inline-block; }

/* ---------- 5. 灵感广场 ---------- */
.insp-bar {
  display: flex; flex-direction: column; align-items: stretch; gap: 7px;
  padding: 10px 12px; margin-bottom: 16px;
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface);
}
.insp-bar__row {
  display: flex; align-items: center; gap: 6px;
  overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none;
}
.insp-bar__row::-webkit-scrollbar { display: none; }
.insp-bar__row .chip { flex: none; }
.insp-bar__label { flex: none; font-size: 11px; color: var(--ink-500); margin-right: 2px; }
.insp-bar .divider-v { flex: none; height: 14px; margin: 0 2px; }
.insp-bar__count { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }

/* 瀑布流：不同画幅按自身比例出图，高度自然错落。
   用 grid 定列宽、列容器内纵向排列，由 JS 按「当前最矮列」放卡——
   原先的 column-count 在高矮混排（9:16 与 16:9 相差近 3 倍）时会把一列塞满、
   另一列底部空出半屏，案例一多就明显。 */
.insp-mason {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}
.insp-col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.insp-col > .insp-card { margin-bottom: 0; }
.insp-card {
  display: block; break-inside: avoid; position: relative;
  margin: 0 0 12px; border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); overflow: hidden; cursor: pointer;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.insp-card:hover { border-color: #F9DCCF; box-shadow: var(--shadow-md); }
.insp-card__media { position: relative; aspect-ratio: var(--ar, 3 / 4); background: var(--surface-3); overflow: hidden; }
.insp-card__media img,
.insp-card__media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.insp-card__media video { opacity: 0; transition: opacity 0.28s var(--ease); }
.insp-card:hover .insp-card__media video { opacity: 1; }
.insp-card__shade {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(21, 21, 27, 0) 46%, rgba(21, 21, 27, 0.58) 100%);
  opacity: 0; transition: opacity 0.22s var(--ease);
}
.insp-card:hover .insp-card__shade { opacity: 1; }
.insp-card__tag {
  position: absolute; left: 9px; top: 9px; z-index: 1;
  font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: var(--r-full);
  background: rgba(255, 255, 255, 0.93); color: var(--ink-800);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.insp-card__dur {
  position: absolute; right: 9px; top: 9px; z-index: 1;
  font-family: var(--font-mono); font-size: 11px; color: #fff;
  background: rgba(21, 21, 27, 0.82); padding: 2px 6px; border-radius: 5px;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.insp-card__acts {
  position: absolute; left: 9px; right: 9px; bottom: 9px; z-index: 2;
  display: flex; gap: 6px;
  opacity: 0; transform: translateY(6px);
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease);
}
.insp-card:hover .insp-card__acts,
.insp-card:focus-visible .insp-card__acts { opacity: 1; transform: none; }
.insp-card__act {
  flex: 1; height: 30px; border-radius: var(--r-full);
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  font-size: 11.5px; font-weight: 600;
  background: rgba(255, 255, 255, 0.95); color: var(--ink-950);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.insp-card__act--brand { background: var(--brand); color: var(--ink-950); flex: 1.2; }
.insp-card__foot { display: flex; align-items: center; gap: 8px; padding: 8px 11px 9px; }
.insp-card__foot b {
  flex: 1; min-width: 0; font-size: 12px; font-weight: 600; color: var(--ink-950);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.insp-card__foot span { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); white-space: nowrap; }

/* 首页只放四张，用统一比例保证一行齐平 */
.insp-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.insp-grid .insp-card { margin: 0; }
.insp-grid .insp-card__media { aspect-ratio: 4 / 5; }

/* ---------- 6. 作品卡 ---------- */
.work-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(266px, 1fr)); gap: 14px; align-items: stretch; }
.work-card {
  position: relative; display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); overflow: visible;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease);
}
.work-card:hover { border-color: #F9DCCF; box-shadow: var(--shadow-md); }
.work-card__media {
  position: relative; aspect-ratio: 4 / 3; flex: none;
  background: var(--surface-3); overflow: hidden;
  border-radius: var(--r-lg) var(--r-lg) 0 0;
}
.work-card__media img,
.work-card__media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.work-card__media img { transition: transform 0.6s var(--ease); }
.work-card:hover .work-card__media img { transform: scale(1.03); }
.work-card__badge { position: absolute; left: 9px; top: 9px; z-index: 1; }
.work-card__dur {
  position: absolute; right: 9px; top: 9px; z-index: 1;
  font-family: var(--font-mono); font-size: 11px; color: #fff;
  background: rgba(21, 21, 27, 0.82); padding: 2px 6px; border-radius: 5px;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
/* 没有可播镜头时，封面回落商品主图，多张卡看上去一模一样。
   这里盖一层「还没有成片」占位，保留商品识别，同时区分出片状态。 */
.work-card__noplay {
  position: absolute; inset: 0; z-index: 1;
  display: flex; align-items: flex-end; justify-content: center;
  padding-bottom: 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 42%, rgba(255, 255, 255, 0.88) 100%);
  color: var(--ink-950); font-size: 11px; font-weight: 600; letter-spacing: 0.02em;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.6);
}
.work-card__play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(0.92); z-index: 2;
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.94); color: var(--ink-950);
  box-shadow: 0 10px 24px -10px rgba(0, 0, 0, 0.7);
  opacity: 0; transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}
.work-card:hover .work-card__play { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.work-card__final {
  position: absolute; right: 9px; bottom: 9px; z-index: 1;
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: var(--r-full);
  background: rgba(255, 255, 255, 0.94); color: var(--success);
}
/* 失败原因压在图底：写进正文会把卡片撑高、把操作行顶歪 */
.work-card__err {
  position: absolute; left: 8px; right: 8px; bottom: 8px; z-index: 2;
  display: flex; align-items: center; gap: 4px;
  padding: 3px 7px; border-radius: 6px;
  background: rgba(255, 255, 255, 0.96); border: 1px solid var(--danger-line);
  font-size: 11px; line-height: 1.4; color: var(--danger);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.work-card__err svg { flex: none; }
.work-card__err span { min-width: 0; font-weight: 600; }
/* 失败原因：封面只报个数，正文用一行说清原因，重试按钮放底栏——
   三者各司其职，卡片高度不被长报错撑开 */
.work-card__fail {
  display: flex; align-items: center; gap: 5px;
  margin-top: 1px; padding: 4px 7px; border-radius: 6px;
  background: var(--danger-soft); border: 1px solid var(--danger-line);
  font-size: 11px; line-height: 1.45; color: var(--danger);
}
.work-card__fail svg { flex: none; }
.work-card__fail span { min-width: 0; }
/* 失败原因原来是一行 ellipsis，关键信息（「在广告页哪里重试」）被吞掉；
   改成两行，既能读全又不把卡片撑得过高。 */
.clamp2 {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; min-width: 0;
}
.work-card__body { padding: 11px 13px 12px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
/* 操作行贴底：卡片高度不一时，网格里每张卡的按钮才能落在同一水平线上 */
.work-card__acts { margin-top: auto; }
.work-card__name {
  display: block; color: inherit; text-decoration: none;
  font-size: 13.5px; font-weight: 650; color: var(--ink-950); line-height: 1.45;
  letter-spacing: -0.01em; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
  /* 点击区扩到 ≥24px，负外边距抵消视觉间距 */
  padding: 3px 0; margin: -3px 0;
}
.work-card__meta { font-size: 11px; color: var(--ink-500); }
.work-card__prog { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.work-card__prog > div { flex: 1; min-width: 0; }
.work-card__prog span { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); white-space: nowrap; }
.work-card__acts {
  position: relative;
  display: flex; align-items: center; gap: 6px;
  margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line);
}
.work-card__acts .btn { flex: none; }
.work-card__acts .spacer { flex: 1; }
.work-card__more { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.work-card__more .spacer { flex: 1; }

/* 更多菜单：次要操作收进来，卡面上只留主操作 */
.popmenu {
  position: absolute; right: 0; bottom: calc(100% + 6px); z-index: 30;
  min-width: 158px; padding: 5px;
  border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); box-shadow: var(--shadow-lg);
  animation: popIn 0.14s var(--ease);
}
@keyframes popIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.popmenu button {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 7px 9px; border-radius: 7px;
  font-size: 12px; color: var(--ink-800); text-align: left;
  transition: background 0.12s var(--ease);
}
.popmenu button:hover { background: var(--surface-3); }
.popmenu button.is-danger { color: var(--danger); }
.popmenu button.is-danger:hover { background: var(--danger-soft); }
.popmenu__sep { height: 1px; background: var(--line); margin: 4px 3px; }

/* ---------- 7. AI 视频创作工作台（三栏） ---------- */
.ws {
  display: grid;
  grid-template-columns: 318px minmax(0, 1fr) 300px;
  grid-template-areas: "steps stage side" "foot foot foot";
  grid-template-rows: minmax(0, 1fr) auto;
  height: calc(100vh - var(--topbar-h));
  min-height: 640px;
  background: var(--surface);
}

/* 左：创作步骤 */
.ws__steps { grid-area: steps; display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--surface); }
.ws__steps-head {
  flex: none; display: flex; align-items: baseline; gap: 8px;
  padding: 13px 16px 11px; border-bottom: 1px solid var(--line);
}
.ws__steps-head b { font-size: 12px; font-weight: 650; color: var(--ink-950); letter-spacing: 0.01em; }
.ws__steps-head span { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }
.ws__steps-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; }

.step { position: relative; border-bottom: 1px solid var(--line); }
.step::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
  background: transparent; transition: background 0.18s var(--ease);
}
.step.is-open::before { background: var(--brand); }
.step__head {
  width: 100%; display: grid; grid-template-columns: 22px minmax(0, 1fr) 16px;
  align-items: center; gap: 10px; padding: 13px 14px 13px 16px; text-align: left;
}
.step__no {
  width: 22px; height: 22px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  font-size: 11px; font-weight: 700;
  border: 1px solid var(--line-strong); color: var(--ink-400); background: var(--surface);
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.step.is-open .step__no {
  background: var(--brand); border-color: var(--brand); color: var(--ink-950);
  box-shadow: 0 4px 10px -5px rgba(243, 107, 69, 0.75);
}
.step.is-done:not(.is-open) .step__no { background: var(--success-soft); border-color: transparent; color: var(--success); }
.step__meta { min-width: 0; }
.step__meta b { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-700); transition: color 0.15s var(--ease); }
.step.is-open .step__meta b { color: var(--ink-950); }
/* 已完成的步骤整体弱化，当前步骤才是注意力焦点 */
.step.is-done:not(.is-open) .step__meta b { color: var(--ink-500); font-weight: 500; }
.step__sum {
  display: block; margin-top: 2px; font-size: 11px; color: var(--ink-400);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.step.is-open .step__sum { display: none; }
.step__chev { color: var(--ink-300); transition: transform 0.2s var(--ease); }
.step.is-open .step__chev { transform: rotate(180deg); }
.step__body { padding: 0 16px 16px; }
.step:not(.is-open) .step__body { display: none; }

/* 中：深色沉浸式画布 */
.ws__stage {
  grid-area: stage; display: flex; flex-direction: column;
  min-width: 0; min-height: 0;
  background-color: var(--stage);
  background-image: radial-gradient(120% 80% at 50% 0%, #1E1E1E 0%, var(--stage) 58%);
}
.stage__bar {
  flex: none; height: 44px; display: flex; align-items: center; gap: 9px;
  padding: 0 16px; border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
.stage__bar b { font-size: 11.5px; font-weight: 600; color: var(--stage-text); }
.stage__bar span { font-family: var(--font-mono); font-size: 11px; color: var(--stage-sub); }
.stage__bar .spacer { flex: 1; }
/* 画布区：尺寸由 JS 按目标画幅算出，这里只负责居中。
   用一个真实比例的画面框，用户看到的构图就是成片构图。 */
.stage__view { position: relative; flex: 1; min-height: 0; display: grid; place-items: center; }
.stage__frame {
  /* JS 会把真实像素写进 inline style；这里的宽高比是脚本未执行时的兜底 */
  position: relative; min-width: 0; min-height: 0;
  width: 240px; aspect-ratio: 9 / 16;
  background: var(--stage); border-radius: 8px; overflow: hidden;
  box-shadow: 0 30px 70px -40px rgba(0, 0, 0, 0.95);
  transition: width 0.24s var(--ease), height 0.24s var(--ease);
}
.stage__frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.stage__frame video { width: 100%; height: 100%; object-fit: contain; display: block; background: var(--stage); }
.stage__frame.is-empty {
  border: 1px dashed rgba(255, 255, 255, 0.16);
  background: #191919; display: grid; place-items: center;
  box-shadow: none;
}
.stage__empty {
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  padding: 16px; text-align: center;
  font-size: 11.5px; line-height: 1.75; color: rgba(255, 255, 255, 0.38);
}
.stage__empty svg { color: rgba(255, 255, 255, 0.2); }

.stage__ctrl {
  flex: none; height: 54px; display: flex; align-items: center; gap: 12px;
  padding: 0 16px; border-top: 1px solid rgba(255, 255, 255, 0.07); background: #131313;
}
.stage__btn {
  width: 28px; height: 28px; border-radius: 8px;
  display: grid; place-items: center; color: rgba(255, 255, 255, 0.82);
  transition: background 0.14s var(--ease), color 0.14s var(--ease);
}
.stage__btn:hover:not(:disabled) { background: rgba(255, 255, 255, 0.08); color: #fff; }
.stage__btn:disabled { color: rgba(255, 255, 255, 0.24); cursor: not-allowed; }
.stage__time { font-family: var(--font-mono); font-size: 11px; color: rgba(255, 255, 255, 0.62); letter-spacing: 0.02em; }
.stage__track { flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.14); overflow: hidden; min-width: 40px; }
.stage__track i { display: block; height: 100%; width: 0; background: #fff; border-radius: 2px; transition: width 0.3s var(--ease); }
.stage__chip {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.02em;
  padding: 2px 7px; border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.16); color: rgba(255, 255, 255, 0.68);
}

/* 右：项目概览与创作辅助 */
.ws__side {
  grid-area: side; display: flex; flex-direction: column; gap: 12px;
  min-height: 0; padding: 14px; overflow-y: auto; overscroll-behavior: contain;
  border-left: 1px solid var(--line); background: var(--surface-2);
}
.side-card { border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); }
.side-card__head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.side-card__head b { font-size: 11.5px; font-weight: 650; color: var(--ink-950); letter-spacing: 0.01em; }
.side-card__head span { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }
.side-card__body { padding: 9px 12px 11px; }
.side-kv { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 0; }
.side-kv span { font-size: 11.5px; color: var(--ink-500); }
.side-kv b { font-family: var(--font-mono); font-size: 11px; font-weight: 600; color: var(--ink-950); }

.shot-mini { display: flex; gap: 8px; padding: 7px 0; border-bottom: 1px dashed var(--line); }
.shot-mini:last-child { border-bottom: 0; padding-bottom: 0; }
.shot-mini__no {
  width: 18px; height: 18px; border-radius: 5px; flex: none; margin-top: 1px;
  display: grid; place-items: center;
  background: var(--surface-3); color: var(--ink-400);
  font-family: var(--font-mono); font-size: 11px;
}
.shot-mini b { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink-800); }
.shot-mini span { font-size: 11px; color: var(--ink-400); }

.hist-row {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 6px; border-radius: var(--r-sm); text-align: left;
  transition: background 0.14s var(--ease);
}
.hist-row:hover { background: var(--surface-3); }
.hist-row img { width: 34px; height: 34px; border-radius: 6px; object-fit: cover; flex: none; background: var(--surface-3); }
.hist-row div { min-width: 0; }
.hist-row b { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink-900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hist-row span { font-family: var(--font-mono); font-size: 11px; color: var(--ink-400); }

/* 底部固定操作栏 */
.ws__foot {
  grid-area: foot; display: flex; align-items: center; gap: 14px;
  padding: 11px 18px; border-top: 1px solid var(--line); background: var(--surface);
}
.ws__cost b { display: block; font-size: 16px; font-weight: 700; color: var(--ink-950); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.ws__cost span { font-size: 11px; color: var(--ink-400); }
.ws__foot .spacer { flex: 1; }

/* 表单里的轻量提示行 */
.field-row-hint { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--ink-400); margin-top: 6px; }

/* ---------- 8. 个人中心 ---------- */
.profile-head {
  position: relative;
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 18px 20px; margin-bottom: 12px;
  border: 1px solid var(--line); border-radius: var(--r-xl); background: var(--surface);
}
.profile-head__id { display: flex; align-items: center; gap: 14px; min-width: 0; }
.profile-head__name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.profile-head__name b { font-size: 16px; font-weight: 650; color: var(--ink-950); letter-spacing: -0.015em; }
.profile-head__mail { font-size: 11.5px; color: var(--ink-500); margin-top: 3px; }
.profile-head__stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px;
  flex: 1; min-width: 320px;
}
.pstat {
  padding: 9px 12px; border-radius: var(--r-md);
  background: var(--surface-2); border: 1px solid var(--line);
}
.pstat b { display: block; font-size: 18px; font-weight: 650; color: var(--ink-950); letter-spacing: -0.025em; line-height: 1.25; font-variant-numeric: tabular-nums; }
.pstat span { font-size: 11px; color: var(--ink-500); }

.perk-list { display: flex; flex-wrap: wrap; gap: 6px; }
.perk {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; color: var(--ink-700);
  padding: 3px 9px; border-radius: var(--r-full);
  background: var(--surface); border: 1px solid var(--line);
}
/* 权益图标降为中性灰：5 个橙色图标排在一起会抢走「可用积分」的注意力 */
.perk svg { color: var(--ink-400); flex: none; }

/* 次级信息面：需要出现，但不该和主卡片争视线 */
.card--quiet { background: var(--surface-2); border-color: var(--line); box-shadow: none; }
.card--quiet .side-kv b { color: var(--ink-700); font-weight: 500; }
.card--quiet .field-row-hint { color: var(--ink-400); }
.subhead { font-size: 11.5px; font-weight: 600; color: var(--ink-500); letter-spacing: 0.02em; }

/* 积分概览：这一页唯一的主角——一个大数、一条额度条、三个小注 */
.quota-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px; align-items: center;
  padding: 20px 22px; border-radius: var(--r-xl);
  border: 1px solid var(--line); background: var(--surface);
}
.quota-hero__main { min-width: 0; }
.quota-hero__label { font-size: 11.5px; font-weight: 600; color: var(--ink-500); letter-spacing: 0.02em; }
.quota-hero__num { display: flex; align-items: baseline; gap: 8px; margin-top: 2px; }
.quota-hero__num b { font-size: 42px; font-weight: 700; letter-spacing: -0.045em; color: var(--ink-950); font-variant-numeric: tabular-nums; line-height: 1.05; }
.quota-hero__num span { font-size: 12.5px; color: var(--ink-500); font-variant-numeric: tabular-nums; }
.quota-hero__bar { margin-top: 12px; height: 8px; border-radius: 4px; background: var(--track); overflow: hidden; }
.quota-hero__bar i { display: block; height: 100%; border-radius: 4px; background: var(--brand); transition: width 0.4s var(--ease); }
.quota-hero__sub { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.quota-hero__sub span { font-size: 11px; color: var(--ink-500); }
.quota-hero__sub b { font-family: var(--font-mono); font-size: 11px; color: var(--ink-900); font-weight: 600; }
.quota-hero__sep { display: block; width: 1px; height: 10px; background: var(--line-strong); flex: none; }

/* ---------- 9. 响应式 ---------- */
@media (max-width: 1440px) {
  .ws { grid-template-columns: 296px minmax(0, 1fr) 278px; }
}
@media (max-width: 1280px) {
  .studio-hero { grid-template-columns: minmax(0, 1fr); }
  .studio-hero__stage { min-height: 300px; }
  /* 入口从四个变三个：这一档继续保持一行三列，掉成 2 列会剩一张孤卡 */
  .entry-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tpl-board { grid-template-columns: minmax(0, 1fr); }
  .insp-mason { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ws {
    grid-template-columns: 288px minmax(0, 1fr);
    grid-template-areas: "steps stage" "side side" "foot foot";
    grid-template-rows: minmax(440px, 1fr) auto auto;
    height: auto; min-height: 0;
  }
  .ws__side {
    flex-direction: row; flex-wrap: wrap;
    border-left: 0; border-top: 1px solid var(--line);
  }
  .ws__side > * { flex: 1 1 236px; }
}
@media (max-width: 1080px) {
  .ws {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "stage" "steps" "side" "foot";
    grid-template-rows: auto auto auto auto;
    padding-bottom: 72px;
  }
  /* 单列时画布在最上方：压到 340px，让「创作步骤」在第一屏就能露头，
     否则 9:16 的大画布会把整套表单推到折叠线以下 */
  .ws__stage { min-height: 340px; }
  .ws__steps { border-right: 0; border-bottom: 1px solid var(--line); }
  .ws__side { border-top: 1px solid var(--line); }
  /* 820 下三张卡片挤成三列，正文每行只剩几个字，改成两列 */
  .ws__side > * { flex: 1 1 300px; }
  /* 单列时表单会把预览与「下一步」推到很下面，把主操作固定住 */
  .ws__foot {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    box-shadow: 0 -12px 32px -24px rgba(23, 23, 32, 0.5);
  }
}
@media (max-width: 820px) {
  /* 极简创作一行塞不下：输入框独占首行，其余控件换行排列 */
  .quick__body { flex-wrap: wrap; }
  .quick__field--grow { flex: 1 1 100%; order: -1; }
  .quick__pick--wide { flex: 1 1 160px; }
  .quick__pick--wide .select { max-width: none; }
  .quick__go { flex: 1 1 auto; height: 38px; }
  .insp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .insp-mason { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .studio-hero__copy { padding: 26px 22px; }
  .studio-hero__title { font-size: 27px; }
  .ws__foot { padding: 10px 14px; gap: 10px; flex-wrap: wrap; row-gap: 8px; }
  .profile-head__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .quota-hero { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .entry-grid { grid-template-columns: minmax(0, 1fr); }
  .work-grid { grid-template-columns: minmax(0, 1fr); }
  .scene-shots { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
  .insp-grid { grid-template-columns: minmax(0, 1fr); }
  .insp-mason { grid-template-columns: minmax(0, 1fr); }
  .studio-hero__meta { gap: 8px; }
  .studio-hero__meta .dot { display: none; }
}

/* ================================================================== *
 * 极简创作（独立页面 #/quick）
 * 目标：一列到底的「描述 → 参考图 → 参数 → 生成」，右侧常驻结果区。
 * ================================================================== */
.qkp { max-width: 1180px; }
.qk-hero { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 18px; flex-wrap: wrap; }
.qk-hero__ic {
  width: 44px; height: 44px; flex: none; display: grid; place-items: center;
  border-radius: var(--r-md); background: var(--brand-soft); color: var(--brand-ink);
}
.qk-hero__text { min-width: 0; }
.qk-hero__kicker { font-size: 11px; letter-spacing: .14em; font-weight: 700; color: var(--ink-400); }
.qk-hero h1 { font-size: 24px; line-height: 1.25; margin: 2px 0 4px; color: var(--ink-950); }
.qk-hero p { font-size: 13px; color: var(--ink-500); }

.qkp__body { display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 14px; align-items: start; }
.qkp__main { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.qkp__side { position: sticky; top: 74px; display: flex; flex-direction: column; gap: 10px; }

.qk-block { }
.qk-block__head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.qk-block__head b { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-900); }
.qk-step {
  width: 19px; height: 19px; flex: none; display: inline-grid; place-items: center;
  border-radius: 6px; background: var(--ink-900); color: #fff; font-size: 11px; font-style: normal; font-weight: 700;
}
.qk-block__hint { font-size: 12px; color: var(--ink-400); margin: 2px 0 10px; }

.qk-prompt { position: relative; }
.qk-prompt .textarea { min-height: 124px; font-size: 13.5px; line-height: 1.75; }
.qk-prompt__foot { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.qk-examples { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.qk-examples .chip { cursor: pointer; }

.qk-drop {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  padding: 26px 16px; border: 1.5px dashed var(--line-strong); border-radius: var(--r-md);
  background: var(--surface-2); color: var(--ink-600); cursor: pointer; text-align: center;
  transition: border-color .16s var(--ease), background .16s var(--ease);
}
.qk-drop:hover, .qk-drop.is-drag { border-color: var(--brand); background: var(--brand-soft); }
.qk-drop b { font-size: 13px; font-weight: 600; color: var(--ink-800); }
.qk-drop__ic { color: var(--ink-400); }

.qk-thumb {
  display: flex; align-items: center; gap: 12px; padding: 10px;
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-2);
}
.qk-thumb img {
  width: 62px; height: 62px; flex: none; object-fit: cover;
  border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface);
}
.qk-thumb__meta { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.qk-thumb__meta b { font-size: 13px; color: var(--ink-900); }

/* 双模式：商品展示 / 场景叙事 */
.qk-modes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 4px 0 12px; }
.qk-mode {
  display: flex; flex-direction: column; gap: 6px; text-align: left; cursor: pointer;
  padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); transition: border-color .16s var(--ease), background .16s var(--ease);
}
.qk-mode:hover { border-color: var(--line-strong); }
.qk-mode.is-active { border-color: var(--brand); background: var(--brand-soft); }
.qk-mode__top { display: flex; align-items: center; gap: 7px; }
.qk-mode__top b { font-size: 13.5px; font-weight: 600; color: var(--ink-900); }
.qk-mode__tag {
  font-style: normal; font-size: 11px; line-height: 1.5; padding: 0 6px; border-radius: 999px;
  background: var(--surface-2); color: var(--ink-500); border: 1px solid var(--line);
}
.qk-mode__tag.is-rec { background: var(--brand-soft); color: var(--brand-ink); border-color: var(--brand-line); }
.qk-mode__tag.is-alt { background: var(--surface-2); color: var(--ink-500); border-color: var(--line); }
.qk-mode__desc { font-size: 11.5px; line-height: 1.6; color: var(--ink-500); }

/* 首帧：画幅适配后的实际提交图 */
.qk-frame {
  display: flex; align-items: center; gap: 12px; margin-top: 10px; padding: 9px 10px;
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-2);
}
.qk-frame img {
  width: 44px; height: 78px; flex: none; object-fit: cover; border-radius: 6px;
  border: 1px solid var(--line); background: var(--surface);
}
.qk-frame__meta { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.qk-frame__meta b { font-size: 12.5px; color: var(--ink-800); }
.qk-frame.is-busy, .qk-frame.is-warn {
  font-size: 12px; gap: 6px; margin-top: 10px; padding: 9px 10px;
  display: flex; align-items: center; border-radius: var(--r-md);
}
.qk-frame.is-busy { color: var(--ink-500); background: var(--surface-2); border: 1px solid var(--line); }
.qk-frame.is-warn { color: var(--warn); background: var(--warn-soft); border: 1px solid var(--warn-line); }

.qk-resnote { margin: 0; line-height: 1.7; }

.qk-params { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 18px; margin-top: 6px; }
.qk-param { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.qk-param--full { grid-column: 1 / -1; }
.qk-param__k { font-size: 11.5px; font-weight: 600; color: var(--ink-500); }
.qk-param__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.qk-param__chips .chip { cursor: pointer; }

.qk-submit {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px;
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface);
  box-shadow: var(--shadow-sm, 0 6px 20px rgba(24,25,28,.08));
}
.qk-submit__cost { flex: 1; min-width: 0; }
.qk-cost { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--ink-600); flex-wrap: wrap; }
.qk-cost b { font-size: 15px; color: var(--ink-950); font-variant-numeric: tabular-nums; }
.qk-cost.is-short, .qk-cost.is-short b { color: var(--danger); }
.qk-cost__warn { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--danger); }
.qk-submit__go { flex: none; min-width: 168px; height: 42px; font-size: 14px; }

.qk-panel__title { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--ink-800); margin-bottom: 12px; }
.qk-panel__empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 26px 12px; text-align: center; color: var(--ink-300); }
.qk-panel__empty b { font-size: 13px; color: var(--ink-700); }
.qk-panel__empty p { max-width: 250px; line-height: 1.7; }
.qk-panel__head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.qk-panel__bar { margin-bottom: 10px; }
.qk-panel__media {
  border-radius: var(--r-md); overflow: hidden; background: var(--surface-2);
  border: 1px solid var(--line); aspect-ratio: 9 / 16; max-height: 340px;
  display: grid; place-items: center; margin-bottom: 12px;
}
.qk-panel__media video { width: 100%; height: 100%; object-fit: contain; background: #000; display: block; }
.qk-panel__media--empty { aspect-ratio: auto; min-height: 132px; max-height: none; }
.qk-panel__ph { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--ink-300); text-align: center; padding: 12px; }
.qk-panel__err {
  display: flex; gap: 6px; align-items: flex-start; font-size: 12px; line-height: 1.6;
  color: var(--danger); background: var(--danger-soft, #FDECEC); border-radius: var(--r-sm); padding: 8px 10px; margin-bottom: 10px;
}
.qk-panel__meta { display: flex; flex-direction: column; gap: 7px; margin: 0 0 12px; }
.qk-panel__meta > div { display: flex; gap: 10px; font-size: 12px; line-height: 1.6; }
.qk-panel__meta dt { flex: none; width: 42px; color: var(--ink-400); }
.qk-panel__meta dd { margin: 0; min-width: 0; color: var(--ink-800); word-break: break-word; }
.qk-panel__acts { display: flex; flex-wrap: wrap; gap: 6px; }
.qk-tip { display: flex; gap: 5px; align-items: flex-start; line-height: 1.65; padding: 0 4px; }

@media (max-width: 1080px) {
  .qkp__body { grid-template-columns: minmax(0, 1fr); }
  .qkp__side { position: static; }
  .qk-panel__media { aspect-ratio: auto; max-height: 420px; min-height: 160px; }
}
@media (max-width: 640px) {
  .qk-params { grid-template-columns: minmax(0, 1fr); }
  .qk-submit { flex-direction: column; align-items: stretch; gap: 10px; }
  .qk-submit__go { width: 100%; }
  .qk-hero h1 { font-size: 21px; }
}
