/* 本司工具箱 —— 全局样式（v3.1：macOS 系统级 App 风格）
 *
 * 本文件在各页面的内联 <style> 之后加载，统一接管：
 * 布局(.app/.sidebar/.main)、页面标题(header)、卡片(.panel)、按钮(button)、
 * 输入框、表格 等通用外观；并提供 .btn/.card/.pill/.toast/.modal 等工具类。
 *
 * 设计基准：prompt/zhanhai-v3.1-prototype.html —— 一切以该原型为准。
 * 页面专属选择器（.drop/.clause/.tree 等）不在此文件，沿用各自内联样式。
 */

/* ============ CSS 变量（v3.1 设计令牌） ============ */
:root {
  /* 背景灰阶：v3.1 加深 canvas，强化卡片对比 */
  --bg-primary:    #FFFFFF;                     /* 卡片纯白 */
  --bg-canvas:     #E8E8ED;                     /* 主背景（加深） */
  --bg-canvas-2:   #EDEDF2;                     /* 主背景过渡色 */
  --bg-secondary:  #E8E8ED;                     /* = canvas（兼容旧引用） */
  --bg-elevated:   rgba(255, 255, 255, 0.92);   /* 浮层毛玻璃 */
  --bg-sidebar:    rgba(232, 232, 237, 0.78);   /* 侧边栏毛玻璃 */

  /* 文字 */
  --text-primary:    #1D1D1F;
  --text-secondary:  #515154;
  --text-tertiary:   #86868B;
  --text-quaternary: #B0B0B5;

  /* 主色 */
  --accent:        #0071E3;
  --accent-hover:  #0077ED;
  --accent-bg:     rgba(0, 113, 227, 0.10);

  --success: #34C759;
  --warning: #FF9500;
  --danger:  #FF3B30;

  /* SF Symbols 标准色板：功能模块图标用色 */
  --color-blue:   #0071E3;
  --color-green:  #34C759;
  --color-red:    #FF3B30;
  --color-orange: #FF9500;
  --color-yellow: #FFCC00;
  --color-purple: #AF52DE;
  --color-gray:   #8E8E93;
  --color-teal:   #5AC8FA;
  --color-indigo: #5856D6;
  --color-pink:   #FF2D55;
  --color-mint:   #00C7BE;

  /* 浅色背景上的橙色文字（与 .pill-warning 一致，保证对比度） */
  --warning-text: #C77800;

  /* 边框 / 分割线 */
  --border-light:  rgba(0, 0, 0, 0.08);
  --border-medium: rgba(0, 0, 0, 0.12);
  --border-strong: rgba(0, 0, 0, 0.16);
  --separator:     rgba(60, 60, 67, 0.18);
  --border:        rgba(0, 0, 0, 0.08);   /* 兼容旧引用 */
  --border-hair:   rgba(0, 0, 0, 0.06);   /* 兼容旧引用 */

  /* 阴影：v3.1 双层，卡片更立体 */
  --shadow-1:    0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-2:    0 4px 12px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-3:    0 12px 32px rgba(0, 0, 0, 0.10), 0 4px 8px rgba(0, 0, 0, 0.06);
  --shadow-icon: 0 2px 6px rgba(0, 0, 0, 0.15);
  --shadow-sm: var(--shadow-1);   /* 兼容旧引用 */
  --shadow-md: var(--shadow-2);
  --shadow-lg: var(--shadow-3);

  /* 圆角 */
  --radius-icon: 8px;
  --radius-sm:   8px;
  --radius-md:   16px;   /* 卡片 */
  --radius-lg:   22px;   /* 模态框 */

  /* 顶部品牌渐变条带 */
  --hero-gradient: linear-gradient(135deg,
    rgba(0, 113, 227, 0.12) 0%,
    rgba(175, 82, 222, 0.08) 45%,
    rgba(255, 149, 0, 0.10) 100%);

  /* 字体 */
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display",
                  "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-text:    -apple-system, BlinkMacSystemFont, "SF Pro Text",
                  "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font: var(--font-text);   /* 兼容旧引用 */

  /* 缓动 */
  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out:   cubic-bezier(0.4, 0, 0.2, 1);
  --duration-fast: 0.18s;
  --duration:      0.28s;
  --transition:    all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============ 基础 ============ */
* { box-sizing: border-box; }
body {
  font-family: var(--font-text);
  color: var(--text-primary);
  letter-spacing: -0.006em;
  font-feature-settings: "tnum" 1, "ss01" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  margin: 0;
  min-height: 100vh;
  /* 环境光：多层径向渐变，让毛玻璃有更丰富的透出 */
  background:
    radial-gradient(ellipse 50% 70% at 0% 0%,    rgba(0, 113, 227, 0.10) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 100% 0%,  rgba(175, 82, 222, 0.07) 0%, transparent 60%),
    radial-gradient(ellipse 40% 50% at 50% 100%, rgba(255, 149, 0, 0.06) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg-canvas-2) 0%, var(--bg-canvas) 100%);
  background-attachment: fixed;
}

