/* ============================================================
   AuthX Design System
   ============================================================ */

:root {
  --brand: #2563eb;
  --brand-600: #1d4ed8;
  --brand-400: #3b82f6;
  --brand-soft: #e8f0fe;
  --accent: #0ea5e9;
  --ok: #0f9960;
  --ok-soft: #e7f6ef;
  --warn: #b45309;
  --warn-soft: #fef3e2;
  --danger: #dc2626;
  --danger-soft: #fdeceb;

  --bg: #f5f6fa;
  --bg-alt: #eceef5;
  --surface: #ffffff;
  --surface-2: #fafbfe;
  --border: #e6e8f0;
  --border-strong: #d6dae6;
  --text: #0f172a;
  --text-2: #475569;
  --muted: #8a93a6;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .05);
  --shadow: 0 6px 24px -12px rgba(15, 23, 42, .18);
  --shadow-lg: 0 24px 64px -28px rgba(15, 23, 42, .35);

  --sidebar-w: 232px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

[data-theme="dark"] {
  --brand: #60a5fa;
  --brand-600: #3b82f6;
  --brand-400: #93c5fd;
  --brand-soft: #16243d;
  --accent: #38bdf8;
  --ok: #34d399;
  --ok-soft: #10312a;
  --warn: #fbbf24;
  --warn-soft: #3a2c12;
  --danger: #f87171;
  --danger-soft: #3a1c1d;

  --bg: #0b0d14;
  --bg-alt: #11141d;
  --surface: #141824;
  --surface-2: #191e2c;
  --border: #252b3b;
  --border-strong: #313849;
  --text: #eef1f8;
  --text-2: #b3bccd;
  --muted: #7b8598;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 8px 28px -14px rgba(0, 0, 0, .8);
  --shadow-lg: 0 28px 70px -30px rgba(0, 0, 0, .9);
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: none; opacity: .85; }

h1, h2, h3, h4 { margin: 0; font-weight: 650; letter-spacing: -.01em; }

p { margin: 0; }

button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }

.hidden { display: none !important; }
.muted { color: var(--muted); }
.text-2 { color: var(--text-2); }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.mono { font-family: var(--mono); }
.grow { flex: 1; }
.row { display: flex; align-items: center; gap: 10px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 10px; }
.wrap { flex-wrap: wrap; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.f12 { font-size: 12px; } .f13 { font-size: 13px; } .f18 { font-size: 18px; }
.f24 { font-size: 24px; } .f34 { font-size: 34px; }

/* ---------- 布局 ---------- */

.container { width: min(1180px, 100% - 48px); margin: 0 auto; }

/* ---------- 导航 ---------- */

.nav {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(14px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; gap: 18px; height: 62px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 16px; color: var(--text); letter-spacing: -.02em; }
.brand-mark {
  width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(140deg, var(--brand), var(--accent));
  color: #fff; font-size: 14px; font-weight: 800; box-shadow: 0 6px 16px -8px var(--brand);
}
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a { padding: 7px 12px; border-radius: 8px; color: var(--text-2); font-size: 13.5px; font-weight: 500; }
.nav-links a:hover, .nav-links a.active { background: var(--brand-soft); color: var(--brand); }

/* ---------- 按钮 ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 16px; border-radius: 10px;
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  font-size: 13.5px; font-weight: 550; cursor: pointer; white-space: nowrap;
  transition: transform .12s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
}
.btn:hover { border-color: var(--brand-400); color: var(--brand); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn-primary {
  background: linear-gradient(135deg, var(--brand), var(--accent));
  border-color: transparent; color: #fff;
  box-shadow: 0 10px 22px -14px var(--brand);
}
.btn-primary:hover { color: #fff; filter: brightness(1.06); box-shadow: 0 14px 28px -14px var(--brand); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--bg-alt); color: var(--text); }
.btn-danger { background: var(--danger); border-color: transparent; color: #fff; }
.btn-danger:hover { color: #fff; filter: brightness(1.05); }
.btn-soft { background: var(--brand-soft); border-color: transparent; color: var(--brand); }
.btn-sm { height: 30px; padding: 0 11px; font-size: 12.5px; border-radius: 8px; }
.btn-xs { height: 26px; padding: 0 9px; font-size: 12px; border-radius: 7px; }
.btn-block { width: 100%; }
.btn-icon { width: 34px; height: 34px; padding: 0; border-radius: 9px; }

/* ---------- 表单 ---------- */

.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-size: 12.5px; font-weight: 550; color: var(--text-2); }
.label .req { color: var(--danger); margin-left: 2px; }
.hint { font-size: 11.5px; color: var(--muted); line-height: 1.55; }

.input, .select, .textarea {
  width: 100%; height: 38px; padding: 0 12px;
  border-radius: 10px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--text);
  outline: none; transition: border-color .15s, box-shadow .15s;
  font-size: 13.5px;
}
.textarea { height: auto; min-height: 86px; padding: 10px 12px; resize: vertical; line-height: 1.6; }
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--brand-400);
  box-shadow: 0 0 0 3.5px color-mix(in srgb, var(--brand) 14%, transparent);
}
.input::placeholder, .textarea::placeholder { color: var(--muted); }
.input:disabled, .select:disabled { background: var(--bg-alt); color: var(--muted); }
.select {
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M2 4.5 6 8.5 10 4.5' fill='none' stroke='%238a93a6' stroke-width='1.6' stroke-linecap='round'/></svg>");
  background-repeat: no-repeat; background-position: right 11px center; padding-right: 30px;
}
.input-group { display: flex; gap: 8px; }
.input-group .input { flex: 1; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }

.switch { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; }
.switch input { display: none; }
.switch .track {
  width: 38px; height: 22px; border-radius: 999px; background: var(--border-strong);
  position: relative; transition: background .18s;
}
.switch .track::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px;
  border-radius: 50%; background: #fff; transition: transform .18s; box-shadow: 0 1px 3px rgba(0,0,0,.25);
}
.switch input:checked + .track { background: var(--brand); }
.switch input:checked + .track::after { transform: translateX(16px); }
.switch span:last-child { font-size: 13px; color: var(--text-2); }

/* ---------- 卡片 ---------- */

.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.card-pad { padding: 20px; }
.card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.card-head h3 { font-size: 14.5px; }
.card-body { padding: 20px; }

/* ---------- 徽标 / 标签 ---------- */

.badge {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 8px; border-radius: 6px;
  font-size: 11.5px; font-weight: 600; letter-spacing: .01em;
  background: var(--bg-alt); color: var(--text-2); white-space: nowrap;
}
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-brand { background: var(--brand-soft); color: var(--brand); }
.badge-dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

.tag { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 5px; background: var(--bg-alt); font-size: 11px; color: var(--muted); }

/* ---------- 表格 ---------- */

.table-wrap { width: 100%; overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; font-size: 13px; }
table.table th {
  text-align: left; font-weight: 600; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase;
  color: var(--muted); padding: 10px 14px; background: var(--surface-2);
  border-bottom: 1px solid var(--border); white-space: nowrap;
}
table.table td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.table tbody tr:last-child td { border-bottom: none; }
table.table tbody tr:hover { background: var(--surface-2); }
table.table td.tight { padding-top: 8px; padding-bottom: 8px; }

/* ---------- 分页 ---------- */

.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--muted); }
.pager-btns { display: flex; gap: 6px; }

/* ---------- 弹窗 ---------- */

.overlay {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  background: rgba(9, 12, 20, .5); backdrop-filter: blur(3px); padding: 20px;
  animation: fade .16s ease;
}
.modal {
  width: min(560px, 100%); max-height: calc(100vh - 60px); overflow: auto;
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  box-shadow: var(--shadow-lg); animation: pop .18s cubic-bezier(.2,.8,.3,1);
}
.modal.lg { width: min(820px, 100%); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.modal-head h3 { font-size: 15px; }
.modal-body { padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 22px; border-top: 1px solid var(--border); background: var(--surface-2); }
.x-btn { border: none; background: transparent; color: var(--muted); cursor: pointer; font-size: 20px; line-height: 1; padding: 4px 6px; border-radius: 6px; }
.x-btn:hover { background: var(--bg-alt); color: var(--text); }

@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.985) } to { opacity: 1; transform: none } }

/* ---------- Toast ---------- */

#toasts { position: fixed; bottom: 22px; right: 22px; z-index: 200; display: flex; flex-direction: column-reverse; gap: 8px; align-items: flex-end; pointer-events: none; max-width: 92vw; }
.toast {
  display: flex; align-items: center; gap: 9px;
  padding: 10px 16px; border-radius: 10px; font-size: 13px; font-weight: 500;
  background: var(--surface); color: var(--text); border: 1px solid var(--border);
  box-shadow: var(--shadow); animation: toastIn .2s ease;
  max-width: 90vw;
}
.toast.ok { border-color: color-mix(in srgb, var(--ok) 40%, var(--border)); }
.toast.err { border-color: color-mix(in srgb, var(--danger) 45%, var(--border)); }
.toast .ico { width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; color: #fff; }
.toast.ok .ico { background: var(--ok); }
.toast.err .ico { background: var(--danger); }
.toast.info .ico { background: var(--brand); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-8px) } to { opacity: 1; transform: none } }

