/* ==========================================================================
   站长猫 ZhanTools · 设计系统
   ========================================================================== */
:root {
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --brand-light: #eff6ff;
  --brand-2: #0ea5e9;
  --ink: #0f172a;
  --ink-2: #334155;
  --muted: #64748b;
  --muted-2: #94a3b8;
  --line: #e6ebf3;
  --line-2: #eef2f8;
  --bg: #f5f7fb;
  --card: #ffffff;
  --green: #16a34a;
  --green-bg: #ecfdf5;
  --red: #dc2626;
  --red-bg: #fef2f2;
  --orange: #f59e0b;
  --orange-bg: #fffbeb;
  --purple: #7c3aed;
  --purple-bg: #f5f3ff;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px -12px rgba(15, 23, 42, .12);
  --shadow-lg: 0 24px 60px -24px rgba(15, 23, 42, .25);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
h1, h2, h3, h4, h5 { color: var(--ink); margin: 0; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0; }
img { max-width: 100%; }
button, input, select, textarea { font-family: inherit; font-size: inherit; }
::selection { background: #bfdbfe; color: #0b2545; }

/* ---------- 布局 ---------- */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.container-wide { max-width: 1360px; }
.row { display: flex; }
.between { justify-content: space-between; }
.center { align-items: center; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-20 { gap: 20px; }
.grid { display: grid; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; } .mb-12 { margin-bottom: 12px; } .mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.tiny { font-size: 11.5px; }
.strong { font-weight: 600; color: var(--ink); }
.mono { font-family: var(--mono); }
.nowrap { white-space: nowrap; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.hidden { display: none !important; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- 顶部导航 ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .inner { height: 64px; display: flex; align-items: center; gap: 28px; }
.logo { display: flex; align-items: center; gap: 9px; font-size: 18px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.logo:hover { color: var(--ink); }
.logo-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  display: grid; place-items: center; color: #fff;
  box-shadow: 0 6px 14px -6px rgba(37, 99, 235, .8);
}
.logo-mark svg { width: 20px; height: 20px; }
.logo small { font-size: 10px; font-weight: 600; color: var(--muted-2); letter-spacing: .12em; display: block; line-height: 1; margin-top: 2px; }
.nav { display: flex; gap: 4px; margin-left: 6px; }
.nav a {
  padding: 8px 14px; border-radius: 9px; color: var(--ink-2); font-weight: 500; font-size: 14px;
  transition: background .15s, color .15s;
}
.nav a:hover { background: #f1f5f9; color: var(--ink); }
.nav a.active { color: var(--brand); background: var(--brand-light); font-weight: 600; }
.header-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.header-quota {
  display: flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  background: var(--brand-light); color: var(--brand-dark); font-size: 12.5px; font-weight: 600;
}
.header-quota b { font-size: 13px; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 16px; border-radius: 9px;
  border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  font-size: 13.5px; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: all .16s ease;
}
.btn:hover { border-color: #cfdaea; background: #f8fafc; color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .6; cursor: not-allowed; }
.btn-primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb); border-color: transparent; color: #fff;
  box-shadow: 0 8px 18px -10px rgba(37, 99, 235, .9);
}
.btn-primary:hover { background: linear-gradient(135deg, #2563eb, #1d4ed8); color: #fff; border-color: transparent; }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { background: #1e293b; color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: #f1f5f9; color: var(--ink); }
.btn-sm { height: 30px; padding: 0 10px; font-size: 12.5px; border-radius: 7px; }
.btn-lg { height: 46px; padding: 0 24px; font-size: 15px; border-radius: 11px; }
.btn-block { width: 100%; }
.btn-danger { color: var(--red); border-color: #fecaca; background: #fff; }
.btn-danger:hover { background: var(--red-bg); border-color: #fca5a5; color: var(--red); }

/* ---------- 卡片 ---------- */
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card-pad { padding: 22px; }
.card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 22px; border-bottom: 1px solid var(--line-2);
}
.card-head h3 { font-size: 15px; }
.card-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.card-body { padding: 20px 22px; }
.card-foot { padding: 14px 22px; border-top: 1px solid var(--line-2); background: #fbfcfe; border-radius: 0 0 var(--radius) var(--radius); }

/* ---------- 表单 ---------- */
.field { margin-bottom: 14px; }
.label { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.input, select.input, textarea.input {
  width: 100%; height: 42px; padding: 0 13px; border: 1px solid var(--line);
  border-radius: var(--radius-sm); background: #fff; color: var(--ink); outline: none;
  transition: border-color .15s, box-shadow .15s;
}
textarea.input { height: auto; padding: 11px 13px; line-height: 1.6; resize: vertical; min-height: 96px; }
.input::placeholder { color: var(--muted-2); }
.input:focus, select.input:focus, textarea.input:focus {
  border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(59, 130, 246, .12);
}
select.input { 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 24 24' fill='none' stroke='%2364748b' stroke-width='2'><path d='M6 9l6 6 6-6'/></svg>"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }
.help { font-size: 12px; color: var(--muted-2); margin-top: 5px; }
.input-group { display: flex; gap: 8px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 300px at 12% -10%, rgba(37, 99, 235, .10), transparent 60%),
    radial-gradient(700px 300px at 88% 0%, rgba(14, 165, 233, .12), transparent 60%),
    linear-gradient(180deg, #f8fbff, #f5f7fb 70%);
  border-bottom: 1px solid var(--line);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(37, 99, 235, .045) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(37, 99, 235, .045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 35%, transparent 78%);
  pointer-events: none;
}
.hero .inner { position: relative; z-index: 2; padding: 52px 0 40px; text-align: center; }
.hero h1 { font-size: 38px; line-height: 1.25; letter-spacing: -.03em; }
.hero h1 em { font-style: normal; background: linear-gradient(120deg, #2563eb, #0ea5e9); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { color: var(--muted); font-size: 15.5px; margin: 14px auto 0; max-width: 640px; }
.hero-badges { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
.pill {
  display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px;
  border-radius: 999px; background: #fff; border: 1px solid var(--line);
  font-size: 12.5px; color: var(--muted); box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
}
.pill b { color: var(--ink); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(22, 163, 74, .15); }

/* ---------- 搜索框 ---------- */
.search-box {
  display: flex; align-items: center; gap: 10px; max-width: 720px; margin: 26px auto 0;
  background: #fff; border: 1px solid #dbe6f5; border-radius: 14px; padding: 8px 8px 8px 16px;
  box-shadow: 0 18px 40px -22px rgba(37, 99, 235, .45), 0 2px 6px rgba(15, 23, 42, .04);
}
.search-box svg { color: var(--muted-2); flex: none; }
.search-box input {
  flex: 1; border: 0; outline: none; height: 40px; font-size: 15px; color: var(--ink); background: transparent;
}
.search-box input::placeholder { color: var(--muted-2); }
.search-tools { display: flex; gap: 6px; align-items: center; }
.hot-links { margin-top: 14px; font-size: 12.5px; color: var(--muted-2); display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.hot-links a { color: var(--muted); }
.hot-links a:hover { color: var(--brand); }

/* ---------- 统计条 ---------- */
.stats-strip {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; margin-top: 34px;
}
.stats-strip .item { background: #fff; padding: 18px; text-align: center; }
.stats-strip .num { font-size: 24px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.stats-strip .lbl { font-size: 12.5px; color: var(--muted); margin-top: 2px; }

/* ---------- 区块标题 ---------- */
.section { padding: 44px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.section-head h2 { font-size: 22px; letter-spacing: -.02em; }
.section-head p { color: var(--muted); font-size: 13.5px; margin-top: 6px; }

/* ---------- 工具卡 ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.tool-card {
  display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; transition: transform .18s ease, box-shadow .18s ease, border-color .18s;
  position: relative; overflow: hidden;
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: #cfdefa; color: inherit; }
.tool-icon {
  width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(135deg, #eff6ff, #e0edff); color: var(--brand); margin-bottom: 12px;
}
.tool-icon svg { width: 19px; height: 19px; }
.tool-card h4 { font-size: 14.5px; margin-bottom: 6px; }
.tool-card p { font-size: 12.5px; color: var(--muted); line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 40px; }
.tool-meta { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; font-size: 11.5px; color: var(--muted-2); }
.tag-cost { display: inline-flex; align-items: center; gap: 3px; }
.tag-free { color: var(--green); font-weight: 600; }

/* ---------- 标签页 ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs button {
  border: 0; background: transparent; padding: 10px 14px; font-size: 13.5px; color: var(--muted);
  cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; font-weight: 500;
}
.tabs button:hover { color: var(--ink); }
.tabs button.active { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th {
  text-align: left; padding: 11px 14px; background: #fbfcfe; color: var(--muted);
  font-weight: 600; font-size: 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.table tbody tr:hover { background: #fafcff; }
.table tbody tr:last-child td { border-bottom: 0; }
.table .link { color: var(--brand); font-weight: 500; }

/* ---------- 徽标 ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px;
  border-radius: 6px; font-size: 11.5px; font-weight: 600; background: #f1f5f9; color: var(--muted);
  white-space: nowrap;
}
.badge-blue { background: var(--brand-light); color: var(--brand-dark); }
.badge-green { background: var(--green-bg); color: var(--green); }
.badge-red { background: var(--red-bg); color: var(--red); }
.badge-orange { background: var(--orange-bg); color: #b45309; }
.badge-purple { background: var(--purple-bg); color: var(--purple); }
.badge-dark { background: #0f172a; color: #fff; }

/* ---------- 工具页布局 ---------- */
.tool-layout { display: grid; grid-template-columns: 232px 1fr; gap: 22px; padding: 26px 0 50px; align-items: start; }
.side-nav { position: sticky; top: 84px; }
.side-group { margin-bottom: 18px; }
.side-group .title { font-size: 11px; font-weight: 700; color: var(--muted-2); letter-spacing: .08em; text-transform: uppercase; padding: 0 10px 8px; }
.side-link {
  display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 8px;
  color: var(--ink-2); font-size: 13px; margin-bottom: 2px; transition: all .14s;
}
.side-link svg { width: 16px; height: 16px; color: var(--muted-2); flex: none; }
.side-link:hover { background: #f1f5f9; color: var(--ink); }
.side-link.active { background: var(--brand-light); color: var(--brand-dark); font-weight: 600; }
.side-link.active svg { color: var(--brand); }

.tool-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 18px; }
.tool-head .icon {
  width: 46px; height: 46px; border-radius: 12px; background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: #fff; display: grid; place-items: center; box-shadow: 0 10px 20px -12px rgba(37, 99, 235, .9);
}
.tool-head .icon svg { width: 22px; height: 22px; }
.tool-head h1 { font-size: 21px; }
.tool-head p { color: var(--muted); font-size: 13px; margin-top: 4px; }

.query-bar { display: flex; gap: 10px; align-items: stretch; }
.query-bar .input { height: 46px; font-size: 14.5px; }
.query-bar .btn { height: 46px; padding: 0 26px; font-size: 14.5px; }
.quick-samples { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; font-size: 12px; color: var(--muted-2); }
.quick-samples button { border: 0; background: #f1f5f9; color: var(--muted); padding: 4px 10px; border-radius: 999px; cursor: pointer; font-size: 12px; }
.quick-samples button:hover { background: var(--brand-light); color: var(--brand-dark); }

/* ---------- 结果区 ---------- */
#result { margin-top: 18px; }
.res-placeholder { text-align: center; padding: 46px 20px; color: var(--muted-2); }
.res-placeholder svg { color: #cbd5e1; margin-bottom: 12px; }

.score-hero { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.ring { position: relative; width: 108px; height: 108px; flex: none; }
.ring svg { transform: rotate(-90deg); }
.ring .val { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.ring .val b { font-size: 28px; color: var(--ink); line-height: 1; font-weight: 800; }
.ring .val span { font-size: 11px; color: var(--muted-2); display: block; margin-top: 4px; }

.kv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.kv { background: #fbfcfe; border: 1px solid var(--line-2); border-radius: 10px; padding: 12px 14px; min-width: 0; }
.kv .k { font-size: 11.5px; color: var(--muted-2); margin-bottom: 3px; }
.kv .v { font-size: 13.5px; color: var(--ink); font-weight: 500; word-break: break-all; }

.metric-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.metric { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.metric .k { font-size: 12px; color: var(--muted); }
.metric .v { font-size: 21px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; margin-top: 2px; }
.metric .v small { font-size: 12px; font-weight: 500; color: var(--muted-2); margin-left: 3px; }

.check-list { display: grid; gap: 8px; }
.check-item {
  display: flex; align-items: flex-start; gap: 10px; padding: 11px 13px; border-radius: 10px;
  background: #fbfcfe; border: 1px solid var(--line-2);
}
.check-item .ic { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; flex: none; margin-top: 1px; }
.check-item .ic.ok { background: var(--green-bg); color: var(--green); }
.check-item .ic.no { background: var(--red-bg); color: var(--red); }
.check-item .nm { font-weight: 600; color: var(--ink); font-size: 13px; }
.check-item .vl { font-size: 11.5px; color: var(--muted-2); margin-left: 6px; }
.check-item .ad { font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.55; }

.progress { height: 6px; background: #eef2f8; border-radius: 999px; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #60a5fa, #2563eb); transition: width .5s ease; }

.bar-list { display: grid; gap: 10px; }
.bar-item { display: grid; grid-template-columns: 96px 1fr 62px; align-items: center; gap: 12px; font-size: 12.5px; }
.bar-item .track { height: 8px; background: #eef2f8; border-radius: 999px; overflow: hidden; }
.bar-item .track i { display: block; height: 100%; background: linear-gradient(90deg, #93c5fd, #2563eb); border-radius: 999px; }

.notice-bar {
  display: flex; align-items: center; gap: 10px; background: #fffbeb; border: 1px solid #fde68a;
  color: #92400e; border-radius: 10px; padding: 9px 14px; font-size: 12.5px; margin-bottom: 18px;
}
.notice-bar svg { flex: none; }

/* ---------- 认证页 ---------- */
.auth-wrap { min-height: calc(100vh - 64px); display: grid; grid-template-columns: 1.05fr .95fr; }
.auth-side {
  background: linear-gradient(150deg, #1e3a8a, #2563eb 55%, #0ea5e9);
  color: #fff; padding: 56px 52px; display: flex; flex-direction: column; justify-content: center; position: relative; overflow: hidden;
}
.auth-side::after {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .16) 1px, transparent 1px);
  background-size: 22px 22px; opacity: .5;
}
.auth-side > * { position: relative; z-index: 2; }
.auth-side h2 { color: #fff; font-size: 30px; line-height: 1.35; letter-spacing: -.02em; }
.auth-side p { color: rgba(255, 255, 255, .82); margin-top: 14px; font-size: 14px; }
.auth-feats { margin-top: 30px; display: grid; gap: 14px; }
.auth-feat { display: flex; gap: 12px; align-items: flex-start; }
.auth-feat .fi { width: 30px; height: 30px; border-radius: 9px; background: rgba(255, 255, 255, .16); display: grid; place-items: center; flex: none; }
.auth-feat b { display: block; font-size: 13.5px; }
.auth-feat span { font-size: 12.5px; color: rgba(255, 255, 255, .72); }
.auth-main { display: grid; place-items: center; padding: 44px 24px; background: #fff; }
.auth-form { width: 100%; max-width: 372px; }
.auth-form h1 { font-size: 24px; }
.auth-form .sub { color: var(--muted); margin: 8px 0 24px; font-size: 13.5px; }
.auth-alt { text-align: center; font-size: 13px; color: var(--muted); margin-top: 18px; }

/* ---------- 用户中心 ---------- */
.user-hero {
  background: linear-gradient(120deg, #1e3a8a, #2563eb 60%, #0ea5e9);
  color: #fff; border-radius: var(--radius); padding: 26px 28px; display: flex; align-items: center; gap: 20px;
  flex-wrap: wrap; box-shadow: var(--shadow);
}
.user-hero .avatar {
  width: 58px; height: 58px; border-radius: 16px; background: rgba(255, 255, 255, .18);
  display: grid; place-items: center; font-size: 22px; font-weight: 800; color: #fff; flex: none;
  border: 1px solid rgba(255, 255, 255, .28);
}
.user-hero h2 { color: #fff; font-size: 20px; }
.user-hero .meta { font-size: 12.5px; color: rgba(255, 255, 255, .78); margin-top: 3px; }
.user-hero .quota-box { margin-left: auto; display: flex; gap: 26px; }
.user-hero .q { text-align: right; }
.user-hero .q b { display: block; font-size: 22px; font-weight: 800; }
.user-hero .q span { font-size: 11.5px; color: rgba(255, 255, 255, .72); }

.quota-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }

/* ---------- 套餐 ---------- */
.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.plan {
  background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 26px;
  position: relative; transition: transform .18s, box-shadow .18s;
}
.plan:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.plan.hot { border-color: #93c5fd; box-shadow: 0 20px 40px -26px rgba(37, 99, 235, .6); }
.plan .badge-top { position: absolute; top: -11px; left: 24px; }
.plan h3 { font-size: 16px; }
.plan .price { font-size: 32px; font-weight: 800; color: var(--ink); letter-spacing: -.03em; margin: 12px 0 2px; }
.plan .price small { font-size: 13px; font-weight: 500; color: var(--muted-2); }
.plan .desc { font-size: 12.5px; color: var(--muted); }
.plan ul { list-style: none; padding: 0; margin: 18px 0 22px; display: grid; gap: 9px; }
.plan li { display: flex; gap: 8px; font-size: 12.8px; color: var(--ink-2); }
.plan li svg { flex: none; color: var(--green); margin-top: 3px; }

/* ---------- 页脚 ---------- */
.site-footer { background: #0b1220; color: #94a3b8; margin-top: 20px; padding: 40px 0 24px; font-size: 12.8px; }
.site-footer .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 30px; }
.site-footer h5 { color: #e2e8f0; font-size: 13px; margin-bottom: 12px; }
.site-footer a { color: #94a3b8; display: block; padding: 4px 0; }
.site-footer a:hover { color: #fff; }
.site-footer .bottom { border-top: 1px solid rgba(255, 255, 255, .08); margin-top: 28px; padding-top: 18px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; color: #64748b; }
.site-footer .logo { color: #fff; }
.site-footer .logo small { color: #64748b; }

/* ---------- Toast / Loading ---------- */
#toasts { position: fixed; top: 78px; right: 20px; z-index: 9999; display: grid; gap: 10px; }
.toast {
  min-width: 240px; max-width: 360px; background: #0f172a; color: #fff; border-radius: 10px;
  padding: 12px 16px; font-size: 13px; box-shadow: var(--shadow-lg); display: flex; gap: 8px; align-items: flex-start;
  animation: slideIn .22s ease;
}
.toast.ok { background: #052e1b; border-left: 3px solid #22c55e; }
.toast.err { background: #3f0d0d; border-left: 3px solid #ef4444; }
@keyframes slideIn { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }

.spinner { width: 15px; height: 15px; border: 2px solid rgba(255, 255, 255, .35); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }
.spinner-dark { border-color: #dbeafe; border-top-color: var(--brand); }
@keyframes spin { to { transform: rotate(360deg); } }
.skeleton { background: linear-gradient(90deg, #eef2f8 25%, #f8fafc 37%, #eef2f8 63%); background-size: 400% 100%; animation: shimmer 1.3s infinite; border-radius: 8px; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

.loading-box { padding: 40px; text-align: center; color: var(--muted); }
.loading-box .spinner-dark { width: 26px; height: 26px; border-width: 3px; }

/* ---------- 空状态 ---------- */
.empty { text-align: center; padding: 44px 20px; color: var(--muted-2); }
.empty svg { color: #cbd5e1; margin-bottom: 10px; }
.empty b { display: block; color: var(--ink-2); font-size: 14px; margin-bottom: 4px; }

/* ---------- 分页 ---------- */
.pager { display: flex; gap: 6px; align-items: center; justify-content: flex-end; padding: 14px 0 2px; }
.pager button {
  min-width: 32px; height: 32px; border-radius: 7px; border: 1px solid var(--line); background: #fff;
  color: var(--ink-2); cursor: pointer; font-size: 12.5px; padding: 0 8px;
}
.pager button:hover:not(:disabled) { border-color: #cfdaea; background: #f8fafc; }
.pager button.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager button:disabled { opacity: .5; cursor: not-allowed; }
.pager .info { font-size: 12px; color: var(--muted-2); margin-right: auto; }

/* ---------- 弹层 ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(15, 23, 42, .45); backdrop-filter: blur(2px);
  z-index: 9000; display: grid; place-items: center; padding: 20px; animation: fadeIn .16s;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: #fff; border-radius: 16px; width: 100%; max-width: 520px; box-shadow: var(--shadow-lg);
  max-height: 88vh; display: flex; flex-direction: column; animation: pop .18s ease;
}
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-head { padding: 18px 22px; border-bottom: 1px solid var(--line-2); display: flex; align-items: center; justify-content: space-between; }
.modal-head h3 { font-size: 15.5px; }
.modal-body { padding: 20px 22px; overflow-y: auto; }
.modal-foot { padding: 14px 22px; border-top: 1px solid var(--line-2); display: flex; justify-content: flex-end; gap: 10px; }
.icon-btn { border: 0; background: transparent; cursor: pointer; color: var(--muted); padding: 4px; border-radius: 6px; display: grid; place-items: center; }
.icon-btn:hover { background: #f1f5f9; color: var(--ink); }

/* ---------- 提示块 ---------- */
.alert { display: flex; gap: 9px; border-radius: 10px; padding: 11px 14px; font-size: 12.8px; line-height: 1.6; }
.alert svg { flex: none; margin-top: 2px; }
.alert-info { background: var(--brand-light); color: #1e40af; border: 1px solid #dbeafe; }
.alert-warn { background: var(--orange-bg); color: #92400e; border: 1px solid #fde68a; }
.alert-success { background: var(--green-bg); color: #065f46; border: 1px solid #a7f3d0; }
.alert-danger { background: var(--red-bg); color: #991b1b; border: 1px solid #fecaca; }

/* ---------- 数据小图 ---------- */
.spark { display: flex; align-items: flex-end; gap: 3px; height: 40px; }
.spark i { flex: 1; background: linear-gradient(180deg, #93c5fd, #3b82f6); border-radius: 3px 3px 0 0; min-height: 2px; opacity: .85; }
.spark i:hover { opacity: 1; }

/* ---------- 装饰 ---------- */
.divider { height: 1px; background: var(--line-2); margin: 16px 0; }
.dot-sep { color: var(--muted-2); margin: 0 6px; }
.link-arrow { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 600; }

/* ---------- 响应式 ---------- */
@media (max-width: 1080px) {
  .tool-grid { grid-template-columns: repeat(3, 1fr); }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .user-hero .quota-box { margin-left: 0; }
}
@media (max-width: 860px) {
  .nav { display: none; }
  .hero h1 { font-size: 28px; }
  .tool-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .tool-layout { grid-template-columns: 1fr; }
  .side-nav { position: static; }
  .side-nav .side-group { display: none; }
  .metric-row { grid-template-columns: repeat(2, 1fr); }
  .plan-grid { grid-template-columns: 1fr; }
  .site-footer .cols { grid-template-columns: 1fr 1fr; }
  .query-bar { flex-direction: column; }
  .search-box { flex-wrap: wrap; }
  .search-box .search-tools { width: 100%; }
  .search-box .search-tools .btn { width: 100%; }
}
@media (max-width: 560px) {
  .tool-grid { grid-template-columns: 1fr; }
  .hero .inner { padding: 34px 0 28px; }
  .card-pad, .card-body { padding: 16px; }
  .section { padding: 30px 0; }
  .header-quota { display: none; }
}

/* 移动端：所有内联双列布局改为单列 */
@media (max-width: 860px) {
  .grid[style*="grid-template-columns"] { grid-template-columns: 1fr !important; }
  .score-hero { gap: 16px; }
  .user-hero { padding: 20px; }
  .user-hero .quota-box { width: 100%; justify-content: space-between; gap: 12px; }
  .user-hero .q { text-align: left; }
  .user-hero .q b { font-size: 18px; }
  .kv-grid { grid-template-columns: 1fr 1fr; }
  .table th, .table td { padding: 10px 10px; }
}
@media (max-width: 560px) {
  .kv-grid { grid-template-columns: 1fr; }
  .metric-row { grid-template-columns: 1fr 1fr; }
  .bar-item { grid-template-columns: 74px 1fr 52px !important; font-size: 12px; }
}

/* 细节修正 */
.tool-head { flex-wrap: wrap; }
.card-head { flex-wrap: wrap; }
.tool-head > div:last-child { flex-shrink: 0; }
@media (max-width: 560px) {
  .tool-head > div:last-child { width: 100%; text-align: left; margin-left: 0 !important; }
}
