/* ============================================================
   VOH 验证中心 · 设计系统 v4.0 「晨雾白瓷」
   亮色 · 单一克莱因蓝 · 无边框白卡柔影 · 精工字体与按钮。

/* ------------------------------------------------ 01 Tokens
   2026-10 改版（样张 A「白瓷 · 蓝阶」定稿）：
   · 亮色：白瓷底 + 白卡无边框极淡柔影；蓝色满色只给主按钮、数据条、当前导航图标，大面积只用浅色阶
   · 深色：纯中性黑（不偏藏青），卡片靠 1px 边分层，不加阴影
   · 全站不用渐变、不用发光（用户明确反感），按钮一律纯色                        */
:root {
  color-scheme: light;

  --bg: #f4f6fa;
  --bg-soft: #f6f8fb;
  --card: #ffffff;
  --line: #e6eaf1;
  --line-soft: #edf0f5;
  /* 交互底色：悬停 / 按下 */
  --hover: #e9edf3;
  --press: #e1e6ee;
  /* 控件描边：输入框、次按钮 */
  --control: #d6dce6;

  --text-1: #0f172a;
  --text-2: #525c6c;
  --text-3: #6b7280;
  /* 导航和标题前的灰图标 */
  --icon: #6b7383;

  /* 主色：克莱因蓝。wash / tint 是它的两级浅色阶，用在大面积 */
  --blue: #2563eb;
  --blue-deep: #1d4ed8;
  --blue-ink: #1e40af;
  --blue-hover: #1d4ed8;
  --blue-wash: #e8eefd;
  --blue-tint: #d9e4fc;
  --blue-light: #5b8ef8;

  --ok: #1f7a4d;
  --ok-wash: #e3f6ea;
  --warn: #b45309;
  --warn-fill: #d97706;
  --warn-wash: #fff4e2;
  --bad: #c4242a;
  --bad-wash: #ffedea;

  --r-lg: 16px;
  --r-md: 10px;
  --r-sm: 8px;

  --sidebar-w: 280px;
  --mobile-bar-h: 42px;

  --shadow-card: 0 1px 2px rgba(16, 24, 40, 0.04), 0 2px 8px rgba(16, 24, 40, 0.04);
  --shadow-pop: 0 4px 12px rgba(16, 24, 40, 0.08), 0 16px 40px rgba(16, 24, 40, 0.12);
  /* 卡片外沿：亮色下透明（靠柔影），深色下换成 1px 边 */
  --ring: 0 0 0 1px transparent;
  /* 数据区的浅井：表格头之外的终端、空状态、任务卡底 */
  --well-bg: #f6f8fb;
  --well-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.05);
  --hairline: #edf0f5;

  /* 字体：MiSans（项目自带字库，样张 A 定稿用的就是它）。
     以前用户嫌它「粗、糊」是因为正文 15.5px + 负字距 + optimizeLegibility，三样都已去掉 */
  --font: "MiSans", system-ui, -apple-system, "Segoe UI", "PingFang SC", "HarmonyOS Sans SC",
    "Microsoft YaHei", sans-serif;
  --mono: "Cascadia Code", ui-monospace, Consolas, "SF Mono", "PingFang SC", monospace;

  --speed: 0.16s;
  --ease: cubic-bezier(0.3, 0.9, 0.4, 1);
}

/* 深色：纯中性黑 */
html[data-theme="dark"] {
  color-scheme: dark;

  --bg: #0a0b0d;
  --bg-soft: #1a1d21;
  --card: #131518;
  --line: #23272d;
  --line-soft: #1e2126;
  --hover: #1b1e23;
  --press: #23272d;
  --control: #2e333b;

  --text-1: #f2f4f7;
  --text-2: #a8b0bd;
  --text-3: #8e96a4;
  --icon: #8e96a4;

  /* 按钮底色仍用克莱因蓝（白字够清楚）；文字和图标里的蓝提亮一档 */
  --blue: #2563eb;
  --blue-deep: #6f9bff;
  --blue-ink: #a8c3ff;
  --blue-hover: #3171f5;
  --blue-wash: rgba(77, 132, 255, 0.13);
  --blue-tint: rgba(77, 132, 255, 0.22);
  --blue-light: #6f9bff;

  --ok: #3fc07a;
  --ok-wash: rgba(63, 192, 122, 0.12);
  --warn: #f0a24a;
  --warn-fill: #e08a1e;
  --warn-wash: rgba(224, 138, 30, 0.12);
  --bad: #ff8b9b;
  --bad-wash: rgba(229, 86, 111, 0.14);

  --shadow-card: none;
  --shadow-pop: 0 8px 28px rgba(0, 0, 0, 0.55);
  --ring: 0 0 0 1px #1f2227;
  --well-bg: #0f1114;
  --well-shadow: inset 0 0 0 1px #1f2227;
  --hairline: #1e2126;
}

html[data-theme="dark"] .badge { background: var(--bg-soft); }
html[data-theme="dark"] .badge-active { color: #3fc07a; border-color: #1c3a2a; }
html[data-theme="dark"] .badge-completed { color: #8fb2ff; border-color: #22324f; }
html[data-theme="dark"] .badge-waiting_code,
html[data-theme="dark"] .badge-unverified { color: #f0a24a; border-color: #3d2e17; }
html[data-theme="dark"] .badge-expired,
html[data-theme="dark"] .badge-disabled { color: #8e96a4; border-color: var(--line); }
html[data-theme="dark"] .badge-failed,
html[data-theme="dark"] .badge-revoked { color: #ff8b9b; border-color: #47242c; }

html[data-theme="dark"] input:not([type="checkbox"]):not([type="radio"]),
html[data-theme="dark"] select,
html[data-theme="dark"] textarea {
  /* 只换底色：写成 background 简写会把下拉框画箭头的 background-image 一起清掉，暗色下所有 select 都没了箭头 */
  background-color: var(--card);
  border-color: var(--control);
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder { color: #6c7380; }

html[data-theme="dark"] .search-form { border-color: var(--control); color: var(--text-1); }

html[data-theme="dark"] .cloud-button { background: #12a06c; }
html[data-theme="dark"] .cloud-button:hover { background: #16b479; }

html[data-theme="dark"] .public-header { background: rgba(10, 11, 13, 0.86); }

html[data-theme="dark"] .avatar::after { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08); }

html[data-theme="dark"] .preview-dots i:first-child { background: #8a4b4b; }
html[data-theme="dark"] .preview-dots i:nth-child(2) { background: #8a7440; }
html[data-theme="dark"] .preview-dots i:last-child { background: #3f7a5c; }

/* ------------------------------------------------ 02 Reset & Base */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-1);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* 表单控件与按钮在部分浏览器不继承字体，显式指定，避免回退到丑字体 */
input,
select,
textarea,
button,
optgroup,
option,
h1, h2, h3, h4, h5, h6,
th, td, label, small, strong, b, em, span, div, p, a, time, li {
  font-family: var(--font);
}

/* 仅这些位置使用等宽字体（真正的代码 / 密钥） */
code,
.issued-token input,
.issued-textarea,
.copy-field input,
.redeem-form input,
.sha-code,
.legacy-code,
.dev-code strong {
  font-family: var(--mono);
}

h1, h2, h3, h4, p { margin: 0; }

/* hidden 属性必须真正隐藏：很多组件用 .xxx{display:flex/grid} 会盖掉 hidden 的
   display:none，导致空面板（如未运行时的"正在处理"进度条）一直挂在页面上显得杂乱。 */
[hidden] { display: none !important; }

a { color: inherit; text-decoration: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0;
}

img, svg { display: block; max-width: 100%; }

code { font-family: var(--mono); font-size: 0.86em; }

::selection { background: rgba(37, 99, 235, 0.16); }

.icon { width: 20px; height: 20px; flex: none; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  z-index: 200;
  padding: 8px 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}

.skip-link:focus { left: 8px; }

.inline { display: inline-flex; }

.text-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-2);
  padding: 8px 12px;
  border-radius: var(--r-sm);
  transition: color var(--speed), background var(--speed);
}

.text-link:hover { color: var(--text-1); background: var(--line-soft); }

/* 区域标题的灰色概括图标 */
.head-icon {
  display: inline-flex;
  vertical-align: -3px;
  margin-right: 10px;
  color: var(--icon);
}

.head-icon .icon { width: 20px; height: 20px; }

h2 .head-icon .icon { width: 18px; height: 18px; }
h2 .head-icon { vertical-align: -2.5px; margin-right: 9px; }

/* ------------------------------------------------ 03 按钮
   四级：主（纯蓝，一屏一个）/ 次（白底描边）/ 小（chip，行内操作）/ 纯图标。
   高度 36 / 30 / 34，圆角 10 / 8 / 8；图标 16 / 15 / 18。
   不上浮、不发光、不用渐变；按下统一 scale(0.975)，见「12 动效 · 微交互」。 */
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 16px;
  border-radius: var(--r-md);
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: var(--blue);
  white-space: nowrap;
}

.primary-button .icon { width: 16px; height: 16px; }
.primary-button:hover { background: var(--blue-hover); }
.primary-button.large { min-height: 44px; padding: 0 24px; font-size: 15px; border-radius: 12px; }
.primary-button.wide { width: 100%; }

.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 15px;
  border-radius: var(--r-md);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  background: var(--card);
  border: 1px solid var(--control);
  white-space: nowrap;
}

.ghost-button .icon { width: 16px; height: 16px; color: var(--icon); }
.ghost-button:hover { background: var(--bg-soft); }
.ghost-button.large { min-height: 44px; padding: 0 22px; font-size: 15px; border-radius: 12px; }

/* 云端面板入口：绿色实心按钮，主文案 + 第二行小字说明 */
.cloud-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 8px 18px;
  border-radius: var(--r-md);
  white-space: nowrap;
  color: #fff;
  background: #0f9d63;
}

.cloud-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.cloud-label b {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}

.cloud-label small {
  font-size: 12px;
  font-weight: 500;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.85);
}

.cloud-button .icon { width: 17px; height: 17px; }
.cloud-button:hover { background: #0c8a57; }

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--r-sm);
  color: var(--icon);
  transition: color var(--speed), background var(--speed);
}

.icon-button:hover { color: var(--text-1); background: var(--hover); }
.icon-button .icon { width: 18px; height: 18px; }

.chip-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 11px;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
  background: var(--card);
  border: 1px solid var(--control);
  white-space: nowrap;
}

.chip-button .icon { width: 15px; height: 15px; color: var(--icon); }
.chip-button:hover { background: var(--bg-soft); }

.chip-button.primary { color: #fff; border-color: transparent; background: var(--blue); }
.chip-button.primary .icon { color: currentColor; }
.chip-button.primary:hover { color: #fff; background: var(--blue-hover); }

.chip-button.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 30%, var(--control)); background: var(--card); }
.chip-button.danger .icon { color: currentColor; }
.chip-button.danger:hover { background: var(--bad-wash); border-color: var(--bad); }
.chip-button.copy-failed { color: var(--bad); border-color: var(--bad); }

/* ------------------------------------------------ 04 通用组件 */

/* 白瓷卡片 */
.panel,
.glass {
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.panel { padding: 20px; }

/* 纵向堆叠的块之间的统一间距。
   企业卡片也要算进来：它不是 .panel，漏掉它就会和紧随其后的「其他权益」
   糊成一整块白底，看起来像同一张卡。 */
.panel + .panel,
.panel + .two-col,
.two-col + .panel,
.enterprise-card + .panel,
.panel + .enterprise-card { margin-top: 16px; }

/* 状态徽章：白底细边 + 色点，色彩克制（过期/停用为中性灰，红色只留真正的异常） */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2.5px 9px 2.5px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--text-2);
  white-space: nowrap;
}

.badge i {
  width: 5.5px;
  height: 5.5px;
  border-radius: 50%;
  background: #b6bfd0;
}

.badge-active { color: #0d7a5c; border-color: #cdeadf; }
.badge-active i { background: #10b981; }

.badge-completed { color: #1e50d6; border-color: #d3e0fb; }
.badge-completed i { background: var(--blue); }

.badge-waiting_code,
.badge-unverified { color: #96690d; border-color: #eddfc0; }
.badge-waiting_code i,
.badge-unverified i { background: #e7a516; }

.badge-expired,
.badge-disabled { color: #7a8499; border-color: var(--line); }
.badge-expired i,
.badge-disabled i { background: #c1c9d6; }

.badge-failed,
.badge-revoked { color: #c73a4f; border-color: #f4d5da; }
.badge-failed i,
.badge-revoked i { background: #e5495f; }


/* 头像：QQ 邮箱注册自动取 QQ 头像，否则首字母渐变方块 */
.avatar {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 12px;
  font-weight: 700;
  color: #fff;
  background: var(--blue);
  overflow: hidden;
}

.avatar.avatar-photo { background: var(--line-soft); }

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.avatar::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.07);
  pointer-events: none;
}

.avatar.small { width: 34px; height: 34px; border-radius: 10px; font-size: 14px; }

.avatar.large {
  width: 72px;
  height: 72px;
  font-size: 28px;
  border-radius: 16px;
}

/* 进度条 */
.progress {
  height: 5px;
  min-height: 5px;
  flex: none;
  border-radius: 999px;
  background: var(--line-soft);
  overflow: hidden;
}

.progress.slim { height: 4px; min-height: 4px; margin: 2px 0; }

.progress i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: var(--blue);
  transition: width 0.8s var(--ease);
}

/* 蓝色主卡内的进度条 */

/* 空状态 */
/* 空状态：保留区块的框，里面一句话 + 下一步按钮，不画大圆圈图标、不撑大高度 */
.empty-state {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 22px 20px;
  text-align: center;
  border: 1px dashed var(--control);
  border-radius: var(--r-md);
  color: var(--text-2);
}

.empty-state .empty-icon { display: none; }

.empty-state strong { color: var(--text-1); font-size: 14px; }

.empty-state p {
  max-width: 380px;
  font-size: 13px;
  color: var(--text-2);
}

/* 数据表 */
.table-scroll {
  overflow-x: auto;
  margin: 2px -6px 0;
  padding: 0 6px;
}

.data-table {
  width: 100%;
  min-width: 660px;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table th {
  padding: 9px 14px;
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-3);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.data-table td {
  padding: 13px 14px;
  vertical-align: middle;
  border-bottom: 1px solid var(--line-soft);
  color: var(--text-2);
}

.data-table td strong { color: var(--text-1); font-weight: 600; }

.data-table td small {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  color: var(--text-3);
}

.data-table tbody tr { transition: background var(--speed); }
.data-table tbody tr:hover { background: var(--bg-soft); }

.data-table .empty-cell {
  padding: 32px;
  text-align: center;
  color: var(--text-3);
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

/* 分区页头 */
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.section-head .head-icon { display: none; }

.section-head h1 {
  font-size: 24px;
  font-weight: 700;
  /* 中文方块字不能用负字距，笔画会挤在一起发糊。中文标题一律 0 或极小正值 */
  letter-spacing: 0;
  line-height: 1.3;
}

.section-head p {
  margin-top: 4px;
  max-width: 720px;
  font-size: 14px;
  color: var(--text-2);
}

.section-aside {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* 面板头 */
.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.panel-head h2 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
}

/* 面板右上角的操作区。里面的 <form> 是块级的，不横过来的话
   两个按钮会各占一行，头部被撑高一截。 */
.panel-action {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.panel-head p {
  margin-top: 2px;
  max-width: 640px;
  font-size: 13px;
  color: var(--text-3);
}

/* 搜索框 */
.search-form {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px 5px 13px;
  border: 1px solid #dbe1ea;
  border-radius: var(--r-md);
  background: var(--card);
  color: var(--text-3);
  transition: border-color var(--speed), box-shadow var(--speed);
}

.search-form:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-form .icon { width: 15px; height: 15px; }

.search-form input {
  width: 190px;
  border: 0;
  background: none;
  color: var(--text-1);
  font: inherit;
  font-size: 14px;
  outline: none;
  box-shadow: none;
  padding: 3px 0;
  border-radius: 0;
}

.search-form input::placeholder { color: var(--text-3); }

/* 搜索框里的输入框不要再画一层基础输入框的边和高度 */
.search-form input:not([type="checkbox"]):not([type="radio"]) {
  min-height: 0;
  border: 0;
  background: none;
  box-shadow: none;
  padding: 3px 0;
}

/* ------------------------------------------------ 05 表单 */
.form-stack { display: grid; gap: 14px; }

.form-stack label,
.smtp-grid label,
.card-create-grid label,
.client-upload-form label {
  display: grid;
  gap: 7px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--text-2);
}

input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  width: 100%;
  min-height: 38px;
  padding: 7px 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 400;
  color: var(--text-1);
  background: var(--card);
  border: 1px solid var(--control);
  border-radius: var(--r-md);
  outline: none;
  transition: border-color var(--speed), box-shadow var(--speed);
}

input::placeholder,
textarea::placeholder { color: #9aa3b2; font-weight: 400; }

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

input[readonly] { color: var(--text-2); background: var(--bg-soft); }

textarea { min-height: 84px; resize: vertical; }

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%),
    linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.split-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-hint {
  font-size: 13px;
  color: var(--text-3);
  font-weight: 400;
}

.form-foot {
  margin-top: 16px;
  text-align: center;
  font-size: 14px;
  color: var(--text-2);
}

.form-foot a { color: var(--blue); font-weight: 600; }
.form-foot a:hover { text-decoration: underline; }

.check-label {
  display: flex !important;
  flex-direction: row;
  align-items: center;
  gap: 9px;
}

.check-label input {
  width: 16px;
  height: 16px;
  accent-color: var(--blue);
}

.divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 18px 0 14px;
  font-size: 13px;
  color: var(--text-3);
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.inline-code-form {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.inline-code-form label {
  flex: 1;
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

.dev-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding: 10px 15px;
  border-radius: var(--r-md);
  border: 1px dashed #ecc98a;
  background: var(--warn-wash);
  font-size: 13px;
  color: var(--warn);
}

.dev-code strong {
  font-size: 18px;
  letter-spacing: 0.18em;
  font-family: var(--mono);
}

/* ------------------------------------------------ 06 公开页 */
.public-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bg);
  /* 兜底：窄屏若有元素略超视口，裁掉横向溢出、不产生横向滚动条，
     整页就不会被顶偏。用 clip 而非 hidden——clip 不创建滚动容器，不破坏 sticky 顶栏。 */
  overflow-x: clip;
}

.public-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.public-header-inner {
  width: min(1080px, calc(100% - 48px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 15px 0;
}

/* 字标 + 一行小字，小字和字标底边对齐 */
.brand {
  display: inline-flex;
  align-items: flex-end;
  gap: 10px;
  color: var(--blue);
}

html[data-theme="dark"] .brand { color: var(--blue-deep); }

.brand .wordmark { height: 22px; width: auto; flex: none; }

.brand small {
  font-size: 12px;
  line-height: 1;
  padding-bottom: 2px;
  color: var(--text-3);
  white-space: nowrap;
}

.public-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.public-main {
  flex: 1;
  width: min(1080px, calc(100% - 48px));
  margin: 0 auto;
  padding: 30px 0 80px;
}

.public-foot,
.app-foot {
  padding: 24px;
  text-align: center;
  font-size: 13px;
  color: var(--text-3);
}

/* Hero */
.hero-center {
  display: grid;
  justify-items: center;
  text-align: center;
  padding: 66px 0 30px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  background: var(--card);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.hero-badge .icon { width: 15px; height: 15px; color: #7b78ea; }

.hero-center h1 {
  margin-top: 24px;
  max-width: 720px;
  font-size: clamp(34px, 5.6vw, 56px);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.12;
}

/* 标题不单独给某几个字染色（2026-10 改版：一行标题一个颜色） */
.hero-center h1 em {
  font-style: normal;
  color: inherit;
}

.hero-center > p {
  margin-top: 18px;
  max-width: 520px;
  font-size: 16px;
  color: var(--text-2);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 30px;
}

/* Hero 预览卡 */
.hero-preview {
  width: min(880px, 100%);
  margin: 52px auto 0;
  padding: 22px 24px 26px;
  text-align: left;
  background: var(--card);
  border-radius: 16px;
  box-shadow: var(--shadow-pop);
}

.preview-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 13px;
  color: var(--text-2);
}

.preview-dots { display: inline-flex; gap: 6px; }

.preview-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line);
}

.preview-dots i:first-child { background: #f4b6b6; }
.preview-dots i:nth-child(2) { background: #f2d9a4; }
.preview-dots i:last-child { background: #b3e2c8; }

.preview-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr;
  gap: 12px;
}

.preview-cell {
  display: grid;
  gap: 5px;
  align-content: start;
  padding: 16px 18px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.preview-cell.hero-cell {
  background: var(--blue);
  border-color: transparent;
}

.preview-cell span { font-size: 12px; color: var(--text-3); }
.preview-cell.hero-cell span { color: rgba(255, 255, 255, 0.82); }

.preview-cell strong {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.preview-cell.hero-cell strong { color: #fff; }

.preview-cell strong em {
  font-style: normal;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-3);
}

.preview-cell small { font-size: 12px; color: var(--text-2); }
.preview-cell.hero-cell small { color: rgba(255, 255, 255, 0.72); }

.live-pill {
  font-style: normal;
  font-size: 13px;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 8px;
  color: var(--ok);
  background: var(--ok-wash);
}

/* 特性网格 */
.feature-bento {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 84px;
}

.feature-bento > div {
  display: grid;
  gap: 6px;
  align-content: start;
  padding: 24px 26px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  transition: background var(--speed);
}

.feature-bento > div:hover {
}

.feature-bento .icon {
  width: 22px;
  height: 22px;
  color: var(--text-3);
  margin-bottom: 8px;
}

.feature-bento b { font-size: 16px; font-weight: 700; color: var(--text-1); }

.feature-bento small {
  font-size: 13px;
  color: var(--text-2);
  max-width: 420px;
}

.feature-bento em { display: none; }

/* 定价 */
.public-section { padding: 84px 0 0; }

.section-intro {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 6px;
  margin-bottom: 34px;
}

.section-intro h2 {
  font-size: clamp(26px, 3.4vw, 36px);
  font-weight: 700;
  letter-spacing: 0;
}

.section-intro p { color: var(--text-2); max-width: 460px; font-size: 15px; }

/* 六档方案（含商业）：190px 起排会变成 5 + 1 的孤儿行，
   280px 起排在常见宽度下正好 3 列，六张卡排成整齐的两行。 */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 13px;
  align-items: stretch;
}

.plan-card {
  position: relative;
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 24px 22px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  transition: background var(--speed);
}

.plan-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-pop); }

.plan-card.current,
.enterprise-card.current { border: 1.5px solid #74cca8; }

.recommended {
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 13px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: var(--blue);
  white-space: nowrap;
}

.plan-card.featured {
  border: 1.5px solid var(--blue);
  background: var(--card);
}

.plan-desc { font-size: 12px; color: var(--text-3); }

.plan-card h3 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0;
}

.price { display: flex; align-items: baseline; gap: 4px; }

.price b {
  font-size: 24px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}

.price small { color: var(--text-3); font-size: 13px; }

.plan-quota {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 11px 14px;
  border-radius: var(--r-md);
  background: var(--blue-wash);
}

.plan-quota strong {
  font-size: 20px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--blue-deep);
}

.plan-quota span { font-size: 12px; color: var(--text-2); }

.plan-card > p { font-size: 13px; color: var(--text-2); }

/* 企业档通栏卡：左边定位与价格，右边三条要点。
   它卖的是出口形态而不是额度多少，跟上面按额度分级的六张卡不是一个维度，
   所以既不排进那个网格（会多出一张孤儿卡），也不套 .plan-card 的额度块排版。 */
.enterprise-card {
  display: grid;
  grid-template-columns: minmax(0, 290px) minmax(0, 1fr);
  gap: 26px;
  align-items: center;
  margin-top: 13px;
  padding: 24px 26px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.enterprise-copy { display: grid; gap: 7px; align-content: start; }

.enterprise-copy h3 { font-size: 20px; font-weight: 700; letter-spacing: 0; }

.enterprise-copy p { font-size: 13px; color: var(--text-2); }

.enterprise-points {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(196px, 1fr));
  gap: 10px;
  list-style: none;
}

.enterprise-points li {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  column-gap: 10px;
  row-gap: 2px;
  padding: 13px 15px;
  border-radius: var(--r-md);
  background: var(--blue-wash);
}

.enterprise-icon {
  grid-row: 1 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--blue-deep);
}

.enterprise-points b { font-size: 14px; font-weight: 700; }

.enterprise-points small { font-size: 12px; color: var(--text-2); line-height: 1.45; }

/* 同理：六项永久权益按 260px 起排，3 列两行，不留孤儿 */
.lifetime-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 6px;
  margin-top: 16px;
  padding: 16px 20px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.lifetime-row > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 12px;
  font-size: 14px;
  color: var(--text-2);
}

.lifetime-row strong {
  color: var(--text-1);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

/* 登录 / 注册 */
.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 430px);
  align-items: center;
  gap: 56px;
  padding: 48px 0;
  min-height: 62vh;
}

.auth-side h1 {
  margin-top: 14px;
  font-size: clamp(28px, 3.8vw, 42px);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.18;
}

.auth-side h1 em { font-style: normal; color: inherit; }

.auth-side > p {
  margin-top: 14px;
  max-width: 420px;
  color: var(--text-2);
  font-size: 15px;
}

.auth-notes {
  display: grid;
  gap: 10px;
  margin-top: 28px;
}

.auth-notes span {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-2);
}

.auth-notes .icon { width: 16px; height: 16px; color: var(--ok); }

.auth-card {
  padding: 30px 30px 24px;
  background: var(--card);
  border-radius: 16px;
  box-shadow: var(--shadow-pop);
}

/* ------------------------------------------------ 07 应用壳（单栏侧边导航）
   侧栏直接铺在页面底色上，不画分隔线；从上到下：字标 / 搜索 / 分组导航 / 额度卡 / 账号行。
   导航行 36px、图标 18px；当前项 = 浅蓝底 + 蓝图标，不加左侧竖条。
   角标只挂在要处理的队列上：红 = 出错，浅蓝 = 可更新。 */
.app-body { min-height: 100vh; }

.app-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  align-self: flex-start;
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: var(--sidebar-w);
  height: 100vh;
  flex: none;
  padding: 18px 16px 14px;
  background: var(--bg);
}

@media (min-width: 1600px) {
  :root { --sidebar-w: 300px; }
  .sidebar { padding: 20px 18px 16px; gap: 14px; }
}

.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 8px 2px 10px;
}

/* 纯字标 + 右侧定位语横排底边对齐（去掉冗余左侧蓝方块，与公开页 .brand 同构） */
.sidebar-brand {
  display: inline-flex;
  align-items: flex-end;
  gap: 10px;
  min-width: 0;
  color: var(--blue);
}

html[data-theme="dark"] .sidebar-brand { color: var(--blue-deep); }

.sidebar-brand .wordmark { display: block; height: 20px; width: auto; flex: none; }

.sidebar-brand small {
  font-size: 13px;
  line-height: 1;
  padding-bottom: 1.5px;
  color: var(--text-3);
  white-space: nowrap;
}

.sidebar-head,
.sidebar-search { flex: none; }

.sidebar-search {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 11px 0 14px;
  border-radius: 11px;
  background: var(--card);
  box-shadow: var(--ring), var(--shadow-card);
  color: var(--text-3);
  font-size: 14.5px;
  text-align: left;
}

.sidebar-search .icon { width: 18px; height: 18px; }
.sidebar-search span { white-space: nowrap; }
.sidebar-search kbd {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--bg-soft);
  font: inherit;
  font-size: 12.5px;
  white-space: nowrap;
}
.sidebar-search:hover { color: var(--text-2); }

.sidebar-nav {
  display: grid;
  gap: 14px;
  flex: 1 1 auto;
  min-height: 0;
  align-content: start;
  overflow-y: auto;
  /* 滚动条平时透明（只占一条细缝不挤内容），鼠标移进导航才显出来 */
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
  scrollbar-gutter: stable;
  margin: 0 -2px;
  padding: 0 2px 18px;
  /* 导航比侧栏长时（管理员）底部淡出，不让一行字被额度卡切掉半截 */
  mask-image: linear-gradient(to bottom, #000 calc(100% - 18px), transparent);
}

.sidebar-group {
  display: grid;
  gap: 3px;
}

.sidebar-group-label {
  padding: 0 12px 4px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-3);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 13px;
  height: 40px;
  padding: 0 14px;
  border-radius: var(--r-md);
  font-size: 15.5px;
  font-weight: 500;
  /* 未选中项也用主文字色——一排灰字整个导航都看不清（用户投诉过） */
  color: var(--text-1);
  transition: background var(--speed);
}

.nav-item .icon {
  width: 20px;
  height: 20px;
  flex: none;
  color: var(--icon);
}

.nav-item:hover { background: var(--hover); }
.nav-item:active { background: var(--press); }

.nav-item.active {
  color: var(--blue-ink);
  background: var(--blue-wash);
  font-weight: 600;
}

.nav-item.active .icon { color: var(--blue); }
html[data-theme="dark"] .nav-item.active .icon { color: var(--blue-deep); }

.nav-count {
  margin-left: auto;
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  border-radius: 11px;
  background: var(--bad);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 22px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

html[data-theme="dark"] .nav-count { background: #e5566f; }
.nav-count.is-soft { background: var(--blue-tint); color: var(--blue-ink); }

.sidebar-foot {
  display: grid;
  gap: 10px;
  flex: none;
}

/* 额度小卡：大数字 + 一行说明，右上角一个去兑换的图标钮 */
.plan-brief {
  display: grid;
  gap: 8px;
  padding: 13px 14px 11px 15px;
  border-radius: 15px;
  background: var(--card);
  box-shadow: var(--ring), var(--shadow-card);
}

.plan-brief-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.plan-brief-top small {
  display: block;
  font-size: 12.5px;
  color: var(--text-3);
}

.plan-brief-top strong {
  display: block;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.28;
  font-variant-numeric: tabular-nums;
}

.plan-brief-of { font-size: 13.5px; font-weight: 400; color: var(--text-3); }

.plan-brief-top .icon-button { width: 34px; height: 34px; margin: -2px -2px 0 0; }

.plan-brief-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--line-soft);
  font-size: 13.5px;
  color: var(--text-2);
}

.plan-brief-row b { color: var(--text-1); font-weight: 600; }

.plan-brief-row a {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-weight: 500;
  color: var(--blue-ink);
}

.plan-brief-row a .icon { width: 15px; height: 15px; }

.sidebar-account {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 2px 0 6px;
}

.sidebar-account .avatar.small {
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 50%;
  font-size: 15px;
}

.sidebar-account-copy {
  display: grid;
  gap: 2px;
  flex: 1 1 auto;
  line-height: 1.35;
  min-width: 0;
}

.sidebar-account-copy strong {
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-account-copy small {
  font-size: 12.5px;
  color: var(--text-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-account .icon-button { width: 36px; height: 36px; }
.sidebar-account .icon-button .icon { width: 19px; height: 19px; }

.sidebar-close { display: none; }

.side-backdrop { display: none; }

/* 内容列 */
.app-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* 主题切换按钮 */
.theme-toggle .theme-moon { display: none; }
html[data-theme="dark"] .theme-toggle .theme-sun { display: none; }
html[data-theme="dark"] .theme-toggle .theme-moon { display: inline-flex; }

.mobile-bar { display: none; }

/* 主内容区的竖向节奏：页头之后的每个区块之间统一 16px。
   以前靠「.panel + .panel」这类成对规则拼，漏一种组合就会两块贴在一起（用量分析页就是） */
.app-main > * + * { margin-top: 16px; }
.app-main > .section-head + * { margin-top: 0; }

.app-main {
  flex: 1;
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 30px 34px 48px;
}

/* ------------------------------------------------ 08 总览 */
.overview-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

/* 总览第一行：三张同规格卡片（进服额度 / 辅助用户 / 服务器卡槽），
   每张：标签行 → 大数字 → 一行说明（或进度条）→ 底部一行说明 + 对应操作 */
.ov-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.ov-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px 20px;
}

.ov-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  font-size: 13px;
  color: var(--text-2);
}

.ov-top small { font-size: 12px; color: var(--text-3); }

.ov-num {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.ov-num em {
  font-style: normal;
  font-size: 14px;
  font-weight: 400;
  color: var(--text-3);
}

.ov-card .progress { height: 6px; min-height: 6px; background: var(--blue-wash); }

.ov-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-2);
}

.ov-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--text-3);
}

.ov-foot > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.ov-split {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  margin-top: 16px;
}

.ov-split > * { min-width: 0; }

/* 横排里的卡片不吃「.panel + .panel」的竖向间距 */
.ov-grid > .panel,
.ov-split > .panel { margin-top: 0; }

/* 快捷入口：一列可点的行，图标 + 两行字 + 右箭头 */
.quick-list { display: grid; margin: -6px -10px -8px; }

.quick-list a {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: var(--r-md);
  transition: background var(--speed);
}

.quick-list a + a { box-shadow: 0 -1px 0 var(--line-soft); }
.quick-list a:hover { background: var(--hover); box-shadow: none; }
.quick-list a:hover + a { box-shadow: none; }
.quick-list .icon { width: 18px; height: 18px; color: var(--icon); }
.quick-list a > .icon:last-child { width: 16px; height: 16px; color: var(--text-3); }
.quick-list span { display: grid; gap: 1px; min-width: 0; }
.quick-list b { font-size: 14px; font-weight: 600; }
.quick-list small { font-size: 12px; color: var(--text-3); }