/* ---------- 空状态 ---------- */

.empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 44px 20px; color: var(--muted); text-align: center; }
.empty .ico { font-size: 26px; opacity: .5; }
.empty h4 { font-size: 14px; color: var(--text-2); font-weight: 600; }
.empty p { font-size: 12.5px; }

/* ---------- 认证页 ---------- */

.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1fr 480px; }
.auth-aside {
  position: relative; overflow: hidden; padding: 56px;
  background: radial-gradient(1000px 600px at 15% 10%, #2563eb 0%, #1e3a8a 45%, #0b1533 100%);
  color: #fff; display: flex; flex-direction: column; justify-content: space-between;
}
.auth-aside::after {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.16) 1px, transparent 1px);
  background-size: 22px 22px; opacity: .5; pointer-events: none;
}
.auth-aside h2 { font-size: 30px; line-height: 1.35; max-width: 460px; position: relative; }
.auth-aside p { color: rgba(255,255,255,.72); max-width: 420px; margin-top: 14px; font-size: 14px; position: relative; }
.auth-aside ul { list-style: none; padding: 0; margin: 26px 0 0; display: flex; flex-direction: column; gap: 12px; position: relative; }
.auth-aside li { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: rgba(255,255,255,.82); }
.auth-aside li b { color: #fff; font-weight: 600; }
.auth-aside .tick { width: 18px; height: 18px; border-radius: 50%; background: rgba(255,255,255,.16); display: grid; place-items: center; font-size: 10px; flex: none; margin-top: 3px; }
.auth-main { display: grid; place-items: center; padding: 40px 32px; background: var(--bg); }
.auth-card { width: 100%; max-width: 352px; }
.auth-card h1 { font-size: 23px; margin-bottom: 6px; }
.auth-card .sub { color: var(--muted); font-size: 13px; margin-bottom: 24px; }
.auth-switch { text-align: center; font-size: 12.5px; color: var(--muted); margin-top: 18px; }
.auth-switch a { color: var(--brand); font-weight: 550; }

/* ---------- 落地页 ---------- */

.hero { position: relative; overflow: hidden; padding: 84px 0 96px; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto -10%; height: 620px;
  background: radial-gradient(600px 320px at 22% 30%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 70%),
              radial-gradient(520px 300px at 78% 10%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 70%);
  pointer-events: none;
}
.hero-inner { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 11px;
  border-radius: 999px; background: var(--brand-soft); color: var(--brand);
  font-size: 11.5px; font-weight: 600; letter-spacing: .02em;
}
.hero h1 { font-size: 44px; line-height: 1.18; letter-spacing: -.035em; margin: 18px 0 16px; }
.hero h1 em { font-style: normal; background: linear-gradient(120deg, var(--brand), var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { font-size: 15px; color: var(--text-2); max-width: 520px; line-height: 1.75; }
.hero-actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.hero-meta { display: flex; gap: 26px; margin-top: 36px; flex-wrap: wrap; }
.hero-meta .n { font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.hero-meta .l { font-size: 11.5px; color: var(--muted); }

.code-card {
  border-radius: 16px; overflow: hidden; border: 1px solid var(--border);
  background: var(--surface); box-shadow: var(--shadow-lg);
}
.code-card .bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.code-card .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--border-strong); }
.code-card .bar span { margin-left: 8px; font-size: 11.5px; color: var(--muted); font-family: var(--mono); }
pre.code {
  margin: 0; padding: 18px 74px 18px 20px; overflow-x: auto;
  font-family: var(--mono); font-size: 12.3px; line-height: 1.85; color: var(--text-2);
  background: transparent;
}
pre.code .k { color: var(--accent); }
pre.code .s { color: var(--ok); }
pre.code .c { color: var(--muted); }
pre.code .f { color: var(--brand); }

.section { padding: 72px 0; }
.section-head { max-width: 620px; margin-bottom: 40px; }
.section-head h2 { font-size: 28px; letter-spacing: -.025em; }
.section-head p { color: var(--text-2); margin-top: 10px; font-size: 14px; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature { padding: 22px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); transition: transform .18s, box-shadow .18s, border-color .18s; }
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--border-strong); }
.feature .ico {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand); font-size: 16px; margin-bottom: 14px;
}
.feature h3 { font-size: 14.5px; margin-bottom: 6px; }
.feature p { font-size: 12.8px; color: var(--text-2); line-height: 1.7; }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; counter-reset: s; }
.step { position: relative; padding: 22px 20px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.step::before {
  counter-increment: s; content: "0" counter(s);
  font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--brand);
  display: inline-block; margin-bottom: 10px;
}
.step h4 { font-size: 13.5px; margin-bottom: 6px; }
.step p { font-size: 12.5px; color: var(--text-2); line-height: 1.65; }

.footer { border-top: 1px solid var(--border); padding: 30px 0 40px; color: var(--muted); font-size: 12.5px; }
.footer-inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }

/* ---------- 控制台骨架 ---------- */

.shell { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column;
  background: var(--surface); border-right: 1px solid var(--border); padding: 16px 12px;
}
.sidebar .brand { padding: 6px 8px 18px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; flex: 1; }
.side-group { font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 16px 10px 6px; }
.side-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 9px;
  color: var(--text-2); font-size: 13px; font-weight: 500; cursor: pointer; border: none; background: transparent; text-align: left; width: 100%;
  transition: background .14s, color .14s;
}
.side-item:hover { background: var(--bg-alt); color: var(--text); }
.side-item.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.side-item .ico { width: 16px; text-align: center; font-size: 13px; opacity: .9; }
.side-item .count { margin-left: auto; font-size: 11px; color: var(--muted); font-weight: 600; }
.side-foot { border-top: 1px solid var(--border); padding-top: 10px; margin-top: 10px; }
.user-chip { display: flex; align-items: center; gap: 9px; padding: 8px; border-radius: 9px; }
.user-chip:hover { background: var(--bg-alt); }
.avatar {
  width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center;
  background: linear-gradient(140deg, var(--brand), var(--accent)); color: #fff; font-size: 12px; font-weight: 700; flex: none;
}
.user-chip .meta { min-width: 0; }
.user-chip .meta b { display: block; font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-chip .meta span { display: block; font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 14px;
  height: 60px; padding: 0 24px; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--border);
}
.topbar h1 { font-size: 16px; }
.topbar .sub { font-size: 12px; color: var(--muted); }
.content { padding: 22px 24px 48px; display: flex; flex-direction: column; gap: 18px; }

/* ---------- KPI ---------- */

.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.kpi { padding: 16px 18px; border-radius: 13px; background: var(--surface); border: 1px solid var(--border); }
.kpi .k-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kpi .k-label { font-size: 12px; color: var(--muted); font-weight: 500; }
.kpi .k-val { font-size: 26px; font-weight: 700; letter-spacing: -.03em; margin-top: 6px; line-height: 1.1; }
.kpi .k-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.kpi .k-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); font-size: 13px; }

/* ---------- 图表 ---------- */

.chart-wrap { padding: 8px 4px 0; }
.chart-legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); }
.chart-legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }

/* ---------- 卡密展示 ---------- */

.key-list { display: flex; flex-direction: column; gap: 6px; max-height: 320px; overflow: auto; background: var(--bg-alt); border-radius: 10px; padding: 12px; border: 1px solid var(--border); }
.key-list code { font-family: var(--mono); font-size: 12.5px; letter-spacing: .4px; color: var(--text); }

/* ---------- 界面切换 ---------- */

.tabs { display: flex; gap: 4px; padding: 4px; background: var(--bg-alt); border-radius: 10px; width: fit-content; }
.tab { padding: 6px 14px; border-radius: 7px; font-size: 12.5px; font-weight: 550; color: var(--text-2); cursor: pointer; border: none; background: transparent; }
.tab.active { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: 9px; overflow: hidden; }
.seg button { border: none; background: var(--surface); padding: 0 12px; height: 32px; font-size: 12.5px; color: var(--text-2); cursor: pointer; }
.seg button + button { border-left: 1px solid var(--border); }
.seg button.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }

/* ---------- 文档 ---------- */

