/* ============================================================
   驾校小红书 AI 内容工作台 —— 视觉体系 v2（小红书风格）
   设计语言：品牌红 #FF2442 · 白底大圆角 · 宽松留白 · 柔性阴影
   ============================================================ */
:root {
  /* 品牌 */
  --brand: #FF2442;
  --brand-2: #FF6B81;
  --brand-dark: #E01A38;
  --brand-soft: #FFF1F3;
  --brand-line: #FFD9DF;
  --brand-grad: linear-gradient(135deg, #FF4D63 0%, #FF2442 55%, #F01B37 100%);

  /* 中性 */
  --ink: #1A1A1A;
  --ink2: #4D4D4D;
  --ink3: #9A9A9A;
  --ink4: #C4C4C4;
  --line: #EFEFF1;
  --line2: #F6F6F8;
  --bg: #F7F8FA;
  --card: #FFFFFF;

  /* 语义 */
  --red: #E0304A;      --red-bg: #FFF0F2;
  --orange: #F5760B;   --orange-bg: #FFF4E8;
  --green: #14A05A;    --green-bg: #EAF8F0;
  --blue: #2E6BE6;     --blue-bg: #EDF2FF;
  --purple: #7B5CF0;   --purple-bg: #F3F0FF;

  /* 形状 */
  --r-sm: 8px;
  --r: 14px;
  --r-lg: 20px;
  --r-pill: 999px;
  --shadow: 0 1px 2px rgba(20,20,30,.03), 0 6px 20px rgba(20,20,30,.045);
  --shadow-lg: 0 12px 40px rgba(20,20,30,.10);
  --sidebar: 236px;
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #DDDDE2; border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #C8C8CE; }
::-webkit-scrollbar-track { background: transparent; }

/* ================= 布局 ================= */
.app { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar); flex: 0 0 var(--sidebar);
  background: #fff; border-right: 1px solid var(--line);
  position: fixed; top: 0; bottom: 0; left: 0;
  display: flex; flex-direction: column; z-index: 20;
}
.brand { padding: 22px 20px 16px; }
.brand .logo {
  width: 36px; height: 36px; border-radius: 11px; background: var(--brand-grad); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 16px;
  margin-bottom: 11px; box-shadow: 0 4px 12px rgba(255,36,66,.28);
}
.brand b { display: block; font-size: 15.5px; letter-spacing: -.2px; color: var(--ink); font-weight: 700; }
.brand span { font-size: 12px; color: var(--ink3); }

.nav { flex: 1; overflow-y: auto; padding: 6px 12px 20px; }
.nav-group { font-size: 11px; color: var(--ink4); padding: 16px 12px 7px; letter-spacing: .8px; font-weight: 600; }
.nav a {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: var(--r-sm);
  color: var(--ink2); font-size: 14px; margin-bottom: 2px; text-decoration: none;
  transition: background .15s, color .15s; position: relative;
}
.nav a:hover { background: var(--line2); color: var(--ink); }
.nav a.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.nav a.active::before {
  content: ''; position: absolute; left: -12px; top: 50%; transform: translateY(-50%);
  width: 3px; height: 18px; background: var(--brand); border-radius: 0 3px 3px 0;
}
.nav a .ic { width: 20px; text-align: center; font-size: 15px; opacity: .95; }
.nav a .badge-n { margin-left: auto; background: var(--brand); color: #fff; font-size: 11px; border-radius: 10px; padding: 0 7px; line-height: 17px; font-weight: 600; }

.sidebar-foot { padding: 14px 16px; border-top: 1px solid var(--line2); font-size: 12.5px; color: var(--ink3); }
.sidebar-foot .u { display: flex; align-items: center; gap: 9px; margin-bottom: 9px; color: var(--ink2); }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; background: var(--brand-grad); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700;
  flex: 0 0 30px;
}

.main { flex: 1; margin-left: var(--sidebar); display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 64px; background: rgba(255,255,255,.86); backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 14px; padding: 0 28px; position: sticky; top: 0; z-index: 15;
}
.topbar h1 { font-size: 17px; font-weight: 700; letter-spacing: -.2px; }
.topbar .sub { font-size: 12.5px; color: var(--ink3); line-height: 1.5; }
.spacer { flex: 1; }
.content { padding: 24px 28px 80px; max-width: 1560px; }

/* ================= 按钮 ================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 36px; padding: 0 16px; border-radius: var(--r-pill); border: 1px solid var(--line);
  background: #fff; color: var(--ink2); cursor: pointer; white-space: nowrap; font-size: 13.5px;
  transition: .16s; font-weight: 500;
}
.btn:hover { border-color: #E0E0E4; background: #FAFAFB; color: var(--ink); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--brand-grad); border-color: transparent; color: #fff; box-shadow: 0 3px 12px rgba(255,36,66,.26); }
.btn-primary:hover { background: var(--brand-dark); border-color: transparent; color: #fff; box-shadow: 0 5px 18px rgba(255,36,66,.34); }
.btn-danger { color: var(--red); border-color: #FFD5DB; background: #fff; }
.btn-danger:hover { background: var(--red-bg); border-color: #FFC2CB; }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-ghost:hover { background: var(--line2); }
.btn-sm { height: 30px; padding: 0 12px; font-size: 12.5px; }
.btn-lg { height: 46px; padding: 0 24px; font-size: 15px; font-weight: 600; }
.btn-block { width: 100%; }

/* ================= 卡片 ================= */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow); overflow: hidden; }
.card-h { padding: 18px 22px 14px; display: flex; align-items: center; gap: 10px; }
.card-h h3 { font-size: 15px; font-weight: 700; letter-spacing: -.2px; }
.card-h .hint { font-size: 12.5px; color: var(--ink3); }
.card-b { padding: 0 22px 22px; }
.card-b.tight { padding: 0; }
.card-b.pad { padding: 22px; }

