:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f8f9fb;
  --border: #e4e6ea;
  --border-strong: #d3d6dc;
  --text: #1c1e21;
  --text-2: #6b7280;
  --text-3: #9aa1ab;
  /* ⭐ 62x（2026-10-14 用户要求）：官网风的近黑配色撤掉，恢复原来的蓝色主题 ——
     主按钮蓝底白字、hover 更深蓝、选中态浅蓝底 + 左侧蓝条。 */
  --accent: #2563eb;
  --accent-strong: #1d4ed8;
  --accent-weak: #eef3fe;
  --surface-3: #e9ebef;
  --ok: #0f8a5f;
  --ok-weak: #e8f6f0;
  --bad: #c9362b;
  --bad-weak: #fdecea;
  --warn: #a86a00;
  --warn-weak: #fdf3e2;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 1px 3px rgba(16, 24, 40, 0.06);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.hidden { display: none !important; }
code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0 4px;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 12px;
}

/* ---------------- 通用控件 ---------------- */

.btn {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 8px 14px;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
  white-space: nowrap;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.btn:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.btn-ghost { background: transparent; border-color: var(--border-strong); }
.btn-block { width: 100%; }
.btn-sm { padding: 5px 10px; font-size: 12px; }

.link-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-size: 12px;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
  text-align: left;
}
.link-btn:hover { text-decoration: underline; }

input[type="text"], input[type="number"], input[type="email"], input[type="password"], select, textarea {
  width: 100%;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: 8px 10px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
}
textarea { resize: vertical; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; }

.field { display: block; margin-bottom: 12px; }
.field > span {
  display: block;
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 5px;
  font-weight: 500;
}
.field .opt { color: var(--text-3); font-weight: 400; margin-left: 6px; }
.field.compact { margin-bottom: 0; min-width: 140px; }
.field.compact.grow { flex: 1; min-width: 180px; }

.row-inline { display: flex; gap: 8px; align-items: center; }
.row-inline.center { justify-content: center; margin-top: 12px; }
.row-inline .btn { flex-shrink: 0; }

.check {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 12px;
  cursor: pointer;
}
.check input { margin-top: 3px; flex-shrink: 0; }

.radio-row { display: flex; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.radio {
  flex: 1 1 180px;
  display: flex;
  gap: 8px;
  align-items: flex-start;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 10px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.radio:has(input:checked) { border-color: var(--accent); background: var(--accent-weak); }
.radio input { margin-top: 3px; }
.radio b { display: block; font-size: 13px; font-weight: 500; }
.radio i { display: block; font-style: normal; font-size: 12px; color: var(--text-2); }

/* ⭐ 2026-10-11 第 55 轮 b：访问限制 / 到期跳转两个弹窗改成「一排两个」（用户截图要求）。
   `.radio` 默认 flex: 1 1 180px，在原来 340px 的窄卡片里一行只塞得下一个，所以：
     ① 卡片换成 modal-card-lg（520px，内宽约 480）—— 在 index.html 上改；
     ② 基准从 180 抬到 200 → 一行正好两个（访问限制 6 档 = 3 行，到期跳转 2 档 = 1 行）。
   ⚠️ 手机上卡片回 100%（768px 那条媒体查询），两个挤不下时 flex-wrap 会自动换回一行一个。
   ⚠️ 必须用 ID 限定，别去改全局 `.radio` 的 flex —— 别处那些弹窗（类型二选一之类）是
      故意一行一个的，顺手改会把它们一起挤变形。 */
#su-limit-modal .radio,
#su-expjump-modal .radio { flex: 1 1 200px; }

.seg {
  display: inline-flex;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 3px;
  gap: 3px;
  margin-bottom: 14px;
}
.seg-item {
  border: none;
  background: transparent;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text-2);
  cursor: pointer;
}
.seg-item.active { background: var(--surface); color: var(--text); box-shadow: var(--shadow); font-weight: 500; }
.seg-sm .seg-item { padding: 4px 10px; font-size: 12px; }

.pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-2);
}
.pill-ok { background: var(--ok-weak); border-color: #bfe3d4; color: var(--ok); }
.pill-bad { background: var(--bad-weak); border-color: #f4c9c4; color: var(--bad); }

.hint { font-size: 12px; color: var(--text-3); margin: 8px 0 0; line-height: 1.6; }
.hint.inline { margin: 0; }
.hint.error { color: var(--bad); }
.hint.success { color: var(--ok); }

/* ---------------- 登录 ---------------- */

.auth {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(180deg, #f7f8fa 0%, #eef0f4 100%);
}
.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 8px 30px rgba(16, 24, 40, 0.08);
}
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.auth-brand h1 { font-size: 17px; margin: 0; font-weight: 500; }
.auth-sub { margin: 2px 0 0; font-size: 12px; color: var(--text-3); }
.logo {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 500;
  flex-shrink: 0;
}
.auth-msg { font-size: 12px; margin: 12px 0 0; min-height: 16px; color: var(--bad); }
.auth-msg.success { color: var(--ok); }
.auth-divider { margin: 16px 0 14px; padding-top: 14px; border-top: 1px dashed var(--border-strong); text-align: center; }

/* ---------------- 主框架（侧边栏） ---------------- */

.app { display: flex; height: 100vh; overflow: hidden; }

/* 侧边栏 */
.sidebar {
  width: 232px;
  flex-shrink: 0;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}
.side-brand {
  height: 60px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  border-bottom: 1px solid var(--border);
}
.side-brand .logo { width: 32px; height: 32px; border-radius: 9px; font-size: 15px; }
.side-brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.side-brand-text strong { font-size: 14px; font-weight: 500; color: var(--text); }
.side-brand-text small { font-size: 11px; color: var(--text-3); }

.side-nav { flex: 1; padding: 14px 12px; display: flex; flex-direction: column; gap: 4px; overflow-y: auto; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  border: none;
  background: transparent;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-family: inherit;
  color: var(--text-2);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s, color 0.15s;
}
/* ⭐ 62x：选中态恢复原来的蓝色主题 —— 浅蓝底 + 左侧蓝条（inset 不占布局）；
   窄屏横排时蓝条挪到底部（见下面媒体查询里的 inset 0 -3px 0，一直没改过）。 */
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item.active { background: var(--accent-weak); color: var(--accent); font-weight: 500; box-shadow: inset 3px 0 0 var(--accent); }

/* 折叠父级（企业微信）：点击展开子菜单 */
.nav-group { display: flex; flex-direction: column; gap: 2px; }
.nav-group-head { justify-content: space-between; cursor: pointer; }
.nav-caret { margin-left: auto; font-size: 10px; line-height: 1; color: var(--text-3); transition: transform .15s ease; }
.nav-group.expanded .nav-caret { transform: rotate(90deg); }
.nav-group-head:hover .nav-caret { color: var(--text-2); }
.nav-sub { display: none; flex-direction: column; gap: 2px; }
.nav-group.expanded .nav-sub { display: flex; }
.nav-sub .nav-item { padding-left: 40px; font-size: 12.5px; }
.nav-sub .nav-item .nav-ico { width: 16px; height: 16px; }
.nav-ico { width: 18px; height: 18px; flex-shrink: 0; }

.side-foot { flex-shrink: 0; padding: 12px; border-top: 1px solid var(--border); }
.side-user { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.side-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 500; flex-shrink: 0;
}
.side-user-meta { display: flex; flex-direction: column; min-width: 0; }
.side-user-email { font-size: 13px; color: var(--text); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-user-role { font-size: 11px; color: var(--text-3); }
.side-actions { display: flex; gap: 8px; }
.side-actions .btn { flex: 1; }

/* 右侧内容区 */
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: 60px;
  flex-shrink: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 22px;
  gap: 16px;
}
.page-title { font-size: 17px; font-weight: 600; margin: 0; color: var(--text); }
.page-head { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.page-sub { margin: 0; font-size: 12px; color: var(--text-3); line-height: 1.4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.main { flex: 1; overflow-y: auto; padding: 22px; }
.pane { display: block; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; margin-bottom: 18px; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}
/* ⭐ 62x：标题颜色恢复成原来的灰（字号 15px / 字重 600 保留，用户只要求恢复颜色） */
.card h2 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-3);
  margin: 0 0 12px;
  letter-spacing: 0.01em;
}
.card h2:not(:first-child) { margin-top: 22px; }

.rule-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 12px; }

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

.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th {
  text-align: left;
  font-weight: 500;
  font-size: 12px;
  color: var(--text-2);
  background: var(--surface-2);
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.table td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: var(--surface-2); }
.ta-r { text-align: right; }
/* ⭐ 第 42 轮 d：短链表「点击」列 —— 表头和数字必须同一个对齐，否则看着错位。
   ⚠️⚠️ 这里必须写成 `.table th.su-hits` 这种**高特异性**选择器：上面 `.table th { text-align: left }`
   特异性是 (0,1,1)，比单独的 `.ta-r`(0,1,0) 高，所以表头上只写 `.ta-r` 是**永远不会生效**的。
   ⭐ 用户 2026-10-10 最新：这一列改成**居中**（表头「点击」、下面的点击数、第三方「暂不支持统计」三处都居中）。
   只给这一列用专属类名，别去改全局的 `th.ta-r`，免得动了别的表。 */
.table th.su-hits,
.table td.su-hits { text-align: center; }

.mono { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; color: var(--text-2); }
.url-cell { max-width: 320px; }
.smallnote { font-size: 12px; white-space: normal; }
.smallnote .sub { margin-top: 4px; color: var(--warn, #b26a00); font-family: inherit; }
.url-cell a { color: var(--accent); text-decoration: none; word-break: break-all; font-size: 12px; }
.url-cell a:hover { text-decoration: underline; }
.table-actions { display: flex; gap: 6px; justify-content: flex-end; }

.empty { text-align: center; padding: 40px; color: var(--text-3); font-size: 13px; }

/* 空态但账已经记下了：上面三个数 + 下面一个渠道排行（不是干巴巴一句「还没有」） */
.lk-empty { max-width: 620px; margin: 0 auto; text-align: left; }
.lk-empty-lead { margin: 0 0 12px; color: var(--text-2); text-align: center; }
.lk-sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.lk-sum-cell {
  display: flex; flex-direction: column; align-items: center;
  background: var(--surface-2); border-radius: var(--radius-sm); padding: 12px 8px;
}
.lk-sum-num { font-size: 24px; font-weight: 600; line-height: 1.2; color: var(--text); font-variant-numeric: tabular-nums; }
.lk-sum-cap { font-size: 12px; color: var(--text-3); }
.lk-rank { display: grid; gap: 7px; }
.lk-rank-row { display: grid; grid-template-columns: 84px 1fr 44px 38px; align-items: center; gap: 9px; font-size: 13px; }
.lk-rank-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.lk-rank-bar { height: 8px; border-radius: 4px; background: var(--border); overflow: hidden; }
.lk-rank-bar i { display: block; height: 100%; background: var(--accent); border-radius: 4px; }
.lk-rank-num { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--text); }
.lk-rank-pct { text-align: right; font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }

/* ---------------- 加好友数据 ---------------- */

.stats-bar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  padding: 12px 16px;
  margin: 10px 0 14px;
}
.stat-cell { display: flex; flex-direction: column; min-width: 108px; }
.stat-num { font-size: 22px; font-weight: 600; color: var(--text); line-height: 1.2; font-variant-numeric: tabular-nums; }
.stat-label { font-size: 12px; color: var(--text-3); }
.stat-note { margin-left: auto; font-size: 12px; color: var(--text-3); }

.th-sub { font-weight: 400; color: var(--text-3); font-size: 11px; }
.stat-nums { font-variant-numeric: tabular-nums; font-size: 13px; color: var(--text-2); white-space: nowrap; cursor: default; }
.stat-nums b { color: var(--accent); font-weight: 600; }
.stat-fail { font-size: 12px; color: var(--bad); cursor: help; }


/* ---------------- 数据查看：主体一排打勾 ---------------- */

.lk-corps { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 10px 0 0; }
.lk-corps-k { font-size: 12px; color: var(--text-3); }
.lk-corp-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lk-corp {
  display: inline-flex; align-items: center;
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  font-size: 12px; color: var(--text-2); user-select: none; overflow: hidden;
}
.lk-corp:hover { border-color: var(--border-strong); }
.lk-corp.on { background: var(--accent-weak); border-color: var(--accent); color: var(--accent); }
.lk-corp-main { display: inline-flex; align-items: center; gap: 5px; padding: 3px 4px 3px 11px; cursor: pointer; }
.lk-corp.on .lk-corp-main { padding-right: 6px; }
.lk-corp input { margin: 0; cursor: pointer; }
/* 删主体：平时藏着，鼠标放上去（或已勾中）才露出来，免得一排 × 太吵 */
.lk-corp-del {
  display: none; border: 0; background: none; cursor: pointer;
  font-family: inherit; font-size: 14px; line-height: 1;
  color: var(--text-3); padding: 2px 9px 3px 3px;
}
.lk-corp:hover .lk-corp-del, .lk-corp.on .lk-corp-del { display: inline-block; }
.lk-corp-del:hover { color: var(--bad); }
.lk-corp-id { font-size: 11px; color: var(--text-3); }
.lk-corp.on .lk-corp-id { color: var(--accent); }
.lk-corps .hint { font-size: 12px; margin: 0; }
/* ⭐ 别人分享给我的主体：虚线边 + 一个「共享」小牌，跟自己的区分开（而且没有 ×） */
.lk-corp.shared { border-style: dashed; }
.lk-corp-tag {
  font-size: 10px; line-height: 1; padding: 2px 5px; border-radius: 999px;
  background: var(--accent-weak); color: var(--accent); border: 1px solid var(--border);
}
.lk-corp.on .lk-corp-tag { background: transparent; color: var(--accent); border-color: var(--accent); }

/* ---------------- 数据查看：存档（导入的表按「客户添加日期」，一天一份） ---------------- */

.lk-arch { margin: 12px 0 0; padding-top: 10px; border-top: 1px dashed var(--border); }
.lk-arch-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.lk-arch-chips { display: flex; flex-wrap: wrap; gap: 6px; flex: 1 1 auto; min-width: 0; }
.lk-arch .hint { font-size: 12px; margin: 0; }
.arch-chip {
  display: inline-flex; align-items: center;
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  font-size: 12px; color: var(--text-2); user-select: none; overflow: hidden;
}
.arch-chip:hover { border-color: var(--border-strong); }
.arch-chip.on { background: var(--accent-weak); border-color: var(--accent); color: var(--accent); }
.arch-main { display: inline-flex; align-items: center; gap: 5px; padding: 3px 4px 3px 11px; cursor: pointer; }
.arch-chip.on .arch-main { padding-right: 6px; }
.arch-main input { margin: 0; cursor: pointer; }
.arch-day { font-variant-numeric: tabular-nums; }
/* ⚠️ 第 40 轮起 chip 上不再显示人数（用户要求「日期后面的数字取消」），
   .arch-c 这两条已经没人用了 —— 留着是因为万一又要把人数摆回来。 */
.arch-c { font-weight: 600; font-variant-numeric: tabular-nums; }
.arch-chip.soon .arch-c { color: var(--warn); }
/* 快过期的（还剩不到一周）：人数没了，就标在 chip 自己身上，
   提醒客户要么导出、要么放宽保留时间 */
.arch-chip.soon { border-color: var(--warn); color: var(--warn); }
.arch-del {
  display: none; border: 0; background: none; cursor: pointer;
  font-family: inherit; font-size: 14px; line-height: 1;
  color: var(--text-3); padding: 2px 9px 3px 3px;
}
.arch-chip:hover .arch-del, .arch-chip.on .arch-del { display: inline-block; }
.arch-del:hover { color: var(--bad); }
/* 保留时间：贴着存档那一行的最右边 */
.lk-keep {
  display: inline-flex; align-items: center; gap: 5px; flex: none; margin-left: auto;
  font-size: 12px; color: var(--text-3); white-space: nowrap; cursor: pointer;
}
.lk-keep select { width: auto; min-width: 74px; padding: 3px 6px; font-size: 12px; }
@media (max-width: 640px) {
  .lk-keep { margin-left: 0; width: 100%; justify-content: flex-end; }
}

/* ---------------- 数据查看：渠道卡片墙（一张卡一个渠道，底下带小渠道） ---------------- */

.lk-chans { margin: 14px 0 0; }
.chan-bar-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.chan-bar-row .hint { font-size: 12px; margin: 0; }
/* ⭐「选择渠道」入口按钮：贴在这一行最右（提示语后面），margin-left:auto 顶过去。
   角标是里面的小圆牌，显示勾了几个。 */
.chan-pick-open { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; }
.chan-pick-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--accent); color: #fff; font-size: 11px; font-weight: 600;
  line-height: 1; font-variant-numeric: tabular-nums;
}
/* 弹窗里按主体分组的渠道勾选。
   ⭐ 2026-10-09 用户报「这个拉太长了，改成一排 2 个或者 4 个稍微小一点的」——
   原来 minmax(168px, 1fr) 在 520px 的弹窗里只塞得下 1 列，16 个渠道拉了一长条。
   现在按「明确列数」排：宽屏 4 列、窄一点 3 列、手机 2 列，每一项再收小一圈。 */