.stat-card {
  display: grid;
  gap: 6px;
  align-content: start;
  padding: 20px 22px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

.stat-top .icon { width: 17px; height: 17px; color: var(--text-3); }

.stat-card .metric-number {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.stat-card .metric-number em {
  font-style: normal;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-3);
}

.stat-card p { font-size: 13px; color: var(--text-2); }
.stat-card p b.good { color: var(--ok); }
.stat-card small { font-size: 12px; color: var(--text-3); }
.plan-expiry { display: block; }

/* 两栏 */
.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 14px;
  margin-top: 16px;
}

/* 两栏里可能放带最小宽度的数据表。允许卡片收缩，超出的表格只在自己的
   .table-scroll 内滚动，避免用户详情等页面把整个手机视口撑宽。 */
.two-col > * { min-width: 0; }

/* 快捷入口 */
.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.quick-grid a {
  display: grid;
  gap: 3px;
  padding: 15px 16px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}

.quick-grid a:hover {
  border-color: #c8d8f8;
  background: var(--blue-wash);
}

.quick-grid .icon {
  width: 18px;
  height: 18px;
  color: var(--text-3);
  margin-bottom: 5px;
}

.quick-grid a:hover .icon { color: var(--blue); }

.quick-grid b { font-size: 14px; font-weight: 600; }
.quick-grid small { font-size: 12px; color: var(--text-3); }

.admin-quick { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }

/* 时间线 */
/* hero 卡右下角那个「N 个任务进行中」的入口。
   克制：半透明描边胶囊 + 一个跳动的点，不加发光也不加渐变文字。
   只在真的有任务在跑时才出现，所以它是信息不是装饰。 */
.preview-note {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--text-3);
  text-align: center;
}

.preview-note a { color: var(--blue); text-decoration: none; }
.preview-note a:hover { text-decoration: underline; }

.timeline { display: grid; gap: 2px; }

.timeline > div,
.timeline-row {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 9px 2px;
}

/* 动态流的每一条都能点进去看详情，所以做成链接。
   整行的悬停反馈用一层向外扩的底色，不给文字加下划线——
   下划线会把这一列本来很整齐的排版打散。 */
.timeline-row {
  border-radius: var(--r-sm);
  color: inherit;
  text-decoration: none;
  isolation: isolate;
  transition: background-color 0.16s var(--ease-out);
}

.timeline-row::after {
  content: "";
  position: absolute;
  inset: 2px -8px;
  border-radius: var(--r-sm);
  background: transparent;
  transition: background-color 0.16s var(--ease-out);
  z-index: -1;
}

.timeline-row:hover::after { background: var(--bg-soft); }
.timeline-row:hover strong { color: var(--blue-deep); }

.timeline > div:not(:last-child)::before,
.timeline-row:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 4.5px;
  top: 27px;
  bottom: -7px;
  width: 1px;
  background: var(--line);
}

.timeline i {
  flex: none;
  width: 10px;
  height: 10px;
  margin-top: 6px;
  border-radius: 50%;
  background: var(--blue);
}

.timeline i.muted { background: #cbd5e1; }
.timeline i.ok { background: var(--ok); }
.timeline i.bad { background: var(--bad); }

/* 进行中：全站唯一允许循环的动效（另一处是侧栏的服务状态灯）。
   它传达的是"这件事还在动"，不是装饰——静止的点跟已完成分不出来。 */
.timeline i.live {
  background: var(--blue);
  animation: pulse-dot 1.9s var(--ease-out) infinite;
}

@keyframes pulse-dot {
  0% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.45); }
  70% { box-shadow: 0 0 0 7px rgba(37, 99, 235, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}

.timeline span {
  flex: 1;
  display: grid;
  line-height: 1.45;
}

.timeline strong {
  font-size: 14px;
  font-weight: 600;
  transition: color 0.16s var(--ease-out);
  /* 建筑名可以很长，超出就截断，别把右边的时间挤走 */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.timeline small {
  font-size: 12px;
  color: var(--text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.timeline time { font-size: 13px; color: var(--text-3); white-space: nowrap; }

/* ------------------------------------------------ 09 控制台分区 */

/* 辅助用户 */
.helper-list { display: grid; gap: 9px; }

.helper-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 17px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}

.helper-card:hover { border-color: var(--line); background: var(--card); }

.helper-info {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 2px;
}

.helper-info > div {
  display: flex;
  align-items: center;
  gap: 9px;
}

.helper-info strong { font-size: 14px; font-weight: 600; }
.helper-info small { font-size: 13px; color: var(--text-3); }

.primary-tag {
  padding: 2px 9px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--blue-deep);
  background: var(--blue-tint);
}

.helper-health {
  display: grid;
  justify-items: end;
  gap: 7px;
}

.helper-health small { font-size: 13px; color: var(--text-3); }

.helper-badges {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.helper-ops {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.helper-ops .chip-button .icon { width: 12px; height: 12px; }

.level-badge {
  display: inline-flex;
  align-items: center;
  padding: 2.5px 9px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--blue-deep);
  background: var(--blue-tint);
  white-space: nowrap;
}

/* 账号卡上的最近一次检测结论 */
.check-line {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
}

.check-line .icon { width: 13px; height: 13px; flex: none; }
.check-line b { font-weight: 700; }
.check-line span { color: var(--text-3); }
.check-line.ok, .check-line.ok b { color: var(--ok); }
.check-line.bad, .check-line.bad b { color: var(--bad); }
.check-line.warn, .check-line.warn b { color: var(--warn); }

/* 一键检测 / 批量导入的进度区 */
.helper-task {
  display: grid;
  gap: 9px;
  margin-bottom: 12px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.helper-task[data-state="failed"] { border-color: #f2c9c9; background: var(--bad-wash); }
.helper-task[data-state="done"] { border-color: #bfe3d2; background: var(--ok-wash); }

.helper-task-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
}

.helper-task-head strong { font-weight: 600; }

.helper-task-head span {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.helper-task-bar {
  height: 5px;
  border-radius: 999px;
  background: var(--line-soft);
  overflow: hidden;
}

.helper-task-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
  transition: width 0.4s var(--ease);
}

/* 逐条结果：最多几十行，超出就自己滚，不把页面撑长 */
.helper-task-log {
  display: grid;
  gap: 4px;
  max-height: 190px;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 12px;
}

.helper-task-log:empty { display: none; }

.task-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.task-item b { flex: none; font-weight: 600; }
.task-item span { color: var(--text-2); }
.task-item.alive b { color: var(--ok); }
.task-item.dead b { color: var(--bad); }
.task-item.skipped b { color: var(--text-3); }
.task-item.error b { color: var(--warn); }

/* 批量改名的效果预览：三个样例名 + 参数不合法时的一行提示 */
.rename-preview {
  display: grid;
  gap: 9px;
  padding: 13px 15px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.rename-preview-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.rename-preview-head span { font-size: 13px; font-weight: 600; color: var(--text-2); }
.rename-preview-head small { font-size: 12px; color: var(--text-3); text-align: right; }

.rename-preview ul {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.rename-preview ul:empty { display: none; }

/* 样例名用等宽：位数是这里的重点，等宽才看得出长度差别 */
.rename-preview li {
  padding: 5px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-1);
}

.rename-preview-error {
  margin: 0;
  font-size: 13px;
  color: var(--bad);
}

/* ------------------------------------------------ 云端任务 */
/* 复选框 + 文案（终端头的「自动滚动」等还在用） */
.task-radio {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
}

.task-radio input { flex: none; margin: 0; }

/* 启动任务表单（tf-*）。
   版式：顶部「导入 / 导出」两张选择卡，下面每一节是「左节名 + 右字段」两栏，
   底部提交栏吸在视口底边——表单再长，「启动任务」和这次要做什么的摘要也一直看得见。
   只有两三个选项的一律做成分段按钮，点一下就选中，不用先展开下拉才知道有什么。
   全部用站内令牌（--line / --blue-wash / --well-shadow …），暗色主题自动跟随。 */
.tf-form { display: grid; }
/* 底栏要用负外边距贴住面板左右下三边，所以内边距在这里写死、和 --tf-pad 一致。
   用 .panel.tf-panel 提高优先级：手机端那条 `.panel { padding: 19px 17px }` 写在后面，同级会盖掉这里。 */
.panel.tf-panel { --tf-pad: 20px; padding: var(--tf-pad); }

/* 单选/复选在视觉上换成卡片、分段、文件行，但真正的 input 必须还在：
   键盘方向键切换、表单提交、读屏都靠它。只把它藏到看不见、点不到。 */
.tf-kind input,
.tf-seg input,
.tf-tabs input,
.tf-file input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.tf-label {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}
.tf-label em { font-style: normal; font-weight: 400; font-size: 12px; color: var(--text-3); }
.tf-hint { font-size: 12.5px; line-height: 1.55; color: var(--text-3); }
.tf-hint.form-hint-bad { color: var(--bad); }
.tf-mono { font-variant-numeric: tabular-nums; }

.tf-field { display: grid; gap: 7px; min-width: 0; align-content: start; }

/* 校验没过的字段：红框 + 淡红光晕，和底栏的报错文案同时出现 */
.tf-form [aria-invalid="true"],
.tf-form [aria-invalid="true"]:focus-visible {
  border-color: var(--bad);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--bad) 18%, transparent);
}
/* 出错字段底下那行格式提示也跟着变红，用户不用去底栏找原因 */
.tf-field:has([aria-invalid="true"]) .tf-hint { color: var(--bad); }

/* ---- 导入 / 导出 选择卡 ---- */
.tf-kind {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding-bottom: 22px;
}
.tf-kind-opt {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 14px 44px 14px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  cursor: pointer;
  transition: border-color var(--speed), background-color var(--speed), box-shadow var(--speed);
}
.tf-kind-opt:hover { border-color: var(--control); }
/* 右侧的单选圈：没选是空心环，选中是蓝底白芯 */
.tf-kind-opt::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 16px;
  width: 18px;
  height: 18px;
  margin-top: -9px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--control);
  transition: box-shadow var(--speed);
}
.tf-kind-opt:has(input:checked) {
  border-color: var(--blue);
  background: color-mix(in srgb, var(--blue-wash) 55%, var(--card));
  box-shadow: inset 0 0 0 1px var(--blue);
}
.tf-kind-opt:has(input:checked)::after { box-shadow: inset 0 0 0 5px var(--blue); background: #fff; }
.tf-kind-opt:has(input:focus-visible) { box-shadow: inset 0 0 0 1px var(--blue), var(--ring-focus); }
.tf-kind-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bg-soft);
  box-shadow: var(--well-shadow);
  color: var(--icon);
  transition: background-color var(--speed), color var(--speed);
}
.tf-kind-icon .icon { width: 19px; height: 19px; }
.tf-kind-opt:has(input:checked) .tf-kind-icon { background: var(--blue); box-shadow: none; color: #fff; }
.tf-kind-text { display: grid; gap: 2px; min-width: 0; }
.tf-kind-text b { font-size: 15px; font-weight: 600; color: var(--text-1); }
.tf-kind-text small { font-size: 12.5px; color: var(--text-3); }

/* ---- 节：左节名 + 右字段 ---- */
.tf-params { display: grid; }
.tf-params[hidden], .tf-section[hidden] { display: none; }
.tf-section {
  display: grid;
  grid-template-columns: 184px minmax(0, 1fr);
  gap: 12px 32px;
  padding: 22px 0;
  border-top: 1px solid var(--hairline);
}
.tf-section-head h4 { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.4; color: var(--text-1); }
.tf-section-head p { margin: 3px 0 0; font-size: 12.5px; line-height: 1.55; color: var(--text-3); }
.tf-section-body { display: grid; gap: 18px; min-width: 0; }

.tf-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 20px; }
.tf-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 18px; }
.tf-grid-place { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px 20px; align-items: start; }

/* ---- 分段按钮 ---- */
.tf-seg {
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  box-shadow: var(--well-shadow);
}
.tf-seg label { position: relative; flex: 1 1 0; min-width: 0; }
.tf-seg span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 7px;
  font-size: 13.5px;
  color: var(--text-2);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--speed), color var(--speed), box-shadow var(--speed);
}
.tf-seg span small { font-size: 12px; color: var(--text-3); font-weight: 400; }
.tf-seg label:hover span { color: var(--text-1); }
.tf-seg input:checked + span {
  background: var(--card);
  color: var(--text-1);
  font-weight: 600;
  box-shadow: var(--ring), 0 1px 2px rgba(16, 24, 40, 0.08), 0 1px 3px rgba(16, 24, 40, 0.05);
}
.tf-seg input:focus-visible + span { box-shadow: var(--ring-focus); }
html[data-theme="dark"] .tf-seg input:checked + span { background: var(--press); }

/* ---- 坐标：轴字母放进框内 ---- */
/* 必须是 block：.tf-field 的 grid 会让 legend 自己成一个网格项，再叠上 gap，标签比旁边的字段低一截 */
fieldset.tf-pos { display: block; min-width: 0; margin: 0; padding: 0; border: 0; }
/* legend 默认会骑在 fieldset 边框上、不参与网格；浮起来再占满一行，它就表现得和普通标签一样 */
.tf-pos > legend { float: left; width: 100%; margin: 0 0 7px; padding: 0; }
.tf-xyz { clear: both; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tf-axis { position: relative; display: block; min-width: 0; }
.tf-axis > span {
  position: absolute;
  inset: 0 auto 0 0;
  width: 30px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
  pointer-events: none;
}
.tf-axis.is-x > span { color: #c8433a; }
.tf-axis.is-y > span { color: #2c8c50; }
.tf-axis.is-z > span { color: var(--blue); }
html[data-theme="dark"] .tf-axis.is-x > span { color: #f0776d; }
html[data-theme="dark"] .tf-axis.is-y > span { color: #5fd08a; }
html[data-theme="dark"] .tf-axis.is-z > span { color: var(--blue-light); }
.tf-form .tf-axis input {
  padding-left: 30px;
  padding-right: 10px;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
}
.tf-axis input::-webkit-inner-spin-button,
.tf-axis input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.tf-axis input::placeholder { color: var(--text-3); opacity: 0.6; }

/* 带单位的数字框（% / 格） */
.tf-affix { position: relative; display: block; }
.tf-affix i {
  position: absolute;
  top: 0;
  right: 12px;
  bottom: 0;
  display: grid;
  place-items: center;
  font-style: normal;
  font-size: 13px;
  color: var(--text-3);
  pointer-events: none;
}
.tf-form .tf-affix input { padding-right: 34px; font-variant-numeric: tabular-nums; }

/* ---- 目标服务器 ---- */
.tf-server {
  display: grid;
  grid-template-columns: 168px minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
/* 山头等不要密码的模式：密码那格收掉，服务器号占满 */
.tf-server:has(> [data-passcode-field][hidden]) { grid-template-columns: 168px minmax(0, 1fr); }
.tf-field-code input { font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }

.tf-recent { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: -4px; }
.tf-recent-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-right: 4px;
  font-size: 12.5px;
  color: var(--text-3);
}
.tf-recent-label .icon { width: 14px; height: 14px; color: var(--icon); }
.tf-recent-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--card);
  font: inherit;
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
  cursor: pointer;
  transition: border-color var(--speed), background-color var(--speed), color var(--speed);
}
.tf-recent-item span { color: var(--text-3); }
.tf-recent-item:hover { border-color: var(--control); background: var(--bg-soft); }
.tf-recent-item.is-current { border-color: var(--blue); color: var(--blue-ink); background: var(--blue-wash); }
.tf-recent-item.is-current span { color: inherit; opacity: 0.75; }
.tf-recent-item:focus-visible { outline: none; box-shadow: var(--ring-focus); }

.tf-inline-field { display: inline-flex; align-items: center; gap: 10px; justify-self: start; font-size: 13px; color: var(--text-3); }
.tf-form .tf-inline-field select { width: auto; min-width: 200px; min-height: 32px; padding-top: 4px; padding-bottom: 4px; font-size: 13px; }

/* ---- 建筑来源 ---- */
.tf-source-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; }
.tf-tabs {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  box-shadow: var(--well-shadow);
}
.tf-tabs label { position: relative; }
.tf-tabs span {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 0 13px;
  border-radius: 7px;
  font-size: 13.5px;
  color: var(--text-2);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--speed), color var(--speed), box-shadow var(--speed);
}
.tf-tabs em { font-style: normal; font-size: 12px; font-variant-numeric: tabular-nums; color: var(--text-3); }
.tf-tabs label:hover span { color: var(--text-1); }
.tf-tabs input:checked + span {
  background: var(--card);
  color: var(--text-1);
  font-weight: 600;
  box-shadow: var(--ring), 0 1px 2px rgba(16, 24, 40, 0.08), 0 1px 3px rgba(16, 24, 40, 0.05);
}
.tf-tabs input:focus-visible + span { box-shadow: var(--ring-focus); }
html[data-theme="dark"] .tf-tabs input:checked + span { background: var(--press); }

.tf-search { position: relative; flex: 1 1 180px; max-width: 280px; }
.tf-search[hidden] { display: none; }
.tf-search .icon {
  position: absolute;
  top: 50%;
  left: 11px;
  width: 15px;
  height: 15px;
  margin-top: -7.5px;
  color: var(--icon);
  pointer-events: none;
}
.tf-form .tf-search input { min-height: 36px; padding-left: 34px; font-size: 13.5px; }

.tf-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue-ink);
}
.tf-link .icon { width: 15px; height: 15px; }
.tf-link:hover { text-decoration: underline; text-underline-offset: 3px; }
html[data-theme="dark"] .tf-link { color: var(--blue-light); }

/* 文件列表：一行一个建筑，名字、格式、大小、框选状态一眼看全。
   超过五六行就在框里滚，不把整张表单撑长。 */
/* 高度停在 5.5 行：最后半行露在外面，一看就知道还能往下滚 */
.tf-files {
  max-height: 368px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  scrollbar-width: thin;
  scrollbar-color: var(--control) transparent;
}
.tf-files[hidden] { display: none; }
.tf-file {
  position: relative;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 14px;
  padding: 11px 14px;
  cursor: pointer;
  transition: background-color var(--speed);
}
.tf-file + .tf-file { box-shadow: inset 0 1px 0 var(--hairline); }
.tf-file:hover { background: var(--bg-soft); }
.tf-file[hidden] { display: none; }
.tf-file:has(input:checked) { background: color-mix(in srgb, var(--blue-wash) 70%, var(--card)); }
.tf-file:has(input:focus-visible) { box-shadow: inset 0 0 0 2px var(--blue); }
.tf-file-ext {
  justify-self: stretch;
  max-width: 100%;
  overflow: hidden;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--bg-soft);
  box-shadow: var(--well-shadow);
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  text-align: center;
  color: var(--text-2);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tf-file:has(input:checked) .tf-file-ext { background: var(--card); color: var(--blue-ink); }
html[data-theme="dark"] .tf-file:has(input:checked) .tf-file-ext { color: var(--blue-light); }
.tf-file-main { display: grid; gap: 3px; min-width: 0; }
.tf-file-main b {
  overflow: hidden;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-1);
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* 扩展名后缀只在手机上显示（那里放不下左边的格式标签） */
.tf-file-suffix { display: none; font-weight: 400; color: var(--text-3); }
.tf-file-main small {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  font-size: 12px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}
.tf-file-main small i {
  width: 3px;
  height: 3px;
  margin: 0 7px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
}
.tf-file-main .is-ok { color: var(--ok); }
.tf-file-main .is-warn { color: var(--warn); font-weight: 600; }
.tf-file-tick {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--control);
  color: transparent;
  transition: background-color var(--speed), box-shadow var(--speed), color var(--speed);
}
.tf-file-tick .icon { width: 12px; height: 12px; stroke-width: 2.6; }
.tf-file:has(input:checked) .tf-file-tick { background: var(--blue); box-shadow: none; color: #fff; }

.tf-files-empty { display: flex; align-items: center; gap: 14px; padding: 18px 16px; }
.tf-files-empty > .icon { flex: none; width: 22px; height: 22px; color: var(--icon); }
.tf-files-empty > div { display: grid; gap: 2px; min-width: 0; }
.tf-files-empty b { font-size: 14px; font-weight: 600; color: var(--text-1); }
.tf-files-empty small { font-size: 12.5px; color: var(--text-3); }
.tf-files-empty .chip-button { flex: none; margin-left: auto; }
.tf-files-nomatch { margin: 0; padding: 18px 16px; text-align: center; font-size: 13px; color: var(--text-3); }
.tf-files-nomatch[hidden] { display: none; }

/* 源区域：建筑在 mcworld 存档里占哪一块。
   两种形态二选一——已框选的报个喜（绿，一行），没框选的是必须处理的事（琥珀，整块）。 */
.tf-bounds[hidden], .tf-bounds-read[hidden], .tf-bounds-ask[hidden] { display: none; }
.tf-bounds-read {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: var(--ok-wash);
  font-size: 13px;
  color: var(--text-2);
}
.tf-bounds-read > .icon { width: 16px; height: 16px; color: var(--ok); stroke-width: 2.2; }
.tf-bounds-read > span { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.tf-bounds-read b { font-weight: 600; color: var(--ok); }
.tf-bounds-read .tf-mono { font-size: 12.5px; color: var(--text-1); }
.tf-bounds-read small { margin-left: auto; font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.tf-bounds-ask {
  display: grid;
  gap: 16px;
  padding: 16px;
  border: 1px solid color-mix(in srgb, var(--warn) 28%, transparent);
  border-radius: 12px;
  background: var(--warn-wash);
}
.tf-bounds-why { display: flex; gap: 10px; }
.tf-bounds-why > .icon { flex: none; width: 18px; height: 18px; margin-top: 1px; color: var(--warn); }
.tf-bounds-why p { margin: 0; font-size: 13px; line-height: 1.65; color: var(--text-2); }
.tf-bounds-why b { display: block; margin-bottom: 2px; font-size: 14px; font-weight: 600; color: var(--text-1); }
.tf-bounds-why em { font-style: normal; font-weight: 600; color: var(--warn); }

/* ---- 建造选项 ---- */
.tf-checks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.tf-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--card);
  cursor: pointer;
  transition: border-color var(--speed), background-color var(--speed);
}
.tf-check:hover { border-color: var(--control); }
.tf-check:has(input:checked) {
  border-color: color-mix(in srgb, var(--blue) 45%, var(--line));
  background: color-mix(in srgb, var(--blue-wash) 55%, var(--card));
}
.tf-check input { flex: none; width: 16px; height: 16px; margin: 2px 0 0; accent-color: var(--blue); cursor: pointer; }
.tf-check > span { display: grid; gap: 2px; min-width: 0; }
.tf-check b { font-size: 13.5px; font-weight: 600; color: var(--text-1); }
.tf-check small { font-size: 12px; line-height: 1.5; color: var(--text-3); }

.tf-advanced { border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.tf-advanced > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-2);
  list-style: none;
  cursor: pointer;
  user-select: none;
  transition: background-color var(--speed), color var(--speed);
}
.tf-advanced > summary::-webkit-details-marker { display: none; }
.tf-advanced > summary:hover { background: var(--bg-soft); color: var(--text-1); }
.tf-advanced > summary .icon { width: 16px; height: 16px; color: var(--icon); }
.tf-advanced > summary .icon:last-child { width: 14px; height: 14px; margin-left: auto; transition: transform 0.2s var(--ease); }
.tf-advanced[open] > summary { border-radius: 12px 12px 0 0; }
.tf-advanced[open] > summary .icon:last-child { transform: rotate(90deg); }
.tf-advanced-body { display: grid; gap: 18px; padding: 16px 14px; border-top: 1px solid var(--hairline); }

/* ---- 底部提交栏：吸在视口底边 ---- */
.tf-foot-sentinel { height: 1px; margin-top: -1px; }
.tf-foot {
  position: sticky;
  bottom: 0;
  z-index: 6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 calc(var(--tf-pad, 20px) * -1) calc(var(--tf-pad, 20px) * -1);
  padding: 14px var(--tf-pad, 20px);
  border-top: 1px solid var(--line);
  border-radius: 0 0 var(--r-lg) var(--r-lg);
  background: var(--card);
  transition: box-shadow 0.2s var(--ease), border-radius 0.2s var(--ease);
}
/* 粘住时（表单底边还在视口下方）：向上一道柔影，表明下面还有内容 */
.tf-foot.is-stuck { border-radius: 0; box-shadow: 0 -8px 20px -12px rgba(16, 24, 40, 0.22); }
html[data-theme="dark"] .tf-foot.is-stuck { box-shadow: 0 -8px 20px -10px rgba(0, 0, 0, 0.7); }
.tf-summary { display: grid; gap: 2px; min-width: 0; }
.tf-summary-main {
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tf-summary-main.is-muted { font-weight: 400; color: var(--text-3); }
.tf-summary-sub { overflow: hidden; font-size: 12.5px; color: var(--text-3); text-overflow: ellipsis; white-space: nowrap; }
.tf-summary-sub.form-hint-bad { color: var(--bad); font-weight: 600; white-space: normal; }
.tf-foot .primary-button { flex: none; min-width: 148px; }

/* 折叠区默认 overflow:hidden（收起 / 展开时内容不能漏出来），可 hidden 会把它变成滚动容器，
   底栏的 sticky 就只认它、不认视口，永远粘不住。换成 overflow:clip：照样裁切，但不算滚动容器，
   sticky 能一路穿透到视口。（原来用动画延时切 visible，实测时灵时不灵，已弃用） */
/* 右下角的客服球会压住吸底栏右端的「启动任务」，吸底期间把它抬到底栏上方 */
.support-widget { transition: bottom 0.25s var(--ease); }
body:has(.tf-foot.is-stuck) .support-widget { bottom: 104px; }

.task-new > .collapse-inner { overflow: clip; }

@media (max-width: 1100px) {
  .tf-section { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .tf-section-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; }
  .tf-section-head p { margin: 0; }
}
@media (max-width: 760px) {
  .tf-server,
  .tf-server:has(> [data-passcode-field][hidden]) { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
  .tf-field-pass { grid-column: 1 / -1; }
  .tf-grid-2, .tf-grid-place { grid-template-columns: minmax(0, 1fr); }
  .tf-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tf-checks { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .panel.tf-panel { --tf-pad: 16px; }
  .tf-kind { gap: 8px; padding-bottom: 18px; }
  .tf-kind-opt { gap: 10px; padding: 12px 34px 12px 12px; }
  .tf-kind-opt::after { right: 12px; width: 16px; height: 16px; margin-top: -8px; }
  .tf-kind-opt:has(input:checked)::after { box-shadow: inset 0 0 0 4.5px var(--blue); }
  .tf-kind-icon { width: 32px; height: 32px; border-radius: 9px; }
  .tf-kind-icon .icon { width: 17px; height: 17px; }
  .tf-kind-text b { font-size: 14px; }
  .tf-kind-text small { display: none; }
  .tf-section { padding: 18px 0; }
  .tf-server,
  .tf-server:has(> [data-passcode-field][hidden]) { grid-template-columns: minmax(0, 1fr); }
  .tf-grid-3 { grid-template-columns: minmax(0, 1fr); }
  .tf-search { max-width: none; flex-basis: 100%; order: 3; }
  .tf-file { grid-template-columns: minmax(0, 1fr) 20px; gap: 10px; padding: 11px 12px; }
  .tf-file-ext { display: none; }
  .tf-file-suffix { display: inline; }
  body:has(.tf-foot.is-stuck) .support-widget { bottom: 90px; }
  .tf-seg span { padding: 0 8px; }
  .tf-foot { gap: 12px; padding-top: 12px; padding-bottom: 12px; }
  .tf-foot .primary-button { min-width: 0; padding: 0 18px; }
  /* 手机上底栏只留一行摘要；那行说明只在出错、提交中时出现 */
  .tf-summary-sub:not(.form-hint-bad):not(.is-live) { display: none; }
  .tf-inline-field { display: grid; gap: 7px; justify-self: stretch; }
  .tf-form .tf-inline-field select { width: 100%; min-width: 0; min-height: 38px; }
}
@media (prefers-reduced-motion: reduce) {
  .tf-kind-opt, .tf-kind-icon, .tf-seg span, .tf-tabs span, .tf-file, .tf-file-tick, .tf-check, .tf-foot,
  .tf-advanced > summary .icon:last-child { transition: none; }
}

/* 执行实例终端：任务详情页里直接看引擎在说什么，不必进面板 */
.task-console-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 16px 0 0;
  padding: 9px 14px;
  border-radius: var(--r-md) var(--r-md) 0 0;
  background: #111c31;
  font-size: 13px;
  color: #cbd5e1;
}

.task-console-head strong {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
}

.task-console-head .icon { width: 15px; height: 15px; color: #7f92b0; }

.task-console-tools {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* 终端里的颜色是有含义的，给一行图例。不写图例的话，
   用户看到一行黄字只会当成"某种装饰"，而它其实是"该你操作了"。 */
.console-legend {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #8fa1bd;
}

.console-legend i {
  width: 7px;
  height: 7px;
  margin-left: 6px;
  border-radius: 50%;
}

.console-legend i:first-child { margin-left: 0; }
.console-legend i.warn { background: #fcd34d; }
.console-legend i.error { background: #fca5a5; }

.task-console-head .task-radio { color: #a8b6cc; font-size: 13px; }

.task-console-head .chip-button {
  padding: 4px 10px;
  border-color: #2b3a55;
  background: #1a2740;
  color: #cbd5e1;
  font-size: 13px;
}

.task-console-head .chip-button:hover { background: #223252; border-color: #3a4d70; }

.task-console {
  margin: 0;
  padding: 12px 14px 14px;
  max-height: 420px;
  overflow: auto;
  border-radius: 0 0 var(--r-md) var(--r-md);
  background: #0f172a;
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.7;
  /* 终端内容不折行会横向撑破卡片，长命令行折下来更好读 */
  white-space: pre-wrap;
  word-break: break-word;
  /* 滚动条也要跟着暗下来，否则暗底上挂一条亮灰滚动条很跳 */
  scrollbar-color: #33415c #0f172a;
  scrollbar-width: thin;
}

/* 全局 code 是 0.86em，套在 12.5px 的终端上只剩 10.75px——低于中文可读下限。
   终端是排查问题时要逐字读的地方，字号必须回到容器本身的大小。 */
.task-console code {
  font-size: inherit;
  font-family: inherit;
}

/* 每一行左侧留一条竖标，颜色即级别。只靠字色区分的话，
   一屏几十行里那条关键的错误很容易被扫过去。 */
.task-console .console-line {
  display: block;
  padding: 1px 0 1px 10px;
  border-left: 2px solid transparent;
}

.task-console .console-line.error {
  color: #fca5a5;
  border-left-color: #ef4444;
  background: rgba(239, 68, 68, 0.08);
}

.task-console .console-line.warn {
  color: #fcd34d;
  border-left-color: #f59e0b;
  background: rgba(245, 158, 11, 0.07);
}

.task-console .console-line.muted { color: #64748b; }

/* 新到的行轻微淡入。终端是逐行冒出来的，硬切会显得跳。 */
.task-console .console-line { animation: fade-in 0.2s var(--ease-out) both; }

.task-list { display: grid; gap: 10px; }

.task-card {
  display: grid;
  gap: 9px;
  padding: 14px 17px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.task-card-head,
.task-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.task-card-title { display: flex; align-items: center; gap: 9px; min-width: 0; }
.task-card-title strong { font-size: 14px; font-weight: 600; }
.task-card-foot small { font-size: 13px; color: var(--text-2); }
.task-card-ops { display: flex; align-items: center; gap: 8px; }

.task-kind {
  padding: 2px 9px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  flex: none;
}

.task-kind.import { color: var(--blue-deep); background: var(--blue-tint); }
.task-kind.export { color: var(--warn-ink); background: var(--warn-wash); }

.task-percent {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-2);
  font-variant-numeric: tabular-nums;
}

.task-progress {
  height: 6px;
  border-radius: 999px;
  background: var(--line-soft);
  overflow: hidden;
}

.task-progress i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
  transition: width 0.6s var(--ease);
}

.task-state {
  padding: 2.5px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.task-state.waiting { color: var(--warn-ink); background: var(--warn-wash); }
.task-state.running { color: var(--blue-deep); background: var(--blue-tint); }
.task-state.done { color: var(--ok-ink); background: var(--ok-wash); }
.task-state.bad { color: var(--bad); background: var(--bad-wash); }
.task-state.muted { color: var(--text-3); background: var(--bg-soft); }

.task-state-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.task-state-row small { font-size: 13px; color: var(--text-2); }

/* 过程记录：一行一条，时间与阶段对齐，出问题时能整段复制给我们 */
.task-events {
  display: grid;
  gap: 6px;
  max-height: 380px;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}

.task-event {
  display: grid;
  grid-template-columns: 132px 76px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: baseline;
  padding: 5px 0;
  border-bottom: 1px solid var(--line-soft);
}

.task-event:last-child { border-bottom: none; }
.task-event-time { font-family: var(--mono); font-size: 13px; color: var(--text-3); }
.task-event b { font-weight: 600; color: var(--text-2); }
.task-event em { font-style: normal; font-family: var(--mono); color: var(--text-3); }
.task-event.warn b { color: var(--warn); }
.task-event.error b, .task-event.error span { color: var(--bad); }

.task-history td small { display: block; margin-top: 2px; font-size: 13px; color: var(--text-3); }

/* 执行机监控（管理后台） */
.runner-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.runner-card {
  display: grid;
  gap: 9px;
  padding: 15px 17px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.runner-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.runner-card-head strong { font-size: 14px; font-weight: 700; }
.runner-metric { display: grid; gap: 5px; }

.runner-metric-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-2);
}

.runner-metric-row b {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.runner-bar {
  height: 5px;
  border-radius: 999px;
  background: var(--line-soft);
  overflow: hidden;
}

.runner-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
}

.runner-bar.hot i { background: var(--warn); }
.runner-bar.critical i { background: var(--bad); }

/* 快捷入口右上角的待办角标 */
.quick-grid a { position: relative; }

.quick-badge {
  position: absolute;
  top: 12px;
  right: 14px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  color: #fff;
  background: var(--warn);
}

/* 投稿审核：分类输入 + 通过按钮同行 */
.review-form {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 6px;
}

.review-category {
  width: 130px;
  padding: 6px 10px;
  font-size: 13px;
}

/* 公用建筑库列表 */
.library-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 10px;
}

.library-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 15px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.library-item-main { display: grid; gap: 3px; min-width: 0; }
.library-item-main strong { font-size: 14px; font-weight: 600; }
.library-item-main small { font-size: 12px; color: var(--text-3); }

.library-uploader {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: none;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--blue-deep);
  background: var(--blue-tint);
}

.library-uploader .icon { width: 13px; height: 13px; }

/* 文件配额进度条 */
.quota-bar { display: grid; gap: 7px; margin-bottom: 14px; }

.quota-bar-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-2);
}

.quota-bar-head b {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.quota-track {
  height: 8px;
  border-radius: 999px;
  background: var(--blue-wash);
  overflow: hidden;
}

.quota-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
  transition: width 0.6s var(--ease);
}

.quota-track.hot i { background: var(--warn); }
.quota-track.critical i { background: var(--bad); }

/* 文件上传表单 */
.file-upload-form {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.file-upload-form input[type="file"] { flex: 1 1 260px; }

/* 文件选择框：浏览器原生的灰按钮换成和次按钮一样的样子 */
input[type="file"] { color: var(--text-2); font-size: 14px; }

input[type="file"]::file-selector-button {
  margin-right: 12px;
  padding: 0 14px;
  height: 32px;
  border: 1px solid var(--control);
  border-radius: var(--r-sm);
  background: var(--card);
  color: var(--text-1);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--speed);
}

input[type="file"]::file-selector-button:hover { background: var(--bg-soft); }
.file-upload-form .form-hint { flex: 1 1 100%; order: 3; margin: 0; }

/* 官方面板入口（Token 页）：左边三步、右边大按钮，一看就懂 */
.panel-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
}

.panel-entry-steps { display: grid; gap: 12px; }

.panel-entry-points {
  display: grid;
  gap: 11px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.panel-entry-points li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  color: var(--text-1);
}

.panel-entry-points .icon { width: 17px; height: 17px; flex: none; color: var(--ok); }

.panel-entry-step {
  display: flex;
  align-items: center;
  gap: 12px;
}

.panel-entry-step .step-num {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  flex: none;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: var(--blue);
}

.panel-entry-step b { font-size: 14px; font-weight: 600; display: block; }
.panel-entry-step small { font-size: 13px; color: var(--text-3); }

.panel-entry-btn {
  display: grid;
  justify-items: center;
  gap: 3px;
  flex: none;
  padding: 20px 34px;
  border-radius: var(--r-lg);
  color: #fff;
  background: var(--blue);
  transition: background var(--speed);
}

.panel-entry-btn:hover { background: var(--blue-hover); }
.panel-entry-btn .icon { width: 26px; height: 26px; }
.panel-entry-btn b { font-size: 16px; font-weight: 700; }
.panel-entry-btn small { font-size: 12px; color: rgba(255, 255, 255, 0.85); }

/* 后台开关行（导入维护等） */
.switch-field {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-1);
  cursor: pointer;
}

.switch-field input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex: none;
  accent-color: var(--blue);
  cursor: pointer;
}

/* 服务器绑定卡片 */
.binding-list { display: grid; gap: 10px; }

.binding-card {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px 18px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}

.binding-card:hover { border-color: var(--line); background: var(--card); }

.binding-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: none;
  border-radius: 12px;
  color: var(--blue-deep);
  background: var(--blue-tint);
}