/* ============ 布局：左侧栏(固定，可收缩) + 右内容 ============ */
/* 侧边栏 position:fixed 浮在最上层；.app 用 padding-left 给它留位。
   默认收起成 64px 窄条，鼠标移上去展开为 244px 浮层（模仿 Claude Desktop）；
   点侧栏顶部的箭头可「固定」展开，状态存 localStorage。 */
.app {
  display: flex;
  min-height: 100vh;
  padding-left: 244px;
  transition: padding-left var(--duration) var(--ease-out);
}
body:not(.sidebar-pinned) .app { padding-left: 64px; }

.sidebar {
  width: 244px;
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  z-index: 200;
  background: var(--bg-sidebar);
  backdrop-filter: blur(50px) saturate(180%);
  -webkit-backdrop-filter: blur(50px) saturate(180%);
  border-right: 0.5px solid var(--border-medium);
  box-shadow: 1px 0 0 rgba(255, 255, 255, 0.4) inset;
  padding: 18px 12px;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overflow-y: auto;
  transition: width var(--duration) var(--ease-out),
              box-shadow var(--duration) var(--ease-out);
}
/* 未固定：收起成窄条，hover 才展开 */
body:not(.sidebar-pinned) .sidebar { width: 64px; }
body:not(.sidebar-pinned) .sidebar:hover {
  width: 244px;
  box-shadow: var(--shadow-3), 1px 0 0 rgba(255, 255, 255, 0.4) inset;
}
/* 收起态隐藏文字（保留图标）：未固定 且 未 hover 时 */
.sidebar .brand-text,
.sidebar .nav-item > span:not(.nav-icon),
.sidebar .nav-section-label,
.sidebar .sidebar-footer-row > div,
.sidebar .sidebar-pin {
  transition: opacity var(--duration-fast) var(--ease-in-out);
}
body:not(.sidebar-pinned) .sidebar:not(:hover) .brand-text,
body:not(.sidebar-pinned) .sidebar:not(:hover) .nav-item > span:not(.nav-icon),
body:not(.sidebar-pinned) .sidebar:not(:hover) .nav-section-label,
body:not(.sidebar-pinned) .sidebar:not(:hover) .sidebar-footer-row > div,
body:not(.sidebar-pinned) .sidebar:not(:hover) .sidebar-pin {
  opacity: 0;
  pointer-events: none;
}
.sidebar .nav-item { white-space: nowrap; }