.cp-group { margin: 0 0 14px; }
.cp-group-head {
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  margin: 0 0 7px; padding: 0 0 6px; border-bottom: 1px solid var(--border);
}
.cp-group-head strong { font-size: 13px; }
.cp-group-head .opt { font-size: 11px; color: var(--text-3); margin-left: auto; }
.cp-items { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.cp-item {
  display: flex; align-items: center; gap: 6px; min-width: 0; cursor: pointer;
  border: 1px solid var(--border); border-radius: 6px; padding: 5px 8px;
  font-size: 12px; color: var(--text-2); background: var(--surface);
}
.cp-item:hover { border-color: var(--border-strong); color: var(--text); }
.cp-item.on { border-color: var(--accent); background: var(--accent-weak); color: var(--text); }
.cp-item input { margin: 0; flex: none; width: 13px; height: 13px; cursor: pointer; }
.cp-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-num { flex: none; font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }
/* ⚠️ 三档都要写死列数（别用 auto-fill：弹窗宽度不定，auto-fill 会退回 1 列，又变成长条） */
@media (max-width: 900px) { .cp-items { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .cp-items { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* ⭐「选择渠道」这个弹窗单独加宽 + 限高：
   ① 加宽到 760px —— 一排 4 个渠道，520px 下每项只剩 105px、名字全被截断；
   ② ⚠️⚠️ **必须限高**（`max-height: 90vh` + flex column）：它用的是 `.modal-card-lg`，
      而 `.modal-card-lg` 只有 max-width、**没有高度约束**（只有 `.modal-card-xl` 才有 90vh）。
      渠道一多（几十个 / 多个主体）弹窗就**无限变高、直接长过屏幕**，
      底下的「全部取消 / 完成」被顶到屏幕外，用户只能滚页面 —— 用户 2026-10-09 报的「弹窗很容易变得超长」。
      限高后靠中间那段 `.imp-form`（`flex:1 1 auto` / `min-height:0` / `overflow-y:auto`）自己滚。 */
.modal-card#chan-pick-card { max-width: 760px; display: flex; flex-direction: column; max-height: 90vh; }
.chan-list {
  /* ⭐ 2026-10-09 用户第二次改：「大卡片排盘尽量对齐」→ **每行等高**。
     走过一轮弯路：原来 grid 会把整行拉到同一高度，用户当时嫌「有分类和没分类的
     一样高太突兀」；改成多列后不再等高，用户又嫌「参差不齐、不对齐」。
     现在明确要**每行等高**，所以回到 grid —— 但这次是**有意的**，
     配下面 .chan-row 内部「内容靠上、空白留底」的排版，短卡不会显得空得离谱。

     ⚠️ 别再随手改回 column-count（那是不等高的瀑布流）；
        也别加 align-items: start（那又会退回参差不齐）。用户要的就是对齐。 */
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  /* 行内等高（grid 默认 stretch 就是），显式写出来提醒后来人这是刻意的 */
  align-items: stretch;
}
.chan-row {
  /* 卡内从上往下排：头 → 条 → 小分类。内容靠上，短卡多出来的高度留在底部
     （这就是「对齐」的代价：没小分类的卡底下会空一点，但整行是齐的）。 */
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface); padding: 14px 16px 13px;
  /* ⭐ 2026-10-09：整张卡就是一个 <label>，点卡上任意位置都能打勾/取消（用户要求） */
  cursor: pointer;
  /* ⚠️ 小渠道区贴着卡底边会显得「和底部重叠」，底部多留一点呼吸空间 */
  padding-bottom: 14px;
}
.chan-row:hover { border-color: var(--border-strong); }
.chan-row.on { border-color: var(--accent); background: var(--accent-weak); }
.chan-head { display: flex; align-items: center; gap: 9px; }
.chan-head input { margin: 0; cursor: pointer; flex: none; width: 15px; height: 15px; }
.chan-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; font-weight: 600; }
/* ⚠️ 第 41 轮：卡上那个「占比 xx%」（.chan-share）按用户要求去掉了 ——
   这条样式现在没人用，留着是万一哪天又要摆回来。 */
.chan-share { flex: none; font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.chan-num { flex: none; min-width: 44px; text-align: right; font-size: 24px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.chan-bar { margin-top: 9px; height: 6px; border-radius: 3px; background: var(--border); overflow: hidden; }
.chan-bar i { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
/* 小渠道区：1~2 个**一行一个**（谁多少人一眼看清，也不占地方）；
   3 个以上切两列（⭐ 阈值是 3 不是 4 —— 3 个走两列 = 2 行，
   和 4 个的 2 行一样高，卡片高度才齐；若留 3 个走单列就是 3 行，
   反而比 4 个的卡还高，看着更乱） */
.chan-subs {
  display: flex; flex-direction: column; gap: 5px;
  margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--border);
}
/* 3 个以上：两列。
   ⚠️⚠️ 2026-10-09 用户报「丁的卡片底部还是和小渠道有重叠起来」——
   根因就是这里原来有 **`max-height: 154px; overflow: hidden`**：
   11 个细分双列 = 6 行 ≈ 175px > 154px → **最后一行被硬裁掉一半**，
   看起来就像小渠道和卡片底边糊在一起。
   去掉硬裁，让卡片按内容自然长高（.chan-list 是 grid 等高，同一行别的卡会跟着齐）。 */
.chan-subs-wide {
  display: grid; grid-template-columns: 1fr 1fr; gap: 5px 7px;
}
/* 小渠道做成小方块：名字 + 人数，一眼扫完 */
.chan-sub {
  display: inline-flex; align-items: baseline; gap: 5px; min-width: 0;
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px;
  padding: 3px 8px; font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums;
}
.chan-sub b { font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chan-sub-c { color: var(--text-3); flex: none; }
/* 两列时让名字自己截断，人数固定在右边，一行看起来是齐的 */
.chan-subs-wide .chan-sub { justify-content: space-between; }
/* 「没再往下分」：行内小字，**不再单独占一段**（原来带一条虚线上边距，等于给空卡也留了高度） */
.chan-none { display: inline-block; margin-top: 9px; font-size: 12px; color: var(--text-3); }
/* 渠道卡片墙的列数：宽屏 3 列；中等屏 2 列；窄屏 1 列（卡名会被截断就不好看了） */
@media (max-width: 1080px) { .chan-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .chan-list { grid-template-columns: minmax(0, 1fr); } }
/* 右下角那块合计：只勾了渠道才出现，靠右对齐 */
.chan-total-row { display: flex; justify-content: flex-end; margin-top: 12px; }
.chan-total {
  display: inline-flex; align-items: baseline; gap: 4px;
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 7px 14px; font-size: 13px; color: var(--text-2); font-variant-numeric: tabular-nums;
}
.chan-total b { font-size: 17px; font-weight: 600; color: var(--accent); }

/* ---------------- 导入的客户明细（企微后台导出） ---------------- */

/* 四个数：并排一行，窄了折成两行。（⚠️ 不能再用外面那套 .stat-cell —— 它按外层页面
   宽度算的，放进这个窄弹窗会被挤成一竖条，看着像坏了。） */
.imp-sum {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 4px 0 14px;
}
.imp-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  padding: 9px 6px;
}
.imp-num { font-size: 21px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; }
.imp-cap { font-size: 11px; color: var(--text-3); white-space: nowrap; }
.imp-sub { grid-column: 1 / -1; font-size: 12px; color: var(--text-3); text-align: center; margin-top: 2px; }

/* ⚠️ 导入弹窗里那四块小榜单（按渠道 / 按标签 / 按成员 / 按日期）已经全部按用户要求删掉，
   `.imp-grid` / `.imp-block` / `.imp-h3` 现在没有 HTML 用它了 —— 保留是为了 impPaint()
   万一在别处被调用还能成型，别再往导入弹窗里塞。 */
.imp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 12px 0 14px;
}
@media (max-width: 640px) {
  .imp-grid { grid-template-columns: 1fr; }
}
.imp-block {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  padding: 10px 12px 12px;
}
.imp-h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  margin: 0 0 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.imp-list { max-height: 260px; overflow-y: auto; }
.imp-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
}
.imp-row:hover { background: var(--surface-3, var(--surface-2)); }
.imp-row.off { cursor: default; }
.imp-row.off:hover { background: none; }
.imp-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.imp-count { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--accent); }
.imp-bar { height: 4px; border-radius: 2px; background: var(--accent); opacity: .55; flex: none; }
.imp-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-2);
  margin: 0 0 10px;
}
.imp-filter b { color: var(--accent); }
/* 弹窗里那行「算到哪个主体名下」：输入框 + 右边一句解释 */
.imp-corp { display: flex; align-items: flex-end; gap: 10px; margin: 12px 0 4px; }
.imp-corp .opt { font-weight: 400; color: var(--text-3); font-size: 11px; }

/* 导入弹窗里那个「带后缀的再分小渠道」勾选框（一行字，勾不勾都看得清） */
.mini-check { display: inline-flex; align-items: flex-start; gap: 7px; cursor: pointer; font-size: 12.5px; line-height: 1.5; color: var(--text-2); }
.mini-check input { margin: 2px 0 0; flex: 0 0 auto; }
.mini-check:hover { color: var(--text-1); }

.modal-card-lg { max-width: 520px; text-align: left; }
.modal-card-lg .modal-head { margin-bottom: 12px; }

/* ══ ⭐ 62i：给账号授权收费功能的弹窗（原来用 window.prompt 两步，用户要求换掉） ══
   四个功能一人一行（点一下选中），时长是几颗胶囊，底下还能自己填天数。 */