.binding-icon .icon { width: 20px; height: 20px; }

.binding-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 2px;
}

.binding-topline {
  display: flex;
  align-items: center;
  gap: 8px;
}

.binding-kind {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-3);
}

.binding-topline small { font-size: 13px; color: var(--text-3); }

.binding-code {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.binding-main > small { font-size: 12px; color: var(--text-3); }

.binding-side {
  display: grid;
  justify-items: end;
  gap: 7px;
}

/* 卡槽页加了「解绑券」后是四张卡；沿用 overview-grid 的三列会拆成 3+1 落单 */
.slot-stats {
  grid-template-columns: repeat(4, 1fr);
  margin-bottom: 16px;
}

/* 代理页是四张等宽概览卡；沿用 overview-grid 的三列会拆成 3+1 落单 */
.agent-stats {
  grid-template-columns: repeat(4, 1fr);
  margin-bottom: 16px;
}

.binding-hint { font-size: 13px; color: var(--text-3); }

.warn-note { color: var(--warn); }
.warn-note b { font-weight: 700; }

/* 额度重置倒计时 */
.reset-countdown {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 4px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(4px);
}

.reset-countdown .reset-label { color: rgba(255, 255, 255, 0.78); }
.reset-countdown b { font-weight: 700; font-variant-numeric: tabular-nums; }

.method-divider {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 22px 0 13px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.method-divider strong { font-size: 15px; font-weight: 700; margin-right: 10px; }
.method-divider span,
.method-divider p { font-size: 13px; color: var(--text-3); }

.login-method-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 11px;
}

.login-method-row button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 17px;
  text-align: left;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}

.login-method-row button:hover {
  border-color: #c8d8f8;
  background: var(--blue-wash);
}

.login-method-row .icon { color: var(--text-3); }
.login-method-row button:hover .icon { color: var(--blue); }
.login-method-row span { display: grid; gap: 1px; }
.login-method-row b { font-size: 14px; font-weight: 600; }
.login-method-row small { font-size: 12px; color: var(--text-3); }

.login-method-row em {
  position: absolute;
  top: -8px;
  right: 13px;
  font-style: normal;
  padding: 1px 9px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--blue-deep);
  background: var(--blue-tint);
  border: 1px solid #c8d8f8;
}

.guest-flow-note {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  padding: 12px 15px;
  font-size: 13px;
  border-radius: var(--r-md);
  background: var(--warn-wash);
  color: var(--warn-ink);
}

.guest-flow-note b { color: var(--warn); margin-right: 4px; }
.guest-flow-note i { color: #c9a15f; font-style: normal; }

/* 页面切换进度条：固定在顶部，先于新页面出现，给出「已经在走了」的反馈 */
.nav-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 300;
  height: 2.5px;
  width: 0;
  border-radius: 0 2px 2px 0;
  background: var(--blue);
  opacity: 0;
  transition: width 0.18s ease-out, opacity 0.2s;
}

.nav-progress.active { opacity: 1; }

/* 同时把光标变成等待态，双重反馈 */
body.nav-busy { cursor: progress; }

/* ---- 在线支付 ---- */
/* 每个商品只有一个「购买」，付款方式在弹窗里选；金额不放按钮上，留到确认页 */
.buy-row {
  display: grid;
  margin-top: 4px;
}

.buy-row .buy-button { width: 100%; }

/* 确认弹窗里的付款方式：两块并排，选中的描蓝边 */
.pay-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 14px 24px 0;
}

.pay-method {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  border-radius: var(--r-md);
  border: 1px solid var(--control);
  background: var(--card);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}

.pay-method svg { width: 22px; height: 22px; border-radius: 6px; flex: none; }
.pay-method.wxpay svg { background: #07a35a; }
.pay-method.alipay svg { background: #1677ff; }
.pay-method:hover { background: var(--bg-soft); }
.pay-method[aria-checked="true"] { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); background: var(--blue-wash); }

.pay-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  color: #fff;
  transition: filter var(--speed), transform var(--speed);
}

.pay-btn:hover { filter: brightness(1.06); }
.pay-btn:active { transform: translateY(1px); }

.pay-btn.wx { background: #07a35a; }
.pay-btn.ali { background: #1677ff; }

.test-pay { max-width: 420px; margin-bottom: 10px; }

/* 订单状态 */
.order-state {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
}

.order-state.pending { color: var(--warn); background: var(--warn-wash); }
.order-state.paid { color: var(--ok); background: var(--ok-wash); }
.order-state.failed { color: var(--bad); background: var(--bad-wash); }

/* 支付确认页 */
.pay-confirm {
  display: grid;
  place-items: start center;
  padding-top: 8px;
}

.pay-confirm-card {
  width: min(440px, 100%);
  border-radius: 16px;
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow-pop);
}

.pay-confirm-head {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 28px 24px 24px;
  color: #fff;
  text-align: center;
}

.pay-confirm-head strong { font-size: 16px; font-weight: 700; }
.pay-confirm-head small { font-size: 13px; color: rgba(255, 255, 255, 0.85); }

/* 品牌配色只能写在样式表里：CSP 禁止内联 style 属性 */
.pay-confirm-head.wxpay,
.pay-submit.wxpay,
.pay-redirect.wxpay { background: #07a35a; }

.pay-confirm-head.alipay,
.pay-submit.alipay,
.pay-redirect.alipay { background: #1677ff; }

.pay-brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 2px;
}

.pay-brand-mark svg { width: 100%; height: 100%; }
.pay-brand-mark.large { width: 60px; height: 60px; }

.pay-confirm-amount {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid var(--line-soft);
}

.pay-confirm-amount span { font-size: 13px; color: var(--text-3); }

.pay-confirm-amount b {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.pay-confirm-detail {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 20px 24px;
}

.pay-confirm-detail > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  font-size: 14px;
}

.pay-confirm-detail dt { color: var(--text-3); flex: none; }
.pay-confirm-detail dd { margin: 0; color: var(--text-1); font-weight: 500; text-align: right; }

.pay-confirm-actions { padding: 0 24px; }

.pay-submit {
  width: 100%;
  padding: 13px 18px;
  border: 0;
  border-radius: var(--r-md);
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  transition: filter var(--speed);
}

.pay-submit:hover { filter: brightness(1.06); }

.pay-confirm-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 16px 24px 4px;
  font-size: 13px;
}

.pay-confirm-note {
  padding: 4px 24px 22px;
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
  color: var(--text-3);
}

/* 后台回调地址提示 */
.pay-callback-hint {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: var(--r-md);
  font-size: 13px;
  background: var(--bg-soft);
}

.pay-callback-hint > div {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.pay-callback-hint span { color: var(--text-3); flex: none; }
.pay-callback-hint code { color: var(--text-1); overflow-wrap: anywhere; }
.pay-callback-hint p { color: var(--text-2); line-height: 1.7; }

.extra-products {
  display: grid;
  gap: 10px;
}

.extra-product {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 17px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  box-shadow: inset 0 0 0 1px var(--line-soft);
}

.extra-product-copy { display: grid; gap: 2px; min-width: 0; }
.extra-product-copy strong { font-size: 15px; font-weight: 600; }
.extra-product-copy small { font-size: 13px; color: var(--text-3); }

.extra-product-buy {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.extra-product-buy > b {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-1);
}

/* 代理提卡：标价划掉 + 折后价，两者并排让差价一眼可见 */
.agent-price {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  white-space: nowrap;
}

.agent-price-was {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-3);
  text-decoration-thickness: 1px;
}

/* 支付跳转中转页 */
.pay-redirect {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
}

.pay-redirect .pay-brand-mark { margin: 0 auto 4px; }

.pay-redirect-card {
  display: grid;
  gap: 10px;
  justify-items: center;
  text-align: center;
  max-width: 420px;
  padding: 34px 30px;
  border-radius: 16px;
  background: var(--card);
  box-shadow: var(--shadow-pop);
}

.pay-redirect-card strong { font-size: 18px; font-weight: 700; }
.pay-redirect-card p { font-size: 14px; color: var(--text-2); }
.pay-redirect-card small { font-size: 13px; color: var(--text-3); }

/* ---- 游客注册向导 ---- */
.wizard-steps {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.wizard-step {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
  font-size: 13px;
}

/* 后续步骤各自吸收一段连接线，靠连接线伸缩把三步均匀撑开，
   文字本身保持自然宽度，不会被连接线挤偏。 */
.wizard-step + .wizard-step {
  flex: 1;
  min-width: 0;
}

.wizard-step + .wizard-step::before {
  content: "";
  flex: 1;
  min-width: 24px;
  height: 1px;
  background: var(--line);
}

.wizard-dot {
  display: grid;
  place-items: center;
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text-3);
  background: var(--bg-soft);
  box-shadow: inset 0 0 0 1px var(--line);
}

.wizard-dot .icon { width: 13px; height: 13px; }

.wizard-label { color: var(--text-3); white-space: nowrap; }

.wizard-step.current .wizard-dot {
  color: #fff;
  background: var(--blue);
  box-shadow: none;
}

.wizard-step.current .wizard-label { color: var(--text-1); font-weight: 600; }

.wizard-step.done .wizard-dot {
  color: #fff;
  background: var(--ok);
  box-shadow: none;
}

.wizard-step.done .wizard-label { color: var(--text-2); }

/* 短信信息卡：号码与内容各占一行，便于分别复制 */
.sms-card {
  display: grid;
  gap: 1px;
  border-radius: var(--r-md);
  background: var(--line-soft);
  overflow: hidden;
}

.sms-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 15px;
  background: var(--card);
}

.sms-row.muted { color: var(--text-3); }

.sms-key {
  flex: none;
  width: 66px;
  font-size: 13px;
  color: var(--text-3);
}

.sms-value {
  flex: 1;
  min-width: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
  overflow-wrap: anywhere;
}

.sms-row.muted .sms-value { font-size: 15px; font-weight: 600; color: var(--text-2); }

.sms-value.sms-code { color: var(--blue-deep); }

.sms-origin {
  display: grid;
  gap: 3px;
  margin-top: 12px;
  padding: 11px 14px;
  border-radius: var(--r-sm);
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-2);
  background: var(--bg-soft);
}

.sms-origin span { font-size: 13px; color: var(--text-3); }

.guest-guide {
  margin: 16px 0 0;
  padding-left: 20px;
  display: grid;
  gap: 6px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-2);
}

.guest-guide b { color: var(--text-1); font-weight: 600; }

.wizard-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.wizard-skip {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  text-align: center;
}

.wizard-skip button {
  border: 0;
  background: none;
  cursor: pointer;
  font: inherit;
}

/* 弹窗内的行内提示条 */
.notice-inline {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 16px;
  padding: 11px 14px;
  border-radius: var(--r-md);
  font-size: 13px;
  background: var(--ok-wash);
  color: var(--ok-ink);
}

.notice-inline .icon { width: 16px; height: 16px; flex: none; }

.notice-inline.warn { background: var(--warn-wash); color: var(--warn-ink); }

html[data-theme="dark"] .notice-inline.ok { color: #4ade9f; }
html[data-theme="dark"] .notice-inline.warn { color: #e0a53a; }

/* 卡槽 */
.slot-summary {
  display: grid;
  grid-template-columns: minmax(200px, 270px) 1fr;
  gap: 14px;
  align-items: stretch;
}

/* 兑换 */
.redeem-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 400px);
  align-items: center;
  gap: 26px;
}

.redeem-copy h2 { font-size: 18px; font-weight: 700; }
.redeem-copy p { margin-top: 6px; font-size: 13px; color: var(--text-2); }

.redeem-form { display: flex; gap: 9px; }

.redeem-form input {
  flex: 1;
  font-family: var(--mono);
  letter-spacing: 0.05em;
}

/* 售后群 */
.support-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 26px;
  margin-top: 14px;
}

.support-copy h2 { font-size: 18px; font-weight: 700; }
.support-copy p { margin-top: 6px; font-size: 13px; color: var(--text-2); }

.support-join {
  display: flex;
  align-items: center;
  gap: 10px;
}

.support-code {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--bg-soft);
}

.support-label { font-size: 12px; color: var(--text-3); }

.support-number {
  font-family: var(--mono);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

/* 方案（控制台） */
.dashboard-plans { margin: 16px 0; }

/* 代理等级正好 4 档：一排 4 张，窄屏 2 × 2，不留孤卡 */
.plans-grid.agent-tiers { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1180px) { .plans-grid.agent-tiers { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .plans-grid.agent-tiers { grid-template-columns: minmax(0, 1fr); } }

.plan-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.plan-flag {
  padding: 2px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--ok);
  background: var(--ok-wash);
  white-space: nowrap;
}

.plan-flag.alt { color: var(--blue-deep); background: var(--blue-tint); }

.plan-description {
  font-size: 13px;
  color: var(--text-2);
  min-height: 3em;
}

.plan-includes {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.plan-includes li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  font-size: 13px;
  color: var(--text-2);
  border-radius: var(--r-sm);
  background: var(--bg-soft);
}

.plan-includes strong {
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
  font-weight: 700;
}

.plan-cta {
  margin-top: 6px;
  text-align: center;
  padding: 8px 14px;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 600;
  color: var(--blue);
  border: 1px solid #c8d8f8;
}

.plan-cta.muted { color: var(--text-3); border-color: var(--line); }

.pricing-note {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  font-size: 13px;
  color: var(--text-2);
}

.pricing-note b {
  color: var(--text-1);
  margin-left: 6px;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

/* Token */
.token-table { display: grid; gap: 8px; }

.token-table-head,
.token-row {
  display: grid;
  grid-template-columns: 1.15fr 1fr 0.9fr 1fr;
  gap: 14px;
  align-items: center;
}

.token-table-head {
  padding: 2px 17px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-3);
}

.token-row {
  padding: 13px 17px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  font-size: 13px;
  color: var(--text-2);
  transition: border-color var(--speed), background var(--speed);
}

.token-row:hover { border-color: var(--line); background: var(--card); }

.token-row small {
  display: block;
  font-size: 13px;
  color: var(--text-3);
}

.token-name strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}

.token-name code { font-size: 12px; color: var(--text-3); }

.token-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex-wrap: wrap;
}

/* 一次性 Token 展示层 */
.issued-token-layer {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fade-in 0.2s var(--ease);
}

.issued-token-card {
  width: min(580px, 100%);
  padding: 26px 28px;
  background: var(--card);
  border-radius: 16px;
  box-shadow: var(--shadow-pop);
  animation: pop-in 0.25s var(--ease);
}

.issued-token {
  display: flex;
  gap: 9px;
  margin-top: 16px;
}

.issued-token input {
  flex: 1;
  font-family: var(--mono);
  font-size: 13px;
}

.security-hint {
  margin-top: 13px;
  font-size: 13px;
  color: var(--warn);
}

/* 客户端 */
.client-list { display: grid; gap: 11px; }

.client-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px 22px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}

.client-card:hover { border-color: var(--line); background: var(--card); }

.client-badge {
  flex: none;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--blue-deep);
  background: var(--blue-tint);
}

.client-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 3px;
}

.client-topline {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--text-3);
}

.client-topline b {
  color: var(--blue);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.client-main h3 {
  font-size: 16px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.client-main p { font-size: 13px; color: var(--text-2); }
.client-main small { font-size: 12px; color: var(--text-3); }

/* 个人中心 */
.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 26px;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.profile-copy {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 2px;
}

.profile-copy h3 { font-size: 20px; font-weight: 700; }

.profile-copy p {
  font-size: 14px;
  color: var(--text-2);
  overflow-wrap: anywhere;
}

.quota-panel {
  display: grid;
  gap: 0;
  align-content: center;
}

.quota-panel > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 4px;
  font-size: 14px;
  color: var(--text-2);
}

.quota-panel > div:not(:last-child) { border-bottom: 1px solid var(--line-soft); }

.quota-panel strong {
  color: var(--text-1);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

/* ------------------------------------------------ 10 管理分区 */
.stats-row { display: flex; gap: 10px; }

.stats-row > div {
  display: grid;
  justify-items: center;
  gap: 0;
  min-width: 84px;
  padding: 11px 16px;
  background: var(--card);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-card);
}

.stats-row strong {
  font-size: 20px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}

.stats-row span { font-size: 13px; color: var(--text-3); }

.user-cell { min-width: 180px; }

.user-config-form {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: flex-end;
}

.user-config-form label {
  display: grid;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-3);
}

/* 表格里的操作列：按钮并排，不换行挤成两截 */
.row-ops { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* 分页条 */
.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-top: 14px;
  font-size: 13px;
  color: var(--text-3);
}

/* 停用理由是一句话，92px 的格子装不下，让它独占一行 */
.user-config-form .user-config-wide { flex: 1 1 100%; }
.user-config-form .user-config-wide input { width: 100%; }

.user-config-form input,
.user-config-form select {
  width: 92px;
  padding: 6px 9px;
  font-size: 13px;
}

.user-config-form select { width: 104px; }

.card-create-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(168px, 1fr));
  gap: 12px;
  align-items: end;
}

.copy-field {
  display: flex;
  gap: 7px;
  align-items: center;
  min-width: 240px;
}

.copy-field input {
  flex: 1;
  padding: 6px 10px;
  font-family: var(--mono);
  font-size: 12px;
}

.legacy-code {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-3);
}

.card-kind {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
}

.kind-credits { color: var(--blue); background: var(--blue-wash); }
.kind-subscription { color: var(--kind-sub-ink); background: var(--kind-sub-wash); }
.kind-slot { color: var(--ok); background: var(--ok-wash); }

.issued-batch { border: 1.5px solid #74cca8; }

.issued-textarea {
  font-family: var(--mono);
  font-size: 13px;
  min-height: 104px;
}

.sha-code {
  display: block;
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  color: var(--text-3);
}

.client-upload-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(188px, 1fr));
  gap: 12px;
  align-items: end;
  margin-bottom: 6px;
}

.client-notes-field { grid-column: 1 / -1; }

/* 设置表单：开关单独一行在最上面，输入框排成一行，说明和保存按钮在最下面靠左。
   以前开关、输入框、说明、按钮挤在同一张自动网格里，各占一格，高低错落 */
.smtp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(198px, 1fr));
  gap: 14px;
  align-items: end;
}

.smtp-grid > .switch-field,
.smtp-grid > .form-hint,
.smtp-grid > label:has(textarea) { grid-column: 1 / -1; }

.smtp-grid > .form-hint { margin: -4px 0 0; }

/* 开关是「勾选框 + 一句话」横排，不吃 .smtp-grid label 的上下排法 */
.smtp-grid > label.switch-field {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}

.smtp-grid > button[type="submit"] {
  grid-column: 1 / -1;
  justify-self: start;
}

.smtp-secret { grid-column: span 2; }

.smtp-test {
  display: flex;
  gap: 11px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.smtp-test label {
  flex: 1;
  min-width: 220px;
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

.state-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  background: var(--line-soft);
}

.state-pill.ready { color: var(--ok); background: var(--ok-wash); }

/* ------------------------------------------------ 11 灵动岛通知 / 模态 */
.island-region {
  position: fixed;
  top: 16px;
  left: 0;
  right: 0;
  z-index: 200;
  display: grid;
  justify-items: center;
  pointer-events: none;
  padding: 0 16px;
}

.island {
  pointer-events: auto;
  display: flex;
  /* 文字可能换成多行，图标与关闭按钮跟着顶部对齐才不会飘 */
  align-items: flex-start;
  gap: 12px;
  /* 最宽占屏幕四分之一，超出就换行；窄屏下退回按边距撑满 */
  max-width: min(max(25vw, 320px), calc(100% - 8px));
  padding: 10px 12px 10px 10px;
  /* 单行时仍是胶囊，多行时圆角自动收敛为大圆角 */
  border-radius: 22px;
  background: #111316;
  color: #fff;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 10px 26px rgba(6, 10, 22, 0.35),
    0 26px 60px rgba(6, 10, 22, 0.28);
  animation: island-in 0.6s cubic-bezier(0.3, 1.35, 0.5, 1) both;
}

.island.leaving {
  animation: island-out 0.42s cubic-bezier(0.55, 0, 0.8, 0.4) forwards;
}

@keyframes island-in {
  0% { transform: translateY(-64px) scale(0.55); opacity: 0; filter: blur(4px); }
  55% { transform: translateY(3px) scale(1.03); opacity: 1; filter: blur(0); }
  100% { transform: translateY(0) scale(1); }
}

@keyframes island-out {
  0% { transform: translateY(0) scale(1); opacity: 1; }
  100% { transform: translateY(-64px) scale(0.55); opacity: 0; filter: blur(4px); }
}

.island-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex: none;
  color: #fff;
  /* 与标题行居中对齐，正文换行时图标不下沉 */
  margin-top: 1px;
}

.island-icon .icon { width: 15px; height: 15px; stroke-width: 2.2; }

.island-success .island-icon {
  background: #12a06c;
}

.island-error .island-icon {
  background: #d93b54;
}

.island-body {
  flex: 1;
  min-width: 0;
  display: grid;
  line-height: 1.4;
  padding-right: 2px;
}

.island-body b {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

/* 提示原文不再截断：网易的报错、短信号码这类内容截掉就没意义了，
   宁可换行占几行，也不要显示成 "……" */
.island-body span {
  font-size: 13px;
  color: rgba(235, 240, 252, 0.62);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.island-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  flex: none;
  margin-top: 1px;
  border-radius: 50%;
  color: rgba(235, 240, 252, 0.5);
  transition: color var(--speed), background var(--speed);
}

.island-close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.island-close .icon { width: 14px; height: 14px; }

/* 模态 */
.modal {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: min(550px, calc(100vw - 40px));
  width: 100%;
}

.modal.modal-wide { max-width: min(660px, calc(100vw - 40px)); }

.modal::backdrop {
  background: rgba(15, 23, 42, 0.42);
  backdrop-filter: blur(5px);
}

.modal[open] { animation: pop-in 0.24s var(--ease); }

.modal-card {
  padding: 25px 27px;
  border-radius: 16px;
  background: var(--card);
  box-shadow: var(--shadow-pop);
  color: var(--text-1);
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.modal-head h2 { font-size: 18px; font-weight: 700; }
.modal-head p { margin-top: 5px; font-size: 13px; color: var(--text-2); }

@keyframes pop-in {
  from { opacity: 0; transform: translateY(10px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.welcome-mark .wordmark { height: 30px; width: auto; }
html[data-theme="dark"] .welcome-mark { color: var(--blue-deep); }

/* ------------------------------------------------ 12 动效
   动效的分寸：**只做"从哪来、到哪去"的交代**，不做装饰性表演。
   一条也不许出现无限循环的呼吸/闪烁/流光（状态灯那一个除外，它在传达"活着"）。
   时长统一在 0.2~0.5s：再快看不清，再慢就挡路。

   缓动曲线只用下面这两条，别再各处自己编：
     --ease-out  收尾极缓的减速，用于"入场、展开、落位"——大部分场合
     --ease-spring  末端带一点点回弹，用于"响应点击"这类要有手感的地方
   两条都不过冲太多，中文界面里夸张的弹跳会显得廉价。 */
:root {
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.4, 0.64, 1);
  --enter-shift: 10px;
}

@keyframes rise-in {
  from { opacity: 0; transform: translateY(var(--enter-shift)); }
  to { opacity: 1; transform: none; }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slide-in-left {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: none; }
}

/* ---- 入场编排 ----
   主内容区的直接子块依次上浮。做成纯 CSS 而不是 JS：
   服务端渲染的站点，JS 要等 defer 脚本跑完才动手，那之前页面已经画出来了，
   于是会先看到静止的成品、再看它动一次——比不做还糟。
   CSS 动画在首帧就生效，用户看到的从头到尾只有一次入场。

   只编排前 8 个：再往下已经在首屏之外，用户滚到那里时动画早播完了，
   徒增一次不必要的重绘。 */
.app-main > *,
.public-main > * {
  animation: rise-in 0.44s var(--ease-out) both;
}

.app-main > *:nth-child(1) { animation-delay: 0.02s; }
.app-main > *:nth-child(2) { animation-delay: 0.07s; }
.app-main > *:nth-child(3) { animation-delay: 0.12s; }
.app-main > *:nth-child(4) { animation-delay: 0.17s; }
.app-main > *:nth-child(5) { animation-delay: 0.22s; }
.app-main > *:nth-child(6) { animation-delay: 0.27s; }
.app-main > *:nth-child(7) { animation-delay: 0.32s; }
.app-main > *:nth-child(n + 8) { animation-delay: 0.36s; }

.public-main > *:nth-child(1) { animation-delay: 0.02s; }
.public-main > *:nth-child(2) { animation-delay: 0.09s; }
.public-main > *:nth-child(3) { animation-delay: 0.16s; }
.public-main > *:nth-child(n + 4) { animation-delay: 0.22s; }

/* 侧栏比正文早一点点落位：视线从左进来，导航先站定才不显得散 */
.sidebar-head { animation: fade-in 0.4s var(--ease-out) both; }
.sidebar-group { animation: slide-in-left 0.4s var(--ease-out) both; }
.sidebar-group:nth-child(1) { animation-delay: 0.04s; }
.sidebar-group:nth-child(2) { animation-delay: 0.08s; }
.sidebar-group:nth-child(3) { animation-delay: 0.12s; }
.sidebar-group:nth-child(4) { animation-delay: 0.16s; }
.sidebar-group:nth-child(5) { animation-delay: 0.20s; }
.sidebar-group:nth-child(6) { animation-delay: 0.24s; }
.sidebar-group:nth-child(n + 7) { animation-delay: 0.28s; }
.sidebar-foot { animation: fade-in 0.5s var(--ease-out) 0.2s both; }

/* 总览页那几张统计卡横向铺开，逐张落位比整排一起出现更有秩序感 */
.overview-grid > .stat-card { animation: rise-in 0.42s var(--ease-out) both; }
.overview-grid > .stat-card:nth-of-type(1) { animation-delay: 0.16s; }
.overview-grid > .stat-card:nth-of-type(2) { animation-delay: 0.22s; }
.overview-grid > .stat-card:nth-of-type(3) { animation-delay: 0.28s; }
.overview-grid > .stat-card:nth-of-type(4) { animation-delay: 0.34s; }

/* ---- 跨页过渡 ----
   服务端渲染的多页站点，点链接时会白闪一下。View Transitions 是浏览器原生的
   跨文档过渡，不支持的浏览器（Firefox / 旧 Safari）自动当这段不存在，
   退回原来的直接切换——所以不需要任何降级代码。 */
@view-transition { navigation: auto; }

::view-transition-old(root) {
  animation: fade-in 0.16s var(--ease-out) reverse both;
}

::view-transition-new(root) {
  animation: rise-in 0.3s var(--ease-out) both;
}

/* 侧栏在翻页时不该跟着淡入淡出——它每一页都一样，动它只会让人以为整站重载了。
   给它一个独立的过渡名，浏览器就会把它当成"同一个元素移动过去"而不是换掉。 */
.sidebar { view-transition-name: voh-sidebar; }
::view-transition-group(voh-sidebar) { animation-duration: 0.01ms; }

/* ---- 微交互 ---- */
/* 卡片不做悬停上浮（每张卡都会动是模板味）；能点的卡片悬停时底色微变即可 */
.quick-grid > a { transition: background-color 0.16s var(--ease-out); }
.quick-grid > a:hover { background-color: var(--bg-soft); }

/* 按钮按下要立刻有回应：0.06s 是"跟手"的上限，再长就感觉钝 */
.primary-button,
.ghost-button,
.chip-button,
.pay-btn {
  transition:
    transform 0.14s var(--ease-spring),
    box-shadow 0.18s var(--ease-out),
    background-color 0.18s var(--ease-out),
    border-color 0.18s var(--ease-out),
    color 0.18s var(--ease-out);
}

.primary-button:active,
.ghost-button:active,
.chip-button:active,
.pay-btn:active {
  transform: scale(0.975);
  transition-duration: 0.06s;
}

/* 进度条填充：宽度由 JS 在下一帧写入，这条过渡负责把它"走"过去而不是跳过去 */
.progress i,
.quota-track i,
.task-progress i,
.helper-task-bar i {
  transition: width 0.7s var(--ease-out);
}

/* 表格行 hover：整行轻微染色，比给每个单元格加边框干净 */
.data-table tbody tr { transition: background-color 0.16s var(--ease-out); }

/* 模态与弹层入场 */
dialog[open] .modal-card { animation: rise-in 0.3s var(--ease-out) both; }
dialog::backdrop { animation: fade-in 0.22s var(--ease-out) both; }

/* ---- 登录欢迎序列 ----
   登录成功后先盖一层，播完再滑走露出控制台。
   分寸：**总长 1.35 秒且随时可点掉**。开屏动画的通病是把自己当主角，
   用户每天登录好几次，第三次之后任何超过 1.5 秒的东西都只剩烦人。
   所以这里没有任何"表演"，只有一句确认："进来了，是你"。

   三段的时间是排过的：描边 0.04→0.59、方块 0.22→0.62、文字 0.34→0.74。
   全部在 0.75 秒内落位，剩下 0.6 秒让人**看清成品**再退场。
   第一版把建立拖到 0.92 秒，完整形态只存在 0.33 秒——等于白做。 */
.welcome-veil {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: grid;
  place-items: center;
  background: var(--bg);
  animation: fade-in 0.2s var(--ease-out) both;
}

.welcome-veil.leaving {
  animation: welcome-veil-out 0.5s var(--ease-out) both;
}

@keyframes welcome-veil-out {
  from { opacity: 1; transform: none; }
  to { opacity: 0; transform: translateY(-14px); }
}

.welcome-inner {
  display: grid;
  justify-items: center;
  gap: 18px;
  text-align: center;
  padding: 0 24px;
}

/* 品牌标记：先画一圈描边，再落下实心方块。
   描边用 stroke-dashoffset，是"正在确认身份"的具象化，不是装饰 */
.welcome-ring {
  position: relative;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
}

.welcome-ring svg {
  position: absolute;
  inset: 0;
  width: 76px;
  height: 76px;
  transform: rotate(-90deg);
}

.welcome-ring circle {
  fill: none;
  stroke: var(--blue);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 226;
  stroke-dashoffset: 226;
  animation: ring-draw 0.55s var(--ease-out) 0.04s both;
}

@keyframes ring-draw {
  to { stroke-dashoffset: 0; }
}

.welcome-mark {
  display: grid;
  place-items: center;
  color: var(--blue);
  /* 字标本身就是标志，不再套蓝色方块 */
  animation: welcome-mark-in 0.4s var(--ease-spring) 0.22s both;
}

@keyframes welcome-mark-in {
  from { opacity: 0; transform: scale(0.6); }
  to { opacity: 1; transform: scale(1); }
}

.welcome-copy {
  display: grid;
  gap: 6px;
  animation: rise-in 0.4s var(--ease-out) 0.34s both;
}

.welcome-copy strong {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: 0;
}

.welcome-copy span {
  font-size: 14px;
  color: var(--text-3);
}

/* 无障碍与省电：关掉动画偏好时，一切装饰性动效必须**立刻**变成静态终态。
   注意欢迎层要连同 JS 一起短路（见 app.js），只把动画时长改成 0 的话，
   那一层会以静止状态挂在屏幕上直到定时器到点——反而更像卡住了。 */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .app-main > *,
  .public-main > *,
  .sidebar-group,
  .sidebar-head,
  .sidebar-foot,
  .overview-grid > .stat-card {
    animation-delay: 0s !important;
  }

  .stat-card:hover,
  .helper-card:hover,
  .binding-card:hover,
  .library-item:hover,
  .task-card:hover,
  .quick-grid > a:hover { transform: none; }
}

/* ------------------------------------------------ 13 响应式 */
@media (max-width: 1080px) {
  .auth-shell {
    grid-template-columns: 1fr;
    gap: 30px;
    padding-top: 20px;
  }

  .feature-bento { grid-template-columns: 1fr; }
  .preview-grid { grid-template-columns: 1fr; }

  .two-col,
  .profile-grid,
  .redeem-panel,
  .support-panel,
  .slot-summary { grid-template-columns: 1fr; }

  /* 四种添加方式在中等屏幕排两行，挤成一行会把说明文字压没 */
  .login-method-row { grid-template-columns: repeat(2, 1fr); }

  .task-event { grid-template-columns: 1fr; gap: 2px; }

  /* 窄屏群号独占一行、按钮排下面，否则三件东西挤成一条挤出边框 */
  .support-join { flex-wrap: wrap; }
  .support-code { flex: 1 1 100%; justify-content: space-between; }

  .overview-grid { grid-template-columns: repeat(2, 1fr); }
  .agent-stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  /* 通栏卡在窄屏折成上下两段，否则右边三条要点会被挤成竖条 */
  .enterprise-card { grid-template-columns: minmax(0, 1fr); gap: 18px; }

  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 140;
    width: min(244px, 74vw);
    height: 100dvh;
    padding: 16px 12px 12px;
    gap: 10px;
    transform: translateX(-102%);
    transition: transform 0.28s var(--ease);
    box-shadow: var(--shadow-pop);
  }

  body.nav-open .sidebar { transform: translateX(0); }

  .sidebar-close { display: inline-flex; width: 30px; height: 30px; }
  .sidebar-close .icon { width: 16px; height: 16px; }

  .side-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 130;
    background: rgba(15, 23, 42, 0.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s;
  }

  body.nav-open .side-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--mobile-bar-h);
    z-index: 120;
    padding: 0 12px 0 6px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
  }

  .mobile-bar .icon-button { width: 32px; height: 32px; }
  .mobile-bar .icon-button .icon { width: 17px; height: 17px; }

  .mobile-bar-mark { flex-shrink: 0; margin-left: auto; color: var(--blue); }
  html[data-theme="dark"] .mobile-bar-mark { color: var(--blue-deep); }
  .mobile-bar-mark .wordmark { height: 13px; width: auto; }

  .mobile-bar-title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text-2);
  }

  .app-main { padding: calc(var(--mobile-bar-h) + 16px) 16px 44px; }

  .overview-grid { grid-template-columns: 1fr; }
  .agent-stats { grid-template-columns: 1fr; }
  .ov-grid, .ov-split { grid-template-columns: minmax(0, 1fr); }

  .login-method-row { grid-template-columns: 1fr; }

  .token-table-head { display: none; }
  .token-row { grid-template-columns: 1fr 1fr; }

  .client-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 13px;
  }

  /* 「左内容 + 右操作」的横排卡片在窄屏没有横向空间，
     继续并排会把中间的文字挤成竖排并与右侧内容重叠，一律改为上下堆叠。 */
  .helper-card,
  .binding-card {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .helper-card .avatar,
  .binding-icon { align-self: flex-start; }

  .helper-health {
    justify-items: start;
    padding-top: 12px;
    border-top: 1px solid var(--line-soft);
  }

  .helper-badges,
  .helper-ops { justify-content: flex-start; }

  .redeem-form { flex-direction: column; }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-center { padding-top: 40px; }
  .feature-bento { margin-top: 56px; }
  .public-section { padding-top: 64px; }
}