.doc-layout { display: grid; grid-template-columns: 210px 1fr; gap: 40px; padding: 34px 0 80px; }
.doc-nav { position: sticky; top: 86px; align-self: start; display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.doc-nav a { padding: 6px 10px; border-radius: 7px; color: var(--text-2); }
.doc-nav a:hover { background: var(--bg-alt); color: var(--text); }
.doc-nav .g { font-size: 11px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 700; padding: 12px 10px 4px; }
.doc-body { max-width: 780px; }
.doc-body h2 { font-size: 22px; margin: 36px 0 12px; padding-top: 8px; letter-spacing: -.02em; }
.doc-body h2:first-child { margin-top: 0; }
.doc-body h3 { font-size: 15px; margin: 24px 0 8px; }
.doc-body p { color: var(--text-2); font-size: 13.5px; line-height: 1.8; margin: 8px 0; }
.doc-body ul { color: var(--text-2); font-size: 13.5px; line-height: 1.9; padding-left: 20px; }
.doc-body code:not(pre code) {
  font-family: var(--mono); font-size: 12px; padding: 2px 6px; border-radius: 5px;
  background: var(--brand-soft); color: var(--brand);
}
.doc-body pre { border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.endpoint { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); margin: 8px 0; font-family: var(--mono); font-size: 12.5px; }
.method { font-weight: 700; font-size: 11px; padding: 2px 7px; border-radius: 5px; letter-spacing: .03em; }
.method.get { background: var(--ok-soft); color: var(--ok); }
.method.post { background: var(--brand-soft); color: var(--brand); }

/* ---------- 响应式 ---------- */

@media (max-width: 1080px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
  .doc-layout { grid-template-columns: 1fr; gap: 20px; }
  .doc-nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .doc-nav .g { display: none; }
}

@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; z-index: 60; inset: 0 auto 0 0; width: 260px; transform: translateX(-100%);
    transition: transform .22s ease; box-shadow: var(--shadow-lg);
  }
  .sidebar.open { transform: none; }
  .sidebar-backdrop { position: fixed; inset: 0; background: rgba(9,12,20,.45); z-index: 55; }
  .hero h1 { font-size: 33px; }
  .feature-grid, .steps { grid-template-columns: 1fr; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .content { padding: 16px 14px 40px; }
  .topbar { padding: 0 14px; }
  .container { width: min(1180px, 100% - 28px); }
  .nav-links { display: none; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   补充：图标 / 提示 / 交互细节
   ============================================================ */

.svg-ico { vertical-align: -2.5px; flex: none; }
.side-item .svg-ico { opacity: .85; }
.brand-mark .svg-ico { color: #fff; }

.side-item .count:empty { display: none; }

/* 移动端菜单按钮 */
#btn-sidebar { display: none; }
@media (max-width: 860px) {
  #btn-sidebar { display: inline-flex; }
}

/* 让侧边栏遮罩可点关闭 */
.sidebar-backdrop { display: none; }
@media (max-width: 860px) { .sidebar-backdrop.on { display: block; } }

/* 表格内的小操作组 */
.actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }

/* 审计详情行 */
tr.detail-row > td { background: var(--surface-2); color: var(--text-2); }
tr.detail-row pre {
  margin: 0; font-family: var(--mono); font-size: 11.5px; line-height: 1.7;
  white-space: pre-wrap; word-break: break-all; color: var(--text-2);
}

/* 键值列表 */
.kv { display: grid; grid-template-columns: 96px 1fr; gap: 8px 12px; font-size: 13px; }
.kv dt { color: var(--muted); font-size: 12.5px; }
.kv dd { margin: 0; color: var(--text); word-break: break-all; }

/* 分段控件容器 */
.seg-wrap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* 可点击行 */
tr[data-click] { cursor: pointer; }

/* 卡密结果列表 */
.keys-out { display: flex; flex-direction: column; gap: 4px; max-height: 300px; overflow: auto; padding: 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-alt); }
.keys-out code { font-family: var(--mono); font-size: 12.5px; letter-spacing: .4px; }

/* 设置分组 */
.set-group { border-top: 1px solid var(--border); padding-top: 16px; margin-top: 4px; }
.set-group:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.set-group h4 { font-size: 13px; margin-bottom: 12px; color: var(--text-2); }

/* 列表页筛选栏 */
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.filters > .field { flex: 0 0 auto; }
.filters .actions-right { margin-left: auto; display: flex; gap: 8px; }

/* 品牌 LOGO（内联 SVG，跟随主题色） */
.brand-logo { flex: none; display: block; }
.brand { gap: 8px; }
.brand-mark { display: none; }

/* 常见问题折叠 */
.faq {
  border: 1px solid var(--border); border-radius: 12px; background: var(--surface);
  padding: 0 18px; box-shadow: var(--shadow-sm);
}
.faq + .faq { margin-top: 8px; }
.faq summary {
  cursor: pointer; padding: 15px 0; font-weight: 600; font-size: 13.5px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 16px; }
.faq[open] summary::after { content: "−"; }
.faq p { padding: 0 0 15px; color: var(--text-2); font-size: 13px; line-height: 1.8; }

/* 概览页「运行状态」指标格 */
.health-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
@media (max-width: 1080px) { .health-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .health-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .health-grid { grid-template-columns: 1fr; } }
.health-grid > .hint { grid-column: 1 / -1; }
.h-cell {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  background: var(--bg-alt);
}
.h-k { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.h-v { font-size: 15px; font-weight: 600; color: var(--text); letter-spacing: .2px; }
.h-v.warn { color: var(--danger); }
.h-v.alert { color: var(--warn, #d97706); }

/* 动作编辑器的代码区 */
.modal textarea[name="code"] { min-height: 190px; tab-size: 2; }

/* 开发者页：AI 提示词卡片 */
.ai-box {
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: linear-gradient(180deg, var(--brand-soft), transparent 70%);
}
.ai-box pre.code { background: var(--bg-alt); }

/* ============================================================
   营销页（首页 / 开发者页）
   ============================================================ */

.btn-lg { height: 44px; padding: 0 22px; font-size: 14.5px; border-radius: 11px; }

.lp-hero { padding: 76px 0 84px; }

/* 首屏右侧的“授权状态”演示卡 */
.lp-mock {
  border-radius: 18px; border: 1px solid var(--border); background: var(--surface);
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.lp-mock-head {
  display: flex; align-items: center; gap: 8px; padding: 12px 16px;
  border-bottom: 1px solid var(--border); background: var(--surface-2);
  font-size: 12.5px; font-weight: 600; color: var(--text-2);
}
.lp-mock-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 18%, transparent); }
.lp-mock-head .lp-pill { margin-left: auto; }
.lp-pill {
  display: inline-flex; align-items: center; height: 21px; padding: 0 8px; border-radius: 999px;
  background: var(--bg-alt); color: var(--muted); font-size: 11px; font-weight: 600;
}
.lp-pill.ok { background: var(--ok-soft); color: var(--ok); }

.lp-mock-plan { padding: 20px 18px 16px; }
.lp-mock-name { font-size: 17px; font-weight: 700; letter-spacing: -.02em; }
.lp-mock-sub { font-size: 12.5px; color: var(--muted); margin-top: 3px; }
.lp-bar { height: 7px; border-radius: 999px; background: var(--bg-alt); margin: 16px 0 8px; overflow: hidden; }
.lp-bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--brand), var(--accent)); }
.lp-mock-meta { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); }

.lp-mock-list { padding: 6px 10px 10px; display: flex; flex-direction: column; gap: 4px; }
.lp-mock-row {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px;
  font-size: 12.8px; color: var(--text-2);
}
.lp-mock-row:nth-child(odd) { background: var(--surface-2); }
.lp-mock-row .lp-pill { margin-left: auto; }
.lp-ico {
  width: 24px; height: 24px; border-radius: 7px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand); font-size: 11px; font-weight: 700; flex: none;
}
.lp-mock-foot {
  padding: 11px 16px; border-top: 1px solid var(--border); background: var(--surface-2);
  font-size: 11.5px; color: var(--muted); text-align: center;
}

/* 首屏信任条 */
.lp-trust { list-style: none; display: flex; gap: 18px; flex-wrap: wrap; margin: 22px 0 0; padding: 0; }
.lp-trust li { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-2); }
.lp-tick {
  width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: var(--ok-soft); color: var(--ok); font-size: 10px; font-weight: 700;
}

.lp-sec-tight { padding: 24px 0 8px; }