/* 顶部「固定/收起」箭头按钮 */
.sidebar-pin {
  margin-left: auto;
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  padding: 0;
  background: transparent;
  background-image: none;
  border: none;
  box-shadow: none;
  color: var(--text-tertiary);
  border-radius: 6px;
}
.sidebar-pin:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--text-primary);
  transform: none;
  box-shadow: none;
}
.sidebar-pin svg {
  width: 15px;
  height: 15px;
  display: block;
  transition: transform var(--duration-fast) var(--ease-out);
}
body.sidebar-pinned .sidebar-pin svg { transform: rotate(180deg); }
.sidebar .brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 18px;
  border-bottom: 0.5px solid var(--separator);
  margin-bottom: 6px;
}
.sidebar .brand-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: -0.04em;
  box-shadow: var(--shadow-icon);
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 50%),
    linear-gradient(135deg, var(--color-blue) 0%, var(--color-purple) 100%);
}
.sidebar .brand-text { line-height: 1.2; }
.sidebar .brand-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.020em;
  color: var(--text-primary);
}
.sidebar .brand-subtitle {
  font-size: 10.5px;
  color: var(--text-tertiary);
  margin-top: 2px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 500;
}
.sidebar .nav {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.sidebar .nav-section-label {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 12px 10px 6px;
}
.sidebar .nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: var(--radius-icon);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -0.004em;
  transition: background var(--duration-fast) var(--ease-in-out),
              transform var(--duration-fast) var(--ease-out);
}
.sidebar .nav-item:hover { background: rgba(0, 0, 0, 0.05); }
.sidebar .nav-item:hover .nav-icon { transform: scale(1.06); }
.sidebar .nav-item.active {
  background: rgba(255, 255, 255, 0.8);
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

/* 导航图标：macOS 系统设置式彩色圆角方块 */
.sidebar .nav-icon {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: var(--radius-icon);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: var(--shadow-icon);
  background-image: linear-gradient(180deg,
    rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 50%);
  transition: transform var(--duration-fast) var(--ease-out);
}
.sidebar .nav-icon svg { width: 15px; height: 15px; display: block; }
.sidebar .nav-icon.blue   { background-color: var(--color-blue); }
.sidebar .nav-icon.green  { background-color: var(--color-green); }
.sidebar .nav-icon.red    { background-color: var(--color-red); }
.sidebar .nav-icon.orange { background-color: var(--color-orange); }
.sidebar .nav-icon.yellow { background-color: var(--color-yellow); color: #4A3500; }
.sidebar .nav-icon.purple { background-color: var(--color-purple); }
.sidebar .nav-icon.gray   { background-color: var(--color-gray); }
.sidebar .nav-icon.teal   { background-color: #30B0C7; }
.sidebar .nav-icon.indigo { background-color: var(--color-indigo); }
.sidebar .nav-icon.pink   { background-color: var(--color-pink); }
.sidebar .nav-icon.mint   { background-color: var(--color-mint); }

.sidebar-footer {
  margin-top: auto;
  padding: 12px 6px 2px;
  border-top: 0.5px solid var(--separator);
  font-size: 11px;
  color: var(--text-tertiary);
}
.sidebar-footer-row { display: flex; align-items: center; gap: 8px; }
.sidebar-footer-avatar {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-blue), var(--color-purple));
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
/* 顶部品牌渐变条带：作为页面级内容区(.app 直接子 .main)的背景，
   只渲染顶部 240px，向下淡出为透明 —— 不波及 bid.html 编辑器里同名的嵌套 .main */
.app > .main {
  background: var(--hero-gradient) no-repeat;
  background-size: 100% 240px;
}

/* ============ 页面标题（沿用各页 <header><h1>） ============ */
header {
  background: transparent;
  color: var(--text-primary);
  padding: 32px 36px 6px;
}
header h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.024em;
  color: var(--text-primary);
}

/* 新版页眉工具类（如页面想用更规范的标题块） */
.page-header { margin-bottom: 24px; }
.page-title {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.024em;
  margin: 0;
}
.page-subtitle {
  font-size: 14.5px;
  color: var(--text-secondary);
  letter-spacing: -0.012em;
  margin: 6px 0 0;
}

/* ============ 内容容器 ============ */
.container {
  padding: 18px 36px 48px;
  max-width: 1320px;
  margin: 0 auto;
  width: 100%;
}

/* ============ 卡片（沿用各页 .panel，并提供 .card 工具类） ============ */
.panel,
.card {
  background: var(--bg-primary);
  border: 0.5px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 22px 26px;
  box-shadow: var(--shadow-1);
  margin-bottom: 16px;
  transition: box-shadow var(--duration) var(--ease-out);
}
.panel:hover,
.card:hover { box-shadow: var(--shadow-2); }
.panel h2,
.card-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.020em;
  color: var(--text-primary);
  margin: 0 0 14px;
}
.card-subtitle {
  font-size: 12.5px;
  color: var(--text-tertiary);
  margin: -8px 0 14px;
}