.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1360px) { .g4 { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 1180px) { .g3 { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 980px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }

/* ================= 表单 ================= */
.field { margin-bottom: 16px; }
.field > label { display: block; font-size: 13px; color: var(--ink2); margin-bottom: 7px; font-weight: 600; }
.field .tip { font-size: 12px; color: var(--ink3); margin-top: 6px; line-height: 1.6; }
.input, .select, .textarea {
  width: 100%; height: 42px; padding: 0 14px; border: 1px solid var(--line);
  border-radius: 12px; background: #FCFCFD; outline: none; transition: .16s;
}
.input:hover, .select:hover, .textarea:hover { background: #fff; }
.textarea { height: auto; padding: 12px 14px; line-height: 1.75; resize: vertical; min-height: 110px; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3.5px rgba(255,36,66,.10); }
.input::placeholder, .textarea::placeholder { color: var(--ink4); }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%239A9A9A' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.row { display: flex; gap: 12px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.row > .field { flex: 1; margin-bottom: 0; }

/* 开关 */
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { display: none; }
.switch .track { width: 44px; height: 25px; border-radius: var(--r-pill); background: #DFDFE4; position: relative; transition: .2s; flex: 0 0 44px; }
.switch .track::after { content: ''; position: absolute; top: 2.5px; left: 2.5px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0,0,0,.18); transition: .2s; }
.switch input:checked + .track { background: var(--brand); }
.switch input:checked + .track::after { transform: translateX(19px); }
.switch .lb { font-size: 13.5px; color: var(--ink2); }

/* ================= 标签 ================= */
.tag { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 10px; border-radius: var(--r-pill); font-size: 12px; background: var(--line2); color: var(--ink2); font-weight: 500; }
.tag.brand { background: var(--brand-soft); color: var(--brand); }
.tag.red { background: var(--red-bg); color: var(--red); }
.tag.orange { background: var(--orange-bg); color: var(--orange); }
.tag.green { background: var(--green-bg); color: var(--green); }
.tag.blue { background: var(--blue-bg); color: var(--blue); }
.tag.purple { background: var(--purple-bg); color: var(--purple); }

/* ================= 表格 ================= */
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.tbl th {
  text-align: left; font-weight: 600; color: var(--ink3); font-size: 12px; letter-spacing: .3px;
  padding: 10px 18px; border-bottom: 1px solid var(--line); background: #FCFCFD; position: sticky; top: 0; z-index: 2;
}
table.tbl td { padding: 14px 18px; border-bottom: 1px solid var(--line2); vertical-align: middle; }
table.tbl tr:last-child td { border-bottom: none; }
table.tbl tbody tr { transition: background .13s; }
table.tbl tbody tr:hover td { background: #FCFAFA; }
table.tbl td.actions { text-align: right; white-space: nowrap; }
.scroll-y { max-height: 640px; overflow-y: auto; }

/* ================= 空状态 ================= */
.empty { padding: 56px 20px; text-align: center; color: var(--ink3); font-size: 13.5px; }
.empty .big { font-size: 40px; margin-bottom: 12px; opacity: .28; line-height: 1; }

/* ================= 统计卡 ================= */
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px 22px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.stat .k { font-size: 12.5px; color: var(--ink3); margin-bottom: 8px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.stat .v { font-size: 30px; font-weight: 800; letter-spacing: -1px; line-height: 1.1; color: var(--ink); }
.stat .d { font-size: 12px; color: var(--ink3); margin-top: 7px; }
.stat.acc { background: var(--brand-grad); border-color: transparent; }
.stat.acc .k, .stat.acc .d { color: rgba(255,255,255,.82); }
.stat.acc .v { color: #fff; }

/* ================= Toast ================= */
.toast-wrap { position: fixed; top: 20px; right: 20px; z-index: 9999; display: flex; flex-direction: column; gap: 10px; }
.toast {
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 13px 18px;
  box-shadow: var(--shadow-lg); min-width: 240px; max-width: 420px; font-size: 13.5px;
  animation: slideIn .22s cubic-bezier(.2,.9,.3,1); display: flex; align-items: center; gap: 9px;
}
.toast::before { content: '✓'; color: var(--green); font-weight: 700; }
.toast.err { border-left: none; }
.toast.err::before { content: '!'; color: var(--red); }
.toast.warn::before { content: '!'; color: var(--orange); }
@keyframes slideIn { from { opacity: 0; transform: translateX(20px) scale(.97); } to { opacity: 1; transform: none; } }

/* ================= Modal ================= */
.modal-mask { position: fixed; inset: 0; background: rgba(24,24,32,.42); backdrop-filter: blur(3px); z-index: 999; display: flex; align-items: center; justify-content: center; padding: 24px; animation: fadeIn .16s ease; }
.modal { background: #fff; border-radius: var(--r-lg); box-shadow: 0 24px 70px rgba(0,0,0,.22); width: 100%; max-width: 640px; max-height: 88vh; display: flex; flex-direction: column; animation: popIn .2s cubic-bezier(.2,.9,.3,1); }
.modal.wide { max-width: 940px; }
.modal-h { padding: 20px 24px 14px; display: flex; align-items: center; }
.modal-h h3 { font-size: 16px; font-weight: 700; }
.modal-b { padding: 4px 24px 20px; overflow-y: auto; flex: 1; }
.modal-f { padding: 16px 24px 20px; display: flex; gap: 10px; justify-content: flex-end; }
.x { margin-left: auto; cursor: pointer; color: var(--ink3); font-size: 20px; line-height: 1; padding: 3px 8px; border-radius: 8px; }
.x:hover { background: var(--line2); color: var(--ink); }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }

mark.hit-block { background: #FFDCE1; color: #B01028; padding: 1px 4px; border-radius: 5px; font-weight: 700; }
mark.hit-warn { background: #FFEFD6; color: #9A5B06; padding: 1px 4px; border-radius: 5px; }

/* ================= 分段控件 ================= */
.seg { display: inline-flex; background: var(--line2); padding: 4px; border-radius: var(--r-pill); gap: 3px; }
.seg button { height: 30px; padding: 0 15px; border: none; background: transparent; border-radius: var(--r-pill); cursor: pointer; color: var(--ink2); font-size: 13px; transition: .15s; font-weight: 500; }
.seg button:hover { color: var(--ink); }
.seg button.on { background: #fff; color: var(--brand); font-weight: 700; box-shadow: 0 1px 4px rgba(0,0,0,.09); }

.bar { height: 7px; background: var(--line2); border-radius: 5px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--brand-grad); border-radius: 5px; transition: width .4s; }

/* ================= 工具类 ================= */
.mono { font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace; font-size: 12px; }
.muted { color: var(--ink3); }
.small { font-size: 12.5px; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; } .mt24 { margin-top: 24px; }
.mb8 { margin-bottom: 8px; } .mb12 { margin-bottom: 12px; } .mb16 { margin-bottom: 16px; } .mb24 { margin-bottom: 24px; }
.hidden { display: none !important; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.pre { white-space: pre-wrap; word-break: break-word; }
.err-text { color: var(--red); font-size: 13px; }
.clickable { cursor: pointer; }
.thumb { width: 52px; height: 52px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); background: var(--line2); }
.pill-list { display: flex; flex-wrap: wrap; gap: 6px; }
.divider { height: 1px; background: var(--line2); margin: 20px 0; }

/* ================= 登录页 ================= */
.login-wrap {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px;
  background:
    radial-gradient(900px 480px at 12% -8%, #FFE8EC 0%, transparent 62%),
    radial-gradient(760px 420px at 92% 108%, #FFEEF1 0%, transparent 60%),
    #FAFAFB;
}
.login-box { width: 420px; background: #fff; border: 1px solid var(--line); border-radius: 26px; padding: 40px 36px; box-shadow: 0 20px 60px rgba(255,36,66,.09), 0 2px 8px rgba(0,0,0,.04); }
.login-box .lg { width: 54px; height: 54px; border-radius: 17px; background: var(--brand-grad); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 800; margin-bottom: 20px; box-shadow: 0 8px 22px rgba(255,36,66,.3); }
.login-box h2 { font-size: 23px; margin-bottom: 7px; letter-spacing: -.4px; font-weight: 800; }
.login-box p.sub { color: var(--ink3); font-size: 13.5px; margin-bottom: 26px; }
.login-tip { margin-top: 20px; padding: 13px 15px; background: var(--brand-soft); border-radius: 14px; font-size: 12.5px; color: var(--brand-dark); line-height: 1.8; }

/* ================= 封面编辑器 ================= */
.cover-stage { background: #F2F3F5; border-radius: var(--r-lg); padding: 26px; display: flex; justify-content: center; align-items: flex-start; min-height: 560px; }
#coverCanvas { box-shadow: 0 10px 34px rgba(0,0,0,.16); border-radius: 8px; max-width: 100%; }
.tpl-item { border: 1.5px solid var(--line); border-radius: var(--r); padding: 12px 13px; cursor: pointer; background: #fff; transition: .16s; }
.tpl-item:hover { border-color: var(--brand-line); transform: translateY(-1px); }
.tpl-item.on { border-color: var(--brand); background: var(--brand-soft); }
.tpl-item b { font-size: 13px; display: block; font-weight: 600; }
.tpl-item span { font-size: 11.5px; color: var(--ink3); line-height: 1.55; display: block; margin-top: 4px; }

/* ================= 流水线 ================= */
.pipe { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pipe .step { display: flex; align-items: center; gap: 7px; padding: 8px 15px; border-radius: var(--r-pill); background: #fff; border: 1px solid var(--line); font-size: 13px; font-weight: 500; }
.pipe .step.done { background: var(--green-bg); border-color: #CBEBD9; color: #0F8A4C; }
.pipe .step.cur { background: var(--brand-grad); border-color: transparent; color: #fff; font-weight: 700; box-shadow: 0 3px 12px rgba(255,36,66,.25); }
.pipe .arrow { color: var(--ink4); font-size: 13px; }

/* ================= 小红书笔记预览卡 ================= */
.xhs-note { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; box-shadow: var(--shadow); transition: .18s; }
.xhs-note:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.xhs-note .cy { width: 100%; aspect-ratio: 3/4; background: linear-gradient(135deg,#FFF1F3,#FFE7EB); display: flex; align-items: center; justify-content: center; color: var(--brand); font-size: 13px; position: relative; overflow: hidden; }
.xhs-note .cy img { width: 100%; height: 100%; object-fit: cover; display: block; }
.xhs-note .nb { padding: 12px 14px 14px; }
.xhs-note .nt { font-size: 13.5px; font-weight: 600; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.xhs-note .nm { display: flex; align-items: center; gap: 7px; margin-top: 10px; font-size: 12px; color: var(--ink3); }
.xhs-note .nm .av { width: 20px; height: 20px; border-radius: 50%; background: var(--brand-grad); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; }
.xhs-note .nl { margin-left: auto; display: flex; align-items: center; gap: 3px; }
.note-preview { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; max-width: 390px; box-shadow: var(--shadow); }
.note-preview .np-h { display: flex; align-items: center; gap: 9px; padding: 12px 14px; }
.note-preview .np-b { padding: 0 14px 14px; font-size: 13.5px; line-height: 1.85; }
.note-preview img { width: 100%; display: block; }

/* ================= 自动化流程 ================= */
.flow { display: flex; flex-direction: column; gap: 0; }
.flow-step { display: flex; gap: 16px; position: relative; padding-bottom: 22px; }
.flow-step:last-child { padding-bottom: 0; }
.flow-step .dot { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 50%; background: #fff; border: 2px solid var(--line); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: var(--ink3); z-index: 1; }
.flow-step.on .dot { background: var(--brand-grad); border-color: transparent; color: #fff; box-shadow: 0 3px 12px rgba(255,36,66,.28); }
.flow-step.done .dot { background: var(--green-bg); border-color: #CBEBD9; color: var(--green); }
.flow-step::after { content: ''; position: absolute; left: 16px; top: 34px; bottom: 0; width: 2px; background: var(--line); }
.flow-step:last-child::after { display: none; }
.flow-step .fb { flex: 1; padding-top: 5px; }
.flow-step .fb b { font-size: 14px; display: block; font-weight: 600; }
.flow-step .fb .d { font-size: 12.5px; color: var(--ink3); line-height: 1.65; margin-top: 3px; }

/* 运行记录 */
.run-item { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line2); font-size: 13px; }
.run-item:last-child { border-bottom: none; }
.run-item .rd { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 8px; }
.run-item .rd.ok { background: var(--green); }
.run-item .rd.err { background: var(--red); }
.run-item .rd.run { background: var(--orange); animation: pulse 1.2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* ================= 发布中心 ================= */
.pub-card { border: 1.5px solid var(--line); border-radius: var(--r-lg); padding: 20px; background: #fff; transition: .18s; }
.pub-card.hot { border-color: var(--brand-line); background: linear-gradient(180deg,#FFFBFC 0%,#fff 40%); }
.pub-card .pct { display: flex; align-items: center; gap: 9px; font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.pub-card .pcd { font-size: 12.5px; color: var(--ink3); line-height: 1.7; }
.badge-soon { background: var(--orange-bg); color: var(--orange); font-size: 11px; padding: 1px 8px; border-radius: var(--r-pill); font-weight: 600; }
.badge-risk { background: var(--red-bg); color: var(--red); font-size: 11px; padding: 1px 8px; border-radius: var(--r-pill); font-weight: 600; }
.badge-ok { background: var(--green-bg); color: var(--green); font-size: 11px; padding: 1px 8px; border-radius: var(--r-pill); font-weight: 600; }

/* 发布步骤条 */
.steps { display: flex; align-items: center; gap: 0; margin: 6px 0 20px; }
.steps .s { display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--ink3); }
.steps .s .n { width: 26px; height: 26px; border-radius: 50%; background: var(--line2); color: var(--ink3); display: flex; align-items: center; justify-content: center; font-size: 12.5px; font-weight: 700; flex: 0 0 26px; }
.steps .s.on { color: var(--brand); font-weight: 600; }
.steps .s.on .n { background: var(--brand-grad); color: #fff; }
.steps .s.done { color: var(--green); }
.steps .s.done .n { background: var(--green-bg); color: var(--green); }
.steps .l { flex: 1; height: 2px; background: var(--line); margin: 0 12px; min-width: 20px; }

/* ================= AI 状态条 ================= */
.ai-status { display: flex; align-items: center; gap: 14px; padding: 16px 20px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); }
.ai-status .ic { width: 42px; height: 42px; border-radius: 13px; display: flex; align-items: center; justify-content: center; font-size: 19px; flex: 0 0 42px; }
.ai-status .ic.on { background: var(--green-bg); }
.ai-status .ic.off { background: var(--orange-bg); }
.ai-status b { font-size: 14.5px; display: block; font-weight: 600; }
.ai-status .d { font-size: 12.5px; color: var(--ink3); margin-top: 2px; }

/* 素材网格 */
.mat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.mat-cell { border: 1.5px solid var(--line); border-radius: var(--r); overflow: hidden; background: #fff; transition: .16s; cursor: pointer; }
.mat-cell:hover { border-color: var(--brand-line); transform: translateY(-2px); box-shadow: var(--shadow); }
.mat-cell.sel { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(255,36,66,.12); }
.mat-cell .im { width: 100%; height: 150px; object-fit: cover; display: block; background: var(--line2); }
.mat-cell .mb { padding: 10px 12px 12px; }
.mat-cell .mf { font-size: 12px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.mat-cell .mt2 { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px; }

/* hero 主视觉 */
.hero { border-radius: 22px; padding: 26px 28px; background: linear-gradient(120deg,#FFF3F5 0%,#FFF8F9 46%,#FFF1F4 100%); border: 1px solid var(--brand-line); position: relative; overflow: hidden; }
.hero::after { content: ''; position: absolute; right: -50px; top: -60px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(255,36,66,.10), transparent 70%); }
.hero h2 { font-size: 21px; font-weight: 800; letter-spacing: -.4px; margin-bottom: 7px; }
.hero p { font-size: 13.5px; color: var(--ink2); line-height: 1.75; max-width: 720px; }
.hero .acts { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }

/* 代码块 */
.codebox { background: #F8F8FA; border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; font-family: "SF Mono", ui-monospace, Menlo, Consolas, sans-serif; font-size: 12.5px; line-height: 1.7; white-space: pre-wrap; word-break: break-all; color: var(--ink2); max-height: 260px; overflow-y: auto; }

/* 双轨 Tab（对标 / 自有） */
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); padding-bottom: 0; }
.tabs .tab { background: none; border: none; padding: 9px 16px 11px; font-size: 14px; color: var(--ink2); cursor: pointer; border-bottom: 2px solid transparent; transition: all .15s; display: flex; align-items: center; gap: 8px; font-weight: 500; }
.tabs .tab:hover { color: var(--ink); }
.tabs .tab.active { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }
.tabs .tab-count { background: var(--line2); color: var(--ink2); padding: 2px 7px; border-radius: 9px; font-size: 11px; font-weight: 500; }
.tabs .tab.active .tab-count { background: var(--brand-soft); color: var(--brand); }