/* L.Box 生态横幅 */
.lp-band {
  display: grid; grid-template-columns: 1fr auto; gap: 36px; align-items: center;
  padding: 40px 42px; border-radius: 20px; color: #eef2ff;
  background: radial-gradient(680px 300px at 12% 0%, #1e3a8a 0%, transparent 60%),
              radial-gradient(520px 260px at 92% 100%, #0e7490 0%, transparent 62%),
              linear-gradient(135deg, #0f172a, #16233c);
  box-shadow: var(--shadow-lg);
}
.lp-band-tag {
  display: inline-flex; align-items: center; height: 23px; padding: 0 10px; border-radius: 999px;
  background: rgba(255, 255, 255, .12); color: #c7d2fe; font-size: 11.5px; font-weight: 600; letter-spacing: .03em;
}
.lp-band h2 { font-size: 26px; margin: 14px 0 10px; letter-spacing: -.025em; color: #fff; }
.lp-band p { color: rgba(226, 232, 255, .78); font-size: 13.5px; line-height: 1.8; max-width: 560px; }
.lp-band-list { list-style: none; padding: 0; margin: 16px 0 0; display: flex; flex-direction: column; gap: 8px; }
.lp-band-list li { position: relative; padding-left: 18px; font-size: 13px; color: rgba(226, 232, 255, .85); }
.lp-band-list li::before {
  content: ""; position: absolute; left: 2px; top: 8px; width: 6px; height: 6px; border-radius: 2px;
  background: linear-gradient(135deg, #60a5fa, #22d3ee);
}
.lp-band-list b { color: #fff; font-weight: 600; }
.lp-band-cta { text-align: center; }
.btn-on-dark {
  background: #fff; color: #0f172a; border-color: transparent; font-weight: 600;
  box-shadow: 0 14px 30px -16px rgba(0, 0, 0, .8);
}
.btn-on-dark:hover { color: #0f172a; filter: brightness(.96); }
.lp-band-hint { margin-top: 10px; font-size: 11.5px; color: rgba(199, 210, 254, .6); font-family: var(--mono); }

/* 价格 */
.lp-plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: stretch; }
.plan {
  position: relative; display: flex; flex-direction: column; gap: 14px;
  padding: 26px 24px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border);
}
.plan.recommend { border-color: color-mix(in srgb, var(--brand) 45%, var(--border)); box-shadow: 0 20px 50px -30px var(--brand); }
.plan-badge {
  position: absolute; top: -10px; left: 24px; height: 21px; padding: 0 9px; border-radius: 999px;
  display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--accent));
}
.plan-name { font-size: 13.5px; font-weight: 650; color: var(--text-2); }
.plan-price { display: flex; align-items: baseline; gap: 8px; }
.plan-price b { font-size: 26px; letter-spacing: -.03em; }
.plan-price span { font-size: 12px; color: var(--muted); }
.plan ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.plan ul li { position: relative; padding-left: 20px; font-size: 13px; color: var(--text-2); line-height: 1.6; }
.plan ul li::before {
  content: "✓"; position: absolute; left: 0; top: 0; font-size: 11px; font-weight: 700; color: var(--brand);
}
.lp-plans-note { text-align: center; color: var(--muted); font-size: 12px; margin-top: 18px; }

/* FAQ 与激活卡 */
.lp-faq { max-width: 780px; }
.lp-redeem { max-width: 720px; margin: 0 auto; }

@media (max-width: 1080px) {
  .lp-band { grid-template-columns: 1fr; gap: 24px; padding: 32px 26px; }
  .lp-band-cta { text-align: left; }
  .lp-plans { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .lp-hero { padding: 44px 0 52px; }
  .hero h1 { font-size: 32px; }
  .lp-trust { gap: 10px 16px; }
  .lp-band h2 { font-size: 21px; }
}

/* 开发者页：邮箱与清单 */
.lp-mail {
  display: inline-flex; align-items: center; margin-top: 14px; padding: 7px 13px; border-radius: 9px;
  background: var(--surface-2); border: 1px dashed var(--border-strong);
  font-family: var(--mono); font-size: 13px; color: var(--text-2);
}
.lp-todo { display: flex; align-items: flex-start; gap: 11px; }
.lp-todo b { font-size: 13.5px; font-weight: 600; }
.lp-todo .hint { margin-top: 1px; }
.lp-todo .lp-ico { margin-top: 1px; }

/* 后台「开发文档」 */
.docs-head { margin-bottom: 14px; }
.docs-intro {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px; margin-bottom: 18px;
}
.docs-kv {
  padding: 11px 14px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2);
}
.docs-kv span { display: block; font-size: 11.5px; color: var(--muted); }
.docs-kv b { display: block; font-size: 13.5px; font-weight: 600; margin-top: 3px; word-break: break-all; }
.docs-kv i { display: block; font-style: normal; font-size: 11.5px; color: var(--muted); margin-top: 2px; }

.doc-block { margin-bottom: 20px; }
.doc-block-title { font-size: 13.5px; font-weight: 650; margin-bottom: 4px; }
.doc-block pre.code {
  margin-top: 10px; max-height: 460px; overflow: auto;
  border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2);
  padding: 16px 18px; font-size: 12.2px; line-height: 1.8;
}
.docs-body > pre.code {
  border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2);
  padding: 16px 18px; max-height: 620px; overflow: auto;
}
.docs-steps { margin: 8px 0 0; padding-left: 20px; color: var(--text-2); font-size: 13.5px; line-height: 1.9; }
.docs-steps code, .docs-list code {
  font-family: var(--mono); font-size: 12px; padding: 2px 6px; border-radius: 5px;
  background: var(--brand-soft); color: var(--brand);
}
.docs-list { margin: 8px 0 0; padding-left: 20px; color: var(--text-2); font-size: 13.5px; line-height: 1.9; }
.docs-list b { color: var(--text); }

/* 首页四张能力卡在一行；窄屏自动降为 2 列 / 1 列 */
@media (min-width: 1081px) {
  .lp .feature-grid { grid-template-columns: repeat(4, 1fr); }
}
.lp .feature .ico { font-size: 18px; line-height: 1; }

/* 审计日志：中文动作名 */
.audit-act { font-size: 13px; color: var(--text); cursor: help; }

/* ============================================================
   统一设计系统 v2（L.Auth 1.4）
   目的：首页 / 开发者页 / 后台文档 / 文案编辑 四套界面共用同一套
        间距、卡片、图标、标题规格，消除"拼接感"。
   ============================================================ */

:root {
  --r-card: 14px;
  --r-tile: 14px;
  --sec-y: 76px;
  --gap: 16px;
}

/* ---------- 区块与标题 ---------- */

.s2 { padding: var(--sec-y) 0; position: relative; }
.s2-tight { padding: 28px 0; }
.s2-head { max-width: 640px; margin-bottom: 30px; }
.s2-eyebrow {
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px;
  font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--brand);
}
.s2-eyebrow::before { content: ""; width: 14px; height: 2px; border-radius: 2px; background: currentColor; }
.s2-head h2 { font-size: 27px; letter-spacing: -.028em; line-height: 1.28; }
.s2-head p { margin-top: 9px; color: var(--text-2); font-size: 14px; line-height: 1.75; }
.s2-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- 卡片 ---------- */

.t3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.t2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap); }
.t4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }

.tile {
  display: flex; flex-direction: column; gap: 12px;
  padding: 24px; border-radius: var(--r-tile);
  background: var(--surface); border: 1px solid var(--border);
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.tile:hover { border-color: var(--border-strong); box-shadow: var(--shadow); transform: translateY(-2px); }
.tile h3 { font-size: 14.5px; letter-spacing: -.01em; }
.tile p { font-size: 13px; color: var(--text-2); line-height: 1.72; }
.tile-ico {
  width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand); flex: none;
}
.tile-ico svg { width: 19px; height: 19px; stroke: currentColor; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.tile-line { margin-top: auto; padding-top: 4px; font-size: 12px; color: var(--muted); }

/* ---------- 首屏 ---------- */

.hero2 { padding: 68px 0 60px; position: relative; overflow: hidden; }
.hero2::before {
  content: ""; position: absolute; inset: -30% -10% auto -10%; height: 560px; pointer-events: none;
  background:
    radial-gradient(560px 300px at 20% 26%, color-mix(in srgb, var(--brand) 16%, transparent), transparent 70%),
    radial-gradient(460px 260px at 82% 6%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%);
}
.hero2-grid { position: relative; display: grid; grid-template-columns: 1.04fr .96fr; gap: 52px; align-items: center; }
.hero2 h1 { font-size: 42px; line-height: 1.16; letter-spacing: -.035em; margin: 16px 0 14px; }
.hero2 h1 em { font-style: normal; background: linear-gradient(120deg, var(--brand), var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero2 .lead { font-size: 14.5px; color: var(--text-2); line-height: 1.78; max-width: 500px; }
.hero2-actions { display: flex; gap: 10px; margin-top: 24px; flex-wrap: wrap; }
.hero2-note { margin-top: 14px; font-size: 12px; color: var(--muted); }

/* 首屏三点 */
.points { display: flex; gap: 18px; flex-wrap: wrap; margin: 22px 0 0; padding: 0; list-style: none; }
.points li { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-2); }
.points svg { width: 15px; height: 15px; stroke: var(--ok); fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* 演示卡 */
.mock2 {
  border-radius: 16px; border: 1px solid var(--border); background: var(--surface);
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.mock2-bar {
  display: flex; align-items: center; gap: 8px; padding: 11px 15px;
  border-bottom: 1px solid var(--border); background: var(--surface-2);
  font-size: 12.5px; font-weight: 600; color: var(--text-2);
}
.mock2-body { padding: 18px 16px 8px; }
.mock2-plan { display: flex; align-items: baseline; justify-content: space-between; }
.mock2-plan b { font-size: 16.5px; letter-spacing: -.02em; }
.mock2-plan span { font-size: 12px; color: var(--muted); }
.mock2-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.mock2-meter { height: 6px; border-radius: 999px; background: var(--bg-alt); margin: 14px 0 7px; overflow: hidden; }
.mock2-meter i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--brand), var(--accent)); }
.mock2-meta { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); }
.mock2-rows { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 3px; }
.mock2-row { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 9px; font-size: 12.8px; color: var(--text-2); }
.mock2-row:nth-child(odd) { background: var(--surface-2); }
.mock2-row .dot-ico {
  width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; flex: none;
  background: var(--brand-soft); color: var(--brand); font-size: 10.5px; font-weight: 700;
}
.mock2-row .st { margin-left: auto; font-size: 11px; font-weight: 600; color: var(--ok); }
.mock2-row .st.free { color: var(--muted); }

