/* ============================================================
   悦享·入库通 DataIn —— 设计系统（浅色主题）
   ============================================================ */
:root {
  --bg: #f5f7fa;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --border: #e5e7eb;
  --border-strong: #d5dbe3;
  --text: #1f2937;
  --text-2: #4b5563;
  --muted: #8b95a5;
  --primary: #2563eb;
  --primary-weak: #eff5ff;
  --primary-dark: #1d4ed8;
  --teal: #0d9488;
  --teal-weak: #ecfdf5;
  --green: #059669;
  --amber: #d97706;
  --amber-weak: #fffbeb;
  --red: #dc2626;
  --red-weak: #fef2f2;
  --purple: #7c3aed;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(16, 24, 40, .05), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-lg: 0 12px 32px rgba(16, 24, 40, .10);
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------------- 顶栏 ---------------- */
.topbar {
  height: 60px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  position: sticky; top: 0; z-index: 40;
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo {
  width: 34px; height: 34px; border-radius: 10px; flex: none;
  background: linear-gradient(135deg, #2563eb, #0d9488);
  color: #fff; font-weight: 700; font-size: 17px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 10px rgba(37, 99, 235, .25);
}
.brand-name { font-size: 15px; font-weight: 700; letter-spacing: .2px; }
.brand-name em { font-style: normal; color: var(--primary); font-weight: 600; font-size: 12px; margin-left: 4px; letter-spacing: .5px; }
.brand-sub { font-size: 11.5px; color: var(--muted); margin-top: -2px; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }

.privacy-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--teal-weak); color: #0f766e;
  border: 1px solid #a7f3d0; border-radius: 999px;
  padding: 4px 12px; font-size: 12px; font-weight: 600;
}

/* ---------------- 步骤条 ---------------- */
.stepper {
  display: flex; align-items: center; gap: 0;
  background: var(--surface); border-bottom: 1px solid var(--border);
  padding: 0 22px; overflow-x: auto; position: sticky; top: 60px; z-index: 30;
}
.step {
  display: flex; align-items: center; gap: 9px;
  padding: 13px 8px 12px; margin-right: 4px;
  font-size: 13px; color: var(--muted); white-space: nowrap;
  border-bottom: 2px solid transparent; cursor: default;
}
.step.done { color: var(--text-2); cursor: pointer; }
.step.done:hover { color: var(--primary); }
.step.active { color: var(--primary); font-weight: 600; border-bottom-color: var(--primary); }
.step-num {
  width: 21px; height: 21px; border-radius: 50%; flex: none;
  background: #eef2f7; color: var(--muted);
  font-size: 11.5px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.step.active .step-num { background: var(--primary); color: #fff; }
.step.done .step-num { background: #d1fae5; color: #047857; }
.step-sep { width: 18px; height: 1px; background: var(--border-strong); margin: 0 2px; flex: none; }

/* ---------------- 主舞台 ---------------- */
.stage { max-width: 1420px; margin: 0 auto; padding: 22px 22px 60px; }
.stage.narrow { max-width: 980px; }

.panel {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
  margin-bottom: 16px; overflow: hidden;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px; border-bottom: 1px solid var(--border); background: var(--surface-2);
}
.panel-head h2 { margin: 0; font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.panel-head .hint { font-size: 12px; color: var(--muted); font-weight: 400; }
.panel-body { padding: 18px; }
.panel-body.tight { padding: 12px; }

.grid-2 { display: grid; grid-template-columns: 1fr 360px; gap: 16px; align-items: start; }
.grid-2.rev { grid-template-columns: 320px 1fr; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }

/* ---------------- 上传页 ---------------- */
.dropzone {
  border: 2px dashed var(--border-strong); border-radius: var(--radius);
  background: var(--surface-2); padding: 46px 24px; text-align: center;
  transition: all .18s ease; cursor: pointer;
}
.dropzone:hover, .dropzone.over { border-color: var(--primary); background: var(--primary-weak); }
.dropzone .dz-icon { font-size: 34px; color: var(--primary); line-height: 1; margin-bottom: 12px; }
.dropzone h3 { margin: 0 0 6px; font-size: 16px; }
.dropzone p { margin: 0; color: var(--muted); font-size: 13px; }
.dz-formats { margin-top: 14px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

.hero-title { font-size: 22px; font-weight: 700; margin: 4px 0 6px; }
.hero-sub { color: var(--text-2); font-size: 13.5px; margin: 0 0 18px; }
.hero-sub b { color: var(--primary); }

.declare-box {
  background: var(--teal-weak); border: 1px solid #a7f3d0; border-radius: var(--radius-sm);
  padding: 14px 16px; font-size: 13px; color: #115e59; line-height: 1.8; margin-top: 16px;
}
.declare-box h4 { margin: 0 0 6px; font-size: 13.5px; color: #0f766e; display: flex; align-items: center; gap: 6px; }
.declare-box ul { margin: 6px 0 0; padding-left: 20px; }
.checkline { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 13px; cursor: pointer; }
.checkline input { width: 15px; height: 15px; accent-color: var(--primary); }

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  border-radius: var(--radius-sm); padding: 8px 15px; font-size: 13px; font-weight: 500;
  cursor: pointer; transition: all .15s ease; font-family: inherit; white-space: nowrap;
}
.btn:hover { border-color: var(--primary); color: var(--primary); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:disabled:hover { border-color: var(--border-strong); color: var(--text); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn-teal { background: var(--teal); border-color: var(--teal); color: #fff; }
.btn-teal:hover { background: #0f766e; border-color: #0f766e; color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-2); padding: 8px 11px; }
.btn-ghost:hover { background: #f1f5f9; color: var(--primary); border-color: transparent; }
.btn-sm { padding: 5px 11px; font-size: 12.5px; }
.btn-danger { color: var(--red); border-color: #fecaca; }
.btn-danger:hover { background: var(--red-weak); border-color: var(--red); color: var(--red); }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.btn-row.right { justify-content: flex-end; }
.step-actions {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 14px 0 0; margin-top: 4px;
}

/* ---------------- 数据网格 ---------------- */
.grid-wrap { overflow: auto; max-height: 520px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
table.dgrid { border-collapse: separate; border-spacing: 0; font-size: 12.5px; width: max-content; min-width: 100%; }
table.dgrid th, table.dgrid td {
  border-right: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 6px 10px; text-align: left; white-space: nowrap; max-width: 230px;
  overflow: hidden; text-overflow: ellipsis;
}
table.dgrid thead th {
  position: sticky; top: 0; z-index: 3; background: var(--surface-2);
  font-weight: 600; color: var(--text-2); font-size: 12px;
}
table.dgrid td.rowno, table.dgrid th.rowno {
  position: sticky; left: 0; z-index: 2; background: #f1f5f9;
  color: var(--muted); font-family: var(--mono); font-size: 11.5px;
  text-align: right; width: 52px; min-width: 52px; cursor: pointer;
}
table.dgrid thead th.rowno { z-index: 4; }
table.dgrid tr.hdr-row td { background: #eef5ff; font-weight: 600; color: var(--primary-dark); }
table.dgrid tr.foot-row td { background: #fff7ed; color: var(--amber); font-style: italic; }
table.dgrid tr.sum-row td { background: #fffbeb; color: var(--amber); font-weight: 600; }
table.dgrid tr:hover td { background: #f8fbff; }
table.dgrid tr.hdr-row:hover td { background: #e6f0ff; }
td .nullv { color: #cbd5e1; font-style: italic; }

.colhead { display: flex; flex-direction: column; gap: 3px; }
.colhead .cname { font-weight: 600; color: var(--text); font-size: 12.5px; }

/* ---------------- 徽标 / 标签 ---------------- */
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 1px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 600; white-space: nowrap;
  background: #eef2f7; color: var(--text-2);
}
.chip.c-blue { background: #e0edff; color: #1d4ed8; }
.chip.c-teal { background: #ccfbf1; color: #0f766e; }
.chip.c-green { background: #d1fae5; color: #047857; }
.chip.c-orange { background: #ffedd5; color: #c2410c; }
.chip.c-purple { background: #ede9fe; color: #6d28d9; }
.chip.c-gray { background: #f1f5f9; color: #64748b; }
.chip.c-red { background: #fee2e2; color: #b91c1c; }
.chip.pk { background: linear-gradient(135deg, #fef3c7, #fde68a); color: #92400e; }

.tag-lv { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; }
.tag-lv.error { background: #fee2e2; color: #b91c1c; }
.tag-lv.warn { background: #fef3c7; color: #b45309; }
.tag-lv.info { background: #e0f2fe; color: #0369a1; }

/* ---------------- 指标卡 ---------------- */
.stat {
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 12px 14px;
}
.stat .k { font-size: 11.5px; color: var(--muted); margin-bottom: 3px; }
.stat .v { font-size: 19px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat .v small { font-size: 12px; font-weight: 500; color: var(--muted); margin-left: 3px; }
.stat.ok .v { color: var(--green); }
.stat.warn .v { color: var(--amber); }
.stat.err .v { color: var(--red); }

/* ---------------- 列画像表 ---------------- */
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
table.tbl th, table.tbl td { padding: 8px 10px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
table.tbl th { background: var(--surface-2); color: var(--text-2); font-weight: 600; font-size: 12.5px; position: sticky; top: 0; }
table.tbl tbody tr:hover { background: #fafcff; }
table.tbl td.num, table.tbl th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.tbl code { font-family: var(--mono); font-size: 12px; background: #f1f5f9; padding: 1px 5px; border-radius: 4px; color: #0f172a; }
.tbl-wrap { max-height: 420px; overflow: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); }

/* ---------------- 表单控件 ---------------- */
.fld { margin-bottom: 12px; }
.fld label { display: block; font-size: 12.5px; color: var(--text-2); margin-bottom: 5px; font-weight: 500; }
input[type=text], input[type=number], input[type=password], select, textarea {
  width: 100%; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  padding: 7px 11px; font-size: 13px; font-family: inherit; background: var(--surface); color: var(--text);
  transition: border-color .15s ease;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, .1); }
textarea { resize: vertical; min-height: 70px; }
select { cursor: pointer; }
.inline-fld { display: flex; gap: 8px; align-items: center; }
.inline-fld > * { flex: 1; }

/* ---------------- 映射表 ---------------- */
.map-row {
  display: grid; grid-template-columns: 1fr 92px 1fr; gap: 10px; align-items: center;
  padding: 9px 12px; border-bottom: 1px solid var(--border);
}
.map-row:hover { background: #fafcff; }
.map-row.head { background: var(--surface-2); font-size: 12.5px; color: var(--text-2); font-weight: 600; position: sticky; top: 0; z-index: 2; }
.map-src { display: flex; align-items: center; gap: 8px; font-size: 13px; min-width: 0; }
.map-src .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.map-mid { text-align: center; }
.conf {
  display: inline-block; min-width: 56px; padding: 2px 7px; border-radius: 999px;
  font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.conf.hi { background: #d1fae5; color: #047857; }
.conf.mid { background: #fef3c7; color: #b45309; }
.conf.lo { background: #f1f5f9; color: #64748b; }
.map-tgt select { padding: 5px 9px; font-size: 12.5px; }
.map-row.accepted { background: #f6fffb; }

/* ---------------- 清洗管道 ---------------- */
.pipe { display: flex; flex-direction: column; gap: 10px; }
.pipe-step {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); padding: 12px 14px; transition: all .15s ease;
}
.pipe-step.on { border-color: #bfdbfe; background: #f8fbff; }
.pipe-step.off { opacity: .62; }
.pipe-top { display: flex; align-items: center; gap: 10px; }
.pipe-idx {
  width: 22px; height: 22px; border-radius: 50%; background: var(--primary-weak); color: var(--primary);
  font-size: 11.5px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none;
}
.pipe-name { font-weight: 600; font-size: 13.5px; }
.pipe-col { font-size: 12px; color: var(--muted); }
.pipe-desc { font-size: 12px; color: var(--muted); margin: 6px 0 0 32px; line-height: 1.6; }
.pipe-stat { margin-left: auto; display: flex; align-items: center; gap: 8px; font-size: 12px; }

.switch { position: relative; width: 36px; height: 20px; flex: none; cursor: pointer; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch i {
  position: absolute; inset: 0; background: #cbd5e1; border-radius: 999px; transition: .2s;
}
.switch i::after {
  content: ''; position: absolute; width: 16px; height: 16px; border-radius: 50%;
  background: #fff; top: 2px; left: 2px; transition: .2s; box-shadow: 0 1px 2px rgba(0,0,0,.2);
}
.switch input:checked + i { background: var(--primary); }
.switch input:checked + i::after { transform: translateX(16px); }

.rule-pick {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px;
  border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 8px;
  cursor: pointer; background: var(--surface); transition: all .15s;
}
.rule-pick:hover { border-color: var(--primary); background: var(--primary-weak); }
.rule-pick .rn { font-size: 13px; font-weight: 600; }
.rule-pick .rd { font-size: 11.5px; color: var(--muted); line-height: 1.5; }

.issue-mini {
  display: flex; gap: 8px; align-items: flex-start; font-size: 12px;
  padding: 7px 10px; border-radius: var(--radius-sm); margin-top: 6px; line-height: 1.6;
}
.issue-mini.error { background: var(--red-weak); color: #991b1b; }
.issue-mini.warn { background: var(--amber-weak); color: #92400e; }
.issue-mini.info { background: #f0f9ff; color: #075985; }

/* 多段内容的提示块（入库前预检 / 服务状态）改为纵向排版 */
.issue-mini.block { display: block; }
.issue-mini.block > b { display: block; margin-bottom: 2px; }

/* ---------------- 评分环 ---------------- */
.score-ring {
  width: 132px; height: 132px; border-radius: 50%; flex: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff;
  box-shadow: 0 8px 22px rgba(37, 99, 235, .18);
}
.score-ring b { font-size: 36px; line-height: 1; font-variant-numeric: tabular-nums; }
.score-ring span { font-size: 11.5px; opacity: .92; margin-top: 3px; }
.g-a { background: linear-gradient(135deg, #059669, #10b981); }
.g-b { background: linear-gradient(135deg, #2563eb, #3b82f6); }
.g-c { background: linear-gradient(135deg, #d97706, #f59e0b); }
.g-e { background: linear-gradient(135deg, #dc2626, #ef4444); }

.dimbar { margin-bottom: 9px; }
.dimbar .t { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 4px; }
.dimbar .t em { font-style: normal; color: var(--muted); font-size: 11.5px; }
.bar { height: 7px; background: #eef2f7; border-radius: 5px; overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, #2563eb, #60a5fa); }

/* ---------------- 代码块 ---------------- */
pre.code {
  background: #0f172a; color: #e2e8f0; border-radius: var(--radius-sm);
  padding: 14px 16px; font-family: var(--mono); font-size: 12.5px; line-height: 1.7;
  overflow: auto; max-height: 380px; margin: 0; white-space: pre;
}
pre.code.light {
  background: var(--surface-2); color: #0f172a; border: 1px solid var(--border);
}
.code-kw { color: #7dd3fc; }
.code-str { color: #86efac; }
.code-num { color: #fcd34d; }
.code-cmt { color: #64748b; font-style: italic; }

/* ---------------- 弹窗 ---------------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(15, 23, 42, .45);
  display: flex; align-items: center; justify-content: center; z-index: 100; padding: 24px;
  backdrop-filter: blur(2px);
}
.modal-mask[hidden] { display: none; }
.modal {
  background: var(--surface); border-radius: 14px; box-shadow: var(--shadow-lg);
  width: 100%; max-width: 620px; max-height: 86vh; overflow: auto;
}
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.modal-head h3 { margin: 0; font-size: 15.5px; }
.modal-body { padding: 20px; font-size: 13.5px; line-height: 1.85; color: var(--text-2); }
.modal-body h4 { color: var(--text); font-size: 13.5px; margin: 16px 0 6px; }
.modal-body ul { margin: 6px 0; padding-left: 20px; }
.modal-body b { color: var(--text); }
.modal-foot { padding: 14px 20px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 10px; }
.modal .x { border: none; background: transparent; font-size: 20px; color: var(--muted); cursor: pointer; line-height: 1; }

/* 顾问联系方式：二维码 + 微信/手机 */
.consult-contact { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.consult-qr {
  width: 132px; height: 132px; flex: none; object-fit: contain;
  background: #fff; padding: 6px; border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 6px 16px rgba(16, 24, 40, .08);
}
.consult-info { flex: 1; min-width: 180px; line-height: 2; }
.consult-info > div { font-size: 13.5px; }

/* ---------------- 账号与额度 ---------------- */
.quota-badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 999px;
  background: #eef4ff; color: #1d4ed8; border: 1px solid #cddffd;
  font-size: 12px; font-weight: 500; white-space: nowrap;
}
.quota-badge.low { background: #fff7ed; color: #b45309; border-color: #fed7aa; }
.quota-badge.pro { background: #ecfdf5; color: #047857; border-color: #a7f3d0; }
.quota-badge.out { background: #fef2f2; color: #b91c1c; border-color: #fecaca; }

.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 8px; }
.plan-card {
  border: 1px solid var(--border); border-radius: 10px; padding: 11px 12px;
  background: var(--surface); font-size: 12.5px; line-height: 1.65;
}
.plan-card.on { border-color: #93c5fd; background: #f5f9ff; box-shadow: 0 0 0 2px rgba(37, 99, 235, .10); }
.plan-card .pn { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.plan-card .pd { color: var(--muted); }

/* ---------------- Toast ---------------- */
.toast-wrap { position: fixed; right: 22px; bottom: 22px; z-index: 200; display: flex; flex-direction: column; gap: 8px; }
.toast {
  background: #0f172a; color: #f1f5f9; border-radius: var(--radius-sm);
  padding: 10px 16px; font-size: 13px; box-shadow: var(--shadow-lg);
  animation: tin .2s ease; max-width: 380px;
}
.toast.ok { background: #065f46; }
.toast.err { background: #991b1b; }
.toast.warn { background: #92400e; }
@keyframes tin { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------------- 其他 ---------------- */
.empty { text-align: center; color: var(--muted); padding: 40px 20px; font-size: 13px; }
.empty .ico { font-size: 30px; opacity: .35; display: block; margin-bottom: 10px; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); }
.fs12 { font-size: 12px; }
.fs13 { font-size: 13px; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; }
.mb8 { margin-bottom: 8px; } .mb12 { margin-bottom: 12px; }
.nowrap { white-space: nowrap; }
.divider { height: 1px; background: var(--border); margin: 16px 0; }
.sheet-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.sheet-tab {
  padding: 5px 13px; border-radius: 999px; font-size: 12.5px; cursor: pointer;
  background: #f1f5f9; color: var(--text-2); border: 1px solid transparent;
}
.sheet-tab:hover { color: var(--primary); }
.sheet-tab.on { background: var(--primary); color: #fff; font-weight: 600; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }

.site-foot {
  text-align: center; color: var(--muted); font-size: 12px;
  padding: 26px 20px 34px; border-top: 1px solid var(--border); background: var(--surface);
}
.site-foot .dot { margin: 0 8px; opacity: .5; }

@media (max-width: 1080px) {
  .grid-2, .grid-2.rev { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   数据模板（保存 / 复用）
   ============================================================ */
.tpl-banner {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  background: linear-gradient(135deg, #eef5ff, #f5f3ff);
  border: 1px solid #c7d7fe; border-radius: var(--radius);
  padding: 14px 18px; margin-bottom: 16px;
}
.tpl-banner.on { background: linear-gradient(135deg, #ecfdf5, #f0fdfa); border-color: #a7f3d0; }
.tpl-banner .tb-ico {
  width: 34px; height: 34px; flex: none; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; font-weight: 700; color: #fff; background: var(--primary);
}
.tpl-banner.on .tb-ico { background: var(--green); }
.tpl-banner .tb-body { flex: 1; min-width: 220px; }
.tpl-banner .tb-body > b { display: block; color: var(--text); font-size: 13.5px; margin-bottom: 3px; }
.tpl-banner .tb-body .fs12 { color: var(--text-2); }
.tpl-banner .tb-ops { display: flex; gap: 8px; flex-wrap: wrap; }

.tpl-list { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.tpl-item {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 14px; background: var(--surface);
}
.tpl-item.on { border-color: #a7f3d0; background: #f6fffb; }
.tpl-item .tpl-main { flex: 1; min-width: 200px; }
.tpl-item .tpl-name { font-size: 13.5px; font-weight: 600; color: var(--text); }
.tpl-item .tpl-desc { font-size: 12px; color: var(--text-2); margin-top: 3px; }
.tpl-item .tpl-meta { font-size: 12px; color: var(--muted); margin-top: 3px; }
.tpl-item .tpl-ops { display: flex; gap: 6px; flex-wrap: wrap; }