@media (max-width: 620px) {
  .public-main,
  .public-header-inner { width: calc(100% - 30px); }

  /* 顶栏收紧：logo + 登录/注册在窄屏排不下会撑出横向滚动、把整页顶偏 */
  .brand small { display: none; }
  .brand .wordmark { height: 18px; }
  .public-header-inner { gap: 10px; padding: 12px 0; }
  .public-nav { gap: 6px; }
  .public-nav .primary-button { padding: 9px 13px; font-size: 14px; }
  .public-nav .text-link { padding: 7px 9px; }

  .quick-grid { grid-template-columns: 1fr; }
  .split-fields { grid-template-columns: 1fr; }

  /* 官方面板入口：窄屏改为单列、按钮整行且矮一些，别占太长竖向空间 */
  .panel-entry { grid-template-columns: 1fr; gap: 14px; }
  .panel-entry-points { gap: 9px; }
  .panel-entry-points li { font-size: 14px; }
  .panel-entry-btn {
    grid-template-columns: auto auto;
    justify-content: center;
    align-items: center;
    gap: 4px 9px;
    padding: 13px 18px;
  }
  .panel-entry-btn .icon { grid-row: span 2; width: 22px; height: 22px; }
  .panel-entry-btn b { font-size: 15px; }
  .panel-entry-btn small { font-size: 12px; }

  .inline-code-form {
    flex-direction: column;
    align-items: stretch;
  }

  .panel { padding: 19px 17px; }
  .auth-card { padding: 22px 20px; }

  /* 窄屏时面板头换行，云端入口占满整行，避免按钮孤零零地贴在左边 */
  .panel-head:has(.cloud-button) .panel-action { width: 100%; }

  .cloud-button { width: 100%; padding: 10px 18px; }

  .stats-row { flex-wrap: wrap; }

  .token-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .token-actions { justify-content: flex-start; }

  .smtp-secret { grid-column: auto; }

  .issued-token { flex-direction: column; }

  /* 账号名与「主账号」标签同排时，窄屏下标签会被压成竖排 */
  .helper-info > div { flex-wrap: wrap; gap: 7px; }
  .helper-info strong { min-width: 0; overflow-wrap: anywhere; }
  .primary-tag { flex: none; white-space: nowrap; }

  /* 向导步骤条：只保留当前步骤的文字，避免三段文字挤在一行 */
  .wizard-steps { gap: 7px; }
  .wizard-step .wizard-label { display: none; }
  .wizard-step.current .wizard-label { display: inline; }
  .wizard-step + .wizard-step::before { min-width: 12px; }

  /* 短信卡：号码很长，标签与复制按钮换行排布 */
  .sms-row { flex-wrap: wrap; gap: 8px; }
  .sms-key { width: auto; }
  .sms-value { flex: 1 0 100%; order: 3; font-size: 16px; }
  .sms-row.muted .sms-value { font-size: 14px; }

  .wizard-actions { flex-wrap: wrap; }
  .wizard-actions > * { flex: 1 1 auto; }

  .modal-head { gap: 10px; }
}

/* ── 站内公告弹窗 ───────────────────────────────────────────
   全站同一时刻只有一条公告，每次刷新都会重新弹出。
   遮罩不做滚动锁定，避免公告很长时挡住页面无法阅读。 */
.announce-mask[hidden] { display: none; }
.announce-mask {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(16, 24, 38, .42);
  backdrop-filter: blur(2px);
}
.announce-card {
  position: relative;
  width: min(520px, 100%);
  max-height: min(72vh, 640px);
  overflow-y: auto;
  padding: 28px 26px 18px;
  border-radius: 16px;
  background: var(--card);
  box-shadow: 0 24px 60px rgba(16, 24, 38, .24);
}
.announce-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text-3);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.announce-close:hover { background: var(--bg-soft); color: var(--text-1); }
.announce-title {
  margin: 0 0 14px;
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-1);
}
.announce-body { color: var(--text-2); font-size: 14px; line-height: 1.75; }
.announce-body p { margin: 0 0 8px; }
.announce-meta {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 18px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--text-3);
  font-size: 12px;
}
@media (max-width: 560px) {
  .announce-card { padding: 24px 18px 14px; }
  .announce-title { font-size: 16px; }
}

/* 验证接入文档：给第三方开发者看的接口说明 */
.doc-flow {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 4px;
}
.doc-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.doc-step-index {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 10px;
  background: var(--accent-soft, #e8efff);
  color: var(--accent, #2f6bff);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.doc-step-body { flex: 1; min-width: 0; }
.doc-step-body b {
  display: block;
  font-size: 15px;
  margin-bottom: 6px;
}
.doc-step-body p {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-muted, #64748b);
}
.doc-step-body pre {
  margin: 0 0 6px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--code-bg, #f5f7fb);
  border: 1px solid var(--line, #e6ebf3);
  overflow-x: auto;
}
.doc-step-body pre code {
  font-size: 12px;
  line-height: 1.65;
  white-space: pre;
  color: var(--text-1);
  background: none;
  padding: 0;
}
.doc-notes {
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--code-bg, #f5f7fb);
  border: 1px solid var(--line, #e6ebf3);
}
.doc-notes b { font-size: 14px; }
.doc-notes ul {
  margin: 8px 0 0;
  padding-left: 20px;
}
.doc-notes li {
  font-size: 13px;
  line-height: 1.8;
  color: var(--text-muted, #64748b);
}

/* ------------------------------------------------ 14 材质与层次
   卡片：亮色靠极淡柔影，深色靠 1px 边（--ring），两者不叠加发光。
   数据区（任务卡、终端、空状态）是一层浅井，和卡面分得开。
   表头不再铺灰底色带：表格靠对齐和发丝线组织，头部只用灰色小字。 */

.panel,
.glass {
  box-shadow: var(--ring), var(--shadow-card);
}

.stat-card { box-shadow: var(--ring), var(--shadow-card); }

.task-card {
  border-color: transparent;
  background: var(--well-bg);
  box-shadow: var(--well-shadow);
}

.task-progress { box-shadow: none; }

.task-console { box-shadow: var(--well-shadow); }

.data-table th { background: none; box-shadow: inset 0 -1px 0 var(--line); }

.data-table td { border-bottom-color: var(--hairline); }

.empty-state { background: none; }

/* 数字等宽：竖排时位数对齐 */
.stat-card .metric-number,
.data-table td,
.quota-panel strong,
.task-percent,
.task-console {
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------ 15 全站维护页
   一张居中的卡把话说完。刻意不做插画、不做动画：
   用户此刻只想知道"出什么事了、多久好"，别的都是干扰。 */

.maintenance-wrap {
  min-height: 70vh;
  display: grid;
  place-items: center;
  padding: 40px 20px;
}

.maintenance-card {
  max-width: 520px;
  text-align: center;
  padding: 40px 38px 34px;
}

.maintenance-mark {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  border-radius: 16px;
  color: var(--blue);
  background: var(--blue-wash);
  box-shadow: var(--well-shadow);
}

.maintenance-mark .icon { width: 24px; height: 24px; }

.maintenance-card h1 {
  margin: 0 0 14px;
  font-size: 20px;
  font-weight: 650;
  letter-spacing: 0;
  color: var(--text-1);
}

/* 管理员写的理由：按行渲染，行距放宽，读起来像一段交代而不是报错 */
.maintenance-copy {
  display: grid;
  gap: 8px;
  padding: 16px 18px;
  border-radius: var(--r-md);
  background: var(--well-bg);
  box-shadow: var(--well-shadow);
  text-align: left;
}

.maintenance-copy p {
  margin: 0;
  font-size: 14px;
  line-height: 1.75;
  color: var(--text-2);
}

.maintenance-foot {
  margin: 18px 0 0;
  font-size: 13px;
  color: var(--text-3);
}

.maintenance-foot a { color: var(--blue); }

/* 一键清理的前置提示：没跑过检测时，用一句灰字代替按钮，
   而不是摆一个点了会报错的按钮。 */
.cleanup-hint {
  font-size: 13px;
  color: var(--text-3);
  align-self: center;
  white-space: nowrap;
}

/* ------------------------------------------------ 16 图表
   服务端渲染的内联 SVG（见 src/views/charts.mjs）。

   ⚠ SVG 里**没有一个 style 属性**：CSP 的 `style-src 'self'` 会把内联样式整块拒掉。
   颜色全部由这里的 class 承担，跟随主题切换；SVG 那边只写 fill/stroke 这类
   呈现属性（它们是属性不是 CSS，不受 CSP 限制）。

   配色是算出来并用 dataviz 验证脚本验过的，不是挑的：
   · 蓝色量级阶梯 5 阶——单一色相、亮度单调、相邻 ΔL ≥ 0.06、浅端对底色 ≥ 2:1
   · 「已取消」用中性灰而非警告橙：实测 #dc2626(失败) 与 #b45309(警告) 在亮色下
     常人视觉 ΔE 只有 9.9（低于 15 底线）、红绿色盲下 2.8，放一起等于没区分
   改这些值之前请重跑验证脚本，别凭眼睛调。 */
:root {
  /* 量级阶梯（浅 → 深） */
  --chart-1: #7ea7f5;
  --chart-2: #4f86ef;
  --chart-3: #2563eb;
  --chart-4: #1a45b8;
  --chart-5: #123081;
  /* 结果状态：完成 / 取消(中性) / 失败 */
  --chart-ok: #059669;
  --chart-neutral: #8b93a5;
  --chart-bad: #dc2626;
  /* 图表专用的墨色，比正文淡一档——网格与坐标要退到数据后面去 */
  --chart-grid: #edf2f9;
  --chart-axis-ink: #6b7690;
  --chart-track: #eef3fb;
}

html[data-theme="dark"] {
  --chart-1: #c3d7fc;
  --chart-2: #96b8f8;
  --chart-3: #6b95f3;
  --chart-4: #4670d9;
  --chart-5: #2f4d9c;
  --chart-ok: #34d399;
  /* 深色下这个灰是算出来的：#9aa3b5 才能和 #f26d7d(失败) 拉开色盲距离 8.5，
     用亮色那个 #8b93a5 只有 6.2，红绿色盲会把"取消"和"失败"看成一样 */
  --chart-neutral: #9aa3b5;
  --chart-bad: #f26d7d;
  --chart-grid: #1e2634;
  --chart-axis-ink: #7d8798;
  --chart-track: #1a2331;
}

.chart-svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

/* 网格与坐标：一像素实线、比底色深一档。虚线会被读成"阈值"或"预测"，
   而它只是网格——这是 dataviz 反模式清单里明确点名的一条。 */
.chart-grid {
  stroke: var(--chart-grid);
  stroke-width: 1;
}

/* 文字一律穿文字色，绝不穿数据色。
   浅色的数据色当文字用在白底上根本读不清；身份由旁边的色块承担。 */
.chart-axis-text {
  fill: var(--chart-axis-ink);
  font-size: 12px;
  font-family: var(--font);
  /* 坐标刻度是需要竖直对齐的列，用等宽数字 */
  font-variant-numeric: tabular-nums;
}

.chart-value-label {
  fill: var(--text-2);
  font-size: 13px;
  font-weight: 600;
  font-family: var(--font);
  font-variant-numeric: tabular-nums;
}

.chart-rank-label { fill: var(--text-2); }

/* 折线 2px、圆角圆头；面积只是 10% 的一层薄雾，不是实心色块 */
.chart-line {
  fill: none;
  stroke: var(--chart-3);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.chart-area {
  fill: var(--chart-3);
  fill-opacity: 0.1;
  stroke: none;
}

/* 端点：≥8px 直径，外加 2px 底色描环——压在线上或互相重叠时才分得开。
   这个环也是它的命中区域的一部分。 */
.chart-dot {
  fill: var(--chart-3);
  stroke: var(--card);
  stroke-width: 2;
}

.chart-bar { fill: var(--chart-3); }
.chart-track { fill: var(--chart-track); }

.chart-fill-ok { fill: var(--chart-ok); }
.chart-fill-neutral { fill: var(--chart-neutral); }
.chart-fill-bad { fill: var(--chart-bad); }

/* 热力图五档：0 单独一档（几乎等于底色），其余四档走量级阶梯。
   把"完全没有"和"很少"分开，否则空白日子看着像有一点点活动。 */
.chart-heat-0 { fill: var(--chart-track); }
.chart-heat-1 { fill: var(--chart-1); }
.chart-heat-2 { fill: var(--chart-2); }
.chart-heat-3 { fill: var(--chart-3); }
.chart-heat-4 { fill: var(--chart-5); }

/* 迷你走势线：统计卡里那条小线，没有轴也没有标签 */
.chart-spark {
  display: block;
  width: 108px;
  height: 30px;
  overflow: visible;
}

.chart-spark-line {
  fill: none;
  stroke: var(--chart-3);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

.chart-spark-dot { fill: var(--chart-3); }

/* 图例：两条以上序列必须有。色块承担身份，文字保持文字色。
   深色主题下「失败↔取消」的色盲距离落在必须配二级编码的区间，
   这个图例就是那道二级编码，**不许为了省地方删掉**。 */
.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 10px;
  padding-left: 44px;
}

.chart-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: var(--text-2);
}

.chart-legend-item i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex: none;
}

.chart-legend-item i.chart-fill-ok { background: var(--chart-ok); }
.chart-legend-item i.chart-fill-neutral { background: var(--chart-neutral); }
.chart-legend-item i.chart-fill-bad { background: var(--chart-bad); }
.chart-legend-item i.chart-bar { background: var(--chart-3); }

/* 表格视图：每张图的孪生体。悬浮提示只能增强、不能成为读到数值的唯一途径
   （色觉障碍、读屏、打印都拿不到悬浮）。默认折叠，但永远在。 */
.chart-table { margin-top: 12px; }

.chart-table > summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--r-sm);
  font-size: 13px;
  color: var(--text-3);
  cursor: pointer;
  list-style: none;
  transition: background-color 0.16s var(--ease-out), color 0.16s var(--ease-out);
}

.chart-table > summary::-webkit-details-marker { display: none; }
.chart-table > summary:hover { background: var(--bg-soft); color: var(--text-1); }
.chart-table[open] > summary { color: var(--text-1); }
.chart-table .data-table { margin-top: 8px; }
.chart-table caption {
  padding-bottom: 8px;
  font-size: 13px;
  color: var(--text-3);
  text-align: left;
}

/* ---- 图表卡片 ---- */
.chart-card {
  padding: 20px 22px 18px;
  border-radius: var(--r-lg);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.chart-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.chart-card-copy h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: 0;
}

.chart-card-copy p {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--text-3);
}

.chart-empty {
  display: grid;
  place-items: center;
  min-height: 140px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  color: var(--text-3);
  font-size: 13px;
}

.chart-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  /* 不拉伸。默认的 stretch 会让"没有数据"的那张卡被旁边有图的卡撑到同高，
     底下留出一大片空白，看着像渲染坏了。各自按内容高就行。 */
  align-items: start;
}

/* ---- 统计卡 ---- */
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.stat-tile {
  display: grid;
  gap: 8px;
  padding: 16px 18px 14px;
  border-radius: var(--r-lg);
  background: var(--card);
  box-shadow: var(--shadow-card);
  color: inherit;
  text-decoration: none;
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-out);
}

a.stat-tile:hover {
  background: var(--bg-soft);
}

.stat-tile-label {
  font-size: 13px;
  color: var(--text-3);
}

/* 大数字用**比例数字**：等宽会让 121 这类数在大字号下显得松垮。
   等宽只用在需要竖直对齐的列里（表格、坐标刻度）。 */
.stat-tile-value {
  font-size: 28px;
  font-weight: 600;
  line-height: 1.1;
  color: var(--text-1);
  letter-spacing: 0;
}

.stat-tile-value em {
  margin-left: 4px;
  font-size: 13px;
  font-style: normal;
  font-weight: 500;
  color: var(--text-3);
}

.stat-tile-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 30px;
}

.stat-delta {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.stat-delta em {
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
  color: var(--text-3);
}

.stat-delta.good { color: var(--ok); }
.stat-delta.bad { color: var(--bad); }
.stat-delta.flat { color: var(--text-3); }

/* ---- 仪表条 ---- */
.chart-meter {
  height: 8px;
  border-radius: 999px;
  background: var(--chart-track);
  overflow: hidden;
}

.chart-meter i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--chart-3);
  transition: width 0.7s var(--ease-out);
}

/* 仪表条的颜色随严重程度走：接近上限时先黄后红。
   槽保持同色系的浅一档，整根条从头到尾在表达同一件事的进度。 */
.chart-meter.hot i { background: var(--warn); }
.chart-meter.critical i { background: var(--bad); }

@media (max-width: 1080px) {
  .chart-grid-2 { grid-template-columns: minmax(0, 1fr); }
  .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .stat-row { grid-template-columns: minmax(0, 1fr); }
  .chart-legend { padding-left: 0; }
  .chart-card { padding: 16px 14px 14px; }
}

/* ------------------------------------------------ 17 命令面板（Ctrl/⌘ + K）
   一个输入框解决"我要去哪 / 我要找什么"。刻意做得像原生：
   白卡、无边框、柔影，不用毛玻璃（那是 AI 味清单上的东西）。 */
.cmdk-mask {
  position: fixed;
  inset: 0;
  z-index: 700;
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 12vh 20px 20px;
  background: rgba(15, 23, 42, 0.32);
  animation: fade-in 0.16s var(--ease-out) both;
}

html[data-theme="dark"] .cmdk-mask { background: rgba(0, 0, 0, 0.52); }

/* 面板开着的时候锁住背景滚动，否则滚轮会滚穿到底下的页面 */
body.cmdk-open { overflow: hidden; }

.cmdk {
  width: min(600px, 100%);
  border-radius: 16px;
  background: var(--card);
  box-shadow: var(--shadow-pop);
  overflow: hidden;
  animation: rise-in 0.24s var(--ease-out) both;
}

.cmdk-field {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 15px 16px;
  border-bottom: 1px solid var(--line-soft);
}

.cmdk-field .icon {
  width: 18px;
  height: 18px;
  color: var(--text-3);
  flex: none;
}

/* 输入框脱掉一切外壳：整个面板就是这个输入框，再画一层边框是多余的 */
.cmdk-field input {
  flex: 1;
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text-1);
  font-size: 15px;
  font-family: var(--font);
}

.cmdk-field input:focus { outline: none; box-shadow: none; }
.cmdk-field input::placeholder { color: var(--text-3); }

.cmdk kbd {
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg-soft);
  color: var(--text-3);
  font-size: 12px;
  font-family: var(--font);
  line-height: 1.5;
}

.cmdk-list {
  max-height: min(52vh, 420px);
  overflow-y: auto;
  padding: 6px;
}

.cmdk-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 11px;
  border: 0;
  border-radius: var(--r-sm);
  background: none;
  color: var(--text-1);
  font-size: 14px;
  font-family: var(--font);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

/* 键盘选中与鼠标悬停用同一个态：两套高亮同时存在会让人不知道回车会打开哪个 */
.cmdk-row.active { background: var(--blue-wash); }
.cmdk-row.active b { color: var(--blue-deep); }

.cmdk-row b {
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cmdk-row small {
  margin-left: auto;
  padding-left: 10px;
  color: var(--text-3);
  font-size: 12px;
  white-space: nowrap;
}

.cmdk-kind {
  flex: none;
  min-width: 34px;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--bg-soft);
  color: var(--text-3);
  font-size: 12px;
  text-align: center;
}

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

.cmdk-foot {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 9px 14px;
  border-top: 1px solid var(--line-soft);
  background: var(--bg-soft);
  color: var(--text-3);
  font-size: 12px;
}

.cmdk-foot span { display: inline-flex; align-items: center; gap: 5px; }
.cmdk-foot-hint { margin-left: auto; }

/* 侧栏里那个「搜索」入口的样式在「07 应用壳」里（移动端没有物理键盘，必须有个能点的地方） */

@media (max-width: 620px) {
  .cmdk-mask { padding: 8vh 12px 12px; }
  .cmdk-foot span:not(.cmdk-foot-hint) { display: none; }
}

/* ------------------------------------------------ 18 补齐：token / 焦点 / 缺失规则
   这一节修的都是**会被看见的坏效果**，不是风格偏好。 */

:root {
  /* wash 底上的深色文字。原来是硬编码 #7c5210 / #0f6b4f，
     深色主题下压在深色 wash 上只有 2.29:1 / 2.37:1，基本读不出来。 */
  --warn-ink: #7c5210;
  --ok-ink: #0f6b4f;
  /* 卡密「订阅」类型标签。原来整条硬编码，深色下是一块浅紫亮斑。 */
  --kind-sub-ink: #7c3aed;
  --kind-sub-wash: #f3edfd;
  /* 这四个来自那段外来代码（公告 + 接入文档）。它们都带兜底值，所以没有像
     --ink/--muted 那样直接失效，但兜底值是**另一套设计系统的颜色**：
     --accent 的 #2f6bff 是第二套蓝、--text-muted 的 #64748b 是第四级灰。
     指回本表的 token，两套色系才不会在同一个页面里打架。 */
  --accent: var(--blue);
  --accent-soft: var(--blue-wash);
  --text-muted: var(--text-3);
  --code-bg: var(--bg-soft);

  /* 焦点环。原来只有输入框有，按钮和链接全靠浏览器默认环——
     那个环在蓝色实心按钮和深色终端上几乎看不见。
     透明度给到 0.38：审计里原来那条 0.1 太淡，等于没有。 */
  --ring-focus: 0 0 0 3px rgba(37, 99, 235, 0.38);
}

html[data-theme="dark"] {
  /* 深色下改用同色系的**浅**色调，压在深色 wash 上才读得出来 */
  --warn-ink: #e6b361;
  --ok-ink: #5cd6a6;
  --kind-sub-ink: #c4a5f7;
  --kind-sub-wash: #2a2140;
  --ring-focus: 0 0 0 3px rgba(107, 149, 243, 0.5);
}

/* ---- 焦点可见性 ----
   审计发现全站只有 3 条 :focus 规则，按钮和链接一条都没有。
   键盘用户在这个站上基本是"盲操作"。
   用 :focus-visible 而不是 :focus：鼠标点击不会亮环，只有键盘导航才亮，
   两边都照顾到。 */
.primary-button:focus-visible,
.ghost-button:focus-visible,
.chip-button:focus-visible,
.icon-button:focus-visible,
.pay-btn:focus-visible,
.pay-submit:focus-visible,
.panel-entry-btn:focus-visible,
.nav-item:focus-visible,
.text-link:focus-visible,
.quick-grid a:focus-visible,
.timeline-row:focus-visible,
.stat-tile:focus-visible,
.sidebar-search:focus-visible,
.cmdk-row:focus-visible,
.island-close:focus-visible,
.announce-close:focus-visible,
.sidebar-close:focus-visible,
.theme-toggle:focus-visible,
.chart-table > summary:focus-visible,
.tf-advanced > summary:focus-visible,
details > summary:focus-visible,
a:focus-visible {
  outline: none;
  box-shadow: var(--ring-focus);
  /* 环要画在元素外面而不是被裁掉 */
  border-radius: var(--r-sm);
}

/* 圆角元素的焦点环跟着它自己的圆角走，否则方环套圆角很难看 */
.primary-button:focus-visible,
.ghost-button:focus-visible,
.pay-btn:focus-visible,
.pay-submit:focus-visible { border-radius: var(--r-md); }
.icon-button:focus-visible,
.theme-toggle:focus-visible { border-radius: var(--r-sm); }
.stat-tile:focus-visible,
.quick-grid a:focus-visible { border-radius: var(--r-lg); }

/* ---- 管理端两条缺失的规则 ----
   这两个 class 在 admin.mjs 里用着，但 CSS 里**一条规则都没有**，
   于是「引擎未就绪」和「就绪」长得一模一样、「维护中」和「正常」也是。
   管理员正是靠这两个色块判断系统状态的。 */
.engine-missing {
  color: var(--bad);
  font-weight: 600;
}

.engine-missing::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--bad);
  vertical-align: middle;
}

.state-pill.warn {
  border-color: var(--warn);
  background: var(--warn-wash);
  color: var(--warn-ink);
}

/* 订单页筛选行、管理端几个只靠继承勉强能看的容器 */
.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.filter-row form { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.filter-row .chip-button.active { border-color: var(--blue); color: var(--blue-deep); background: var(--blue-wash); }

/* ---- 全局 code 字号 ----
   全局 `code { font-size: 0.86em }` 会把 12.5px 容器里的行内代码压到 10.75px，
   低于中文可读下限。只有 3 处显式修回过，其余 20 多处裸 <code> 全部漏网。
   这里统一兜底：行内代码不再缩小，靠底色和字体区分即可。 */
code { font-size: inherit; }


/* ---- 时间范围切换 ----
   放在所有图之上的一行，一次切换全部跟着走。
   每张图各自带一个范围选择器是可视化的反模式：读者会以为它们各自独立。 */
.range-tabs {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  border: 1px solid var(--line);
}

.range-tab {
  padding: 5px 13px;
  border-radius: 8px;
  color: var(--text-2);
  font-size: 13px;
  text-decoration: none;
  transition: background-color 0.16s var(--ease-out), color 0.16s var(--ease-out);
}

.range-tab:hover { color: var(--text-1); }

.range-tab.active {
  background: var(--card);
  color: var(--blue-deep);
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

/* 额度流水里的正负变动。加号绿、减号红是**语义**不是装饰，
   所以用状态色；但同时带了 +/− 符号，不靠颜色单独承担信息。 */
.ledger-delta { font-variant-numeric: tabular-nums; font-weight: 600; }
.ledger-delta.up { color: var(--ok); }
.ledger-delta.down { color: var(--text-1); }

/* 统计卡的告警色调：接近上限或成功率偏低时用 */
.stat-tile.warn .stat-tile-value { color: var(--warn); }
.stat-tile.bad .stat-tile-value { color: var(--bad); }

/* ---- 管理端运维页 ---- */

/* 芯片列表：辅助账号、Token 这类"数量不定但每个都很短"的东西。
   用表格会显得很空，用卡片又太重。 */
.ops-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ops-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 11px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  font-size: 13px;
}

.ops-chip b { font-weight: 500; color: var(--text-1); }
.ops-chip small { color: var(--text-3); }

/* 分页器。原来 .pager 只是个 flex 空壳，没有页码也没有禁用态。 */
.pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--text-3);
}

.pager-links { display: flex; gap: 8px; }

/* 禁用态必须看得出来。原来到了第一页，「上一页」和「下一页」长得一模一样，
   点了没反应会让人以为坏了。 */
.chip-button.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

/* 筛选行里的输入与下拉：跟按钮同高，否则一行东西高低不齐 */
/* 全局那条 `input, select { width: 100% }` 会让筛选行里的每个控件各占一整行。
   这里显式收回宽度——筛选条件是并排读的，竖着排就失去了"一眼看全"的意义。 */
.filter-row input[type="search"],
.filter-row select {
  width: auto;
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--card);
  color: var(--text-1);
  font-size: 13px;
  font-family: var(--font);
}

.filter-row input[type="search"] {
  flex: 1 1 220px;
  min-width: 180px;
  max-width: 360px;
}

.filter-row select { flex: 0 0 auto; min-width: 130px; }

/* 审计日志的机读名：给运营看人话，但原始 action 也留着——
   排查时要拿它去 grep 代码 */
.audit-table small.legacy-code {
  display: block;
  margin-top: 2px;
  color: var(--text-3);
  font-family: var(--mono);
  font-size: 12px;
}

.audit-table td { vertical-align: top; }
.audit-table a { color: var(--blue); text-decoration: none; }
.audit-table a:hover { text-decoration: underline; }

@media (max-width: 620px) {
  .filter-row input[type="search"] { min-width: 0; flex: 1; }
  .pager { flex-direction: column; align-items: stretch; }
}

/* 云端任务状态徽章。和账号状态分开配色：
   任务的「失败」是这一次没跑成，不是账号出了问题。 */
.badge-task-succeeded { color: var(--ok); border-color: var(--ok-wash); }
.badge-task-failed { color: var(--bad); border-color: var(--bad-wash); }
.badge-task-running { color: var(--blue-deep); border-color: var(--blue-tint); }
.badge-task-queued { color: var(--warn); border-color: var(--warn-wash); }
.badge-task-canceled { color: var(--text-3); }