/* ---------- 价格 ---------- */

.pcard {
  position: relative; display: flex; flex-direction: column; gap: 14px;
  padding: 26px 24px; border-radius: var(--r-card);
  background: var(--surface); border: 1px solid var(--border);
}
.pcard.hi { border-color: color-mix(in srgb, var(--brand) 42%, var(--border)); box-shadow: 0 18px 44px -30px var(--brand); }
.pcard-tag {
  position: absolute; top: -10px; left: 24px; height: 20px; padding: 0 9px; border-radius: 999px;
  display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--accent));
}
.pcard-name { font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--text-2); }
.pcard-price { display: flex; align-items: baseline; gap: 7px; }
.pcard-price b { font-size: 25px; letter-spacing: -.03em; }
.pcard-price span { font-size: 12px; color: var(--muted); }
.pcard ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.pcard li { position: relative; padding-left: 19px; font-size: 12.8px; color: var(--text-2); line-height: 1.6; }
.pcard li::before {
  content: ""; position: absolute; left: 2px; top: 7px; width: 8px; height: 8px; border-radius: 3px;
  background: var(--brand-soft); border: 1.5px solid var(--brand);
}
.pcard-note { text-align: center; font-size: 12px; color: var(--muted); margin-top: 16px; }

/* ---------- 深色横幅（统一版） ---------- */

.band2 {
  position: relative; overflow: hidden; border-radius: var(--r-card);
  padding: 34px 36px; color: #e8eeff;
  background: linear-gradient(135deg, #0d1526, #16233c 55%, #10283a);
  display: grid; grid-template-columns: 1fr auto; gap: 30px; align-items: center;
}
.band2::after {
  content: ""; position: absolute; right: -60px; top: -80px; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(circle, rgba(59, 130, 246, .35), transparent 65%); pointer-events: none;
}
.band2 h2 { font-size: 22px; color: #fff; letter-spacing: -.02em; }
.band2 p { margin-top: 8px; font-size: 13px; line-height: 1.8; color: rgba(226, 232, 255, .74); max-width: 560px; }
.band2 .band2-list { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-direction: column; gap: 7px; }
.band2 .band2-list li { position: relative; padding-left: 16px; font-size: 12.8px; color: rgba(226, 232, 255, .82); }
.band2 .band2-list li::before { content: ""; position: absolute; left: 2px; top: 8px; width: 6px; height: 6px; border-radius: 2px; background: #60a5fa; }
.band2 .band2-list b { color: #fff; }
.band2-cta { text-align: center; position: relative; z-index: 1; }
.band2-hint { margin-top: 9px; font-size: 11.5px; color: rgba(199, 210, 254, .55); font-family: var(--mono); }

/* ---------- 步进 ---------- */

.steps2 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); counter-reset: st; }
.steps2 .step2 {
  position: relative; padding: 22px 22px 20px; border-radius: var(--r-tile);
  background: var(--surface); border: 1px solid var(--border);
}
.steps2 .step2::before {
  counter-increment: st; content: counter(st);
  display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; margin-bottom: 12px;
  background: var(--brand-soft); color: var(--brand); font-size: 12px; font-weight: 700; font-family: var(--mono);
}
.steps2 h4 { font-size: 13.5px; margin-bottom: 5px; }
.steps2 p { font-size: 12.8px; color: var(--text-2); line-height: 1.7; }

/* ---------- 对比表（两种合作模式） ---------- */

.cmp {
  display: grid; grid-template-columns: 1.1fr 1fr 1fr; border: 1px solid var(--border);
  border-radius: var(--r-card); overflow: hidden; background: var(--surface);
}
.cmp > div { padding: 15px 18px; font-size: 13px; border-bottom: 1px solid var(--border); }
.cmp > div:nth-last-child(-n+3) { border-bottom: 0; }
.cmp .cmp-h { background: var(--surface-2); font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.cmp .cmp-k { font-weight: 600; color: var(--text); background: var(--surface-2); }
.cmp .cmp-strong { color: var(--ok); font-weight: 650; }
.cmp .cmp-mid { font-size: 12.5px; color: var(--text-2); line-height: 1.65; }

/* ---------- 文档页（左侧目录 + 右侧内容） ---------- */

.docs2 { display: grid; grid-template-columns: 196px 1fr; gap: 26px; align-items: start; }
.docs2-nav { position: sticky; top: 74px; display: flex; flex-direction: column; gap: 2px; }
.docs2-nav button {
  text-align: left; padding: 8px 12px; border: 0; border-radius: 8px; background: transparent;
  color: var(--text-2); font-size: 13px; cursor: pointer; font-family: inherit;
}
.docs2-nav button:hover { background: var(--bg-alt); color: var(--text); }
.docs2-nav button.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.doc-group {
  margin: 14px 12px 4px; font-size: 10.5px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--muted);
}
.doc-group:first-of-type { margin-top: 4px; }
.doc-ver {
  margin: 14px 12px 0; padding: 10px 12px; border-radius: 9px; background: var(--surface-2);
  font-size: 11px; line-height: 1.7; color: var(--muted); border: 1px solid var(--border);
}
.doc-ver br { display: block; }
.docs2-main { min-width: 0; }
.docs2-h { font-size: 19px; letter-spacing: -.02em; margin-bottom: 6px; }
.docs2-p { color: var(--text-2); font-size: 13px; line-height: 1.75; margin-bottom: 18px; }

.cb { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--surface); margin: 12px 0 20px; }
.cb-bar {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 14px;
  background: var(--surface-2); border-bottom: 1px solid var(--border);
}
.cb-bar b { font-size: 12px; font-weight: 600; color: var(--text-2); }
.cb-bar .cb-actions { margin-left: auto; display: flex; gap: 6px; }
.cb pre { margin: 0; padding: 15px 16px; overflow: auto; max-height: 420px; font-family: var(--mono); font-size: 12.3px; line-height: 1.8; color: var(--text-2); }

.kv2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; margin-bottom: 18px; }
.kv2 > div { padding: 12px 14px; border-radius: 11px; border: 1px solid var(--border); background: var(--surface-2); }
.kv2 span { display: block; font-size: 11.5px; color: var(--muted); }
.kv2 b { display: block; margin-top: 3px; font-size: 13.5px; word-break: break-all; }
.kv2 i { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--muted); }

.note2 {
  display: flex; gap: 10px; padding: 12px 14px; border-radius: 11px; margin: 12px 0 18px;
  background: var(--warn-soft); color: var(--warn); font-size: 12.8px; line-height: 1.7;
}
.note2.ok { background: var(--ok-soft); color: var(--ok); }

/* ---------- 文案编辑 ---------- */

