/* ============ 应用外壳（暗色工作台） ============ */
body.app-dark {
  background: #0a0b0e;
  color: #e9ebf2;
  --surface: #101218;
  --surface-2: #151821;
  --surface-3: #1c2030;
  --hair: rgba(255, 255, 255, 0.08);
  --hair-strong: rgba(255, 255, 255, 0.16);
  --dim: #8d95a8;
  --brand: #a855f7;
  --brand-2: #c026d3;
  --cyan: #22d3ee;
  min-height: 100dvh;
}

/* ---- 顶栏 ---- */
.appbar {
  position: sticky;
  top: 0;
  z-index: 60;
  height: 62px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 22px;
  background: rgba(10, 11, 14, 0.86);
  border-bottom: 1px solid var(--hair);
  backdrop-filter: blur(16px);
}
.appbar .brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.appbar .brand i {
  font-style: normal;
  background: linear-gradient(135deg, #a855f7, #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.appbar .nav { display: flex; align-items: center; gap: 8px; margin-left: 10px; }
.appbar .nav a {
  padding: 6px 12px;
  border-radius: 9px;
  font-size: 13px;
  color: var(--dim);
}
.appbar .nav a:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }
.appbar .nav a.is-active { background: rgba(168, 85, 247, 0.16); color: #e9d5ff; }
.appbar .spacer { flex: 1; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--hair-strong);
  font-size: 12.5px;
  white-space: nowrap;
  background: var(--surface-2);
}
.pill-gold { border-color: rgba(245, 158, 11, 0.4); background: rgba(245, 158, 11, 0.14); color: #fcd34d; }
.pill-cyan { border-color: rgba(34, 211, 238, 0.35); background: rgba(34, 211, 238, 0.12); color: #a5f3fc; }
.pill-brand { border-color: rgba(168, 85, 247, 0.45); background: rgba(168, 85, 247, 0.16); color: #e9d5ff; }
.pill-bell { width: 34px; justify-content: center; padding: 0; position: relative; }
.pill-bell::after {
  content: "";
  position: absolute;
  top: 6px; right: 8px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #ef4444;
}
.avatar-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, #334155, #1e293b);
  border: 1px solid var(--hair-strong);
  font-size: 15px;
  color: #fff;
}

/* ---- 左侧悬浮栏 ---- */
.rail {
  position: fixed;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 8px;
  border-radius: 18px;
  background: rgba(18, 20, 28, 0.9);
  border: 1px solid var(--hair);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(12px);
}
.rail a, .rail button {
  position: relative;
  width: 38px; height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  border: none;
  background: transparent;
  color: #9aa3b6;
  font-size: 17px;
  transition: background 0.15s, color 0.15s, transform 0.15s;
}
.rail a:hover, .rail button:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.rail a.is-active, .rail button.is-active {
  background: linear-gradient(135deg, #a855f7, #c026d3);
  color: #fff;
  box-shadow: 0 6px 18px rgba(168, 85, 247, 0.45);
}
.rail .rail-label {
  position: absolute;
  left: 46px;
  padding: 4px 9px;
  border-radius: 7px;
  background: #1b1f2b;
  border: 1px solid var(--hair);
  font-size: 11.5px;
  color: #e9ebf2;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-4px);
  pointer-events: none;
  transition: opacity 0.15s, transform 0.15s;
}
.rail a:hover .rail-label, .rail button:hover .rail-label { opacity: 1; transform: none; }
.rail hr { width: 22px; border: none; border-top: 1px solid var(--hair); margin: 4px 0; }

/* ---- 页面容器 ---- */
.page {
  padding: 26px 26px 70px 76px;
  max-width: 1560px;
  margin: 0 auto;
}
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head h1 { margin: 0 0 6px; font-size: 26px; letter-spacing: -0.4px; }
.page-head p { margin: 0; color: var(--dim); font-size: 13px; }
.page-head .actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---- 工具栏 ---- */
.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--hair);
  border-radius: 14px;
  background: var(--surface);
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.toolbar .grow { flex: 1; min-width: 200px; }
.input-dark, .select-dark, .textarea-dark {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--hair-strong);
  border-radius: 10px;
  color: #e9ebf2;
  padding: 0 12px;
  height: 38px;
  font-size: 13.5px;
}
.textarea-dark { height: auto; padding: 12px; line-height: 1.8; resize: vertical; }
.input-dark::placeholder, .textarea-dark::placeholder { color: #5f6779; }
.input-dark:focus, .select-dark:focus, .textarea-dark:focus { outline: none; border-color: var(--brand); }
.select-dark { max-width: 170px; }

.btn-brand {
  background: linear-gradient(135deg, #a855f7, #c026d3);
  border: none;
  color: #fff;
  box-shadow: 0 8px 22px rgba(168, 85, 247, 0.35);
}
.btn-brand:hover { filter: brightness(1.08); }
.btn-cyan { background: #0ea5e9; border: none; color: #fff; }
.btn-line { background: transparent; border: 1px solid var(--hair-strong); color: #e9ebf2; }
.btn-line:hover { background: rgba(255, 255, 255, 0.06); }
.btn-green { background: linear-gradient(135deg, #10b981, #059669); border: none; color: #fff; }

/* ---- 卡片 ---- */
.card-dark {
  background: var(--surface);
  border: 1px solid var(--hair);
  border-radius: 16px;
  padding: 18px;
}
.project-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.project-card {
  border: 1px solid var(--hair);
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  transition: transform 0.16s, border-color 0.16s, box-shadow 0.16s;
  text-align: left;
  color: inherit;
  padding: 0;
  cursor: pointer;
}
.project-card:hover { transform: translateY(-3px); border-color: rgba(168, 85, 247, 0.55); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45); }
.project-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(140deg, #1e1b4b, #312e81 55%, #0e7490);
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.35);
  font-size: 34px;
}
.project-cover img { width: 100%; height: 100%; object-fit: cover; }
.project-cover .badge {
  position: absolute;
  left: 10px; top: 10px;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #e9ebf2;
}
.project-meta { padding: 12px 14px 14px; }
.project-meta strong { display: block; font-size: 15px; margin-bottom: 2px; }
.project-meta .sub { font-size: 11.5px; color: var(--dim); }
.project-meta .foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--dim);
}
.dot-status { display: inline-flex; align-items: center; gap: 5px; }
.dot-status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #22c55e; }
.dot-status.is-done::before { background: #38bdf8; }

/* ---- 工作台 ---- */
.ws-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--hair);
  border-radius: 14px;
  background: var(--surface);
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.ws-back {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; color: var(--dim);
  border: 1px solid var(--hair-strong); border-radius: 9px;
  padding: 6px 10px;
}
.ws-back:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }
.ws-project { font-size: 14px; font-weight: 700; }
.ws-tabs { display: flex; gap: 4px; margin: 0 auto; flex-wrap: wrap; }
.ws-tab {
  border: 1px solid transparent;
  background: transparent;
  color: var(--dim);
  padding: 7px 14px;
  border-radius: 10px;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.ws-tab:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }
.ws-tab.is-active {
  background: linear-gradient(135deg, #a855f7, #c026d3);
  color: #fff;
  box-shadow: 0 6px 18px rgba(168, 85, 247, 0.4);
}
.announce {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px;
  border-radius: 10px;
  background: rgba(30, 58, 138, 0.28);
  border: 1px solid rgba(59, 130, 246, 0.32);
  color: #bfdbfe;
  font-size: 12.5px;
  margin-bottom: 14px;
}
.announce .close { margin-left: auto; border: none; background: transparent; color: inherit; }

.ws-steps { display: flex; align-items: center; gap: 10px; justify-content: center; margin: 4px 0 16px; }
.ws-step {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 13px;
  border: 1px solid var(--hair-strong);
  color: var(--dim);
}
.ws-step.is-active { background: linear-gradient(135deg, #a855f7, #c026d3); color: #fff; border-color: transparent; }
.ws-step.is-done { color: #a5f3fc; border-color: rgba(34, 211, 238, 0.4); }
.ws-step b { font-family: var(--mono); font-size: 11px; }
.ws-line { width: 46px; height: 1px; background: var(--hair-strong); }

/* 剧本创建 */
.script-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 16px; align-items: start; }
.episode-panel { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); overflow: hidden; }
.episode-panel-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px solid var(--hair);
  font-size: 13px;
}
.episode-panel-head span { color: var(--dim); font-size: 11.5px; }
.episode-add {
  margin: 12px 14px;
  width: calc(100% - 28px);
  height: 38px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(135deg, #10b981, #059669);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.episode-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 0 14px 12px; }
.episode-chip {
  position: relative;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--hair-strong);
  background: var(--surface-2);
  color: #cfd6e4;
  font-size: 12.5px;
}
.episode-chip:hover { border-color: rgba(168, 85, 247, 0.5); }
.episode-chip.is-active { background: linear-gradient(135deg, #a855f7, #c026d3); border-color: transparent; color: #fff; }
.episode-chip.has-content::after {
  content: "";
  position: absolute; right: 4px; top: 4px;
  width: 5px; height: 5px; border-radius: 50%; background: #22c55e;
}
.episode-pager { display: flex; gap: 4px; padding: 0 14px 14px; flex-wrap: wrap; }
.episode-pager button {
  min-width: 28px; height: 26px; border-radius: 7px;
  border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 11.5px;
}
.episode-pager button.is-active { color: #fff; border-color: var(--brand); }

.editor-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.editor-head .title { font-size: 14px; font-weight: 700; }
.editor-body {
  border: 1px solid var(--hair);
  border-radius: 12px;
  background: #0d0f14;
  padding: 16px 18px;
  min-height: 420px;
  font-size: 13.5px;
  line-height: 1.9;
  white-space: pre-wrap;
  color: #dbe2ee;
}
.editor-foot { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.editor-foot .count { margin-left: auto; font-size: 11.5px; color: var(--dim); }

/* 分镜 */
.storyboard-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr) 220px; gap: 12px; align-items: start; }
.sb-col { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 12px; }
.sb-label { font-size: 11.5px; color: var(--dim); margin-bottom: 6px; }
.sb-assets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.sb-asset {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--hair-strong);
  background: var(--surface-2);
  display: grid; place-items: center;
  font-size: 10px; color: var(--dim); text-align: center; padding: 2px;
  cursor: pointer;
}
.sb-asset img { width: 100%; height: 100%; object-fit: cover; }
.sb-asset.is-picked { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.3); }
.sb-asset span { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(0, 0, 0, 0.6); font-size: 9.5px; padding: 1px 3px; }
.sb-add {
  aspect-ratio: 3 / 4;
  border: 1px dashed var(--hair-strong);
  border-radius: 8px;
  display: grid; place-items: center;
  font-size: 10.5px; color: var(--dim);
  background: transparent;
}
.sb-prompt {
  margin-top: 10px;
  border: 1px solid rgba(168, 85, 247, 0.45);
  border-radius: 12px;
  background: rgba(168, 85, 247, 0.06);
  padding: 12px;
}
.sb-prompt textarea {
  width: 100%;
  min-height: 150px;
  background: transparent;
  border: none;
  color: #e9ebf2;
  font-size: 12.5px;
  line-height: 1.8;
  resize: vertical;
}
.sb-prompt textarea:focus { outline: none; }
.sb-count { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--dim); margin-top: 6px; }
.sb-count .bar { flex: 1; height: 4px; border-radius: 3px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.sb-count .bar i { display: block; height: 100%; background: linear-gradient(90deg, #a855f7, #22d3ee); }

.player {
  border: 1px solid var(--hair);
  border-radius: 12px;
  background: #05060a;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  color: #5f6779;
  font-size: 12.5px;
  overflow: hidden;
  position: relative;
}
.player img { width: 100%; height: 100%; object-fit: cover; }
.player .pbar {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 8px 12px;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.8), transparent);
  display: flex; align-items: center; gap: 10px;
  font-size: 11.5px; color: #cbd5e1;
}
.shot-strip { display: flex; gap: 8px; overflow-x: auto; padding: 10px 0 4px; }
.shot-thumb {
  flex: none;
  width: 118px;
  border-radius: 8px;
  border: 1px solid var(--hair-strong);
  background: var(--surface-2);
  overflow: hidden;
  cursor: pointer;
  padding: 0;
  color: inherit;
}
.shot-thumb.is-active { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.35); }
.shot-thumb .cover { aspect-ratio: 16 / 9; background: #0b0d12; display: grid; place-items: center; font-size: 10px; color: #5f6779; }
.shot-thumb .cover img { width: 100%; height: 100%; object-fit: cover; }
.shot-thumb .cap { display: flex; justify-content: space-between; padding: 3px 6px; font-size: 10px; color: var(--dim); }

.gen-list { display: flex; flex-direction: column; gap: 8px; max-height: 520px; overflow-y: auto; }
.gen-item { border: 1px solid var(--hair); border-radius: 10px; overflow: hidden; background: var(--surface-2); }
.gen-item img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.gen-item .meta { padding: 6px 8px; font-size: 10.5px; color: var(--dim); display: flex; justify-content: space-between; gap: 6px; }

/* 拉片 */
.review-layout { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 14px; align-items: start; }
.review-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--hair);
  border-radius: 10px;
  background: var(--surface);
  margin-bottom: 8px;
  cursor: pointer;
}
.review-item.is-active { border-color: var(--brand); background: rgba(168, 85, 247, 0.08); }
.review-item .no { font-family: var(--mono); font-size: 11px; color: var(--dim); width: 44px; }
.review-item .body { min-width: 0; flex: 1; }
.review-item .body strong { display: block; font-size: 13px; }
.review-item .body span { font-size: 11px; color: var(--dim); }
.status-tag { font-size: 10.5px; padding: 2px 7px; border-radius: 5px; border: 1px solid var(--hair-strong); color: var(--dim); white-space: nowrap; }
.status-pending { color: #fcd34d; border-color: rgba(245, 158, 11, 0.45); background: rgba(245, 158, 11, 0.12); }
.status-reviewing { color: #93c5fd; border-color: rgba(59, 130, 246, 0.45); background: rgba(59, 130, 246, 0.12); }
.status-approved { color: #86efac; border-color: rgba(34, 197, 94, 0.45); background: rgba(34, 197, 94, 0.12); }
.status-rejected { color: #fca5a5; border-color: rgba(239, 68, 68, 0.45); background: rgba(239, 68, 68, 0.12); }
.comment-list { display: flex; flex-direction: column; gap: 8px; max-height: 240px; overflow-y: auto; margin: 10px 0; }
.comment-item { border: 1px solid var(--hair); border-radius: 9px; padding: 8px 10px; background: var(--surface-2); font-size: 12.5px; }
.comment-item .who { font-size: 11px; color: var(--dim); margin-bottom: 3px; }

/* 资产库 */
.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.asset-card { border: 1px solid var(--hair); border-radius: 12px; overflow: hidden; background: var(--surface); }
.asset-card .pic { aspect-ratio: 3 / 4; background: #0d0f14; display: grid; place-items: center; color: #5f6779; font-size: 22px; }
.asset-card .pic img { width: 100%; height: 100%; object-fit: cover; }
.asset-card .info { padding: 8px 10px; display: flex; align-items: center; gap: 6px; font-size: 12px; min-width: 0; }
.asset-card .info > span:first-child {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.asset-card .info .btn { padding: 0 6px; height: 24px; min-width: 0; flex: none; font-size: 11px; }
.asset-card .info .tag { margin-left: auto; font-size: 10px; color: var(--dim); flex: none; }
.pic { font-size: 30px; }

/* 会员 */
.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.plan-card {
  border: 1px solid var(--hair);
  border-radius: 16px;
  padding: 18px;
  background: var(--surface);
  display: flex; flex-direction: column; gap: 10px;
}
.plan-card.is-current { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.14); }
.plan-card .price { font-size: 26px; font-weight: 800; }
.plan-card .price small { font-size: 12px; color: var(--dim); font-weight: 500; }
.plan-card ul { margin: 0; padding-left: 16px; font-size: 12px; color: var(--dim); display: flex; flex-direction: column; gap: 4px; }
.points-hero {
  display: flex; align-items: center; gap: 28px;
  padding: 20px 24px;
  border-radius: 18px;
  background: linear-gradient(120deg, #1e1b4b, #4c1d95 55%, #be123c);
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.points-hero .big { font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums; }
.points-hero .label { font-size: 11.5px; color: rgba(255, 255, 255, 0.72); }
.record-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.record-table th, .record-table td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--hair); }
.record-table th { color: var(--dim); font-weight: 600; font-size: 11.5px; }

/* 管理后台 */
.stat-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.stat-card { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 16px; }
.stat-card .big { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat-card .label { font-size: 11.5px; color: var(--dim); }
.chart { display: flex; align-items: flex-end; gap: 10px; height: 160px; padding: 10px 4px 0; }
.chart .col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.chart .col i {
  display: block; width: 100%; max-width: 34px; border-radius: 6px 6px 0 0;
  background: linear-gradient(180deg, #a855f7, #6d28d9);
  min-height: 3px;
}
.chart .col span { font-size: 10.5px; color: var(--dim); }
.split-bar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: rgba(255, 255, 255, 0.08); }
.split-bar i { display: block; height: 100%; }

/* 工坊 */
.tool-tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.style-grid { display: flex; flex-wrap: wrap; gap: 6px; max-height: 148px; overflow-y: auto; }
.style-chip {
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid var(--hair-strong);
  background: transparent;
  color: var(--dim);
  font-size: 11.5px;
}
.style-chip.is-active { border-color: var(--brand); color: #fff; background: rgba(168, 85, 247, 0.16); }
.ref-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ref-item { aspect-ratio: 1; border: 1px dashed var(--hair-strong); border-radius: 8px; display: grid; place-items: center; color: var(--dim); font-size: 10.5px; overflow: hidden; background: transparent; }
.ref-item img { width: 100%; height: 100%; object-fit: cover; }

/* 空态与加载 */
.empty { text-align: center; color: var(--dim); font-size: 13px; padding: 60px 20px; border: 1px dashed var(--hair); border-radius: 14px; }
.empty .big { font-size: 30px; opacity: 0.5; display: block; margin-bottom: 10px; }

/* 弹窗 */
.modal-dark { position: fixed; inset: 0; z-index: 140; display: grid; place-items: center; }
.modal-dark .mask { position: absolute; inset: 0; background: rgba(4, 5, 8, 0.62); }
.modal-dark .box {
  position: relative;
  width: min(480px, 92vw);
  border-radius: 16px;
  border: 1px solid var(--hair);
  background: var(--surface);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  padding: 18px;
}
.modal-dark h3 { margin: 0 0 14px; font-size: 16px; }
.modal-dark .foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }

@media (max-width: 1100px) {
  .script-layout { grid-template-columns: 1fr; }
  .storyboard-layout { grid-template-columns: 1fr; }
  .review-layout { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .page { padding: 18px 14px 80px 66px; }
  .appbar { padding: 0 12px; gap: 8px; }
  .appbar .nav { display: none; }
  .rail { left: 6px; padding: 6px; }
  .rail a, .rail button { width: 34px; height: 34px; font-size: 15px; }
  .episode-grid { grid-template-columns: repeat(5, 1fr); }
}

.mt-10 { margin-top: 10px; }
.mt-14 { margin-top: 14px; }

.sb-hint { font-size: 11px; color: var(--dim); padding: 8px 2px; line-height: 1.7; }
.editor-foot + .sb-label, .editor-foot + .sb-label { margin-top: 14px; }

/* ---- 通知浮层 ---- */
.popover {
  position: fixed;
  top: 62px; right: 18px;
  width: min(360px, 92vw);
  max-height: 60vh;
  overflow: hidden;
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--hair-strong);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
  z-index: 130;
}
.popover-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; border-bottom: 1px solid var(--hair);
  font-size: 13px;
}
.popover-list { overflow-y: auto; padding: 6px; }
.popover-item { padding: 9px 10px; border-radius: 9px; cursor: default; }
.popover-item:hover { background: rgba(255, 255, 255, 0.05); }
.popover-item.is-unread { background: rgba(168, 85, 247, 0.09); }
.popover-title { font-size: 12.5px; margin-bottom: 2px; }
.popover-body { font-size: 11.5px; color: var(--dim); }
.popover-empty { padding: 24px; text-align: center; color: var(--dim); font-size: 12.5px; }

/* ---- 团队弹窗 ---- */
#team-modal .order-row.is-picked { border-color: rgba(168, 85, 247, 0.5); background: rgba(168, 85, 247, 0.08); }
#team-modal .box .row { margin-bottom: 8px; }
#team-modal .box .row .input-dark { flex: 1; }
.row-center { align-items: center; gap: 16px; }
.avatar-lg { width: 64px; height: 64px; font-size: 26px; border-radius: 16px; }
.avatar-lg img { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; }
.mt-6 { margin-top: 6px; }

/* ---- 作品设定（角色/场景/道具） ---- */
.set-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 10px 12px; margin-bottom: 16px;
  border: 1px solid var(--hair); border-radius: 14px; background: var(--surface);
}
.set-tabs { display: flex; gap: 4px; }
.set-tab {
  border: 1px solid transparent; background: transparent; color: var(--dim);
  padding: 7px 14px; border-radius: 9px; font-size: 13px;
  display: inline-flex; align-items: center; gap: 6px;
}
.set-tab:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }
.set-tab.is-active {
  background: linear-gradient(135deg, #a855f7, #c026d3); color: #fff;
  box-shadow: 0 6px 18px rgba(168, 85, 247, 0.35);
}
.seg { display: inline-flex; padding: 3px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--hair); }
.seg button {
  border: none; background: transparent; color: var(--dim);
  padding: 5px 12px; border-radius: 7px; font-size: 12.5px;
}
.seg button.is-active { background: rgba(34, 197, 94, 0.16); color: #86efac; }
.set-right { margin-left: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.set-model { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--dim); white-space: nowrap; }
.cost-badge {
  font-size: 11px; padding: 2px 7px; border-radius: 5px;
  background: rgba(245, 158, 11, 0.16); color: #fcd34d; border: 1px solid rgba(245, 158, 11, 0.4);
}
.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.set-card {
  position: relative; border-radius: 12px; overflow: hidden; cursor: pointer;
  border: 1px solid var(--hair-strong); background: #0d0f14; padding: 0; text-align: left; color: inherit;
  transition: transform 0.15s, border-color 0.15s;
}
.set-card:hover { transform: translateY(-2px); border-color: rgba(168, 85, 247, 0.55); }
.set-cover { aspect-ratio: 16 / 9; display: grid; place-items: center; overflow: hidden; }
.set-cover img { width: 100%; height: 100%; object-fit: cover; }
.set-cover .ph { font-size: 28px; color: rgba(255, 255, 255, 0.28); }
.set-name {
  position: absolute; left: 10px; bottom: 10px;
  font-size: 15px; font-weight: 700; color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
}
.set-badges { position: absolute; right: 8px; bottom: 8px; display: flex; gap: 4px; }
.set-badge {
  font-size: 10px; padding: 2px 6px; border-radius: 4px;
  background: rgba(0, 0, 0, 0.62); border: 1px solid rgba(255, 255, 255, 0.22); color: #e5e7eb;
}
.set-badge.voice { background: rgba(244, 63, 94, 0.85); border-color: transparent; color: #fff; }
.set-badge.more { background: rgba(59, 130, 246, 0.8); border-color: transparent; color: #fff; }
.set-new {
  display: grid; place-items: center; gap: 8px; min-height: 150px;
  border: 1px dashed rgba(255, 255, 255, 0.22); border-radius: 12px;
  color: var(--dim); font-size: 13px; background: rgba(255, 255, 255, 0.015); cursor: pointer;
}
.set-new:hover { border-color: rgba(168, 85, 247, 0.6); color: #fff; }
.set-new .plus { font-size: 30px; opacity: 0.6; }
/* ---- 分镜视图 ---- */
.sb-stats {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 8px 12px; margin-bottom: 12px;
  border: 1px solid var(--hair); border-radius: 12px; background: var(--surface);
  font-size: 12px; color: var(--dim);
}
.sb-tip { color: #fcd34d; }
.sb-code {
  font-family: var(--mono); font-size: 11px; padding: 2px 7px; border-radius: 5px;
  background: rgba(168, 85, 247, 0.16); color: #e9d5ff; border: 1px solid rgba(168, 85, 247, 0.35);
}
.sb-count-g b { color: #cfd6e4; font-weight: 600; margin-right: 4px; }
.sb-layout { display: grid; grid-template-columns: 320px minmax(0, 1fr) 236px; gap: 12px; align-items: start; }
.sb-left, .sb-right {
  border: 1px solid var(--hair); border-radius: 12px; background: var(--surface);
  padding: 10px; display: flex; flex-direction: column; gap: 10px;
}
.sb-sec-head { font-size: 11.5px; color: var(--dim); margin-bottom: 6px; }
.sb-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.sb-thumb {
  position: relative; aspect-ratio: 3 / 4; border-radius: 8px; overflow: hidden;
  border: 1px solid var(--hair-strong); background: #0d0f14; padding: 0; color: inherit; cursor: pointer;
}
.sb-thumb img { width: 100%; height: 100%; object-fit: cover; }
.sb-thumb .ph { display: grid; place-items: center; width: 100%; height: 100%; font-size: 16px; opacity: 0.5; }
.sb-thumb .name {
  position: absolute; left: 0; right: 0; bottom: 0;
  font-size: 9.5px; padding: 2px 3px; background: rgba(0, 0, 0, 0.66);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #e5e7eb;
}
.sb-thumb.is-picked { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.35); }
.sb-thumb-add { border-style: dashed; color: var(--dim); }
.sb-controls { display: flex; flex-direction: column; gap: 8px; }
.sb-controls .row { display: flex; gap: 8px; }
.sb-controls .select-dark { flex: 1; max-width: none; }
.sb-cost { font-size: 11.5px; color: #fcd34d; display: grid; place-items: center; }
.sb-prompt {
  border: 1px solid rgba(168, 85, 247, 0.45); border-radius: 12px;
  background: rgba(168, 85, 247, 0.06); padding: 10px;
}
.sb-prompt-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; font-size: 12.5px; }
.sb-prompt textarea {
  width: 100%; min-height: 180px; background: transparent; border: none; color: #e9ebf2;
  font-size: 12.5px; line-height: 1.8; resize: vertical;
}
.sb-prompt textarea:focus { outline: none; }
.sb-prompt-foot { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.sb-check { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; color: var(--dim); }
.sb-center { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.sb-player { aspect-ratio: 16 / 9; }
.sb-timeline {
  display: flex; align-items: center; gap: 12px; font-size: 12px;
  padding: 8px 10px; border: 1px solid var(--hair); border-radius: 10px; background: var(--surface);
}
.sb-play {
  width: 30px; height: 30px; border-radius: 50%; border: none;
  background: linear-gradient(135deg, #22d3ee, #0891b2); color: #fff; font-size: 12px;
}
.sb-strip { border: 1px solid var(--hair); border-radius: 10px; background: var(--surface); padding: 8px; }
.sb-records-head { display: flex; align-items: baseline; justify-content: space-between; font-size: 12.5px; }
.sb-records { display: flex; flex-direction: column; gap: 8px; max-height: 620px; overflow-y: auto; }
.sb-record {
  border: 1px solid var(--hair); border-radius: 10px; overflow: hidden; background: var(--surface-2);
}
.sb-record.is-inuse { border-color: rgba(34, 211, 238, 0.55); box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.18); }
.sb-record img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.sb-record-meta { display: flex; align-items: center; gap: 5px; padding: 5px 7px 0; flex-wrap: wrap; }
.sb-record-model { font-size: 10.5px; color: var(--dim); padding: 2px 7px 6px; }
.sb-record-actions { display: flex; gap: 6px; padding: 0 7px 7px; }
.sb-record-actions .btn { flex: 1; height: 26px; font-size: 11px; }
.btn.is-on { border-color: rgba(168, 85, 247, 0.6); color: #e9d5ff; }
@media (max-width: 1280px) {
  .sb-layout { grid-template-columns: 280px minmax(0, 1fr); }
  .sb-right { grid-column: 1 / -1; }
}
/* ---- 本集资产管理弹窗 ---- */
.ea-modal { position: fixed; inset: 0; z-index: 150; display: grid; place-items: center; }
.ea-box {
  position: relative; width: min(1360px, 96vw); max-height: 92vh; overflow: hidden;
  display: flex; flex-direction: column;
  background: #101218; border: 1px solid var(--hair-strong); border-radius: 16px;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.7);
}
.ea-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 16px 18px 8px; }
.ea-head h3 { margin: 0 0 6px; font-size: 18px; }
.ea-close {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--hair-strong);
  background: transparent; color: #cfd6e4; font-size: 14px;
}
.ea-hint {
  margin: 0 18px 10px; padding: 9px 12px; border-radius: 9px; font-size: 12px; line-height: 1.7;
  background: rgba(245, 158, 11, 0.14); border: 1px solid rgba(245, 158, 11, 0.35); color: #fcd34d;
}
.ea-body { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 14px; padding: 0 18px; overflow: hidden; min-height: 0; }
.ea-lib { border: 1px solid var(--hair); border-radius: 12px; padding: 10px; background: var(--surface); display: flex; flex-direction: column; min-height: 0; }
.ea-lib-head { font-size: 13px; font-weight: 600; }
.ea-lib-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 3px; border-radius: 9px; background: var(--surface-2); margin: 8px 0; }
.ea-lib-tab { border: none; background: transparent; color: var(--dim); font-size: 12px; padding: 6px 0; border-radius: 7px; }
.ea-lib-tab.is-active { background: rgba(168, 85, 247, 0.22); color: #e9d5ff; }
.ea-lib-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; overflow-y: auto; margin-top: 8px; }
.ea-lib-item { border: 1px solid var(--hair); border-radius: 8px; background: transparent; padding: 0; overflow: hidden; color: inherit; cursor: pointer; }
.ea-lib-item:hover { border-color: rgba(168, 85, 247, 0.6); }
.ea-lib-pic { aspect-ratio: 1; display: grid; place-items: center; font-size: 18px; background: #0d0f14; }
.ea-lib-pic img { width: 100%; height: 100%; object-fit: cover; }
.ea-lib-name { display: block; font-size: 10px; padding: 3px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
.ea-cast { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; overflow: hidden; }
.ea-col { border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); padding: 10px; display: flex; flex-direction: column; gap: 8px; min-height: 0; }
.ea-col-head { display: flex; align-items: center; justify-content: space-between; font-size: 13px; font-weight: 600; }
.ea-count { font-family: var(--mono); font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--surface-3); color: var(--dim); }
.ea-chips { display: flex; flex-wrap: wrap; gap: 6px; min-height: 28px; max-height: 260px; overflow-y: auto; }
.ea-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 6px 3px 9px; border-radius: 7px; font-size: 12px; border: 1px solid rgba(168, 85, 247, 0.45); background: rgba(168, 85, 247, 0.14); color: #e9d5ff; }
.ea-scene .ea-chip { border-color: rgba(34, 211, 238, 0.45); background: rgba(34, 211, 238, 0.12); color: #a5f3fc; }
.ea-prop .ea-chip { border-color: rgba(245, 158, 11, 0.45); background: rgba(245, 158, 11, 0.12); color: #fcd34d; }
.ea-chip-x { border: none; background: transparent; color: inherit; font-size: 13px; line-height: 1; padding: 0 2px; opacity: 0.75; }
.ea-chip-x:hover { opacity: 1; }
.ea-add { display: flex; flex-direction: column; gap: 6px; margin-top: auto; }
.ea-add textarea { min-height: 74px; font-size: 12px; }
.ea-foot { display: flex; align-items: center; gap: 12px; padding: 12px 18px 16px; }
.ea-warn { flex: 1; font-size: 12px; color: #fcd34d; padding: 8px 12px; border-radius: 9px; background: rgba(245, 158, 11, 0.12); border: 1px solid rgba(245, 158, 11, 0.3); }
.ea-menu {
  position: fixed; z-index: 160; min-width: 190px; padding: 6px;
  background: #151821; border: 1px solid var(--hair-strong); border-radius: 10px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.6); display: flex; flex-direction: column; gap: 2px;
}
.ea-menu-item { border: none; background: transparent; color: #e9ebf2; text-align: left; font-size: 12.5px; padding: 8px 10px; border-radius: 7px; }
.ea-menu-item:hover { background: rgba(168, 85, 247, 0.16); }
@media (max-width: 1100px) {
  .ea-body { grid-template-columns: 1fr; }
  .ea-cast { grid-template-columns: 1fr; }
}
/* ---- 创作助理 ---- */
.as-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 14px; align-items: start; }
.as-side { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 14px; position: sticky; top: 76px; }
.as-side-head { display: flex; flex-direction: column; gap: 2px; margin-bottom: 12px; }
.as-side-head strong { font-size: 14px; }
.as-side .select-dark { max-width: none; }
.as-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 14px 0; }
.as-stat { border: 1px solid var(--hair); border-radius: 9px; padding: 8px 10px; background: var(--surface-2); }
.as-stat span { display: block; font-size: 11px; color: var(--dim); }
.as-stat b { font-size: 14px; }
.as-quick { display: flex; flex-direction: column; gap: 6px; }
.as-quick-item {
  text-align: left; border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4;
  border-radius: 9px; padding: 9px 10px; font-size: 12.5px;
}
.as-quick-item:hover { border-color: rgba(168, 85, 247, 0.6); background: rgba(168, 85, 247, 0.08); color: #fff; }
.as-main { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); display: flex; flex-direction: column; min-height: 70vh; }
.as-main-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--hair); }
.as-main-head strong { font-size: 14px; margin-right: 8px; }
.as-thread { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 14px; max-height: 56vh; }
.as-msg { display: flex; flex-direction: column; gap: 6px; max-width: 78%; }
.as-user { align-self: flex-end; align-items: flex-end; }
.as-assistant, .as-system { align-self: flex-start; }
.as-bubble { padding: 11px 14px; border-radius: 12px; font-size: 13px; line-height: 1.8; white-space: pre-wrap; }
.as-assistant .as-bubble { background: var(--surface-2); border: 1px solid var(--hair); }
.as-user .as-bubble { background: linear-gradient(135deg, #7c3aed, #c026d3); color: #fff; }
.as-system .as-bubble { background: rgba(34, 211, 238, 0.1); border: 1px dashed rgba(34, 211, 238, 0.4); color: #a5f3fc; font-size: 12px; }
.as-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.as-time { font-size: 10.5px; color: #5f6779; }
.as-compose { border-top: 1px solid var(--hair); padding: 12px 14px; }
.as-compose textarea { min-height: 74px; }
.as-compose-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
@media (max-width: 1000px) {
  .as-layout { grid-template-columns: 1fr; }
  .as-side { position: static; }
}
/* ============ 顶栏 v2（对齐真实产品） ============ */
.appbar {
  height: 64px; gap: 10px; padding: 0 18px;
  background: #0b0c10;
  border-bottom: none;
}
.appbar .brand {
  gap: 10px; font-size: 17px; letter-spacing: 0.2px;
  color: #fff;
}
.appbar .brand i {
  width: 30px; height: 30px; border-radius: 8px;
  display: grid; place-items: center; font-style: normal; font-size: 14px;
  background: linear-gradient(135deg, #a855f7, #22d3ee);
  -webkit-text-fill-color: #0b0c10; color: #0b0c10;
}
.appbar .brand em { font-style: normal; font-weight: 500; color: #cbd5e1; font-size: 13px; }
.top-link {
  height: 34px; padding: 0 14px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14); background: rgba(255, 255, 255, 0.03);
  color: #e5e7eb; font-size: 13px; white-space: nowrap;
}
.top-link:hover { background: rgba(255, 255, 255, 0.09); }
.top-bell { position: relative; display: inline-flex; align-items: center; gap: 6px; }
.bell-dot {
  position: absolute; top: 5px; right: 9px; width: 7px; height: 7px;
  border-radius: 50%; background: #ef4444;
}
.top-chip {
  height: 34px; display: inline-flex; align-items: center; gap: 6px;
  padding: 0 14px; border-radius: 999px; font-size: 13px; white-space: nowrap;
}
.top-chip-gold { background: linear-gradient(135deg, #f5d0a9, #e7b98a); color: #3b2a17; font-weight: 600; }
.top-chip-cyan { background: linear-gradient(135deg, #a5e8f5, #7dd3e8); color: #113340; font-weight: 600; }
.top-chip:hover { filter: brightness(1.05); }
.top-who {
  height: 38px; display: inline-flex; align-items: center; gap: 9px;
  padding: 0 14px 0 6px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(255, 255, 255, 0.04);
  color: #e5e7eb; font-size: 13px;
}
.top-who:hover { background: rgba(255, 255, 255, 0.08); }
.who-avatar {
  width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, #475569, #1e293b); font-size: 14px;
}
.who-caret { font-size: 10px; color: #94a3b8; }

/* 账号下拉 */
.acct-menu {
  position: fixed; z-index: 170; width: 300px; padding: 8px;
  background: #15171d; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 14px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.7);
}
.acct-group { font-size: 11px; color: #8b93a3; padding: 8px 10px 4px; }
.acct-row {
  width: 100%; display: flex; align-items: center; gap: 10px;
  border: none; background: transparent; color: #e5e7eb;
  padding: 9px 10px; border-radius: 9px; font-size: 13px; text-align: left;
}
.acct-row:hover { background: rgba(255, 255, 255, 0.07); }
.acct-row.is-on { color: #86efac; }
.acct-row.is-danger { color: #fca5a5; }
.acct-ico { width: 18px; display: inline-grid; place-items: center; }
.acct-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-check { color: #22c55e; }
.acct-empty { font-size: 12px; color: #6b7280; padding: 6px 10px; }
.acct-hr { height: 1px; background: rgba(255, 255, 255, 0.08); margin: 6px 4px; }
.tut-list { margin: 0; padding-left: 18px; font-size: 12.5px; color: #cfd6e4; line-height: 2; }

/* ============ 左侧图标栏 v2 ============ */
.rail {
  left: 14px; top: 50%; transform: translateY(-50%);
  gap: 4px; padding: 8px 6px; border-radius: 22px;
  background: #101216; border: 1px solid rgba(255, 255, 255, 0.08);
}
.rail-a {
  width: 46px; padding: 7px 0; border-radius: 14px;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: #8b93a3; font-size: 10px;
}
.rail-a:hover { background: rgba(255, 255, 255, 0.07); color: #fff; }
.rail-a.is-active {
  background: linear-gradient(135deg, #a855f7, #d946ef); color: #fff;
  box-shadow: 0 8px 22px rgba(168, 85, 247, 0.4);
}
.rail-i { font-size: 16px; line-height: 1; }
.rail-t { display: none; }
.rail hr { width: 26px; margin: 6px 0; border: none; border-top: 1px solid rgba(255, 255, 255, 0.1); }
@media (max-width: 900px) {
  .rail-t { display: none; }
  .rail-a { width: 40px; }
  .top-link { padding: 0 10px; font-size: 12px; }
  .top-chip { padding: 0 10px; font-size: 12px; }
}
/* ============ 我的项目 ============ */
.pj-toolbar { padding: 10px; gap: 10px; }
.pj-search { position: relative; flex: 1; min-width: 240px; }
.pj-search-ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); font-size: 12px; opacity: 0.6; }
.pj-search .input-dark { padding-left: 34px; }
.pd-select {
  height: 42px; min-width: 150px; padding: 0 14px; border-radius: 10px;
  background: #1b2130; border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e5e7eb; font-size: 13px;
}
.pj-refresh { height: 42px; }
.pj-empty {
  grid-column: 1 / -1; min-height: 340px; display: grid; place-items: center; gap: 6px;
  border: 1px dashed rgba(255, 255, 255, 0.14); border-radius: 12px; cursor: pointer;
  background: rgba(255, 255, 255, 0.012);
}
.pj-empty:hover { border-color: rgba(168, 85, 247, 0.5); background: rgba(168, 85, 247, 0.04); }
.pj-empty-ico { font-size: 30px; color: #a855f7; }
.pj-empty-title { font-size: 15px; color: #e5e7eb; }
.pj-empty-sub { font-size: 12.5px; color: #7c8496; }

/* 创建作品弹窗 */
.pj-modal { position: fixed; inset: 0; z-index: 160; display: grid; place-items: center; }
.pj-box {
  position: relative; width: min(1240px, 96vw); max-height: 94vh; overflow: hidden;
  display: flex; flex-direction: column;
  background: #0f1115; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 16px;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.75);
}
.pj-head { display: flex; align-items: center; gap: 12px; padding: 18px 20px 12px; border-bottom: 1px solid rgba(255, 255, 255, 0.07); }
.pj-head-ico {
  width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(135deg, #10b981, #14b8a6); color: #06281f; font-size: 18px;
}
.pj-head h3 { margin: 0 0 2px; font-size: 19px; }
.pj-head p { margin: 0; font-size: 12px; color: #8b93a3; }
.pj-x { margin-left: auto; width: 32px; height: 32px; border-radius: 50%; border: none; background: transparent; color: #94a3b8; font-size: 15px; }
.pj-x:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.pj-body { overflow-y: auto; padding: 14px 20px 8px; display: flex; flex-direction: column; gap: 12px; }
.pj-sec { border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 12px; padding: 14px 16px; background: rgba(255, 255, 255, 0.015); }
.pj-sec-two { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 18px; }
.pj-sec-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.pj-label { font-size: 13px; color: #cfd6e4; display: block; margin-bottom: 8px; }
.pj-label em { color: #f87171; font-style: normal; margin-left: 2px; }
.pj-label span { color: #7c8496; font-size: 12px; }
.pj-help { font-size: 11.5px; color: #7c8496; }
.pj-input { height: 46px; font-size: 14px; }
.pj-hint { font-size: 11.5px; color: #7c8496; margin: 8px 0 0; line-height: 1.7; }
.pj-mode {
  display: flex; align-items: flex-start; gap: 10px; padding: 14px 16px; border-radius: 10px;
  border: 1px solid rgba(245, 158, 11, 0.55); background: rgba(245, 158, 11, 0.08); cursor: pointer;
}
.pj-mode input { margin-top: 3px; accent-color: #f59e0b; }
.pj-mode strong { display: block; font-size: 14px; margin-bottom: 3px; }
.pj-mode span { font-size: 12px; color: #a8b0c0; }
.pj-cover {
  width: 100%; aspect-ratio: 4 / 3; display: grid; place-items: center; gap: 4px;
  border: 1px dashed rgba(255, 255, 255, 0.18); border-radius: 12px; background: transparent;
  color: #7c8496; padding: 0; overflow: hidden; position: relative;
}
.pj-cover:hover { border-color: rgba(168, 85, 247, 0.55); }
.pj-cover-plus { font-size: 30px; }
.pj-cover-tip { font-size: 13px; color: #cbd5e1; }
.pj-cover-sub { font-size: 11px; }
.pj-cover-img { width: 100%; height: 100%; object-fit: cover; }
.pj-design { border: 1px solid rgba(168, 85, 247, 0.5); background: rgba(168, 85, 247, 0.12); color: #e9d5ff; border-radius: 8px; font-size: 12px; padding: 5px 10px; }
.pj-style-switch { display: inline-flex; gap: 4px; padding: 3px; border-radius: 9px; background: #171a21; }
.pj-style-switch button { border: none; background: transparent; color: #8b93a3; font-size: 12px; padding: 6px 12px; border-radius: 7px; }
.pj-style-switch button.is-on { background: rgba(168, 85, 247, 0.24); color: #fff; }
.pj-style-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px;
  max-height: 260px; overflow-y: auto; padding-right: 4px;
}
.pj-style { border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 10px; overflow: hidden; background: transparent; padding: 0; cursor: pointer; }
.pj-style.is-on { border-color: #a855f7; box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.28); }
.pj-style-art {
  aspect-ratio: 1; display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(140deg, #1f2937, #312e81 60%, #0e7490);
}
.pj-style:nth-child(3n) .pj-style-art { background: linear-gradient(140deg, #3f1d38, #7c2d12 60%, #b45309); }
.pj-style:nth-child(4n) .pj-style-art { background: linear-gradient(140deg, #0f172a, #1e3a8a 60%, #155e75); }
.pj-style-name { display: block; font-size: 11px; color: #cbd5e1; padding: 5px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pj-budget { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.pj-budget-row { display: flex; gap: 18px; font-size: 12px; color: #9aa3b6; margin-bottom: 4px; }
.pj-budget-row b { color: #e5e7eb; }
.pj-note {
  padding: 12px 14px; border-radius: 10px; font-size: 12.5px;
  background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.3); color: #fcd34d;
}
.pj-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px 18px; border-top: 1px solid rgba(255, 255, 255, 0.07); }
@media (max-width: 980px) {
  .pj-sec-two { grid-template-columns: 1fr; }
  .pj-body { padding: 12px; }
}
/* ============ 首页四宫格 ============ */
.home-body { min-height: 100dvh; }
.home-main { padding: 22px 26px 40px 78px; max-width: 1560px; margin: 0 auto; }
.home-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.home-card {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  border-radius: 18px; border: 1px solid rgba(255, 255, 255, 0.08);
  background: #14161c; min-height: 420px; color: #fff;
  transition: transform 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.home-card:hover { transform: translateY(-4px); border-color: rgba(168, 85, 247, 0.45); box-shadow: 0 26px 60px rgba(0, 0, 0, 0.5); }
.hc-art { flex: 1; position: relative; display: grid; place-items: center; font-size: 13px; color: rgba(255, 255, 255, 0.5); letter-spacing: 6px; }
.hc-art::after { content: ""; position: absolute; inset: 0; background: radial-gradient(120% 80% at 50% 20%, rgba(255,255,255,0.16), transparent 60%); }
.art-1 { background: linear-gradient(160deg, #1f2937 0%, #334155 40%, #0f172a 100%); }
.art-2 { background: linear-gradient(160deg, #1c1917 0%, #44403c 45%, #0c0a09 100%); }
.art-3 { background: linear-gradient(160deg, #111827 0%, #1e3a8a 55%, #0b1120 100%); }
.art-4 { background: linear-gradient(160deg, #1e1b4b 0%, #4c1d95 55%, #0b1020 100%); }
.hc-body { padding: 18px 20px 20px; background: linear-gradient(180deg, rgba(10, 11, 14, 0.2), rgba(10, 11, 14, 0.92) 40%); }
.hc-body h3 { margin: 0 0 8px; font-size: 24px; letter-spacing: 0.5px; }
.hc-body p { margin: 0 0 12px; font-size: 12.5px; line-height: 1.8; color: #a8b0c0; }
.hc-cta { font-size: 13px; font-weight: 600; }
.cta-gold { color: #fbbf24; }
.cta-green { color: #34d399; }
.cta-pink { color: #f472b6; }
.cta-purple { color: #c084fc; }
.cta-red { color: #fb7185; }
.home-card-wide {
  grid-column: span 2; flex-direction: row; align-items: center; gap: 16px;
  min-height: 168px; padding: 18px 22px;
}
.hc-wide-ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; flex: none; z-index: 1; }
.hc-ico-red { background: rgba(244, 63, 94, 0.16); color: #fb7185; }
.hc-ico-purple { background: rgba(168, 85, 247, 0.16); color: #c084fc; }
.hc-wide-body { flex: 1; min-width: 0; z-index: 1; }
.hc-wide-body h3 { margin: 0 0 6px; font-size: 20px; }
.hc-wide-body p { margin: 0 0 10px; font-size: 12.5px; color: #a8b0c0; }
.hc-wide-art { position: absolute; right: 0; top: 0; bottom: 0; width: 38%; opacity: 0.5; }
.art-5 { background: linear-gradient(120deg, transparent, #4c0519 60%, #881337); }
.art-6 { background: linear-gradient(120deg, transparent, #2e1065 60%, #4c1d95); }
.home-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 26px; font-size: 12px; color: #6b7280; }
.home-login { color: #c084fc; }
@media (max-width: 1200px) {
  .home-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-card { min-height: 320px; }
}
@media (max-width: 720px) {
  .home-grid { grid-template-columns: 1fr; }
  .home-main { padding: 14px 14px 40px 66px; }
  .home-card-wide { grid-column: span 1; }
}
.rail-a { width: 46px; height: 46px; border-radius: 50%; justify-content: center; }
.rail-a.is-active { border-radius: 50%; }

/* ============ 剧集列表（带竖排分页） ============ */
.ep-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 0 12px 10px; }
.ep-chip {
  position: relative; height: 40px; border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1); background: #191d26;
  color: #d7dce6; font-size: 13px; font-variant-numeric: tabular-nums;
}
.ep-chip:hover { border-color: rgba(168, 85, 247, 0.55); }
.ep-chip.is-active { background: linear-gradient(135deg, #a855f7, #c026d3); border-color: transparent; color: #fff; }
.ep-dot { position: absolute; right: 5px; top: 5px; width: 5px; height: 5px; border-radius: 50%; background: #22c55e; }
.ep-pager { display: flex; flex-direction: column; gap: 6px; padding: 0 12px 12px; }
.ep-page {
  display: flex; align-items: center; justify-content: center; gap: 2px;
  height: 40px; border-radius: 8px; border: 1px solid rgba(255, 255, 255, 0.1);
  background: #191d26; color: #9aa3b6; font-size: 11.5px; font-variant-numeric: tabular-nums;
}
.ep-page.is-active { color: #fff; border-color: rgba(168, 85, 247, 0.65); background: rgba(168, 85, 247, 0.2); }
.ep-page-dash { opacity: 0.5; }
.ep-done { font-size: 10.5px; padding: 2px 7px; border-radius: 5px; background: rgba(34, 197, 94, 0.18); color: #86efac; border: 1px solid rgba(34, 197, 94, 0.4); }
.sb-link { border: none; background: transparent; color: #a5b4fc; font-size: 11.5px; text-decoration: underline; }

/* ============ 追加剧集弹窗 ============ */
.imp-modal { position: fixed; inset: 0; z-index: 170; display: grid; place-items: center; }
.imp-box {
  position: relative; width: min(1320px, 96vw); max-height: 92vh; overflow: hidden;
  display: flex; flex-direction: column; background: #101216;
  border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 16px;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.75);
}
.imp-head { display: flex; align-items: flex-start; gap: 16px; padding: 18px 20px 12px; }
.imp-head h3 { margin: 0 0 6px; font-size: 20px; }
.imp-head p { margin: 0; font-size: 12.5px; color: #8b93a3; }
.imp-tip {
  flex: 1; max-width: 640px; padding: 10px 14px; border-radius: 10px; font-size: 12px; line-height: 1.75;
  background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.4); color: #fcd34d;
}
.imp-x { width: 32px; height: 32px; border-radius: 50%; border: none; background: transparent; color: #94a3b8; font-size: 15px; }
.imp-x:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.imp-body { padding: 0 20px; overflow-y: auto; }
.imp-tabrow { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.imp-tab { padding: 8px 18px; border-radius: 10px; background: linear-gradient(135deg, #6d28d9, #7c3aed); color: #fff; font-size: 13px; }
.imp-mode { font-size: 12px; color: #8b93a3; }
.imp-notice {
  padding: 12px 14px; border-radius: 10px; margin-bottom: 12px; font-size: 12.5px;
  background: #1a1d24; border: 1px solid rgba(255, 255, 255, 0.08); color: #e5e7eb;
}
.imp-notice::first-letter { color: #fbbf24; }
.imp-editor { position: relative; border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 12px; background: #0c0e12; padding: 10px 12px 34px; }
.imp-tools { display: flex; justify-content: flex-end; gap: 10px; margin-bottom: 8px; }
.imp-link { border: none; background: transparent; color: #8b93a3; font-size: 12px; }
.imp-link:hover { color: #fff; }
.imp-file { border: 1px solid rgba(168, 85, 247, 0.6); background: rgba(168, 85, 247, 0.14); color: #e9d5ff; border-radius: 8px; font-size: 12px; padding: 6px 12px; }
.imp-area { width: 100%; min-height: 320px; background: transparent; border: none; color: #e9ebf2; font-size: 13.5px; line-height: 1.9; resize: vertical; }
.imp-area:focus { outline: none; }
.imp-counter { position: absolute; right: 14px; bottom: 10px; font-size: 11.5px; color: #7c8496; font-variant-numeric: tabular-nums; }
.imp-foot { display: flex; align-items: center; gap: 12px; padding: 14px 20px 18px; border-top: 1px solid rgba(255, 255, 255, 0.07); }
.imp-hint { flex: 1; font-size: 12px; color: #7c8496; }

/* ============ 审核中心 ============ */
.rv-page { display: flex; flex-direction: column; gap: 14px; }
.rv-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px; border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); flex-wrap: wrap; }
.rv-title { display: flex; align-items: center; gap: 12px; }
.rv-ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: rgba(168, 85, 247, 0.18); font-size: 20px; }
.rv-title h2 { margin: 0 0 4px; font-size: 20px; }
.rv-title p { margin: 0; font-size: 12px; color: var(--dim); }
.rv-stats { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rv-stat { font-size: 12px; color: #cfd6e4; padding: 6px 12px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--hair); font-variant-numeric: tabular-nums; }
.rv-stat b { font-weight: 500; color: var(--dim); margin-right: 6px; font-size: 11.5px; }
.rv-stat i { font-style: normal; color: var(--dim); margin-left: 2px; }
.rv-stat.is-warn { border-color: rgba(245, 158, 11, 0.4); color: #fcd34d; }
.rv-stat.is-ok { border-color: rgba(34, 197, 94, 0.4); color: #86efac; }
.rv-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rv-filter { display: inline-flex; align-items: center; gap: 8px; border-radius: 10px; border: 1px solid var(--hair); background: var(--surface); color: #cfd6e4; font-size: 12.5px; padding: 8px 14px; }
.rv-filter.is-active { background: linear-gradient(135deg, #7c3aed, #a855f7); border-color: transparent; color: #fff; }
.rv-count { font-size: 11px; padding: 0 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.12); }
.rv-searchbox { margin-left: auto; display: flex; gap: 8px; }
.rv-search { width: 300px; height: 38px; }
.rv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(400px, 1fr)); gap: 14px; }
.rv-card { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.rv-card-head { display: flex; align-items: center; gap: 10px; }
.rv-card-head strong { font-size: 15px; }
.rv-play { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4; font-size: 11px; }
.rv-play:hover { background: rgba(168, 85, 247, 0.2); color: #fff; }
.rv-dl { border: none; background: transparent; color: var(--dim); font-size: 12px; }
.rv-dl:hover { color: #fff; }
.rv-status { font-size: 11px; padding: 3px 9px; border-radius: 6px; border: 1px solid rgba(245, 158, 11, 0.4); background: rgba(245, 158, 11, 0.12); color: #fcd34d; }
.rv-card-meta { display: flex; align-items: center; gap: 10px; font-size: 11.5px; color: var(--dim); }
.rv-id, .rv-shots { padding: 3px 8px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--hair); font-variant-numeric: tabular-nums; }
.rv-bar { height: 5px; border-radius: 4px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.rv-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #a855f7, #c026d3); }
.rv-card-sum { font-size: 12.5px; color: #8b93a3; }
.rv-card-foot { display: flex; justify-content: flex-end; }
.rp-modal { position: fixed; inset: 0; z-index: 170; display: grid; place-items: center; }
.rp-box { position: relative; width: min(1100px, 94vw); max-height: 92vh; overflow-y: auto; background: #101216; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.rp-head { display: flex; align-items: center; gap: 10px; }
.rp-player { aspect-ratio: 16 / 9; }
.rp-meta { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--dim); }
.rp-strip { max-height: 120px; }
.rp-foot { display: flex; flex-direction: column; gap: 8px; }
.rp-comments { max-height: 160px; }
.help-list p { margin: 0 0 8px; font-size: 12.5px; line-height: 1.9; color: #cfd6e4; }
@media (max-width: 720px) {
  .ep-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .rv-grid { grid-template-columns: 1fr; }
  .rv-search { width: 100%; }
}
/* ============ 素材详情（三栏） ============ */
.ad-page { display: flex; flex-direction: column; gap: 12px; }
.ad-head { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); }
.ad-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr) 320px; gap: 12px; align-items: start; }
.ad-left, .ad-right, .ad-center { border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.ad-center { min-width: 0; }
.ad-title { font-size: 13px; font-weight: 700; padding-bottom: 8px; border-bottom: 1px solid var(--hair); }
.ad-main { aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: #0c0e12; display: grid; place-items: center; }
.ad-main img { width: 100%; height: 100%; object-fit: cover; }
.ad-subs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.ad-sub { aspect-ratio: 3 / 4; border-radius: 8px; overflow: hidden; background: #0c0e12; border: 1px solid var(--hair); display: grid; place-items: center; font-size: 10px; color: var(--dim); }
.ad-sub img { width: 100%; height: 100%; object-fit: cover; }
.ad-sub.is-empty { border-style: dashed; }
.ad-style-switch { display: inline-flex; gap: 4px; padding: 3px; border-radius: 9px; background: var(--surface-2); align-self: flex-start; }
.ad-style-switch button { border: none; background: transparent; color: var(--dim); font-size: 12px; padding: 6px 12px; border-radius: 7px; }
.ad-style-switch button.is-on { background: rgba(168, 85, 247, 0.24); color: #fff; }
.ad-styles { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.ad-style { flex: none; width: 92px; border: 1px solid var(--hair); border-radius: 9px; overflow: hidden; background: transparent; padding: 0; color: inherit; cursor: pointer; }
.ad-style.is-on { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.28); }
.ad-style-art { aspect-ratio: 1; display: grid; place-items: center; font-size: 20px; background: linear-gradient(140deg, #1f2937, #312e81 60%, #0e7490); }
.ad-style span { display: block; font-size: 10px; padding: 4px 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #cbd5e1; }
.ad-sec-head { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.ad-refs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ad-ref { aspect-ratio: 1; border: 1px dashed var(--hair-strong); border-radius: 10px; display: grid; place-items: center; gap: 2px; color: var(--dim); font-size: 11px; overflow: hidden; cursor: pointer; }
.ad-ref.has { border-style: solid; }
.ad-ref img { width: 100%; height: 100%; object-fit: cover; }
.ad-ref-plus { font-size: 20px; opacity: 0.6; }
.ad-siblings { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
.ad-sibling { flex: none; width: 56px; height: 56px; border-radius: 8px; overflow: hidden; border: 1px solid var(--hair); background: #0c0e12; padding: 0; }
.ad-sibling img { width: 100%; height: 100%; object-fit: cover; }
.ad-prompt-bar { display: flex; align-items: center; gap: 8px; width: 100%; }
.ad-prompt { min-height: 160px; }
.ad-right-head { display: flex; align-items: center; justify-content: space-between; }
.ad-gens { display: flex; flex-direction: column; gap: 8px; max-height: 520px; overflow-y: auto; }
.ad-gen { border: 1px solid var(--hair); border-radius: 9px; overflow: hidden; background: var(--surface-2); }
.ad-gen img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.ad-gen-meta { display: flex; justify-content: space-between; padding: 4px 8px; font-size: 10.5px; color: var(--dim); }
.ad-empty { text-align: center; color: var(--dim); font-size: 12px; padding: 30px 10px; border: 1px dashed var(--hair); border-radius: 10px; }
.ad-empty .big { font-size: 26px; display: block; margin-bottom: 8px; opacity: 0.6; }
@media (max-width: 1200px) { .ad-layout { grid-template-columns: 1fr; } }
/* ============ 进入作品设定弹窗 ============ */
.an-modal { position: fixed; inset: 0; z-index: 175; display: grid; place-items: center; }
.an-box {
  position: relative; width: min(920px, 94vw);
  background: #14161c; border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 14px;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.75); overflow: hidden;
  display: flex; flex-direction: column;
}
.an-head { padding: 22px 26px 16px; border-bottom: 1px solid rgba(255, 255, 255, 0.07); }
.an-head h3 { margin: 0 0 10px; font-size: 20px; }
.an-head p { margin: 0; font-size: 14px; color: #cfd6e4; }
.an-actions { display: flex; justify-content: flex-end; align-items: center; gap: 14px; padding: 18px 26px; }
.an-warn {
  padding: 14px 26px; font-size: 12.5px; color: #fbbf24;
  border-top: 1px solid rgba(255, 255, 255, 0.07); border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(245, 158, 11, 0.06);
}
.an-model-head { padding: 14px 26px 6px; font-size: 12px; color: #8b93a3; }
.an-model {
  margin: 0 26px; display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12); background: #1b1f27; position: relative;
}
.an-dot { width: 9px; height: 9px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 8px rgba(34, 197, 94, 0.7); }
.an-select {
  flex: 1; appearance: none; background: transparent; border: none; color: #e5e7eb;
  font-size: 14px; padding-right: 20px; cursor: pointer;
}
.an-cost { font-size: 11.5px; color: #fbbf24; background: rgba(245, 158, 11, 0.14); border: 1px solid rgba(245, 158, 11, 0.4); border-radius: 6px; padding: 3px 8px; white-space: nowrap; }
.an-caret { color: #8b93a3; font-size: 11px; }
.an-again {
  margin: 14px 26px 24px; height: 46px; border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14); background: #1b1f27; color: #cfd6e4; font-size: 14px;
}
.an-again:hover { border-color: rgba(168, 85, 247, 0.5); color: #fff; }

/* 编辑器字数浮层 + 剧集列表横排（网格 + 竖排分页） */
.ep-editor-wrap { position: relative; }
.ep-count-float {
  position: absolute; right: 14px; bottom: 10px; font-size: 12px; color: #7c8496;
  font-variant-numeric: tabular-nums; background: rgba(10, 11, 14, 0.75); padding: 2px 8px; border-radius: 6px;
}
.ep-body { display: flex; gap: 8px; }
.ep-body .ep-grid { flex: 1; }
.ep-body .ep-pager { width: 58px; padding: 0 8px 10px 0; }
/* ============ 分镜顶栏工具 + 折叠 ============ */
.sb-tool {
  height: 26px; padding: 0 10px; border-radius: 7px; font-size: 11.5px;
  border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4;
}
.sb-tool:hover { border-color: rgba(168, 85, 247, 0.55); color: #fff; }
.sb-tool.is-on { border-color: rgba(34, 211, 238, 0.5); color: #a5f3fc; background: rgba(34, 211, 238, 0.1); }
.sb-seg { display: inline-flex; padding: 2px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--hair); }
.sb-seg button { border: none; background: transparent; color: var(--dim); font-size: 11.5px; padding: 4px 10px; border-radius: 6px; }
.sb-seg button.is-on { background: rgba(34, 197, 94, 0.2); color: #86efac; }
.sb-page.is-collapsed .sb-layout { grid-template-columns: 0 minmax(0, 1fr) 220px; }
.sb-page.is-collapsed .sb-left { display: none; }

/* 分镜历史 */
.hist-list { display: flex; flex-direction: column; gap: 8px; max-height: 56vh; overflow-y: auto; }
.hist-item { border: 1px solid var(--hair); border-radius: 10px; padding: 10px; background: var(--surface-2); display: flex; flex-direction: column; gap: 6px; }
.hist-head { display: flex; align-items: center; justify-content: space-between; font-size: 11.5px; }
.hist-text { font-size: 12px; color: #cfd6e4; line-height: 1.8; white-space: pre-wrap; max-height: 150px; overflow-y: auto; }
/* ============ 资产库（左树 + 右列表） ============ */
.al-page { padding-left: 78px; }
.al-shell { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 0; border: 1px solid var(--hair); border-radius: 14px; overflow: hidden; background: var(--surface); min-height: 72vh; }
.al-side { border-right: 1px solid var(--hair); padding: 14px; display: flex; flex-direction: column; gap: 12px; background: #0f1116; }
.al-scope { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 3px; border-radius: 10px; background: var(--surface-2); }
.al-scope button { border: none; background: transparent; color: var(--dim); font-size: 12.5px; padding: 8px 0; border-radius: 8px; }
.al-scope button.is-on { background: #1f2430; color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08); }
.al-kinds { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.al-kinds button { border: none; background: transparent; color: var(--dim); font-size: 12.5px; padding: 6px 0; border-radius: 7px; }
.al-kinds button.is-on { background: linear-gradient(135deg, #a855f7, #c026d3); color: #fff; }
.al-cats { display: flex; flex-direction: column; gap: 6px; }
.al-cat {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 10px 12px; border-radius: 9px; text-align: left;
  border: 1px solid rgba(168, 85, 247, 0.35); background: rgba(168, 85, 247, 0.08); color: #e9d5ff; font-size: 13px;
}
.al-cat.is-on { border-color: rgba(168, 85, 247, 0.8); background: rgba(168, 85, 247, 0.22); color: #fff; }
.al-cat-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.al-cat-count { font-size: 11px; color: var(--dim); }
.al-cat-up { font-size: 13px; opacity: 0.7; padding: 0 2px; }
.al-cat-up:hover { opacity: 1; }
.al-newcat { margin-top: auto; padding: 12px; border-radius: 9px; border: 1px dashed var(--hair-strong); background: transparent; color: var(--dim); font-size: 13px; }
.al-newcat:hover { border-color: rgba(168, 85, 247, 0.6); color: #fff; }
.al-main { padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.al-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-bottom: 10px; border-bottom: 1px solid var(--hair); }
.al-head h2 { margin: 0; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.al-count { font-size: 12px; color: var(--dim); background: var(--surface-2); border: 1px solid var(--hair); border-radius: 999px; padding: 1px 8px; }
.al-search { display: flex; align-items: center; gap: 8px; }
.al-label { font-size: 12px; color: var(--dim); }
.al-search .input-dark { width: 220px; height: 34px; }
.al-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.al-card { border: 1px solid var(--hair); border-radius: 12px; overflow: hidden; background: var(--surface-2); }
.al-pic { aspect-ratio: 3 / 4; display: grid; place-items: center; font-size: 26px; background: #0c0e12; color: #5f6779; }
.al-pic img { width: 100%; height: 100%; object-fit: cover; }
.al-info { display: flex; align-items: center; gap: 6px; padding: 8px 10px; font-size: 12px; }
.al-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.al-del { border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 10.5px; border-radius: 6px; padding: 2px 6px; }
.al-del:hover { color: #fca5a5; border-color: rgba(239, 68, 68, 0.5); }
.al-tag { font-size: 10px; color: var(--dim); flex: none; }
.al-empty { grid-column: 1 / -1; min-height: 320px; display: grid; place-items: center; align-content: center; gap: 6px; color: var(--dim); border: 1px dashed var(--hair); border-radius: 12px; }
.al-empty .big { font-size: 30px; opacity: 0.5; }
@media (max-width: 900px) {
  .al-shell { grid-template-columns: 1fr; }
  .al-side { border-right: none; border-bottom: 1px solid var(--hair); }
}
/* ============ 会员页 ============ */
.vip-eyebrow { margin: 0 0 6px; font-size: 12px; color: #c084fc; letter-spacing: 1px; }
.vip-records {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 12px 14px; border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); margin-bottom: 14px;
}
.vip-records-label { font-size: 12px; color: var(--dim); margin-right: 6px; }
.vip-record {
  flex: 1; min-width: 180px; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 16px; border-radius: 10px; font-size: 13px; color: #e9d5ff;
  border: 1px solid rgba(168, 85, 247, 0.35); background: rgba(168, 85, 247, 0.1);
}
.vip-record:hover { background: rgba(168, 85, 247, 0.18); border-color: rgba(168, 85, 247, 0.6); }
.vip-arrow { color: #c084fc; }
.vip-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 22px; }
.vip-card { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.vip-card-head { display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: var(--dim); }
.vip-redeem { border: 1px solid rgba(168, 85, 247, 0.5); background: rgba(168, 85, 247, 0.14); color: #e9d5ff; border-radius: 999px; font-size: 11.5px; padding: 4px 12px; }
.vip-points { display: flex; align-items: baseline; gap: 8px; }
.vip-points b { font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums; }
.vip-points span { font-size: 12px; color: var(--dim); }
.vip-muted { margin: 0; font-size: 12px; color: var(--dim); line-height: 1.7; }
.vip-compose { margin: 0; font-size: 12px; color: #a5b4fc; }
.vip-plan { font-size: 22px; font-weight: 700; }
.vip-card-quick { background: linear-gradient(150deg, rgba(76, 29, 149, 0.35), rgba(15, 17, 22, 0.9)); }
.vip-quick-btn {
  margin-top: auto; height: 44px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08); color: #e5e7eb; font-size: 13px;
}
.vip-quick-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.vip-section-title { margin: 0 0 12px; font-size: 18px; }
.vip-plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.vip-plan-card {
  border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 16px;
  display: flex; flex-direction: column; gap: 8px;
}
.vip-plan-name { font-size: 15px; font-weight: 700; }
.vip-plan-price { font-size: 30px; font-weight: 800; letter-spacing: -0.5px; }
.vip-plan-origin { font-size: 12px; color: #f59e0b; }
.vip-plan-perks { margin: 4px 0 0; padding-left: 16px; font-size: 12px; color: var(--dim); display: flex; flex-direction: column; gap: 3px; }
.vip-detail-row { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--hair); font-size: 13px; }
.vip-detail-row b { font-variant-numeric: tabular-nums; }
@media (max-width: 1100px) {
  .vip-plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vip-cards { grid-template-columns: 1fr; }
}
/* ============ 工坊 ============ */
.ws-tools { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.ws-tool {
  padding: 9px 18px; border-radius: 999px; font-size: 13px;
  border: 1px solid var(--hair-strong); background: var(--surface); color: var(--dim);
}
.ws-tool.is-on { background: linear-gradient(135deg, #a855f7, #c026d3); border-color: transparent; color: #fff; }
.wk-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 14px; align-items: start; }
.wk-side { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.wk-side-head { font-size: 13px; font-weight: 600; }
.wk-side-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.wk-side-btn { border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4; font-size: 11.5px; border-radius: 7px; padding: 5px 9px; }
.wk-side-btn:hover { border-color: rgba(168, 85, 247, 0.6); color: #fff; }
.wk-cat { font-size: 12px; color: #e9d5ff; background: rgba(168, 85, 247, 0.12); border: 1px solid rgba(168, 85, 247, 0.35); border-radius: 8px; padding: 7px 10px; }
.wk-search { height: 34px; }
.wk-list { display: flex; flex-direction: column; gap: 6px; max-height: 420px; overflow-y: auto; }
.wk-asset { display: flex; align-items: center; gap: 8px; border: 1px solid var(--hair); border-radius: 9px; background: var(--surface-2); padding: 6px; color: inherit; text-align: left; font-size: 12px; }
.wk-asset.is-on { border-color: rgba(168, 85, 247, 0.7); }
.wk-asset-pic { width: 34px; height: 34px; border-radius: 6px; overflow: hidden; display: grid; place-items: center; background: #0c0e12; flex: none; }
.wk-asset-pic img { width: 100%; height: 100%; object-fit: cover; }
.wk-empty { font-size: 12px; color: var(--dim); text-align: center; padding: 30px 0; }
.wk-main { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.wk-style-head { display: flex; align-items: center; justify-content: space-between; }
.wk-style-tabs { display: inline-flex; gap: 4px; padding: 3px; border-radius: 9px; background: var(--surface-2); }
.wk-style-tabs button { border: none; background: transparent; color: var(--dim); font-size: 12px; padding: 6px 14px; border-radius: 7px; }
.wk-style-tabs button.is-on { background: #1f2430; color: #fff; }
.wk-expand { border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 11.5px; border-radius: 7px; padding: 4px 10px; }
.wk-styles { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.wk-style { flex: none; width: 104px; border: 1px solid var(--hair); border-radius: 10px; overflow: hidden; background: transparent; color: inherit; padding: 0; cursor: pointer; }
.wk-style.is-on { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.28); }
.wk-style-art { aspect-ratio: 1; display: grid; place-items: center; font-size: 22px; background: linear-gradient(140deg, #1f2937, #312e81 60%, #0e7490); }
.wk-style span { display: block; font-size: 10.5px; padding: 5px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #cbd5e1; }
.wk-more { width: 74px; display: grid; place-items: center; font-size: 11.5px; color: var(--dim); }
.wk-sec-head { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.wk-hint { margin: 0; font-size: 11.5px; color: var(--dim); }
.wk-refs { display: flex; gap: 8px; flex-wrap: wrap; }
.wk-ref { position: relative; width: 84px; height: 84px; border-radius: 10px; overflow: hidden; border: 1px solid var(--hair-strong); background: #0c0e12; }
.wk-ref img { width: 100%; height: 100%; object-fit: cover; }
.wk-ref-add { border-style: dashed; display: grid; place-items: center; gap: 2px; color: var(--dim); font-size: 11px; }
.wk-ref-x { position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; border-radius: 50%; border: none; background: rgba(0, 0, 0, 0.65); color: #fff; font-size: 12px; line-height: 1; }
.wk-prompt { min-height: 96px; }
.wk-params { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wk-params .select-dark { max-width: 260px; }
.wk-qty { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; }
.wk-step { width: 26px; height: 26px; border-radius: 7px; border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4; }
.wk-generate { margin-left: auto; height: 42px; padding: 0 22px; }
.wk-gallery-head { display: flex; align-items: center; gap: 10px; font-size: 12.5px; padding-top: 10px; border-top: 1px solid var(--hair); flex-wrap: wrap; }
.wk-date { width: 210px; height: 32px; }
.wk-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.wk-gen { border: 1px solid var(--hair); border-radius: 10px; overflow: hidden; background: var(--surface-2); }
.wk-gen img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }
.wk-gen-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 6px 8px; font-size: 11px; }
.wk-empty-gallery { grid-column: 1 / -1; display: grid; place-items: center; gap: 6px; padding: 46px 10px; color: var(--dim); border: 1px dashed var(--hair); border-radius: 12px; }
.wk-empty-gallery .big { font-size: 26px; opacity: 0.5; }
.wk-big-box { width: min(900px, 94vw); }
.wk-big-view { display: grid; place-items: center; min-height: 320px; background: #0c0e12; border-radius: 12px; overflow: hidden; }
.wk-big-view img { max-width: 100%; max-height: 60vh; object-fit: contain; }
@media (max-width: 900px) {
  .wk-layout { grid-template-columns: 1fr; }
}
/* ============ 管理后台 ============ */
.ad-toolbar { padding: 10px 12px; gap: 10px; }
.ad-tabs { display: inline-flex; gap: 4px; padding: 3px; border-radius: 10px; background: var(--surface-2); }
.ad-tabs button { border: none; background: transparent; color: var(--dim); font-size: 12.5px; padding: 8px 16px; border-radius: 8px; }
.ad-tabs button.is-on { background: linear-gradient(135deg, #7c3aed, #a855f7); color: #fff; }
.ad-periods { display: inline-flex; gap: 4px; padding: 3px; border-radius: 10px; background: var(--surface-2); }
.ad-periods button { border: none; background: transparent; color: var(--dim); font-size: 12px; padding: 7px 14px; border-radius: 8px; }
.ad-periods button.is-on { background: #1f2430; color: #fff; }
.ad-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 14px; margin-bottom: 14px; }
.ad-chart { display: flex; align-items: flex-end; gap: 10px; height: 200px; padding: 8px 4px 0; }
.ad-col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
.ad-col i { display: block; width: 100%; max-width: 42px; border-radius: 6px 6px 0 0; background: linear-gradient(180deg, #a855f7, #6d28d9); min-height: 2px; }
.ad-value { font-size: 10px; color: var(--dim); font-variant-numeric: tabular-nums; }
.ad-x { font-size: 10.5px; color: #6b7280; }
.ad-split { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: rgba(255, 255, 255, 0.08); }
.ad-legend { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ad-legend li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #cfd6e4; }
.ad-dot { width: 8px; height: 8px; border-radius: 50%; background: #a855f7; }
.ad-legend li:nth-child(2) .ad-dot { background: #a78bfa; }
.ad-legend li:nth-child(3) .ad-dot { background: #f59e0b; }
.ad-legend li:nth-child(4) .ad-dot { background: #c026d3; }
.ad-legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.ad-progress { display: flex; flex-direction: column; gap: 8px; }
.ad-prow { display: flex; align-items: center; gap: 10px; font-size: 12px; }
.ad-pname { width: 120px; color: #cfd6e4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-bar { flex: 1; height: 6px; border-radius: 4px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.ad-bar i { display: block; height: 100%; background: linear-gradient(90deg, #a855f7, #c026d3); }
.ad-tasks { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.ad-task { border: 1px solid var(--hair); border-radius: 12px; background: var(--surface-2); padding: 12px; display: flex; flex-direction: column; gap: 6px; }
.ad-task-head { display: flex; align-items: center; justify-content: space-between; }
.ad-task-head strong { font-size: 14px; }
.ad-status { font-size: 11px; padding: 2px 8px; border-radius: 6px; border: 1px solid rgba(34, 197, 94, 0.4); background: rgba(34, 197, 94, 0.12); color: #86efac; }
.ad-task-meta { display: flex; gap: 12px; font-size: 12px; color: #cfd6e4; }
.ad-task-sub { font-size: 11.5px; color: #8b93a3; }
.ad-task-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; }
@media (max-width: 1100px) { .ad-grid { grid-template-columns: 1fr; } }
/* ============ 导演拉片播放页 ============ */
.rvp-page { display: flex; flex-direction: column; gap: 12px; }
.rvp-head {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 10px 14px; border: 1px solid var(--hair); border-radius: 12px; background: var(--surface);
}
.rvp-back { border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4; border-radius: 8px; font-size: 12px; padding: 6px 12px; }
.rvp-back:hover { border-color: rgba(168, 85, 247, 0.6); color: #fff; }
.rvp-play { border: 1px solid rgba(34, 211, 238, 0.5); background: rgba(34, 211, 238, 0.12); color: #a5f3fc; border-radius: 8px; font-size: 12px; padding: 6px 14px; }
.rvp-layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 12px; align-items: start; }
.rvp-left { border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); padding: 12px; display: flex; flex-direction: column; gap: 8px; min-height: 420px; }
.rvp-shot-title { font-size: 14px; font-weight: 700; }
.rvp-desc { margin: 0; font-size: 12px; color: var(--dim); line-height: 1.7; }
.rvp-anno-head { display: flex; align-items: center; justify-content: space-between; font-size: 12.5px; padding-top: 8px; border-top: 1px solid var(--hair); }
.rvp-comments { display: flex; flex-direction: column; gap: 6px; max-height: 380px; overflow-y: auto; }
.rvp-empty { font-size: 12px; color: var(--dim); text-align: center; padding: 26px 0; }
.rvp-center { border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.rvp-player { aspect-ratio: 16 / 9; }
.rvp-timebar { display: flex; align-items: center; justify-content: space-between; font-size: 12px; }
.rvp-progress { height: 4px; border-radius: 3px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.rvp-progress i { display: block; height: 100%; background: linear-gradient(90deg, #22d3ee, #a855f7); }
.rvp-segments { display: flex; flex-direction: column; gap: 8px; max-height: 260px; overflow-y: auto; }
.rvp-seg {
  display: grid; grid-template-columns: 52px auto 1fr 1fr 32px 32px; align-items: center; gap: 8px;
  border: 1px solid var(--hair); border-radius: 9px; background: var(--surface-2); padding: 8px 10px; color: inherit; text-align: left; font-size: 11.5px;
}
.rvp-seg.is-on { border-color: rgba(168, 85, 247, 0.7); background: rgba(168, 85, 247, 0.1); }
.rvp-seg-code { font-family: var(--mono); color: #e9d5ff; }
.rvp-seg-current { font-size: 10px; padding: 1px 6px; border-radius: 4px; background: rgba(168, 85, 247, 0.3); color: #fff; }
.rvp-seg-time { color: var(--dim); }
.rvp-mark { border: 1px solid var(--hair-strong); background: transparent; color: #cfd6e4; border-radius: 6px; font-size: 11px; height: 24px; }
.rvp-mark:hover { border-color: rgba(34, 211, 238, 0.6); color: #a5f3fc; }
@media (max-width: 1000px) { .rvp-layout { grid-template-columns: 1fr; } }
/* ============ 通知抽屉 ============ */
.notice-drawer { position: fixed; inset: 0; z-index: 180; }
.notice-mask { position: absolute; inset: 0; background: rgba(4, 5, 8, 0.5); }
.notice-panel {
  position: absolute; right: 0; top: 0; bottom: 0; width: min(420px, 92vw);
  background: #101216; border-left: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.55);
  display: flex; flex-direction: column;
  animation: notice-in 0.18s ease-out;
}
@keyframes notice-in { from { transform: translateX(24px); opacity: 0.6; } to { transform: none; opacity: 1; } }
.notice-head { display: flex; align-items: center; gap: 10px; padding: 16px 16px 12px; border-bottom: 1px solid var(--hair); }
.notice-head strong { font-size: 16px; }
.notice-sub { font-size: 11.5px; color: var(--dim); padding: 2px 8px; border-radius: 999px; background: var(--surface-2); }
.notice-close { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; border: none; background: transparent; color: #94a3b8; font-size: 14px; }
.notice-close:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.notice-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; font-size: 12px; border-bottom: 1px solid var(--hair); }
.notice-list { flex: 1; overflow-y: auto; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.notice-item { border: 1px solid var(--hair); border-radius: 10px; background: var(--surface-2); padding: 10px 12px; cursor: pointer; }
.notice-item.is-unread { border-color: rgba(168, 85, 247, 0.45); background: rgba(168, 85, 247, 0.08); }
.notice-title { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.notice-dot { width: 6px; height: 6px; border-radius: 50%; background: #ef4444; }
.notice-body { margin-top: 4px; font-size: 12px; color: var(--dim); line-height: 1.7; }
.notice-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 6px; font-size: 11px; }
.notice-link { color: #c084fc; }
.notice-empty { text-align: center; color: var(--dim); font-size: 12px; padding: 26px 0; }

/* ============ 首页卡片插画层 ============ */
.hc-art { isolation: isolate; }
.hc-art::before {
  content: ""; position: absolute; inset: -10%;
  background:
    radial-gradient(38% 32% at 28% 26%, rgba(255, 255, 255, 0.22), transparent 70%),
    radial-gradient(46% 40% at 74% 68%, rgba(168, 85, 247, 0.35), transparent 72%),
    radial-gradient(30% 26% at 52% 84%, rgba(34, 211, 238, 0.28), transparent 70%);
  filter: blur(2px); opacity: 0.85; z-index: 0;
}
.hc-art::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background-image: repeating-linear-gradient(115deg, rgba(255, 255, 255, 0.06) 0 1px, transparent 1px 46px);
  opacity: 0.5;
}
.hc-art span {
  position: relative; z-index: 2; letter-spacing: 8px; color: rgba(255, 255, 255, 0.32);
  font-size: 15px; writing-mode: horizontal-tb;
}
.home-card:hover .hc-art::before { opacity: 1; transform: scale(1.03); transition: opacity 0.2s, transform 0.2s; }
.home-card:hover .hc-art span { color: rgba(255, 255, 255, 0.45); }

/* ============ 项目卡 hover 信息层 ============ */
.project-card { position: relative; }
.project-hover {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; gap: 6px;
  padding: 16px; background: linear-gradient(180deg, rgba(8, 9, 12, 0.55), rgba(8, 9, 12, 0.88));
  opacity: 0; transition: opacity 0.16s; pointer-events: none;
}
.project-card:hover .project-hover { opacity: 1; }
.project-hover .ph-row { display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: #cfd6e4; }
.project-hover .ph-cta { margin-top: 6px; font-size: 12.5px; font-weight: 600; color: #c084fc; }
/* 图片大图 + 参考图拖拽态 */
.wk-refs.is-drop, .ad-refs.is-drop { outline: 2px dashed rgba(168, 85, 247, 0.7); outline-offset: 4px; border-radius: 12px; }
.lb-modal { position: fixed; inset: 0; z-index: 190; display: grid; place-items: center; }
.lb-box { position: relative; width: min(1000px, 94vw); max-height: 92vh; background: #0d0f14; border: 1px solid rgba(255,255,255,0.12); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; }
.lb-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--hair); }
.lb-view { display: grid; place-items: center; padding: 12px; overflow: auto; }
.lb-view img { max-width: 100%; max-height: 78vh; object-fit: contain; }
.ad-main img, .ad-sub img { cursor: zoom-in; }
/* 助理历史会话 */
.as-sessions-head { display: flex; align-items: center; justify-content: space-between; margin: 14px 0 8px; font-size: 12px; color: var(--dim); }
.as-new { border: 1px solid rgba(168, 85, 247, 0.5); background: rgba(168, 85, 247, 0.12); color: #e9d5ff; border-radius: 7px; font-size: 11px; padding: 4px 8px; }
.as-sessions { display: flex; flex-direction: column; gap: 6px; max-height: 240px; overflow-y: auto; }
.as-session { border: 1px solid var(--hair); border-radius: 9px; background: var(--surface-2); padding: 8px 10px; text-align: left; color: inherit; display: flex; flex-direction: column; gap: 2px; }
.as-session.is-on { border-color: rgba(168, 85, 247, 0.6); background: rgba(168, 85, 247, 0.1); }
.as-session-title { font-size: 12.5px; }
.as-session-meta { font-size: 10.5px; color: var(--dim); }
.as-session-empty { font-size: 11.5px; color: var(--dim); padding: 8px 0; }
/* 团队成员弹窗 */
.modal-dark .order-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.order-row .pill { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--hair-strong); color: var(--dim); }
.team-members .order-row { display: grid; grid-template-columns: 1fr auto auto auto; align-items: center; gap: 8px; }
/* 首屏骨架 */
.skeleton { position: relative; overflow: hidden; background: rgba(255, 255, 255, 0.06); border-radius: 8px; }
.skeleton::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
  animation: skeleton-sweep 1.2s ease-in-out infinite;
}
@keyframes skeleton-sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.skeleton.line { height: 12px; margin: 8px 0; }
.skeleton.line.w60 { width: 60%; }
.skeleton.line.w40 { width: 40%; }
.project-card.is-skeleton { pointer-events: none; }
/* 通知头部未读徽标 */
.notice-unread { font-size: 10.5px; color: #fca5a5; background: rgba(239, 68, 68, 0.14); border: 1px solid rgba(239, 68, 68, 0.35); border-radius: 999px; padding: 1px 8px; }
.notice-unread.is-empty { color: #86efac; background: rgba(34, 197, 94, 0.12); border-color: rgba(34, 197, 94, 0.3); }
a.vip-detail-row { color: inherit; text-decoration: none; }
a.vip-detail-row:hover { color: #c084fc; }
/* 生成记录头部：不再竖排换行 */
.sb-records-head strong { white-space: nowrap; }
.sb-records-head .sb-seg { flex: none; }
.sb-records-head .sb-seg button { white-space: nowrap; }
/* 资产库批量操作 */
.al-bulk { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid rgba(168, 85, 247, 0.4); background: rgba(168, 85, 247, 0.1); border-radius: 10px; }
.al-bulk-count { font-size: 12px; color: #e9d5ff; }
.al-card.is-selected { border-color: var(--brand); box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.35); }
/* 管理后台卡密 */
.ad-cardlist { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.ad-cardrow { display: flex; align-items: center; gap: 12px; font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--hair); border-radius: 8px; background: var(--surface-2); }
.ad-code { font-family: var(--mono); color: #e9d5ff; }
.ad-used { margin-left: auto; color: #fca5a5; font-size: 11px; }
.ad-unused { margin-left: auto; color: #86efac; font-size: 11px; }

/* 消费记录项目筛选 */
.cons-filter { width: 200px; }

/* 项目卡团队徽标 */
.badge-team { left: auto; right: 8px; background: rgba(34, 197, 94, 0.2); border-color: rgba(34, 197, 94, 0.4); color: #bbf7d0; }

.ep-jump { display: flex; align-items: center; gap: 6px; margin: 6px 0 8px; }
.ep-jump-input { width: 84px; height: 30px; }

.ad-sub-add { display: grid; place-items: center; border: 1px dashed var(--hair-strong); background: transparent; color: var(--dim); font-size: 18px; cursor: pointer; }

/* 分镜批量操作 */
.sb-bulkbar { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--hair); border-radius: 9px; background: var(--surface-2); }
.sb-bulkbar .select-dark { width: 130px; }
.shot-thumb.is-selected { outline: 2px solid var(--brand); outline-offset: 1px; }

.al-grid.is-drop { outline: 2px dashed rgba(168, 85, 247, 0.7); outline-offset: 6px; border-radius: 12px; }

/* 首页工作台概览 */
.home-overview { margin: 0 0 18px; padding: 14px 16px; border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); }
.home-overview-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.home-more { font-size: 12px; color: #c084fc; }
.home-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.home-stat { border: 1px solid var(--hair); border-radius: 10px; padding: 10px 12px; background: var(--surface-2); display: flex; flex-direction: column; gap: 2px; }
.home-stat b { font-size: 20px; }
.home-stat span { font-size: 11.5px; color: var(--dim); }
.home-recent { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.home-recent-card { display: flex; gap: 8px; align-items: center; border: 1px solid var(--hair); border-radius: 10px; padding: 8px; background: var(--surface-2); color: inherit; }
.home-recent-card:hover { border-color: rgba(168, 85, 247, 0.5); }
.home-recent-cover { width: 44px; height: 44px; border-radius: 8px; overflow: hidden; display: grid; place-items: center; background: #0c0e12; flex: none; }
.home-recent-cover img { width: 100%; height: 100%; object-fit: cover; }
.home-recent-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.home-recent-body strong { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-recent-body .muted { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 900px) { .home-stats { grid-template-columns: repeat(2, 1fr); } .home-recent { grid-template-columns: 1fr; } }
/* 生成记录批量回收 */
.sb-bulk-mini { display: flex; align-items: center; gap: 6px; }
.sb-bulk-mini .btn { height: 26px; padding: 0 8px; font-size: 11.5px; }

.al-cat.is-dragging { opacity: 0.5; }
.al-cat[draggable="true"] { cursor: grab; }

/* 提示词历史 */
.ad-hist { display: flex; flex-direction: column; gap: 8px; max-height: 380px; overflow: auto; margin: 8px 0; }
.ad-hist-row { border: 1px solid var(--hair); border-radius: 10px; padding: 8px 10px; background: var(--surface-2); display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.ad-hist-meta { display: flex; gap: 10px; font-size: 11.5px; color: var(--dim); }
.ad-hist-text { margin: 0; font-size: 12px; white-space: pre-wrap; max-height: 90px; overflow: auto; }
.set-card[draggable="true"] { cursor: grab; }
.set-card.is-dragging { opacity: 0.45; }

.wk-ref { position: relative; }
.wk-ref.is-dragging { opacity: 0.45; }
.wk-ref-no { position: absolute; left: 4px; top: 4px; font-size: 10px; padding: 0 4px; border-radius: 6px; background: rgba(0,0,0,0.6); color: #e9d5ff; }

.notice-types { display: flex; gap: 4px; padding: 8px 14px 0; flex-wrap: wrap; }
.notice-types .ws-tab { font-size: 11.5px; padding: 2px 8px; }

.wk-pickgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; max-height: 340px; overflow: auto; margin: 8px 0; }
.wk-pick { display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--hair); border-radius: 10px; padding: 6px; background: var(--surface-2); cursor: pointer; }
.wk-pick img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }
.wk-pick span { font-size: 11px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.rvp-seg[draggable="true"] { cursor: grab; }
.rvp-seg.is-dragging { opacity: 0.45; }

.al-hit { background: rgba(250, 204, 21, 0.35); color: #fef9c3; border-radius: 3px; padding: 0 1px; }

/* 首页卡片统一 hover 动效 */
.home-card { transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.home-card:hover { transform: translateY(-3px); border-color: rgba(168, 85, 247, .45); box-shadow: 0 12px 28px rgba(0, 0, 0, .45); }
.home-card:hover .hc-art { transform: scale(1.03); }
.hc-art { transition: transform .25s ease; }
.project-card { transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.project-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, .4); }
.sb-record-model-sel { width: 108px; height: 26px; font-size: 11px; }

/* ============ 亮色皮肤（覆盖主要表面与文本，仍有少量深色装饰块） ============ */
body.theme-light {
  background: #f4f6fb;
  color: #151827;
  --surface: #ffffff;
  --surface-2: #f1f3f9;
  --surface-3: #e6e9f3;
  --hair: rgba(18, 22, 38, 0.10);
  --hair-strong: rgba(18, 22, 38, 0.18);
  --dim: #5c6579;
}
body.theme-light .appbar { background: rgba(255, 255, 255, 0.9); border-bottom-color: rgba(18, 22, 38, 0.1); }
body.theme-light .appbar, body.theme-light .appbar a, body.theme-light .appbar button { color: #151827; }
body.theme-light .rail { background: #ffffff; border-color: rgba(18, 22, 38, 0.1); }
body.theme-light .card-dark,
body.theme-light .panel,
body.theme-light .home-card,
body.theme-light .project-card,
body.theme-light .home-overview,
body.theme-light .home-stat,
body.theme-light .home-recent-card,
body.theme-light .notice-panel,
body.theme-light .modal-dark .box,
body.theme-light .sb-page,
body.theme-light .sb-center,
body.theme-light .sb-right,
body.theme-light .episode-panel,
body.theme-light .ad-left,
body.theme-light .ad-center,
body.theme-light .as-card,
body.theme-light .set-card,
body.theme-light .wk-main,
body.theme-light .wl-card {
  background: #ffffff;
  color: #151827;
  border-color: rgba(18, 22, 38, 0.1);
}
body.theme-light .input-dark,
body.theme-light .textarea-dark,
body.theme-light .select-dark,
body.theme-light input,
body.theme-light textarea,
body.theme-light select {
  background: #f7f8fc;
  color: #151827;
  border-color: rgba(18, 22, 38, 0.16);
}
body.theme-light .muted,
body.theme-light .sb-hint,
body.theme-light .wk-hint { color: #5c6579; }
body.theme-light .btn-line { color: #2a2f42; border-color: rgba(18, 22, 38, 0.18); }
body.theme-light .ep-chip { background: #eef1f8; color: #2a2f42; }
body.theme-light .ep-chip.is-active { background: #a855f7; color: #fff; }
body.theme-light .sb-tool { background: #eef1f8; color: #2a2f42; }
body.theme-light .wk-ref, body.theme-light .wk-gen, body.theme-light .sb-record { background: #f1f3f9; }
body.theme-light .notice-mask, body.theme-light .modal-dark .mask { background: rgba(15, 20, 38, 0.35); }
/* ============ 工作台顶栏（对齐真实站结构） ============ */
body.workbench .appbar, body.workbench .rail { display: none; }
body.workbench .wb-page { padding: 16px 22px 28px; max-width: none; }
.ws-exit {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 1px; padding: 5px 14px; border-radius: 10px;
  border: 1px solid rgba(34, 197, 94, 0.55); color: #86efac; line-height: 1.05;
}
.ws-exit-k { font-size: 10px; color: rgba(134, 239, 172, 0.8); }
.ws-exit-v { font-size: 12.5px; font-weight: 600; }
.ws-exit:hover { background: rgba(34, 197, 94, 0.12); }
.ws-divider { width: 1px; height: 26px; background: var(--hair-strong); }
.ws-current { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ws-current-k { font-size: 10.5px; color: var(--dim); }
.ws-edit { border: none; background: transparent; color: var(--dim); font-size: 12px; padding: 2px 4px; border-radius: 6px; }
.ws-edit:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.ws-right { display: flex; align-items: center; gap: 10px; margin-left: auto; position: relative; }
.ws-balance { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.1; }
.ws-balance i { font-style: normal; font-size: 10px; color: var(--dim); }
.ws-balance b { font-size: 14px; color: #facc15; font-family: var(--mono); }
.ws-style { padding: 5px 10px; border-radius: 8px; border: 1px solid rgba(34, 211, 238, 0.35); color: #a5f3fc; font-size: 11.5px; }
.ws-avatar {
  width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
  background: linear-gradient(135deg, #a855f7, #6366f1); color: #fff;
}
.ws-more { width: 26px; height: 26px; border-radius: 8px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); }
.ws-menu {
  position: absolute; right: 0; top: 38px; z-index: 40;
  display: flex; flex-direction: column; min-width: 150px;
  border: 1px solid var(--hair-strong); border-radius: 10px;
  background: var(--surface-2); padding: 4px; box-shadow: 0 12px 28px rgba(0, 0, 0, 0.5);
}
.ws-menu-item { text-align: left; padding: 8px 10px; border-radius: 7px; border: none; background: transparent; color: inherit; font-size: 12.5px; }
.ws-menu-item:hover { background: rgba(168, 85, 247, 0.18); }
.ws-step.is-done { color: #86efac; border-color: rgba(34, 197, 94, 0.55); background: rgba(34, 197, 94, 0.12); }
.ws-step b { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, 0.12); font-size: 10px; }
.ws-step.is-active b { background: rgba(255, 255, 255, 0.25); }
/* ============ 剧本创建：剧集网格对齐真实站 ============ */
.ep-body { display: flex; gap: 6px; align-items: flex-start; padding: 0 10px 10px 0; }
.ep-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; padding: 0; flex: 1; }
.ep-chip { aspect-ratio: 1; padding: 0; font-size: 10px; border-radius: 5px; position: relative; min-height: 0; }
.ep-chip .ep-dot { position: absolute; right: 2px; bottom: 2px; width: 4px; height: 4px; border-radius: 50%; background: #22c55e; }
.ep-chip.is-active { background: linear-gradient(135deg, #7c3aed, #c026d3); }
.ep-chip.is-active .ep-dot { background: #f97316; }
.ep-pager { width: 40px; flex: none; padding: 0 0 8px; gap: 6px; }
.ep-page { font-size: 9.5px; padding: 4px 2px; border-radius: 8px; flex-direction: column; gap: 0; line-height: 1.1; }
.ep-page .ep-page-dash { display: none; }
.ep-page.is-active { background: rgba(124, 58, 237, 0.35); border-color: rgba(168, 85, 247, 0.7); }
.ws-next { background: linear-gradient(180deg, #2f6fed, #2563eb); border: 1px solid rgba(37, 99, 235, 0.9); color: #fff; }
.ws-next:hover { background: #1d4ed8; }
.ep-jump { margin: 4px 0 8px; }
.ep-jump-input { height: 26px; font-size: 11px; width: 70px; }
.ep-jump .btn { height: 26px; font-size: 11px; padding: 0 8px; }
/* 剧集网格可读性修正 */
.script-layout { grid-template-columns: 320px minmax(0, 1fr); }
.ep-grid { grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 4px; }
.ep-chip { aspect-ratio: auto; min-height: 22px; font-size: 9.5px; line-height: 1; display: grid; place-items: center; }
.ep-pager { width: 46px; }
.ep-page { font-size: 8.5px; padding: 4px 0; }
.ep-page .ep-page-dash { display: inline; }
.ep-page span { display: block; }
/* 对齐参考图：12 列 + 宽面板 + 添加剧集渐变按钮 */
.script-layout { grid-template-columns: 340px minmax(0, 1fr); }
.ep-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; }
.ep-chip { min-height: 21px; font-size: 9px; }
.episode-add {
  width: calc(100% - 24px); margin: 0 12px 10px; height: 36px;
  border: 1px solid rgba(34, 197, 94, 0.55); border-radius: 10px;
  background: linear-gradient(180deg, #178a4b, #137a41);
  color: #eafff2; font-size: 13px; font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.episode-add:hover { background: linear-gradient(180deg, #1a9a55, #158047); }
/* ============ 作品设定：宽幅设定卡（对齐参考图） ============ */
.set-grid { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-start; }
.set-new {
  width: 246px; height: 116px; flex: none;
  border: 1px dashed rgba(148, 163, 184, 0.45); border-radius: 12px;
  background: rgba(255, 255, 255, 0.02); color: var(--dim);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
}
.set-new .plus { font-size: 26px; line-height: 1; }
.set-card {
  width: 246px; height: 116px; flex: none; position: relative;
  border-radius: 12px; overflow: hidden; padding: 0;
  border: 1px solid var(--hair-strong); background: var(--surface-2);
}
.set-card .set-cover { position: absolute; inset: 0; }
.set-card .set-cover img { width: 100%; height: 100%; object-fit: cover; }
.set-card .set-name {
  position: absolute; left: 8px; bottom: 6px; z-index: 2;
  font-size: 13px; font-weight: 700; color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}
.set-card .set-badges {
  position: absolute; right: 6px; bottom: 6px; z-index: 2;
  display: flex; gap: 4px;
}
.set-card .set-badge {
  font-size: 10px; padding: 1px 5px; border-radius: 4px;
  background: rgba(15, 20, 34, 0.75); border: 1px solid rgba(255, 255, 255, 0.16); color: #e5e7eb;
}
.set-card::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 45%, rgba(0, 0, 0, 0.55) 100%);
}
.set-card .set-name, .set-card .set-badges { z-index: 3; }
.ws-ep { height: 30px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--hair-strong); color: #e5e7eb; font-size: 12px; padding: 0 8px; }
.ws-ep-count { font-size: 11px; color: var(--dim); }
.ws-asset-pill { height: 30px; padding: 0 12px; border-radius: 9px; border: 1px solid rgba(168, 85, 247, 0.55); background: linear-gradient(180deg, #7c3aed, #6d28d9); color: #fff; font-size: 12px; }
/* ============ 分镜视图：对齐参考图 ============ */
body.workbench .announce { display: none; }
.sb-stats {
  display: flex; align-items: center; gap: 10px; flex-wrap: nowrap;
  padding: 8px 12px; border: 1px solid var(--hair); border-radius: 12px;
  background: var(--surface); overflow-x: auto;
}
.sb-stats .sb-count-g { display: inline-flex; gap: 4px; align-items: baseline; font-size: 11px; color: var(--dim); white-space: nowrap; }
.sb-stats .sb-count-g b { color: #e5e7eb; font-weight: 600; }
.sb-tool { border-radius: 999px; padding: 3px 10px; font-size: 11px; }
.sb-tool:nth-of-type(1) { }
.sb-tool.is-on { background: rgba(34, 197, 94, 0.18); border-color: rgba(34, 197, 94, 0.6); color: #bbf7d0; }

/* 左侧：场景/角色/道具 缩略图横排 */
.sb-left { display: flex; flex-direction: column; gap: 10px; }
.sb-col { padding: 10px; border-radius: 12px; }
.sb-col-title { font-size: 11.5px; color: var(--dim); margin-bottom: 6px; }
.sb-thumbs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; }
.sb-thumb { width: 46px; height: 46px; flex: none; border-radius: 8px; }
.sb-thumb .name { font-size: 9px; bottom: 1px; }
.sb-thumb-add { width: 46px; height: 46px; }

/* 视频提示词卡：左侧紫边 + 字数条 */
.sb-prompt {
  border: 1px solid rgba(168, 85, 247, 0.55);
  border-left: 3px solid #a855f7;
  border-radius: 10px; background: rgba(88, 28, 135, 0.12);
  padding: 8px 10px;
}
.sb-prompt-head { font-size: 12px; }
.sb-prompt textarea { background: rgba(10, 11, 14, 0.5); border-color: rgba(168, 85, 247, 0.25); font-size: 11.5px; }
.sb-prompt-foot { font-size: 11px; }

/* 右侧记录卡：顶部徽标行 */
.sb-record { position: relative; border-radius: 10px; overflow: hidden; }
.sb-record-meta { position: absolute; top: 6px; left: 6px; right: 6px; padding: 0; }
.sb-record-meta .set-badge { background: rgba(15, 20, 34, 0.85); }
.sb-record img { border-radius: 10px 10px 0 0; }

/* 底部镜头条：编号 + 时长标签 */
.shot-thumb .cap { padding: 3px 6px; font-size: 10px; color: #cbd5e1; }
.shot-thumb { border-radius: 8px; }
.shot-thumb.is-active { box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.55); }/* 分镜时间轴与播放器 */
.sb-timeline { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--hair); border-radius: 10px; background: var(--surface); font-size: 11.5px; }
.sb-play { width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(34, 197, 94, 0.5); background: rgba(34, 197, 94, 0.12); color: #86efac; display: grid; place-items: center; font-size: 12px; }
.sb-play-sm { width: 26px; height: 26px; border-color: var(--hair-strong); background: transparent; color: var(--dim); }
.sb-rate { padding: 2px 8px; border-radius: 6px; border: 1px solid var(--hair-strong); color: #cbd5e1; }
.sb-manage { border-color: rgba(250, 204, 21, 0.55); color: #fde68a; }
.sb-layout { grid-template-columns: 300px minmax(0, 1fr) 290px; }/* 播放器空态 */
.sb-player, .rvp-player { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; background: #05060a; }
.player-mark { font-size: 34px; opacity: 0.5; }
.player-hint { font-size: 12px; color: #6b7280; }/* 分镜中心工具条 */
.sb-centerbar { display: flex; align-items: center; gap: 8px; }
.sb-pill { padding: 4px 10px; border-radius: 999px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 11px; }
.sb-pill:hover { color: #fff; border-color: rgba(168, 85, 247, 0.5); }
.sb-pill-purple { border-color: rgba(168, 85, 247, 0.55); color: #d8b4fe; }
.sb-pill-yellow { border-color: rgba(250, 204, 21, 0.55); color: #fde68a; }
.sb-pill.is-on { background: rgba(250, 204, 21, 0.15); }
.sb-durseg { display: flex; gap: 4px; }
.sb-durseg button { padding: 3px 10px; border-radius: 6px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 11px; }
.sb-durseg button.is-on { background: rgba(34, 197, 94, 0.2); border-color: rgba(34, 197, 94, 0.6); color: #bbf7d0; }/* 右栏头部紧凑化 + 左栏占位块 */
.sb-records-head { flex-wrap: nowrap; gap: 4px; align-items: center; }
.sb-records-head strong { font-size: 12px; }
.sb-records-head .muted { display: none; }
.sb-records-head .sb-pill { padding: 2px 6px; font-size: 10px; white-space: nowrap; }
.sb-records-head .sb-seg button { padding: 2px 6px; font-size: 10px; }
.sb-thumb-add { font-size: 14px; }/* 审核中心：三列大卡 + 分页条 */
.rv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.rv-card { min-height: 176px; padding: 14px 16px; border-radius: 14px; }
.rv-card-head strong { font-size: 15px; }
.rv-bar { height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.rv-bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #7c3aed, #c026d3); }
.rv-page-btn { min-width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 12px; }
.rv-page-btn.is-active { background: linear-gradient(135deg, #a855f7, #c026d3); color: #fff; border-color: transparent; }
.rv-pager { display: flex; align-items: center; gap: 8px; justify-content: center; padding: 10px 14px; margin-top: 14px; border: 1px solid var(--hair); border-radius: 12px; background: var(--surface); }
.rv-pager-label { font-size: 11.5px; color: var(--dim); }
.rv-jump { width: 56px; height: 28px; text-align: center; }
.rv-size { width: 74px; height: 28px; }/* 拉片播放页：播放器在左、批注栏在右（对齐参考图） */
.rvp-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; align-items: start; }
.rvp-center { order: 1; }
.rvp-left { order: 2; border-left: 1px solid var(--hair); padding-left: 16px; }
.rvp-player { background: #000; border-radius: 0; min-height: 520px; }
.rvp-shot-title { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.rvp-desc { font-size: 12px; color: var(--dim); margin: 0 0 10px; }
.rvp-anno-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair); font-size: 12px; }
.rvp-comments { min-height: 240px; }.rvp-play-main { background: rgba(71, 85, 105, 0.9); color: #fff; border: 1px solid rgba(148, 163, 184, 0.35); padding: 6px 14px; border-radius: 6px; }
.rvp-play-main:hover { background: rgba(100, 116, 139, 0.9); }/* 拉片片段行缩略图 */
.rvp-seg { display: flex; align-items: center; gap: 8px; }
.rvp-seg-thumb { width: 64px; height: 40px; border-radius: 6px; overflow: hidden; background: #0b0d12; flex: none; display: block; }
.rvp-seg-thumb img { width: 100%; height: 100%; object-fit: cover; }
/* 本集资产管理：添加按钮配色 */
.ea-add-blue { background: linear-gradient(180deg, #3b82f6, #2563eb); color: #fff; border: 1px solid rgba(37, 99, 235, 0.9); }
.ea-add-blue:hover { background: #1d4ed8; }
.ea-add-orange { background: linear-gradient(180deg, #d97706, #b45309); color: #fff; border: 1px solid rgba(180, 83, 9, 0.9); }
.ea-add-orange:hover { background: #92400e; }
.ea-lib-pic { aspect-ratio: 4 / 5; background: #0b0d12; display: grid; place-items: center; }
.ea-lib-name { display: block; padding: 6px 4px; font-size: 12px; text-align: center; }

/* 工坊三栏布局（对齐参考图：左资产库 / 中工具区 / 右画廊） */
.wk-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr) 300px; gap: 16px; align-items: start; }
.ws-tools { justify-content: center; }
.wk-gallery-side { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 10px 12px; max-height: calc(100dvh - 150px); overflow: auto; }
.wk-gallery-side .wk-gallery-head { flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.wk-gallery-side .wk-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.wk-gallery-side .wk-date { width: 108px; }
@media (max-width: 1400px) { .wk-layout { grid-template-columns: 240px minmax(0, 1fr) 260px; } }

/* 工坊细节：风格横滑、右栏紧凑 */
.wk-styles { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; }
.wk-gallery-side #gallery-model { display: none; }
.wk-gallery-side .wk-gallery-head .muted { font-size: 11px; }
.wk-gallery-side .wk-date { width: 100px; height: 28px; }
.wk-gallery-side .btn-sm { height: 28px; }

.wk-gallery-side .wk-gallery-head { display: flex; flex-direction: column; gap: 8px; align-items: stretch; }
.wk-gallery-title { display: flex; align-items: baseline; gap: 8px; }
.wk-date-row { display: flex; align-items: center; gap: 6px; }
.wk-gallery-side .wk-date { flex: 1; width: auto; }

.wk-gallery-side .wk-date { flex: 1 1 0; min-width: 0; width: auto; }
.wk-gallery-side .wk-date-row .muted { flex: none; font-size: 11px; }

/* 会员套餐卡：白色 CTA + 积分胶囊 + 权益行 */
.vip-buy { background: #ffffff; color: #111827; border: 1px solid rgba(255,255,255,0.6); font-weight: 700; border-radius: 999px; height: 40px; }
.vip-buy:hover { background: #f3f4f6; }
.vip-plan-points { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 12px; border-radius: 8px; background: rgba(255,255,255,0.04); border: 1px solid var(--hair); margin-bottom: 10px; }
.vip-plan-points b { font-size: 18px; color: #fff; }
.vip-plan-points span { font-size: 12px; color: var(--dim); }
.vip-plan-perks { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--hair); }
.vip-plan-perks li { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: #cbd5e1; }
.vip-perk-badge { font-style: normal; font-size: 11px; padding: 1px 6px; border-radius: 4px; background: rgba(168,85,247,0.18); color: #d8b4fe; }

/* 首页精选作品 + 公告弹窗 */
.home-featured { padding: 26px 0 40px; }
.home-featured-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; }
.home-featured-head h2 { font-size: 26px; font-weight: 800; }
.home-posters { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; }
.home-poster { position: relative; display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 3 / 4; border: 1px solid var(--hair); }
.home-poster-art { position: absolute; inset: 0; display: grid; place-items: center; font-size: 15px; font-weight: 800; color: rgba(255,255,255,0.85); text-align: center; padding: 10px; }
.home-poster-art.art-0 { background: linear-gradient(160deg, #1f2937, #7c3aed); }
.home-poster-art.art-1 { background: linear-gradient(160deg, #0f766e, #134e4a); }
.home-poster-art.art-2 { background: linear-gradient(160deg, #7f1d1d, #b91c1c); }
.home-poster-art.art-3 { background: linear-gradient(160deg, #1e3a8a, #0ea5e9); }
.home-poster-art.art-4 { background: linear-gradient(160deg, #87352b, #d97706); }
.home-poster-art.art-5 { background: linear-gradient(160deg, #312e81, #6366f1); }
.home-poster-art.art-6 { background: linear-gradient(160deg, #14532d, #22c55e); }
.home-poster-tag { position: absolute; left: 8px; top: 8px; font-size: 10px; padding: 2px 6px; border-radius: 4px; background: rgba(220, 38, 38, 0.9); color: #fff; }
.home-poster-name { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px; font-size: 13px; background: linear-gradient(180deg, transparent, rgba(0,0,0,0.75)); }
@media (max-width: 1100px) { .home-posters { grid-template-columns: repeat(3, 1fr); } }

.ann-box { width: min(900px, 92vw); }
.ann-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 16px 20px 10px; }
.ann-kicker { font-size: 12px; color: var(--dim); }
.ann-head h3 { margin: 4px 0 0; font-size: 18px; }
.ann-close { border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); width: 30px; height: 30px; border-radius: 50%; }
.ann-main { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 16px; padding: 0 20px 20px; min-height: 320px; }
.ann-list { display: flex; flex-direction: column; gap: 8px; border-right: 1px solid var(--hair); padding-right: 14px; }
.ann-item { text-align: left; border: 1px solid transparent; background: transparent; color: var(--dim); padding: 8px 10px; border-radius: 8px; display: flex; flex-direction: column; gap: 2px; }
.ann-item.is-on { background: var(--surface-2); border-color: var(--hair-strong); color: #fff; }
.ann-item-time { font-size: 11px; }
.ann-body { font-size: 13px; line-height: 1.8; color: #d1d5db; white-space: pre-wrap; }

/* 拉片片段滑杆 */
.rvp-seg-wrap { border-bottom: 1px solid var(--hair); padding-bottom: 6px; }
.rvp-seg-wrap .rvp-seg { border-bottom: none; }
.rvp-seg-sliders { display: flex; align-items: center; gap: 8px; padding: 4px 10px 2px; }
.rvp-slider { flex: 1; min-width: 0; accent-color: #3b82f6; height: 4px; }
.rvp-slider-label { font-size: 10px; color: var(--dim); flex: none; }

/* 首页顶部拼贴背景 */
.hero { position: relative; overflow: hidden; }
.hero-collage { position: absolute; inset: -40px -40px auto -40px; height: 420px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; opacity: 0.22; filter: blur(3px) saturate(0.8); pointer-events: none; z-index: 0; }
.hero-collage span { border-radius: 16px; display: block; }
.hc-0 { background: linear-gradient(160deg, #334155, #7c3aed); }
.hc-1 { background: linear-gradient(160deg, #1f2937, #0f766e); }
.hc-2 { background: linear-gradient(160deg, #312e81, #0ea5e9); }
.hc-3 { background: linear-gradient(160deg, #4c1d95, #db2777); }
.hc-4 { background: linear-gradient(160deg, #134e4a, #65a30d); }
.hero > *:not(.hero-collage) { position: relative; z-index: 1; }
/* 会员金色钻石 */
.vip-gem { color: #fbbf24; font-size: 18px; margin-right: 6px; }
.rv-pager-dots { color: var(--dim); padding: 0 2px; }

/* 剧集列表：正方形编号 + 间隔（对齐参考图） */
.ep-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 8px; }
.ep-chip {
  aspect-ratio: 1 / 1; min-height: 0; padding: 0;
  border-radius: 7px; font-size: 11px;
  display: grid; place-items: center;
}
.ep-chip .ep-dot { right: 3px; bottom: 3px; width: 5px; height: 5px; }
.ep-body { gap: 10px; }
.ep-pager { width: 44px; gap: 8px; }
@media (min-width: 1900px) { .ep-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 9px; } }

/* 剧本页：内容输入 / 剧本创作 两态与真实站对齐 */
.ep-source { min-height: 420px; font-size: 13px; line-height: 1.9; }
.ep-script-read {
  width: 100%; min-height: 560px; resize: vertical;
  background: transparent; border: none; outline: none;
  color: #e5e7eb; font-size: 13px; line-height: 1.9;
  font-family: inherit; padding: 18px 20px;
}
.ep-script-read:focus { outline: none; }
.ws-step { cursor: pointer; }
.ws-step:not(.is-active):not(.is-done) { opacity: 0.75; }

/* 顶部余额充值 + 风格点 + 添加剧集青色渐变 */
.ws-recharge { height: 26px; padding: 0 10px; border-radius: 6px; border: 1px solid rgba(34,197,94,.7); background: #16a34a; color: #fff; font-size: 11px; font-weight: 700; }
.ws-recharge:hover { background: #15803d; }
.ws-style::before { content: '●'; color: #22d3ee; margin-right: 5px; font-size: 8px; vertical-align: middle; }
.episode-add { background: linear-gradient(180deg, #14b8a6, #0d9488); border-color: rgba(20,184,166,.7); }
.episode-add:hover { background: linear-gradient(180deg, #0d9488, #0f766e); }

/* 分镜入口弹窗 */
.sb-setup-box { width: min(560px, 92vw); background: var(--surface); border: 1px solid var(--hair-strong); border-radius: 16px; padding: 18px 20px; display: flex; flex-direction: column; gap: 10px; }
.sb-setup-head h3 { margin: 0 0 4px; font-size: 18px; }
.sb-setup-head p { margin: 0; font-size: 12px; color: var(--dim); }
.sb-setup-label { font-size: 11.5px; color: var(--dim); margin-top: 6px; }
.sb-setup-durations { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sb-setup-card { text-align: left; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--hair-strong); background: transparent; color: #e5e7eb; display: flex; flex-direction: column; gap: 4px; }
.sb-setup-card b { font-size: 13px; }
.sb-setup-card span { font-size: 11px; color: var(--dim); }
.sb-setup-card.is-on { border-color: rgba(16, 185, 129, 0.8); box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.4) inset; background: rgba(16, 185, 129, 0.08); }
.sb-setup-row { display: flex; gap: 8px; }
.sb-setup-yes { flex: 1; padding: 8px; border-radius: 8px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); }
.sb-setup-yes.is-on { border-color: rgba(16, 185, 129, 0.75); color: #a7f3d0; background: rgba(16, 185, 129, 0.12); }
.sb-setup-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }

/* 分镜分析进度遮罩 */
.sb-analyze { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.72); backdrop-filter: blur(3px); display: grid; place-items: center; }
.sb-analyze-box { width: min(460px, 90vw); border-radius: 16px; border: 1px solid rgba(16,185,129,.35); background: linear-gradient(160deg, #0b1220, #0f2a24); padding: 22px 24px; text-align: center; display: flex; flex-direction: column; gap: 8px; }
.sb-analyze-stage { font-size: 11px; color: #6ee7b7; }
.sb-analyze-title { font-size: 16px; font-weight: 700; }
.sb-analyze-desc { font-size: 12px; color: var(--dim); }
.sb-analyze-timer { font-size: 28px; font-weight: 800; font-family: var(--mono); color: #a7f3d0; }

/* 项目画廊弹窗 */
.gal-box { width: min(1080px, 94vw); max-height: 86vh; display: flex; flex-direction: column; gap: 10px; background: var(--surface); border: 1px solid var(--hair-strong); border-radius: 16px; padding: 16px 18px; }
.gal-head { display: flex; align-items: baseline; gap: 10px; }
.gal-head h3 { margin: 0; font-size: 17px; }
.gal-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.gal-grid { flex: 1; min-height: 240px; overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.gal-item { position: relative; border-radius: 10px; overflow: hidden; border: 1px solid var(--hair); aspect-ratio: 16/10; background: #0b0d12; }
.gal-item img { width: 100%; height: 100%; object-fit: cover; }
.gal-tag { position: absolute; left: 6px; top: 6px; font-size: 10px; padding: 1px 6px; border-radius: 4px; background: rgba(0,0,0,.65); color: #e5e7eb; }
.gal-model { position: absolute; left: 0; right: 0; bottom: 0; padding: 4px 6px; font-size: 10px; color: #cbd5e1; background: linear-gradient(180deg, transparent, rgba(0,0,0,.75)); }

/* 右栏记录头：允许换行，紧凑不挤压 */
.sb-records-head { flex-wrap: wrap; row-gap: 4px; }
.sb-records-head strong { margin-right: 2px; }
.sb-records-head .sb-seg { flex-wrap: wrap; }
.sb-records-head .sb-pill { padding: 1px 6px; }
@media (max-width: 1500px) {
  .sb-records-head .sb-seg button { padding: 1px 5px; }
}

/* 分镜表导入表单 */
.sbi-box { max-height: 88vh; overflow: auto; }
.sbi-cols { display: grid; grid-template-columns: 1.3fr 90px 70px 1.7fr 1.7fr 100px 28px; gap: 8px; font-size: 11px; color: var(--dim); padding: 0 2px; }
.sbi-rows { display: flex; flex-direction: column; gap: 8px; }
.sbi-row { display: grid; grid-template-columns: 1.3fr 90px 70px 1.7fr 1.7fr 100px 28px; gap: 8px; align-items: center; }
.sbi-row input, .sbi-row select { height: 32px; font-size: 12px; min-width: 0; }
.sbi-del { width: 26px; height: 26px; border-radius: 6px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); }
.sbi-del:hover { color: #f87171; border-color: rgba(248,113,113,.6); }
.sbi-actions { display: flex; gap: 8px; }
@media (max-width: 1200px) {
  .sbi-cols, .sbi-row { grid-template-columns: 1.3fr 80px 60px 1.4fr 1.4fr 90px 26px; }
}

/* 保证弹窗卡片始终高于自身遮罩，避免多弹窗叠加时卡片被盖住 */
.modal-dark .mask { z-index: 0; }
.modal-dark .box, .modal-dark .gal-box, .modal-dark .sb-setup-box, .modal-dark .an-box, .modal-dark .ea-box { position: relative; z-index: 2; }
.modal-dark .sb-analyze { z-index: 1; }

/* 作品设定卡片：对齐真实站的 4:3 大卡 */
.set-card, .set-new {
  width: clamp(240px, 17vw, 320px);
  height: auto;
  aspect-ratio: 4 / 3;
}
.set-card .set-cover img { object-fit: cover; }
.set-card .set-name { font-size: 14px; bottom: 8px; }
.set-card .set-badge { font-size: 11px; }
.set-new .plus { font-size: 34px; }

.ad-crumb { display: flex; gap: 8px; align-items: baseline; padding: 2px 0 10px; font-size: 12px; }
.ad-refs { display: grid; grid-template-columns: repeat(3, 120px); gap: 10px; margin: 6px 0 14px; }
.ad-ref { position: relative; width: 120px; aspect-ratio: 4/3; border-radius: 10px; overflow: hidden; border: 1px solid var(--hair); background: #0b0d12; }
.ad-ref img { width: 100%; height: 100%; object-fit: cover; }
.ad-ref-add { display: flex; flex-direction: column; gap: 4px; align-items: center; justify-content: center; border-style: dashed; color: var(--dim); }
.ad-ref-del { position: absolute; right: 4px; top: 4px; width: 20px; height: 20px; border-radius: 50%; border: none; background: rgba(0,0,0,.6); color: #fff; font-size: 11px; }

/* 详情页生成设置 */
.ad-genset { margin-top: 8px; display: flex; flex-direction: column; gap: 10px; }
.ad-genset-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ad-genset-row select { height: 32px; }
.ad-genset .wk-qty { display: flex; align-items: center; gap: 6px; }

/* 子形象/多视角 上传格 */
.ad-subs { display: flex; flex-wrap: wrap; gap: 10px; }
.ad-sub { width: 120px; aspect-ratio: 4/3; border-radius: 10px; overflow: hidden; border: 1px solid var(--hair); background: #0b0d12; display: grid; place-items: center; }
.ad-sub img { width: 100%; height: 100%; object-fit: cover; }
.ad-sub.is-empty { color: var(--dim); font-size: 12px; border-style: dashed; }
.ad-sub-add { border-style: dashed; color: var(--dim); gap: 4px; display: flex; flex-direction: column; align-items: center; justify-content: center; }

/* 详情页右栏历史记录缩略图约束 */
.ad-right .ad-gen img { width: 100%; height: 120px; object-fit: cover; border-radius: 8px; }
.ad-right .ad-gens { gap: 8px; }

.ad-gen.is-new { border: 1px solid rgba(34, 197, 94, .7); box-shadow: 0 0 0 2px rgba(34, 197, 94, .18); }

.ad-style-wrap { display: flex; flex-direction: column; gap: 8px; }

.rv-shots-list { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 0 2px; }
.rv-shot-chip { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--hair-strong); color: var(--dim); }

.rv-shot-chip { cursor: pointer; background: transparent; }
.rv-shot-chip:hover { border-color: rgba(168, 85, 247, .6); color: #e9d5ff; }

.rvp-dl { display: inline-flex; align-items: center; gap: 4px; padding: 5px 12px; border-radius: 6px; border: 1px solid var(--hair-strong); color: #cbd5e1; font-size: 12px; }
.rvp-dl:hover { background: rgba(255,255,255,.06); color: #fff; }

.rvp-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; color: #9ca3af; }
.rvp-empty strong { font-size: 15px; color: #d1d5db; font-weight: 600; }

.rv-act { font-size: 11px; padding: 2px 8px; border-radius: 6px; border: 1px solid var(--hair-strong); background: transparent; }
.rv-act.is-ok { color: #86efac; border-color: rgba(34,197,94,.6); }
.rv-act.is-no { color: #fca5a5; border-color: rgba(248,113,113,.55); }
.rv-act:hover { background: rgba(255,255,255,.06); }

.comment-img { width: 100%; max-height: 160px; object-fit: contain; border-radius: 8px; margin-top: 6px; border: 1px solid var(--hair); }

/* 助理角色/技能选择 */
.as-role-chip { font-size: 11px; padding: 3px 8px; border-radius: 999px; border: 1px solid rgba(168,85,247,.5); color: #e9d5ff; }
.as-role-box { width: min(760px, 94vw); max-height: 84vh; display: flex; flex-direction: column; gap: 10px; }
.as-role-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.as-role-tab { font-size: 11px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); }
.as-role-tab.is-on { border-color: rgba(168,85,247,.6); color: #e9d5ff; background: rgba(168,85,247,.12); }
.as-role-list { overflow-y: auto; display: flex; flex-direction: column; gap: 6px; }
.as-role-item { text-align: left; display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--hair); background: transparent; color: #e5e7eb; }
.as-role-item:hover { border-color: rgba(168,85,247,.5); background: rgba(168,85,247,.08); }
.as-role-item.is-on { border-color: rgba(168,85,247,.7); }
.as-role-prompt { font-size: 11px; color: #9ca3af; }

/* 管理后台 · AI 接入 */
.ad-ai-rows { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.ad-ai-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--hair); border-radius: 9px; font-size: 12.5px; flex-wrap: wrap; }
.ad-ai-type { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: rgba(168,85,247,.16); color: #e9d5ff; }
.ad-ai-stage-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }
.ad-ai-stage { font-size: 11.5px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); }
.ad-ai-stage.is-on { border-color: rgba(168,85,247,.65); background: rgba(168,85,247,.14); color: #e9d5ff; }
.ad-ai-form { display: flex; flex-direction: column; }
.ad-ai-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--dim); }
.ad-ai-modal { width: min(560px, 94vw); }

.ad-ai-default { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: rgba(34,197,94,.16); color: #86efac; border: 1px solid rgba(34,197,94,.4); }

/* 团队管理台 */
.tm-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.tm-head, .tm-row { display: grid; grid-template-columns: minmax(220px, 1.6fr) repeat(6, 76px) 130px auto; gap: 8px; align-items: center; padding: 8px 6px; }
.tm-head { color: var(--dim); font-size: 11.5px; border-bottom: 1px solid var(--hair); }
.tm-row { border-bottom: 1px solid var(--hair); font-size: 12.5px; }
.tm-who { display: flex; flex-direction: column; gap: 2px; }
.tm-cell { display: flex; flex-direction: column; align-items: flex-start; }
.tm-cell b { font-size: 14px; }
.tm-cell span { font-size: 11px; color: var(--dim); }
.tm-when { font-size: 11.5px; }
.tm-role { font-size: 10.5px; padding: 1px 6px; border-radius: 999px; width: fit-content; }
.tm-role.is-owner { background: rgba(245,158,11,.18); color: #fcd34d; }
.tm-role.is-admin { background: rgba(168,85,247,.18); color: #e9d5ff; }
.tm-role.is-member { background: rgba(148,163,184,.16); color: #cbd5e1; }
.tm-modal { width: min(720px, 94vw); }
.tm-projects { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow: auto; }
.tm-project { display: flex; flex-direction: column; gap: 3px; padding: 10px; border: 1px solid var(--hair); border-radius: 10px; }

/* 独立运营后台 */
.ops-body { background: #08090d; }
.ops-bar { display: flex; align-items: center; gap: 16px; padding: 14px 22px; border-bottom: 1px solid var(--hair); background: rgba(12,14,20,.9); position: sticky; top: 0; z-index: 20; }
.ops-brand { display: flex; align-items: center; gap: 12px; }
.ops-logo { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: linear-gradient(135deg,#7c3aed,#d946ef); color: #fff; }
.ops-brand strong { display: block; font-size: 15px; }
.ops-brand .muted { font-size: 11.5px; }
.ops-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.ops-actions .input-dark { width: 240px; }
.ops-toolbar { display: flex; align-items: center; gap: 10px; padding: 12px 22px; border-bottom: 1px solid var(--hair); }
.ops-tabs { display: flex; gap: 4px; background: rgba(255,255,255,.04); padding: 3px; border-radius: 9px; }
.ops-tab { border: none; background: transparent; color: var(--dim); font-size: 12.5px; padding: 6px 14px; border-radius: 7px; cursor: pointer; }
.ops-tab.is-on { background: rgba(168,85,247,.22); color: #f5e9ff; }
.ops-periods { display: flex; gap: 2px; }
.ops-periods button { border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 11.5px; padding: 3px 9px; border-radius: 6px; cursor: pointer; }
.ops-periods button.is-on { border-color: rgba(168,85,247,.6); color: #e9d5ff; }
.ops-main { padding: 18px 22px 60px; max-width: 1400px; margin: 0 auto; }
.ops-cards { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.ops-two { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; margin-top: 12px; }
.ops-mix { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; font-size: 12px; }
.ops-mix-row { display: flex; justify-content: space-between; color: var(--dim); }
.ops-rows { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.ops-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 10px; border: 1px solid var(--hair); border-radius: 9px; font-size: 12.5px; }
.ops-type { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: rgba(168,85,247,.16); color: #e9d5ff; }
.ops-default { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: rgba(34,197,94,.16); color: #86efac; border: 1px solid rgba(34,197,94,.4); }
.ops-on { color: #86efac; font-size: 11.5px; }
.ops-recent { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.ops-recent-row { display: flex; gap: 10px; align-items: baseline; font-size: 12.5px; }
.ops-stage-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 10px; }
.ops-stage { font-size: 11.5px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); cursor: pointer; }
.ops-stage.is-on { border-color: rgba(168,85,247,.65); background: rgba(168,85,247,.14); color: #e9d5ff; }
.ops-form { display: flex; flex-direction: column; }
.ops-form-foot { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-top: 10px; }
.ops-label { font-size: 11.5px; color: var(--dim); margin: 4px 0 4px; display: block; }
.ops-field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.ops-field label { font-size: 11.5px; color: var(--dim); }
.ops-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--dim); }
.ops-flags { display: flex; gap: 16px; }
.ops-modal { width: min(560px, 94vw); }
.ops-ann { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.ops-ann-row { display: grid; grid-template-columns: 120px 160px 1fr auto; gap: 8px; align-items: start; }

.site-bar { text-align: center; font-size: 12px; padding: 7px 12px; background: linear-gradient(90deg, rgba(168,85,247,.18), rgba(236,72,153,.18)); color: #f5e9ff; border-bottom: 1px solid var(--hair); }

.home-poster-img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }

.ops-poster-row { display: grid; grid-template-columns: 1fr 120px 1.4fr auto; gap: 8px; align-items: center; }
.ops-plan-row { display: grid; grid-template-columns: 1.2fr 100px 90px 100px 100px auto; gap: 8px; align-items: center; }

.ops-login { display: flex; gap: 8px; align-items: center; }
.ops-login .input-dark { width: 180px; }
.ops-account { display: flex; gap: 8px; align-items: center; }
.ops-who { font-size: 12px; color: var(--dim); }

.ops-gate { display: grid; place-items: center; min-height: calc(100vh - 64px); padding: 30px 16px; }
.ops-gate[hidden] { display: none; }
.ops-gate-card { width: min(420px, 92vw); display: flex; flex-direction: column; gap: 8px; padding: 24px; border-radius: 14px; border: 1px solid var(--hair); background: rgba(15,17,24,.92); }
.ops-gate-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.ops-gate-brand strong { display: block; font-size: 16px; }
.ops-gate-brand .muted { font-size: 11.5px; }
.ops-gate-label { font-size: 12px; color: var(--dim); margin-top: 6px; }
.ops-gate-remember { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--dim); margin: 8px 0 4px; }
.ops-gate-hint { font-size: 11px; line-height: 1.6; margin-top: 6px; }

.ops-skill-form { display: grid; grid-template-columns: 240px 180px 1fr; gap: 8px; align-items: start; margin: 8px 0; }
.ops-skill-form textarea { min-height: 72px; }

.relay-card { margin-bottom: 14px; }
.relay-fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px 16px; margin: 8px 0 12px; }
.relay-fields .ops-field label { font-size: 11.5px; color: var(--dim); }
.relay-actions { display: flex; gap: 8px; justify-content: flex-end; }

.relay-group { margin-bottom: 14px; }
.relay-item { border-bottom: 1px solid var(--hair); }
.relay-row { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px 4px; background: transparent; border: none; color: inherit; cursor: pointer; text-align: left; font-size: 12.5px; }
.relay-row:hover { background: rgba(255,255,255,.03); }
.relay-caret { color: var(--dim); width: 12px; }
.relay-expanded { padding: 4px 4px 14px; }
.relay-form { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px 16px; }
.relay-form .relay-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; }
.relay-dynamic { display: contents; }

.ops-style-row { display: grid; grid-template-columns: 200px 1fr 1fr auto; gap: 8px; align-items: center; }

.relay-modelrow { display: flex; gap: 8px; align-items: center; }
.relay-modelrow select { flex: 1; }

.ops-result { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0; }
.ops-result div { border: 1px solid var(--hair); border-radius: 8px; padding: 8px; display: flex; flex-direction: column; gap: 3px; }
.ops-result b { font-size: 13px; word-break: break-all; }
.ops-result span { font-size: 11px; color: var(--dim); }
.ops-sample { max-height: 180px; overflow: auto; font-size: 11.5px; padding: 8px; border-radius: 8px; background: rgba(255,255,255,.04); }

.ep-chip-wrap { position: relative; display: inline-flex; }
.ep-del { position: absolute; top: -5px; right: -5px; width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--hair-strong); background: #1a1c25; color: #fca5a5; font-size: 11px; line-height: 1; display: none; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.ep-chip-wrap:hover .ep-del { display: inline-flex; }

/* 剧集列表：工具条 + 分页样式修正 */
.episode-tools { display: flex; gap: 8px; padding: 0 12px 10px; }
.episode-tools .episode-add { flex: 1; }
.episode-bulk { flex: none; height: 34px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--hair-strong); background: transparent; color: var(--dim); font-size: 12px; cursor: pointer; }
.episode-bulk:hover { border-color: rgba(248, 113, 113, .55); color: #fca5a5; }
.ep-pager { width: auto; flex: none; flex-direction: row; align-items: center; gap: 6px; padding: 0 12px 12px; align-self: flex-end; }
.ep-page { display: inline-flex; flex-direction: row; align-items: center; justify-content: center; gap: 2px; min-width: 52px; height: 28px; padding: 0 8px; font-size: 11px; line-height: 1; border-radius: 8px; }
.ep-page span { display: inline; }
.ep-page .ep-page-dash { display: inline; }
.ep-body { align-items: flex-start; }
/* 批量删除弹窗 */
.ep-bulk-box { width: min(520px, 94vw); }
.ep-bulk-list { display: flex; flex-direction: column; gap: 4px; max-height: 52vh; overflow: auto; margin: 8px 0; }
.ep-bulk-row { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border: 1px solid var(--hair); border-radius: 8px; font-size: 12.5px; cursor: pointer; }
.ep-bulk-row:hover { border-color: rgba(168, 85, 247, .45); }
.ep-bulk-no { font-weight: 600; min-width: 56px; }

.ep-bulk-row input[type="checkbox"] { width: 15px; height: 15px; accent-color: #a855f7; }

.ep-bulk-range-row { align-items: center; margin: 6px 0 2px; }
.ep-bulk-range { width: 96px; height: 30px; }
.ep-page-total { font-size: 11px; color: var(--dim); margin-left: 4px; }

/* 分镜左栏：场景/角色/道具 竖向标签 + 网格，无横向滚动 */
.sb-sec { display: flex; gap: 8px; align-items: stretch; }
.sb-sec-label { flex: none; width: 24px; display: flex; align-items: center; justify-content: center; border-radius: 8px; background: rgba(255,255,255,.05); border: 1px solid var(--hair); color: var(--dim); font-size: 10.5px; letter-spacing: 2px; writing-mode: vertical-rl; }
.sb-thumbs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; overflow: visible; padding-bottom: 0; flex: 1; }
.sb-thumb { width: auto; height: auto; aspect-ratio: 1 / 1; flex: none; border-radius: 8px; position: relative; }
.sb-thumb .name { font-size: 9.5px; bottom: 2px; left: 2px; right: 2px; text-align: center; }
.sb-thumb-add { width: auto; height: auto; aspect-ratio: 1 / 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.sb-thumb-add .ph { font-size: 14px; height: auto; }
.sb-thumb-add .name { position: static; font-size: 9.5px; color: #d8b4fe; }
.sb-thumb-sub { font-size: 8px; color: var(--dim); }
.sb-thumb-x { position: absolute; top: -5px; right: -5px; width: 16px; height: 16px; border-radius: 50%; background: #ef4444; color: #fff; font-size: 11px; line-height: 1; display: grid; place-items: center; z-index: 2; }

.sb-voice-row { display: flex; align-items: center; gap: 8px; margin-left: 32px; margin-top: 6px; flex-wrap: wrap; }
.sb-voice-label { flex: none; font-size: 10.5px; color: var(--dim); letter-spacing: 1px; }
.sb-voice-select { height: 28px; font-size: 11.5px; max-width: 150px; }

.sb-sec-wrap { display: flex; flex-direction: column; gap: 4px; }

.project-card { position: relative; }
.project-del { position: absolute; top: 10px; right: 10px; z-index: 3; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: rgba(15,17,24,.72); border: 1px solid var(--hair-strong); font-size: 13px; cursor: pointer; opacity: 0; transition: opacity .15s; }
.project-card:hover .project-del { opacity: 1; }
.project-del:hover { border-color: rgba(248,113,113,.6); }
.pj-bulk-box { width: min(560px, 94vw); }
.pj-bulk-list { display: flex; flex-direction: column; gap: 6px; max-height: 52vh; overflow: auto; margin: 8px 0; }
.pj-bulk-row { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border: 1px solid var(--hair); border-radius: 8px; cursor: pointer; }
.pj-bulk-row:hover { border-color: rgba(168,85,247,.45); }
.pj-bulk-row input[type="checkbox"] { width: 15px; height: 15px; accent-color: #a855f7; }