/* ============ 按钮（沿用各页 <button> 及 .secondary/.ghost/.danger 等） ============ */
button,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 510;
  letter-spacing: -0.004em;
  font-family: var(--font-text);
  border: none;
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
  transition: background var(--duration-fast) var(--ease-in-out),
              transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-in-out);
  background-color: var(--accent);
  background-image: linear-gradient(180deg,
    rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 50%);
  color: #fff;
  box-shadow: 0 1px 3px rgba(0, 113, 227, 0.30);
}
button:hover,
.btn-primary:hover {
  background-color: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0, 113, 227, 0.35);
}
button:active,
.btn:active { transform: scale(0.97); }
button:disabled,
.btn:disabled {
  background-color: rgba(0, 0, 0, 0.06);
  background-image: none;
  color: var(--text-quaternary);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.btn-primary { background-color: var(--accent); color: #fff; }

/* 次要 / 幽灵按钮：白底描边 */
button.secondary, button.sm.ghost,
.btn-secondary {
  background-color: #fff;
  background-image: none;
  color: var(--text-primary);
  border: 0.5px solid var(--border-medium);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
button.secondary:hover,
.btn-secondary:hover {
  background-color: rgba(0, 0, 0, 0.03);
  border-color: var(--border-strong);
  transform: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

button.ghost, .btn-ghost {
  background-color: transparent;
  background-image: none;
  color: var(--text-secondary);
  border: none;
  box-shadow: none;
}
button.ghost:hover, .btn-ghost:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
  transform: none;
  box-shadow: none;
}

button.danger, .btn-danger {
  background-color: var(--danger);
  color: #fff;
  box-shadow: 0 1px 3px rgba(255, 59, 48, 0.30);
}
button.danger:hover, .btn-danger:hover { background-color: #FF453A; }

button.ok {
  background-color: var(--success);
  color: #fff;
  box-shadow: 0 1px 3px rgba(52, 199, 89, 0.30);
}
button.ok:hover { background-color: #2FB350; }

button.sm, .btn-sm { padding: 5px 12px; font-size: 13px; }

/* ============ 输入框 ============ */
input, select, textarea {
  border: 0.5px solid var(--border-medium);
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  font-size: 13.5px;
  font-family: var(--font-text);
  background: var(--bg-primary);
  color: var(--text-primary);
  letter-spacing: -0.004em;
  font-variant-numeric: tabular-nums;
  transition: border-color var(--duration-fast) var(--ease-in-out),
              box-shadow var(--duration-fast) var(--ease-in-out);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.14);
}
input::placeholder, textarea::placeholder { color: var(--text-quaternary); }
textarea { resize: vertical; }
label { font-size: 13px; color: var(--text-secondary); }

/* ============ 表格（无外框 + 斑马纹 + hover 高亮） ============ */
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-variant-numeric: tabular-nums;
}
table th {
  font-weight: 700;
  font-size: 10.5px;
  color: var(--text-secondary);
  padding: 12px 14px;
  text-align: left;
  background: rgba(0, 0, 0, 0.025);
  border-bottom: 0.5px solid var(--separator);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
table td {
  padding: 14px;
  border-bottom: 0.5px solid var(--separator);
  font-size: 13.5px;
  font-variant-numeric: tabular-nums;
}
table tr:last-child td { border-bottom: none; }
table tbody tr { transition: background var(--duration-fast) var(--ease-in-out); }
table tbody tr:nth-child(even) td { background: rgba(0, 0, 0, 0.012); }
table tbody tr:hover td,
table tbody tr:nth-child(even):hover td { background: var(--accent-bg); }

/* ============ 徽章 / 药丸标签 ============ */
.badge,
.pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.01em;
  background: var(--accent-bg);
  color: var(--accent);
}
/* 语义色（旧引用保留） */
.pill-danger  { background: rgba(255, 59, 48, 0.16);  color: var(--danger); }
.pill-warning { background: rgba(255, 149, 0, 0.16);  color: #C77800; }
.pill-success { background: rgba(52, 199, 89, 0.16);  color: #1A8A3F; }
.pill-info    { background: rgba(0, 113, 227, 0.14);  color: var(--accent); }
/* 色板色（v3.1 原型命名） */
.pill-blue    { background: rgba(0, 113, 227, 0.14);  color: var(--color-blue); }
.pill-green   { background: rgba(52, 199, 89, 0.16);  color: #1A8A3F; }
.pill-orange  { background: rgba(255, 149, 0, 0.16);  color: #C77800; }
.pill-red     { background: rgba(255, 59, 48, 0.16);  color: var(--color-red); }
.pill-purple  { background: rgba(175, 82, 222, 0.14); color: var(--color-purple); }
.pill-gray    { background: rgba(60, 60, 67, 0.12);   color: var(--text-secondary); }

/* ============ 模态框（含 P1 的报价单分组管理） ============ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(20px) saturate(120%);
  -webkit-backdrop-filter: blur(20px) saturate(120%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal {
  background: var(--bg-elevated);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  border: 0.5px solid var(--border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-3);
  padding: 26px 28px;
  max-width: 520px;
  width: 90%;
  max-height: 82vh;
  overflow: auto;
}
.modal h3, .modal-title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.020em;
  color: var(--text-primary);
}
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }

/* P1：报价单分组管理 —— 模态框内的分组编辑行 + 批量工具栏 */
.group-edit-row {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 6px;
}
.group-edit-row .g-name {
  flex: 1;
  min-width: 0;
  padding: 6px 9px;
  font-size: 13px;
}
.group-edit-row button { flex-shrink: 0; padding: 5px 10px; font-size: 13px; }

.bulk-toolbar {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  padding: 9px 12px;
  margin-bottom: 12px;
  background: rgba(0, 0, 0, 0.03);
  border-radius: var(--radius-sm);
  font-size: 13px;
}
.bulk-toolbar .bulk-chk { display: flex; align-items: center; gap: 4px; margin: 0; }

/* ============ Toast 通知 ============ */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
}
.toast {
  background: var(--bg-elevated);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 0.5px solid var(--border-light);
  border-left: 3px solid var(--accent);
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: var(--shadow-3);
  margin-bottom: 8px;
  min-width: 260px;
  max-width: 400px;
  font-size: 14px;
  color: var(--text-primary);
  white-space: pre-line;
  animation: toastIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.toast.success { border-left-color: var(--success); }
.toast.error   { border-left-color: var(--danger); }
.toast.info    { border-left-color: var(--accent); }
.toast.warning { border-left-color: var(--warning); }
@keyframes toastIn {
  from { transform: translateX(20px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

/* ============ 空状态 ============ */
.empty-state { text-align: center; padding: 48px 24px; color: var(--text-secondary); }
.empty-icon { font-size: 48px; margin-bottom: 12px; }
.empty-title { font-size: 16px; font-weight: 600; color: var(--text-primary); margin-bottom: 4px; }
.empty-subtitle { font-size: 13px; }

/* ============ 进度条 / 加载动画 ============ */
.progress-bar {
  width: 100%;
  height: 6px;
  background: rgba(0, 0, 0, 0.10);
  border-radius: 999px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s ease;
}
.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============ 滚动条（macOS 风格：细、悬浮显色） ============ */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.20);
  border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(0, 0, 0, 0.32); }

/* ============ 工具类 ============ */
/* 等宽数字：金额 / 价格 / 编号对齐用 */
.tnum { font-variant-numeric: tabular-nums; }