.txt2 { display: grid; grid-template-columns: 168px 1fr; gap: 22px; align-items: start; }
.txt2-nav { position: sticky; top: 74px; display: flex; flex-direction: column; gap: 2px; }
.txt2-nav button {
  text-align: left; padding: 8px 12px; border: 0; border-radius: 8px; background: transparent;
  color: var(--text-2); font-size: 13px; cursor: pointer; font-family: inherit; display: flex; gap: 8px;
}
.txt2-nav button:hover { background: var(--bg-alt); }
.txt2-nav button.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.txt2-nav .cnt { margin-left: auto; font-size: 11px; color: var(--muted); }
.txt2-list { display: flex; flex-direction: column; gap: 14px; }
.txt2-item { padding: 14px 16px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.txt2-item .top { display: flex; align-items: center; gap: 8px; margin-bottom: 7px; }
.txt2-item .top .lab { font-size: 12.5px; font-weight: 600; }
.txt2-item textarea { width: 100%; }
.txt2-item .foot { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.txt2-savebar {
  position: sticky; bottom: 0; z-index: 5; margin-top: 16px;
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(10px); border: 1px solid var(--border); border-radius: 12px;
}

@media (max-width: 1080px) {
  .hero2-grid { grid-template-columns: 1fr; gap: 36px; }
  .t3, .t4 { grid-template-columns: repeat(2, 1fr); }
  .steps2 { grid-template-columns: 1fr; }
  .band2 { grid-template-columns: 1fr; padding: 28px 24px; }
  .band2-cta { text-align: left; }
  .docs2, .txt2 { grid-template-columns: 1fr; }
  .docs2-nav, .txt2-nav { position: static; flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 720px) {
  :root { --sec-y: 52px; }
  .hero2 { padding: 40px 0 36px; }
  .hero2 h1 { font-size: 31px; }
  .t3, .t4, .t2 { grid-template-columns: 1fr; }
  .cmp { grid-template-columns: 1fr; }
  .cmp > div { border-bottom: 1px solid var(--border) !important; }
  .s2-head h2 { font-size: 22px; }
}

/* 四步流程 */
.steps2.four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1080px) { .steps2.four { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .steps2.four { grid-template-columns: 1fr; } }

/* 文案编辑器：更紧凑，宽屏两列 */
.txt2-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.txt2-item { padding: 12px 14px; }
.txt2-item textarea { min-height: 42px; height: auto; resize: vertical; font-size: 12.8px; line-height: 1.65; }
.txt2-item .top { margin-bottom: 6px; }
.txt2-item .top .lab { font-size: 12.5px; font-weight: 600; color: var(--text); }
.txt2-item .df { font-size: 11.5px; color: var(--muted); margin-top: 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 1180px) { .txt2-list { grid-template-columns: 1fr; } }

/* 提示条改成块级，避免 flex 把「标题+正文」拆成两列 */
.note2 { display: block; border-left: 3px solid currentColor; }

/* 分组整块排布：标题通栏，条目两列 */
.txt2-list { display: block; }
.txt2-group { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.txt2-group > .hint { grid-column: 1 / -1; }
@media (max-width: 1180px) { .txt2-group { grid-template-columns: 1fr; } }

/* ============================================================
   公告 / FAQ / 流程 —— 重做视觉
   ============================================================ */

/* 公告卡片 */
.notice-card {
  display: grid; grid-template-columns: 104px 1fr; gap: 18px; align-items: start;
  padding: 16px 18px; border-radius: 12px; background: var(--surface);
  border: 1px solid var(--border); border-left: 3px solid var(--brand);
  transition: border-color .18s, box-shadow .18s;
}
.notice-card:hover { box-shadow: var(--shadow); }
.notice-card[data-level="danger"] { border-left-color: var(--danger); }
.notice-card[data-level="warning"] { border-left-color: var(--warn); }
.notice-card[data-level="success"] { border-left-color: var(--ok); }

.notice-side { display: flex; flex-direction: column; gap: 4px; padding-top: 1px; }
.notice-tag {
  display: inline-flex; align-items: center; justify-content: center; align-self: flex-start;
  height: 21px; padding: 0 9px; border-radius: 6px; font-size: 11px; font-weight: 700;
  background: var(--brand-soft); color: var(--brand); letter-spacing: .02em;
}
.notice-card[data-level="danger"] .notice-tag { background: var(--danger-soft); color: var(--danger); }
.notice-card[data-level="warning"] .notice-tag { background: var(--warn-soft); color: var(--warn); }
.notice-card[data-level="success"] .notice-tag { background: var(--ok-soft); color: var(--ok); }
.notice-date { font-size: 11px; color: var(--muted); font-family: var(--mono); }

.notice-main h3 { font-size: 14px; font-weight: 650; letter-spacing: -.01em; }
.notice-main p { margin-top: 6px; font-size: 13px; color: var(--text-2); line-height: 1.78; white-space: pre-wrap; }

.notice-popup-body { font-size: 13.5px; color: var(--text-2); line-height: 1.85; white-space: pre-wrap; }

/* FAQ 手风琴 */
.lp-faq { display: flex; flex-direction: column; gap: 10px; max-width: 100%; }
details.faq {
  border: 1px solid var(--border); border-radius: 12px; background: var(--surface);
  padding: 0 18px; transition: border-color .18s, box-shadow .18s, background .18s;
}
details.faq:hover { border-color: var(--border-strong); }
details.faq[open] {
  border-color: color-mix(in srgb, var(--brand) 34%, var(--border));
  box-shadow: 0 10px 30px -24px var(--brand);
}
details.faq summary {
  list-style: none; cursor: pointer; position: relative;
  padding: 15px 34px 15px 0; font-size: 14px; font-weight: 600; color: var(--text);
  line-height: 1.55;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: ""; position: absolute; right: 6px; top: 50%; width: 7px; height: 7px;
  border-right: 1.8px solid var(--muted); border-bottom: 1.8px solid var(--muted);
  transform: translateY(-70%) rotate(45deg); transition: transform .2s, border-color .2s;
}
details.faq[open] summary { color: var(--brand); }
details.faq[open] summary::after { transform: translateY(-30%) rotate(-135deg); border-color: var(--brand); }
details.faq p {
  margin: 0; padding: 0 34px 16px 0; font-size: 13.3px; color: var(--text-2); line-height: 1.85;
}

/* 三步 / 四步：加连接线，视觉上连成一条流程 */
.steps2 { position: relative; }
.steps2 .step2 { transition: border-color .18s, box-shadow .18s, transform .18s; }
.steps2 .step2:hover { border-color: var(--border-strong); box-shadow: var(--shadow); transform: translateY(-2px); }
.steps2 .step2::before {
  width: 28px; height: 28px; border-radius: 9px; font-size: 12.5px;
  background: linear-gradient(140deg, var(--brand), var(--accent)); color: #fff;
  box-shadow: 0 8px 18px -12px var(--brand);
}
.steps2 .step2::after {
  content: ""; position: absolute; left: 46px; top: 36px; right: -16px; height: 1px;
  background: repeating-linear-gradient(90deg, var(--border-strong) 0 5px, transparent 5px 10px);
}
.steps2 .step2:last-child::after { display: none; }

@media (max-width: 1080px) {
  .steps2 .step2::after { display: none; }
}
@media (max-width: 720px) {
  .notice-card { grid-template-columns: 1fr; gap: 8px; padding: 14px 15px; }
  .notice-side { flex-direction: row; align-items: center; gap: 8px; }
  details.faq { padding: 0 14px; }
  details.faq summary { padding: 13px 30px 13px 0; font-size: 13.5px; }
  details.faq p { padding: 0 0 14px; font-size: 13px; }
  .steps2 .step2 { padding: 18px 18px 16px; }
}

/* ============================================================
   开发文档：单页滚动 + 接口折叠卡
   ============================================================ */

.doc-sec { scroll-margin-top: 78px; padding-bottom: 26px; margin-bottom: 8px; border-bottom: 1px dashed var(--border); }
.doc-sec:last-child { border-bottom: 0; }
.docs2-main { max-width: 860px; }
.docs2-nav { top: 84px; }

.api-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.api-card {
  border: 1px solid var(--border); border-radius: 11px; background: var(--surface); overflow: hidden;
  transition: border-color .16s, box-shadow .16s;
}
.api-card:hover { border-color: var(--border-strong); }
.api-card[open] { border-color: color-mix(in srgb, var(--brand) 32%, var(--border)); box-shadow: 0 8px 24px -20px var(--brand); }
.api-card > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; font-size: 12.8px;
}
.api-card > summary::-webkit-details-marker { display: none; }
.api-card > summary code { font-family: var(--mono); font-size: 12.3px; color: var(--text); }
.api-desc { color: var(--text-2); font-size: 12.5px; }
.api-need { margin-left: auto; font-size: 11px; color: var(--muted); background: var(--bg-alt); padding: 2px 7px; border-radius: 5px; white-space: nowrap; }
.api-body { border-top: 1px solid var(--border); }
.api-pre {
  margin: 0; padding: 13px 15px; background: var(--surface-2); overflow-x: auto;
  font-family: var(--mono); font-size: 12.1px; line-height: 1.8; color: var(--text-2);
}
@media (max-width: 720px) {
  .api-card > summary { flex-wrap: wrap; gap: 6px; }
  .api-need { margin-left: 0; }
}

/* ============================================================
   界面文案：一行一项，做减法
   ============================================================ */

.tx-bar {
  position: sticky; top: 0; z-index: 6; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 0 12px; background: linear-gradient(var(--bg) 72%, transparent);
}
.tx-hint { font-size: 11.5px; color: var(--muted); margin-bottom: 12px; }
.tx-list { display: flex; flex-direction: column; gap: 10px; }
.tx-group { border: 1px solid var(--border); border-radius: 12px; background: var(--surface); overflow: hidden; }
.tx-group > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px;
  padding: 12px 16px; font-size: 13px; font-weight: 650; background: var(--surface-2);
}
.tx-group > summary::-webkit-details-marker { display: none; }
.tx-group > summary::after {
  content: ""; margin-left: auto; width: 6px; height: 6px;
  border-right: 1.6px solid var(--muted); border-bottom: 1.6px solid var(--muted);
  transform: rotate(45deg) translateY(-2px); transition: transform .18s;
}
.tx-group[open] > summary::after { transform: rotate(-135deg) translateY(-2px); }
.tx-cnt { font-size: 11px; color: var(--muted); font-weight: 500; }
.tx-rows { padding: 6px 10px 10px; display: flex; flex-direction: column; }
.tx-row {
  display: grid; grid-template-columns: 132px 1fr 30px; gap: 10px; align-items: start;
  padding: 7px 6px; border-radius: 8px;
}
.tx-row:hover { background: var(--surface-2); }
.tx-lab { font-size: 12.5px; color: var(--text-2); padding-top: 7px; display: flex; align-items: center; gap: 6px; overflow: hidden; }
.tx-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-lab.on .tx-name { color: var(--brand); font-weight: 600; }
.tx-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); flex: none; }
.tx-in {
  width: 100%; min-height: 34px; padding: 7px 10px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--text); font-size: 12.8px; line-height: 1.6;
  font-family: inherit; resize: none; overflow: auto;
}
.tx-in:focus { outline: none; border-color: var(--brand-400); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 14%, transparent); }
.tx-reset {
  width: 30px; height: 30px; border: 1px solid transparent; border-radius: 8px; background: transparent;
  color: var(--muted); cursor: pointer; font-size: 14px; line-height: 1;
}
.tx-reset:hover { background: var(--bg-alt); color: var(--brand); }
@media (max-width: 720px) {
  .tx-row { grid-template-columns: 1fr 30px; }
  .tx-lab { grid-column: 1 / -1; padding-top: 0; margin-bottom: 2px; }
}