html[data-theme="dark"] .badge-task-succeeded { color: #3ddba6; border-color: #1e4436; }
html[data-theme="dark"] .badge-task-failed { color: #f2798c; border-color: #4a2831; }
html[data-theme="dark"] .badge-task-running { color: #6ba9f9; border-color: #1f3557; }
html[data-theme="dark"] .badge-task-queued { color: #e2ad4c; border-color: #45361a; }
html[data-theme="dark"] .badge-task-canceled { color: #8b94a6; border-color: var(--line); }

/* ------------------------------------------------ 19 数据表增强
   排序 / 搜索 / 翻页 / 导出。服务端已经渲染出完整的表，
   这一层只是给它装上能力（见 app.js 的「数据表增强」）。 */

.table-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.table-search { flex: 1 1 240px; max-width: 340px; }

.table-search input {
  width: 100%;
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--card);
  color: var(--text-1);
  font-size: 13px;
  font-family: var(--font);
}

.table-toolbar .chip-button { margin-left: auto; }
.table-toolbar .table-search ~ .chip-button { margin-left: auto; }

/* 可排序表头。整格可点，不是只有那个小箭头——
   小箭头的点击区太小，是可用性清单上的常见问题。 */
.data-table th[data-sort] {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: color 0.16s var(--ease-out);
}

.data-table th[data-sort]:hover { color: var(--text-1); }

.data-table th[data-sort] span { position: relative; padding-right: 15px; }

/* 排序箭头：**未排序时也画一个淡的**，否则用户不知道这一列可以点。
   这是「可发现性」——能力藏起来等于没有。 */
.data-table th[data-sort] span::after {
  content: "";
  position: absolute;
  right: 0;
  top: 50%;
  width: 0;
  height: 0;
  margin-top: -1px;
  border-left: 3.5px solid transparent;
  border-right: 3.5px solid transparent;
  border-bottom: 4.5px solid currentColor;
  opacity: 0.25;
  transition: opacity 0.16s var(--ease-out), transform 0.16s var(--ease-out);
}

.data-table th[data-sort]:hover span::after { opacity: 0.5; }

.data-table th.sort-asc span::after,
.data-table th.sort-desc span::after {
  opacity: 1;
  color: var(--blue);
}

.data-table th.sort-desc span::after { transform: rotate(180deg); }

/* 空表没东西可排，箭头只是噪音 */
.data-table:has(.empty-cell) th[data-sort] { cursor: default; }
.data-table:has(.empty-cell) th[data-sort] span::after { display: none; }

.data-table th[data-sort]:focus-visible {
  outline: none;
  box-shadow: var(--ring-focus);
  border-radius: var(--r-sm);
}

.table-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--text-3);
}

.pager-current {
  min-width: 54px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.table-foot .pager-links { display: flex; align-items: center; gap: 8px; }

@media (max-width: 620px) {
  .table-search { max-width: none; }
  .table-toolbar .chip-button { margin-left: 0; }
  .table-foot { flex-direction: column; align-items: stretch; }
}

/* ------------------------------------------------ 20 订单售后客服
   一个真正的小球 + 一张紧凑的会话面板。不往侧栏再塞一项，也不做“工单中心”式的
   重页面：用户正在干活时点开、说完、关掉，路径才够短。 */
.support-widget {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 720;
}

/* 浮窗不能继承主内容的入场 transform；否则移动端 fixed 面板会被限制在浮球坐标系里。 */
.app-main > .support-widget { animation: none; }

.support-orb {
  position: relative;
  display: grid;
  width: 58px;
  height: 58px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
  box-shadow: var(--shadow-pop);
  cursor: pointer;
  transition: transform var(--speed) var(--ease), box-shadow var(--speed) var(--ease);
}

.support-orb:hover {
  background: var(--blue-hover);
}

.support-orb:active { transform: translateY(0) scale(0.97); }
.support-orb:focus-visible { outline: 3px solid rgba(37, 99, 235, 0.24); outline-offset: 4px; }
.support-orb .icon { width: 25px; height: 25px; }

.support-orb-label {
  position: absolute;
  right: 68px;
  top: 50%;
  padding: 7px 11px;
  border: 1px solid var(--line-soft);
  border-radius: 10px;
  color: var(--text-1);
  background: var(--card);
  box-shadow: var(--shadow-card);
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translate(6px, -50%);
  transition: opacity var(--speed) var(--ease), transform var(--speed) var(--ease);
}

.support-orb:hover .support-orb-label,
.support-orb:focus-visible .support-orb-label {
  opacity: 1;
  transform: translate(0, -50%);
}

.support-orb-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  display: grid;
  min-width: 21px;
  height: 21px;
  padding: 0 5px;
  place-items: center;
  border: 2px solid var(--bg);
  border-radius: 999px;
  color: #fff;
  background: #e11d48;
  box-shadow: 0 2px 7px rgba(190, 18, 60, 0.36);
  font-size: 12px;
  font-weight: 750;
  line-height: 1;
}

.support-chat-panel {
  position: absolute;
  right: 0;
  bottom: 74px;
  display: flex;
  align-items: stretch;
  gap: 0;
  width: min(430px, calc(100vw - 32px));
  height: min(680px, calc(100vh - 122px));
  min-height: 480px;
  margin-top: 0;
  overflow: hidden;
  flex-direction: column;
  grid-template-columns: none;
  border: 1px solid rgba(220, 229, 242, 0.9);
  border-radius: 16px;
  background: var(--card);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.2), 0 4px 16px rgba(15, 23, 42, 0.08);
  transform-origin: right bottom;
  animation: support-chat-panel-in 0.2s var(--ease) both;
}

@keyframes support-chat-panel-in {
  from { opacity: 0; transform: translateY(8px) scale(0.975); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.support-panel-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 32px;
  column-gap: 12px;
  align-items: center;
  min-height: 72px;
  padding: 14px 16px 13px 18px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--card);
}

.support-panel-heading { min-width: 0; }
.support-panel-title { display: flex; min-width: 0; align-items: center; gap: 8px; }
.support-panel-title strong { display: block; font-size: 16px; line-height: 1.35; }
.support-panel-heading > small { display: block; margin-top: 2px; overflow: hidden; color: var(--text-3); font-size: 12px; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; }
.support-official-badge {
  display: inline-flex;
  height: 20px;
  padding: 0 7px;
  flex: 0 0 auto;
  align-items: center;
  border: 1px solid #c9d9fa;
  border-radius: 6px;
  color: var(--blue-deep);
  background: var(--blue-wash);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.support-close,
.support-back {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 10px;
  color: var(--text-3);
  background: transparent;
  cursor: pointer;
}

.support-close .icon,
.support-back .icon { display: block; width: 18px; height: 18px; }
.support-back .icon { transform: rotate(180deg); }

.support-close:hover,
.support-back:hover { color: var(--text-1); background: var(--blue-wash); }

.support-live,
.support-peer {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-3);
  font-size: 12px;
  white-space: nowrap;
}

.support-live i,
.support-peer i {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #a8b1c1;
}

.support-live.online,
.support-peer.online { color: var(--ok); }
.support-live.online i,
.support-peer.online i { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-wash); }

.support-panel-body,
.support-list-view,
.support-thread-view { min-height: 0; flex: 1; }

.support-panel-body { display: flex; overflow: hidden; }

.support-list-view {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.support-list-intro {
  padding: 13px 18px 10px;
  color: var(--text-2);
  font-size: 13px;
}

.support-list {
  display: flex;
  overflow-y: auto;
  padding: 0 12px 14px;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  scrollbar-width: thin;
}

.support-list-item {
  display: grid;
  width: 100%;
  padding: 13px 14px;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text-1);
  text-align: left;
  background: var(--card);
  cursor: pointer;
  transition: border-color var(--speed) var(--ease), background var(--speed) var(--ease), transform var(--speed) var(--ease);
}

.support-list-item.has-avatar { grid-template-columns: auto minmax(0, 1fr) auto; }

.support-chat-avatar {
  display: inline-flex;
  width: 30px;
  height: 30px;
  overflow: hidden;
  flex: none;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: #fff;
  background: var(--blue);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.07);
  font-size: 12px;
  font-weight: 750;
}

.support-chat-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.support-thread-avatar { width: 34px; height: 34px; border-radius: 10px; }

.support-list-item:hover {
  border-color: #b9cdf6;
  background: var(--blue-wash);
}

.support-list-copy { min-width: 0; }
.support-list-copy strong,
.support-list-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.support-list-copy strong { font-size: 14px; }
.support-list-copy small { margin-top: 2px; color: var(--text-3); font-size: 12px; }
.support-list-copy .support-preview { margin-top: 6px; color: var(--text-2); }

.support-list-meta {
  display: flex;
  align-items: flex-end;
  align-self: stretch;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.support-list-meta time { color: var(--text-3); font-size: 12px; }
.support-unread {
  display: grid;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--blue);
  font-size: 12px;
  font-weight: 750;
}