.grant-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.grant-item {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px;
  width: 100%; text-align: left; cursor: pointer; font: inherit;
  padding: 9px 12px; border: 1px solid var(--border); border-radius: 10px;
  background: var(--surface-2, rgba(127, 127, 127, .06)); color: var(--text-1);
}
.grant-item:hover { border-color: var(--accent, #4a7dff); }
.grant-item.on { border-color: var(--accent, #4a7dff); background: rgba(74, 125, 255, .12); }
.grant-item-t { font-weight: 600; font-size: 13.5px; white-space: nowrap; }
.grant-item-d { font-size: 12px; color: var(--text-2); }
.grant-item-c { font-size: 12px; color: var(--text-3, var(--text-2)); white-space: nowrap; }
.grant-item.on .grant-item-c { color: var(--accent, #4a7dff); font-weight: 600; }
/* ⚠️ 时长那排要能换行：手机上 5 颗胶囊一行放不下（父级没有 flex-wrap 会顶出卡片） */
.grant-days-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.grant-k { font-size: 12.5px; color: var(--text-2); white-space: nowrap; }
.grant-days { display: flex; gap: 6px; flex-wrap: wrap; flex: 1 1 auto; }
.grant-day {
  cursor: pointer; font: inherit; font-size: 12.5px; padding: 5px 12px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface-2, rgba(127, 127, 127, .06)); color: var(--text-1);
}
.grant-day:hover { border-color: var(--accent, #4a7dff); }
.grant-day.on { border-color: var(--accent, #4a7dff); background: rgba(74, 125, 255, .14); font-weight: 600; }
@media (max-width: 520px) {
  .grant-item { grid-template-columns: 1fr auto; }
  .grant-item-d { grid-column: 1 / -1; }
}
/* 地址比较长，可信企业/投诉页那个弹窗要给宽一点，不然框里只看得到前半截 */
.modal-card-xl { max-width: 680px; text-align: left; }
.modal-card-xl .modal-head { margin-bottom: 12px; }
/* 「新建链接」内容多：卡片限高、中间那段自己滚，保存按钮钉在底部（不用滚到底找按钮） */
.modal-card-xl { display: flex; flex-direction: column; max-height: 90vh; }
.pg-form { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding-right: 4px; }
/* 导入弹窗跟「新建链接」一个毛病：内容能长到一屏装不下，
   中间这段也得自己滚，否则底栏（开始导入）会被顶出卡片、跟下面的页面叠在一起。 */
.imp-form { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding-right: 4px; }
/* ⭐ 62e（本轮）：所有弹窗底栏的按钮组**整体靠右**（右下角）。
   取消 / 关闭 在 保存 / 确定 的左边、保存 / 确定 落右下角。
   带 `flex:1` 提示语的弹窗（pg / chan-pick / imp / al）靠提示语把按钮挤到右边，
   这里再补一句 flex-end 把没有提示语的那种（tk-link / md / su-limit / su-expjump）也统一靠右。 */
.modal-foot { flex: 0 0 auto; display: flex; align-items: center; gap: 10px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); flex-wrap: wrap; justify-content: flex-end; }
/* ⚠️ 底栏里那组按钮**自己也要能换行**：`.modal-foot` 只保证「提示文字」和「按钮组」
   这两块之间换行，按钮组内部默认 nowrap（`.row-inline` 没有 flex-wrap），
   而按钮又是 `flex-shrink: 0`（不许压扁）→ 组比卡片内宽时就整组往右溢出。
   窗口再窄一点（手机上 320px）按钮会自动折成两行，而不是从边框里伸出去。 */
.modal-foot .row-inline { flex-wrap: wrap; }
/* ⭐ 第 48 轮 b：导入弹窗底栏那四个按钮**等宽占满一整行**（用户要求）。
   `flex: 1 1 0` = 基准 0，剩下的空间四家平分 → 不管窗口多宽都是四个一样宽的按钮。
   ⚠️ 必须留 `min-width: 104px`：基准 0 的话浏览器以为「四个都塞得下」永不换行，
   360px 那种窄屏上每颗只剩 70 多 px、「清空这个主体」这行字会被切掉。
   有了这个下限，放不下时会自动折成两行（2+2），而不是把字压没。
   ⚠️ 统一 padding / 字号 / 高度：这四个按钮混着 .btn 和 .btn-sm 两号，
   不拉平的话一排里高矮不齐很难看（手机媒体查询里两号尺寸又不一样）。 */
#imp-modal .imp-foot-btns { width: 100%; }
#imp-modal .imp-foot-btns .btn { flex: 1 1 0; min-width: 104px; padding: 8px 10px; font-size: 12.5px; min-height: 38px; }
.edit-body .field > span { font-size: 12px; }

/* 生成的地址：输入框独占一行，按钮另起一行，复制出来才完整 */
.gen-url { width: 100%; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }
.gen-btns { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }

.mini-note {
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  padding: 10px 12px;
  margin: 4px 0 12px;
}
.mini-note p { margin: 0 0 6px; font-size: 12px; color: var(--text-2); line-height: 1.7; }
.mini-note p:last-child { margin-bottom: 0; }
.mini-note b { color: var(--text); font-weight: 500; }

.owner-tag { font-size: 11px; color: var(--text-3); margin-top: 2px; }

/* 链接库：勾选列 */
.sel-col { width: 40px; text-align: center; white-space: nowrap; }
.sel-col .checkbox-cell { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--text-3); cursor: pointer; }
.sel-link { width: 16px; height: 16px; cursor: pointer; vertical-align: middle; }

/* ---------------- 首页概览（仪表盘） ---------------- */

.dash { display: flex; flex-direction: column; gap: 18px; }

.dash-hero {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
  background: linear-gradient(120deg, var(--accent) 0%, #1d4ed8 100%);
  color: #fff; border-radius: var(--radius); padding: 22px 24px;
  box-shadow: 0 8px 24px rgba(50, 99, 224, 0.18);
}
.dash-title { margin: 0 0 6px; font-size: 20px; font-weight: 600; }
.dash-sub { margin: 0; font-size: 13px; opacity: 0.92; line-height: 1.6; max-width: 720px; }
.dash-hero .btn-primary { background: #fff; color: var(--accent); border-color: #fff; }
.dash-hero .btn-primary:hover { background: rgba(255,255,255,0.9); }

.dash-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; }

.stat-card {
  display: flex; align-items: center; gap: 14px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 18px; box-shadow: var(--shadow); transition: box-shadow .15s ease;
}
/* ⭐ 官网风：hover 只加深阴影、不位移（官网卡片是沉稳的，不弹跳） */
.stat-card:hover { box-shadow: 0 6px 18px rgba(17,24,39,0.08); }
.stat-ico {
  flex: 0 0 auto; width: 46px; height: 46px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 700; color: #fff;
}
/* ⭐ 2026-10-10 首页换了一组指标（页面访问 / 投诉 / 短链 / 卡片），图标跟着换 */
.ico-trust { background: linear-gradient(135deg, #19b8a6, #0fa391); }
.ico-complain { background: linear-gradient(135deg, #ff8a4c, #ff6a3d); }
.ico-feedback { background: linear-gradient(135deg, #8b5cf6, #7c3aed); }
.ico-pending { background: linear-gradient(135deg, #ff5c8a, #f53d72); }
.ico-short { background: linear-gradient(135deg, #2bb1ff, #1890ff); }
.ico-card { background: linear-gradient(135deg, #4f7cff, #3b6ef5); }
/* ⭐ 62j：「合集页」功能卡那颗图标 */
.ico-taoke { background: linear-gradient(135deg, #ffa53c, #f2781b); }
/* ⭐ 64k：「传奇BOSS」功能卡那颗图标（红系 —— 打怪） */
.ico-boss { background: linear-gradient(135deg, #ff6b6b, #e03131); }
.stat-body { min-width: 0; }
.stat-val { font-size: 26px; font-variant-numeric: tabular-nums; font-weight: 700; line-height: 1.1; color: var(--text); }
.stat-label { font-size: 12.5px; color: var(--text-2); margin-top: 2px; }
/* ⭐ 第 56 轮：六格下面那行「今天 X · 昨天 Y」（抄的引流宝首页那种双行卡片的写法） */
.stat-sub { font-size: 11.5px; color: var(--text-3); margin-top: 3px; font-variant-numeric: tabular-nums; }

/* ---------------- 首页数据中心（第 56 轮：分时访问 + 近 7 天） ---------------- */

/* 左图右表；窄屏自动叠成一列（见本块末尾的媒体查询） */
.dc-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 14px;
  align-items: stretch;
}
/* 卡片自带 20px 内边距，这里要的是「表头贴着卡片边」，所以清零自己加 */
.dc-card { padding: 0; margin-bottom: 0; overflow: hidden; }
.dc-card .preview-head h2 { font-size: 13px; color: var(--text-2); font-weight: 500; }
.dc-peak { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }

.dc-sum { display: flex; flex-wrap: wrap; gap: 12px 30px; padding: 14px 16px 2px; }
.dc-sum-i { display: flex; flex-direction: column; gap: 2px; min-width: 76px; }
.dc-sum-i b { font-size: 22px; font-weight: 700; line-height: 1.1; color: var(--text); font-variant-numeric: tabular-nums; }
.dc-sum-i span { font-size: 12px; color: var(--text-3); }

.dc-chart { position: relative; padding: 10px 16px 0; }
/* ⚠️ 折线是 preserveAspectRatio="none" 拉的（宽高各自铺满），所以描边必须
   `vector-effect: non-scaling-stroke`，否则横向拉伸会把 2px 的线压成一头粗一头细。
   坐标刻度是 HTML 画的（不吃 SVG 拉伸），点位置按 i/23 算，跟线严格对齐。 */
.dc-svg { display: block; width: 100%; height: 165px; }
.dc-grid-line { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.dc-line { stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.dc-peak-dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2; vector-effect: non-scaling-stroke; }
.dc-none {
  position: absolute; left: 0; right: 0; top: 0; bottom: 0; margin: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 12.5px; color: var(--text-3); pointer-events: none;
}
.dc-x { position: relative; height: 20px; margin: 2px 16px 0; }
/* ⚠️ 刻度是绝对定位的，窄屏不加 nowrap 会被挤成「23」换行「点」 */
.dc-x span { position: absolute; top: 0; font-size: 11px; color: var(--text-3); white-space: nowrap; }
.dc-note { margin: 0; padding: 10px 16px 14px; font-size: 11.5px; color: var(--text-3); line-height: 1.6; }

.dc-tbl { font-size: 12.5px; }
/* ⚠️ `.table th { text-align: left }` 的特异性比 `.dc-r` 高（(0,1,1) > (0,1,0)），
   表头要右对齐**必须**写成 `.table th.dc-r` 这种带 .table 的写法（跟 .su-hits 一个坑）。 */
.dc-tbl .dc-r,
.table th.dc-r,
.table td.dc-r { text-align: right; }
/* 今天那行挑出来（表里是倒序，今天排最上面） */
.dc-tbl tr.dc-today td { background: var(--accent-weak); font-weight: 600; }
.dc-none-td { text-align: center; color: var(--text-3); font-size: 12px; padding: 22px 0; }

@media (max-width: 1000px) {
  .dc-grid { grid-template-columns: minmax(0, 1fr); }
  .dc-card { padding: 0; }
}
/* 窄屏（手机后台）：六格挤成两列之后，图标 + 内边距会把「今天 183 · 昨天 96」挤到换行，
   所以小屏把图标和内边距一起收一点，四个汇总数也把间距收紧（一行放得下四个）。 */
@media (max-width: 640px) {
  .stat-card { padding: 12px 13px; gap: 10px; }
  .stat-ico { width: 38px; height: 38px; border-radius: 10px; font-size: 15px; }
  .stat-val { font-size: 22px; }
  .stat-sub { font-size: 11px; }
  .dc-sum { gap: 10px 12px; }
  .dc-sum-i { min-width: 66px; }
  .dc-sum-i b { font-size: 19px; }
}

.dash-meta { display: flex; gap: 22px; flex-wrap: wrap; font-size: 12.5px; color: var(--text-2); }
.dash-meta b { color: var(--text); font-weight: 600; }


/* ---------------- 二维码工坊 ---------------- */

.qr-studio {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 430px);
  gap: 16px;
  align-items: start;
}
.qra-ctrl { min-width: 0; }
.qra-preview { position: sticky; top: 12px; }

.qra-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.qra-tab {
  appearance: none;
  font-family: inherit;
  font-size: 13px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.qra-tab:hover { color: var(--text); border-color: var(--text-3); }
.qra-tab.active {
  background: var(--accent-weak);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.qra-panel { display: none; }
.qra-panel.active { display: block; }

.qra-group {
  margin: 18px 0 10px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text-2);
}
.qra-group:first-child { border-top: 0; padding-top: 0; margin-top: 0; }

.qra-note { margin: 0 0 12px; font-size: 12.5px; color: var(--text-3); line-height: 1.65; }
.qra-hint { font-size: 11.5px; color: var(--text-3); margin-top: 5px; line-height: 1.5; }

.qra-row { margin: 10px 0; }
.qra-lab { display: block; font-size: 12px; color: var(--text-3); margin-bottom: 5px; }
.qra-ctl { display: flex; align-items: center; gap: 8px; }
.qra-ctl > select,
.qra-ctl > input[type="text"] { width: 100%; }
.qra-ctl > textarea { width: 100%; }
.qra-ctl > input[type="range"] {
  flex: 1 1 auto;
  width: auto;
  margin: 0;
  accent-color: var(--accent);
}
.qra-ctl > input[type="number"] { width: 100%; }
.qra-ctl > input[type="file"] { flex: 1 1 auto; width: auto; }

.qra-stat { font-size: 13px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }

.qra-val {
  font-size: 12px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  min-width: 38px;
  text-align: right;
  flex: 0 0 auto;
}
.qra-unit { font-size: 11.5px; color: var(--text-3); flex: 0 0 auto; }

.qra-row.qra-check { display: flex; align-items: center; gap: 9px; }
.qra-row.qra-check .qra-lab { margin: 0; order: 2; font-size: 13px; color: var(--text-2); }
.qra-row.qra-check .qra-ctl { order: 1; flex: 0 0 auto; }
.qra-row.qra-check input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--accent); }

/* ⭐ 62u+：「显示文字」勾选框 +「文字来源」下拉合并成一排（原来上下两行） */
.qra-row.qra-checkselect { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.qra-cs-left { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.qra-cs-left input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--accent); }
.qra-cs-left .qra-cs-lab { font-size: 13px; color: var(--text-2); cursor: pointer; }
.qra-cs-right { display: flex; align-items: center; gap: 8px; flex: 1 1 240px; min-width: 200px; }
.qra-cs-right .qra-cs-sublab { flex: 0 0 auto; font-size: 12px; color: var(--text-3); }
.qra-cs-right select { flex: 1 1 auto; width: 100%; }
.qra-row.qra-checkselect .qra-hint { flex: 1 1 100%; margin-top: 2px; }

.qra-pal { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.qra-pal-i { display: inline-flex; align-items: center; gap: 2px; }
.qra-pal-i input[type="color"] {
  width: 34px;
  height: 30px;
  padding: 2px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
}
.qra-pal-i .qra-x { width: 18px; height: 18px; font-size: 12px; border-radius: 4px; }
.qra-pal-add { padding: 4px 9px; font-size: 12px; }

.qra-stops { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.qra-stop { display: flex; align-items: center; gap: 8px; }
.qra-stop input[type="color"] {
  width: 38px;
  height: 28px;
  padding: 2px;
  flex: 0 0 auto;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
}
.qra-stop input[type="range"] { flex: 1 1 auto; margin: 0; accent-color: var(--accent); }
.qra-stop .qra-val { min-width: 40px; }
.qra-x {
  appearance: none;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  line-height: 1;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text-3);
  font-size: 14px;
  cursor: pointer;
}
.qra-x:hover { color: var(--bad); border-color: var(--bad); }

.qra-btns { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.qra-btns .btn { flex: 1 1 auto; }

.qra-ctrl input[type="color"] {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
  height: 34px;
  padding: 2px;
}
.qra-ctrl input[type="file"] { font-size: 12.5px; color: var(--text-2); }
.qra-ctrl input[type="file"]::file-selector-button {
  font-family: inherit;
  font-size: 12.5px;
  margin-right: 10px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  color: var(--text);
  cursor: pointer;
}
.qra-ctrl input[type="file"]::file-selector-button:hover { border-color: var(--text-3); }

.qra-canvas-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #fff;
  background-image:
    linear-gradient(45deg, #eef0f4 25%, transparent 25%),
    linear-gradient(-45deg, #eef0f4 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #eef0f4 75%),
    linear-gradient(-45deg, transparent 75%, #eef0f4 75%);
  background-size: 16px 16px;
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
}
#qra-canvas {
  display: block;
  width: 100%;
  max-width: 360px;
  height: auto;
  border-radius: 4px;
}
.qra-canvas-wrap.qra-portrait #qra-canvas { max-width: 260px; width: auto; max-height: 520px; }
.qra-canvas-wrap.qra-drag { cursor: move; }
.qra-canvas-wrap.qra-drag #qra-canvas { cursor: move; }

.qra-preview .hint { text-align: center; font-variant-numeric: tabular-nums; }

@media (max-width: 1080px) {
  .qr-studio { grid-template-columns: 1fr; }
  .qra-preview { position: static; }
}

/* ---------------- 工具条 / 预览 ---------------- */

/* 数据查看那一条工具条：左边「我的/共享给我/全部用户」，右边一排按钮，**同一行**。
   ⚠️ 这里刻意不换行（用户要求「跟下面一排合并」）：
      seg 让它可以收缩（flex: 0 1 auto + min-width:0），按钮组保持自身宽度贴在右边，
      中间用 margin-left:auto 顶开。窗口实在窄到放不下才让 buttons 换到第二行，
      但那时候至少不是「压住上面那行」而是整块掉下去。 */
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 4px; row-gap: 8px; }
.toolbar-wrap { flex-wrap: wrap; }
/* 输入框默认 width:100%，不限制的话筛选区里每个控件都会独占一整行 */
.toolbar .field.compact { flex: 0 1 168px; }
.toolbar .field.compact.grow { flex: 1 1 220px; }
.toolbar .seg { margin-bottom: 0; }
.toolbar .field > span { white-space: nowrap; }
.toolbar-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; flex: none; }
/* 数据查看那条：seg 能缩，按钮保持不缩，两者永远并排 */
.toolbar .seg { flex: 0 1 auto; min-width: 0; overflow: hidden; }
.toolbar .seg .seg-item { white-space: nowrap; }

.preview-box { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; margin: 14px 0; }
.preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.preview-head h2 { margin: 0; }
/* ⭐ 62g：卡片头下面统一留白。原来 .preview-head 紧贴下面第一行内容（margin 0），
   各板块的「说明文字 / 筛选行 / 表单 / 表格」都跟头挤在一起 —— 用户反馈的「跟上面重叠」。
   ⚠️ 19 处 .preview-head 全是 .card 的直接子元素，所以写 .card > 就行。 */
.card > .preview-head { margin-bottom: 16px }
/* ⭐ 62u+：区块说明并入标题行右侧（投诉记录 / 预警通知，不再单独占一行） */
.head-note { margin: 0; max-width: 62%; text-align: right; font-size: 12px; line-height: 1.5; color: var(--text-3); }
.preview-list { max-height: 190px; overflow-y: auto; padding: 10px 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.preview-list .tag {
  background: var(--accent-weak);
  color: var(--accent);
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 12px;
  font-family: ui-monospace, Menlo, Consolas, monospace;
}
.preview-list .more { color: var(--text-3); font-size: 12px; padding: 3px 8px; }

.actions { margin-top: 14px; }

/* ---------------- 主体列表 ---------------- */

.corp-list { display: flex; flex-direction: column; gap: 10px; }
.corp-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.corp-item .ci-main { flex: 1; min-width: 0; }
.corp-item .ci-name { font-weight: 500; font-size: 13px; }
.corp-item .ci-meta { font-size: 12px; color: var(--text-3); margin-top: 2px; word-break: break-all; }
.corp-item .ci-actions { display: flex; gap: 6px; flex-shrink: 0; }

/* 可信企业 / 投诉页弹窗里的一小块内容，浅底 + 细边框，跟普通表单区分开 */
.block-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 12px; background: var(--surface-2); }
.block-card .bc-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.block-card .bc-head strong { font-size: 13px; }
.block-card .bc-head .opt { color: var(--text-3); font-size: 12px; }
.block-card input[readonly] { background: #f1f3f7; color: var(--text-2); }

/* 可信企业页的工商信息：两列排，窄屏落回一列 */
.ent-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.ent-grid .field { margin-bottom: 10px; }
#ent-scope { font-family: inherit; font-size: 13px; line-height: 1.6; min-height: 68px; }
@media (max-width: 640px) { .ent-grid { grid-template-columns: 1fr; } }

/* 「我想用自己的地址」默认折叠，别一打开就让人以为要填 */
.adv-block { border-top: 1px dashed var(--border); padding-top: 12px; margin-top: 4px; }
.adv-block > summary { cursor: pointer; font-size: 13px; color: var(--text-2); user-select: none; }
.adv-block > summary:hover { color: var(--accent); }
.adv-block[open] > summary { margin-bottom: 4px; }

/* 「可信企业 / 投诉页」整页：一个主体一张卡，卡里两行地址 + 可折叠的工商信息 */
.pg-line { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.pg-line .pg-tag { flex: 0 0 76px; font-size: 12.5px; color: var(--text-2); }
.pg-line .gen-url { flex: 1 1 auto; min-width: 0; }
.pg-ent { margin-top: 12px; border-top: 1px dashed var(--border); padding-top: 10px; }
.pg-ent > summary { cursor: pointer; font-size: 12.5px; color: var(--text-2); user-select: none; list-style: none; }
.pg-ent > summary::-webkit-details-marker { display: none; }
.pg-ent > summary::before { content: '▸ '; color: var(--text-3); }
.pg-ent[open] > summary::before { content: '▾ '; }
.pg-ent > summary:hover { color: var(--accent); }
.pg-ent textarea { font-family: inherit; font-size: 13px; line-height: 1.6; min-height: 68px; }
.pg-ent .ent-grid { margin-top: 10px; }
/* 弹窗里「资料名称」那一行：下拉能缩，别把右边「存进信息库」挤出去 */
.lic-pick { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 12px; }
.lic-pick .pg-tag { flex: 0 0 auto; font-size: 12.5px; color: var(--text-2); }
.lic-pick select { flex: 1 1 160px; min-width: 0; max-width: 300px; }
/* 营业执照信息库：一套一条，右侧改名 / 删除 */
.lic-box > summary { cursor: pointer; font-size: 13px; color: var(--text-2); user-select: none; list-style: none; }
.lic-box > summary::-webkit-details-marker { display: none; }
.lic-box > summary::before { content: '▸ '; color: var(--text-3); }
.lic-box[open] > summary::before { content: '▾ '; }
.lic-box > summary:hover { color: var(--accent); }
.lic-box > summary .opt { color: var(--text-3); font-size: 12px; margin-left: 8px; }
.lic-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px dashed var(--border); }
.lic-item:first-child { border-top: 0; padding-top: 2px; }
.lic-main { flex: 1 1 auto; min-width: 0; }
.lic-name { font-size: 13px; }
.lic-meta { font-size: 12px; color: var(--text-3); margin-top: 2px; word-break: break-all; }
.lic-actions { flex: 0 0 auto; display: flex; gap: 6px; }
@media (max-width: 640px) {
  .pg-line { flex-wrap: wrap; gap: 4px; }
  .pg-line .pg-tag { flex: 0 0 100%; }
  .lic-pick select { max-width: none; }
}

/* 刚生成出来的卡密：就地列出来，点一下就复制 */
.card-out-head { font-size: 12.5px; color: var(--text-3); margin: 8px 0 6px; }
.card-out-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-top: 1px dashed var(--border); }
.card-out-row:first-of-type { border-top: 0; }
.card-out-code { flex: 1 1 auto; min-width: 0; font-size: 14px; letter-spacing: .5px; word-break: break-all; }
.card-out-row .hint { flex: 0 0 auto; font-size: 12px; }

/* 「可信企业 / 投诉页」板块顶上合成一行：左边营业执照信息库，右边添加信息 + 两个新增按钮 */
.pg-pane-head { align-items: flex-start; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
/* ⚠️ 原来这里提到 `.lic-box` 只剩「我的域名」折叠块在用 —— 「我的域名」已删
   （2026-10-09 第三十四轮），`.lic-box` 现在**没有任何元素在用**了（样式本身留着，
   以后再有折叠块可以直接套）。 */
.pg-acts { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
/* 弹窗顶部那句说明 */
.pg-modal-hint { margin: 0 0 12px; padding: 8px 10px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
/* ⭐⭐⭐ 「这条是哪种链接」两张卡的样式（.pg-kind-pick / .pg-kind / .pg-kind.on / 那条 640px 媒体查询）
   **全部删了**（第 49 轮 c，2026-10-11 用户要求）—— 那一块连 DOM 一起没了，别留死样式。
   ⚠️ 历史坑记一笔（元素已删，仅供考古）：那两张选项卡原来 :hover 上写了 transform，
   鼠标一划过去整张卡往上蹿，用户反馈过「选项卡会上移」。以后再写类似的选项卡别用 transform。 */

/* 工商信息那 6 栏：三列铺开，弹窗短一半（新建可信企业页时不用往下滚那么久） */
.ent-grid.g3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 760px) { .ent-grid.g3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .ent-grid.g3 { grid-template-columns: 1fr; } }
/* 列表按「可信企业页 / 投诉页」分组，各带一个小标题 */
.pg-group { margin-bottom: 6px; }
.pg-group-head { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; font-size: 13px; font-weight: 600; }
.pg-group-head .pill { font-weight: 400; }
.pg-group-empty { color: var(--text-3); font-size: 12.5px; margin: 0 0 8px; }

/* ⭐⭐「我的域名」那块样式整段删了（2026-10-09 第三十四轮）：
   .dom-box / .dom-title / .dom-steps / .dom-step / .dom-host / .dom-row / .dom-seg-row。
   绑自己域名功能已取消，页面上再没有这些元素了。 */

/* 投诉记录：客户写的那段可能很长，给它一个宽一点的列 + 换行 */
#cmp-table .cell-note { max-width: 380px; white-space: pre-wrap; word-break: break-word; line-height: 1.55; }
#cmp-table .sub { margin-top: 4px; font-size: 12px; color: var(--text-3); }

/* 客户提交的图片证据：列表里只给缩略图，点开铺满屏幕看 */
.cmp-imgs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.cmp-thumb {
  width: 52px; height: 52px; object-fit: cover;
  border: 1px solid var(--border); border-radius: 6px;
  background: var(--surface-2); cursor: zoom-in;
}
.cmp-thumb:hover { border-color: var(--accent); }

.img-view {
  position: fixed; inset: 0; z-index: 90;
  display: flex; align-items: center; justify-content: center;
  background: rgba(12, 15, 22, .88); padding: 24px; cursor: zoom-out;
}
.img-view img { max-width: 100%; max-height: 100%; border-radius: 8px; box-shadow: 0 14px 44px rgba(0, 0, 0, .5); }

/* ---------------- 选择器 ---------------- */

.picker {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-top: 10px;
  max-height: 165px;
  overflow-y: auto;
  background: var(--surface-2);
}
.picker .pick-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  padding: 4px 0;
  cursor: pointer;
}
.picker .pick-item:hover { color: var(--accent); }
.picker .pick-item .muted { color: var(--text-3); font-size: 12px; }
.picker-group { font-size: 12px; color: var(--text-3); margin: 8px 0 2px; font-weight: 500; }
.picker-block + .picker-block { margin-top: 8px; border-top: 1px dashed var(--border); padding-top: 4px; }

/* ---------------- 弹窗 / 提示 ---------------- */

.modal {
  position: fixed;
  inset: 0;
  background: rgba(16, 24, 40, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  padding: 20px;
}
.modal-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 20px;
  width: 100%;
  max-width: 340px;
  text-align: center;
}
/* ⚠️⚠️ 第 48 轮：`.modal-card-lg` / `.modal-card-xl` 的宽度**必须写成两个类**
   （`.modal-card.modal-card-xl`）。
   根因：上面第 705 / 708 行那两条变体规则跟紧邻上面的 `.modal-card` 特异性一模一样，
   全是 (0,1,0)，而它们写在本文件**更靠前**的位置 → `.modal-card { max-width: 340px }` 胜出
   → 所有 lg / xl 弹窗一直只有 340px 宽。导入弹窗底栏那一排按钮（重新读取 / 清空这个主体 /
   关闭 / 开始导入）加起来 324px，比卡片内宽 300px 还宽，又不换行、按钮还不许缩，
   于是蓝色的「开始导入」直接从卡片右边框伸出去 —— 2026-10-11 用户截图报的就是这个。
   写成两个类 = (0,2,0)，跟先后顺序无关，以后谁挪位置都不会再翻车。
   ⚠️ 手机上要回 100%：768px 那条媒体查询里的同款选择器在文件更后面，同特异性后者胜。 */
.modal-card.modal-card-lg { max-width: 520px; }
.modal-card.modal-card-xl { max-width: 680px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.qr-body { background: var(--surface-2); border-radius: var(--radius-sm); padding: 16px; }
.qr-body img { width: 200px; height: 200px; display: block; margin: 0 auto; }
.qr-url { font-size: 12px; color: var(--text-3); word-break: break-all; margin: 12px 0 0; }

.toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  background: #1f2937;
  color: #fff;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: 999px;
  z-index: 80;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  max-width: 80vw;
}
.toast.bad { background: var(--bad); }
.toast.ok { background: var(--ok); }

/* 预览模式提示条 */
.preview-banner {
  background: var(--warn-weak);
  border-bottom: 1px solid #f0dcb4;
  color: var(--warn);
  font-size: 12px;
  text-align: center;
  padding: 7px 16px;
  line-height: 1.5;
}

/* 顶部到期提示条 */
.banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 13px;
  color: var(--warn);
  background: var(--warn-weak);
  border-bottom: 1px solid #f0dcb4;
  line-height: 1.5;
}
.banner.banner-bad { color: var(--bad); background: var(--bad-weak); border-bottom-color: #f4c9c4; }
.banner .banner-act { margin-left: auto; }
.banner .btn { padding: 4px 10px; font-size: 12px; }

/* ---------------- 短网址 ---------------- */

.su-form { padding-bottom: 14px; border-bottom: 1px dashed var(--border); margin-bottom: 14px; }
/* 短网址那排控件（原先是写在标签上的内联样式，见 index.html 里的注释） */
.su-row { align-items: flex-end; gap: 10px; flex-wrap: wrap; }
/* 卡上「地址域名」那一行：下拉能缩，别把右边那句说明挤出去 */
.pg-domain { margin-top: 10px; }
.pg-domain select { flex: 0 1 auto; min-width: 0; max-width: 240px; }
/* 短链地址比一般单元格长：允许断行，别把表格撑出横向滚动条 */
.su-link { font-size: 13px; word-break: break-all; line-height: 1.45; }
.su-link a { color: var(--accent); text-decoration: none; }
.su-link a:hover { text-decoration: underline; }
#su-table .sub { margin-top: 4px; font-size: 12px; color: var(--text-3); }
#su-table .cell-note { max-width: 320px; word-break: break-all; line-height: 1.5; color: var(--text-2); }
/* 展开的「修改」行：底色压一下，一眼看出在改哪一条 */
.su-edit-row > td { background: var(--surface-2); }
@media (max-width: 640px) {
  .su-form .row-inline { flex-direction: column; align-items: stretch; }
  /* ⚠️ min-width 也得一起放开：下面那几个 label 上写了内联 `min-width:220px`，
     不 !important 抢回来，竖排后输入框只有 220px 宽、还贴在右边（第 44 轮踩过） */
  .su-form .row-inline .field { flex: 1 1 auto !important; min-width: 0 !important; width: 100%; }
  .su-form .row-inline .btn { width: 100%; }
}

/* ---------------- 抖音卡片 ---------------- */

.dy-form { padding-bottom: 16px; border-bottom: 1px dashed var(--border); }
.dy-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 720px) { .dy-grid { grid-template-columns: 1fr; } }

.dy-note {
  display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 10px 12px; margin-bottom: 16px;
  font-size: 12.5px; line-height: 1.7; color: var(--text-2);
}
.dy-note b { color: var(--text); flex: 0 0 auto; }
.dy-note span { flex: 1 1 300px; min-width: 0; }

/* 封面 / 二维码：左边一个方形预览框，右边按钮和说明 */
.dy-cover-row { display: flex; gap: 14px; align-items: flex-start; margin-top: 16px; flex-wrap: wrap; }
.dy-cover-box {
  flex: 0 0 104px; width: 104px; height: 104px; border-radius: var(--radius-sm);
  border: 1px dashed var(--border); background: var(--surface-2);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  cursor: pointer; position: relative;
}
.dy-cover-box:hover { border-color: var(--accent); }
.dy-cover-box img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dy-cover-box .dy-cover-ph {
  font-size: 12px; color: var(--text-3); text-align: center; line-height: 1.5; padding: 0 6px;
}
.dy-cover-side { flex: 1 1 260px; min-width: 0; }
.dy-cover-label { font-size: 12.5px; font-weight: 500; margin-bottom: 8px; }
.dy-cover-label .opt { color: var(--text-3); font-weight: 400; margin-left: 6px; }
.dy-lib-sel { max-width: 240px; min-width: 0; }

/* 跳转类型 / 企微类型：一排按钮，选中高亮 */
.dy-picks { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.dy-pick {
  font-family: inherit; font-size: 13px; padding: 7px 14px; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface); color: var(--text-2);
  border-radius: var(--radius-sm); transition: none;
}
.dy-pick:hover { border-color: var(--accent); color: var(--accent); }
.dy-pick.active {
  background: var(--accent-weak, var(--surface-2)); border-color: var(--accent);
  color: var(--accent); font-weight: 500;
}

#dy-table .dy-thumb { width: 44px; height: 44px; border-radius: 6px; object-fit: cover; display: block; border: 1px solid var(--border); }
#dy-table .dy-thumb-ph {
  width: 44px; height: 44px; border-radius: 6px; background: var(--surface-2);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  font-size: 11px; color: var(--text-3);
}
/* 文字卡的缩略图：白底两行字的迷你版，比一个「无」字有用 */
#dy-table .dy-thumb-tap {
  width: 44px; height: 44px; border-radius: 6px; background: #fff;
  border: 1px solid var(--border); overflow: hidden;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  padding: 3px; gap: 2px; text-align: center;
}
#dy-table .dy-thumb-tap span {
  font-size: 8px; line-height: 1.1; color: #333; word-break: break-all;
  max-height: 17px; overflow: hidden;
}
#dy-table .dy-thumb-tap b { font-size: 8px; line-height: 1.1; color: #1a73e8; font-weight: 400; word-break: break-all; max-height: 17px; overflow: hidden; }
#dy-table .dy-t { font-weight: 500; word-break: break-word; line-height: 1.45; }
#dy-table .dy-d { font-size: 12px; color: var(--text-3); margin-top: 3px; word-break: break-word; line-height: 1.5; }
#dy-table .dy-jump { font-size: 12.5px; color: var(--text-2); line-height: 1.5; word-break: break-word; max-width: 260px; }
#dy-table .dy-jump .sub { margin-top: 4px; font-size: 12px; color: var(--text-3); }
.dy-edit-row > td { background: var(--surface-2); }

/* 「蓝色文字链接」的实时预览：白底两行字，上面黑的、下面蓝的。
   版式跟服务端 dyTapPage 渲染出来的一致，让人填字时就看到手机上的样子。 */
.dy-tap-prev { margin-top: 14px; }
.dy-tap-prev-label { font-size: 12.5px; color: var(--text-3); margin-bottom: 8px; }
.dy-tap-prev-box {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 26px 18px; text-align: center; max-width: 320px;
}
.dy-tap-prev-box p { margin: 0 0 18px; font-size: 16px; line-height: 1.5; color: #222; word-break: break-word; }
.dy-tap-prev-box a { font-size: 17px; line-height: 1.5; color: #1a73e8; text-decoration: none; word-break: break-word; }

/* 生成卡片地址之后那块「怎么把它变成卡片」面板。
   只给一条链接是不够的 —— 链接发出去还是链接，必须拿苹果手机去抖音里转一次。
   所以这里摆一个可扫的码 + 四步说明，让人扫完就知道下一步干什么。 */
.dy-done {
  margin-top: 16px; padding: 16px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--bg-soft);
}
.dy-done-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.dy-done-head b { font-size: 14px; }
.dy-done-body { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.dy-done-qr { flex: 0 0 auto; text-align: center; }
.dy-done-qr img {
  width: 148px; height: 148px; border-radius: 8px;
  background: #fff; padding: 6px; border: 1px solid var(--border); display: block;
}
.dy-done-qr-tip { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.dy-done-steps { flex: 1 1 240px; margin: 0; padding-left: 20px; font-size: 13px; line-height: 1.85; color: var(--text-2); }
.dy-done-steps li { margin-bottom: 2px; }
.dy-done-url {
  flex: 1 1 240px; min-width: 0; font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 12.5px; padding: 7px 10px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg); color: var(--text-2);
}

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

@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; }
  .rule-grid { grid-template-columns: repeat(2, 1fr); }
  .sidebar { width: 64px; padding: 0; }
  .side-brand { padding: 0; justify-content: center; height: 60px; }
  .side-brand-text, .nav-label, .side-user-meta, .side-brand small { display: none; }
  .nav-item { justify-content: center; padding: 11px 0; }
  .side-foot { padding: 10px 8px; }
  .side-user { justify-content: center; margin-bottom: 8px; }
  .side-actions { flex-direction: column; gap: 6px; }
  .side-actions .btn { font-size: 11px; padding: 5px 2px; }
  .topbar { padding: 0 14px; gap: 12px; }
  .main { padding: 14px; }
  /* 窄屏（≤900px）实在并排放不下，就让按钮整排掉到第二行、靠右 —— 至少不是「压住上面那排」 */
  .toolbar { flex-wrap: wrap; }
  .toolbar-actions { margin-left: 0; width: 100%; justify-content: flex-end; }
}

/* ---------- 可信企业 / 投诉页：自己新建链接（2026-10-08 改版） ---------- */
.tp-card { margin-bottom: 12px; }
/* ⭐⭐ 第 58 轮 d（2026-10-12 用户原话：「投诉页和可信企业这个页给他合并成一排，然后前面链接的
   框框长度统一」）：整张卡就**一行**（.tp-url）—— 左边三样（类型 pill / 主体 / 状态）
   和链接四样（地址框 / 被打开 N 次 / 备注 / 按钮组）并排，跟短链表格的行一个思路：
   左边认出是谁 → 中间地址框**一般齐** → 右边一列操作。改之前是两行（标题行 + 链接排）。
   ⚠️⚠️ 地址框**定宽** `flex: 0 0 300px`（不 grow 也不 shrink）：58b/58c 用的是 flex-grow，
     结果「有备注的卡框窄、没备注的卡框宽、备注越长框越窄」—— 用户要的就是「长度统一」，
     跟表格列一样钉死，每条一般齐；URL 更长时输入框自己横向滚，选中 / 复制不受影响。
   ⚠️ 窄屏退场规则见下面 `@media (max-width: 1440px)`：主体 / 状态两个 chip 让位。 */
.tp-url { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.tp-url .gen-url { flex: 1 1 auto; min-width: 0; }
.tp-url .btn { flex: 0 0 auto; }
/* ⭐⭐ 58d2（2026-10-12 用户原话：「把前面黑字[页名]去掉」「投诉页和可信企业胶囊都改成统一的颜色」）：
   ① 原来这排最前面那条 `.tp-url .tp-title{max-width:88px;…}`（页名，超长截断）**整条删掉** ——
      页名不在这排上了，名字 + 主体全文挪进类型胶囊的 title 悬停提示（data-tp-name 给测试认卡）。
   ② 胶囊也不再有 pill-ok：可信企业原来是绿的、投诉页是灰的，现在两种卡同一种颜色（通用 .pill）。
   剩下的 chip 一律不许被挤扁（shrink 0），超长各自靠 max-width 截断 + title 看全文。 */
.tp-url .pill { flex: 0 0 auto; }
.tp-url .tp-subject {
  flex: 0 0 auto; min-width: 0; max-width: 88px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tp-url .tp-status { flex: 0 0 auto; white-space: nowrap; color: var(--text-3); font-size: 12px; }
.tp-url .tp-url-box { flex: 0 0 300px; }
/* ⭐⭐ 58d2（2026-10-12 用户原话：「备注和点击量这个重新布局调整下不要太靠左」）：
   「被打开 N 次 + 备注」原来**紧贴在地址框右边**（框只 300px，等于整排在左半截，右边一大片空）。
   给次数加 `margin-left: auto` —— 它和按钮组各自的 auto 把剩余空白**对半分**，这两样就被
   推到中间偏右、不再黏着地址框；整排内容一个没动，只是宽屏上空白重新分布。
   ⚠️ 不动 .tp-ops 的 auto：窄屏这一排折行时按钮组还得靠最右（58c 定下的排法）。
   ⚠️ 也别把次数挪到按钮组后面 —— 用户要的是「位置往右挪」，不是改变内容顺序。 */
.tp-url .tp-hit { flex: 0 0 auto; margin-left: auto; color: var(--text-3); font-size: 12px; white-space: nowrap; }
/* 备注在这一排里只给一角：超长截断 + 悬停 title 看全文（「仅自己可见」的提示也在 title 上）。
   ⚠️ 第 58 轮 c：240 → 200；第 58 轮 d：标题四样并进来先收到 160，再配合 1440 退场规则
     收到 136 —— 给 1600 视口「最挤场景」（名字/主体/备注全顶上限）留出余量。 */
.tp-url .tp-note {
  flex: 0 1 auto; min-width: 0; max-width: 136px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  padding: 2px 8px; border-radius: 6px;
  background: var(--warn-weak); border: 1px solid rgba(168, 106, 0, .22);
  color: var(--text-2); font-size: 12px;
}
/* 按钮组靠最右（跟短链列表的操作列一个位置）；装不下时整组折行 */
.tp-url .tp-ops { flex: 0 0 auto; margin-left: auto; }
/* ⭐⭐ 第 58 轮 d 窄屏退场（641–1440px，视口内宽 < ~1092）：主体、状态两个 chip display:none。
   它们不回答「这一行是谁、地址是什么、能点什么」，中宽桌面上先退场 —— 主体全文一直在
   类型胶囊的 title 提示里，状态在「修改」弹窗里也看得到，信息不丢。
   实测（最挤场景：名字/主体/备注全顶到上限）带上它们整排要 1130（可信）/ 1224（投诉）px，
   1440 视口内宽只有 1092；藏了之后 960 / 982 —— 1366（内宽 1018）装得下，
   1200（内宽 852）放得下没备注的卡（841）。≥1441 全显示：1600 内宽 1252 > 1224，最挤也是一行。
   ⚠️ 下限卡在 641px 是故意的：手机上这两个 chip 反而放得下（390px：88+54+144+gap < 340），
   状态那句话在手机上还显示，只有主体由下面的 ≤640 块负责藏。 */
@media (max-width: 1440px) and (min-width: 641px) {
  .tp-url .tp-subject { display: none; }
  .tp-url .tp-status { display: none; }
}
/* ⭐⭐ 第 58 轮 c + d 窄屏排法（≤640px）：
   c：这一排允许换行、按钮组单独成行不追右、只收横向尺寸（五颗按钮才不溢出）；
   d：整合成一排后，手机上的顺序 = 类型 pill + 状态一行 → 地址框独占一行 →
      「被打开 N 次 + 备注」一行 → 按钮组一行。主体 chip 在手机上藏起来
      （一行实在放不下，全文捎在类型胶囊的 title 上，信息不丢；状态还显示，390px 放得下）。 */
@media (max-width: 640px) {
  .tp-url { gap: 6px; }
  .tp-url .tp-url-box { flex-basis: 100%; }
  .tp-url .tp-note { max-width: 150px; }
  /* ⭐ 58d2：桌面上把「次数」推到右侧的 margin-left:auto 在手机上撤掉 ——
     手机这排本来就是「贴着卡片左边一行一行往下走」的排法（按钮组都不追右），
     再留个 auto 会把次数甩到右边、跟备注断开。 */
  .tp-url .tp-hit { margin-left: 0; }
  .tp-url .tp-ops { margin-left: 0; flex: 0 1 auto; flex-wrap: wrap; row-gap: 6px; }
  /* ⚠️ 投诉页一组五颗按钮（修改/举報/投訴/删除/复制）在 390px 上按默认尺寸会溢出换行，
     卡片就多一行 —— 这里只收**横向** padding / 间距 / 字号（高度不动，仍够手指点），
     把五颗压回一行。 specificity (0,3,0) 稳压全局 `.btn-sm`（768px 媒体查询里那条）。 */
  .tp-url .tp-ops { gap: 4px; }
  .tp-url .tp-ops .btn { padding: 4px 8px; font-size: 12px; min-height: 30px; }
  .tp-url .tp-subject { display: none; }
}
/* ⭐⭐ 第 49 轮 b（2026-10-11 用户要求）：那句绿色「已开启防盗模式」从地址下面
   挪进**地址框里面**、紧贴复制按钮那头。input 里塞不了元素（它自己不能有子元素），
   所以套一层 relative 的小盒子、把绿字 absolute 叠到输入框右侧。
   ⚠️ 必须给 input 留 padding-right（绿字 7 个字 12px ≈ 88px + 留白 = 92px）—
      否则地址尾部被绿字压在下面，地址比框长时尤其明显。
   ⚠️ pointer-events: none —— 绿字盖在输入框上，不设的话它自己会吃掉点击，
      用户点它那一片就选不中 / 复制不了地址。 */
.tp-url-box { position: relative; display: flex; flex: 1 1 auto; min-width: 0; }
.tp-url-box .gen-url { padding-right: 92px; }
.tp-url-box .tp-guard {
  position: absolute; right: 9px; top: 50%; transform: translateY(-50%);
  pointer-events: none; white-space: nowrap;
}
@media (max-width: 640px) {
  /* 手机上框窄，绿字缩一档，给地址多让出几个字符的位置 */
  .tp-url-box .gen-url { padding-right: 86px; }
  .tp-url-box .tp-guard { font-size: 11px; right: 7px; }
}
/* ⭐ 第 48 轮 c + 第 49 轮 b：可信企业 / 投诉页卡片上那句绿色的「已开启防盗模式」（用户要求）。
   ⚠️ 位置改过两次：48c 加在**地址下面那一行**；49b 用户要求挪进**地址框里面**、
   紧贴复制按钮那头（叠加方式见上面 .tp-url-box 那段注释）。
   绿字用 --ok，跟「已开通」那些标记一个色。 */
.tp-guard { color: var(--ok); font-size: 12px; font-weight: 600; }
/* ⭐⭐ 第 58 轮：`.tp-meta`（主体 + 被打开次数那一行）和备注的旧「整行淡黄块」样式都取消了 ——
   主体挪进标题行（.tp-subject）、被打开次数和备注并进链接那一排（见上面 .tp-url 那组样式）。
   备注的淡黄底保留成小 chip（.tp-url .tp-note），「淡黄 = 内部备注」的认知不断。 */
/* ⭐⭐ 58d2：`.tp-card .tp-title { cursor: pointer }` + hover 变蓝那两条跟着页名一起删了 ——
   页名不在这排上了，可点进编辑的入口只剩右边那颗「修改」按钮（带 data-tp-edit）。
   留着这两条就是死样式（DOM 里再没有 .tp-title）。 */
.pg-paste { margin: 4px 0 12px; border: 1px dashed var(--border); border-radius: 8px; padding: 0 12px; }
.pg-paste > summary { cursor: pointer; font-size: 13px; color: var(--text-2); user-select: none; list-style: none; padding: 9px 0; }
.pg-paste > summary::-webkit-details-marker { display: none; }
.pg-paste > summary::before { content: '▸ '; color: var(--text-3); }
.pg-paste[open] > summary::before { content: '▾ '; }
.pg-paste > summary:hover { color: var(--accent); }
.pg-paste textarea { width: 100%; box-sizing: border-box; font-family: inherit; font-size: 13px; line-height: 1.6; margin-bottom: 2px; }
.pg-paste .row-inline { margin-bottom: 12px; }
/* ⚠️ `.pg-check` 原来给「用自己的域名发这条链接」那个勾选框用 —— 整块已删
   （2026-10-09 第三十四轮），HTML 里再没有这个 class 了，样式一并删掉。 */
#pg-ent-grid { margin-top: 4px; }

/* ---------------- 功能中心（第 39 轮）----------------
   超管之外的所有账号在「功能中心」里看四个收费功能：一功能一张卡，
   卡上只有一颗「购买 / 续费」（点开弹窗兑卡密）。不显示价格，也没有「立即使用」。 */
.feat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}
.feat-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.feat-head { display: flex; align-items: center; gap: 10px; }
.feat-head .stat-ico { width: 38px; height: 38px; border-radius: 10px; font-size: 15px; }
.feat-name { flex: 1; min-width: 0; font-size: 15px; }
.feat-desc { flex: 1; margin: 0; font-size: 12.5px; line-height: 1.6; color: var(--text-2); }
.feat-meta { font-size: 12.5px; color: var(--text-2); }
.feat-meta b { color: var(--text); font-weight: 600; }
.feat-foot { display: flex; padding-top: 10px; border-top: 1px solid var(--border); }
.feat-foot .btn { flex: 1; }
/* 免费那两项的说明：占满一整行，不跟卡片挤在同一格 */
.feat-free { grid-column: 1 / -1; margin: 0; font-size: 12.5px; color: var(--text-2); }

/* ================= 告警通知（2026-10-10 第 43 轮） =================
   侧栏「抖音卡片」下面、「小圆码生成」上面那个板块。
   三块：渠道列表 / 事件开关 / 发送记录。
   ⚠️ 追加在文件末尾 —— 这个文件历史上被一个孤立的大括号废掉过后面几百条规则，
      放末尾至少不会影响别人；改完记得跑一次括号平衡检查。
      ⚠️⚠️ 注释里**别写大括号**：wlf-zipcheck 那条「括号平衡」只剥单行注释，
         多行注释里写一个右大括号就会被数进去，断言当场红。 */

.al-block {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.al-block:first-of-type { margin-top: 0; padding-top: 0; border-top: 0; }
/* ⭐ 64b：独页块 —— 传奇BOSS 独立板块里 preview-head 后面紧跟这一个块，
   整页就它一个不用分隔线（首个子元素不是它，first-of-type 够不着，单独给个类） */
.al-block-solo { margin-top: 0; padding-top: 0; border-top: 0; }
.al-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.al-block-head strong { font-size: 14px; }
.al-block-head .opt { font-weight: 400; }

/* ⭐ 64a→64b：传奇BOSS 独立板块（侧栏「预警通知」下面）—— 一行一个 BOSS
   （名字 / 间隔 / 剩余 / 上次 / 两颗按钮）。64a 时它是预警通知页的 ④ 块，64b 搬成独立板块，
   样式原样复用（类名没改，前端逻辑也没必要大动）。 */
.al-boss-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  margin-bottom: 8px;
}
.al-boss-row.due { border-color: var(--bad); background: var(--bad-weak); }
.al-boss-row input { width: 150px; }
.al-boss-row .al-boss-name { font-weight: 600; }
.al-boss-gap { display: flex; align-items: center; gap: 6px; }
/* ⭐ 64f：间隔改成「X 小时 X 分钟」两个框（一个 3 位数 / 一个 2 位数） */
.al-boss-gap input { width: 56px; }
.al-boss-gap i { font-style: normal; font-size: 12px; color: var(--text-2); white-space: nowrap; }
.al-boss-next { font-size: 13px; font-variant-numeric: tabular-nums; min-width: 170px; }
.al-boss-row.due .al-boss-next { color: var(--bad); font-weight: 700; }
.al-boss-last { font-size: 12px; color: var(--text-3); white-space: nowrap; }
/* ⭐ 64e（2026-10-15 用户要求）：「已击杀 / 删除」推到每行最右 ——
   给「已击杀」一个 margin-left:auto 吃掉左边剩余空间，两颗按钮一起贴到行尾（换行后同样靠右） */
.al-boss-row [data-al-boss-kill] { margin-left: auto; }

/* ⭐ 64d→64f：「提前 X 分钟提醒」输入（默认 1 分钟）。
   ⚠️ .al-boss-lead input 要压过上面 .al-boss-row input 的 width:150px —— 放它后面即可（同优先级后者胜） */
.al-boss-lead {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-2);
  white-space: nowrap;
}
.al-boss-lead input { width: 56px; }

/* ⭐ 64h→64k（2026-10-15 用户要求）：BOSS 按固定周期刷 —— 行里「下次刷新」是手填的
   「还有 X 小时 X 分钟」两格（相对时长，不是钟点/日期），长相/手感都跟「一刷」那个一样
   （同样的浅色数字框；系统日期控件和月/日都不要，
   ⚠️ 别给它加任何「深色配色」相关样式 —— 用户截图里那个黑框就是上一版这么害的）。
   ⚠️ 同样要压过 .al-boss-row input 的 width:150px（放它后面）。 */
.al-boss-at { display: flex; align-items: center; gap: 6px; }
.al-boss-at i { font-style: normal; font-size: 12px; color: var(--text-2); white-space: nowrap; }
.al-boss-at input { width: 56px; }

/* ⭐ 64c：常用BOSS 快捷添加弹窗里的名字按钮（点一下直接加进列表） */
.ab-group { margin-bottom: 14px; }
.ab-group:last-child { margin-bottom: 0; }
.ab-group-title { font-size: 12px; color: var(--text-3); margin-bottom: 8px; }
.ab-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ab-chip {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px;
  line-height: 1;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}
.ab-chip:hover { border-color: var(--accent); color: var(--accent); }
.ab-chip.done { opacity: .45; cursor: default; background: var(--surface-2); color: var(--text-3); }
.ab-chip.done:hover { border-color: var(--border); color: var(--text-3); }
/* ⭐ 64l（2026-10-15 用户要求「新增删除xx的选项」）：已加入的 chip 右边那颗「×」——
   点它 = 从 BOSS 列表删掉这条（主列表同步刷新、即时保存）。
   chip 主体依然点不动，只有 × 是活的、悬停泛红。 */
.ab-chip .ab-chip-x { margin-left: 6px; font-weight: 700; color: var(--text-3); }
.ab-chip .ab-chip-x:hover { color: #e03131; }

/* ⭐ 事件开关一排两个（用户 2026-10-10 要求）。
   用 grid 而不是 flex：flex 每个格子宽度会被内容撑得不一样，两列对不齐。 */
#al-rules {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
/* 事件是奇数个时，最后一个独占整行 —— 不然右下角空一块，看着像没画完。
   ⭐ 写成 :last-child:nth-child(odd) 而不是写死第 5 个：事件数量会变
   （2026-10-10 把「页面访问激增」拆成可信页 / 投诉页两个，5 个变 6 个），
   写死下标的话每次加减事件都得跟着改这里。 */
#al-rules .al-ev:last-child:nth-child(odd) { grid-column: 1 / -1; }
/* 窄屏（笔记本半屏 / 手机）两列太挤，直接竖过来 */
@media (max-width: 900px) {
  #al-rules { grid-template-columns: 1fr; }
  #al-rules .al-ev:last-child:nth-child(odd) { grid-column: auto; }
}

/* 一个事件一格：开关 + 说明 +（激增/日报才有的）参数 */
.al-ev {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  /* ⚠️ 网格里靠 gap 撑间距，**不能留 margin-bottom**（会跟 gap 叠一起，行距忽大忽小） */
  margin: 0;
}
.al-ev-desc {
  margin: 2px 0 0 24px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text-2);
}
.al-extra { margin: 8px 0 0 24px; flex-wrap: wrap; }
.al-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  cursor: pointer;
  user-select: none;
}
.al-check input { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }

.al-inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.al-lab { font-size: 12.5px; color: var(--text-2); }
.al-sel, .al-num {
  height: 32px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
}
/* ⚠️⚠️ 宽度必须写成 `.al-inline .al-*`，不能只写 `.al-sel`：
   文件上面有一条 `input[type="text"], input[type="number"], …, select, textarea { width: 100% }`
   —— 它的特异性是 (0,1,1)，比 `.al-num`(0,1,0) 高，单靠类名压不住。
   压不住的后果是「在 [10 分钟] 内被访问超过 [50] 次」整行竖着堆下来（一个框占一行），
   而且不带 .al-inline 的那两处（免打扰 / 冷却）也会散开。 */
.al-inline .al-sel, .al-inline .al-num { width: auto; flex: 0 0 auto; }
.al-inline .al-num { width: 84px; }
/* 事件卡现在只有半屏宽（一排两个），参数那行要挤一点：
   缩间距 + 缩左边距，让「在 [10 分钟] 内超过 [50] 次就推一次」在一行里放得下 */
.al-ev .al-extra { margin-left: 0; gap: 6px; }

/* 免打扰 / 重复抑制 两块小设置 */
.al-sub {
  margin-top: 14px;
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
}
.al-sub-title { font-size: 13.5px; margin-bottom: 8px; }
.al-sub-title .opt { display: block; margin-top: 2px; font-size: 12px; font-weight: 400; }
.al-sub-title .opt b { color: var(--text); }

/* ⚠️⚠️ 渠道弹窗的宽度必须写 `#al-modal .modal-card` 这种「id + 类」的形式。
   原因：文件上面 `.modal-card-xl { max-width: 680px }`（第 708 行）写在
   `.modal-card { max-width: 340px; text-align: center }`（第 1201 行）**前面**，
   两边特异性都是 (0,1,0) → 后面的胜出 → 光靠 .modal-card-xl 这个类**根本撑不开**，
   而且文字还是居中的（标签会飘到框上面去）。
   前面那个「新建链接」弹窗也是这个毛病，只是它内容简单看不出来。 */
#al-modal .modal-card { max-width: 620px; text-align: left; }

/* 弹窗里渠道配置那几栏：两列排开，窄屏自动竖过来 */
.al-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 640px) { .al-grid { grid-template-columns: 1fr; } }
#al-fields textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  resize: vertical;
}

/* 表格里：配置那一列用等宽字体，长串地址不会飘 */
.al-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  color: var(--text-2);
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.al-ops { white-space: nowrap; }
.al-ops .btn + .btn { margin-left: 4px; }
/* 发送失败时把原因跟在「失败」那颗 pill 后面 */
.al-err { display: block; margin-top: 4px; font-size: 12px; color: var(--bad); }

/* ================================================================== *
 * ⭐⭐ 手机 / 窄屏适配（2026-10-10）
 *
 * 后台原来只在几处零散写过 640px 的断点，整体是给电脑用的：
 * 232px 固定侧栏 + 内容区，手机上侧栏吃掉一半屏，表格挤成一团。
 * 这一整段统一处理 ≤768px（手机竖屏 / 平板窄屏），目标是**能看能点**，不是做成 App。
 *
 * 三条原则：
 *   ① 侧栏改成顶部一条**可以左右滑**的页签（不然 10 个板块要滚半天）
 *   ② 表格保持横向滚动（.table-wrap 本来就有 overflow-x:auto），别硬塞
 *   ③ 按钮、输入框往大了调 —— 手指点得准（按钮 ≥38px，输入字号 16px）
 *      ⚠️ 输入字号必须 ≥16px：iOS Safari 一见到更小的输入框就自动放大整个页面
 *
 * ⚠️⚠️ 动手前先看这条（第 44 轮踩过）：
 *   上面 1377 行还有一条 `@media (max-width: 900px)`，它把侧栏收成 64px 图标条。
 *   手机（390px）**两条同时命中**，谁在后谁赢 —— 所以它藏掉的东西
 *   （`.nav-label`、`.side-brand-text`、`.side-user-meta`）必须在这段里**显式抢回来**，
 *   否则两边各藏一半：它藏文字、这段藏图标 → 页签变成一个空壳，什么都看不见。
 * ================================================================== */

@media (max-width: 768px) {
  /* ① 整体：侧栏到顶上，内容区跟着往下排 */
  .app { flex-direction: column; height: auto; min-height: 100vh; overflow: visible; }
  .sidebar {
    width: auto;
    flex-shrink: initial;
    border-right: none;
    border-bottom: none;
    /* 整块不吸顶 —— 只让页签那一条吸住（不然品牌行 + 账号行白占 200px 屏） */
    position: static;
  }
  /* 品牌行：⭐ 名字要抢回来（900px 那条把它藏了），小字副标题可以不要 */
  .side-brand { height: 46px; padding: 0 14px; justify-content: flex-start; gap: 8px; }
  .side-brand .logo { width: 28px; height: 28px; border-radius: 8px; font-size: 13px; }
  .side-brand-text { display: block; }
  .side-brand-text strong { font-size: 13.5px; }
  .side-brand-text small { display: none; }

  /* 页签横排、可左右滑、滚动时吸在顶上 */
  .side-nav {
    flex-direction: row;
    align-items: center;
    padding: 8px 10px;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    position: sticky;
    top: 0;
    z-index: 40;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 6px 12px -10px rgba(0, 0, 0, 0.5);
  }
  .side-nav::-webkit-scrollbar { display: none; }
  /* ⭐ 页签：只留文字（图标在 390px 宽下白占 30px 一个），标签必须显式显回来 */
  .nav-item { width: auto; flex: 0 0 auto; padding: 8px 12px; white-space: nowrap; font-size: 13px; gap: 0; }
  .nav-label { display: inline; }
  .nav-ico { display: none; }
  .nav-item.active { box-shadow: inset 0 -3px 0 var(--accent); }
  /* 企业微信这组：展开后子项也横着排，别掉一列下来 */
  .nav-group { flex-direction: row; flex: 0 0 auto; gap: 6px; }
  .nav-group.expanded .nav-sub { flex-direction: row; gap: 6px; }
  .nav-sub .nav-item { padding-left: 12px; font-size: 13px; }
  .nav-caret { display: none; }

  /* 账号行：压成一条（原来竖着排要 137px） */
  .side-foot {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-top: none;
  }
  .side-user { margin-bottom: 0; gap: 8px; min-width: 0; }
  .side-avatar { width: 26px; height: 26px; font-size: 12px; }
  .side-user-meta { display: flex; flex-direction: row; align-items: center; gap: 6px; }
  .side-user-email { font-size: 12.5px; max-width: 30vw; }
  .side-user-role { display: none; }
  .side-actions { flex-direction: row; gap: 6px; margin-left: auto; }
  .side-actions .btn { flex: 0 0 auto; min-height: 32px; padding: 6px 10px; font-size: 12px; }

  /* ② 内容区 */
  .topbar { height: 48px; padding: 0 12px; }
  .main { padding: 12px 12px 40px; overflow: visible; }
  /* ⚠️ 工具条：窄屏一律换行 + 左对齐。
     原来 .toolbar-actions 靠 `margin-left:auto` 顶右边、还不换行（flex:none），
     四个按钮一排塞不下就**从左边溢出去**（左溢不进 scrollWidth，横向溢出检查抓不到）。 */
  .toolbar { flex-wrap: wrap; row-gap: 8px; }
  .toolbar .seg { width: 100%; overflow: visible; }
  .toolbar-actions { width: 100%; margin-left: 0; justify-content: flex-start; flex-wrap: wrap; }
  .card { padding: 14px 12px; border-radius: 12px; }
  .card + .card { margin-top: 12px; }
  .preview-head { flex-wrap: wrap; gap: 8px; }
  .preview-head h2 { font-size: 16px; }
  .row-inline { flex-wrap: wrap; gap: 8px; }
  .pg-acts { flex-wrap: wrap; gap: 8px; }

  /* 表格：字号收小，padding 收窄；横向滚动交给 .table-wrap */
  .table { font-size: 12.5px; }
  .table th, .table td { padding: 8px 10px; }
  .table td, .table th { white-space: nowrap; }
  .table-wrap { border-radius: 10px; }

  /* ③ 手指友好 */
  .btn { min-height: 38px; padding: 9px 14px; }
  .btn-sm { min-height: 34px; padding: 7px 12px; font-size: 13px; }
  input[type="text"], input[type="password"], input[type="number"], input[type="email"], select, textarea {
    font-size: 16px;   /* ⚠️ 别改小：iOS 会自动放大页面 */
    min-height: 40px;
  }
  .field.compact { min-width: 100%; }

  /* 首页六格：手机上排两列（原来是 auto-fit 190px，375 宽只塞得下一列） */
  .dash-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .dash-hero { padding: 16px 14px; }
  .dash-title { font-size: 17px; }
  .dash-meta { gap: 12px; }

  /* 弹窗改成底部抽屉：手机上从下往上升起比居中好点 */
  .modal { align-items: flex-end; padding: 0; }
  .modal-card,
  .modal-card-lg,
  .modal-card-xl,
  /* ⚠️ 第 48 轮补的两个复合选择器：上面第 1205 行那两条「.modal-card.modal-card-lg / -xl」
     也是 (0,2,0)，跟这里同特异性 —— 靠**顺序**（这条在文件更后面）压回 100%。
     只写单个类的话 (0,1,0) 会被它压掉，手机上弹窗就顶出屏幕了。 */
  .modal-card.modal-card-lg,
  .modal-card.modal-card-xl {
    max-width: 100%;
    max-height: 88vh;
    overflow-y: auto;
    border-radius: 16px 16px 0 0;
    padding: 16px 14px 20px;
  }
  .modal-card-xl { display: flex; flex-direction: column; }

  /* 提示条别被手机底部的小黑条挡住 */
  .toast { bottom: 20px; max-width: 90vw; }

  /* 告警板块：事件开关手机上还是一列好读（900px 那条已经处理，这里再兜一次） */
  #al-rules { grid-template-columns: 1fr; }
  #al-rules .al-ev:last-child:nth-child(odd) { grid-column: auto; }
  .al-inline { flex-wrap: wrap; }
}

/* ⭐⭐ 2026-10-11 第 46 轮：短网址页里的「我的域名」区块（绑自己的域名发短链）。
   故意不用 .card —— 它跟上面的主卡片贴在一起会两层边框打架、阴影也叠起来。
   做成主卡片内部一个浅色小区块。两个区块共用一套样式，超管那块加 r-super 控制显隐。 */
.md-box {
  margin: 14px 0 0;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.md-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.md-head strong { font-size: 14px; }
/* 按钮推到右边；手机上 .md-head 会换行，这时 margin-left:auto 也不会把人挤扁 */
.md-head .row-inline { margin-left: auto; }
/* 小区块里的表给回白底，不然跟浅色背景糊在一起看不清行 */
.md-box .table { background: var(--surface); }
/* ---------- 「添加域名」弹窗（第 47 轮照同行样式重做） ---------- */
/* ⚠️ 写 ID 选择器不是图省事：`.modal-card` 的 max-width 是 (0,1,0)，
   跟任何单个类同特异性 —— 写在它前面就白写（这坑在 #al-modal 上踩过）。 */
#md-modal .modal-card { max-width: 460px; }

.md-field { margin-bottom: 16px; }
.md-field:last-of-type { margin-bottom: 4px; }
.md-label { display: block; font-size: 13px; color: var(--text); margin-bottom: 6px; }
.md-tip { margin: 0 0 8px; font-size: 12px; color: var(--text-3); line-height: 1.7; }
.md-tip b { color: var(--warn); font-weight: 600; }
.md-tip-2 { margin: 6px 0 0; font-size: 12px; color: var(--warn); }

/* 备案接入平台：三个并排按钮，选中的蓝底白字 */
.md-plat { display: flex; gap: 8px; flex-wrap: wrap; }
.md-plat-btn {
  padding: 7px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  cursor: pointer;
}
.md-plat-btn:hover { border-color: var(--accent); color: var(--accent); }
.md-plat-btn.on { background: var(--accent); border-color: var(--accent); color: #fff; }

/* 「解析到 / 备案查询」那一格：浅灰底 + 域名商记录表样式 */
.md-resolve {
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.md-rec-title { font-size: 12px; color: var(--text-3); margin-bottom: 8px; }
.md-rec-tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.md-rec-tbl td { padding: 7px 10px; border: 1px solid var(--border); vertical-align: middle; }
.md-rec-tbl tr:first-child td { border-top: 1px solid var(--border); }
.md-rec-k { flex: 0 0 auto; width: 72px; color: var(--text-3); background: var(--surface); white-space: nowrap; }
.md-rec-v { color: var(--text); word-break: break-all; }
.md-rec-typ { font-weight: 600; color: var(--accent); letter-spacing: .5px; }
.md-rec-val { display: flex; align-items: center; gap: 8px; }
.md-rec-val code { flex: 1 1 auto; font-size: 13px; word-break: break-all; }
.md-resolve-row { display: flex; align-items: center; gap: 6px; font-size: 13px; min-height: 26px; margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--border); }
.md-resolve-k { flex: 0 0 auto; color: var(--text-3); }
.md-resolve code { color: var(--text); font-size: 13px; word-break: break-all; }
.md-resolve a { color: var(--accent); font-size: 12px; word-break: break-all; }
.md-copy {
  flex: 0 0 auto;
  margin-left: auto;
  padding: 3px 10px;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 12px;
  cursor: pointer;
}
.md-copy:hover { border-color: var(--accent); color: var(--accent); }

/* 域名下面那行小字里：超管写的拒绝理由要看得见（红），但不能整个行都红 */
.md-note { color: var(--bad); }
/* 检测没通过时，区块下方那条提示 */
.md-say-bad { color: var(--bad); }

/* ⭐ 第 51 轮「一键配置」的进度 / 结果。
   点一下要等半分钟到一分钟（Let's Encrypt 要验证 + 签发），
   所以这块要让人一眼看出「到哪一步了、哪一步炸的」——
   步骤结果原样来自服务端的 steps[]，前端只负责上色。 */
.md-auto {
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.md-auto-steps {
  margin: 8px 0 0;
  padding: 0 0 0 4px;
  list-style: none;
  font-size: 13px;
  line-height: 1.9;
  color: var(--text-2);
}
/* 每条前面一颗小圆点：绿=成了、红=炸了、灰=进行中 */
.md-auto-steps li { position: relative; padding-left: 16px; }
.md-auto-steps li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-3);
}
.md-auto-steps li.md-step-ok::before { background: var(--ok, #0f8a5f); }
.md-auto-steps li.md-step-bad::before { background: var(--bad); }
.md-auto-steps li.md-step-bad { color: var(--bad); }
/* 每条后面的说明文字（路径、报错原文）用弱色，别跟步骤名抢 */
.md-auto-steps li .opt { margin-left: 6px; word-break: break-all; }
.md-auto-steps li b { font-weight: 600; color: var(--text); }

/* ⭐ 62l：自动配置的「详细过程」折叠区 —— 默认收起（里面有 nginx 目录 / 面板地址 / 站点根目录
   这些服务器路径，用户会截图外发）。默认视图只报「成功 / 失败 + 原因」，这层要点开才见。 */
.md-detail { margin-top: 6px; }
.md-detail > summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--text-3);
  user-select: none;
  list-style-position: inside;
}
.md-detail > summary:hover { color: var(--text-2); }
.md-detail[open] > summary { margin-bottom: 2px; }

/* ---------- 宝塔面板 API 配置卡（2026-10-13 第 62h 轮） ----------
   三个输入框按宽度自动换行排（窄屏一格、宽屏三格），两个勾选项占满整行。
   ⚠️ .field 自带 margin-bottom，这里收窄一点，别把卡撑太高。 */
.bt-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 0 14px; margin-top: 10px; }
.bt-form .field { margin-bottom: 8px; }
/* 两个勾选项整行放，跟上面的输入框分开 */
.bt-form .bt-checks { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 2px; }
.bt-form .al-check { margin: 0; }

/* ⭐ 超管的「在宝塔里要做的三步」折叠块：默认收起，不占地方。
   ⚠️ 第 51 轮起它只是**备用**路径 —— 正常走上面那个「一键配置」。 */
.md-howto { margin-top: 10px; }
.md-howto > summary { cursor: pointer; font-size: 13px; color: var(--accent); }
.md-howto > ol { margin: 8px 0 0 18px; padding: 0; font-size: 13px; color: var(--text-2); line-height: 1.8; }
.md-howto code {
  padding: 1px 5px;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--surface);
  font-size: 12px;
}

/* ⭐ 淘客站管理（仅超管，2026-10-12 第 61 轮）：左边改、右边实时预览 */
/* （62f 给的 margin-top 已合并到全局 .card > .preview-head { margin-bottom:16px }） */
.tk-manage { display: grid; grid-template-columns: minmax(0, 1fr) 440px; gap: 18px; align-items: start }
.tk-left { min-width: 0 }
.tk-right { min-width: 0; position: sticky; top: 12px }
.tk-block { border-top: 1px solid var(--border); margin-top: 18px; padding-top: 14px }
.tk-block-first { border-top: none; margin-top: 0; padding-top: 0 }
.tk-block.off { display: none }   /* 页签没选中的页面块：留在 DOM 里、不显示（保存时照样提交） */
.tk-switch { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 0 0 14px }
/* ⭐ 61d：块标题加一条竖条，左栏三块（站点设置 / 访问方式 / 页面内容）一眼分层 */
.tk-block-title {
  font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 10px;
  display: flex; align-items: center; gap: 8px;
  border-left: 3px solid var(--accent); padding-left: 8px; line-height: 1.3;
}
.tk-block-title .opt { font-weight: 400 }
/* ⭐ 62a：块标题右边的小按钮组（改名 / ✕ 删板块）——自定义板块才能删 */
.tk-block-title .tk-title-btns { margin-left: auto; display: flex; align-items: center; gap: 6px; flex-wrap: wrap }
.tk-tbtn {
  cursor: pointer; font-family: inherit; font-size: 12px; line-height: 1;
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--text-2);
}
.tk-tbtn:hover { border-color: var(--accent); color: var(--accent) }
.tk-tbtn-del:hover { border-color: var(--bad); color: var(--bad) }
/* （.tk-prev「新窗口打开 ↗」第 61f 轮按用户要求删了：右边就是实时预览，不用再开新窗口） */
/* （.tk-grid3 那套三列栅格第 61e 轮不用了：站点设置拆成了「顶部」和「底部」两块） */
/* ⭐ 第 61c 轮：左栏全做成「胶囊 + 点修改弹窗」（原来是每条链接两个输入框横排，太乱）。
    胶囊 = 一行：左边标签（或按钮文字）+ 中间现值 + 右边「修改」（+ 删除）。 */
.tk-links-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin: 16px 0 6px; font-size: 12px; color: var(--text-3) }
.tk-field-rows { display: flex; flex-direction: column; gap: 6px }
.tk-chips { display: flex; flex-direction: column; gap: 8px }
/* 一行胶囊：文字类的（标题 / 副标题 / 提示语）*/
.tk-chip-row {
  display: flex; align-items: center; gap: 8px; padding: 6px 8px 6px 12px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--surface-2);
}
.tk-chip-k { flex: 0 0 auto; min-width: 46px; font-size: 12px; color: var(--text-3) }
.tk-chip-v {
  flex: 1 1 auto; min-width: 0; font-size: 13px; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tk-chip-v.tk-empty { color: var(--text-3) }
/* 一条链接的胶囊：名字 + 跳到哪（灰字）+ 修改 / 删 */
.tk-chip {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 7px 9px 7px 14px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface);
}
.tk-chip:hover { border-color: var(--border-strong) }
.tk-chip-name {
  flex: 0 1 auto; max-width: 45%; min-width: 0; font-size: 13px; font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tk-chip-url {
  flex: 1 1 150px; min-width: 0; font-size: 12px; color: var(--text-3);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* 胶囊上那两颗按钮（没挂 .btn，样式自己给全） */
.tk-chip-edit, .tk-chip-del {
  flex: 0 0 auto; cursor: pointer; font-size: 12px; line-height: 1;
  padding: 5px 10px; border-radius: 999px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--text-2); font-family: inherit;
}
.tk-chip-edit:hover { border-color: var(--accent); color: var(--accent) }
.tk-chip-del { padding: 5px 9px; color: var(--text-3) }
.tk-chip-del:hover { border-color: var(--bad); color: var(--bad) }
/* 上移 / 下移：比「修改 / 删」更淡一点，别抢主按钮的视觉 */
.tk-chip-mv {
  flex: 0 0 auto; cursor: pointer; font-size: 12px; line-height: 1; font-family: inherit;
  padding: 5px 7px; border-radius: 999px; border: 1px solid var(--border);
  background: transparent; color: var(--text-2);
}
.tk-chip-mv:hover:not(:disabled) { border-color: var(--accent); color: var(--accent) }
.tk-chip-mv:disabled { opacity: 0.35; cursor: not-allowed }
.tk-chip-add {
  margin-top: 2px; width: 100%; cursor: pointer; font-family: inherit;
  padding: 8px 12px; font-size: 12px; color: var(--text-3);
  border: 1px dashed var(--border-strong); border-radius: 12px; background: transparent;
}
.tk-chip-add:hover { border-color: var(--accent); color: var(--accent) }
/* ⭐ 62c：备案号那颗胶囊的「修改」弹窗里还有「自动获取」和工信部链接（#tk-site-modal-icp 那行），
   .tk-icp-q 留着给弹窗里那条链接用；原来左栏两列输入框那套（.tk-icp-row / .tk-grid2）连规则一起删了。 */
.tk-icp-q { display: inline-block; font-size: 12px; color: var(--accent); text-decoration: none }
.tk-icp-q:hover { text-decoration: underline }
/* ⭐ 61e：左栏照右边预览的顺序排 —— 顶部 = Logo + 大标题，底部 = 页脚联系 / 备案号两颗胶囊
   ⭐ 62f：用户要求「合并成一排」—— logo + 站名 + 上传/恢复按钮 变成**同一行**（原来分三行：
   logo/站名一行、输入框一行、按钮一行）。窄屏放不下时整块自动换行，不会挤坏。 */
.tk-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap }
/* 站名那一栏改成「标签 + 输入框」同一行（原来标签在输入框上面，多占一行） */
.tk-name-field { display: flex; align-items: center; gap: 8px; margin: 0; flex: 1 1 300px; min-width: 170px }
.tk-name-field > span { display: inline-flex; align-items: baseline; margin: 0; font-size: 12px; color: var(--text-2); font-weight: 500 }
/* 覆盖全局 input[type="text"]{width:100%}（在 flex 里会把站名输入框挤爆） */
.tk-name-field > input { flex: 1 1 auto; min-width: 0; width: auto }
.tk-field-after { margin-top: 12px }
/* ⭐ 61f：② 页面内容是个「套着页面块」的大块 —— 里面的页面块不要再来一条上边框 */
.tk-block-pages > #tk-pages > .tk-block,
.tk-block-pages > .tk-block-note {
  border-top: 1px dashed var(--border); margin-top: 14px; padding-top: 12px;
}
.tk-logo-thumb {
  flex: 0 0 auto; width: 46px; height: 46px; border-radius: 10px; display: block;
  border: 1px solid var(--border); background: var(--surface-2); object-fit: contain;
}
.tk-logo-pick { display: flex; align-items: center; gap: 6px; flex-wrap: wrap }
/* ⭐ 62e（本轮）：「生成短链」挪进「官方随机域名」卡片里、跟说明文字平级（左文字 / 右按钮）；
   三张卡等高（grid stretch + .tk-mode 撑开，让没有按钮的另外两张也和第一张一样高）。 */
.tk-mode-b .tk-mode-btn { margin: 0; white-space: nowrap }
/* ⭐ 访问方式：三张卡片式单选（第 61d 轮） */
.tk-modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; align-items: stretch }
.tk-mode { position: relative; display: flex; cursor: pointer; margin: 0 }
.tk-mode input { position: absolute; opacity: 0; width: 0; height: 0 }
.tk-mode-b {
  flex: 1; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px;
  background: var(--surface); transition: border-color .15s, background .15s;
}
.tk-mode-b b { display: block; font-size: 13px; color: var(--text) }
/* 选中态：左边一个小圆点（光靠描边太淡，用户看不出选了哪个） */
.tk-mode-b b::before {
  content: ''; display: inline-block; width: 12px; height: 12px; margin-right: 7px; vertical-align: -2px;
  border: 1.5px solid var(--border-strong); border-radius: 50%; background: var(--surface);
}
.tk-mode input:checked + .tk-mode-b b::before {
  background: var(--accent); border-color: var(--accent);
  box-shadow: inset 0 0 0 2.5px var(--surface);
}
.tk-mode-b i { display: block; font-style: normal; font-size: 12px; color: var(--text-3); margin-top: 3px; line-height: 1.4 }
.tk-mode:hover .tk-mode-b { border-color: var(--border-strong) }
.tk-mode input:checked + .tk-mode-b { border-color: var(--accent); background: var(--accent-soft, var(--surface-2)) }
.tk-mode input:focus-visible + .tk-mode-b { outline: 2px solid var(--accent); outline-offset: 2px }
.tk-mode-pane { margin-top: 14px }
/* ⭐ 62e：左栏底部的显式保存条（自动保存在后台兜底，这个按钮立即存档 + 给明确反馈）。
   提示语占左边、按钮靠右下角，和全站弹窗底栏一个套路。 */
.tk-save-bar { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--border); }
.tk-save-bar .hint { flex: 1 1 auto; margin: 0 }
/* ⭐ 62h：独立域名「保存后自动建站」的结果框（步骤列表直接复用 .md-auto-steps 那套圆点） */
.tk-setup { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface) }
.tk-setup-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap }
.tk-setup-head strong { font-size: 13px }
.tk-setup-head .btn { margin-left: auto; flex-shrink: 0 }
.tk-url-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap }
.tk-url-line code {
  flex: 0 1 auto; min-width: 0; font-size: 12px; padding: 5px 9px; border-radius: 8px;
  background: var(--surface-2); border: 1px solid var(--border); word-break: break-all;
}
/* ⭐ 61f：解析说明做成**对齐的两行小表格**（原来两行各排各的 flex，两颗「复制」不在一条竖线上）。
   grid 四列 = 类型 / 主机记录 / 记录值 / 复制（最后一列 `auto`，两颗按钮自然对齐）。 */
.tk-dns { margin-top: 12px; padding: 12px; border: 1px dashed var(--border-strong); border-radius: 12px; background: var(--surface-2) }
.tk-dns-k { font-size: 12px; color: var(--text-2); margin-bottom: 10px }
.tk-dns-tb {
  display: grid; align-items: center; row-gap: 8px; column-gap: 10px;
  grid-template-columns: 62px minmax(52px, max-content) minmax(0, 1fr) auto;
}
.tk-dns-hd { font-size: 12px; color: var(--text-3) }
.tk-dns-t {
  justify-self: start; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 6px;
  background: var(--accent); color: #fff; white-space: nowrap;
}
.tk-dns-tb code {
  font-size: 12px; padding: 4px 8px; border-radius: 6px; background: var(--surface);
  border: 1px solid var(--border); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tk-dns-tb .btn { justify-self: end; white-space: nowrap }
/* ⭐ 63a（2026-10-15）：独立域名模式下「提交域名」+「申请证书」两颗按钮排（替换原来的「保存」配站一步） */
.tk-dom-btns { display: flex; align-items: center; gap: 10px; margin-top: 14px; flex-wrap: wrap }
.tk-dom-btns .hint { flex: 1 1 auto; margin: 0; min-width: 0 }
/* ⭐ 63b（2026-10-15）：独立域名「已绑定」状态条 —— 提交域名成功后替代编辑区显示 */
.tk-dom-bound { display: flex; align-items: center; gap: 10px; margin-top: 14px; flex-wrap: wrap;
  border: 1px solid var(--line, #e5e7eb); border-radius: 10px; padding: 10px 14px; background: var(--card2, #fafafa) }
.tk-dom-bound .tk-dom-ok { flex: 0 0 auto; background: #e8f7ee; color: #1a7f4b; border: 1px solid #bfe8cf;
  padding: 2px 10px; border-radius: 12px; font-size: 12px; font-weight: 600 }
.tk-dom-bound code { flex: 1 1 auto; min-width: 0; font-size: 13px; word-break: break-all }
.tk-dom-bound .btn { flex: 0 0 auto }
/* （.tk-logo-row / .tk-logo-box / .tk-logo-side 第 61d 轮删掉了：
     Logo 现在就是「站点设置」第三格里的小方图 .tk-logo-thumb + 两颗按钮） */
/* 右边预览：手机框（里面就是访客看到的那副样子）；页签在 #tk-prev-tabs（.tk-switch）那一排 */
.tk-ptab {
  padding: 4px 11px; font-size: 12px; cursor: pointer; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text-2);
}
.tk-ptab:hover { border-color: var(--accent); color: var(--accent) }
.tk-ptab.on { background: var(--accent); border-color: var(--accent); color: #fff }
/* ⭐ 62a：「＋ 加板块」是动作不是页签：虚线框，别跟其它页签抢眼 */
.tk-ptab-add { border-style: dashed; color: var(--text-3) }
.tk-ptab-add:hover { border-color: var(--accent); color: var(--accent) }
/* ⭐ 62c：右边预览区上面的标题（左栏每块都有编号标题，右边以前光秃秃一个手机框）
   ⭐ 62e：按用户要求「预览页面这几个字相对预览框居中」—— 去掉左边的竖条，改成整行居中 */
.tk-prev-head {
  font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 10px;
  display: flex; align-items: center; justify-content: center; text-align: center; line-height: 1.3;
}
.tk-prev-head strong { font-weight: 600 }
.tk-prev-phone {
  border: 1px solid var(--border); border-radius: 18px; background: var(--surface-2);
  padding: 10px; display: flex; justify-content: center;
}
/* ⭐ 62d：按用户要求「手机页面放大一点」—— 右栏 404→470，手机框 375×640→430×780（更接近真机比例）
   ⭐ 62e：用户又说「稍微大了一点点，按比例缩小一点」→ 470→440，手机框 430×780→400×726（同比例） */
.tk-prev-phone iframe { width: 100%; max-width: 400px; height: 726px; border: 0; border-radius: 10px; background: #fff; display: block }
@media (max-width: 1180px) {
  /* 窄屏放不下两栏：预览整块挪到下面，手机框居中 */
  .tk-manage { grid-template-columns: 1fr }
  .tk-right { position: static }
  .tk-prev-phone iframe { width: 100%; max-width: 400px }
}
/* 改一条链接 / 改一行文字的弹窗（左栏胶囊「修改」弹出） */
#tk-link-modal .modal-card { max-width: 460px; text-align: left }
/* ⭐ 62c：页脚联系 / 备案号的弹窗（左边两颗胶囊点「修改」弹出） */
#tk-site-modal .modal-card { max-width: 460px; text-align: left }
#tk-site-modal textarea { min-height: 66px; resize: vertical }
/* ⭐ 62c：保存按钮取消后，所有提示改成右下角浮动 toast（2.6 秒后自己消失）。
   z-index 要压过弹窗（.modal 是 60）——备案号「自动获取」的结果就得在弹窗上面看得见。 */
.tk-toast {
  position: fixed; right: 20px; bottom: 20px; z-index: 120; max-width: min(430px, 82vw);
  padding: 10px 14px; border-radius: 12px; font-size: 13px; line-height: 1.55;
  background: var(--surface); color: var(--text); border: 1px solid var(--border-strong);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .22); word-break: break-all;
}
.tk-toast.ok { border-color: var(--accent) }
.tk-toast.bad { border-color: var(--bad); color: var(--bad) }
@media (max-width: 640px) {
  .tk-toast { left: 12px; right: 12px; bottom: 12px; max-width: none }
}
/* 弹窗里「跳到本站」那排快选按钮 */
.tk-quick { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 10px }
.tk-quick-k { font-size: 12px; color: var(--text-3) }
.tk-quick-btn {
  cursor: pointer; font-family: inherit; font-size: 12px; padding: 4px 10px; border-radius: 999px;
  border: 1px dashed var(--border-strong); background: transparent; color: var(--text-2);
}
.tk-quick-btn:hover { border-style: solid; border-color: var(--accent); color: var(--accent) }

/* ⭐⭐ 62w：⑤ 联盟授权 / ⑥ 专链 / ⑦ 本地生活（暂时只对超管，app.js 按 isSuper() 显隐） */
.tk-union .field { margin-bottom: 10px }
.tk-union-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px }
.tk-union-note { font-size: 12px; color: var(--text-3); line-height: 1.6; margin: 2px 0 10px }
.tk-union-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap }
.tk-tool { display: flex; align-items: center; gap: 8px; flex-wrap: wrap }
.tk-tool-sel { width: auto; min-width: 150px; flex: 0 0 auto }
.tk-tool input[type="text"] { flex: 1 1 220px; min-width: 180px }
.tk-tool-out {
  margin-top: 12px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px; background: var(--surface-2);
}
.tk-tool-ttl { font-size: 12px; color: var(--text-2); margin-bottom: 8px }
.tk-tool-link { display: flex; gap: 8px; margin-bottom: 8px; flex-wrap: wrap }
.tk-tool-name { flex: 0 0 200px }
.tk-tool-url { flex: 1 1 220px; color: var(--text-2); font-size: 12px }
.tk-tool-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px }
.tk-tool-page { width: auto; min-width: 120px }
/* ⭐⭐ 62z：授权页 —— 各平台渠道网格 + 淘宝联盟直达链接 */
.tk-u-link { color: var(--accent); text-decoration: none; border-bottom: 1px dashed var(--accent) }
.tk-u-link:hover { border-bottom-style: solid }
.tk-u-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 12px }
.tk-u-cell { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px; background: var(--surface) }
.tk-u-cell-k { font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 6px }
.tk-u-cell-k .opt { font-weight: 400; color: var(--text-3); margin-left: 6px }
.tk-u-cell-v { width: 100%; margin-bottom: 6px }
.tk-u-cell-hdk { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-2); cursor: pointer }
/* ⭐⭐ 62z：专链三段式（内容 → 形式 → 结果）*/
.tk-tool3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; align-items: start }
.tk-tool-col { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; background: var(--surface-2); min-height: 180px }
.tk-tool-col .tk-tool-ttl { margin-bottom: 10px }
.tk-tool-ta {
  width: 100%; min-height: 96px; resize: vertical; font-family: inherit; font-size: 13px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 8px 10px;
  background: var(--surface); color: var(--text); margin-bottom: 8px;
}
.tk-forms { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px }
.tk-form { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--text-2); cursor: pointer }
.tk-form input { accent-color: var(--accent) }
.tk-tool-log { margin-top: 12px; border: 1px dashed var(--border-strong); border-radius: var(--radius-sm); padding: 10px 12px }
.tk-tool-log-list { max-height: 120px; overflow-y: auto; font-size: 12px; color: var(--text-3); line-height: 1.7 }
.tk-tool-log-row { word-break: break-all }
/* ⭐⭐ 62z：本地生活活动卡片墙（照官方后台那面墙） */
.tk-live-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px }
.tk-live-card { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: var(--surface); display: flex; flex-direction: column }
.tk-live-card-img { width: 100%; height: 110px; object-fit: cover; display: block; background: var(--surface-2) }
.tk-live-card-noimg { display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--text-3) }
.tk-live-card-b { padding: 10px; display: flex; flex-direction: column; gap: 6px; flex: 1 }
.tk-live-card-n { font-size: 13px; font-weight: 600; color: var(--text); line-height: 1.4 }
.tk-live-card-d { font-size: 12px; color: var(--text-3); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden }
.tk-live-card-t { font-size: 11px; color: var(--text-3) }
.tk-live-card-b .btn { margin-top: auto; align-self: flex-start }
.tk-live-more-row { margin-top: 12px; text-align: center }
@media (max-width: 720px) {
  .tk-union-2 { grid-template-columns: 1fr }
  .tk-tool-name { flex: 1 1 100% }
  .tk-u-grid { grid-template-columns: 1fr }
  .tk-tool3 { grid-template-columns: 1fr }
}
@media (max-width: 900px) {
  .tk-modes { grid-template-columns: 1fr }
}
@media (max-width: 640px) {
  .tk-top { display: block }   /* 窄屏：logo 一行、大标题一行 */
  .tk-top .tk-logo-thumb { margin-bottom: 10px }
  .tk-grid2 { grid-template-columns: 1fr }
  /* 窄屏胶囊：名字 + 四颗按钮一行，地址折到第二行（不折的话一颗胶囊要占三行） */
  .tk-chip { border-radius: 14px; padding: 8px 10px 8px 12px }
  .tk-chip-name { max-width: 100%; order: 1 }
  .tk-chip-mv, .tk-chip-edit, .tk-chip-del { order: 2 }
  .tk-chip-url { flex: 1 1 100%; order: 3 }
}