/* 文档顶部参数卡：两列更稳，避免 3+1 落单 */
.kv2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

/* ============================================================
   空状态 / 加载态：统一插画 + 骨架屏
   ============================================================ */

.empty {
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  padding: 40px 20px; color: var(--muted); text-align: center;
}
.empty h4 { font-size: 13.5px; color: var(--text-2); font-weight: 600; margin: 0; }
.empty p { font-size: 12.5px; line-height: 1.7; max-width: 340px; margin: 0; }

.ill {
  width: 116px; height: 82px; color: color-mix(in srgb, var(--brand) 60%, var(--muted));
  opacity: .5; flex: none;
}
.ill svg { width: 100%; height: 100%; display: block; }
.ill-error { color: var(--danger); opacity: .55; }
.ill-offline { color: var(--warn); opacity: .55; }
.ill-ok { color: var(--ok); opacity: .55; }
.ill-load { animation: illFloat 3s ease-in-out infinite; }

@keyframes illFloat {
  0%, 100% { transform: translateY(0); opacity: .42; }
  50% { transform: translateY(-4px); opacity: .58; }
}

.sk-pulse { display: flex; gap: 5px; margin-top: 2px; }
.sk-pulse i {
  width: 6px; height: 6px; border-radius: 50%; background: var(--brand);
  animation: skPulse 1.1s ease-in-out infinite;
}
.sk-pulse i:nth-child(2) { animation-delay: .16s; }
.sk-pulse i:nth-child(3) { animation-delay: .32s; }
@keyframes skPulse { 0%, 100% { opacity: .22; transform: scale(.85); } 50% { opacity: .95; transform: scale(1); } }

.sk-wrap { padding: 14px 18px; }
.sk-line { display: flex; align-items: center; gap: 12px; padding: 9px 0; }
.sk {
  display: block; border-radius: 6px; background: var(--bg-alt);
  background-image: linear-gradient(90deg, transparent 0%, color-mix(in srgb, var(--surface) 85%, transparent) 50%, transparent 100%);
  background-size: 400px 100%; background-repeat: no-repeat;
  animation: shimmer 1.5s linear infinite;
}
.sk-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.sk-bar { height: 10px; flex: 1; max-width: 300px; }
.sk-bar.short { max-width: 110px; margin-left: auto; flex: none; width: 110px; }
@keyframes shimmer { 0% { background-position: -400px 0; } 100% { background-position: 460px 0; } }

@media (prefers-reduced-motion: reduce) {
  .ill-load, .sk, .sk-pulse i { animation: none; }
}

/* ============================================================
   首页工具墙
   ============================================================ */

.link-more {
  display: inline-flex; align-items: center; gap: 5px; flex: none;
  font-size: 13px; color: var(--brand); text-decoration: none; font-weight: 600;
  padding-bottom: 3px;
}
.link-more:hover { text-decoration: underline; text-underline-offset: 3px; }

.toolwall {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(216px, 1fr));
  gap: 12px;
}
.tool-card {
  display: flex; flex-direction: column; gap: 9px; min-height: 128px;
  padding: 18px; border-radius: 14px; background: var(--surface);
  border: 1px solid var(--border); text-decoration: none; color: inherit;
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.tool-card:hover {
  border-color: color-mix(in srgb, var(--brand) 40%, var(--border));
  box-shadow: var(--shadow); transform: translateY(-2px);
}
.tool-ico {
  width: 38px; height: 38px; border-radius: 11px; flex: none;
  display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand);
  font-size: 16px; font-weight: 700; line-height: 1;
}
.tool-ico.sm { font-size: 11px; letter-spacing: -.02em; font-weight: 700; }
.tool-name {
  display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
  font-size: 14px; font-weight: 650; letter-spacing: -.01em;
}
.tool-pro, .tool-free {
  height: 18px; padding: 0 6px; border-radius: 5px; font-size: 10.5px; font-weight: 700;
  display: inline-flex; align-items: center; letter-spacing: .02em;
}
.tool-pro { background: linear-gradient(135deg, var(--brand), var(--accent)); color: #fff; }
.tool-free { background: var(--ok-soft); color: var(--ok); }
.tool-desc {
  font-size: 12.5px; color: var(--text-2); line-height: 1.65; margin: 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.tool-foot {
  margin-top: auto; font-size: 11.5px; color: var(--muted);
  display: flex; align-items: center; gap: 4px;
}
.toolwall-empty { grid-column: 1 / -1; }

/* 首屏加载占位：与上面的 shimmer 动画共用 */
.tool-card.skeleton {
  background: var(--bg-alt); border-style: dashed; border-color: var(--border);
  animation: shimmer 1.5s linear infinite;
  background-image: linear-gradient(90deg, transparent 0%, color-mix(in srgb, var(--surface) 80%, transparent) 50%, transparent 100%);
  background-size: 400px 100%; background-repeat: no-repeat;
}
.tool-card.skeleton:hover { transform: none; box-shadow: none; border-color: var(--border); }

/* 用量占比条 */
.share { height: 6px; border-radius: 999px; background: var(--bg-alt); overflow: hidden; margin-bottom: 4px; }
.share i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--brand), var(--accent)); }

/* ============================================================
   区块布局 v3：解决「标题窄、内容宽」与「忽宽忽窄」的割裂
   - .s2-head.split  左标题 + 右辅助信息，两侧都有内容
   - .flow           一体化流程条（一个容器内分格，不再是散落卡片）
   - .redeem         激活卡改满宽双栏
   - .notice-grid    公告两列网格
   - .faq2           常见问题两列 + 联系卡
   ============================================================ */

/* ---------- 区块标题：左右两端 ---------- */

.s2-head.split {
  max-width: none; display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px 28px; flex-wrap: wrap;
}
.s2-head.split > div { max-width: 620px; }
.head-meta {
  display: inline-flex; align-items: center; gap: 7px; flex: none;
  height: 26px; padding: 0 11px; border-radius: 999px;
  background: var(--bg-alt); color: var(--text-2);
  font-size: 12px; font-weight: 600; letter-spacing: .01em;
}
.head-meta::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--brand);
}

/* ---------- 一体化流程条 ---------- */

.flow {
  display: grid; gap: 1px; background: var(--border);
  border: 1px solid var(--border); border-radius: 16px; overflow: hidden;
}
.flow.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.flow.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.flow-item { background: var(--surface); padding: 26px 26px 24px; position: relative; }
.flow-n {
  display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 14px;
  border-radius: 10px; color: #fff; font: 700 13px/1 var(--mono);
  background: linear-gradient(140deg, var(--brand), var(--accent));
  box-shadow: 0 8px 18px -12px var(--brand);
}
.flow-item h4 { font-size: 14px; letter-spacing: -.01em; margin: 0 0 6px; }
.flow-item p { font-size: 12.8px; color: var(--text-2); line-height: 1.72; margin: 0; }
.flow-item .flow-tip { margin-top: 10px; font-size: 11.5px; color: var(--muted); }

@media (max-width: 1080px) {
  .flow.three, .flow.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .flow.three .flow-item:last-child { grid-column: span 2; }
}
@media (max-width: 720px) {
  .flow.three, .flow.four { grid-template-columns: 1fr; }
  .flow.three .flow-item:last-child { grid-column: auto; }
  .flow-item { padding: 20px 20px 18px; }
}

/* ---------- 激活：满宽双栏 ---------- */

.redeem {
  display: grid; grid-template-columns: minmax(0, 1fr) 440px;
  border: 1px solid var(--border); border-radius: 16px; overflow: hidden;
  background: var(--surface);
}
.redeem-info {
  padding: 30px 32px;
  background:
    radial-gradient(520px 220px at 0% 0%, color-mix(in srgb, var(--brand) 9%, transparent), transparent 70%),
    var(--surface);
}
.redeem-info h2 { font-size: 23px; letter-spacing: -.025em; margin: 0; }
.redeem-info p { margin: 8px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.75; max-width: 460px; }
.redeem-list { list-style: none; padding: 0; margin: 16px 0 0; display: flex; flex-direction: column; gap: 9px; }
.redeem-list li { position: relative; padding-left: 21px; font-size: 12.8px; color: var(--text-2); line-height: 1.6; }
.redeem-list li::before {
  content: ""; position: absolute; left: 2px; top: 6px; width: 9px; height: 9px; border-radius: 3px;
  background: var(--brand-soft); border: 1.5px solid var(--brand);
}
.redeem-form-side {
  padding: 30px 32px; border-left: 1px solid var(--border);
  display: flex; flex-direction: column; justify-content: center; gap: 12px;
  background: var(--surface-2);
}
.redeem-form-side .input-group .input { height: 44px; font-size: 13px; }
.redeem-form-side .btn { height: 44px; padding: 0 20px; }
.redeem-badge {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 6px;
  height: 22px; padding: 0 9px; border-radius: 6px;
  background: var(--brand-soft); color: var(--brand); font: 600 11px/1 var(--mono);
}