.support-state-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--text-3);
  font-size: 12px;
}
.support-state-pill i { width: 6px; height: 6px; border-radius: 50%; background: #a8b1c1; }
.support-state-pill.online { color: var(--ok); }
.support-state-pill.online i { background: var(--ok); }

.support-empty {
  display: grid;
  min-height: 230px;
  padding: 34px 26px;
  place-content: center;
  text-align: center;
}
.support-empty-mark {
  display: grid;
  width: 48px;
  height: 48px;
  margin: 0 auto 12px;
  place-items: center;
  border-radius: 16px;
  color: var(--blue);
  background: var(--blue-wash);
}
.support-empty-mark .icon { width: 22px; height: 22px; }
.support-empty strong { font-size: 14px; }
.support-empty p { max-width: 260px; margin-top: 4px; color: var(--text-3); font-size: 12px; }

.support-thread-view {
  display: flex;
  overflow: hidden;
  flex-direction: column;
}

.support-thread-top {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 58px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line-soft);
}
.support-thread-title { min-width: 0; }
.support-thread-title strong { display: block; overflow: hidden; font-size: 14px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.support-thread-title .support-peer { margin-top: 2px; }

.support-order-card {
  margin: 10px 14px;
  padding: 11px 13px;
  border: 1px solid #dbe6f8;
  border-radius: 12px;
  background: var(--blue-wash);
}
.support-order-main { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.support-order-main strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.support-order-main b { color: var(--blue-deep); font-size: 13px; white-space: nowrap; }
.support-order-sub { display: flex; gap: 7px; margin-top: 3px; color: var(--text-3); font-size: 12px; }
.support-order-sub code { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.support-messages {
  display: flex;
  overflow-y: auto;
  padding: 12px 14px 16px;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  background: var(--bg-soft);
  scrollbar-width: thin;
}

.support-message { display: flex; align-items: flex-start; gap: 9px; }
.support-message.mine { justify-content: flex-end; }
.support-message-stack {
  display: flex;
  min-width: 0;
  max-width: 78%;
  flex-direction: column;
  align-items: flex-start;
}
.support-message.mine .support-message-stack { align-items: flex-end; }
.support-message > .support-chat-avatar {
  width: 36px;
  height: 36px;
  margin-top: 18px;
  border-radius: 10px;
}
.support-message-author { height: 15px; margin: 0 2px 3px; color: var(--text-3); font-size: 12px; line-height: 15px; }
.support-message.mine .support-message-author { text-align: right; }
.support-message-bubble {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 6px 14px 14px 14px;
  color: var(--text-1);
  background: var(--card);
  font-size: 13px;
  line-height: 20px;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.support-message.mine .support-message-bubble {
  border-color: transparent;
  border-radius: 14px 6px 14px 14px;
  color: #fff;
  background: var(--blue);
}

.support-message-image {
  display: flex;
  max-width: 240px;
  padding: 0;
  overflow: hidden;
  flex-direction: column;
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text-1);
  text-align: left;
  background: var(--card);
  cursor: zoom-in;
}
.support-message.mine .support-message-image { border-color: #bfd1f8; }
.support-message-image img {
  display: block;
  width: auto;
  min-width: 120px;
  max-width: 100%;
  max-height: 280px;
  object-fit: contain;
  background: var(--line-soft);
}
.support-message-image-caption {
  display: block;
  padding: 8px 10px;
  overflow-wrap: anywhere;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
}
.support-message-image.is-error {
  min-width: 140px;
  padding: 18px;
  color: var(--text-3);
  text-align: center;
  cursor: default;
}
.support-message-meta { min-height: 15px; margin: 3px 2px 0; color: var(--text-3); font-size: 12px; line-height: 15px; }
.support-message.mine .support-message-meta { text-align: right; }
.support-read.is-read { color: var(--blue-deep); }

.support-message-empty {
  margin: auto;
  padding: 20px;
  color: var(--text-3);
  text-align: center;
  font-size: 12px;
}

.support-error {
  margin: 0 14px 8px;
  padding: 8px 10px;
  border-radius: 10px;
  color: var(--bad);
  background: var(--bad-wash);
  font-size: 12px;
}

.support-compose {
  display: grid;
  padding: 12px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border-top: 1px solid var(--line-soft);
  background: var(--card);
}
.support-compose textarea {
  width: 100%;
  min-height: 40px;
  max-height: 110px;
  padding: 9px 11px;
  resize: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--text-1);
  background: var(--bg-soft);
  font-size: 13px;
  line-height: 1.5;
}
.support-compose textarea:focus { outline: none; border-color: var(--blue-light); box-shadow: var(--ring-focus); }
.support-compose button {
  display: grid;
  height: 40px;
  padding: 0 15px;
  place-items: center;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--blue);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}
.support-compose button:hover { background: var(--blue-deep); }
.support-compose button:disabled { opacity: 0.55; cursor: wait; }

.support-compose .support-image-button {
  width: 40px;
  padding: 0;
  align-self: end;
  border: 1px solid var(--line);
  color: var(--text-2);
  background: var(--bg-soft);
}
.support-compose .support-image-button:hover { color: var(--blue); border-color: var(--blue-light); background: var(--blue-wash); }
.support-image-button .icon { display: block; width: 21px; height: 21px; stroke-width: 1.65; }

.support-image-draft {
  display: grid;
  min-width: 0;
  padding: 7px;
  grid-column: 1 / -1;
  grid-template-columns: 44px minmax(0, 1fr) 30px;
  gap: 9px;
  align-items: center;
  border: 1px solid #cddcf8;
  border-radius: 10px;
  background: var(--blue-wash);
}
.support-image-draft[hidden] { display: none; }
.support-image-draft img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: var(--line-soft); }
.support-image-draft > span { min-width: 0; }
.support-image-draft strong,
.support-image-draft small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.support-image-draft strong { font-size: 12px; }
.support-image-draft small { margin-top: 2px; color: var(--text-3); font-size: 12px; }
.support-compose .support-image-draft button {
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  color: var(--text-3);
  background: transparent;
}
.support-image-draft button .icon { display: block; width: 16px; height: 16px; }
.support-compose .support-image-draft button:hover { color: var(--bad); background: var(--bad-wash); }

body.support-image-viewer-open { overflow: hidden; }
.support-image-viewer {
  position: fixed;
  inset: 0;
  z-index: 980;
  display: grid;
  padding: 24px;
  place-items: center;
  background: rgba(7, 12, 23, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.support-image-viewer-frame { position: relative; display: grid; max-width: 94vw; max-height: 90dvh; place-items: center; }
.support-image-viewer img { display: block; max-width: 94vw; max-height: 90dvh; border-radius: 12px; object-fit: contain; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.4); }
.support-image-viewer-close {
  position: absolute;
  top: -16px;
  right: -16px;
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  color: #fff;
  background: rgba(15, 23, 42, 0.84);
  font-size: 24px;
  cursor: pointer;
}

html[data-theme="dark"] .support-chat-panel { border-color: #2a3548; }
html[data-theme="dark"] .support-list-item:hover { border-color: #38527d; }
html[data-theme="dark"] .support-order-card { border-color: #29446f; }
html[data-theme="dark"] .support-message.mine .support-message-bubble { color: #fff; background: #3268da; }
html[data-theme="dark"] .support-read.is-read { color: #86afff; }
html[data-theme="dark"] .support-image-draft { border-color: #29446f; }

@media (max-width: 620px) {
  body.support-chat-open { overflow: hidden; }
  .support-widget { right: 16px; bottom: 16px; }
  .support-orb { width: 46px; height: 46px; }
  /* 悬浮客服钮固定在右下角：页面底部留出它的高度，最后一张卡能滚到它上面，不被盖住 */
  .app-main { padding-bottom: 96px; }
  .support-widget.is-open .support-orb {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.9);
  }
  .support-orb-label { display: none; }
  .support-chat-panel {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100dvh;
    min-height: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
  .support-panel-head {
    min-height: calc(66px + env(safe-area-inset-top, 0px));
    padding-top: calc(14px + env(safe-area-inset-top, 0px));
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(14px, env(safe-area-inset-right, 0px));
  }
  .support-messages { overscroll-behavior: contain; }
  .support-compose {
    padding-right: max(12px, env(safe-area-inset-right, 0px));
    padding-bottom: calc(11px + env(safe-area-inset-bottom, 0px));
    padding-left: max(12px, env(safe-area-inset-left, 0px));
  }
  .support-message-image { max-width: min(240px, 72vw); }
  .support-image-viewer { padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
  .support-message-stack { max-width: 84%; }
}

@media (prefers-reduced-motion: reduce) {
  .support-chat-panel { animation: none; }
  .support-orb,
  .support-list-item { transition: none; }
}

/* ------------------------------------------------ QQ 内置浏览器引导 */
.qq-browser-page {
  min-height: 100vh;
  min-height: 100dvh;
  color: #172033;
  background:
    #f4f6fa;
}

.qq-browser-guide {
  display: flex;
  width: min(100%, 520px);
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  padding: max(24px, env(safe-area-inset-top, 0px)) 20px max(28px, env(safe-area-inset-bottom, 0px));
  flex-direction: column;
  justify-content: center;
}

.qq-guide-brand {
  display: flex;
  margin: 0 auto 18px;
  align-items: center;
  gap: 9px;
  color: #26334d;
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.02em;
}

.qq-guide-brand > span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 10px;
  color: #fff;
  background: var(--blue);
  box-shadow: var(--shadow-card);
  font-size: 15px;
  font-weight: 800;
}

.qq-guide-card {
  padding: 32px 30px 28px;
  text-align: center;
  border: 1px solid rgba(204, 216, 238, 0.9);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 22px 60px rgba(38, 59, 98, 0.11), 0 2px 8px rgba(38, 59, 98, 0.05);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.qq-guide-visual {
  position: relative;
  width: 126px;
  height: 116px;
  margin: 0 auto 18px;
}

.qq-guide-phone {
  position: absolute;
  left: 13px;
  bottom: 0;
  width: 91px;
  height: 111px;
  overflow: hidden;
  border: 5px solid #18233a;
  border-radius: 16px;
  background: #edf3ff;
  box-shadow: 0 15px 28px rgba(30, 61, 119, 0.18);
}

.qq-guide-phone::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  width: 34px;
  height: 8px;
  border-radius: 0 0 7px 7px;
  background: #18233a;
  transform: translateX(-50%);
}

.qq-guide-phone-bar {
  display: flex;
  height: 29px;
  padding: 13px 8px 0;
  justify-content: flex-end;
  gap: 3px;
  background: #fff;
  border-bottom: 1px solid #dfe7f5;
}

.qq-guide-phone-bar i {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #64748b;
}

.qq-guide-browser-mark {
  position: relative;
  width: 48px;
  height: 48px;
  margin: 17px auto 0;
  border-radius: 50%;
  background: #2563eb;
}

.qq-guide-browser-mark span {
  position: absolute;
  top: 10px;
  left: 20px;
  width: 8px;
  height: 28px;
  border-radius: 6px;
  background: #fff;
  transform: rotate(43deg);
}

.qq-guide-browser-mark b {
  position: absolute;
  top: 18px;
  left: 18px;
  width: 12px;
  height: 12px;
  border: 3px solid #fff;
  border-radius: 50%;
}

.qq-guide-menu-hint {
  position: absolute;
  top: 0;
  right: 0;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid #cfdcf4;
  border-radius: 16px;
  color: var(--blue);
  background: #fff;
  box-shadow: 0 10px 24px rgba(30, 61, 119, 0.15);
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

.qq-guide-menu-hint::after {
  content: "";
  position: absolute;
  right: 34px;
  bottom: -12px;
  width: 26px;
  height: 26px;
  border: solid var(--blue);
  border-width: 0 0 2px 2px;
  border-radius: 0 0 0 18px;
  transform: rotate(15deg);
}

.qq-guide-eyebrow {
  margin-bottom: 6px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.qq-guide-card h1 {
  font-size: clamp(25px, 7vw, 31px);
  line-height: 1.25;
  letter-spacing: -0.035em;
}

.qq-guide-lead {
  max-width: 360px;
  margin: 12px auto 22px;
  color: #647089;
  font-size: 14px;
  line-height: 1.75;
}

.qq-guide-steps {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 9px;
  list-style: none;
  text-align: left;
}

.qq-guide-steps li {
  display: flex;
  min-height: 50px;
  padding: 11px 14px;
  align-items: center;
  gap: 12px;
  border: 1px solid #e1e8f4;
  border-radius: 12px;
  background: #f8faff;
}

.qq-guide-steps li > span {
  display: grid;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  color: var(--blue);
  background: #e8f0ff;
  font-size: 13px;
  font-weight: 800;
}

.qq-guide-steps p { color: #4a5872; font-size: 14px; }
.qq-guide-steps strong { color: #172033; }

.qq-guide-divider {
  display: flex;
  margin: 19px 0 15px;
  align-items: center;
  gap: 12px;
  color: #98a3b7;
  font-size: 12px;
}

.qq-guide-divider::before,
.qq-guide-divider::after { content: ""; height: 1px; flex: 1; background: #e7ecf5; }

.qq-guide-copy {
  display: flex;
  width: 100%;
  height: 48px;
  padding: 0 18px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: var(--blue);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--speed) var(--ease), box-shadow var(--speed) var(--ease);
}

.qq-guide-copy:active { transform: scale(0.985); }
.qq-guide-copy .icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.qq-guide-copy.copy-failed { background: var(--bad); }
.qq-guide-footnote { margin-top: 11px; color: #8a96ac; font-size: 12px; }

@media (max-width: 420px) {
  .qq-browser-guide { padding-right: 14px; padding-left: 14px; }
  .qq-guide-card { padding: 27px 20px 23px; border-radius: 21px; }
  .qq-guide-visual { transform: scale(0.92); margin-bottom: 10px; }
}

@media (max-height: 680px) {
  .qq-browser-guide { justify-content: flex-start; }
  .qq-guide-brand { margin-bottom: 12px; }
  .qq-guide-card { padding-top: 22px; }
  .qq-guide-visual { height: 94px; transform: scale(0.8); transform-origin: center top; margin-bottom: -4px; }
}

/* ------------------------------------------------ 21 余额与充值
   余额是全站通用的钱：左边一张余额卡（大数字），右边充值表单（金额档位 + 自定义 + 支付方式），下面是流水 */
.pay-confirm-head.balance,
.pay-submit.balance { background: var(--blue); }

.pay-methods { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pay-method.balance .icon { width: 20px; height: 20px; color: var(--blue); }
.pay-method span { display: grid; line-height: 1.25; text-align: left; }
.pay-method small { font-size: 12px; font-weight: 400; color: var(--text-3); }
.pay-method:disabled { cursor: not-allowed; opacity: 0.5; background: var(--bg-soft); }

.wallet-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 16px;
  align-items: stretch;
}

.wallet-grid > .panel { margin-top: 0; }

.wallet-balance { display: flex; flex-direction: column; gap: 10px; }

.wallet-amount {
  font-size: 38px;
  font-weight: 700;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.recharge-form { display: grid; gap: 16px; }

.amount-chips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.amount-chip { position: relative; cursor: pointer; }
.amount-chip > input[type="radio"] { position: absolute; opacity: 0; pointer-events: none; }

.amount-chip > span {
  display: grid;
  place-items: center;
  min-height: 48px;
  padding: 0 10px;
  border-radius: var(--r-md);
  border: 1px solid var(--control);
  background: var(--card);
  transition: background var(--speed), border-color var(--speed);
}

.amount-chip b { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.amount-chip:hover > span { background: var(--bg-soft); }
.amount-chip > input:checked + span { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); background: var(--blue-wash); }
.amount-chip > input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }

.amount-chip.is-custom .custom-amount {
  min-height: 0;
  border: 0;
  padding: 0;
  background: none;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  box-shadow: none;
}

.recharge-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.pay-type-choice { display: inline-flex; gap: 6px; }
.pay-type-choice label { position: relative; cursor: pointer; }
.pay-type-choice input { position: absolute; opacity: 0; pointer-events: none; }

.pay-type-choice span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--control);
  font-size: 14px;
  font-weight: 600;
  background: var(--card);
}

.pay-type-choice input:checked + span { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); background: var(--blue-wash); }
.pay-type-choice input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }

.wallet-table .num-col { text-align: right; font-variant-numeric: tabular-nums; }
.wallet-table td.num-col { color: var(--text-1); }
.wallet-table td.is-in { color: var(--ok); }

/* 侧栏小卡下面那行：进服额度数字加粗 */
.plan-brief-row > span b { font-weight: 600; color: var(--text-1); }

@media (max-width: 900px) {
  .wallet-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 560px) {
  .pay-methods { grid-template-columns: minmax(0, 1fr); }
  .amount-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ------------------------------------------------ 22 插件市场
   封面 = 纯色底 + 插件在游戏里真实显示的那一块（网易 § 颜色码），文字按封面宽度等比缩放（cqw），
   窄卡和大图比例一致、不折行。颜色全部走类名，不写内联 style（CSP 禁止）。 */
.pv {
  position: relative;
  display: grid;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  container-type: inline-size;
  font-family: var(--font);
  font-weight: 600;
  line-height: 1.35;
}

.pv > * { white-space: nowrap; }
.pv-night { background: #1c2333; }
.pv-dusk { background: #2b2433; }
.pv-moss { background: #1e2b25; }
.pv-plum { background: #29223a; }
.pv-ember { background: #2d2224; }
.pv-slate { background: #24282f; }

.mc-sidebar { justify-self: end; align-self: center; margin-right: 8%; min-width: 42%; background: rgba(0, 0, 0, 0.42); padding: 1.4cqw 0 2cqw; font-size: 4.3cqw; }
.mc-sb-title { text-align: center; padding: 0 3cqw 1cqw; }
.mc-sb-row { display: flex; justify-content: space-between; gap: 4cqw; padding: 0 2cqw 0 3cqw; }
.mc-chat { align-self: end; margin: 0 0 8% 4%; display: grid; gap: 0.6cqw; justify-items: start; font-size: 3.9cqw; }
.mc-line { background: rgba(0, 0, 0, 0.42); padding: 0.3cqw 2cqw; }
.mc-actionbar { align-self: end; justify-self: center; margin-bottom: 13%; font-size: 4.1cqw; }
.mc-title { align-self: center; justify-self: center; text-align: center; }
.mc-t1 { font-size: 9.6cqw; font-weight: 700; }
.mc-t2 { font-size: 4.3cqw; margin-top: 1.2cqw; }
.pv-icon { align-self: center; justify-self: center; width: 22cqw; height: 22cqw; object-fit: contain; image-rendering: pixelated; }

/* 网易 / MC 的文字阴影：同色 25% 亮度、右下偏移，这是游戏本来的样子，不是发光 */
.mc-0 { color: #000000; text-shadow: 1px 1px 0 #000000; }
.mc-1 { color: #0000aa; text-shadow: 1px 1px 0 #00002a; }
.mc-2 { color: #00aa00; text-shadow: 1px 1px 0 #002a00; }
.mc-3 { color: #00aaaa; text-shadow: 1px 1px 0 #002a2a; }
.mc-4 { color: #aa0000; text-shadow: 1px 1px 0 #2a0000; }
.mc-5 { color: #aa00aa; text-shadow: 1px 1px 0 #2a002a; }
.mc-6 { color: #ffaa00; text-shadow: 1px 1px 0 #3f2a00; }
.mc-7 { color: #aaaaaa; text-shadow: 1px 1px 0 #2a2a2a; }
.mc-8 { color: #555555; text-shadow: 1px 1px 0 #151515; }
.mc-9 { color: #5555ff; text-shadow: 1px 1px 0 #15153f; }
.mc-a { color: #55ff55; text-shadow: 1px 1px 0 #153f15; }
.mc-b { color: #55ffff; text-shadow: 1px 1px 0 #153f3f; }
.mc-c { color: #ff5555; text-shadow: 1px 1px 0 #3f1515; }
.mc-d { color: #ff55ff; text-shadow: 1px 1px 0 #3f153f; }
.mc-e { color: #ffff55; text-shadow: 1px 1px 0 #3f3f15; }
.mc-f { color: #ffffff; text-shadow: 1px 1px 0 #3f3f3f; }
/* 基岩版多出来的矿物色（网易同样认） */
.mc-g { color: #ddd605; text-shadow: 1px 1px 0 #373501; }
.mc-h { color: #e3d4d1; text-shadow: 1px 1px 0 #383534; }
.mc-i { color: #cecaca; text-shadow: 1px 1px 0 #333232; }
.mc-j { color: #443a3b; text-shadow: 1px 1px 0 #110e0e; }
.mc-m { color: #971607; text-shadow: 1px 1px 0 #250501; }
.mc-n { color: #b4684d; text-shadow: 1px 1px 0 #2d1a13; }
.mc-p { color: #deb12d; text-shadow: 1px 1px 0 #372c0b; }
.mc-q { color: #47a036; text-shadow: 1px 1px 0 #11280d; }
.mc-s { color: #2cbaa8; text-shadow: 1px 1px 0 #0b2e2a; }
.mc-t { color: #21497b; text-shadow: 1px 1px 0 #08121e; }
.mc-u { color: #9a5cc6; text-shadow: 1px 1px 0 #261731; }
.mc-l { font-weight: 700; }
/* ࡀ 在网易里是一格实心块，连着无缝（侧边栏流光条） */
.mc-blk { display: inline-flex; vertical-align: -0.1em; }
.mc-blk i { width: 0.7em; height: 0.95em; background: currentColor; }

.plugin-thumb { display: inline-grid; place-items: center; flex: none; overflow: hidden; border-radius: 8px; color: #fff; font-size: 16px; }
.plugin-thumb.thumb-36 { width: 36px; height: 36px; }
.plugin-thumb.thumb-40 { width: 40px; height: 40px; }
.plugin-thumb img { width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; }
.plugin-name { display: flex; align-items: center; gap: 12px; }
.plugin-name small { display: block; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 7px;
  border-radius: 6px;
  background: var(--bg-soft);
  color: var(--text-2);
  font-size: 12px;
  white-space: nowrap;
  flex: none;
}

.tag .icon { width: 12px; height: 12px; }
.tag-warn { background: var(--warn-wash); color: var(--warn); }
.official { color: var(--blue-ink); font-weight: 600; }
.price { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price.is-free { color: var(--ok); }

.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 16px;
}

.store-grid > .panel { margin-top: 0; }

.pcard { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.pcard-cover .pv { border-radius: 0; }
.pcard-body { display: grid; flex: 1; align-content: start; gap: 6px; padding: 14px 16px 16px; }
.pcard-title { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pcard-title b { font-size: 15px; font-weight: 600; }
.pcard-title a:hover b { color: var(--blue-ink); }
.pcard-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12px; color: var(--text-3); }
.pcard-blurb { margin: 0; font-size: 13px; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pcard-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 6px; }
.pcard-tags { display: flex; flex-wrap: wrap; gap: 6px; }

.feature { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); padding: 0; overflow: hidden; }
.feature .pv { height: 100%; aspect-ratio: auto; min-height: 280px; }
.feature-body { display: grid; align-content: center; gap: 12px; padding: 28px 32px; }
.feature-kicker { font-size: 13px; color: var(--text-3); }
.feature-body h2 { margin: 0; font-size: 24px; font-weight: 700; }
.feature-body p { margin: 0; color: var(--text-2); }
.feature-facts { display: flex; gap: 24px; font-size: 13px; color: var(--text-3); }
.feature-facts b { display: block; color: var(--text-1); font-size: 18px; font-weight: 600; }
.feature-buy { display: flex; align-items: center; gap: 12px; margin-top: 4px; }
.feature-buy .big { font-size: 24px; font-weight: 700; font-variant-numeric: tabular-nums; }
.faint { font-size: 12px; color: var(--text-3); }

.tabs { display: flex; gap: 22px; overflow-x: auto; border-bottom: 1px solid var(--line); }
.tab { padding: 10px 0; margin-bottom: -1px; border-bottom: 2px solid transparent; font-size: 14px; color: var(--text-2); white-space: nowrap; }
.tab:hover { color: var(--text-1); }
.tab.is-on { color: var(--text-1); font-weight: 600; border-bottom-color: var(--blue); }
.tab small { margin-left: 4px; font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }

.crumb { display: flex; gap: 6px; font-size: 13px; color: var(--text-3); margin-bottom: 6px; }
.crumb a { color: var(--text-2); }
.crumb a:hover { color: var(--blue-ink); }

.detail-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.detail-main, .detail-side { display: grid; gap: 16px; min-width: 0; }
.detail-main > .panel, .detail-side > .panel { margin-top: 0; }
.detail-cover { padding: 0; overflow: hidden; }
.detail-cover .pv { border-radius: 0; }
.readme h3 { margin: 14px 0 6px; font-size: 15px; }
.readme p { margin: 0 0 8px; color: var(--text-2); }
.readme ul { margin: 0 0 8px; padding-left: 20px; color: var(--text-2); }
.version-list { display: grid; margin: 0; padding: 0; list-style: none; }
.version-list li { display: grid; grid-template-columns: 90px 1fr auto; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-soft); font-size: 14px; }
.version-list li:first-child { border-top: 0; padding-top: 0; }
.version-list span, .version-list small { color: var(--text-3); }
.buy-card { display: grid; gap: 14px; position: sticky; top: 20px; }
.buy-price b { display: block; font-size: 30px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; }
.buy-price span { font-size: 13px; color: var(--text-3); }
.buy-note { display: flex; align-items: center; gap: 6px; margin: -6px 0 0; font-size: 13px; color: var(--text-2); }
.buy-note a { color: var(--blue-ink); }
.buy-note .icon { width: 16px; height: 16px; }
.buy-note.is-ok { color: var(--ok); margin: 0; }
.buy-note.is-warn { color: var(--warn); margin: 0; }
.ghost-button.wide { width: 100%; }
.primary-button:disabled { opacity: 0.5; cursor: not-allowed; }
.kv-list { display: grid; gap: 8px; margin: 0; padding-top: 12px; border-top: 1px solid var(--line-soft); }
.kv-list div { display: flex; justify-content: space-between; font-size: 14px; }
.kv-list dt { color: var(--text-3); }
.kv-list dd { margin: 0; font-weight: 500; }
.report-link { display: inline-flex; align-items: center; gap: 6px; justify-self: start; color: var(--text-3); font-weight: 500; }
.report-link .icon { width: 15px; height: 15px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; }

.kpi-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 0; }
.kpi-strip > div { display: grid; gap: 4px; align-content: start; padding: 18px 20px; }
.kpi-strip > div + div { border-left: 1px solid var(--line-soft); }
.kpi-strip small { font-size: 13px; color: var(--text-2); }
.kpi-strip b { font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.kpi-strip b.lead { font-size: 30px; font-weight: 700; }
.kpi-strip p { margin: 0; font-size: 12px; color: var(--text-3); }
.author-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.author-grid > .panel { margin-top: 0; }
.plugin-upload { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.plugin-upload input[type="file"] { flex: 1 1 240px; }
.rule-list { margin: 14px 0 0; padding-left: 18px; display: grid; gap: 4px; font-size: 13px; color: var(--text-2); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.data-table .num-col { text-align: right; }
.data-table td.is-in { color: var(--ok); }
.data-table small.is-err { color: var(--bad); }
.withdraw-actions { display: grid; gap: 6px; }
.withdraw-actions form { display: flex; gap: 6px; align-items: center; }
.withdraw-actions input { min-height: 30px; padding: 4px 8px; font-size: 13px; }

@media (max-width: 1100px) {
  .store-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature, .detail-grid, .author-grid { grid-template-columns: minmax(0, 1fr); }
  .feature .pv { min-height: 0; aspect-ratio: 16 / 9; }
  .buy-card { position: static; }
}

@media (max-width: 620px) {
  .store-grid { grid-template-columns: minmax(0, 1fr); }
  .kpi-strip { grid-template-columns: 1fr 1fr; }
  .kpi-strip > div:nth-child(3) { border-left: 0; }
  .kpi-strip > div:nth-child(n + 3) { border-top: 1px solid var(--line-soft); }
  .form-row { grid-template-columns: minmax(0, 1fr); }
  .feature-body { padding: 20px; }
  .feature-facts { flex-wrap: wrap; }
}

/* 设置项里的彩色文本默认值：放在深色小条上按游戏颜色显示 */
.mc-inline { display: inline-block; padding: 2px 8px; border-radius: 4px; background: #1c2333; font-weight: 600; white-space: nowrap; }

/* 总览：钱包卡 + 最近上新 */
.ov-wallet { display: flex; flex-direction: column; gap: 14px; }
.ov-wallet .panel-head { margin-bottom: 0; }
.ov-wallet-lead small, .ov-wallet-row small { display: block; font-size: 13px; color: var(--text-2); }
.ov-wallet-lead b { font-size: 30px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; }
.ov-wallet-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-top: 12px; border-top: 1px solid var(--line-soft); }
.ov-wallet-row b { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ov-wallet-row em { font-style: normal; font-size: 13px; font-weight: 400; color: var(--text-3); }
.ov-wallet-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: auto; }
.ov-split { align-items: stretch; }
.ov-plugins { display: grid; gap: 12px; }
.ov-sec-head { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; }
.ov-sec-head h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 16px; font-weight: 700; }
.ov-sec-head h2 .icon { width: 18px; height: 18px; color: var(--icon); }
.ov-plugin-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ov-plugin-grid > .panel { margin-top: 0; }
.ov-plugin { display: grid; gap: 4px; padding: 0 0 14px; overflow: hidden; }
.ov-plugin .pv { margin-bottom: 8px; }
.ov-plugin-body { display: flex; justify-content: space-between; gap: 8px; padding: 0 14px; }
.ov-plugin-body b { font-size: 14px; font-weight: 600; }
.ov-plugin small { padding: 0 14px; font-size: 12px; color: var(--text-3); }
.ov-plugin:hover b { color: var(--blue-ink); }
@media (max-width: 1100px) { .ov-plugin-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ------------------------------------------------ 23 插件网页设置（按「配置」声明画出来的表单） */
.cfg-form { display: grid; gap: 18px; }
.cfg-group { margin: 0; padding: 0; border: 0; min-width: 0; }
.cfg-group legend {
  padding: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}
.cfg-group + .cfg-group { padding-top: 4px; }
.cfg-row {
  display: grid;
  grid-template-columns: minmax(150px, 220px) minmax(0, 1fr);
  gap: 8px 24px;
  align-items: start;
  padding: 14px 0;
  border-top: 1px solid var(--line-soft);
}
.cfg-group .cfg-row:last-child { border-bottom: 1px solid var(--line-soft); }
.cfg-label { display: grid; gap: 4px; padding-top: 8px; }
.cfg-label b { font-size: 14px; font-weight: 600; color: var(--text-1); }
.cfg-label label { cursor: pointer; }
.cfg-label small { font-size: 13px; line-height: 1.5; color: var(--text-3); }
.cfg-control { display: grid; gap: 6px; min-width: 0; }
.cfg-control > input, .cfg-control > select, .cfg-control > textarea { max-width: 520px; }
.cfg-control textarea { font-family: var(--mono); font-size: 13px; }
.cfg-range { font-size: 12px; color: var(--text-3); }

.cfg-number { display: flex; align-items: center; gap: 8px; }
.cfg-number input { max-width: 160px; font-variant-numeric: tabular-nums; }
.cfg-number span { font-size: 14px; color: var(--text-2); }

.cfg-coord { display: flex; gap: 8px; flex-wrap: wrap; }
.cfg-coord label { display: flex; align-items: center; gap: 0; }
.cfg-coord label span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 38px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  background: var(--bg-soft);
  border: 1px solid var(--control);
  border-right: 0;
  border-radius: var(--r-md) 0 0 var(--r-md);
}
.cfg-coord input[type="number"] { width: 104px; border-radius: 0 var(--r-md) var(--r-md) 0; font-variant-numeric: tabular-nums; }

/* 开关：真正的复选框藏在轨道下面，键盘和读屏照常可用 */
.cfg-switch { position: relative; display: inline-flex; align-items: center; gap: 10px; min-height: 38px; cursor: pointer; width: max-content; }
.cfg-switch input { position: absolute; opacity: 0; width: 36px; height: 20px; margin: 0; cursor: pointer; }
.cfg-switch-track {
  position: relative;
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: var(--control);
  transition: background var(--speed);
}
.cfg-switch-track::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  transition: transform var(--speed);
}
.cfg-switch input:checked + .cfg-switch-track { background: var(--blue); }
.cfg-switch input:checked + .cfg-switch-track::after { transform: translateX(16px); }
.cfg-switch input:focus-visible + .cfg-switch-track { outline: 2px solid var(--blue); outline-offset: 2px; }
.cfg-switch-text { font-size: 14px; color: var(--text-2); }
.cfg-switch-text::after { content: attr(data-off); }
.cfg-switch input:checked ~ .cfg-switch-text::after { content: attr(data-on); }

/* 彩色文本：输入框 + 色板 + 游戏里的样子 */
.cfg-mc { display: grid; gap: 8px; max-width: 520px; }
.cfg-mc input { font-family: var(--mono); font-size: 13px; }
.cfg-palette { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.cfg-swatch {
  width: 20px;
  height: 20px;
  padding: 0;
  border: 1px solid rgba(0, 0, 0, 0.18);
  border-radius: 3px;
  cursor: pointer;
}
.cfg-swatch:hover, .cfg-swatch-text:hover { border-color: var(--blue); }
.cfg-swatch-text {
  height: 20px;
  min-width: 26px;
  padding: 0 6px;
  font: inherit;
  font-size: 12px;
  color: var(--text-2);
  background: var(--card);
  border: 1px solid var(--control);
  border-radius: 3px;
  cursor: pointer;
}
.cfg-mc-preview {
  min-height: 36px;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
  background: #1c2333;
  border-radius: var(--r-md);
}
.mc-bg-0 { background: #000000; } .mc-bg-1 { background: #0000aa; } .mc-bg-2 { background: #00aa00; } .mc-bg-3 { background: #00aaaa; }
.mc-bg-4 { background: #aa0000; } .mc-bg-5 { background: #aa00aa; } .mc-bg-6 { background: #ffaa00; } .mc-bg-7 { background: #aaaaaa; }
.mc-bg-8 { background: #555555; } .mc-bg-9 { background: #5555ff; } .mc-bg-a { background: #55ff55; } .mc-bg-b { background: #55ffff; }
.mc-bg-c { background: #ff5555; } .mc-bg-d { background: #ff55ff; } .mc-bg-e { background: #ffff55; } .mc-bg-f { background: #ffffff; }

.cfg-foot { display: flex; justify-content: flex-end; gap: 10px; }
.cfg-foot p { display: flex; align-items: center; gap: 8px; margin: 0; margin-right: auto; font-size: 13px; color: var(--text-3); }
.cfg-foot p .icon { width: 16px; height: 16px; flex: none; }

/* 作者中心 · 设置界面预览：左边写声明，右边看效果 */
.cfg-workbench { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 20px; align-items: start; }
.cfg-workbench > .panel { margin-top: 0; }
.code-input { font-family: var(--mono); font-size: 13px; line-height: 1.6; white-space: pre; overflow-x: auto; }
.cfg-types { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line-soft); }
.cfg-types h3 { margin: 0 0 8px; font-size: 14px; font-weight: 700; }
.cfg-types dl { display: grid; gap: 6px; margin: 0 0 10px; }
.cfg-types dl div { display: grid; grid-template-columns: 76px 1fr; gap: 8px; font-size: 13px; }
.cfg-types dt { font-weight: 600; color: var(--text-1); }
.cfg-types dd { margin: 0; color: var(--text-2); }
.cfg-workbench .cfg-row { grid-template-columns: minmax(120px, 170px) minmax(0, 1fr); }

@media (max-width: 1100px) {
  .cfg-workbench { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .cfg-row, .cfg-workbench .cfg-row { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .cfg-label { padding-top: 0; }
  .cfg-coord { flex-wrap: nowrap; }
  .cfg-coord label { flex: 1; min-width: 0; }
  .cfg-coord input[type="number"] { width: 100%; min-width: 0; }
  .cfg-foot { flex-wrap: wrap; }
}

/* ------------------------------------------------ 24 开发者等级 */
.author-with-level { display: inline-flex; align-items: center; gap: 6px; }
.dev-level {
  display: inline-flex;
  align-items: center;
  height: 18px;
  padding: 0 5px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--text-2);
  border: 1px solid var(--line);
  border-radius: 3px;
}
.dev-level.lv-2 { color: var(--blue-ink); border-color: var(--blue); }
.dev-level.lv-3 { color: #fff; background: var(--blue); border-color: var(--blue); }

.lv-ladder { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0 0 16px; padding: 0; list-style: none; }
.lv-ladder li { display: grid; gap: 10px; padding: 14px 16px; border: 1px solid var(--line-soft); border-radius: var(--r-md); }
.lv-ladder li.is-current { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); }
.lv-ladder li.is-passed { background: var(--bg-soft); }
.lv-head { display: flex; align-items: baseline; gap: 8px; }
.lv-head b { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.lv-head span { font-size: 14px; color: var(--text-2); }
.lv-head em { margin-left: auto; font-style: normal; font-size: 12px; font-weight: 600; color: var(--blue-ink); }
.lv-ladder dl { display: grid; gap: 4px; margin: 0; }
.lv-ladder dl div { display: flex; justify-content: space-between; font-size: 13px; }
.lv-ladder dt { color: var(--text-3); }
.lv-ladder dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.lv-ladder small { font-size: 12px; color: var(--text-3); }
.lv-progress { display: grid; gap: 8px; }
.lv-progress-text { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--text-2); }
.lv-progress-text b { color: var(--text-1); font-variant-numeric: tabular-nums; }
.lv-bar { height: 6px; overflow: hidden; background: var(--bg-soft); border-radius: 3px; }
.lv-bar i { display: block; height: 100%; background: var(--blue); }
.lv-bar i.w-0 { width: 0%; }
.lv-bar i.w-5 { width: 5%; }
.lv-bar i.w-10 { width: 10%; }
.lv-bar i.w-15 { width: 15%; }
.lv-bar i.w-20 { width: 20%; }
.lv-bar i.w-25 { width: 25%; }
.lv-bar i.w-30 { width: 30%; }
.lv-bar i.w-35 { width: 35%; }
.lv-bar i.w-40 { width: 40%; }
.lv-bar i.w-45 { width: 45%; }
.lv-bar i.w-50 { width: 50%; }
.lv-bar i.w-55 { width: 55%; }
.lv-bar i.w-60 { width: 60%; }
.lv-bar i.w-65 { width: 65%; }
.lv-bar i.w-70 { width: 70%; }
.lv-bar i.w-75 { width: 75%; }
.lv-bar i.w-80 { width: 80%; }
.lv-bar i.w-85 { width: 85%; }
.lv-bar i.w-90 { width: 90%; }
.lv-bar i.w-95 { width: 95%; }
.lv-bar i.w-100 { width: 100%; }
@media (max-width: 720px) { .lv-ladder { grid-template-columns: minmax(0, 1fr); } }
.lv-set { flex-wrap: nowrap; }
.lv-set select { width: auto; min-width: 200px; }

/* ------------------------------------------------ 25 插件实例 */
.mono { font-family: var(--mono); font-size: 13px; }
.is-new { color: var(--blue-ink); font-weight: 600; }

.inst-specs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.inst-spec { display: grid; gap: 14px; padding: 18px; border: 1px solid var(--line-soft); border-radius: var(--r-md); }
.inst-spec.is-pick { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); }
.inst-spec-head { display: flex; align-items: baseline; gap: 8px; }
.inst-spec-head b { font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
.inst-spec-head span { font-size: 14px; color: var(--text-2); }
.inst-spec-facts { display: grid; gap: 6px; margin: 0; }
.inst-spec-facts div { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; }
.inst-spec-facts dt { color: var(--text-3); }
.inst-spec-facts dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
.inst-spec-facts dd small { display: block; font-size: 12px; font-weight: 400; color: var(--text-3); }
.inst-spec-buy { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.inst-spec-buy .buy-button { justify-content: center; }

.inst-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 20px; align-items: start; }
.inst-grid > .panel { margin-top: 0; }
.inst-state { font-size: 20px; }
.inst-run { display: flex; gap: 10px; flex-wrap: wrap; }
.inst-renew { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line-soft); }
.inst-renew h3 { margin: 0 0 10px; font-size: 14px; font-weight: 700; }
.inst-renew-buy { display: flex; gap: 8px; flex-wrap: wrap; }

.inst-plugins { display: grid; margin: 0 0 16px; padding: 0; list-style: none; }
.inst-plugin { border-top: 1px solid var(--line-soft); }
.inst-plugin:last-child { border-bottom: 1px solid var(--line-soft); }
.inst-plugin.is-off .plugin-name { opacity: 0.55; }
.inst-plugin-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; }
.inst-plugin-row .row-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.inst-plugin-row .chip-button.is-on { color: var(--blue-ink); border-color: var(--blue); }
.inst-plugin-config { padding: 4px 0 18px; }
.inst-install { display: flex; gap: 10px; align-items: center; }
.inst-install select { max-width: 360px; }

@media (max-width: 1100px) {
  .inst-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .inst-specs { grid-template-columns: minmax(0, 1fr); }
  .inst-plugin-row { flex-direction: column; align-items: flex-start; }
  .inst-plugin-row .row-actions { justify-content: flex-start; }
  .inst-install { flex-direction: column; align-items: stretch; }
  .inst-install select { max-width: none; }
}
.inst-plugin .plugin-name small { margin-top: 2px; font-size: 12px; color: var(--text-3); }
.inst-no-config { align-self: center; padding: 0 4px; }
/* 实例里每个插件的开关：一个提交按钮画成开关样式，点一下就切换（没有 JS 也能用） */
.inst-toggle-form { display: inline-flex; }
.inst-toggle {
  display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 10px 0 6px;
  font: inherit; font-size: 13px; font-weight: 600; color: var(--text-2);
  background: var(--card); border: 1px solid var(--control); border-radius: var(--r-md); cursor: pointer;
}
.inst-toggle-track { position: relative; width: 30px; height: 18px; border-radius: 9px; background: var(--control); transition: background var(--speed); }
.inst-toggle-track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform var(--speed); }
.inst-toggle.is-on { color: var(--blue-ink); border-color: var(--blue); }
.inst-toggle.is-on .inst-toggle-track { background: var(--blue); }
.inst-toggle.is-on .inst-toggle-track::after { transform: translateX(12px); }
.inst-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

/* 实例终端：左栏「运行」下面，自动拉到和右边「设置」一样高，没输出时也有一行说明，不留白 */
.inst-grid { align-items: stretch; }
.inst-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.inst-col > .panel { margin-top: 0; }
.inst-term-panel { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.inst-term {
  flex: 1; min-height: 150px; max-height: 520px; overflow: auto;
  padding: 12px 14px; font-family: var(--mono); font-size: 13px; line-height: 1.65;
  color: #c9d1d9; background: #0f1115; border: 1px solid #1f242c; border-radius: var(--r-md);
}
.inst-term:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.inst-term-lines { margin: 0; padding: 0; list-style: none; }
.inst-term-lines li { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 10px; overflow-wrap: anywhere; }
.inst-term-lines time { color: #6e7681; font-variant-numeric: tabular-nums; }
.inst-term-lines b { font-weight: 600; color: #7aa2f7; }
.inst-term-lines .t-runtime b { color: #9ece6a; }
.inst-term-lines .t-warn span { color: #e0af68; }
.inst-term-lines .t-error span { color: #f7768e; }
.inst-term-prompt { display: flex; align-items: baseline; gap: 8px; margin: 6px 0 0; color: #8b949e; }
.inst-term-prompt > span:first-child { color: #7aa2f7; font-weight: 700; }
.inst-term-prompt i { display: inline-block; width: 7px; height: 14px; background: #8b949e; transform: translateY(2px); animation: inst-caret 1.1s steps(1) infinite; }
@keyframes inst-caret { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .inst-term-prompt i { animation: none; } }

/* 表单里的勾选行：别被 .form-stack label 的网格样式拆成两行 */
.form-stack label.switch-field { display: flex; align-items: center; gap: 10px; font-weight: 400; color: var(--text-1); }
.form-hint a { color: var(--blue-ink); font-weight: 600; }

/* 实例封面与大卡片（我的实例）——实例是主角，购买区收成底部一张小表 */
.inst-cover { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: var(--bg-soft); border-radius: var(--r-md); }
.inst-cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
.inst-cover.is-blank { display: flex; align-items: center; justify-content: center; }
.inst-cover.is-blank b { font-size: 64px; font-weight: 700; color: rgba(255, 255, 255, 0.92); }
.inst-cover.tone-blue { background: #2563eb; }
.inst-cover.tone-slate { background: #334155; }
.inst-cover.tone-green { background: #15803d; }
.inst-cover.tone-amber { background: #b45309; }
.inst-cover.is-banner { aspect-ratio: auto; height: 180px; margin-bottom: 18px; }
.inst-cover.is-banner.is-blank b { font-size: 72px; }
.inst-cover.is-thumb { width: 192px; flex: none; }
.inst-cover.is-thumb.is-blank b { font-size: 40px; }

.inst-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.inst-card { display: flex; flex-direction: column; overflow: hidden; background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--r-lg, 14px); }
.inst-card-cover .inst-cover { border-radius: 0; }
.inst-card-body { display: grid; gap: 12px; padding: 18px 20px 20px; }
.inst-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.inst-card-head h2 { margin: 0; font-size: 22px; font-weight: 700; color: var(--text-1); }
.inst-card-head a:hover h2 { color: var(--blue-ink); }
.inst-card-hint { margin: -6px 0 0; font-size: 13px; color: var(--text-3); }
.inst-card-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 12px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.inst-card-facts dt { font-size: 12px; color: var(--text-3); }
.inst-card-facts dd { margin: 2px 0 0; font-size: 14px; font-weight: 600; color: var(--text-1); }
.inst-card-actions { display: flex; gap: 10px; }

.inst-buy-table td { vertical-align: middle; }
.inst-buy-table small { display: inline; margin-left: 2px; font-size: 12px; color: var(--text-3); }
.inst-buy-actions { display: flex; gap: 8px; justify-content: flex-end; }
.inst-buy-actions .buy-button { white-space: nowrap; }

.inst-cover-edit { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line-soft); }
.inst-cover-edit h3 { margin: 0 0 10px; font-size: 14px; font-weight: 700; }
.inst-cover-row { display: flex; gap: 16px; align-items: flex-start; }
.inst-cover-forms { display: grid; gap: 8px; min-width: 0; }
.inst-cover-upload { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

@media (max-width: 1100px) {
  .inst-cards { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .inst-card-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .inst-cover-row { flex-direction: column; }
  .inst-cover.is-thumb { width: 100%; }
  .inst-buy-table tr { display: grid; gap: 6px; padding: 10px 0; }
  .inst-buy-table td { padding: 0; border: 0; text-align: left; }
  .inst-buy-actions { justify-content: flex-start; }
}
.inst-card-facts dd small { display: block; margin-top: 2px; font-size: 12px; font-weight: 400; color: var(--text-3); }
.inst-card-facts dd small.is-err { color: var(--bad); }
.data-table.inst-buy-table td small { display: inline; margin: 0 0 0 2px; }
/* 只有一个实例：横着放，封面在左、信息在右，占满整行 */
.inst-cards.is-single { grid-template-columns: minmax(0, 1fr); }
.inst-cards.is-single .inst-card { flex-direction: row; }
.inst-cards.is-single .inst-card-cover { flex: 0 0 46%; }
.inst-cards.is-single .inst-card-cover .inst-cover { height: 100%; aspect-ratio: auto; min-height: 260px; }
.inst-cards.is-single .inst-card-body { flex: 1; align-content: center; padding: 24px 28px; }
@media (max-width: 900px) {
  .inst-cards.is-single .inst-card { flex-direction: column; }
  .inst-cards.is-single .inst-card-cover .inst-cover { aspect-ratio: 16 / 9; min-height: 0; }
}
.inst-buy-list { display: grid; margin: 0; padding: 0; list-style: none; }
.inst-buy-list li { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr) minmax(0, 1.4fr) auto; gap: 16px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.inst-buy-list li:last-child { border-bottom: 1px solid var(--line-soft); }
.inst-buy-spec b, .inst-buy-price b { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--text-1); }
.inst-buy-spec span, .inst-buy-price span { margin-left: 6px; font-size: 12px; color: var(--text-3); }
@media (max-width: 900px) {
  .inst-cards.is-single .inst-card-cover { flex: none; }
  .inst-cards.is-single .inst-card-cover .inst-cover { height: auto; }
}
@media (max-width: 720px) {
  .inst-buy-list li { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px 12px; }
  .inst-buy-spec { grid-column: 1 / -1; }
  .inst-buy-actions { grid-column: 1 / -1; }
}


/* ------------------------------------------------ 26 页内标签（参考 GitHub UnderlineNav） */
.tabnav { margin: 6px 0 20px; border-bottom: 1px solid var(--line); }
.tabnav-track { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.tabnav-track::-webkit-scrollbar { display: none; }
.tabnav-item {
  position: relative; display: inline-flex; align-items: center; gap: 9px; flex: none;
  height: 48px; padding: 0 14px; font-size: 15.5px; font-weight: 500; color: var(--text-2); white-space: nowrap;
}
.tabnav-item .icon { width: 18px; height: 18px; color: var(--text-3); }
.tabnav-item:hover { color: var(--text-1); }
.tabnav-item:hover::after { content: ""; position: absolute; left: 8px; right: 8px; bottom: -1px; height: 2px; background: var(--line); border-radius: 2px; }
.tabnav-item.is-current { font-weight: 600; color: var(--text-1); }
.tabnav-item.is-current .icon { color: var(--blue); }
.tabnav-item.is-current::after { content: ""; position: absolute; left: 8px; right: 8px; bottom: -1px; height: 2px; background: var(--blue); border-radius: 2px; }
.tabnav-item:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; border-radius: var(--r-sm); }
.tabnav-count {
  min-width: 22px; padding: 0 7px; font-size: 13px; font-weight: 600; line-height: 20px; text-align: center;
  color: var(--text-2); background: var(--bg-soft); border-radius: 6px; font-variant-numeric: tabular-nums;
}

/* 实例详情页头：小封面 + 名字 + 状态与启停 */
.inst-head { display: flex; align-items: center; gap: 16px; margin-bottom: 8px; }
.inst-cover.is-avatar { width: 96px; flex: none; border-radius: var(--r-md); }
.inst-cover.is-avatar.is-blank b { font-size: 30px; }
.inst-head-copy { flex: 1; min-width: 0; }
.inst-head-copy h1 { margin: 0; font-size: 26px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.inst-head-copy p { margin: 4px 0 0; font-size: 14px; color: var(--text-2); }
.inst-head-actions { display: flex; align-items: center; gap: 12px; flex: none; }
.inst-head-run button { min-width: 108px; justify-content: center; }

.inst-overview { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 20px; align-items: stretch; }
.inst-overview > .panel { margin-top: 0; }
.inst-side { display: flex; flex-direction: column; gap: 20px; }
.inst-side > .panel { margin-top: 0; }
/* 起步 340px，多了在框里滚，不把页面撑长；右栏比它高时才跟着拉齐 */
.inst-overview .inst-term { flex: 1 0 340px; height: 340px; min-height: 340px; max-height: none; }
.inst-checklist ul { display: grid; gap: 10px; margin: 0 0 12px; padding: 0; list-style: none; }
.inst-checklist li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-1); }
.inst-checklist li .icon { width: 18px; height: 18px; flex: none; color: var(--warn, #b45309); }
.inst-checklist li.is-done .icon { color: var(--good, #15803d); }
.inst-checklist li a { color: var(--blue-ink); font-weight: 600; }

.inst-settings { display: grid; grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr); gap: 20px; align-items: start; }
.inst-settings > .panel { margin-top: 0; }
.inst-danger { margin-top: 20px; }
.inst-danger .head-icon { color: var(--bad); }
.inst-danger-form { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; }
.inst-danger-form label { flex: 1 1 260px; max-width: 420px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--text-2); }
.inst-danger-form .chip-button { flex: none; height: 40px; }
.inst-cover.is-preview { margin-bottom: 14px; }
.inst-cover-edit .inst-cover-upload { margin-bottom: 8px; }

@media (max-width: 1100px) {
  .inst-overview, .inst-settings { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .inst-head { flex-wrap: wrap; gap: 12px; }
  .inst-cover.is-avatar { width: 72px; }
  .inst-head-copy h1 { font-size: 22px; }
  .inst-head-actions { width: 100%; justify-content: space-between; }
  .inst-head-run { flex: 1; max-width: 60%; }
  .inst-head-run button { width: 100%; min-height: 44px; font-size: 15px; }
  .tabnav { margin: 0 -16px 14px; padding: 0 10px; }
  .tabnav-track { gap: 2px; }
  .tabnav-item { height: 40px; padding: 0 10px; gap: 5px; font-size: 13px; flex: 1; justify-content: center; }
  .tabnav-item .icon { width: 15px; height: 15px; }
  .tabnav-count { min-width: 18px; padding: 0 5px; font-size: 12px; line-height: 17px; border-radius: 4px; }
  .inst-cover.is-banner { display: none; }   /* 手机上页头已经有封面，横幅省掉，省一屏 */
  .inst-overview .inst-term { flex-basis: 300px; height: 300px; min-height: 300px; }
  .inst-renew-buy { display: grid; grid-template-columns: 1fr 1fr; }
  .inst-renew-buy .buy-button { justify-content: center; min-height: 40px; }
  .inst-plugin-row .row-actions .chip-button, .inst-toggle { min-height: 40px; }
  .inst-card-actions .primary-button { flex: 1; justify-content: center; min-height: 44px; }
  .inst-buy-actions .buy-button { flex: 1; justify-content: center; min-height: 40px; }
}
.inst-cover-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }

/* ------------------------------------------------ 27 产品页头（导入器各页共用，参考 GitHub 仓库页头） */
.product-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 6px; }
.product-head-copy h1 { margin: 0; font-size: 26px; font-weight: 700; line-height: 1.25; }
.product-head-copy p { margin: 6px 0 0; font-size: 14px; color: var(--text-2); }
.product-head-meter {
  display: grid; gap: 2px; padding: 8px 14px; text-align: right;
  border: 1px solid var(--line-soft); border-radius: var(--r-md); background: var(--card);
}
.product-head-meter:hover { border-color: var(--blue); }
.product-head-meter small { font-size: 12px; color: var(--text-3); }
.product-head-meter b { font-size: 20px; font-weight: 700; color: var(--text-1); font-variant-numeric: tabular-nums; }
.product-head-meter b span { font-size: 13px; font-weight: 500; color: var(--text-3); }
.product-subhead { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: -6px 0 16px; }
.product-subhead p { margin: 0; font-size: 14px; color: var(--text-2); }
.product-subhead-action { display: flex; align-items: center; gap: 10px; flex: none; }
@media (max-width: 720px) {
  .product-head { align-items: center; }
  .product-head-copy p { display: none; }        /* 手机上一句流程说明让给内容 */
  .product-head-copy h1 { font-size: 22px; }
  .product-head-meter { padding: 6px 10px; }
  .product-head-meter b { font-size: 17px; }
  .product-subhead { flex-direction: column; align-items: stretch; gap: 10px; }
  .tabnav-track:has(> :nth-child(5)) .tabnav-item { flex: none; }   /* 标签多（导入器 6 个）：手机上横向滑，不平分 */
}

/* 拖放上传区：整块都能点、能拖；拖进来时描边变蓝 */
.dropzone {
  position: relative; display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0;
  padding: 18px 20px; cursor: pointer;
  border: 1.5px dashed var(--control); border-radius: var(--r-md); background: var(--bg-soft);
  transition: border-color var(--speed), background var(--speed);
}
.dropzone input[type="file"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.dropzone:hover, .dropzone:focus-within { border-color: var(--blue); }
.dropzone.is-over { border-color: var(--blue); background: rgba(37, 99, 235, 0.06); }
.dropzone.has-file { border-style: solid; border-color: var(--blue); background: var(--card); }
.dropzone-icon { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; flex: none; border-radius: var(--r-md); background: var(--card); color: var(--blue); border: 1px solid var(--line-soft); }
.dropzone-icon .icon { width: 20px; height: 20px; }
.dropzone-text { display: grid; gap: 2px; min-width: 0; }
.dropzone-text b { font-size: 15px; font-weight: 600; color: var(--text-1); overflow-wrap: anywhere; }
.dropzone-text span { font-size: 13px; color: var(--text-3); }
.inst-cover-upload .dropzone { flex: 1 1 100%; padding: 14px 16px; }

.sidebar-nav:hover, .sidebar-nav:focus-within { scrollbar-color: var(--line) transparent; }
.sidebar-nav::-webkit-scrollbar { width: 6px; }
.sidebar-nav::-webkit-scrollbar-thumb { border-radius: 3px; background: transparent; }
.sidebar-nav:hover::-webkit-scrollbar-thumb { background: var(--line); }

/* ---- 页内标签切换：页头和标签条原地不动，下划线滑到新标签，内容按方向平移 ---- */
.inst-head, .product-head { view-transition-name: voh-pagehead; }
.crumb { view-transition-name: voh-crumb; }
.tabnav { view-transition-name: voh-tabnav; }
.tabnav-bar { position: absolute; left: 8px; right: 8px; bottom: -1px; height: 2px; background: var(--blue); border-radius: 2px; view-transition-name: voh-tabbar; }
.tabnav-item.is-current::after { content: none; }      /* 下划线由真元素 .tabnav-bar 画，伪元素那条不要了 */
.app-main { view-transition-name: voh-main; }

/* 静态部分（侧栏、页头、标签条）：旧快照直接不画，新快照立刻出现。
   光把 group 的时长设成 0 不够——浏览器默认还会对新旧两张快照做 0.25 秒交叉淡化，中途会半透明。 */
::view-transition-group(voh-pagehead), ::view-transition-group(voh-tabnav), ::view-transition-group(voh-sidebar), ::view-transition-group(voh-crumb) { animation: none; }
::view-transition-old(voh-pagehead), ::view-transition-old(voh-tabnav), ::view-transition-old(voh-sidebar), ::view-transition-old(voh-crumb) { display: none; }
::view-transition-new(voh-pagehead), ::view-transition-new(voh-tabnav), ::view-transition-new(voh-sidebar), ::view-transition-new(voh-crumb) { animation: none; }
/* 下划线：新旧两条不交叉淡化，只让 group 从旧位置滑到新位置 */
::view-transition-old(voh-tabbar) { display: none; }
::view-transition-new(voh-tabbar) { animation: none; }
::view-transition-group(voh-tabbar) { animation-duration: 0.32s; animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1); }
::view-transition-old(voh-main) { animation: fade-in 0.16s var(--ease-out) reverse both; }
::view-transition-new(voh-main) { animation: rise-in 0.3s var(--ease-out) both; }

/* 模糊融合（2026-10-21 用户定，替换推页）：旧页一边糊开一边淡出，新页从糊到清晰浮现，
   两张叠在一起的那一刻都是糊的，看不出「残影」；再顺着切换方向各漂一点，保留左右的方向感。
   容器直接用新页面尺寸（不做高度从长缩到短的默认动画，那会让旧页下半截露在新内容下面）。 */
html:active-view-transition-type(tab-forward, tab-back)::view-transition-group(voh-main) { animation: none; }
html:active-view-transition-type(tab-forward, tab-back)::view-transition-image-pair(voh-main) { overflow: clip; isolation: isolate; }
html:active-view-transition-type(tab-forward, tab-back)::view-transition-old(voh-main),
html:active-view-transition-type(tab-forward, tab-back)::view-transition-new(voh-main) {
  mix-blend-mode: normal; animation-fill-mode: both; animation-delay: 0s; animation-direction: normal;
}
html:active-view-transition-type(tab-forward, tab-back)::view-transition-old(voh-main) { animation-duration: 0.24s; animation-timing-function: linear; }
html:active-view-transition-type(tab-forward, tab-back)::view-transition-new(voh-main) { animation-duration: 0.42s; animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1); animation-delay: 0.03s; }
html:active-view-transition-type(tab-forward)::view-transition-old(voh-main) { animation-name: melt-out-left; }
html:active-view-transition-type(tab-forward)::view-transition-new(voh-main) { animation-name: melt-in-right; }
html:active-view-transition-type(tab-back)::view-transition-old(voh-main) { animation-name: melt-out-right; }
html:active-view-transition-type(tab-back)::view-transition-new(voh-main) { animation-name: melt-in-left; }
/* 旧页在前 70% 就淡完，后面只剩模糊和漂移走完：新页清晰起来的时候旧页已经看不见，不会垫在后面 */
@keyframes melt-out-left { 70% { opacity: 0; } to { opacity: 0; filter: blur(14px); transform: translateX(-24px) scale(0.99); } }
@keyframes melt-out-right { 70% { opacity: 0; } to { opacity: 0; filter: blur(14px); transform: translateX(24px) scale(0.99); } }
@keyframes melt-in-right { from { opacity: 0; filter: blur(14px); transform: translateX(28px) scale(1.01); } }
@keyframes melt-in-left { from { opacity: 0; filter: blur(14px); transform: translateX(-28px) scale(1.01); } }
/* 同一个标签里提交表单再回来：不平移，只轻轻换一下 */
html:active-view-transition-type(tab-same)::view-transition-group(voh-main) { animation: none; }
html:active-view-transition-type(tab-same)::view-transition-old(voh-main) { animation: melt-out-same 0.2s cubic-bezier(0.4, 0, 1, 1) normal both; mix-blend-mode: normal; }
html:active-view-transition-type(tab-same)::view-transition-new(voh-main) { animation: melt-in-same 0.32s cubic-bezier(0.2, 0.8, 0.2, 1) normal both; mix-blend-mode: normal; }
@keyframes melt-out-same { to { opacity: 0; filter: blur(8px); } }
@keyframes melt-in-same { from { opacity: 0; filter: blur(8px); } }
/* 标签切换时整页底色那层不要再淡入淡出，否则又像整页刷新 */
html:active-view-transition-type(tab-forward, tab-back, tab-same)::view-transition-old(root),
html:active-view-transition-type(tab-forward, tab-back, tab-same)::view-transition-new(root) { animation: none; }


@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* 站内跳转（不是这次打开网站的第一页）：进场动画全部不播，交给跨页过渡 */
html[data-nav="soft"] .app-main > *,
html[data-nav="soft"] .public-main > *,
html[data-nav="soft"] .sidebar-head,
html[data-nav="soft"] .sidebar-group,
html[data-nav="soft"] .sidebar-foot,
html[data-nav="soft"] .overview-grid > .stat-card { animation: none; }

/* ---- 折叠区：grid 行高从 0fr 过渡到 1fr，高度是内容的真实高度，不用量、不用写死 ---- */
.collapse { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.34s cubic-bezier(0.2, 0.8, 0.2, 1); }
.collapse.is-open { grid-template-rows: 1fr; }
.collapse-inner { min-height: 0; overflow: hidden; }
.collapse-inner > * { opacity: 0; transform: translateY(-6px); transition: opacity 0.22s ease, transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
.collapse.is-open .collapse-inner > * { opacity: 1; transform: none; transition-delay: 0.06s; }
.inst-plugin-config.collapse { padding: 0; }
.inst-plugin-config.collapse.is-open .collapse-inner { padding: 4px 0 18px; }
.inst-plugin-config.collapse .collapse-inner { transition: padding 0.34s cubic-bezier(0.2, 0.8, 0.2, 1); }
[data-collapse-toggle] .icon:last-child { width: 14px; height: 14px; transform: rotate(90deg); transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
[data-collapse-toggle][aria-expanded="true"] .icon:last-child { transform: rotate(-90deg); }
@media (prefers-reduced-motion: reduce) {
  .collapse, .collapse-inner, .collapse-inner > *, [data-collapse-toggle] .icon:last-child { transition: none; }
}
.task-new .collapse-inner { padding: 2px; margin: -2px; }   /* 给面板阴影留出位置，不被裁掉 */
.app-main > .task-new:not(.is-open) { margin-top: 0; }   /* 收起时高度 0，别再留一截块间距 */
.app-main > .task-new { transition: grid-template-rows 0.34s cubic-bezier(0.2, 0.8, 0.2, 1), margin-top 0.34s cubic-bezier(0.2, 0.8, 0.2, 1); }

/* ------------------------------------------------ 28 动态底纹「碎瓷」+ 外观设置（学 PeusdoLancer）
   以前整站是一块 #f4f6fa 纯色，用户嫌「背景太空」。PeusdoLancer 好看的根子是一张会慢慢动的维诺图底，
   而且侧栏、页面框全透明，让它处处透出来；只铺一张背景、上面盖满实心块是没用的。
   画布由 bg-field.js 画（WebGL，半分辨率，最多 24 帧）；颜色、浓淡、动态/静止/关闭在个人中心 · 外观里改。
   z-index: -1：落在根层背景之上、所有正文之下，不给 .app-shell 开层叠上下文（否则手机抽屉会被客服球压住）。 */
.bg-field {
  position: fixed;
  inset: 0;
  z-index: -1;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
html[data-field="off"] .bg-field { display: none; }

/* 侧栏不铺底色，和 PeusdoLancer 一样让花纹透上来（试过加 45% 薄纱：在侧栏右缘切出一道生硬的直边，去掉了）。
   渐变是左下浅右上深，侧栏正好落在最浅的那头，小字照样清楚 */
.sidebar { background: transparent; }
html[data-field="off"] .sidebar { background: var(--bg); }

@media (max-width: 900px) {
  /* 手机抽屉浮在正文上面，必须实心，否则下面的文字透上来 */
  .sidebar { background: var(--bg); }
  .mobile-bar {
    background: color-mix(in srgb, var(--bg) 78%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }
}

/* ---- 微交互（学 PeusdoLancer）：能点进去的大卡悬停上浮 2px、阴影加深；导航项悬停往右让 3px ----
   2026-10-21 用户要「搞点动态」，推翻上面「卡片不做悬停上浮」那条：只给整张可点的卡，信息卡照旧不动 */
.pcard,
.inst-card,
.quick-grid > a {
  transition:
    transform 0.18s var(--ease-out),
    box-shadow 0.2s var(--ease-out),
    background-color 0.16s var(--ease-out);
}
.pcard:hover,
.inst-card:hover,
.quick-grid > a:hover { transform: translateY(-2px); box-shadow: var(--ring), var(--shadow-pop); }

.nav-item { transition: background var(--speed), transform 0.2s var(--ease-out); }
.nav-item:hover:not(.active) { transform: translateX(3px); }

@media (prefers-reduced-motion: reduce) {
  .pcard:hover, .inst-card:hover, .quick-grid > a:hover, .nav-item:hover:not(.active) { transform: none; }
}

/* ---- 个人中心 · 外观 ---- */
.appearance-panel { display: grid; gap: 0; padding: 0; }
.appearance-head { margin: 0; padding: 18px 20px 6px; }
.appearance-row {
  display: grid;
  grid-template-columns: minmax(0, 220px) minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
}
.appearance-row + .appearance-row { border-top: 1px solid var(--hairline); }
.appearance-row > div:first-child b { display: block; font-size: 14px; font-weight: 600; }
.appearance-row > div:first-child small { display: block; margin-top: 2px; font-size: 12px; color: var(--text-3); }

/* 分段选择：和页内标签一个调子，选中项白底柔影，不做整块蓝 */
.seg {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 2px;
  padding: 3px;
  border-radius: var(--r-md);
  background: var(--bg-soft);
  box-shadow: var(--well-shadow);
  justify-self: start;
}
.seg button {
  min-height: 30px;
  padding: 0 14px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--text-2);
  font-size: 13px;
  cursor: pointer;
  transition: background-color 0.16s var(--ease-out), color 0.16s var(--ease-out), box-shadow 0.16s var(--ease-out);
}
.seg button:hover { color: var(--text-1); }
.seg button[aria-pressed="true"] { background: var(--card); color: var(--text-1); font-weight: 600; box-shadow: var(--ring), var(--shadow-card); }
html[data-theme="dark"] .seg button[aria-pressed="true"] { background: var(--press); }

/* 色板：8 个预设 + 自定义。色块颜色不能写内联 style（CSP），一色一个 class */
.swatches { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.swatch {
  position: relative;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
  transition: transform 0.14s var(--ease-out);
}
.swatch:hover { transform: scale(1.08); }
.swatch:active { transform: scale(0.95); }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--text-1); }
.swatch.sw-blue { background: #2563eb; }
.swatch.sw-violet { background: #7c3aed; }
.swatch.sw-pink { background: #db2777; }
.swatch.sw-coral { background: #e5484d; }
.swatch.sw-amber { background: #d97706; }
.swatch.sw-green { background: #16a34a; }
.swatch.sw-teal { background: #0891b2; }
.swatch.sw-slate { background: #64748b; }
.swatch-custom {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 4px;
  font-size: 13px;
  color: var(--text-2);
  cursor: pointer;
}
.swatch-custom input[type="color"] {
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: none;
  cursor: pointer;
}
.swatch-custom input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.swatch-custom input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 8px; box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.12); }
.swatch-custom input[type="color"]::-moz-color-swatch { border: 0; border-radius: 8px; }
.swatch-custom.is-on input[type="color"] { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--text-1); }

.strength { display: flex; align-items: center; gap: 12px; max-width: 360px; }
.strength input[type="range"] { flex: 1; accent-color: var(--blue); }
.strength output { min-width: 28px; font-size: 13px; color: var(--text-2); font-variant-numeric: tabular-nums; text-align: right; }
.appearance-foot { display: flex; justify-content: flex-end; padding: 12px 20px 16px; border-top: 1px solid var(--hairline); }

@media (max-width: 640px) {
  .appearance-row { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 14px 16px; }
}

/* ------------------------------------------------ 29 协议链接 + 插件审核台 */
.app-foot a,
.public-foot a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.app-foot a:hover,
.public-foot a:hover { color: var(--text-1); }
.detail-main > details.panel > summary { cursor: pointer; display: flex; gap: 8px; align-items: baseline; }
.detail-main > details.panel[open] > summary { margin-bottom: 12px; }

/* 商店分类标签 .tabs：横向可滚动的容器里，.tab 用 margin-bottom:-1px 压住底线，
   多出的 1px 让浏览器顺带给了一条竖向滚动条（标签条右端多出 ▲●▼）。
   底线改成容器的内阴影（画在子元素下面），标签不再越界；滚动条藏起来，手机上照样能横滑 */
.tabs { border-bottom: 0; box-shadow: inset 0 -1px 0 var(--line); overflow-y: hidden; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { margin-bottom: 0; }

/* ------------------------------------------------ 30 管理端「实例管理」总表（像 MCSM 的实例列表）+ 站长查看提示
   信息密度参考 GitHub / MCSM：一行一个实例，状态灯是一个色点 + 文字，不做胶囊徽章。
   内存条宽度走 .w-NN（CSP 禁内联 style），按 5% 一档。手机上表格折成一张张卡片，不横向溢出 */
.admin-viewing {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 14px;
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: var(--warn-wash);
  color: var(--warn);
  font-size: 13px;
  line-height: 1.6;
}
.admin-viewing .icon { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.admin-viewing b { font-weight: 600; }

.ainst-summary { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.ainst-filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 12px; }
.ainst-filters label { display: grid; gap: 4px; font-size: 12px; color: var(--text-2); }
.ainst-filters select { min-width: 150px; }
.ainst-filters .ainst-search { flex: 1 1 240px; }
.ainst-filters .ainst-search input { width: 100%; }
.ainst-count { margin-left: auto; align-self: flex-end; padding-bottom: 9px; }
/* 正常宽度下 8 列放得下；更窄的平板宽度上表格在面板里横向滚动，而不是被裁掉 */
.ainst-panel { padding: 0; overflow-x: auto; }
.ainst-empty { padding: 20px; margin: 0; }

.ainst-table { font-size: 13px; }
.ainst-table th,
.ainst-table td { padding: 10px 8px; vertical-align: middle; }
.ainst-table th:first-child,
.ainst-table td:first-child { padding-left: 16px; }
.ainst-table th:last-child,
.ainst-table td:last-child { padding-right: 16px; }
.ainst-table th { white-space: nowrap; }
.ainst-table td small { display: block; margin-top: 2px; font-size: 12px; color: var(--text-3); white-space: nowrap; }
.ainst-table td { white-space: nowrap; }
.ainst-table td.ainst-error { white-space: normal; }

.ainst-lamp { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; font-weight: 500; }
.ainst-lamp i { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--text-3); }
.ainst-lamp.is-running i { background: var(--ok); }
.ainst-lamp.is-waiting i { background: var(--warn-fill); }
.ainst-lamp.is-error i { background: var(--bad); }
.ainst-lamp.is-error { color: var(--bad); }
.ainst-lamp.is-stopped i { background: var(--icon); }
.ainst-lamp.is-expired i { background: transparent; box-shadow: inset 0 0 0 1.5px var(--icon); }
.ainst-lamp.is-purged { color: var(--text-3); }
.ainst-lamp.is-purged i { background: var(--line); }

.ainst-name { display: grid; gap: 1px; max-width: 180px; color: var(--text-1); }
.ainst-name b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.ainst-name:hover b { color: var(--blue-ink); }
.ainst-owner { display: grid; gap: 1px; color: var(--text-1); min-width: 120px; max-width: 160px; }
.ainst-owner span,
.ainst-owner small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ainst-owner:hover span { color: var(--blue-ink); }
.ainst-spec { white-space: nowrap; }

.ainst-mem-cell { display: grid; gap: 4px; min-width: 80px; }
.ainst-mem { display: block; width: 80px; height: 6px; border-radius: 3px; background: var(--bg-soft); box-shadow: var(--well-shadow); overflow: hidden; }
.ainst-mem i { display: block; height: 100%; border-radius: 3px; background: var(--blue); transition: width 0.4s var(--ease-out); }
.ainst-mem.is-hot i { background: var(--warn-fill); }
.ainst-mem i.w-0 { width: 0%; }
.ainst-mem i.w-5 { width: 5%; }
.ainst-mem i.w-10 { width: 10%; }
.ainst-mem i.w-15 { width: 15%; }
.ainst-mem i.w-20 { width: 20%; }
.ainst-mem i.w-25 { width: 25%; }
.ainst-mem i.w-30 { width: 30%; }
.ainst-mem i.w-35 { width: 35%; }
.ainst-mem i.w-40 { width: 40%; }
.ainst-mem i.w-45 { width: 45%; }
.ainst-mem i.w-50 { width: 50%; }
.ainst-mem i.w-55 { width: 55%; }
.ainst-mem i.w-60 { width: 60%; }
.ainst-mem i.w-65 { width: 65%; }
.ainst-mem i.w-70 { width: 70%; }
.ainst-mem i.w-75 { width: 75%; }
.ainst-mem i.w-80 { width: 80%; }
.ainst-mem i.w-85 { width: 85%; }
.ainst-mem i.w-90 { width: 90%; }
.ainst-mem i.w-95 { width: 95%; }
.ainst-mem i.w-100 { width: 100%; }
.ainst-restarts { color: var(--warn) !important; }

.ainst-error { min-width: 96px; max-width: 150px; color: var(--bad); font-size: 12px; }
.ainst-error span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ainst-actions { display: flex; flex-wrap: nowrap; gap: 4px; }
.ainst-actions form { margin: 0; }
.ainst-actions .chip-button { min-height: 28px; padding: 0 9px; font-size: 12px; }

@media (max-width: 1280px) {
  .ainst-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ainst-summary > div:nth-child(4) { border-left: 0; }
}

/* 窄屏：表格折成卡片，每格前面带上列名 */
@media (max-width: 900px) {
  .ainst-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ainst-summary > div { border-left: 0 !important; border-top: 1px solid var(--line-soft); }
  .ainst-summary > div:nth-child(-n + 2) { border-top: 0; }
  .ainst-summary > div:nth-child(even) { border-left: 1px solid var(--line-soft) !important; }
  .ainst-filters select { min-width: 0; width: 100%; }
  .ainst-filters label { flex: 1 1 140px; }
  .ainst-count { margin-left: 0; }
  .ainst-panel { background: transparent; box-shadow: none; overflow: visible; }
  .ainst-table,
  .ainst-table tbody { display: block; }
  .ainst-table { min-width: 0; }   /* 通用 .data-table 有 min-width: 660px，折成卡片后必须去掉，否则卡片撑出屏幕 */
  .ainst-table thead { display: none; }
  .ainst-table tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px 14px;
    margin-bottom: 12px;
    padding: 14px 16px;
    border-radius: var(--r-lg);
    background: var(--card);
    box-shadow: var(--ring), var(--shadow-card);
  }
  .ainst-table td { display: grid; gap: 2px; min-width: 0; padding: 0; border: 0; white-space: normal; overflow-wrap: anywhere; }
  .ainst-table td small { white-space: normal; }
  .ainst-table td:first-child,
  .ainst-table td:last-child { padding: 0; }
  .ainst-name { max-width: none; }
  .ainst-actions { flex-wrap: wrap; }
  .ainst-table td::before { content: attr(data-label); font-size: 12px; color: var(--text-3); }
  .ainst-table td[data-label="状态"],
  .ainst-table td[data-label="实例"] { grid-column: span 1; }
  .ainst-table td[data-label="最近报错"],
  .ainst-table td[data-label="操作"] { grid-column: 1 / -1; }
  .ainst-table td[data-label="最近报错"]:has(span:empty) { display: none; }
  .ainst-error { max-width: none; }
  .ainst-owner { max-width: none; }
  .ainst-mem { width: 100%; }
}

/* ------------------------------------------------ 31 实例开放购买开关（实例管理页顶上一条） */
.ainst-sales .panel-head { margin-bottom: 0; align-items: center; }

/* ------------------------------------------------ 32 实例概览：一行状态（2026-10-21 用户嫌大封面 + 四格大数字占地方） */
.inst-facts { display: flex; flex-wrap: wrap; margin: 0 0 20px; padding: 0; overflow: hidden; }
/* 每格按内容定宽、剩下的空间再均分：6 格（加了延迟）平均分时「到期 日期 剩 N 天」放不下，压到隔壁格子上（10-21 服主截图） */
.inst-facts > div { flex: 1 1 auto; min-width: 0; display: flex; align-items: baseline; gap: 10px; padding: 14px 18px; }
.inst-facts > div { box-shadow: -1px 0 0 var(--line-soft), 0 -1px 0 var(--line-soft); }   /* 每格左、上各一道，第一行和第一列那道被面板裁掉：换行后也对得齐 */
.inst-facts dt { flex: none; font-size: 13px; color: var(--text-3); }
.inst-facts dd { margin: 0; min-width: 0; font-size: 15px; font-weight: 600; color: var(--text-1); font-variant-numeric: tabular-nums; white-space: nowrap; }
.inst-facts dd small { margin-left: 6px; font-size: 12px; font-weight: 400; color: var(--text-3); }
.inst-facts dd small.is-err { color: var(--err, #b91c1c); }
/* 右栏最后一块「插件」往下撑，和左边终端底边对齐，不留空（用户截图「这里空了」） */
.inst-overview { align-items: stretch; }
.inst-side-plugins { flex: 1; display: flex; flex-direction: column; }
.inst-mini-plugins { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.inst-mini-plugins li { display: flex; align-items: center; gap: 10px; padding: 6px 0; }
.inst-mini-plugins .plugin-thumb { flex: none; }
.inst-mini-name { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.inst-mini-name b { font-size: 14px; font-weight: 600; color: var(--text-1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inst-mini-plugins small { font-size: 12px; color: var(--text-3); }
.inst-mini-plugins em { flex: none; font-size: 13px; font-style: normal; color: var(--good, #15803d); }
.inst-mini-plugins li.is-off .inst-mini-name b,.inst-mini-plugins li.is-off em { color: var(--text-3); }
.inst-mini-more { display: inline-block; margin-top: 6px; font-size: 13px; color: var(--blue-ink); }
.inst-side-note { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--line-soft); }
@media (max-width: 720px) {
  .inst-facts > div { flex: 1 1 50%; padding: 10px 16px; }
  .inst-facts dd { white-space: normal; }
  .inst-facts dd small { display: block; margin: 2px 0 0; }
  .inst-facts > div:last-child:nth-child(odd) { flex-basis: 100%; }
}

/* ------------------------------------------------ 33 侧栏可展开分组（2026-10-21 用户给的参考图：父项带箭头，子项左边一条竖线） */
.sidebar-nav { gap: 3px; }
.sidebar-group.is-flat { gap: 3px; margin-bottom: 9px; }
.nav-fold { gap: 0; }
.nav-parent {
  display: flex; align-items: center; gap: 13px; width: 100%; height: 40px; padding: 0 14px;
  border: 0; border-radius: var(--r-md); background: transparent; color: var(--text-1);
  font: inherit; font-size: 15.5px; font-weight: 500; text-align: left; cursor: pointer; transition: background var(--speed);
}
.nav-parent:hover { background: var(--hover); }
.nav-parent:active { background: var(--press); }
.nav-parent .icon { width: 20px; height: 20px; flex: none; color: var(--icon); }
.nav-parent .sidebar-group-label { flex: 1; min-width: 0; padding: 0; font-size: 15.5px; font-weight: inherit; color: inherit; }
.nav-parent .icon:last-child { width: 16px; height: 16px; color: var(--text-3); transform: rotate(90deg); transition: transform 0.3s var(--ease-out); }
.nav-parent[aria-expanded="true"] { background: var(--hover); font-weight: 600; }
.nav-parent[aria-expanded="true"] .icon:last-child { transform: rotate(-90deg); }
.nav-fold.has-active .nav-parent .icon:first-child { color: var(--blue); }
.nav-parent:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.nav-sub-list { position: relative; display: grid; gap: 2px; padding: 3px 0 6px 35px; }
.nav-sub-list::before { content: ""; position: absolute; left: 24px; top: 5px; bottom: 9px; width: 1px; background: color-mix(in srgb, var(--text-3) 40%, transparent); }
.nav-sub-list .nav-item { height: 37px; padding: 0 12px; font-size: 14.5px; font-weight: 400; color: var(--text-2); }
.nav-sub-list .nav-item:hover { color: var(--text-1); }
.nav-sub-list .nav-item.active { color: var(--blue-ink); font-weight: 600; }
.nav-sub-list .nav-item.active::before { content: ""; position: absolute; left: 23px; width: 3px; height: 19px; border-radius: 2px; background: var(--blue); }
@media (min-width: 1600px) and (min-height: 960px) {
  .sidebar-nav { gap: 4px; }
  .sidebar-group.is-flat { gap: 4px; margin-bottom: 10px; }
  .nav-item, .nav-parent { height: 42px; font-size: 16px; }
  .nav-parent .sidebar-group-label { font-size: 16px; }
  .nav-sub-list { gap: 3px; padding: 4px 0 7px 35px; }
  .nav-sub-list .nav-item { height: 38px; font-size: 15px; }
  .sidebar-search { height: 42px; font-size: 15px; }
  .plan-brief { padding: 14px 15px 12px 16px; }
  .plan-brief-top strong { font-size: 23px; }
}
/* 移动端侧栏抽屉独立收紧：不跟随桌面放大，反而在原基线上适度微缩，保持小屏轻巧精致 */
@media (max-width: 900px) {
  .sidebar-head { padding: 2px 4px 0 8px; }
  .sidebar-brand { gap: 8px; }
  .sidebar-brand .wordmark { height: 16.5px; }
  .sidebar-brand small { font-size: 12px; padding-bottom: 1px; }
  .sidebar-search { height: 34px; padding: 0 9px 0 11px; gap: 7px; border-radius: 9px; font-size: 13px; }
  .sidebar-search .icon { width: 15px; height: 15px; }
  .sidebar-search kbd { padding: 1px 5px; font-size: 12px; }
  .sidebar-nav { gap: 2px; padding: 0 2px 14px; }
  .sidebar-group.is-flat { gap: 2px; margin-bottom: 6px; }
  .nav-item, .nav-parent { height: 33px; padding: 0 10px; gap: 10px; font-size: 13.5px; }
  .nav-item .icon, .nav-parent .icon { width: 17px; height: 17px; }
  .nav-parent .sidebar-group-label { font-size: 13.5px; }
  .nav-parent .icon:last-child { width: 13px; height: 13px; }
  .nav-sub-list { gap: 1px; padding: 2px 0 5px 27px; }
  .nav-sub-list::before { left: 18px; top: 4px; bottom: 8px; }
  .nav-sub-list .nav-item { height: 31px; padding: 0 10px; font-size: 13px; }
  .nav-sub-list .nav-item.active::before { left: 17px; height: 16px; }
  .nav-count { min-width: 19px; height: 19px; padding: 0 5px; font-size: 12px; line-height: 19px; }
  .sidebar-foot { gap: 8px; }
  .plan-brief { gap: 6px; padding: 10px 11px 9px 12px; border-radius: 12px; }
  .plan-brief-top small { font-size: 12px; }
  .plan-brief-top strong { font-size: 18px; }
  .plan-brief-of { font-size: 12px; }
  .plan-brief-top .icon-button { width: 28px; height: 28px; }
  .plan-brief-top .icon-button .icon { width: 16px; height: 16px; }
  .plan-brief-row { padding-top: 6px; font-size: 12.5px; }
  .plan-brief-row a .icon { width: 13px; height: 13px; }
  .sidebar-account { gap: 8px; padding: 2px 0 0 4px; }
  .sidebar-account .avatar.small { width: 30px; height: 30px; font-size: 13px; }
  .sidebar-account-copy { gap: 1px; }
  .sidebar-account-copy strong { font-size: 13.5px; }
  .sidebar-account-copy small { font-size: 12px; }
  .sidebar-account .icon-button { width: 30px; height: 30px; }
  .sidebar-account .icon-button .icon { width: 16px; height: 16px; }
}
.sidebar.nav-instant .collapse, .sidebar.nav-instant .collapse-inner > *, .sidebar.nav-instant .nav-parent .icon:last-child { transition: none; }
@media (prefers-reduced-motion: reduce) { .nav-parent .icon:last-child { transition: none; } }

/* ------------------------------------------------ 插件开发文档（/dashboard/author/docs，src/views/plugin-docs.mjs）
   左侧目录 + 右侧一节一张卡。只用全站 token，深色模式自动跟着变。
   代码块在框内横向滚动；表格窄屏下每行叠成一块，不让整页横向溢出。 */
.pdoc { display: grid; grid-template-columns: 184px minmax(0, 1fr); gap: 24px; align-items: start; }
.pdoc-toc { position: sticky; top: 24px; padding: 4px 0; font-size: 13px; }
.pdoc-toc > b { display: block; padding: 0 12px 8px; font-size: 12px; font-weight: 600; color: var(--text-3); }
.pdoc-toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; border-left: 1px solid var(--line); }
.pdoc-toc a { display: flex; gap: 10px; align-items: baseline; margin-left: -1px; padding: 6px 12px; border-left: 2px solid transparent; color: var(--text-2); line-height: 1.4; }
.pdoc-toc a span { font-family: var(--mono); font-size: 12px; color: var(--text-3); }
.pdoc-toc a:hover { color: var(--text-1); border-left-color: var(--control); }
.pdoc-toc a:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; border-radius: 4px; }
.pdoc-body { display: grid; gap: 16px; min-width: 0; }
.pdoc-sec { scroll-margin-top: 20px; padding: 26px 28px 24px; min-width: 0; }
.pdoc-sec:target { box-shadow: var(--shadow-card), inset 3px 0 0 var(--blue); }
.pdoc-sec h2 { margin: 0 0 12px; font-size: 19px; font-weight: 700; line-height: 1.35; color: var(--text-1); }
.pdoc-sec h3 { margin: 24px 0 8px; font-size: 15px; font-weight: 600; color: var(--text-1); }
.pdoc-sec p { margin: 0 0 10px; max-width: 72ch; font-size: 14px; line-height: 1.75; color: var(--text-2); }
.pdoc-sec ul, .pdoc-olist { margin: 0 0 10px; padding-left: 20px; display: grid; gap: 6px; font-size: 14px; line-height: 1.7; color: var(--text-2); }
.pdoc-sec li::marker { color: var(--text-3); }
.pdoc-sec b { color: var(--text-1); font-weight: 600; }
.pdoc-sec a:not(.chip-button) { color: var(--blue-ink); text-decoration: underline; text-decoration-color: var(--blue-tint); text-underline-offset: 3px; }
.pdoc-sec a:not(.chip-button):hover { text-decoration-color: currentColor; }
.pdoc-sec :not(pre) > code { padding: 1px 5px; border-radius: 5px; background: var(--bg-soft); border: 1px solid var(--line-soft); color: var(--text-1); font-size: 0.86em; overflow-wrap: anywhere; }

/* 代码块：文件名条 + 复制按钮；本体是一层浅井，框内横向滚动 */
.pdoc-code { margin: 12px 0 14px; border-radius: var(--r-md); background: var(--well-bg); box-shadow: var(--well-shadow); overflow: hidden; }
.pdoc-file { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 40px; padding: 6px 8px 6px 14px; border-bottom: 1px solid var(--line-soft); font-family: var(--mono); font-size: 12px; color: var(--text-3); }
.pdoc-file .chip-button { min-height: 28px; font-family: var(--font); }
.pdoc-code pre { margin: 0; padding: 14px 16px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.pdoc-code pre code { display: block; width: max-content; min-width: 100%; font-family: var(--mono); font-size: 13px; line-height: 1.65; white-space: pre; color: var(--text-1); background: none; padding: 0; border: 0; }

/* 步骤：方角序号，不用胶囊 */
.pdoc-steps { list-style: none; counter-reset: pdoc-step; margin: 14px 0 16px; padding: 0; display: grid; gap: 14px; }
.pdoc-steps li { counter-increment: pdoc-step; position: relative; padding-left: 40px; min-height: 26px; }
.pdoc-steps li::before { content: counter(pdoc-step); position: absolute; left: 0; top: 0; width: 26px; height: 26px; display: grid; place-items: center; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--card); color: var(--blue-ink); font-size: 13px; font-weight: 700; }
.pdoc-steps b { display: block; font-size: 14px; line-height: 26px; }
.pdoc-steps p { margin: 2px 0 0; }

/* 提示条：左侧一道色边 */
.pdoc-note { display: flex; gap: 10px; align-items: flex-start; margin: 12px 0 14px; padding: 12px 14px; border-radius: 0 var(--r-sm) var(--r-sm) 0; border-left: 3px solid var(--blue); background: var(--bg-soft); font-size: 14px; line-height: 1.7; color: var(--text-2); }
.pdoc-note .icon { flex: none; width: 16px; height: 16px; margin-top: 4px; color: var(--blue); }
.pdoc-note.is-warn { border-left-color: var(--warn-fill); background: var(--warn-wash); }
.pdoc-note.is-warn .icon { color: var(--warn); }

/* 表格 */
.pdoc-table-wrap { margin: 10px 0 14px; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.pdoc-table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.6; }
.pdoc-table th { padding: 9px 14px; text-align: left; font-size: 12px; font-weight: 600; color: var(--text-3); background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.pdoc-table td { padding: 10px 14px; vertical-align: top; color: var(--text-2); border-bottom: 1px solid var(--line-soft); overflow-wrap: anywhere; }
.pdoc-table tbody tr:last-child td { border-bottom: 0; }
.pdoc-table td:first-child { color: var(--text-1); }
.pdoc-table td:first-child > code { padding: 0; border: 0; background: none; font-size: 13px; font-weight: 600; }
@media (min-width: 621px) {
  .pdoc-table:not(.is-api) td:first-child { white-space: nowrap; }
  .pdoc-table.is-api td:first-child { width: 34%; }
  .pdoc-table.is-api td:nth-child(2) { width: 26%; }
  .pdoc-table.is-manifest td:first-child { width: 112px; white-space: nowrap; }
  .pdoc-table.is-manifest td:nth-child(2) { width: 120px; }
}
.pdoc-table.is-manifest td:nth-child(2) { color: var(--text-3); }

/* 自测清单：方框勾选位 */
.pdoc-sec .pdoc-check { list-style: none; padding-left: 0; }
.pdoc-check li { position: relative; padding-left: 28px; }
.pdoc-check li::before { content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; border-radius: 4px; border: 1.5px solid var(--control); background: var(--card); }

@media (max-width: 900px) {
  .pdoc { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .pdoc-toc { position: static; padding: 14px 6px 10px; background: var(--card); border-radius: var(--r-lg); box-shadow: var(--shadow-card), var(--ring); }
  .pdoc-toc ol { grid-template-columns: repeat(2, minmax(0, 1fr)); border-left: 0; gap: 0 4px; }
  .pdoc-toc a { margin-left: 0; border-left: 0; border-radius: var(--r-sm); }
  .pdoc-toc a:hover { background: var(--hover); }
  .pdoc-sec { scroll-margin-top: 76px; padding: 20px 18px; }
}

@media (max-width: 620px) {
  .pdoc-sec { padding: 18px 16px; }
  .pdoc-sec h2 { font-size: 18px; }
  .pdoc-code { margin-left: -4px; margin-right: -4px; }
  .pdoc-code pre { padding: 12px 14px; }
  .pdoc-code pre code { font-size: 12px; }
  /* 表格叠成块：每行一块，单元格前面用 data-label 标出列名 */
  .pdoc-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .pdoc-table, .pdoc-table tbody, .pdoc-table tr, .pdoc-table td { display: block; }
  .pdoc-table tr { padding: 10px 14px; border-bottom: 1px solid var(--line-soft); }
  .pdoc-table tbody tr:last-child { border-bottom: 0; }
  .pdoc-table td { padding: 2px 0; border-bottom: 0; }
  .pdoc-table td:first-child { padding-bottom: 4px; }
  .pdoc-table td.is-none { display: none; }
  .pdoc-table td:not(:first-child)::before { content: attr(data-label) "　"; font-size: 12px; color: var(--text-3); }
}

/* ------------------------------------------------ 35 群服互通卡片（实例概览右栏） */
.inst-qq .panel-head { margin-bottom: 12px; }
.inst-qq-qr { display: flex; justify-content: center; margin: 4px 0 10px; }
.inst-qq-qr img { display: block; width: 168px; height: 168px; padding: 8px; background: #fff; border-radius: var(--r-md); box-shadow: inset 0 0 0 1px var(--line); image-rendering: pixelated; }
.inst-qq-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.inst-qq-status > :first-child { margin-top: 0; }
.inst-qq-status form { margin-top: 10px; }
.inst-qq-qr { justify-content: flex-start; }
.inst-qq-side > form + form { margin-top: 6px; }
@media (max-width: 720px) { .inst-qq-body { grid-template-columns: minmax(0, 1fr); gap: 12px; } }
.inst-qq-who { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; font-size: 14px; }
.inst-qq-who .faint { font-size: 13px; font-variant-numeric: tabular-nums; }
.inst-qq-group { margin-top: 0; }
.inst-qq-row { display: flex; gap: 8px; margin-top: 6px; }
.inst-qq-row input { flex: 1; min-width: 0; }
.inst-qq .text-link { margin-top: 10px; font-size: 13px; }
.form-hint.is-err { color: var(--err, #b91c1c); }

/* ------------------------------------------------ 36 插件商店：长内容折叠、说明里的表格，手机上一行两个（2026-10-21 服主：手机要滑到最下面才能买、简介太长、卡片太大） */
.fold.is-folded { overflow: hidden; -webkit-mask-image: linear-gradient(#000 calc(100% - 72px), transparent); mask-image: linear-gradient(#000 calc(100% - 72px), transparent); }
.fold.is-folded[data-fold="360"] { max-height: 360px; }
.fold.is-folded[data-fold="300"] { max-height: 300px; }
.fold-toggle {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 36px; margin-top: 8px;
  border: 0; border-radius: var(--r-md); background: var(--bg-soft); color: var(--blue-ink); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
}
.fold-toggle:hover { background: var(--hover); }
.fold-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.readme ol { margin: 0 0 8px; padding-left: 22px; color: var(--text-2); }
.readme li + li { margin-top: 2px; }
.readme code { padding: 1px 5px; font-family: var(--mono); font-size: 12px; color: var(--text-1); background: var(--bg-soft); border-radius: 4px; }
.readme-table { margin: 4px 0 10px; overflow-x: auto; }
.readme-table table { width: 100%; border-collapse: collapse; font-size: 13px; }
.readme-table th, .readme-table td { padding: 7px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line-soft); }
.readme-table th { font-weight: 600; color: var(--text-1); background: var(--bg-soft); white-space: nowrap; }
.readme-table td { color: var(--text-2); }

@media (max-width: 720px) {
  /* 详情页：价格和购买放到最上面，不用滑过整篇说明 */
  .detail-grid { display: flex; flex-direction: column; align-items: stretch; }   /* 电脑版是 align-items: start，竖排时会让购买卡缩成内容宽 */
  .detail-side { order: -1; }
  /* 商店列表：一行两个，卡片收紧；大推荐位和列表第一个重复，手机上不放 */
  .panel.feature { display: none; }
  .store-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .pcard-body { gap: 4px; padding: 10px 10px 12px; }
  .pcard-title { flex-direction: column; align-items: flex-start; gap: 2px; }
  .pcard-title b { font-size: 14px; }
  .pcard-title .price { font-size: 13px; }
  .pcard-meta, .pcard-tags { display: none; }
  .pcard-blurb { font-size: 12px; line-height: 1.5; }
  .pcard-foot { margin-top: 4px; }
  .pcard-foot .chip-button { width: 100%; justify-content: center; }
}

/* ------------------------------------------------ 37 aetherlang（DeepSeek / Gemini 同款极简画布 · 常驻最近对话 · 交付中心） */

/* 在 AI 指令对话页隐藏右下角客服悬浮球与页脚，保证移动端输入舱纯粹干净 */
body:has(.gmi-layout) .support-widget {
  display: none !important;
}
.app-column:has(.gmi-layout) {
  background: var(--card);
}
.app-column:has(.gmi-layout) .app-main {
  max-width: none;
  width: 100%;
  padding: 0;
  margin: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.app-column:has(.gmi-layout) .app-foot {
  display: none;
}

.gmi-layout {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-height: 100dvh;
  background: var(--card);
}

/* 「最近对话」浮层弹窗（PC 端与移动端均默认收起，点击左上角「最近对话」弹出） */
.gmi-rail {
  position: fixed;
  top: 56px;
  left: calc(var(--sidebar-w) + 10px);
  width: 320px;
  max-height: min(540px, 74dvh);
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.16);
  display: none;
  flex-direction: column;
  padding: 14px 12px;
  gap: 12px;
  z-index: 150;
}
.gmi-rail.is-open {
  display: flex;
  animation: rise-in 0.18s var(--ease-out) both;
}
.gmi-rail-backdrop {
  display: none;
}
.gmi-rail-backdrop:not([hidden]) {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 145;
  background: rgba(15, 23, 42, 0.18);
}
.gmi-rail-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.gmi-new-chat-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text-1);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background var(--speed) var(--ease), border-color var(--speed) var(--ease);
}
.gmi-new-chat-btn:hover {
  background: var(--hover);
  border-color: var(--control);
}
.gmi-new-chat-btn svg {
  width: 15px;
  height: 15px;
  color: var(--blue);
}
.gmi-rail-close-btn {
  display: inline-flex;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  cursor: pointer;
}
.gmi-rail-close-btn:hover {
  background: var(--bg-soft);
  color: var(--text-1);
}
.gmi-rail-close-btn svg {
  width: 16px;
  height: 16px;
}

.gmi-rail-section {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.gmi-rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-3);
}
.gmi-rail-head a {
  color: var(--blue);
  font-weight: 500;
  text-decoration: none;
}
.gmi-rail-empty {
  padding: 20px 10px;
  font-size: 12.5px;
  color: var(--text-3);
  text-align: center;
}
.gmi-rail-list {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.gmi-rail-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 9px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--text-1);
  transition: background var(--speed) var(--ease);
}
.gmi-rail-item:hover {
  background: var(--hover);
}
.gmi-rail-item.is-active {
  background: var(--blue-wash);
}
.gmi-rail-item-title {
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gmi-rail-item.is-active .gmi-rail-item-title {
  color: var(--blue-ink);
  font-weight: 600;
}
.gmi-rail-item small {
  font-size: 11px;
  color: var(--text-3);
}

.gmi-shell {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: var(--card);
  color: var(--text-1);
}

/* DeepSeek 同款极简顶部栏 */
.gmi-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
  padding: 6px 18px;
  background: color-mix(in srgb, var(--card) 92%, transparent);
  backdrop-filter: blur(12px);
}
.gmi-topbar-left,
.gmi-topbar-right {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.gmi-topbar-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
}

.gmi-top-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  color: var(--text-1);
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  flex-shrink: 0;
  transition: background var(--speed) var(--ease), border-color var(--speed) var(--ease);
}
.gmi-top-icon-btn:hover {
  background: var(--hover);
  border-color: var(--control);
}
.gmi-top-icon-btn svg {
  width: 15px;
  height: 15px;
}

.gmi-icon-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text-2);
  font-size: 11.5px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--speed) var(--ease), color var(--speed) var(--ease);
}
.gmi-icon-pill:hover {
  background: var(--hover);
  color: var(--text-1);
}
.gmi-icon-pill svg {
  width: 13px;
  height: 13px;
}

/* 中央主视口：空状态像 DeepSeek 一样上下分布（中间 Logo+问候，底部输入舱） */
.gmi-viewport {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  padding: 10px 20px 18px;
  gap: 16px;
}
.gmi-viewport.is-welcome {
  min-height: calc(100dvh - 52px);
}

/* DeepSeek 同款正中央 VOH Logo + 一句话问候 */
.gmi-welcome-center {
  margin: auto 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  gap: 12px;
  padding: 18px 12px;
}
.gmi-hero-logo-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--blue);
}
.gmi-voh-logo {
  height: 26px;
  width: auto;
  color: var(--blue);
}
.gmi-greeting-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
  color: var(--text-1);
}

/* DeepSeek 同款贴底圆角输入舱 */
.gmi-dock-wrap {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: auto;
}
.gmi-dock-wrap.is-sticky {
  position: sticky;
  bottom: 0;
  padding: 8px 0 2px;
  background: linear-gradient(to top, var(--card) 85%, transparent);
}

.gmi-omnibox {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 13px 9px;
  border-radius: 18px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  transition: background var(--speed) var(--ease), border-color var(--speed) var(--ease), box-shadow var(--speed) var(--ease);
}
.gmi-omnibox:focus-within {
  background: var(--card);
  border-color: var(--control);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
}
html[data-theme="dark"] .gmi-omnibox:focus-within {
  background: #1e1f22;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.42);
}

.gmi-omnibox textarea {
  width: 100%;
  min-height: 32px;
  max-height: 120px;
  border: none;
  background: transparent;
  color: var(--text-1);
  font-size: 13.5px;
  line-height: 1.48;
  resize: none;
  padding: 0 2px;
  outline: none;
  box-shadow: none;
  scrollbar-width: none;
}
.gmi-omnibox textarea::-webkit-scrollbar {
  display: none;
}
.gmi-omnibox textarea::placeholder {
  color: var(--text-3);
}
.gmi-omnibox textarea:focus {
  border: none;
  outline: none;
  box-shadow: none;
}

.gmi-omnibox-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.gmi-omnibox-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
}
.gmi-tool-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-1);
  white-space: nowrap;
}
.gmi-chip-kong {
  width: 13px;
  height: 13px;
  color: var(--blue);
  flex-shrink: 0;
}

/* 纯圆向上箭头发送按钮 */
.gmi-send-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: var(--text-1);
  color: var(--card);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}
.gmi-send-circle:hover {
  transform: scale(1.04);
  background: var(--blue);
  color: #ffffff;
}
.gmi-send-circle:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  transform: none;
}
.gmi-send-circle svg {
  width: 14px;
  height: 14px;
}

/* 对话流容器与回合排版（Gemini 无框 AI 排版 + 右侧柔和浅灰蓝用户胶囊） */
.gmi-stream-wrap {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.gmi-stream-wrap:empty {
  display: none;
}

.gmi-user-row {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}
.gmi-user-bubble {
  max-width: 78%;
  padding: 9px 14px;
  border-radius: 18px 18px 4px 18px;
  background: var(--bg-soft);
  color: var(--text-1);
  font-size: 13.5px;
  line-height: 1.58;
  word-break: break-word;
}
html[data-theme="dark"] .gmi-user-bubble {
  background: #282a2c;
}

.gmi-ai-row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  width: 100%;
}
.gmi-ai-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--blue);
  flex-shrink: 0;
  margin-top: 1px;
}
.gmi-ai-avatar svg {
  width: 17px;
  height: 17px;
}
.gmi-ai-avatar.is-spinning svg {
  animation: gmiStarSpin 2.4s infinite ease-in-out;
}
@keyframes gmiStarSpin {
  0% { transform: rotate(0deg) scale(0.92); opacity: 0.75; }
  50% { transform: rotate(180deg) scale(1.1); opacity: 1; }
  100% { transform: rotate(360deg) scale(0.92); opacity: 0.75; }
}

.gmi-ai-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.gmi-ai-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}
.gmi-ai-meta strong {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}
.gmi-ai-meta small {
  font-size: 12px;
  color: var(--text-3);
}

/* Gemini 同款「显示思路 (Show thinking)」折叠胶囊与左侧导轨 */
.gmi-thinking-box {
  align-self: flex-start;
  width: 100%;
  max-width: 680px;
}
.gmi-thinking-summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text-2);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  user-select: none;
  transition: background var(--speed) var(--ease), color var(--speed) var(--ease);
}
.gmi-thinking-summary::-webkit-details-marker {
  display: none;
}
.gmi-thinking-summary:hover {
  background: var(--hover);
  color: var(--text-1);
}
.gmi-thinking-summary svg {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease;
}
.gmi-thinking-box[open] .gmi-thinking-summary svg {
  transform: rotate(90deg);
}

.gmi-thinking-head {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--blue-wash);
  color: var(--blue-ink);
  font-size: 13px;
  font-weight: 500;
}
.gmi-thinking-timer {
  font-family: var(--mono);
  font-size: 12px;
  opacity: 0.85;
}

.gmi-thinking-steps {
  list-style: none;
  margin: 10px 0 4px 14px;
  padding: 4px 0 4px 18px;
  border-left: 2px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.gmi-thinking-steps[hidden] {
  display: none !important;
}
.gmi-step {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  opacity: 0.4;
  transition: opacity 0.25s ease;
}
.gmi-step.is-active,
.gmi-step.is-done {
  opacity: 1;
}
.gmi-step-indicator {
  position: absolute;
  left: -23px;
  top: 5px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--line);
}
.gmi-step.is-active .gmi-step-indicator {
  background: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-wash);
}
.gmi-step.is-done .gmi-step-indicator {
  background: var(--ok);
}
.gmi-step strong {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}
.gmi-step p {
  margin: 2px 0 0;
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.5;
}

/* AI 回复正文（直接排印在画布上，支持换行分段） */
.gmi-ai-prose {
  font-size: 13.8px;
  line-height: 1.66;
  color: var(--text-1);
  white-space: pre-wrap;
  word-break: break-word;
}
.gmi-ai-prose.is-error {
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--bad-wash);
  color: var(--bad);
  font-size: 14px;
}

.gmi-confirm-plan-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}
.gmi-confirm-hint {
  font-size: 12px;
  color: var(--text-3);
}

/* 每个对话专属的「交付文案区域 + 历史交付文件列表」 */
.gmi-delivery-hub[hidden] {
  display: none !important;
}
.gmi-delivery-hub {
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.gmi-delivery-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.gmi-delivery-head strong {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-1);
}
.gmi-delivery-head strong svg {
  width: 16px;
  height: 16px;
  color: var(--blue);
}
.gmi-delivery-head small {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-3);
}
.gmi-delivery-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.gmi-delivery-empty {
  padding: 14px;
  border-radius: 12px;
  background: var(--card);
  border: 1px dashed var(--line);
  font-size: 13px;
  color: var(--text-3);
  text-align: center;
}
.gmi-delivery-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 14px;
}
.gmi-delivery-note-card,
.gmi-delivery-files-card {
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.gmi-delivery-subhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
}
.gmi-delivery-subhead code {
  font-size: 11px;
  color: var(--blue-ink);
  background: var(--blue-wash);
  padding: 2px 6px;
  border-radius: 6px;
}
.gmi-delivery-note-body {
  margin: 0;
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-1);
  white-space: pre-wrap;
  word-break: break-word;
  background: var(--bg-soft);
  padding: 10px 12px;
  border-radius: 10px;
}
.gmi-delivery-file-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 240px;
  overflow-y: auto;
}
.gmi-delivery-file-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--bg-soft);
  border: 1px solid transparent;
}
.gmi-delivery-file-item.is-latest {
  border-color: var(--blue-tint);
}
.gmi-delivery-file-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.gmi-delivery-file-info > div {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.gmi-delivery-file-info strong {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}
.gmi-delivery-file-info small {
  font-size: 11.5px;
  color: var(--text-3);
}
.gmi-ver-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: 5px;
  background: var(--blue-wash);
  color: var(--blue-ink);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
}
.gmi-latest-tag {
  font-size: 11px;
  font-weight: 600;
  color: var(--ok);
  background: var(--ok-wash);
  padding: 1px 6px;
  border-radius: 5px;
}
.gmi-delivery-file-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.gmi-ai-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.gmi-ai-points li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-2);
}
.gmi-ai-points svg {
  width: 15px;
  height: 15px;
  color: var(--blue);
  flex-shrink: 0;
}

/* Gemini Canvas / Artifact 风格圆角成果胶囊卡 */
.gmi-canvas-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 20px;
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  margin-top: 4px;
}
.gmi-canvas-card-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.gmi-canvas-badge {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--card);
  color: var(--blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--line-soft);
}
.gmi-canvas-badge svg {
  width: 18px;
  height: 18px;
}
.gmi-canvas-meta strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}
.gmi-canvas-meta small {
  display: block;
  font-size: 12px;
  color: var(--text-3);
  margin-top: 2px;
}
.gmi-canvas-card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.gmi-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text-1);
  font-size: 12.5px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background var(--speed) var(--ease), border-color var(--speed) var(--ease);
}
.gmi-pill-btn:hover {
  background: var(--hover);
  border-color: var(--control);
}
.gmi-pill-btn svg {
  width: 14px;
  height: 14px;
}
.gmi-pill-btn.is-accent {
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}
.gmi-pill-btn.is-accent:hover {
  background: var(--blue-hover);
}

.gmi-live-turn {
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
}
.gmi-live-turn[hidden] {
  display: none;
}

/* 可展开的三维阵列与沙盒检视抽屉 */
.gmi-inspector {
  border-radius: 20px;
  border: 1px solid var(--line-soft);
  background: var(--bg-soft);
  overflow: hidden;
}
.gmi-inspector-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  cursor: pointer;
  list-style: none;
  user-select: none;
  font-size: 13px;
  color: var(--text-2);
}
.gmi-inspector-summary::-webkit-details-marker {
  display: none;
}
.gmi-inspector-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  color: var(--text-1);
}
.gmi-inspector-title svg {
  width: 16px;
  height: 16px;
  color: var(--blue);
}
.gmi-inspector-summary small {
  color: var(--blue-ink);
  font-weight: 500;
}
.gmi-inspector-body {
  padding: 18px;
  border-top: 1px solid var(--line-soft);
  background: var(--card);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.gmi-subpage-wrap {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: 20px 24px 40px;
}

.ai-composer-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 8px;
  border-top: 1px solid var(--line-soft);
}
.ai-engine-guarantees {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  color: var(--text-2);
  font-size: 12px;
}
.ai-engine-guarantees span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.ai-engine-guarantees svg {
  width: 14px;
  height: 14px;
  color: var(--ok);
}
.ai-version-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--blue-wash);
  color: var(--blue-ink);
  font-size: 12px;
  font-weight: 600;
  font-family: var(--mono);
}
.inline-form {
  display: inline-flex;
  margin: 0;
}
.full-width {
  width: 100%;
  justify-content: center;
}

.ai-canvas-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}
.ai-band-filter {
  height: 32px;
  padding: 0 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--control);
  background: var(--card);
  color: var(--text-1);
  font-size: 12px;
}
.ai-canvas-stage {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ai-cmd-canvas {
  width: 100%;
  height: 320px;
  border-radius: var(--r-md);
  background: #0f141c;
  border: 1px solid var(--line);
  cursor: grab;
  display: block;
}
.ai-cmd-canvas:active {
  cursor: grabbing;
}
.ai-canvas-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  color: var(--text-2);
}
.ai-canvas-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  display: inline-block;
}
.legend-impulse { background: #d97706; }
.legend-repeating { background: #7c3aed; }
.legend-chain { background: #0d9488; }
.legend-cond { background: transparent; border: 2px solid #f59e0b; }
.ai-canvas-tooltip {
  padding: 8px 12px;
  border-radius: var(--r-sm);
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ai-sim-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.ai-sim-select {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-2);
}
.ai-sim-select select {
  height: 32px;
  padding: 0 8px;
  border-radius: var(--r-sm);
  border: 1px solid var(--control);
  background: var(--card);
  color: var(--text-1);
  font-size: 12px;
}
.ai-hud-preview {
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--line);
  margin-bottom: 14px;
}
.ai-hud-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--text-2);
}
.ai-hud-screen {
  background: #11161f;
  color: #f8fafc;
  padding: 18px 16px;
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  font-family: var(--mono);
}
.ai-hud-title-box {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ai-hud-main-title {
  font-size: 18px;
  font-weight: 700;
}
.ai-hud-sub-title {
  font-size: 13px;
}
.ai-hud-chat-box {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 12px;
  background: rgba(0, 0, 0, 0.38);
  padding: 8px 10px;
  border-radius: 6px;
  max-width: 560px;
}
.ai-hud-chat-line small {
  color: #94a3b8;
  margin-right: 6px;
}
.ai-hud-actionbar-box {
  text-align: center;
  font-size: 13px;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.45);
  border-radius: 6px;
  align-self: center;
}
.ai-hud-fx-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: var(--bg-soft);
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
}
.ai-fx-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--card);
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12px;
}
.ai-sandbox-tables {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.ai-subtable-title {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}
.ai-score-val {
  font-family: var(--mono);
  color: var(--blue-ink);
}
.ai-ctrl-tag {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--blue-wash);
  color: var(--blue-ink);
  font-family: var(--mono);
  font-size: 12px;
}

.ai-bands-accordion {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ai-band-details {
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--card);
  overflow: hidden;
}
.ai-band-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  background: var(--bg-soft);
  cursor: pointer;
  list-style: none;
}
.ai-band-summary::-webkit-details-marker {
  display: none;
}
.ai-band-summary div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.ai-band-table-wrap {
  padding: 0;
  border-top: 1px solid var(--line-soft);
}
.ai-cb-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.ai-cb-impulse {
  background: #fff4e2;
  color: #b45309;
}
.ai-cb-repeating {
  background: #f3e8ff;
  color: #6d28d9;
}
.ai-cb-chain {
  background: #ccfbf1;
  color: #0f766e;
}
html[data-theme="dark"] .ai-cb-impulse {
  background: #3b2506;
  color: #fbbf24;
}
html[data-theme="dark"] .ai-cb-repeating {
  background: #2e1065;
  color: #c4b5fd;
}
html[data-theme="dark"] .ai-cb-chain {
  background: #134e4a;
  color: #5eead4;
}
.ai-cmd-code {
  display: inline-block;
  max-width: 440px;
  white-space: pre-wrap;
  word-break: break-all;
  font-family: var(--mono);
  font-size: 12px;
}
.ai-proj-link {
  color: var(--text-1);
  text-decoration: none;
}
.ai-proj-link:hover {
  color: var(--blue);
}
.block {
  display: block;
}

@media (max-width: 960px) {
  .ai-sandbox-tables,
  .gmi-delivery-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .app-main:has(.gmi-layout) {
    padding: var(--mobile-bar-h) 0 0;
  }
  .gmi-layout {
    min-height: calc(100dvh - var(--mobile-bar-h));
  }
  .gmi-shell {
    min-height: calc(100dvh - var(--mobile-bar-h));
  }
  .gmi-topbar {
    top: var(--mobile-bar-h);
    min-height: 38px;
    padding: 4px 12px;
  }
  .gmi-rail {
    top: calc(var(--mobile-bar-h) + 44px);
    left: 12px;
    right: 12px;
    width: auto;
    max-height: 68dvh;
  }
}

@media (max-width: 720px) {
  .ai-cmd-canvas {
    height: 220px;
  }
  .gmi-hide-mobile {
    display: none !important;
  }
  .gmi-topbar-title {
    font-size: 12.5px;
    max-width: 135px;
  }
  .gmi-top-icon-btn {
    height: 28px;
    padding: 0 8px;
    font-size: 11.5px;
  }
  .gmi-icon-pill {
    height: 26px;
    padding: 0 8px;
    font-size: 11px;
  }
  .gmi-viewport {
    padding: 6px 12px 12px;
    gap: 12px;
  }
  .gmi-viewport.is-welcome {
    min-height: calc(100dvh - 88px);
  }
  .gmi-voh-logo {
    height: 22px;
  }
  .gmi-greeting-title {
    font-size: 15px;
  }
  .gmi-stream-wrap {
    gap: 14px;
  }
  .gmi-user-bubble {
    max-width: 86%;
    padding: 7px 12px;
    font-size: 13px;
    border-radius: 15px 15px 4px 15px;
  }
  .gmi-ai-row {
    gap: 8px;
  }
  .gmi-ai-avatar {
    width: 22px;
    height: 22px;
  }
  .gmi-ai-avatar svg {
    width: 14px;
    height: 14px;
  }
  .gmi-ai-meta strong {
    font-size: 12.5px;
  }
  .gmi-ai-meta small {
    font-size: 11px;
  }
  .gmi-ai-prose {
    font-size: 13px;
    line-height: 1.58;
  }
  .gmi-omnibox {
    gap: 4px;
    padding: 8px 11px 7px;
    border-radius: 15px;
  }
  .gmi-omnibox textarea {
    min-height: 26px;
    font-size: 13px;
  }
  .gmi-tool-chip {
    height: 24px;
    padding: 0 8px;
    font-size: 11px;
  }
  .gmi-send-circle {
    width: 28px;
    height: 28px;
  }
  .gmi-send-circle svg {
    width: 13px;
    height: 13px;
  }
  .gmi-live-card {
    padding: 12px 13px;
    border-radius: 14px;
  }
  .gmi-live-thought-body {
    max-height: 88px;
    font-size: 12px;
  }
}

/* ---------------- AI 指令工坊：Markdown 干净排印 + 实时流光进度条与思考流视窗 ---------------- */
.gmi-ai-prose strong {
  font-weight: 650;
  color: var(--text-1);
}
.gmi-md-heading {
  display: inline-block;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-1);
}
.gmi-inline-code {
  font-family: var(--mono);
  font-size: 12.5px;
  padding: 1px 6px;
  border-radius: 5px;
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  color: var(--blue-ink);
}
.gmi-md-pre {
  margin: 6px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 12.5px;
  line-height: 1.55;
}

.gmi-user-row[hidden],
.gmi-confirm-plan-bar[hidden],
.gmi-live-thought-box[hidden],
.gmi-live-milestones[hidden] {
  display: none !important;
}

.gmi-live-card {
  width: 100%;
  max-width: 680px;
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 11px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
}
.gmi-live-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.gmi-live-status-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}
.gmi-live-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  flex-shrink: 0;
  animation: gmi-pulse-dot 1.6s ease-in-out infinite;
}
@keyframes gmi-pulse-dot {
  0%, 100% {
    transform: scale(0.92);
    opacity: 0.65;
  }
  50% {
    transform: scale(1.18);
    opacity: 1;
  }
}
.gmi-live-card .gmi-thinking-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  line-height: 1.4;
}
.gmi-live-metrics {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  flex-shrink: 0;
}
.gmi-thinking-pct {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--blue-ink);
  font-variant-numeric: tabular-nums;
}
.gmi-live-card .gmi-thinking-timer {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.gmi-progress-track {
  position: relative;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: var(--bg-soft);
  overflow: hidden;
}
.gmi-progress-fill {
  position: relative;
  height: 100%;
  border-radius: 999px;
  background: var(--blue);
  overflow: hidden;
  transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.gmi-progress-fill::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.38) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: translateX(-100%);
  animation: gmi-bar-shimmer 1.75s ease-in-out infinite;
}
@keyframes gmi-bar-shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.gmi-live-thought-box {
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.gmi-live-thought-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-3);
}
.gmi-live-thought-head small {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--blue-ink);
  font-variant-numeric: tabular-nums;
}
.gmi-live-thought-body {
  max-height: 108px;
  overflow-y: auto;
  font-size: 12.5px;
  line-height: 1.62;
  color: var(--text-2);
  white-space: pre-wrap;
  word-break: break-word;
}

.gmi-live-milestones {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.gmi-milestone-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--ok-wash);
  color: var(--ok);
  font-size: 11.5px;
  font-weight: 600;
}
.gmi-milestone-chip svg {
  width: 12px;
  height: 12px;
}
.gmi-milestone-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ok);
  flex-shrink: 0;
}

.gmi-live-card .gmi-thinking-steps {
  margin: 2px 0 2px 10px;
}

/* CSP 安全百分比宽度映射 (0%~100%) */
.gmi-pct-0 { width: 0%; } .gmi-pct-1 { width: 1%; } .gmi-pct-2 { width: 2%; } .gmi-pct-3 { width: 3%; } .gmi-pct-4 { width: 4%; }
.gmi-pct-5 { width: 5%; } .gmi-pct-6 { width: 6%; } .gmi-pct-7 { width: 7%; } .gmi-pct-8 { width: 8%; } .gmi-pct-9 { width: 9%; }
.gmi-pct-10 { width: 10%; } .gmi-pct-11 { width: 11%; } .gmi-pct-12 { width: 12%; } .gmi-pct-13 { width: 13%; } .gmi-pct-14 { width: 14%; }
.gmi-pct-15 { width: 15%; } .gmi-pct-16 { width: 16%; } .gmi-pct-17 { width: 17%; } .gmi-pct-18 { width: 18%; } .gmi-pct-19 { width: 19%; }
.gmi-pct-20 { width: 20%; } .gmi-pct-21 { width: 21%; } .gmi-pct-22 { width: 22%; } .gmi-pct-23 { width: 23%; } .gmi-pct-24 { width: 24%; }
.gmi-pct-25 { width: 25%; } .gmi-pct-26 { width: 26%; } .gmi-pct-27 { width: 27%; } .gmi-pct-28 { width: 28%; } .gmi-pct-29 { width: 29%; }
.gmi-pct-30 { width: 30%; } .gmi-pct-31 { width: 31%; } .gmi-pct-32 { width: 32%; } .gmi-pct-33 { width: 33%; } .gmi-pct-34 { width: 34%; }
.gmi-pct-35 { width: 35%; } .gmi-pct-36 { width: 36%; } .gmi-pct-37 { width: 37%; } .gmi-pct-38 { width: 38%; } .gmi-pct-39 { width: 39%; }
.gmi-pct-40 { width: 40%; } .gmi-pct-41 { width: 41%; } .gmi-pct-42 { width: 42%; } .gmi-pct-43 { width: 43%; } .gmi-pct-44 { width: 44%; }
.gmi-pct-45 { width: 45%; } .gmi-pct-46 { width: 46%; } .gmi-pct-47 { width: 47%; } .gmi-pct-48 { width: 48%; } .gmi-pct-49 { width: 49%; }
.gmi-pct-50 { width: 50%; } .gmi-pct-51 { width: 51%; } .gmi-pct-52 { width: 52%; } .gmi-pct-53 { width: 53%; } .gmi-pct-54 { width: 54%; }
.gmi-pct-55 { width: 55%; } .gmi-pct-56 { width: 56%; } .gmi-pct-57 { width: 57%; } .gmi-pct-58 { width: 58%; } .gmi-pct-59 { width: 59%; }
.gmi-pct-60 { width: 60%; } .gmi-pct-61 { width: 61%; } .gmi-pct-62 { width: 62%; } .gmi-pct-63 { width: 63%; } .gmi-pct-64 { width: 64%; }
.gmi-pct-65 { width: 65%; } .gmi-pct-66 { width: 66%; } .gmi-pct-67 { width: 67%; } .gmi-pct-68 { width: 68%; } .gmi-pct-69 { width: 69%; }
.gmi-pct-70 { width: 70%; } .gmi-pct-71 { width: 71%; } .gmi-pct-72 { width: 72%; } .gmi-pct-73 { width: 73%; } .gmi-pct-74 { width: 74%; }
.gmi-pct-75 { width: 75%; } .gmi-pct-76 { width: 76%; } .gmi-pct-77 { width: 77%; } .gmi-pct-78 { width: 78%; } .gmi-pct-79 { width: 79%; }
.gmi-pct-80 { width: 80%; } .gmi-pct-81 { width: 81%; } .gmi-pct-82 { width: 82%; } .gmi-pct-83 { width: 83%; } .gmi-pct-84 { width: 84%; }
.gmi-pct-85 { width: 85%; } .gmi-pct-86 { width: 86%; } .gmi-pct-87 { width: 87%; } .gmi-pct-88 { width: 88%; } .gmi-pct-89 { width: 89%; }
.gmi-pct-90 { width: 90%; } .gmi-pct-91 { width: 91%; } .gmi-pct-92 { width: 92%; } .gmi-pct-93 { width: 93%; } .gmi-pct-94 { width: 94%; }
.gmi-pct-95 { width: 95%; } .gmi-pct-96 { width: 96%; } .gmi-pct-97 { width: 97%; } .gmi-pct-98 { width: 98%; } .gmi-pct-99 { width: 99%; }
.gmi-pct-100 { width: 100%; }