@media (max-width: 980px) {
  .redeem { grid-template-columns: 1fr; }
  .redeem-form-side { border-left: 0; border-top: 1px solid var(--border); }
  .redeem-info, .redeem-form-side { padding: 24px 22px; }
}

/* ---------- 公告：两列网格 ---------- */

.notice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.notice-grid .notice-card { grid-template-columns: 1fr; gap: 9px; padding: 16px 18px 18px; }
.notice-grid .notice-side { flex-direction: row; align-items: center; gap: 8px; }
.notice-grid .notice-main h3 { font-size: 13.5px; }
.notice-grid .notice-main p { font-size: 12.8px; line-height: 1.72; }

@media (max-width: 900px) {
  .notice-grid { grid-template-columns: 1fr; }
}

/* ---------- FAQ：两列 + 联系卡 ---------- */

.faq2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.faq-col { display: flex; flex-direction: column; gap: 10px; }
.faq-help {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px;
  border-radius: 12px; border: 1px dashed var(--border-strong);
  background: var(--surface-2); text-decoration: none; color: var(--text-2);
  font-size: 12.8px; line-height: 1.6; transition: border-color .18s, background .18s;
}
.faq-help:hover { border-color: var(--brand); background: var(--brand-soft); }
.faq-help .fh-ico {
  width: 32px; height: 32px; border-radius: 9px; flex: none; display: grid; place-items: center;
  background: var(--surface); color: var(--brand); border: 1px solid var(--border);
}
.faq-help .fh-ico svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.faq-help b { display: block; color: var(--text); font-size: 13px; margin-bottom: 1px; }

@media (max-width: 900px) {
  .faq2 { grid-template-columns: 1fr; }
}

/* ---------- 开发者：两种合作模式卡 ---------- */

.mode2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.mode-card {
  display: flex; flex-direction: column; gap: 14px; padding: 26px;
  border: 1px solid var(--border); border-radius: 16px; background: var(--surface);
}
.mode-card.pro {
  border-color: color-mix(in srgb, var(--brand) 40%, var(--border));
  box-shadow: 0 20px 50px -38px var(--brand);
}
.mode-top { display: flex; align-items: center; gap: 11px; }
.mode-ico {
  width: 36px; height: 36px; border-radius: 11px; flex: none; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand);
}
.mode-ico svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.mode-name { font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
.mode-tag {
  margin-left: auto; height: 20px; padding: 0 8px; border-radius: 999px;
  display: inline-flex; align-items: center; font-size: 11px; font-weight: 700;
  background: var(--bg-alt); color: var(--muted);
}
.mode-card.pro .mode-tag { background: linear-gradient(135deg, var(--brand), var(--accent)); color: #fff; }
.mode-card > p { font-size: 13px; color: var(--text-2); line-height: 1.75; margin: 0; }
.mode-gain {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 12px 14px; border-radius: 10px; background: var(--surface-2);
  font-size: 12.5px; color: var(--muted);
}
.mode-gain b { font-size: 14.5px; color: var(--ok); letter-spacing: -.01em; }
.mode-foot { margin-top: auto; padding-top: 4px; font-size: 12px; color: var(--muted); line-height: 1.65; }

@media (max-width: 900px) {
  .mode2 { grid-template-columns: 1fr; }
}

/* ---------- 联系方式条（新） ---------- */

.contact-strip {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 16px 20px; border-radius: 12px; border: 1px solid var(--border);
  background: var(--surface-2);
}
.contact-strip .cs-label { font-size: 12.5px; color: var(--muted); }
.contact-strip .cs-mail {
  font-family: var(--mono); font-size: 13px; color: var(--text);
  padding: 6px 10px; border-radius: 8px; background: var(--surface); border: 1px dashed var(--border-strong);
}

/* 公告只有 1 条 / 奇数条时，最后一条占满整行，避免右侧留半屏空白 */
.notice-grid > .notice-card:only-child,
.notice-grid > .notice-card:nth-child(odd):last-child { grid-column: 1 / -1; }

/* 深链 #/activate 时给卡密输入框一个短暂的聚焦高亮，让用户一眼看到该在哪填 */
.input.ring {
  border-color: var(--brand) !important;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 18%, transparent);
  transition: box-shadow .25s, border-color .25s;
}

/* ============================================================
   开发文档 v2：功能手册卡片 / 配置清单 / FAQ
   ============================================================ */

.feat {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 22px 16px;
  margin-bottom: 14px;
  background: var(--surface);
}

.feat h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  letter-spacing: -.01em;
  margin: 0 0 8px;
}

.feat-n {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  flex: none;
  background: var(--brand-soft);
  color: var(--brand);
  font: 700 12px/1 var(--mono);
}

.feat-when {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.75;
  color: var(--text-2);
}

.feat-row {
  display: grid;
  grid-template-columns: 104px 1fr;
  gap: 10px;
  align-items: start;
  padding: 8px 0;
  border-top: 1px dashed var(--border);
  font-size: 12.5px;
  line-height: 1.7;
}

.feat-row b {
  color: var(--muted);
  font-weight: 600;
  font-size: 12px;
}

.feat-row code {
  font-family: var(--mono);
  font-size: 11.8px;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--brand-soft);
  color: var(--brand);
  margin-right: 4px;
  white-space: nowrap;
}

.feat-row i {
  display: block;
  font-style: normal;
  color: var(--text-2);
  padding-left: 10px;
  position: relative;
}

.feat-row i::before {
  content: "·";
  position: absolute;
  left: 0;
  color: var(--muted);
}

.feat table.table { margin-top: 10px; }
.feat .cb { margin-bottom: 4px; }

.setup-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 18px 10px;
  margin-bottom: 12px;
  background: var(--surface);
}

.setup-h {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.setup-h b { font-size: 13.5px; }

.setup-n {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  flex: none;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  color: #fff;
  font: 700 11.5px/1 var(--mono);
}

.setup-card .docs-list { margin: 4px 0 8px; }

.faq-item {
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
}

.faq-item:last-child { border-bottom: 0; }

.faq-item b {
  display: block;
  font-size: 13.2px;
  margin-bottom: 4px;
  color: var(--text);
}

.faq-item p {
  margin: 0;
  font-size: 12.8px;
  line-height: 1.8;
  color: var(--text-2);
}

@media (max-width: 720px) {
  .feat { padding: 16px 14px 12px; }
  .feat-row { grid-template-columns: 1fr; gap: 3px; }
  .feat-row b { font-size: 11.5px; }
}

/* ===== 开发文档：搜索 ===== */
.doc-search { position: relative; padding: 0 12px 10px; }
.doc-search input {
  width: 100%; height: 34px; border-radius: 9px; padding: 0 10px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  font-size: 12.5px;
}
.doc-search input::placeholder { color: var(--muted); }
.doc-search input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.doc-results {
  position: absolute; left: 12px; right: 12px; top: 46px; z-index: 60;
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, .16);
  max-height: 62vh; overflow: auto; display: none;
}
.doc-results.on { display: block; }
.doc-results .r {
  display: block; width: 100%; text-align: left; border: none; background: transparent;
  padding: 9px 11px; cursor: pointer; border-bottom: 1px solid var(--border);
}
.doc-results .r:last-child { border-bottom: none; }
.doc-results .r:hover, .doc-results .r.sel { background: var(--surface-2); }
.doc-results .r b { display: block; font-size: 12.5px; font-weight: 600; color: var(--text); }
.doc-results .r i { font-style: normal; font-size: 10.5px; color: var(--muted); margin-left: 6px; }
.doc-results .r span {
  display: block; font-size: 11.5px; color: var(--muted); margin-top: 3px; line-height: 1.55;
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.doc-results .empty { padding: 16px; text-align: center; font-size: 12px; color: var(--muted); }
.doc-hit { animation: docHit 1.7s ease; }
@keyframes docHit { 0%, 55% { background: var(--brand-soft); } 100% { background: transparent; } }

@media (max-width: 900px) {
  .doc-results { max-height: 50vh; }
}

/* ===== 代码块折叠 ===== */
.cb-body { position: relative; }
.cb-body.cb-folded pre { max-height: 300px; overflow: hidden; }
.cb-body.cb-folded::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 34px; height: 64px;
  background: linear-gradient(to bottom, transparent, var(--surface)); pointer-events: none;
}
.cb-expand {
  display: block; width: 100%; border: 0; border-top: 1px solid var(--border);
  background: var(--surface-2); color: var(--brand); font-size: 12px; padding: 8px; cursor: pointer; font-family: inherit;
}
.cb-expand:hover { background: var(--bg-alt); }
