 /* ===== 主题系统 ===== */
:root, [data-theme=blue] {
--primary-lightest: hsl(222,95%,97%);
--primary-lighter: hsl(222,95%,90%);
--primary-bg-color: hsl(222,95%,97%);
--primary-light: hsl(222,90%,66%);
--primary-color: hsl(222,90%,58%);
--primary-dark: hsl(222,85%,48%);
--primary-darker: hsl(222,80%,38%);
--primary-darkest: hsl(222,75%,28%);
--primary-grad: linear-gradient(135deg, hsl(222,90%,66%) 0%, hsl(222,90%,58%) 52%, hsl(222,85%,48%) 100%);
--ring-focus: 0 0 0 3px color-mix(in srgb, var(--primary-color) 16%, transparent);
--success-color: hsl(152,60%,42%);
--success-light: hsl(152,55%,94%);
--success-dark: hsl(152,60%,32%);
--danger-color: hsl(354,75%,55%);
--danger-light: hsl(354,65%,94%);
--danger-dark: hsl(354,65%,42%);
--warning-color: hsl(38,92%,50%);
--warning-light: hsl(38,80%,93%);
--warning-dark: hsl(38,75%,38%);
--info-color: hsl(199,89%,48%);
--info-light: hsl(199,55%,93%);
--info-dark: hsl(199,65%,32%);
--text-color: #14161f;
--text-secondary: #565a6b;
--text-muted: #8b90a3;
--text-disabled: #c2c6d2;
 --bg-color: #f5f7fb;
 --card-bg: #ffffff;
 --border-color: #e7ebf2;
 --sidebar-bg-start: hsl(222,88%,58%);
 --sidebar-bg-end: hsl(228,62%,40%);
 --sidebar-text: rgba(255,255,255,0.88);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.66);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.28);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
 --sidebar-active-bg: rgba(255,255,255,0.18);
}
 [data-theme=dark] {
 --primary-color: hsl(211,90%,62%);
 --primary-dark: hsl(211,90%,50%);
 --primary-light: hsl(211,90%,72%);
 --primary-bg-color: hsl(211,35%,22%);
 --success-color: hsl(135,60%,55%);
 --danger-color: hsl(0,85%,65%);
 --warning-color: hsl(40,95%,58%);
 --info-color: hsl(185,75%,58%);
 --text-color: #e8ebf0;
 --text-secondary: #aab2c0;
 --text-muted: #6e7788;
 --bg-color: #0d1117;
 --card-bg: #161b22;
 --border-color: #30363d;
 --sidebar-bg-start: hsl(210,20%,18%);
 --sidebar-bg-end: hsl(210,20%,12%);
 --sidebar-text: rgba(255,255,255,0.85);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.65);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.25);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
 --sidebar-active-bg: rgba(255,255,255,0.2);
 }
 [data-theme=light] {
 --primary-color: hsl(211,90%,50%);
 --primary-dark: hsl(211,85%,40%);
 --primary-light: hsl(211,85%,62%);
 --primary-bg-color: hsl(211,50%,95%);
 --success-color: hsl(135,60%,45%);
 --danger-color: hsl(0,80%,55%);
 --warning-color: hsl(40,95%,50%);
 --info-color: hsl(185,70%,45%);
 --text-color: #333;
 --text-secondary: #666;
 --text-muted: #999;
 --bg-color: #fafbfc;
 --card-bg: #ffffff;
 --border-color: #e8ecf0;
 --sidebar-bg-start: hsl(200,15%,92%);
 --sidebar-bg-end: hsl(200,15%,88%);
 --sidebar-text: #444444;
 --sidebar-text-hover: #111111;
 --sidebar-text-active: #111111;
 --sidebar-text-muted: #666666;
 --sidebar-divider: rgba(0,0,0,0.08);
 --sidebar-border: rgba(0,0,0,0.05);
 --sidebar-footer: rgba(0,0,0,0.25);
 --sidebar-hover-bg: rgba(0,0,0,0.05);
 --sidebar-active-bg: rgba(0,0,0,0.1);
 }
 [data-theme=green] {
 --primary-color: hsl(145,70%,42%);
 --primary-dark: hsl(145,70%,32%);
 --primary-light: hsl(145,70%,52%);
 --primary-bg-color: hsl(145,60%,96%);
 --success-color: hsl(135,55%,50%);
 --danger-color: hsl(0,80%,55%);
 --warning-color: hsl(40,95%,50%);
 --info-color: hsl(185,70%,45%);
 --text-color: #222;
 --text-secondary: #555;
 --text-muted: #888;
 --bg-color: #f6fcf8;
 --card-bg: #ffffff;
 --border-color: #e0f0e8;
 --sidebar-bg-start: hsl(145,50%,45%);
 --sidebar-bg-end: hsl(145,45%,36%);
 --sidebar-text: rgba(255,255,255,0.85);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.65);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.25);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
 --sidebar-active-bg: rgba(255,255,255,0.2);
 }
 [data-theme=purple] {
 --primary-color: hsl(265,75%,55%);
 --primary-dark: hsl(265,70%,42%);
 --primary-light: hsl(265,70%,65%);
 --primary-bg-color: hsl(265,50%,96%);
 --success-color: hsl(135,55%,50%);
 --danger-color: hsl(0,80%,55%);
 --warning-color: hsl(40,95%,50%);
 --info-color: hsl(185,70%,45%);
 --text-color: #222;
 --text-secondary: #555;
 --text-muted: #888;
 --bg-color: #faf8fc;
 --card-bg: #ffffff;
 --border-color: #eee6f5;
 --sidebar-bg-start: hsl(265,55%,50%);
 --sidebar-bg-end: hsl(265,48%,40%);
 --sidebar-text: rgba(255,255,255,0.85);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.65);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.25);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
 --sidebar-active-bg: rgba(255,255,255,0.2);
 }
 [data-theme=orange] {
 --primary-color: hsl(30,90%,50%);
 --primary-dark: hsl(30,85%,38%);
 --primary-light: hsl(30,85%,60%);
 --primary-bg-color: hsl(30,70%,96%);
 --success-color: hsl(135,55%,50%);
 --danger-color: hsl(0,80%,55%);
 --warning-color: hsl(40,95%,50%);
 --info-color: hsl(185,70%,45%);
 --text-color: #222;
 --text-secondary: #555;
 --text-muted: #888;
 --bg-color: #fefaf6;
 --card-bg: #ffffff;
 --border-color: #f5e8d8;
 --sidebar-bg-start: hsl(30,70%,52%);
 --sidebar-bg-end: hsl(30,60%,42%);
 --sidebar-text: rgba(255,255,255,0.85);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.65);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.25);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
  --sidebar-active-bg: rgba(255,255,255,0.2);
  }
  /* 系统主题使用媒体查询自动适配 */
  @media (prefers-color-scheme:dark) {
 [data-theme=system] {
 --primary-color: hsl(211,90%,62%);
 --primary-dark: hsl(211,90%,50%);
 --primary-light: hsl(211,90%,72%);
 --primary-bg-color: hsl(211,35%,22%);
 --success-color: hsl(135,60%,55%);
 --danger-color: hsl(0,85%,65%);
 --warning-color: hsl(40,95%,58%);
 --info-color: hsl(185,75%,58%);
 --text-color: #e8ebf0;
 --text-secondary: #aab2c0;
 --text-muted: #6e7788;
 --bg-color: #15192a;
 --card-bg: #1f2438;
 --border-color: #2d344d;
 --sidebar-bg-start: #1a2038;
 --sidebar-bg-end: #11162b;
 --sidebar-text: rgba(255,255,255,0.85);
 --sidebar-text-hover: #ffffff;
 --sidebar-text-active: #ffffff;
 --sidebar-text-muted: rgba(255,255,255,0.65);
 --sidebar-divider: rgba(255,255,255,0.12);
 --sidebar-border: rgba(255,255,255,0.08);
 --sidebar-footer: rgba(255,255,255,0.25);
 --sidebar-hover-bg: rgba(255,255,255,0.1);
 --sidebar-active-bg: rgba(255,255,255,0.2);
 }
 }

 * { margin: 0; padding: 0; box-sizing: border-box; }

 body {
 font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
 background: var(--bg-color);
 color: var(--text-color);
 min-height: 100vh;
 }

 /* ========== Layout ========== */
 .main-layout {
 display: flex;
 height: 100vh;
 overflow: hidden;
 }

 .sidebar {
 width: 180px;
 height: 100vh;
 background: linear-gradient(180deg, var(--sidebar-bg-start) 0%, var(--sidebar-bg-end) 100%);
 color: #fff;
 flex-shrink: 0;
 display: flex;
 flex-direction: column;
 transition: width 0.25s, transform 0.3s;
 z-index: 100;
 overflow: hidden;
 position: sticky;
 top: 0;
 align-self: flex-start;
 }

 .sidebar.collapsed {
 width: 60px;
 }

 .sidebar.collapsed .sidebar-menu a span,
 .sidebar.collapsed .sidebar-footer {
 display: none;
 }

 

 .sidebar.collapsed .sidebar-menu a {
 justify-content: center;
 padding: 14px 0;
 }

 .sidebar.collapsed .sidebar-menu a svg {
 width: 22px;
 height: 22px;
 }

 .sidebar.collapsed .sidebar-menu a.router-link-active {
 border-right: none;
 }

 .sidebar-header {
 padding: 16px 10px;
 text-align: center;
 border-bottom: 1px solid var(--sidebar-divider);
 flex-shrink: 0;
 cursor: pointer;
 transition: background 0.2s;
 }
 .sidebar-header:hover {
 background: rgba(255,255,255,0.05);
 }

 .sidebar-user {
 display: flex;
 flex-direction: column;
 align-items: center;
 gap: 8px;
 }

 .sidebar-avatar {
 width: 48px;
 height: 48px;
 border-radius: 50%;
 background: rgba(255,255,255,0.2);
 color: var(--sidebar-text-active);
 color: var(--sidebar-text-active);
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 20px;
 font-weight: 500;
 flex-shrink: 0;
 }

.sidebar-user-name {
  font-size: 15px;
  font-weight: 500;
  color: var(--sidebar-text);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

 .sidebar.collapsed .sidebar-user-name {
display: none;
}
.sidebar.collapsed .role-badge { display: none; }
.sidebar.collapsed .sidebar-user { gap: 0; }
.sidebar.collapsed .sidebar-header { padding: 10px 6px; }
.sidebar.collapsed .sidebar-menu a { padding: 10px 0; gap: 0; }
.sidebar.collapsed .sidebar-menu { padding: 6px 0; }

 .sidebar.collapsed .sidebar-avatar {
width: 36px;
height: 36px;
font-size: 16px;
}
 .sidebar-menu {
 padding: 10px 0;
 flex: 1;
 overflow-y: auto;
 min-height: 0;
 }

 .sidebar-footer {
 flex-shrink: 0;
 }

 .sidebar-divider {
 margin: 6px 18px;
 border-top: 1px solid var(--sidebar-divider);
 }

 .sidebar-menu a {
 
  display: flex;
  align-items: center;
  padding: 14px 24px;
  color: var(--sidebar-text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  gap: 12px;
  cursor: pointer;
  white-space: nowrap;
  border-radius: 6px;
  margin: 0 8px;
  font-size: 18px;
  font-weight: 500;
}

.sidebar-menu a:hover {
  color: var(--sidebar-text-hover);
  background: var(--sidebar-hover-bg);
  transform: translateX(4px);
  font-size: 18px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.sidebar-menu a.router-link-active {
  color: var(--sidebar-text-active);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, rgba(255, 255, 255, 0.1) 100%);
  border-left: 3px solid var(--sidebar-text-active);
  border-right: none;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
 .sidebar-menu a.router-link-active::before {
 content: \'\';
 position: absolute;
 left: 0; top: 50%; transform: translateY(-50%);
 width: 3px; height: 60%; background: var(--sidebar-text-active);
 border-radius: 0 3px 3px 0;
 border-radius: 0 3px 3px 0;
 }

 .sidebar-menu a svg {
 width: 22px;
 height: 22px;
 min-width: 22px;
 min-height: 22px;
 flex-shrink: 0;
 }

 .user-info {
 display: flex;
 align-items: center;
 gap: 12px;
 padding: 8px;
 border-radius: 8px;
 cursor: pointer;
 transition: background 0.3s;
 }

 .user-info:hover {
 background: rgba(255, 255, 255, 0.1);
 }

 .user-avatar-small {
 width: 40px;
 height: 40px;
 border-radius: 50%;
 background: rgba(255, 255, 255, 0.2);
 color: #fff;
 display: flex;
 align-items: center;
 justify-content: center;
 font-weight: 500;
 font-size: 16px;
 flex-shrink: 0;
 }

 .user-details {
 flex: 1;
 min-width: 0;
 }

 .user-name-small {
 font-size: 15px;
 font-weight: 500;
 white-space: nowrap;
 overflow: hidden;
 text-overflow: ellipsis;
 }

.user-role {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
}

/* 角色徽章（按账户类型显示不同颜色，强化"不同账户不同内容"的视觉隔离） */
.role-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  line-height: 1.4;
  border: 1px solid transparent;
  backdrop-filter: blur(4px);
}
.role-badge::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 6px currentColor;
}
.role-admin   { color: #ffd666; background: rgba(255,214,102,0.16); border-color: rgba(255,214,102,0.4); }
.role-engineer{ color: #91d5ff; background: rgba(145,213,255,0.16); border-color: rgba(145,213,255,0.4); }
.role-dealer { color: #b7eb8f; background: rgba(183,235,143,0.16); border-color: rgba(183,235,143,0.4); }
.role-customer{ color: #ffccc7; background: rgba(255,204,199,0.16); border-color: rgba(255,204,199,0.4); }
/* 头部用户角色小标识 */
.header-role-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.25);
  white-space: nowrap;
}

 .main-content {
 flex: 1;
 display: flex;
 flex-direction: column;
 overflow: hidden;
 }

.header {
  height: 64px;
  background: linear-gradient(135deg, var(--sidebar-bg-start) 0%, var(--sidebar-bg-end) 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  flex-shrink: 0;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

 .header .mobile-menu-btn {
 color: #fff;
 }
 .header .sidebar-toggle-btn {
 color: #fff;
 }
 .header .sidebar-toggle-btn:hover {
 background: rgba(255,255,255,0.2);
 color: #fff;
 }

 .header-left {
 display: flex;
 align-items: center;
 gap: 12px;
 flex: 1;
 }

.header-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 20px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  letter-spacing: 0.5px;
}

 .header-title {
 font-size: 20px;
 font-weight: 500;
 }

 .header-actions {
 display: flex;
 gap: 12px;
 align-items: center;
 }

 .header-user-info {
 display: flex;
 align-items: center;
 gap: 10px;
 padding: 6px 12px;
 border-radius: 8px;
 cursor: pointer;
 transition: background 0.2s;
 }

 .header-user-info:hover {
 background: var(--border-color);
 }

 .sidebar-toggle-btn {
 display: flex;
 align-items: center;
 justify-content: center;
 width: 32px;
 height: 32px;
 border: none;
 background: none;
 cursor: pointer;
 border-radius: 6px;
 font-size: 16px;
 color: var(--text-secondary);
 transition: background 0.2s, color 0.2s;
 }

 .sidebar-toggle-btn:hover {
 background: var(--border-color);
 color: var(--text-color);
 }

 .mobile-menu-btn {
 display: none;
 background: none;
 border: none;
 font-size: 24px;
 cursor: pointer;
 color: var(--text-color);
 }

 .content {
 flex: 1;
 padding: 8px 12px;
 overflow-y: auto;
 }

/* ========== Cards ========== */
.card {
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-bottom: 20px;
  border: 1px solid rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  overflow: hidden;
}

.card:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}
/* .product-card 统一样式已移至下方"商品卡片整体美化"区块 */

 .card-header {
 padding: 16px 24px;
 border-bottom: 1px solid var(--border-color);
 display: flex; align-items: center; justify-content: space-between;
 background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
 }
 .card-title { font-size: 16px; font-weight: 700; color: var(--text-color); letter-spacing: 0.3px; }

 .card-title {
 font-size: 16px;
 font-weight: 500;
 }

 .card-body {
 padding: 24px;
 }

 /* ========== Stat Cards ========== */
 .stats-row {
 display: grid;
 grid-template-columns: repeat(6, 1fr);
 gap: 14px;
 margin-bottom: 24px;
 }

.stat-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, var(--card-bg) 100%);
  border-radius: 12px;
  padding: 20px 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color) 0%, var(--primary-light) 100%);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ===== CSS 单色图标系统（替代 emoji） ===== */
.stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px; height: 28px;
    margin: 0 auto 6px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    flex-shrink: 0;
}
/* 各图标颜色与形状 */
.ico-pool    { background: var(--primary-bg-color); color: var(--primary-color); }   /* 接单池 */
.ico-pool::before { content: '⇩'; }
.ico-progress{ background: #fff7e6; color: #fa8c16; }   /* 处理中 */
.ico-progress::before { content: '⟳'; font-variant-emoji: text; }
.ico-list    { background: #f6ffed; color: #52c41a; }   /* 列表 */
.ico-list::before { content: '≡'; }
.ico-total   { background: var(--primary-bg-color); color: var(--primary-color); }   /* 总数 */
.ico-total::before { content: '☰'; }
.ico-device  { background: var(--primary-bg-color); color: var(--primary-color); }   /* 设备 */
.ico-device::before { content: '⬡'; }
.ico-paid    { background: #f6ffed; color: #52c41a; }   /* 已回款 */
.ico-paid::before { content: '✔'; }
.ico-pending { background: #fff7e6; color: #faad14; }   /* 待回款 */
.ico-pending::before { content: '◷'; }
.ico-alert   { background: #fff2f0; color: #ff4d4f; }   /* 预警 */
.ico-alert::before { content: '!'; font-size: 18px; }
.ico-new     { background: var(--primary-bg-color); color: var(--primary-color); }   /* 新建 */
.ico-new::before { content: '+'; font-size: 20px; }
/* 图标尺寸变体 */
.stat-icon-sm { width: 22px; height: 22px; font-size: 12px; border-radius: 6px; }
.stat-icon-lg { width: 36px; height: 36px; font-size: 20px; border-radius: 10px; }
/* 空状态占位图标 */
.empty-icon {
    display: inline-block;
    width: 48px; height: 48px;
    border: 2px dashed #d9d9d9;
    border-radius: 50%;
    position: relative;
    opacity: 0.4;
    margin-bottom: 8px;
}
.empty-icon::after {
    content: '!';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 18px;
    color: #d9d9d9;
    font-weight: 700;
}
/* toast / 提示图标用简单文本 */
.ico-check  { color: #52c41a; }
.ico-cross  { color: #ff4d4f; }
.ico-warn   { color: #faad14; }
.ico-info   { color: var(--info-color); }
/* 通知铃铛图标（CSS绘制） */
.notif-bell {
    display: inline-block;
    width: 18px; height: 18px;
    border: 2px solid currentColor;
    border-radius: 6px 6px 0 0;
    position: relative;
}
.notif-bell::after {
    content: '';
    position: absolute;
    bottom: -4px; left: 50%;
    transform: translateX(-50%);
    width: 4px; height: 4px;
    border-radius: 50%;
    background: currentColor;
}
/* 库存包裹图标（CSS绘制） */
.ico-box {
    display: inline-block;
    width: 40px; height: 32px;
    border: 2px solid #d9d9d9;
    border-radius: 4px;
    position: relative;
    opacity: 0.4;
}
.ico-box::after {
    content: '';
    position: absolute;
    top: -2px; left: 10px; right: 10px;
    height: 6px;
    border: 2px solid #d9d9d9;
    border-bottom: none;
    border-radius: 4px 4px 0 0;
}
/* 设备图标 */
.ico-desktop {
    display: inline-block;
    width: 36px; height: 28px;
    border: 2px solid #d9d9d9;
    border-radius: 4px;
    position: relative;
    opacity: 0.4;
}
.ico-desktop::after {
    content: '';
    position: absolute;
    bottom: -8px; left: 50%;
    transform: translateX(-50%);
    width: 16px; height: 6px;
    border: 2px solid #d9d9d9;
    border-top: none;
    border-radius: 0 0 4px 4px;
}

 .stat-value {
 font-size: 24px;
 font-weight: 600;
 color: var(--primary-color);
 }

 .stat-label {
 font-size: 13px;
 color: var(--text-secondary);
 margin-top: 4px;
 }

 /* ========== Charts ========== */
 .chart-container {
 display: grid;
 grid-template-columns: 1fr 1fr 1fr;
 gap: 16px;
 margin-bottom: 24px;
 }

 .chart-card {
 background: var(--card-bg);
 border-radius: 8px;
 padding: 20px;
 box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
 }

 .chart-card h3 {
 font-size: 16px;
 font-weight: 500;
 margin-bottom: 16px;
 color: var(--text-color);
 }

 .chart-wrapper {
 position: relative;
 height: 250px;
 }

 /* ========== Tables ========== */
 .table-wrapper {
 overflow-x: auto;
 }

 table {
 width: 100%;
 border-collapse: collapse;
 }

 th, td {
 padding: 14px 16px;
 text-align: left;
 border-bottom: 1px solid var(--border-color);
 font-size: 15px;
 }

th {
  background: linear-gradient(180deg, #f8f9fa 0%, #f1f3f5 100%);
  font-weight: 600;
  color: var(--text-color);
  border-bottom: 2px solid var(--primary-color);
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 0.5px;
}

 tr:hover td {
 background: #fafafa;
 }

 /* ========== Status Tags ========== */
.status-tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  transition: all 0.2s ease;
}

.status-pending {
  background: linear-gradient(135deg, var(--warning-light) 0%, #ffe58f 100%);
  color: var(--warning-dark);
  border: 1px solid rgba(250,173,20,0.18);
}
.status-progress {
  background: linear-gradient(135deg, var(--primary-lighter) 0%, var(--primary-light) 100%);
  color: var(--primary-dark);
  border: 1px solid color-mix(in srgb, var(--primary-color) 18%, transparent);
}
.status-done {
  background: linear-gradient(135deg, var(--success-light) 0%, #b7eb8f 100%);
  color: var(--success-dark);
  border: 1px solid rgba(82,196,26,0.18);
}

.status-tag:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

 /* ========== Buttons ========== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 20px; border: none; border-radius: 8px;
  font-size: 14px; font-weight: 600; cursor: pointer;
  transition: all 0.2s ease; gap: 6px; text-decoration: none;
  white-space: nowrap; letter-spacing: 0.3px;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

/* ===== 统一操作按钮系统（尺寸/圆角/阴影一致） ===== */
.btn-primary { 
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%); 
  color: #fff; 
  border: none;
  box-shadow: 0 2px 8px color-mix(in srgb, var(--primary-color) 22%, transparent);
}
.btn-primary:hover { 
  background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-color) 100%); 
  transform: translateY(-1px);
  box-shadow: 0 4px 14px color-mix(in srgb, var(--primary-color) 35%, transparent);
}
.btn-success { background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%); color: #fff; border: none; box-shadow: 0 2px 8px rgba(40,199,111,0.2); }
.btn-success:hover { background: linear-gradient(135deg, #48d98b 0%, var(--success-color) 100%); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(40,199,111,0.35); }
.btn-info { background: linear-gradient(135deg, var(--info-color) 0%, var(--info-dark) 100%); color: #fff; border: none; box-shadow: 0 2px 8px rgba(28,194,223,0.2); }
.btn-info:hover { background: linear-gradient(135deg, #4dd4ec 0%, var(--info-color) 100%); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(28,194,223,0.35); }
.btn-warning { background: linear-gradient(135deg, var(--warning-color) 0%, var(--warning-dark) 100%); color: #fff; border: none; box-shadow: 0 2px 8px rgba(255,159,67,0.2); }
.btn-warning:hover { background: linear-gradient(135deg, #ffb86a 0%, var(--warning-color) 100%); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(255,159,67,0.35); }
.btn-danger { background: linear-gradient(135deg, var(--danger-color) 0%, var(--danger-dark) 100%); color: #fff; border: none; box-shadow: 0 2px 8px rgba(255,91,91,0.2); }
.btn-danger:hover { background: linear-gradient(135deg, #ff7b7b 0%, var(--danger-color) 100%); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(255,91,91,0.35); }

/* ===== 服务器管理：系统信息（现代卡片 + 环形图 + Windows 风格磁盘 + 网络SSL） ===== */
.sysinfo-grid {
display: grid;
grid-template-columns: minmax(220px, 1fr) minmax(300px, 1.4fr) minmax(240px, 1.1fr) minmax(260px, 1.2fr);
gap: 14px;
align-items: stretch;
}
@media (max-width: 1200px){ .sysinfo-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px){ .sysinfo-grid { grid-template-columns: 1fr; } }
.sysinfo-card {
background: #fff;
border: 1px solid var(--border-color, #e8e8e8);
border-radius: 10px;
padding: 16px;
display: flex;
flex-direction: column;
gap: 12px;
box-shadow: 0 2px 8px rgba(0,0,0,0.04);
transition: box-shadow .18s;
}
.sysinfo-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
.sysinfo-card-head { display: flex; align-items: center; gap: 10px; }
.sysinfo-icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 38px;
height: 28px;
border-radius: 6px;
font-size: 10px;
font-weight: 700;
color: #fff;
letter-spacing: 1px;
box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.sysinfo-card-title { font-size: 14px; font-weight: 600; color: var(--text-color); }

/* 内存环形图 */
.sysinfo-card-ring { align-items: center; justify-content: center; }
.sysinfo-ring {
position: relative;
display: inline-flex;
align-items: center;
justify-content: center;
}
.sysinfo-ring svg { display: block; }
.sysinfo-ring-text {
position: absolute;
inset: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
text-align: center;
line-height: 1.15;
}
.sysinfo-ring-pct { font-size: 28px; font-weight: 700; font-family: "Menlo","Consolas",monospace; }
.sysinfo-ring-sub { font-size: 11px; color: var(--text-muted, #999); margin-top: 4px; }
.sysinfo-card-foot { font-size: 12px; color: var(--text-muted, #999); text-align: center; }

/* 磁盘 Windows 风格 */
.sysinfo-disk-stats {
display: flex;
align-items: center;
gap: 12px;
padding: 6px 0;
}
.sysinfo-disk-label { display: block; font-size: 11px; color: var(--text-muted, #999); margin-bottom: 4px; }
.sysinfo-disk-value { display: block; font-size: 24px; font-weight: 700; font-family: "Menlo","Consolas",monospace; }
.sysinfo-disk-value small { font-size: 12px; color: var(--text-muted, #999); font-weight: 500; margin-left: 2px; }
.sysinfo-disk-sep { width: 1px; align-self: stretch; background: #e8e8e8; }
.sysinfo-disk-pct { margin-left: auto; font-size: 22px; font-weight: 700; font-family: "Menlo","Consolas",monospace; }
.sysinfo-disk-bar {
position: relative;
height: 10px;
background: #f0f2f5;
border-radius: 5px;
overflow: hidden;
}
.sysinfo-disk-bar-fill {
height: 100%;
border-radius: 5px;
transition: width .4s ease;
}
.sysinfo-disk-foot {
display: flex;
justify-content: space-between;
font-size: 12px;
color: var(--text-muted, #999);
}
.sysinfo-disk-foot b { color: var(--text-color); }

/* 基础信息卡片 */
.sysinfo-meta-list {
display: flex;
flex-direction: column;
gap: 6px;
}
.sysinfo-meta-row {
display: flex;
align-items: center;
gap: 8px;
font-size: 13px;
padding: 5px 10px;
background: #fafbfc;
border-radius: 5px;
}
.sysinfo-meta-row > span { color: var(--text-muted, #999); min-width: 70px; }
.sysinfo-meta-row > b { color: var(--text-color); font-weight: 500; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.sysinfo-meta-row-full { background: #f5f6fa; }

/* ===== 网络 & SSL 卡片（系统信息页） ===== */
.sysinfo-net-foot {
display: flex;
align-items: center;
gap: 10px;
flex-wrap: wrap;
margin-top: auto;
padding-top: 10px;
border-top: 1px dashed var(--border-color, #e8e8e8);
}
.ssl-renew-msg {
font-size: 11px;
flex: 1;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.ssl-renew-msg.ok { color: var(--success-color, #52c41a); }
.ssl-renew-msg:not(.ok) { color: var(--danger-color, #cf1322); }
/* 开关按钮 */
.ssl-switch {
display: inline-block;
position: relative;
width: 36px;
height: 20px;
background: #d9d9d9;
border-radius: 10px;
cursor: pointer;
margin-left: 10px;
vertical-align: middle;
transition: background .2s ease;
flex-shrink: 0;
}
.ssl-switch.on { background: var(--success-color, #52c41a); }
.ssl-switch-slider {
position: absolute;
top: 2px;
left: 2px;
width: 16px;
height: 16px;
background: #fff;
border-radius: 50%;
transition: left .2s ease;
box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}
.ssl-switch.on .ssl-switch-slider { left: 18px; }

/* ===== 服务器管理：SSL / 网络信息卡片 ===== */
.ssl-net-card {
display: flex;
flex-direction: column;
gap: 10px;
padding: 14px 16px;
background: #fafbfc;
border: 1px solid var(--border-color, #e8e8e8);
border-radius: 8px;
}
.ssl-net-row {
display: flex;
align-items: center;
gap: 12px;
}
.ssl-net-label {
font-size: 13px;
color: var(--text-muted, #999);
min-width: 70px;
}
.ssl-net-value {
font-size: 15px;
font-weight: 600;
color: var(--text-color);
font-family: "Menlo","Consolas",monospace;
}
.btn-danger:disabled, .btn-danger.disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
/* 危险操作：红色描边（非实心），降低视觉压迫，避免误点 */
.btn-danger-outline { background: #fff; color: var(--danger-color); border: 1px solid var(--danger-color); box-shadow: none; }
.btn-danger-outline:hover:not(:disabled) { background: rgba(255,91,91,0.08); transform: translateY(-1px); }
.btn-danger-outline:disabled, .btn-danger-outline.disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
/* 次操作：中性描边按钮（编辑/盘点等） */
.btn-outline { background: #fff; color: var(--text-color); border: 1px solid var(--border-color); box-shadow: none; }
.btn-outline:hover:not(:disabled) { border-color: var(--primary-color); color: var(--primary-color); background: var(--primary-lightest); transform: translateY(-1px); }
.btn-outline:disabled, .btn-outline.disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

 .btn-default {
 background: #fff;
 color: var(--text-color);
 border: 1px solid var(--border-color);
 }
 .btn-default:hover { border-color: var(--primary-color); color: var(--primary-color); background: var(--primary-lightest); }
 .btn-block { width: 100%; }
 .btn-sm { padding: 6px 14px; font-size: 13px; border-radius: 8px; }

 .btn-group { display: flex; gap: 10px; margin-top: 20px; }

 /* ========== Forms ========== */
 .form-group {
 margin-bottom: 20px;
 }

 .form-group label {
 display: block;
 margin-bottom: 8px;
 color: var(--text-secondary);
 font-size: 15px;
 }

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 15px;
  transition: all 0.3s ease;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(24, 144, 255, 0.15), 0 4px 12px rgba(24, 144, 255, 0.1);
  transform: translateY(-1px);
}

 .form-group textarea {
 min-height: 100px;
 resize: vertical;
 }

 .form-row {
 display: flex;
 gap: 20px;
 margin-bottom: 0;
 }

 .form-row .form-group {
 flex: 1;
 }

 /* ========== Image Upload ========== */
 .upload-section {
 margin-bottom: 20px;
 }

 .upload-label {
 display: block;
 margin-bottom: 8px;
 color: var(--text-secondary);
 font-size: 15px;
 font-weight: 500;
 }

 .upload-area {
 border: 2px dashed var(--border-color);
 border-radius: 8px;
 padding: 16px;
 min-height: 100px;
 cursor: pointer;
 transition: border-color 0.3s, background 0.3s;
 }

 .upload-area:hover {
 border-color: var(--primary-color);
 background: rgba(24, 144, 255, 0.03);
 }

 .upload-placeholder {
 display: flex;
 flex-direction: column;
 align-items: center;
 justify-content: center;
 gap: 8px;
 color: var(--text-muted);
 font-size: 13px;
 min-height: 80px;
 }

 .upload-preview-list {
 display: flex;
 flex-wrap: wrap;
 gap: 10px;
 }

 .upload-preview-item {
 position: relative;
 width: 80px;
 height: 80px;
 border-radius: 6px;
 overflow: hidden;
 border: 1px solid var(--border-color);
 }

 .upload-preview-item img {
 width: 100%;
 height: 100%;
 object-fit: cover;
 }

 .upload-remove-btn {
 position: absolute;
 top: 2px;
 right: 2px;
 width: 20px;
 height: 20px;
 border-radius: 50%;
 background: rgba(0, 0, 0, 0.6);
 color: #fff;
 border: none;
 font-size: 15px;
 line-height: 1;
 cursor: pointer;
 display: flex;
 align-items: center;
 justify-content: center;
 padding: 0;
 }

 .upload-remove-btn:hover {
 background: var(--danger-color);
 }

 .upload-add-more {
 width: 80px;
 height: 80px;
 border: 2px dashed var(--border-color);
 border-radius: 6px;
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 28px;
 color: var(--text-muted);
 cursor: pointer;
 transition: border-color 0.3s, color 0.3s;
 }

 .upload-add-more:hover {
 border-color: var(--primary-color);
 color: var(--primary-color);
 }

 /* ========== Autocomplete Dropdown ========== */
 .autocomplete-dropdown {
 position: absolute;
 top: 100%;
 left: 0;
 right: 0;
 max-height: 200px;
 overflow-y: auto;
 background: #fff;
 border: 1px solid var(--border-color);
 border-radius: 0 0 6px 6px;
 box-shadow: 0 4px 12px rgba(0,0,0,0.1);
 z-index: 1000;
 list-style: none;
 padding: 4px 0;
 margin: 0;
 }
 .autocomplete-dropdown li {
 padding: 8px 14px;
 cursor: pointer;
 font-size: 15px;
 color: var(--text-color);
 }
 .autocomplete-dropdown li:hover {
 background: var(--primary-color);
 color: #fff;
 }

 /* ========== Image Gallery (Detail) ========== */
 .image-gallery {
 display: flex;
 flex-wrap: wrap;
 gap: 12px;
 }

 .image-gallery-item {
 width: 150px;
 height: 150px;
 border-radius: 8px;
 overflow: hidden;
 border: 1px solid var(--border-color);
 cursor: pointer;
 transition: transform 0.2s, box-shadow 0.2s;
 }

 .image-gallery-item:hover {
 transform: scale(1.05);
 box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
 }

 .image-gallery-item img {
 width: 100%;
 height: 100%;
 object-fit: cover;
 }

 /* ===== 图片完整加载后再淡入显示（避免从上到下渐显） ===== */
 img.fade-load {
 opacity: 0;
 background: #f2f3f5;
 transition: opacity .3s ease;
 }
 img.fade-load.loaded {
 opacity: 1;
 }
 /* 灯箱大图：加载完成前显示浅色占位 + 居中 loading 动效 */
 .modal-overlay img.fade-load {
 background: #eef1f5;
 }

 /* ========== Search Bar ========== */
 .search-bar {
   display: flex;
   gap: 10px;
   margin-bottom: 16px;
   flex-wrap: wrap;
   align-items: center;
 }

 .search-bar .form-group {
   margin-bottom: 0;
   display: flex;
   align-items: center;
   gap: 6px;
   flex: 0 0 auto;
 }

 .search-bar .form-group label {
   font-size: 12px;
   color: var(--text-muted);
   white-space: nowrap;
   margin: 0;
 }

 .search-bar input[type="text"],
 .search-bar input[type="search"],
 .search-bar select {
   height: 36px !important;
   padding: 0 10px !important;
   border: 1px solid var(--border-color) !important;
   border-radius: 4px !important;
   font-size: 13px !important;
   background: #fff;
   box-sizing: border-box;
   min-width: auto;
   max-width: none;
   outline: none;
 }

 /* ===== 工具条：美化搜索框（图标 + 圆角 + 聚焦高亮） ===== */
 .search-input-wrap {
   position: relative;
   display: inline-flex;
   align-items: center;
 }
 .search-input-wrap .mi-search {
   position: absolute;
   left: 10px;
   width: 14px; height: 14px;
   background: var(--text-muted);
   -webkit-mask-position: center; mask-position: center;
   -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
   -webkit-mask-size: contain; mask-size: contain;
   pointer-events: none;
   z-index: 1;
 }
 .search-input-wrap input {
   height: 36px;
   width: 260px;
   padding: 0 32px 0 32px;
   border: 1px solid var(--border-color);
   border-radius: 18px;
   font-size: 13px;
   background: #fff;
   color: var(--text-color);
   transition: all 0.2s ease;
   box-shadow: 0 1px 2px rgba(16,24,40,0.04);
   box-sizing: border-box;
   outline: none;
 }
 .search-input-wrap input::placeholder { color: #a0a6b5; }
 .search-input-wrap input:hover { border-color: #c5cad6; }
 .search-input-wrap input:focus {
   border-color: var(--primary-color) !important;
   box-shadow: 0 0 0 3px rgba(22,119,255,0.12), 0 1px 2px rgba(16,24,40,0.04);
 }
 .search-input-wrap .search-clear {
   position: absolute;
   right: 6px;
   width: 20px; height: 20px;
   border: none; background: transparent;
   border-radius: 50%;
   cursor: pointer;
   display: inline-flex; align-items: center; justify-content: center;
   color: var(--text-muted);
   font-size: 14px;
   padding: 0;
   z-index: 1;
 }
 .search-input-wrap .search-clear:hover { background: rgba(15,23,42,0.06); color: var(--text-color); }

 /* ===== 工具条：内联下拉（无 label，与搜索框/按钮同高 36px） ===== */
 .quick-select {
   height: 36px;
   padding: 0 28px 0 12px;
   border: 1px solid var(--border-color);
   border-radius: 18px;
   font-size: 13px;
   background: #fff url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='%238b90a3'><path d='M6 8.5L1.5 4h9z'/></svg>") no-repeat right 10px center;
   background-size: 10px 10px;
   color: var(--text-color);
   cursor: pointer;
   min-width: 120px;
   appearance: none;
   -webkit-appearance: none;
   -moz-appearance: none;
   transition: all 0.2s ease;
   box-shadow: 0 1px 2px rgba(16,24,40,0.04);
   box-sizing: border-box;
   outline: none;
 }
 .quick-select:hover { border-color: #c5cad6; }
 .quick-select:focus {
   border-color: var(--primary-color) !important;
   box-shadow: 0 0 0 3px rgba(22,119,255,0.12), 0 1px 2px rgba(16,24,40,0.04);
 }

 .search-bar input[type="text"]:focus,
 .search-bar input[type="search"]:focus,
 .search-bar select:focus {
   border-color: var(--primary-color) !important;
   box-shadow: 0 0 0 2px rgba(22, 119, 255, 0.12);
 }

 .search-bar .btn {
   align-self: center;
   height: 36px;
   padding: 0 14px;
   font-size: 13px;
   display: inline-flex;
   align-items: center;
   justify-content: center;
 }

 .search-bar .btn-sm {
   padding: 0 12px;
 }


 /* ========== Pagination ========== */
 .pagination {
 display: flex;
 justify-content: center;
 align-items: center;
 gap: 8px;
 margin-top: 20px;
 }

 .pagination .btn {
 padding: 8px 12px;
 font-size: 13px;
 }

 .pagination .btn.active {
 background: var(--primary-color);
 color: #fff;
 border-color: var(--primary-color);
 }

 .pagination .page-info {
 padding: 0 12px;
 font-size: 13px;
 color: var(--text-secondary);
 }

 /* ========== Modal ========== */
 .modal-overlay {
 position: fixed;
 top: 0;
 left: 0;
 right: 0;
 bottom: 0;
 background: rgba(0, 0, 0, 0.5);
 display: flex;
 align-items: center;
 justify-content: center;
 z-index: 1000;
 /* 提升为合成层，避免遮罩渲染卡顿 */
 will-change: opacity;
 transform: translateZ(0);
 -webkit-transform: translateZ(0);
 }
 /* 灯箱：图片加载完成前的 loading 指示 */
 .lb-loading {
 display: flex;
 flex-direction: column;
 align-items: center;
 gap: 14px;
 color: #fff;
 font-size: 14px;
 letter-spacing: 1px;
 }
 .lb-loading .spinner {
 width: 40px;
 height: 40px;
 border: 4px solid rgba(255, 255, 255, 0.25);
 border-top-color: #fff;
 border-radius: 50%;
 animation: lb-spin 0.8s linear infinite;
 }
 @keyframes lb-spin {
 to { transform: rotate(360deg); }
 }

.modal {
background: var(--card-bg);
border-radius: 8px;
width: 100%;
max-width: 900px;
max-height: 95vh;
overflow-y: auto;
scrollbar-width: none;
-ms-overflow-style: none;
/* 弹窗用 GPU 层渲染，配合轻微缩放淡入动画减少卡顿 */
will-change: transform, opacity;
transform: translateZ(0) scale(1);
-webkit-transform: translateZ(0) scale(1);
animation: modal-in 0.18s ease-out;
}
.modal::-webkit-scrollbar { display: none; }
@keyframes modal-in {
  from { opacity: 0.85; transform: translateZ(0) scale(0.97); }
  to { opacity: 1; transform: translateZ(0) scale(1); }
}

 .modal-header {
 padding: 16px 24px;
 border-bottom: 1px solid var(--border-color);
 display: flex;
 align-items: center;
 justify-content: space-between;
 }

 .modal-title {
 font-size: 16px;
 font-weight: 500;
 }

 .modal-close {
 font-size: 24px;
 cursor: pointer;
 color: var(--text-secondary);
 line-height: 1;
 background: none;
 border: none;
 }

 .modal-close:hover { color: var(--text-color); }

 .modal-body {
 padding: 24px;
 }

 .modal-footer {
padding: 16px 24px;
border-top: 1px solid var(--border-color);
display: flex;
justify-content: flex-end;
gap: 10px;
}

/* 扫码出入库 */
.scan-bar {
display: flex;
align-items: center;
gap: 8px;
margin: 10px 0 4px;
padding: 8px 10px;
background: #f6f8fb;
border: 1px dashed var(--primary-color, #2b6cb0);
border-radius: 10px;
}
.scan-bar .mi { font-size: 18px; color: var(--primary-color, #2b6cb0); }
.scan-bar input {
flex: 1;
height: 40px;
padding: 8px 12px;
border: 1px solid var(--border-color, #e2e8f0);
border-radius: 8px;
font-size: 14px;
outline: none;
}
.scan-bar input:focus { border-color: var(--primary-color, #2b6cb0); }
.scan-bar .scan-msg { font-size: 13px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scan-bar .scan-msg.ok { color: #2f9e44; }
.scan-bar .scan-msg.err { color: #e03131; }
.scan-batch { margin: 4px 0 8px; }
.scan-batch summary { cursor: pointer; font-size: 13px; color: var(--primary-color, #2b6cb0); user-select: none; }
.scan-batch textarea { width: 100%; margin: 6px 0; padding: 8px; border: 1px solid var(--border-color, #e2e8f0); border-radius: 6px; font-size: 13px; resize: vertical; box-sizing: border-box; }

/* 出库商品搜索框 */
.out-search { position: relative; margin: 8px 0; }
.out-search input { width: 100%; height: 40px; padding: 8px 12px; border: 1px solid var(--border-color, #e2e8f0); border-radius: 8px; font-size: 14px; outline: none; }
.out-search input:focus { border-color: var(--primary-color, #2b6cb0); }
.search-dropdown { position: absolute; z-index: 50; top: 42px; left: 0; right: 0; background: #fff; border: 1px solid var(--border-color, #e2e8f0); border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.12); max-height: 260px; overflow-y: auto; list-style: none; margin: 0; padding: 4px; }
.search-dropdown li { padding: 8px 10px; border-radius: 6px; cursor: pointer; display: flex; align-items: center; gap: 8px; font-size: 14px; }
.search-dropdown li:hover { background: #f1f5fb; }
.search-dropdown .sd-name { font-weight: 600; }
.search-dropdown .sd-model { color: #555; font-size: 12px; }
.search-dropdown .sd-no { color: var(--primary-color, #2b6cb0); font-size: 12px; margin-left: auto; }

/* 顶部全局快捷出入库条 */
.quick-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; background: linear-gradient(90deg, var(--primary-lightest, #eef5ff), var(--bg-color, #f6fbff)); border: 1px solid var(--primary-lighter, rgba(64,158,255,0.18)); border-radius: 12px; margin-bottom: 16px; position: relative; box-shadow: 0 2px 6px rgba(15,23,42,0.04); }
.quick-bar .qb-icon { font-size: 20px; color: var(--primary-color); }
.quick-bar input { flex: 1; min-width: 180px; height: 40px; padding: 8px 12px; border: 1px solid var(--border-color, #e2e8f0); border-radius: 8px; font-size: 14px; outline: none; transition: border-color .18s, box-shadow .18s; background: var(--bg-color, #fff); }
.quick-bar input::placeholder { font-size: 12.5px; color: var(--text-muted); opacity: .8; }
.quick-bar input:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 14%, transparent); }
.quick-bar .qb-msg { font-size: 13px; max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.quick-bar .qb-msg.ok { color: var(--success-color); }
.quick-bar .qb-msg.err { color: var(--danger-color); }
.quick-bar > .btn { flex-shrink: 0; }

/* 全部商品按钮激活态：在总览模式下高亮 */
.btn-overview-active {
  background: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
  color: #fff !important;
  font-weight: 600 !important;
}
.btn-overview-active:disabled,
.btn-overview-active[disabled] {
  background: var(--bg-color, #f5f7fb) !important;
  border-color: var(--border-color, #e7ebf2) !important;
  color: var(--text-muted, #8b90a3) !important;
  cursor: not-allowed !important;
}

/* 扫码输入/消息：移出 .quick-bar 后的独立样式（合并到树头部使用） */
.qb-scan {
  height: 36px;
  padding: 4px 10px;
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: 6px;
  font-size: 13px;
  outline: none;
  transition: border-color .18s, box-shadow .18s;
  background: var(--bg-color, #fff);
}
.qb-scan::placeholder { font-size: 12px; color: var(--text-muted); opacity: .8; }
.qb-scan:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 14%, transparent); }
.qb-scan.active { border-color: var(--primary-color); background: color-mix(in srgb, var(--primary-color) 5%, var(--bg-color, #fff)); }
/* 顶部工具条按钮与 qb-scan 同高 36px */
.quick-bar .btn-sm { height: 36px; padding: 0 14px; box-sizing: border-box; display: inline-flex; align-items: center; }

/* 出库单列表工具条：所有控件统一 36px 高 */
.dm-toolbar .form-group input { height: 36px; padding: 0 12px; }
.dm-toolbar .form-group label { margin-bottom: 4px; }
.dm-toolbar .btn { height: 36px; padding: 0 16px; box-sizing: border-box; display: inline-flex; align-items: center; }

.qb-msg { font-size: 13px; max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qb-msg.ok { color: var(--success-color); }
.qb-msg.err { color: var(--danger-color); }

/* 备件仓库顶部 tabs（分段式控件） */
.erp-tabs { display: flex; align-items: stretch; gap: 4px; padding: 4px; background: var(--bg-color, #f1f5f9); border: 1px solid var(--border-color); border-radius: 10px; box-shadow: inset 0 1px 2px rgba(15,23,42,0.04); margin-bottom: 12px; flex-wrap: wrap; }
.erp-tabs > .btn { flex: 1; min-width: 0; border-radius: 8px; transition: transform .18s, box-shadow .18s, background-color .18s, color .18s; }
.erp-tabs > .btn.btn-primary { box-shadow: 0 2px 8px rgba(15,23,42,0.10), 0 0 0 1px color-mix(in srgb, var(--primary-color) 22%, transparent); }
.qb-panel { flex-basis: 100%; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 8px; border-top: 1px dashed var(--border-color, #e2e8f0); margin-top: 4px; }
.qb-prod { display: flex; flex-direction: column; }
.qb-prod .qb-name { font-weight: 600; font-size: 14px; }
.qb-prod .qb-no { font-size: 12px; color: var(--primary-color, #2b6cb0); }
.qb-fields { display: flex; align-items: center; gap: 12px; }
.qb-fields label { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-muted); }

/* 二维码打印标签 */
.qr-sheet { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.qr-label { border: 1px solid #ddd; border-radius: 6px; padding: 8px; background: #fff; display: flex; flex-direction: column; align-items: center; box-sizing: border-box; }
.qr-label-head { font-size: 12px; font-weight: 600; text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qr-label-code { margin: 6px 0; min-height: 64px; display: flex; align-items: center; justify-content: center; }
.qr-label-code canvas, .qr-label-code svg { display: block; max-width: 100%; }
.qr-label-foot { font-size: 12px; color: #333; text-align: center; }

/* ========== Drawer / 侧边栏弹窗 ========== */
.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  background: rgba(0,0,0,0.35);
  display: flex;
  animation: drawer-fade-in 0.2s ease;
}
.drawer-panel {
  background: #f4f6fa;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  box-shadow: -4px 0 24px rgba(0,0,0,0.18);
  animation: drawer-slide-in 0.25s ease;
}
.drawer-panel-right {
  margin-left: auto;
  width: 92vw;
  max-width: 1280px;
  min-width: 360px;
  border-radius: 12px 0 0 12px;
}
.drawer-header {
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: #fff;
  border-radius: 12px 0 0 0;
}
.drawer-body {
  flex: 1;
  overflow-y: auto;
  min-height: 0;
}
.drawer-footer {
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #fff;
  border-top: 1px solid var(--border-color);
}
@keyframes drawer-fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes drawer-slide-in { from { transform: translateX(100%); } to { transform: translateX(0); } }
@media (max-width: 640px) {
  .drawer-panel-right { width: 100vw; max-width: 100vw; border-radius: 0; }
  .drawer-header { border-radius: 0; }
}

/* 打印样式：仅打印二维码标签 */
@media print {
  body * { visibility: hidden !important; }
  .modal-overlay, .modal-overlay * { visibility: visible !important; }
  .modal-overlay { position: absolute; top: 0; left: 0; background: #fff; }
  .modal { box-shadow: none !important; max-width: 100% !important; width: 100%; }
  .modal-header, .modal-footer { display: none !important; }
  .qr-sheet { gap: 4px; }
  .qr-label { border: 1px dashed #999; page-break-inside: avoid; }
}


/* Detail grid labels */
/* 所有 .dg 统一限制宽度并居中，保证所有卡片视觉对齐 */
.card-body > .dg:not(.full),
.card-body > .dg.sparse,
.card-body > .dg.aligned {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 760px;
    margin: 0 auto;
}
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 12px;
    align-items: end;
}
.form-field label {
    display: block;
    font-size: 12px;
    color: var(--text-muted, #999);
    margin-bottom: 6px;
}
.form-field input,
.form-field select {
    width: 100%;
    height: 36px;
    padding: 6px 12px;
    border: 1px solid var(--border-color, #e8e8e8);
    border-radius: 6px;
    font-size: 14px;
    background: var(--card-bg, #fff);
    color: var(--text-color, #333);
    box-sizing: border-box;
    transition: border-color .15s, box-shadow .15s;
}
.form-field input:focus,
.form-field select:focus {
    outline: none;
    border-color: var(--primary-color, #1890ff);
    box-shadow: 0 0 0 3px var(--primary-bg-color, rgba(24,144,255,.12));
}
.form-actions {
    display: flex;
    align-items: end;
}
.form-actions .btn {
    height: 36px;
    padding: 0 18px;
    border-radius: 6px;
    font-size: 14px;
}
@media (max-width: 640px) {
    .form-grid { grid-template-columns: 1fr; }
    .form-actions { justify-content: flex-end; }
}
.dg {
 display: grid;
 grid-template-columns: repeat(2, 1fr);
 gap: 12px;
 }
 .dg.full { grid-template-columns: 1fr; }
 .di {
 display: flex;
 flex-direction: column;
 gap: 6px;
 padding: 12px 14px;
 background: var(--card-bg, #fff);
 border: 1px solid var(--border-color, #e8e8e8);
 border-left: 4px solid var(--primary-color, #1890ff);
 border-radius: 8px;
 }
 .dl {
 font-size: 12px;
 font-weight: 600;
 color: var(--primary-color, #1890ff);
 text-transform: uppercase;
 letter-spacing: 0.5px;
 }
 .dv {
 font-size: 15px;
 color: var(--text-color, #333);
 font-weight: 500;
 line-height: 1.5;
 word-break: break-all;
 }
 .di .dv:empty::before {
 content: '-';
 color: #bbb;
 }
 .card-body .desc {
 margin-top: 4px;
 padding: 12px 14px;
 background: #f8f9fa;
 border: 1px solid var(--border-color, #e8e8e8);
 border-radius: 8px;
 font-size: 15px;
 line-height: 1.6;
 color: var(--text-color, #333);
 }

 /* ========== Detail Page ========== */
 .detail-header-bar {
 display: flex;
 justify-content: space-between;
 align-items: center;
 padding-bottom: 16px;
 margin-bottom: 20px;
 border-bottom: 2px solid var(--primary-color);
 }

 .detail-title-section {
 display: flex;
 align-items: center;
 gap: 16px;
 }

 .detail-no {
 font-size: 22px;
 font-weight: bold;
 color: var(--primary-color);
 }

 .detail-section {
 margin-bottom: 20px;
 background: #fafafa;
 border-radius: 8px;
 overflow: hidden;
 }

 .detail-section-title {
 display: flex;
 align-items: center;
 gap: 8px;
 padding: 12px 16px;
 background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
 color: white;
 font-weight: 500;
 font-size: 15px;
 }

 .section-icon { font-size: 18px; }

 .detail-section-content {
 padding: 16px;
 }

 .detail-row {
 display: grid;
 grid-template-columns: repeat(2, 1fr);
 gap: 16px;
 margin-bottom: 12px;
 }

 .detail-row:last-child { margin-bottom: 0; }

 .detail-item {
 display: flex;
 flex-direction: column;
 gap: 4px;
 }

 .detail-item.full { grid-column: span 2; }

 .detail-label {
 font-size: 12px;
 color: #999;
 }

 .detail-value {
 font-size: 15px;
 color: #333;
 }

 .sn-value {
 font-family: 'Consolas', monospace;
 background: var(--primary-bg-color);
 padding: 4px 8px;
 border-radius: 4px;
 display: inline-block;
 }

 .error-code { color: #ff4d4f; font-weight: 500; }

 .solution-box {
 background: white;
 padding: 12px;
 border-radius: 6px;
 border-left: 3px solid var(--primary-color);
 line-height: 1.6;
 min-height: 60px;
 }

 /* Fee section */
 .fee-section {
 background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
 }

 .fee-section .detail-section-title {
 background: rgba(255, 255, 255, 0.1);
 }

 .fee-section .detail-section-content {
 background: white;
 margin: 8px;
 border-radius: 6px;
 padding: 12px;
 }

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

 .fee-item {
 text-align: center;
 padding: 9px 8px;
 background: #fafafa;
 border-radius: 6px;
 transition: background .15s;
 }
 .fee-item:hover {
 background: #f5f7fa;
 }
 .fee-item .fee-label {
 font-size: 12px;
 }
 .fee-item .fee-value {
 font-size: 15px;
 font-weight: 600;
 margin-top: 2px;
 }

 /* ===== 发票上传行（费用明细内，费用总计与流水/凭证之间） ===== */
 .inv-upload-row {
 display: flex;
 align-items: center;
 flex-wrap: wrap;
 gap: 6px 12px;
 margin-top: 8px;
 padding: 7px 12px;
 background: #f8faff;
 border: 1px dashed var(--border-color, #d9e2f0);
 border-radius: 6px;
 }
 .inv-upload-label {
 font-size: 12px;
 color: var(--text-muted, #999);
 font-weight: 600;
 white-space: nowrap;
 flex-shrink: 0;
 }
 .inv-upload-controls {
 display: flex;
 align-items: center;
 gap: 8px;
 }
 .inv-upload-msg {
 font-size: 12px;
 flex-basis: 100%;
 }

 /* ===== 费用总计（简约块状，淡灰底 + 左侧蓝色强调条） ===== */
 .fee-total-block {
 display: flex;
 align-items: center;
 justify-content: space-between;
 padding: 9px 14px;
 margin-top: 8px;
 background: #fafbfc;
 border: 1px solid var(--border-color, #e8e8e8);
 border-left: 4px solid var(--primary-color, #1890ff);
 border-radius: 6px;
 }
 .fee-total-block .ftb-label {
 font-size: 12px;
 color: var(--text-muted, #999);
 font-weight: 500;
 letter-spacing: .5px;
 }
 .fee-total-block .ftb-value {
 font-size: 17px;
 font-weight: 700;
 color: var(--primary-color, #1890ff);
 font-family: "Menlo","Consolas",monospace;
 }

 /* ===== 费用明细底部元信息（发票号/回款/流水号/凭证）紧凑行内布局 ===== */
 .fee-meta {
 display: flex;
 flex-wrap: wrap;
 align-items: stretch;
 gap: 6px;
 margin-top: 8px;
 padding: 8px 12px;
 background: #fafbfc;
 border: 1px solid var(--border-color, #e8e8e8);
 border-radius: 6px;
 }
 .fm-row {
 display: flex;
 align-items: center;
 gap: 6px;
 flex: 1 1 auto;
 min-width: 0;
 padding: 0 6px;
 min-height: 26px;
 border-right: 1px solid #ececec;
 }
 .fm-row:last-child { border-right: none; }
 .fm-label {
 font-size: 12px;
 color: var(--text-muted, #999);
 white-space: nowrap;
 flex-shrink: 0;
 }
 .fm-value {
 font-size: 13px;
 font-weight: 500;
 color: var(--text-color, #333);
 overflow: hidden;
 text-overflow: ellipsis;
 white-space: nowrap;
 }
 .fm-voucher {
 flex: 0 0 auto;
 }
 .fm-thumb {
 width: 60px;
 height: 60px;
 object-fit: cover;
 border-radius: 4px;
 cursor: pointer;
 background: #f5f6fa;
 border: 1px solid #e8e8e8;
 transition: transform .15s, box-shadow .15s;
 flex-shrink: 0;
 }
 .fm-thumb:hover {
 transform: scale(1.06);
 box-shadow: 0 2px 8px rgba(0,0,0,0.15);
 }

 .fee-label {
 display: block;
 font-size: 12px;
 color: #999;
 margin-bottom: 4px;
 }

 .fee-value {
 display: block;
 font-size: 16px;
 font-weight: 500;
 color: #333;
 }

 .fee-total-row {
 display: flex;
 justify-content: space-between;
 align-items: center;
 padding: 12px 16px;
 background: linear-gradient(135deg, #ff6b6b 0%, #ff8e53 100%);
 border-radius: 6px;
 }

 .fee-total-label {
 font-size: 15px;
 font-weight: 500;
 color: white;
 }

 .fee-total-value {
 font-size: 24px;
 font-weight: bold;
 color: white;
 }

 /* ========== 新工单弹窗 ========== */
.order-popup { position:fixed; bottom:80px; right:20px; width:340px; max-width:90vw; background:linear-gradient(135deg,#1a3c6e,#2c5282); color:#fff; border-radius:12px; box-shadow:0 8px 40px rgba(0,0,0,.3); cursor:pointer; z-index:4000; animation:slideIn .4s ease; display:flex; gap:12px; padding:16px; }
.order-popup.hide { animation:slideOut .4s ease forwards; }
.popup-close { position:absolute; top:6px; right:10px; font-size:20px; line-height:1; opacity:.6; cursor:pointer; }
.popup-close:hover { opacity:1; }
.popup-icon { font-size:32px; flex-shrink:0; }
.popup-title { font-size:13px; opacity:.8; }
.popup-wo { font-size:17px; font-weight:700; margin:4px 0; letter-spacing:1px; }
.popup-customer { font-size:13px; opacity:.85; }
.popup-hint { font-size:11px; opacity:.6; margin-top:6px; }
@keyframes slideIn { from { transform:translateX(120%); opacity:0; } to { transform:translateX(0); opacity:1; } }
@keyframes slideOut { from { transform:translateX(0); opacity:1; } to { transform:translateX(120%); opacity:0; } }

/* ========== Toast ========== */
 .toast {
 position: fixed;
 top: 20px;
 left: 50%;
 transform: translateX(-50%);
 padding: 12px 24px;
 border-radius: 6px;
 color: #fff;
 font-size: 15px;
 z-index: 2000;
 animation: toastFadeIn 0.3s;
 white-space: nowrap;
 }

 .toast-success { background: var(--success-color); }
 .toast-error { background: var(--danger-color); }
 .toast-warning { background: var(--warning-color); }

 @keyframes toastFadeIn {
 from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
 to { opacity: 1; transform: translateX(-50%) translateY(0); }
 }

 /* ========== Settings ========== */
 .theme-selector {
 display: flex;
 gap: 12px;
 margin-top: 12px;
 }

 .theme-option {
 width: 36px;
 height: 36px;
 border-radius: 50%;
 cursor: pointer;
 border: 3px solid transparent;
 transition: all 0.3s;
 }

 .theme-option:hover { transform: scale(1.15); }
 .theme-option.active { border-color: var(--text-color); box-shadow: 0 0 0 3px var(--primary-color); }

 .theme-dot-blue { background: #1890ff; }
 .theme-dot-light { background: #f0f2f5; border: 1px solid #ccc; }
 .theme-dot-dark { background: #0d1117; border: 1px solid #30363d; }
 .theme-dot-green { background: #52c41a; }
 .theme-dot-purple { background: #722ed1; }
 .theme-dot-orange { background: #fa8c16; }


 .settings-section {
 margin-bottom: 24px;
 }

 .settings-section h3 {
 font-size: 15px;
 color: var(--text-secondary);
 margin-bottom: 12px;
 padding-bottom: 8px;
 border-bottom: 1px solid var(--border-color);
 }

 .action-btns {
 display: flex;
 gap: 8px;
 }

 .action-btns .btn {
 padding: 6px 12px;
 font-size: 12px;
 }

 /* ========== Loading ========== */
 .loading {
 text-align: center;
 padding: 40px;
 color: var(--text-muted);
 }

 .loading-spinner {
 display: inline-block;
 width: 32px;
 height: 32px;
 border: 3px solid var(--border-color);
 border-top-color: var(--primary-color);
 border-radius: 50%;
 animation: spin 0.8s linear infinite;
 margin-bottom: 8px;
 }

 @keyframes spin {
 to { transform: rotate(360deg); }
 }

 /* ========== Tech Docs ========== */
 .tech-nav-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
 .tech-card { background: var(--card-bg); border-radius: 12px; padding: 28px; cursor: pointer; transition: all 0.3s; border: 2px solid var(--border-color); text-align: center; }
 .tech-card:hover { border-color: var(--primary-color); transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
 .tech-icon { font-size: 48px; margin-bottom: 12px; }
 .tech-card h3 { font-size: 18px; margin-bottom: 8px; }
 .tech-card p { color: var(--text-secondary); font-size: 13px; margin-bottom: 12px; }
 .tech-count { color: var(--primary-color); font-size: 13px; }
 .tab-nav { display: flex; gap: 4px; }
 .tab-nav button { padding: 10px 20px; border: 1px solid var(--border-color); background: var(--card-bg); cursor: pointer; border-radius: 6px 6px 0 0; font-size: 15px; }
 .tab-nav button.active { background: var(--primary-color); color: #fff; border-color: var(--primary-color); }
 .stats-bar { padding: 10px 16px; background: var(--primary-bg-color); border-radius: 8px; margin-bottom: 16px; font-size: 15px; }
.editor-container { background: var(--card-bg); border-radius: 8px; padding: 24px; }
.editor-container .form-input, .editor-container .form-textarea { width: 100%; padding: 10px 14px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 15px; }
.editor-container .form-textarea { resize: vertical; font-family: inherit; }
.editor-container .form-row { display: flex; gap: 16px; }
.editor-container .form-row .form-group { flex: 1; }
.editor-container .form-group { margin-bottom: 16px; }
.editor-container label { display: block; margin-bottom: 6px; font-weight: 500; color: var(--text-secondary); font-size: 13px; }
.editor-toolbar { display: flex; gap: 8px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--border-color); margin-bottom: 16px; }

/* ========== 统一富文本编辑器主题 ========== */
.unified-editor { background: var(--card-bg); border-radius: 12px; box-shadow: 0 4px 20px rgba(0,0,0,0.08); border: 1px solid var(--border-color); overflow: hidden; display: flex; flex-direction: column; }
.unified-editor-toolbar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; background: linear-gradient(180deg, #fafbfc 0%, #f0f3f7 100%); border-bottom: 1px solid var(--border-color); flex-wrap: wrap; }
.unified-editor-toolbar .tool-group { display: flex; gap: 4px; padding: 0 8px; border-right: 1px solid var(--border-color); }
.unified-editor-toolbar .tool-group:last-child { border-right: none; padding-right: 0; }
.unified-editor-toolbar .tool-group:first-child { padding-left: 0; }
.unified-editor-toolbar .tool-btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 8px 14px; border: 1px solid var(--border-color); background: #fff; border-radius: 6px; cursor: pointer; font-size: 13px; color: var(--text-secondary); transition: all 0.2s; }
.unified-editor-toolbar .tool-btn:hover { background: var(--primary-bg-color); border-color: var(--primary-color); color: var(--primary-color); transform: translateY(-1px); }
.unified-editor-toolbar .tool-btn.primary { background: var(--primary-color); color: #fff; border-color: var(--primary-color); }
.unified-editor-toolbar .tool-btn.primary:hover { background: var(--primary-light); }
.unified-editor-toolbar .tool-btn svg { width: 16px; height: 16px; }
.unified-editor-content { flex: 1; padding: 24px; background: var(--card-bg); min-height: 400px; }

/* 块编辑器统一风格 */
.rich-block { background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 10px; margin-bottom: 14px; box-shadow: 0 2px 8px rgba(0,0,0,0.04); transition: all 0.2s ease; position: relative; }
.rich-block:hover { border-color: var(--primary-color); box-shadow: 0 4px 16px color-mix(in srgb, var(--primary-color) 10%, transparent); }
.rich-block.focused { border-color: var(--primary-color); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 10%, transparent), 0 4px 16px color-mix(in srgb, var(--primary-color) 10%, transparent); }
.rich-block-header { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: linear-gradient(180deg, #fafbfc 0%, #f4f6f9 100%); border-bottom: 1px solid var(--border-color); border-radius: 10px 10px 0 0; }
.rich-block-body { padding: 12px 16px; }
.rich-block-actions { display: flex; gap: 4px; margin-left: auto; }
.rich-block-btn { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; padding: 0; border: 1px solid var(--border-color); background: #fff; border-radius: 6px; cursor: pointer; font-size: 15px; color: var(--text-secondary); transition: all 0.2s; }
.rich-block-btn:hover { background: var(--primary-bg-color); color: var(--primary-color); border-color: var(--primary-color); }
.rich-block-btn.danger:hover { background: #fff2f0; color: var(--danger-color); border-color: var(--danger-color); }
.rich-block-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* 文本块格式工具栏 */
.block-format-bar { display: flex; gap: 4px; padding: 0 12px 8px; border-bottom: 1px solid var(--border-color); margin-bottom: 8px; flex-wrap: wrap; }
.block-format-bar .format-btn { padding: 4px 10px; border: 1px solid transparent; background: transparent; border-radius: 4px; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--text-muted); transition: all 0.2s; }
.block-format-bar .format-btn:hover { background: var(--primary-bg-color); color: var(--primary-color); }
.block-format-bar .format-btn.active { background: var(--primary-color); color: #fff; }

/* 输入框样式 */
.rich-block input, .rich-block textarea { width: 100%; border: none; outline: none; background: transparent; font-family: inherit; color: var(--text-color); }
.rich-block textarea { resize: vertical; line-height: 1.8; }

/* 空块状态 */
.rich-empty { text-align: center; padding: 60px 20px; color: var(--text-muted); border: 2px dashed var(--border-color); border-radius: 12px; background: #fafbfc; }

/* Quill 编辑器统一覆盖 */
.ql-toolbar { background: linear-gradient(180deg, #fafbfc 0%, #f0f3f7 100%) !important; border-color: var(--border-color) !important; border-radius: 8px 8px 0 0 !important; padding: 10px 12px !important; }
.ql-container { border-color: var(--border-color) !important; border-radius: 0 0 8px 8px !important; background: var(--card-bg) !important; }
.ql-editor { min-height: 300px; font-size: 15px; line-height: 1.8; color: var(--text-color); }
.ql-editor p { margin-bottom: 8px; }
.ql-snow .ql-picker-label { color: var(--text-secondary); }
.ql-snow .ql-stroke { stroke: var(--text-secondary); }
.ql-snow .ql-fill { fill: var(--text-secondary); }
.ql-snow .ql-picker-options { background: var(--card-bg); border-color: var(--border-color); }
.ql-snow .ql-tooltip { background: var(--card-bg); border-color: var(--border-color); box-shadow: 0 4px 20px rgba(0,0,0,0.15); }

/* tech editor 尺寸 */
#tech-editor-wrapper { border-radius: 12px; overflow: hidden; border: 1px solid var(--border-color); box-shadow: 0 4px 20px rgba(0,0,0,0.08); }
#tech-editor-wrapper .ql-editor { min-height: 420px; }

/* repair editor 尺寸 */
#repair-editor-wrapper { border-radius: 12px; overflow: hidden; border: 1px solid var(--border-color); box-shadow: 0 4px 20px rgba(0,0,0,0.08); }
#repair-editor-wrapper .ql-editor { min-height: 300px; }



 /* 手机模型预览 */
 .phone-frame { position: relative; width: 375px; height: 760px; background: #1a1a1a; border-radius: 44px; padding: 12px; box-shadow: 0 25px 70px rgba(0,0,0,0.45); display: flex; flex-direction: column; overflow: hidden; }
 .phone-notch { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: 150px; height: 28px; background: #1a1a1a; border-radius: 0 0 18px 18px; z-index: 10; }
 .phone-statusbar { display: flex; justify-content: space-between; align-items: center; padding: 8px 22px 4px; color: #fff; font-size: 12px; font-weight: 600; background: #1a1a1a; z-index: 5; }
 .phone-navbar { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; background: #f5f5f5; border-bottom: 1px solid #e0e0e0; }
 .phone-navbtn { background: none; border: none; font-size: 16px; color: #333; cursor: pointer; padding: 4px 8px; }
 .phone-navtitle { font-size: 15px; color: #333; font-weight: 500; }
 .phone-screen { flex: 1; background: #fff; overflow-y: auto; border-radius: 0 0 32px 32px; }
 .phone-homebar { width: 120px; height: 5px; background: rgba(255,255,255,0.6); border-radius: 3px; margin: 8px auto 4px; }
 .phone-body { font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; padding-top: 12px; }
 .preview-cover img { width: calc(100% - 32px); margin: 0 16px 16px; border-radius: 6px; display: block; }
 .preview-title { font-size: 22px; font-weight: 700; line-height: 1.4; padding: 0 16px; margin: 0 0 8px 0; color: #222; }
 .preview-meta { padding: 0 16px; color: #999; font-size: 12px; margin-bottom: 16px; }
 .preview-content { padding: 0 16px 24px; font-size: 16px; line-height: 1.8; color: #333; word-break: break-word; }
 .preview-content h2,.preview-content h3 { font-size: 18px; }
 .preview-content img { max-width: 100%; height: auto; border-radius: 4px; }
 .preview-content p { margin: 8px 0; }
 .preview-content blockquote { border-left: 3px solid var(--primary-color); padding-left: 12px; color: #666; margin: 12px 0; }
 /* 统计卡片 */
 .stat-card { background: linear-gradient(135deg, var(--primary-bg-color,#e6f7ff), #fff); border-radius: 12px; padding: 24px 20px; text-align: center; border: 1px solid var(--border-color); }
 .stat-num { font-size: 32px; font-weight: 700; color: var(--primary-color); }
 .stat-label { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.btn-row { display: flex; gap: 10px; margin-top: 16px; }
/* 页面容器样式 - 留空用于未来扩展 */
.page-container { }
 .page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
 .page-header h2 { font-size: 22px; }
 .header-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
 .search-input { padding: 8px 14px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 13px; min-width: 200px; }
 .filter-select { padding: 8px 14px; border: 1px solid var(--border-color); border-radius: 6px; font-size: 13px; }
 .btn-back { padding: 8px 16px; border: 1px solid var(--border-color); background: var(--card-bg); border-radius: 6px; cursor: pointer; font-size: 13px; }
 .data-table { width: 100%; border-collapse: collapse; background: var(--card-bg); border-radius: 8px; overflow: hidden; }
 .data-table th { background: linear-gradient(180deg, #f8fafc 0%, #eff2f7 100%); padding: 12px 14px; text-align: left; font-size: 12px; font-weight: 600; color: var(--text-secondary); letter-spacing: 0.3px; border-bottom: 2px solid var(--primary-lighter); white-space: nowrap; position: sticky; top: 0; z-index: 5; }
 .data-table td { padding: 12px 14px; border-bottom: 1px solid var(--border-color); font-size: 13px; color: var(--text-secondary); }
 .data-table tbody tr { transition: background 0.15s ease; }
 .data-table tbody tr:hover td { background: var(--primary-lightest); }
 .title-cell { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
 .action-cell { white-space: nowrap; display: flex; gap: 6px; }
 .tag { display: inline-block; padding: 2px 8px; background: #f0f0f0; border-radius: 4px; font-size: 11px; }
 .status-draft { background: #fff7e6; color: #fa8c16; }
.modal-large { max-width: 900px; }
/* 案例详情样式 - 留空用于未来扩展 */
.case-detail { }
 .content-block { background: #f8f9fa; padding: 14px; border-radius: 6px; margin: 8px 0 16px; white-space: pre-wrap; line-height: 1.6; }
 .pdf-viewer { margin-top: 16px; border: 1px solid var(--border-color); border-radius: 8px; overflow: hidden; }
 .loading-text { text-align: center; padding: 40px; color: var(--text-secondary); }
 .page-container { padding-bottom: 20px; }

 /* ========== Inline Toast ========== */
 .toast-inline { padding: 8px 12px; border-radius: 6px; font-size: 13px; display: flex; align-items: center; }
 .toast-inline.success { background: #f6ffed; border: 1px solid #b7eb8f; color: #389e0d; }
 .toast-inline.error { background: #fff2f0; border: 1px solid #ffccc7; color: #cf1322; }

.login-page {
    position: fixed; inset: 0;
    /* 天蓝色调：与 APP 登录页一致，中心向四周渐深 */
    background: radial-gradient(circle at 50% 0%, #60a5fa 0%, #3b82f6 48%, #2563eb 100%);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
    /* 登录页局部主题色改为蓝色系，不影响全局主题 */
    --lp-1: #93c5fd;
    --lp-2: #3b82f6;
    --lp-3: #1d4ed8;
}
.login-page::before {
    content: '';
    position: absolute; inset: 0;
    /* 顶部轻微高光，让蓝色更通透 */
    background: linear-gradient(180deg, rgba(255,255,255,0.10) 0%, transparent 55%);
    pointer-events: none;
    z-index: 0;
}
.login-page::after {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(620px 360px at 50% 0%, rgba(255,255,255,0.20), transparent 70%);
    pointer-events: none;
    z-index: 0;
    animation: loginBgPulse 12s ease-in-out infinite alternate;
}
@keyframes loginBgDrift {
    0%   { background-position: 0% 0%, 100% 100%, 50% 0%, 0% 0%; }
    100% { background-position: 6% 4%, 94% 96%, 52% 6%, 100% 100%; }
}
@keyframes loginBgPulse {
    0%   { opacity: 0.85; }
    100% { opacity: 1.05; }
}
@keyframes bgPulse {
    0% { background: rgba(10,20,40,0.25); }
    100% { background: rgba(10,20,40,0.45); }
}
/* ===== 登录页抽象几何背景装饰（极简、清透） ===== */
.login-decor {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
}
.login-decor .dec { position: absolute; display: block; will-change: transform; }
.dec-blob {
  left: -4%; bottom: -6%; width: 340px; height: 340px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.78) 0%, rgba(255,255,255,0.28) 48%, transparent 72%);
  filter: blur(3px);
  opacity: 0.9;
  animation: decBlob 20s ease-in-out infinite alternate;
}
.dec-blob.b2 {
  left: auto; right: -8%; top: -8%; width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(255,255,255,0.65) 0%, rgba(255,255,255,0.22) 45%, transparent 70%);
  animation-delay: -10s;
}
.dec-ring { border-radius: 50%; border: 3px solid rgba(255,255,255,0.55); background: transparent; }
.dec-ring.r1 { right: 12%; top: 28%; width: 160px; height: 160px; animation: decSpin 30s linear infinite; }
.dec-ring.r2 { left: 10%; top: 54%; width: 90px; height: 90px; border-width: 2px; opacity: 0.7; animation: decSpin 22s linear infinite reverse; }
.dec-ring.r3 { right: 26%; bottom: 18%; width: 56px; height: 56px; border-width: 2px; opacity: 0.6; }
.dec-dot { border-radius: 50%; background: #fff; }
.dec-dot.d1 { left: 32%; top: 20%; width: 8px; height: 8px; opacity: 0.65; }
.dec-dot.d2 { left: 18%; bottom: 34%; width: 6px; height: 6px; opacity: 0.55; }
.dec-dot.d3 { right: 22%; top: 62%; width: 9px; height: 9px; opacity: 0.6; }
.dec-dot.d4 { right: 36%; bottom: 28%; width: 5px; height: 5px; opacity: 0.55; }
.dec-dot.d5 { left: 48%; top: 46%; width: 4px; height: 4px; opacity: 0.45; }
@keyframes decBlob {
  0%   { transform: translate(0,0) scale(1); }
  100% { transform: translate(24px,-28px) scale(1.05); }
}
@keyframes decSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .login-decor .dec { animation: none !important; }
}
/* ===== 登录页星点 + 底部波浪 ===== */
.dec-star { position: absolute; color: #fff; opacity: 0.65; pointer-events: none; will-change: transform; filter: drop-shadow(0 1px 2px rgba(0,0,0,0.04)); }
.dec-star.s1 { left: 34%; top: 36%; width: 16px; height: 16px; animation: decTwinkle 5s ease-in-out infinite; }
.dec-star.s2 { right: 40%; top: 42%; width: 12px; height: 12px; animation: decTwinkle 4s ease-in-out infinite 0.7s; }
.dec-star.s3 { left: 58%; bottom: 32%; width: 14px; height: 14px; animation: decTwinkle 5.5s ease-in-out infinite 1.5s; }
.login-wave {
  position: fixed; left: 0; right: 0; bottom: 0; width: 100%; height: 100px;
  z-index: 0; pointer-events: none; display: block;
  fill: rgba(255,255,255,0.42);
}
@keyframes decTwinkle {
  0%, 100% { opacity: 0.35; transform: scale(0.85); }
  50%      { opacity: 0.75; transform: scale(1.1); }
}
@media (prefers-reduced-motion: reduce) {
  .dec-star { animation: none !important; }
}
 .login-wrapper {
 position: relative; z-index: 1;
 width: 100%;
 min-height: 100vh;
 display: flex;
 align-items: center;
 justify-content: space-between;
 gap: 40px;
 padding: 40px 7% 70px 5%;
 box-sizing: border-box;
 }
 .login-left {
 flex: 1 1 420px;
 max-width: 520px;
 display: flex;
 flex-direction: column;
 align-items: center;
 justify-content: center;
 position: relative;
 }
 .login-left::before {
  content: '';
  position: absolute;
  left: -18%; top: -10%;
  width: 520px; height: 520px;
  background: radial-gradient(circle, rgba(255,255,255,0.28) 0%, transparent 70%);
  border-radius: 50%;
  z-index: -1;
  pointer-events: none;
 }
 .login-left::after {
  content: '';
  position: absolute;
  right: -10%; bottom: -8%;
  width: 260px; height: 260px;
  background: radial-gradient(circle, rgba(255,255,255,0.18) 0%, transparent 70%);
  border-radius: 50%;
  z-index: -1;
  pointer-events: none;
 }
 /* 登录页顶部时间日期：与卡片同宽，居中 */
 .login-clock {
    width: 100%;
    text-align: center;
    margin-bottom: 22px;
    user-select: none;
    color: #3a3a6a;
    text-shadow: 0 1px 6px rgba(255,255,255,0.55);
 }
 .login-clock-time {
    font-size: 44px;
    font-weight: 200;
    letter-spacing: 4px;
    line-height: 1.05;
    font-variant-numeric: tabular-nums;
    background: linear-gradient(135deg, var(--lp-3) 0%, var(--lp-2) 50%, var(--lp-1) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    display: inline-flex;
    align-items: baseline;
 }
 .login-clock-time .colon { animation: colonBlink 1.2s ease-in-out infinite; }
 .login-clock-time .sec {
    font-size: 22px;
    margin-left: 6px;
    font-weight: 300;
    letter-spacing: 2px;
    opacity: 0.85;
 }
 .login-clock-date {
    margin-top: 6px;
    font-size: 14px;
    letter-spacing: 2px;
    color: rgba(71,85,105,0.92);
    font-weight: 400;
 }
 .login-clock-date .week {
    margin: 0 10px;
    padding: 2px 10px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--lp-2) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--lp-2) 28%, transparent);
    color: var(--lp-3);
    font-size: 12px;
    letter-spacing: 1px;
 }
 .login-clock-greet {
     margin-top: 4px;
     font-size: 12px;
     color: color-mix(in srgb, var(--lp-2) 75%, #444);
     letter-spacing: 1.5px;
 }
 /* 天蓝背景上左侧文字统一变白 */
 .login-page .login-clock { color: rgba(255,255,255,0.92); text-shadow: 0 2px 8px rgba(0,0,0,0.18); }
 .login-page .login-clock-time { background: none; -webkit-text-fill-color: #fff; color: #fff; }
 .login-page .login-clock-date { color: rgba(255,255,255,0.88); }
 .login-page .login-clock-date .week { background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.28); color: #fff; }
 .login-page .login-clock-greet { color: rgba(255,255,255,0.72); }
 .login-page .login-qr-title { color: #fff; text-shadow: 0 2px 6px rgba(0,0,0,0.15); }
 .login-page .login-qr-tip { color: rgba(255,255,255,0.78); }
 .login-page .login-qr-label { color: #fff; }
 .login-page .login-qr-note { color: rgba(255,255,255,0.68); }
 .login-page .login-qr-download { color: #fff; }
 .login-page .login-qr-download:hover { background: rgba(255,255,255,0.16); }
 .login-page .login-qr-download:disabled { color: rgba(255,255,255,0.45); }
 .login-page .login-footer { color: rgba(255,255,255,0.72); }
 .login-page .login-register-row a { color: var(--lp-2); }
 .login-page .login-register-row a:hover { background: color-mix(in srgb, var(--lp-2) 12%, transparent); }
 @keyframes colonBlink {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.35; }
 }
 @media (max-width: 480px) {
     .login-clock-time { font-size: 36px; }
     .login-clock-time .sec { font-size: 18px; }
 }
 @media (max-width: 900px) {
     .login-wrapper {
         flex-direction: column;
         justify-content: flex-start;
         padding: 24px 20px 80px;
         gap: 24px;
     }
     .login-left { width: 100%; max-width: 420px; }
     .login-box { flex: 0 0 auto; width: 100%; max-width: 420px; }
 }
.login-box {
   flex: 0 0 420px;
   width: 420px;
   background: #ffffff;
   border-radius: 24px;
   padding: 44px 36px 32px;
   box-shadow:
       0 24px 60px rgba(0, 0, 0, 0.18),
       0 8px 22px rgba(0, 0, 0, 0.10);
   transition: transform 0.35s ease, box-shadow 0.35s ease;
   position: relative;
}
.login-box:hover {
   transform: translateY(-3px);
   box-shadow:
       0 32px 78px rgba(0, 0, 0, 0.22),
       0 10px 28px rgba(0, 0, 0, 0.12);
}
 .login-title {
  text-align: center;
  font-size: 26px; font-weight: 700;
  margin: 0 0 28px 0;
  letter-spacing: 1px;
  /* 渐变色文字：跟随主题（深→主→浅） */
  background: linear-gradient(135deg, var(--lp-3) 0%, var(--lp-2) 45%, var(--lp-1) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  }
  .login-form { width: 100%; }
  .login-input-group {
  position: relative;
  margin-bottom: 18px;
  }
  .login-input-group input {
  width: 100%;
  height: 50px;
  padding: 0 44px 0 44px;
  border: 1px solid color-mix(in srgb, var(--lp-2) 18%, transparent);
  border-radius: 12px;
  font-size: 15px;
  color: #2d2b6b;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(250, 248, 255, 0.78));
  transition: all 0.25s;
  box-shadow: 0 2px 10px color-mix(in srgb, var(--lp-2) 8%, transparent), 0 0 0 1px rgba(255, 255, 255, 0.7) inset;
  }
  .login-input-group input::placeholder { color: #9ca3af; }
  .login-input-group input:focus {
  outline: none;
  border-color: color-mix(in srgb, var(--lp-2) 60%, transparent);
  background: #ffffff;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--lp-2) 16%, transparent), 0 4px 16px color-mix(in srgb, var(--lp-2) 10%, transparent);
  }
  .login-icon {
     position: absolute;
     left: 15px; top: 50%;
     transform: translateY(-50%);
     font-size: 16px;
     color: #a3a6c8;
     user-select: none;
  }
  .login-eye {
     position: absolute;
     right: 10px; top: 50%;
     transform: translateY(-50%);
     color: color-mix(in srgb, var(--lp-2) 60%, #5b6472);
     cursor: pointer;
     padding: 8px;
     user-select: none;
     display: inline-flex;
     align-items: center;
     justify-content: center;
     transition: color 0.2s;
  }
  .login-eye:hover { color: var(--lp-2); }
  .login-eye svg { display: block; }
  .login-error {
     min-height: 18px;
     font-size: 12px;
     color: #e5484d;
     margin-bottom: 8px;
  }
  .login-btn {
     width: 100%;
     height: 50px;
     border: none;
     border-radius: 12px;
     background: linear-gradient(135deg, var(--lp-1) 0%, var(--lp-2) 50%, var(--lp-3) 100%);
     color: #fff;
     font-size: 16px;
     font-weight: 600;
     cursor: pointer;
     transition: all 0.25s;
     letter-spacing: 6px;
     box-shadow: 0 10px 26px color-mix(in srgb, var(--lp-2) 42%, transparent), 0 0 0 1px rgba(255, 255, 255, 0.25) inset;
  }
 .login-btn:hover {
     transform: translateY(-1px);
     background: linear-gradient(135deg, var(--lp-1) 0%, var(--lp-2) 60%, var(--lp-3) 100%);
     box-shadow: 0 14px 34px color-mix(in srgb, var(--lp-2) 55%, transparent), 0 0 0 1px rgba(255, 255, 255, 0.35) inset;
     filter: brightness(1.04);
  }
 .login-btn:disabled {
     background: linear-gradient(135deg, color-mix(in srgb, var(--lp-1) 70%, #fff), color-mix(in srgb, var(--lp-2) 40%, #fff));
     cursor: not-allowed;
     box-shadow: none;
  }
 /* 注册入口位于奶白毛玻璃卡片内，使用深色文字与品牌色链接保证可读（替代原本的白色文字） */
 .login-register-row { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 18px; font-size: 13px; color: var(--text-secondary); }
 .login-register-row a { color: var(--primary-color); text-decoration: none; font-weight: 500; transition: all 0.2s; padding: 3px 8px; border-radius: 6px; }
 .login-register-row a:hover { background: var(--primary-lightest); }
 .login-register-row .dot { color: var(--text-muted); }
 .form-error { color: var(--danger-color); font-size: 12px; padding: 6px 10px; background: var(--danger-light); border-radius: 4px; margin-top: 4px; }
 .form-success { color: var(--success-dark, #237804); font-size: 12px; padding: 6px 10px; background: var(--success-light, #f6ffed); border: 1px solid var(--success-color, #52c41a); border-radius: 4px; margin-top: 4px; }
 .form-msg { margin-top: 4px; }
 .login-footer {
  position: fixed; bottom: 22px; left: 0; right: 0;
  font-size: 12px;
  color: rgba(71,85,105,0.7);
  text-align: center;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 3px rgba(255, 255, 255, 0.5);
  }
/* ===== 注册弹窗横向布局（标签左、输入右，两列网格，聚焦悬浮提示） ===== */
.reg-form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 18px; }
.reg-form .form-group { display: flex; align-items: center; gap: 10px; margin-bottom: 0; }
.reg-form .form-group label { flex: 0 0 84px; text-align: right; font-size: 13px; color: var(--text-secondary); margin-bottom: 0; white-space: nowrap; }
.reg-input-wrap { position: relative; flex: 1 1 auto; }
.reg-form .form-group input { width: 100%; height: 42px; }
.reg-input-wrap::after {
  content: attr(data-hint);
  position: absolute; left: 0; bottom: calc(100% + 7px);
  display: none;
  max-width: 260px; white-space: nowrap;
  background: rgba(30, 41, 59, 0.88); color: #fff;
  font-size: 12px; line-height: 1.4;
  padding: 6px 10px; border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
  z-index: 10;
}
.reg-input-wrap::before {
  content: '';
  position: absolute; left: 14px; bottom: calc(100% + 2px);
  display: none;
  border: 5px solid transparent; border-top-color: rgba(30, 41, 59, 0.88);
  z-index: 10;
}
.reg-input-wrap:hover::after, .reg-input-wrap:focus-within::after,
.reg-input-wrap:hover::before, .reg-input-wrap:focus-within::before { display: block; }
.reg-section { grid-column: 1 / -1; margin: 6px 0 2px; padding: 6px 10px; border-radius: 6px; font-size: 12px; font-weight: 600; }
.reg-error-wrap { grid-column: 1 / -1; }
@media (max-width: 600px) {
  .reg-form { grid-template-columns: 1fr; }
  .reg-form .form-group label { flex-basis: 92px; }
}

 /* ===== 登录页 APP 下载二维码区块（无容器，直接二维码） ===== */
 .login-qr-section {
  margin-top: 28px;
  width: 100%;
  text-align: center;
 }
 .login-qr-title {
  font-size: 16px; font-weight: 700; color: #2f2f5a;
  letter-spacing: 1px; margin-bottom: 8px;
 }
 .login-qr-tip {
  font-size: 12px; color: #6b6b8f; line-height: 1.5;
  margin-bottom: 18px;
 }
 .login-qr-row {
  display: flex; gap: 28px; justify-content: center;
 }
 .login-qr-item {
  display: flex; flex-direction: column; align-items: center;
  transition: transform 0.25s ease;
 }
 .login-qr-item:hover { transform: translateY(-3px); }
 .login-qr-label {
  display: inline-flex; align-items: center; gap: 5px;
  margin-bottom: 4px; font-size: 13px; font-weight: 600; color: #333;
 }
 .qr-channel-icon {
  width: 15px; height: 15px; color: var(--lp-3);
 }
 .login-qr-ver {
  margin-bottom: 8px; font-size: 11px; color: var(--primary-color);
  background: color-mix(in srgb, var(--primary-color) 10%, transparent);
  padding: 1px 8px; border-radius: 999px;
 }
 .lab-qr {
  width: 128px; height: 128px;
  display: flex; align-items: center; justify-content: center;
  background: #fff; border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08), 0 0 0 1px rgba(255,255,255,0.6) inset;
  transition: box-shadow 0.25s ease;
 }
 .login-qr-item:hover .lab-qr {
  box-shadow: 0 12px 32px rgba(0,0,0,0.12), 0 0 0 1px rgba(255,255,255,0.7) inset;
 }
 .lab-qr img { display: block; }
 .login-qr-download {
  margin-top: 12px;
  padding: 5px 14px;
  background: transparent; border: none; border-radius: 999px;
  font-size: 12px; color: var(--primary-color);
  cursor: pointer; text-decoration: none;
  transition: all 0.2s;
 }
 .login-qr-download:hover {
  background: color-mix(in srgb, var(--primary-color) 10%, transparent);
 }
 .login-qr-download:disabled {
  color: #bbb; background: transparent; cursor: not-allowed;
 }
 .login-qr-note {
  margin-top: 14px; font-size: 12px; color: #888;
 }

 .chart-card h3 {
 font-size: 20px;
 font-weight: 600;
 color: var(--text-color);
 margin-bottom: 12px;
 }

 .page-header h2 {
 font-size: 22px;
 font-weight: 600;
 }

 .card-title, .card-header > span:first-child {
 font-size: 16px;
 font-weight: 600;
 }

 /* 新建工单 - A4页宽 */
.order-form-page { max-width: 1200px; margin: 0 auto; }
/* 工单详情页占满整个内容区，不做 A4 居中 */
.order-form-page.od-a4 { max-width: 100%; width: 100%; margin: 0; padding: 16px 20px; }

/* ========== Order Form Underline Inputs ========== */
 .order-form input:not([type="file"]),
 .order-form textarea,
 .order-form select {
 border: none;
 border-bottom: 1px solid var(--border-color);
 background: transparent;
 border-radius: 0;
 padding: 8px 0;
 box-shadow: none;
 }
 .order-form input:not([type="file"]):focus,
 .order-form textarea:focus,
 .order-form select:focus {
 outline: none;
 border-bottom-color: var(--primary-color);
 box-shadow: none;
 }
 .order-form textarea {
 min-height: 80px;
 resize: vertical;
 }
 /* 工单表单：被锁定字段标识 */
.field-locked-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    padding: 2px 10px;
    font-size: 11px;
    font-weight: 400;
    color: #8c8c8c;
    background: #f5f5f5;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    white-space: nowrap;
}
.field-locked-badge::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #d9d9d9;
    border-radius: 50%;
    margin-right: 2px;
}
/* 禁用输入框样式 */
input:disabled, textarea:disabled, select:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    background: #f9f9f9 !important;
    color: #666 !important;
    border-color: #e8e8e8 !important;
}

.order-form .autocomplete-dropdown {
 top: 36px;
 }

 /* ========== Server Page ========== */
 .info-item {
 display: flex; flex-direction: column;
 padding: 10px 12px; background: var(--bg-color);
 border-radius: 6px;
 }
.info-item .lbl { font-size: 11px; color: var(--text-muted); margin-bottom: 4px; }
.info-item .val { font-size: 15px; font-weight: 500; color: var(--text-color); }

/* ========== 工单表单底部按钮 ========== */
.form-bottom-bar {
    position: sticky;
    bottom: 0;
    z-index: 10;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    padding: 16px 24px;
    margin: 24px 0 40px;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-top: 1px solid var(--border-color, #e5e7eb);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.04);
    border-radius: 8px;
}
.btn-form {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 110px;
    height: 40px;
    padding: 0 20px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    white-space: nowrap;
}
.btn-form svg { flex-shrink: 0; }
.btn-form:active { transform: translateY(1px); }
.btn-form:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
.btn-form-cancel {
    background: #fff;
    color: var(--text-color, #333);
    border-color: var(--border-color, #d1d5db);
}
.btn-form-cancel:hover {
    background: #f9fafb;
    border-color: var(--primary-color, #1890ff);
    color: var(--primary-color, #1890ff);
}
.btn-form-save {
    background: linear-gradient(135deg, var(--primary-color, #1890ff) 0%, var(--primary-dark, #096dd9) 100%);
    color: #fff;
    border: none;
    box-shadow: 0 2px 8px color-mix(in srgb, var(--primary-color) 25%, transparent);
}
.btn-form-save:hover:not(:disabled) {
    box-shadow: 0 4px 14px color-mix(in srgb, var(--primary-color) 40%, transparent);
    transform: translateY(-1px);
}
.btn-form-save .spinner {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid rgba(255,255,255,0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: btn-spin 0.7s linear infinite;
}
@keyframes btn-spin { to { transform: rotate(360deg); } }
.company-opt:hover { border-color: var(--primary-color) !important; background: var(--primary-lightest); }
.company-opt.active { border-color: var(--primary-color) !important; background: var(--primary-lightest); }
@media (max-width: 480px) {
    .form-bottom-bar { flex-direction: column-reverse; gap: 8px; }
    .btn-form { width: 100%; }
}


 /* ========== Responsive ========== */
 @media (max-width: 768px) {
 .sidebar {
 position: fixed;
 left: 0;
 top: 0;
 bottom: 0;
 transform: translateX(-100%);
 }

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

 .mobile-menu-btn { display: block; }

 .stats-row { grid-template-columns: repeat(2, 1fr); }
 .chart-container { grid-template-columns: 1fr; }
 .form-row { flex-direction: column; gap: 0; }
 .detail-row { grid-template-columns: 1fr; }
 .detail-item.full { grid-column: span 1; }
 .fee-grid { grid-template-columns: repeat(2, 1fr); }
 }

/* ========== Print ========== */
@media print {
.sidebar, .header, .btn, .search-bar, .action-btns, .modal-overlay, .drawer-overlay, .pagination, .toast {
display: none !important;
}
.main-content { width: 100%; }
.content { padding: 0; }
.card { box-shadow: none; border: 1px solid #ddd; page-break-inside: avoid; }
}

/* ========== 路由过渡动画 ========== */
.route-fade-enter-active, .route-fade-leave-active {
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.route-fade-enter-from {
  opacity: 0;
  transform: translateY(8px);
}
.route-fade-leave-to {
  opacity: 0;
  transform: translateY(-8px);
}

/* ========== 错误边界 ========== */
.error-boundary {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 60px 20px; text-align: center; min-height: 300px;
}
.error-boundary-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--danger-color); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; font-weight: bold; margin-bottom: 16px;
}
.error-boundary h3 { margin-bottom: 8px; color: var(--text-color); }
.error-boundary p { color: var(--text-muted); margin-bottom: 20px; max-width: 400px; }

/* ========== 上传进度条 ========== */
.upload-progress {
  margin-top: 8px; height: 4px; background: var(--border-color); border-radius: 2px; overflow: hidden;
}
.upload-progress-bar {
  height: 100%; background: var(--primary-color); border-radius: 2px;
  transition: width 0.3s ease;
}
.upload-progress-text {
  font-size: 11px; color: var(--text-muted); margin-top: 4px; text-align: right;
}

/* ========== 响应式侧边栏增强 ========== */
@media (max-width: 1024px) {
  .sidebar { width: 60px; }
  .sidebar .sidebar-menu a span { display: none; }
  .sidebar .sidebar-user-name { display: none; }
  .sidebar.open { width: 180px; }
  .sidebar.open .sidebar-menu a span { display: inline; }
  .sidebar.open .sidebar-user-name { display: block; }
}

 /* ========== 技术资料树形样式 (v97) ========== */
 .tech-tree{user-select:none;}
 .tech-tree .tree-item-wrap{position:relative;}
 .tech-tree .tree-node-row{
 display:flex;align-items:center;padding:10px 8px 10px 4px;
 border-radius:6px;margin-bottom:2px;
 cursor:pointer;font-size:16px;line-height:1.5;gap:2px;
 transition:background 0.15s;
 }
 .tech-tree .tree-node-row:hover{background:var(--primary-light);}
 .tech-tree .tree-node-row.active{
 background:var(--primary-color);
 color:#fff;font-weight:600;
 }
 .tech-tree .tree-node-row.active .tree-count{
 background:rgba(255,255,255,0.25);color:#fff;
 }
 .tech-tree .tree-node-row.active .tree-toggle{
 color:#fff;
 }
.tech-tree-toolbar{
 display:flex;flex-wrap:wrap;gap:6px;width:100%;
 }
.tech-tree-toolbar .btn{margin:0;}
.tech-tree .tree-node-row{cursor:pointer;}
/* ===== 树状折叠/展开三角符号（与技术资料树一致） ===== */
.tech-tree .tree-toggle,
.tree-toggle {
flex-shrink: 0;
display: inline-flex;
width: 18px;
height: 18px;
align-items: center;
justify-content: center;
color: var(--text-muted);
line-height: 1;
margin-right: 2px;
transition: transform 0.2s;
transform: rotate(90deg); /* 默认展开：三角形朝下 */
cursor: pointer;
}
.tech-tree .tree-toggle:hover,
.tree-toggle:hover {
color: var(--primary-color);
}
.tech-tree .tree-toggle.collapsed,
.tree-toggle.collapsed {
transform: rotate(0deg); /* 收起：三角形朝右 */
}
.tech-tree .tree-toggle.leaf,
.tree-toggle.leaf {
transform: rotate(0deg);
opacity: 0.25;
cursor: default;
}
.tech-tree .tree-toggle.leaf svg,
.tree-toggle.leaf svg {
width: 6px;
height: 6px;
}

 .tech-tree .tree-label{
 flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
 font-size:16px;min-width:0;
 }
 .tech-tree .tree-count{
 flex-shrink:0;font-size:12px;color:var(--text-muted);
 background:rgba(128,128,128,0.1);border-radius:10px;
 padding:0 7px;height:20px;line-height:20px;margin-right:6px;
 }
 .tech-tree .tree-actions{display:flex;gap:2px;flex-shrink:0;opacity:0;transition:opacity 0.15s;}
 .tech-tree .tree-node-row:hover .tree-actions,.tech-tree .tree-node-row.active .tree-actions{opacity:1;}
 .tech-tree .btn-xs-link{
 background:none;border:none;padding:2px 5px;
 font-size:13px;cursor:pointer;border-radius:4px;
 color:var(--text-muted);transition:all 0.15s;
 }
 .tech-tree .btn-xs-link:hover{background:rgba(255,255,255,0.5);color:var(--primary-color);}
 .tech-tree .btn-xs-link.del:hover{color:var(--danger-color);background:rgba(220,53,69,0.08);}

 /* 备件仓库树状操作按钮已移至顶部工具栏（新建仓库/新增区域/编辑/删除） */

/* ===== 仓库目录顶部工具栏（单行布局） ===== */
.wh-toolbar {
display: flex;
gap: 4px;
flex-wrap: nowrap;
align-items: stretch;
width: 100%;
}
.wh-toolbar .btn {
flex: 1 1 0;
min-width: 0;
padding: 4px 6px;
font-size: 12px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}

  .tech-tree .tree-children{
  position:relative;padding-left:18px;margin-left:11px;
  border-left:1.5px dotted var(--primary-color);
  }
 .tech-tree .tree-node-row.child{padding-left:4px;font-size:15px;}
 .tech-tree .tree-node-row.child .tree-label{font-size:15px;}
  .tech-tree .tree-node-row.child3{padding-left:4px;font-size:14px;}
  .tech-tree .tree-node-row.child3 .tree-label{font-size:14px;}



/* ===== 全局UI现代化升级：标题更大气、内容更精致、按钮更现代 ===== */
/* 页面内容基准：更紧凑精致 */
.page-container { font-size: 13px; color: var(--text-secondary); }

/* 标题：更大、更粗、更有层次 */
.page-header { margin-bottom: 24px; padding-bottom: 14px; border-bottom: 1px solid var(--border-color); }
.page-header h2 { font-size: 28px; font-weight: 700; color: var(--text-color); letter-spacing: 0.3px; }
.page-header h3 { font-size: 20px; font-weight: 700; color: var(--text-color); }

/* 内容区域字体更小更精致 */
.card-body { font-size: 13px; }
.content-block { font-size: 13px; line-height: 1.7; }
.search-input, .filter-select, .btn-back { font-size: 12px; padding: 9px 14px; }

/* ===== 工单详情页 宽屏显示 ===== */
/* 容器占满整个内容区，取消旧 A4 居中限制，最大宽度 1600px 以保证大屏阅读舒适度 */
.od-a4 {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px 24px 32px;
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    box-sizing: border-box;
    overflow: visible;
    flex-shrink: 0;
}
/* 内部容器，确保所有卡片在同DOM父级内 */
.od-a4-inner {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}
/* 卡片铺满容器宽度，取消旧 A4 纸张居中限制 */
.od-a4 > .card,
.od-a4 .card,
.order-form-page > .card,
.order-form-page .card {
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-bottom: 18px;
    box-sizing: border-box !important;
}
.od-a4 .card-body { min-width: 0; overflow: hidden; }
.od-a4 > .card:last-child { margin-bottom: 0; }
/* 卡片内部网格铺满：每块宽度由内容自适应（最小 200px，内容多则自动变宽），
   剩余空间由行尾的"占位空格"吸收，避免最后一项独占一行时与同行宽度不一致 */
.od-a4 .card-body > .dg:not(.full),
.od-a4 .card-body > .dg.sparse,
.od-a4 .card-body > .dg.aligned {
    max-width: 100%;
    grid-template-columns: repeat(auto-fit, minmax(200px, auto));
}
.od-a4 .card-body > .fee-grid { max-width: 100%; margin: 0 auto; }
/* 卡片标题：左侧强调条 + 清晰层级（取消居中） */
.od-a4 .card-header {
    justify-content: flex-start;
    position: relative;
    border-bottom: 1px solid var(--border-color, #e8e8e8);
    padding-bottom: 12px;
}
.od-a4 .card-header::before {
    content: "";
    width: 4px;
    height: 16px;
    background: var(--primary-color, #1890ff);
    border-radius: 2px;
    margin-right: 8px;
}
.od-a4 .card-header .btn,
.od-a4 .card-header .status-tag {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
}
.od-a4 .card-header .od-title {
    text-align: left;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color, #333);
}
.od-a4 .card-body table { width: 100%; border-collapse: collapse; font-size: 14px; }
.od-a4 .card-body table th,
.od-a4 .card-body table td { padding: 10px 14px; border: 1px solid #e8e8e8; vertical-align: middle; }
.od-a4 .card-body table thead th { background: #f5f7fa; color: #555; font-weight: 600; text-align: left; }
.od-a4 .card-body table tbody tr:nth-child(even) { background: #fafbfc; }
.od-a4 .card-body table tbody tr:hover { background: #f0f6ff; }

/* 富文本内容（处理过程/维修过程/完成情况）中的图片与视频排版 */
.od-a4 .desc img,
.od-a4 .card-body .ql-editor img,
.od-card .desc img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 6px 0;
    box-shadow: 0 1px 4px rgba(0,0, 0,.08);
}
.od-a4 .desc video,
.od-card .desc video {
    max-width: 100%;
    border-radius: 8px;
    margin: 6px 0;
    background: #000;
    display: block;
}
/* 图片环绕（正文内联 float 由编辑器写入 inline style，这里仅兜底） */
.od-a4 .desc img[style*="float"] { margin: 4px 12px; }
.od-a4 .desc img[style*="auto"] { display: block; margin: 8px auto; }
@media (max-width: 840px) {
    .od-a4 { width: 100%; max-width: 100%; margin: 0; border-radius: 0; box-shadow: none; padding: 16px; }
}

/* ===== 顶部操作栏（返回+工单号 / 操作按钮单行布局，按钮自然右对齐换行） ===== */
.od-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; flex-wrap: wrap; }
.od-top-main { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; flex: 0 1 auto; min-width: 0; }
.od-wo { font-size: 18px; font-weight: 700; color: var(--text-color, #2c3e50); letter-spacing: .5px; }
.od-payer { font-size: 12px; color: var(--text-muted); background: #f5f5f5; border-radius: 4px; padding: 3px 8px; }
.od-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: flex-end; flex: 1 1 auto; min-width: 0; }
.od-divider { width: 1px; height: 20px; background: var(--border-color); margin: 0 4px; flex-shrink: 0; }

/* ===== 生成报告按钮下的进度条 ===== */
.gen-wrap { display: inline-flex; flex-direction: column; align-items: stretch; gap: 3px; }
.gen-progress {
position: relative;
height: 6px;
min-width: 120px;
background: #f0f2f5;
border-radius: 3px;
overflow: hidden;
}
.gen-progress-bar {
height: 100%;
background: linear-gradient(90deg, var(--primary-color, #1890ff), var(--primary-dark, #096dd9));
border-radius: 3px;
transition: width .2s ease;
}
.gen-progress-text {
position: absolute;
right: 4px;
top: -1px;
font-size: 9px;
line-height: 6px;
color: var(--text-muted, #999);
}

/* ===== 报告与附件列表项（按钮左对齐，紧跟标题后） ===== */
.od-att { display: flex; align-items: center; justify-content: flex-start; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--border-color); flex-wrap: wrap; }
.od-att:last-child { border-bottom: none; }
.od-att-info { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 0 1 auto; }
.od-att-title { font-weight: 500; }
.od-att-sub { font-size: 12px; padding: 2px 8px; border-radius: 4px; }
.od-att-sub.ok { color: var(--success-color, #52c41a); background: rgba(82,196,26,.1); }
.od-att-sub.pending { color: var(--text-muted); background: #f5f5f5; }
.od-att-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-left: auto; }
.od-att-empty { color: var(--text-muted); font-size: 12px; margin-left: auto; }


/* 统计卡片标题 */
.chart-card h3 { font-size: 20px; font-weight: 700; color: var(--text-color); }

/* Tab 导航 */
.tab-nav { display: flex; gap: 6px; padding: 4px; background: var(--bg-color); border-radius: 10px; border: 1px solid var(--border-color); }
.tab-nav button { padding: 9px 18px; border: none; background: transparent; cursor: pointer; border-radius: 8px; font-size: 14px; font-weight: 600; color: var(--text-secondary); transition: all 0.25s ease; }
.tab-nav button:hover { background: color-mix(in srgb, var(--primary-color) 8%, transparent); color: var(--primary-color); }
.tab-nav button.active { background: var(--primary-color); color: #fff; box-shadow: 0 4px 12px color-mix(in srgb, var(--primary-color) 25%, transparent); }

/* + 新建/+ 新增 按钮中的加号 */
.btn-plus { font-size: 1.5em; font-weight: 700; margin-right: 5px; line-height: 1; }

/* ===== 文字语义层级工具类 ===== */
.text-primary { color: var(--primary-color); }
.text-success { color: var(--success-color); }
.text-danger { color: var(--danger-color); }
.text-warning { color: var(--warning-color); }
.text-strong { font-weight: 700; color: var(--text-color); }
.text-label { font-size: 11px; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
.text-number { font-weight: 700; font-variant-numeric: tabular-nums; }
.data-table .title-cell { font-size: 13px; font-weight: 600; color: var(--text-color); }

/* 搜索输入框更现代 */
.search-input, .filter-select, .btn-back { border-radius: 10px; transition: all 0.2s ease; }
.search-input:focus, .filter-select:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 10%, transparent); outline: none; }

/* 统计卡片 */
.stat-card { border-radius: 14px; padding: 22px 18px; background: linear-gradient(135deg, rgba(255,255,255,0.98) 0%, var(--card-bg) 100%); border: 1px solid rgba(0,0,0,0.05); box-shadow: 0 4px 16px rgba(0,0,0,0.06); transition: all 0.3s ease; }
.stat-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.stat-num { font-size: 34px; font-weight: 700; color: var(--primary-color); }
.stat-label { font-size: 12px; color: var(--text-muted); margin-top: 6px; font-weight: 500; }

/* 头部标题更大气 */
.header-center { font-size: 24px; font-weight: 700; letter-spacing: 0.5px; text-shadow: 0 2px 6px rgba(0,0,0,0.2); }

/* 侧边栏当前项更醒目 */
.sidebar-menu a.router-link-active { background: var(--sidebar-active-bg); color: var(--sidebar-text-active); font-weight: 600; box-shadow: inset 3px 0 0 rgba(255,255,255,0.8); }
/* 图表 tooltip 即时显示/隐藏 */
canvas+.chartjs-tooltip,#chartjs-tooltip,.chartjs-tooltip{transition:none!important;}
/* 接单进度时间线 */
.accept-steps{display:flex;align-items:center;gap:6px;margin-top:14px;flex-wrap:wrap;}
.accept-step{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--text-muted);padding:6px 12px;border-radius:20px;background:var(--bg-color);border:1px solid var(--border-color);}
.accept-step .dot{width:20px;height:20px;border-radius:50%;background:var(--text-muted);color:#fff;display:inline-flex;align-items:center;justify-content:center;font-size:12px;}
.accept-step.on{color:var(--success-color);border-color:var(--success-color);background:rgba(40,199,111,.08);}
.accept-step.on .dot{background:var(--success-color);}
/* 通知铃铛 */
.header-right{margin-left:auto;display:flex;align-items:center;gap:12px;}
.header-notif{position:relative;}
.header-notif-btn{position:relative;background:rgba(255,255,255,.15);border:none;color:#fff;width:38px;height:38px;border-radius:50%;font-size:18px;cursor:pointer;transition:background .2s;display:flex;align-items:center;justify-content:center;}
.header-notif-btn:hover{background:rgba(255,255,255,.28);}
.notif-badge{position:absolute;top:-4px;right:-4px;min-width:18px;height:18px;padding:0 4px;background:var(--danger-color);color:#fff;border-radius:9px;font-size:11px;line-height:18px;text-align:center;box-shadow:0 0 0 2px rgba(255,255,255,.2);}
.notif-backdrop{position:fixed;inset:0;z-index:40;}
.notif-panel{position:absolute;top:46px;right:0;width:340px;max-width:86vw;background:var(--card-bg);border:1px solid var(--border-color);border-radius:12px;box-shadow:0 12px 40px rgba(0,0,0,.18);z-index:50;overflow:hidden;}
.notif-panel-head{display:flex;align-items:center;justify-content:space-between;padding:12px 16px;border-bottom:1px solid var(--border-color);font-weight:600;color:var(--text-color);}
.notif-readall{background:none;border:none;color:var(--primary-color);font-size:13px;cursor:pointer;}
.notif-list{max-height:60vh;overflow-y:auto;}
.notif-item{padding:12px 16px;border-bottom:1px solid var(--border-color);cursor:pointer;transition:background .15s;}
.notif-item:hover{background:var(--bg-color);}
.notif-item.unread{background:var(--primary-bg-color);}
.notif-item.unread .notif-title::before{content:'';display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--primary-color);margin-right:6px;vertical-align:middle;}
.notif-title{font-size:14px;font-weight:600;color:var(--text-color);margin-bottom:4px;}
.notif-content{font-size:13px;color:var(--text-secondary);line-height:1.5;}
.notif-time{font-size:11px;color:var(--text-muted);margin-top:6px;}
.notif-empty{padding:30px;text-align:center;color:var(--text-muted);font-size:13px;}
.notif-sound-btn{background:transparent;border:1px solid var(--border-color);color:var(--text-muted);width:26px;height:26px;border-radius:6px;font-size:14px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;transition:all .2s;}
.notif-sound-btn:hover{border-color:var(--primary-color);color:var(--primary-color);}
.notif-sound-btn.on{color:var(--primary-color);border-color:var(--primary-lighter);background:var(--primary-lightest);}
.notif-sound-btn.on::after{content:'·';color:var(--success-color);margin-left:-2px;font-weight:900;}
.notif-panel-foot{padding:10px 16px;border-top:1px solid var(--border-color);text-align:center;background:var(--bg-color);}
.notif-panel-foot a{color:var(--primary-color);font-size:13px;cursor:pointer;text-decoration:none;font-weight:500;}
.notif-panel-foot a:hover{text-decoration:underline;}
/* ERP 数据管理 子选项卡(出库单/商品厂家/供应商) 选中/未选中 */
.dm-subtab{background:var(--bg-color,#fff);color:var(--text-muted);}
.dm-subtab:hover{background:color-mix(in srgb, var(--primary-color) 8%, transparent);color:var(--primary-color);border-color:var(--primary-color);}
.dm-subtab.active{background:var(--primary-color);color:#fff;border-color:var(--primary-color);font-weight:600;box-shadow:0 2px 6px color-mix(in srgb, var(--primary-color) 30%, transparent);}
/* ERP 出库单 列表：配件摘要 + 选中行高亮 */
.ob-summary{font-size:11px;color:var(--text-muted);margin-top:2px;line-height:1.4;}
.table tbody tr.selected{background:color-mix(in srgb, var(--primary-color) 8%, transparent);}
.table tbody tr{cursor:pointer;}
.table tbody tr td:first-child{text-align:center;}

/* ========== 单色 SVG 图标系统（替代彩色 emoji） ========== */
.mi{display:inline-block;width:1em;height:1em;flex:none;vertical-align:-0.15em;
  background-color:currentColor;-webkit-mask-position:center;mask-position:center;
  -webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;
  -webkit-mask-size:contain;mask-size:contain;}
.mi-box{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M12 2 3 7v10l9 5 9-5V7l-9-5zm0 2.3L18.5 8 12 11.7 5.5 8 12 4.3zM5 9.7l6 3.4v6.6l-6-3.3V9.7zm14 0v6.4l-6 3.3v-6.6l6-3.4z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M12 2 3 7v10l9 5 9-5V7l-9-5zm0 2.3L18.5 8 12 11.7 5.5 8 12 4.3zM5 9.7l6 3.4v6.6l-6-3.3V9.7zm14 0v6.4l-6 3.3v-6.6l6-3.4z'/></svg>");}
.mi-edit{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M3 17.25V21h3.75L17.8 9.94l-3.75-3.75L3 17.25zM20.7 7.04a1 1 0 0 0 0-1.41l-2.34-2.34a1 1 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M3 17.25V21h3.75L17.8 9.94l-3.75-3.75L3 17.25zM20.7 7.04a1 1 0 0 0 0-1.41l-2.34-2.34a1 1 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z'/></svg>");}
.mi-gear{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M19.14 12.94a7.49 7.49 0 0 0 .05-.94 7.49 7.49 0 0 0-.05-.94l2.03-1.58a.5.5 0 0 0 .12-.64l-1.92-3.32a.5.5 0 0 0-.61-.22l-2.39.96a7.3 7.3 0 0 0-1.62-.94l-.36-2.54a.5.5 0 0 0-.5-.42h-3.84a.5.5 0 0 0-.5.42l-.36 2.54c-.59.24-1.13.56-1.62.94l-2.39-.96a.5.5 0 0 0-.61.22L2.74 8.84a.5.5 0 0 0 .12.64l2.03 1.58c-.03.31-.05.62-.05.94s.02.63.05.94l-2.03 1.58a.5.5 0 0 0-.12.64l1.92 3.32c.14.24.43.34.69.22l2.39-.96c.49.38 1.03.7 1.62.94l.36 2.54c.05.24.25.42.5.42h3.84c.25 0 .45-.18.5-.42l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.26.12.55.02.69-.22l1.92-3.32a.5.5 0 0 0-.12-.64l-2.03-1.58zM12 15.5A3.5 3.5 0 1 1 12 8.5a3.5 3.5 0 0 1 0 7z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M19.14 12.94a7.49 7.49 0 0 0 .05-.94 7.49 7.49 0 0 0-.05-.94l2.03-1.58a.5.5 0 0 0 .12-.64l-1.92-3.32a.5.5 0 0 0-.61-.22l-2.39.96a7.3 7.3 0 0 0-1.62-.94l-.36-2.54a.5.5 0 0 0-.5-.42h-3.84a.5.5 0 0 0-.5.42l-.36 2.54c-.59.24-1.13.56-1.62.94l-2.39-.96a.5.5 0 0 0-.61.22L2.74 8.84a.5.5 0 0 0 .12.64l2.03 1.58c-.03.31-.05.62-.05.94s.02.63.05.94l-2.03 1.58a.5.5 0 0 0-.12.64l1.92 3.32c.14.24.43.34.69.22l2.39-.96c.49.38 1.03.7 1.62.94l.36 2.54c.05.24.25.42.5.42h3.84c.25 0 .45-.18.5-.42l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.26.12.55.02.69-.22l1.92-3.32a.5.5 0 0 0-.12-.64l-2.03-1.58zM12 15.5A3.5 3.5 0 1 1 12 8.5a3.5 3.5 0 0 1 0 7z'/></svg>");}
.mi-clipboard{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M19 2h-4.18A3 3 0 0 0 11 0h2a3 3 0 0 0 0 0v2H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm-7 0a1 1 0 1 1 0 2 1 1 0 0 1 0-2zm7 16H7V4h2v2h6V4h2v14z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M19 2h-4.18A3 3 0 0 0 11 0h2a3 3 0 0 0 0 0v2H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm-7 0a1 1 0 1 1 0 2 1 1 0 0 1 0-2zm7 16H7V4h2v2h6V4h2v14z'/></svg>");}
.mi-warning{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z'/></svg>");}
.mi-trash{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M6 7h12v13a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2V7zm3-3h6l1 2h4v2H2V6h4l1-2zM9 9v9h2V9H9zm4 0v9h2V9h-2z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M6 7h12v13a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2V7zm3-3h6l1 2h4v2H2V6h4l1-2zM9 9v9h2V9H9zm4 0v9h2V9h-2z'/></svg>");}
.mi-copy{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M16 1H4a2 2 0 0 0-2 2v12h2V3h12V1zm3 4H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2zm0 16H8V7h11v14z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M16 1H4a2 2 0 0 0-2 2v12h2V3h12V1zm3 4H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2zm0 16H8V7h11v14z'/></svg>");}
.mi-check{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/></svg>");}
.mi-close{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M18.3 5.7 12 12l6.3 6.3-1.4 1.4L10.6 13.4 4.3 19.7 2.9 18.3 9.2 12 2.9 5.7l1.4-1.4L10.6 10.6l6.3-6.3z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M18.3 5.7 12 12l6.3 6.3-1.4 1.4L10.6 13.4 4.3 19.7 2.9 18.3 9.2 12 2.9 5.7l1.4-1.4L10.6 10.6l6.3-6.3z'/></svg>");}
.mi-doc{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M6 2h9l5 5v15a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1zm8 1.5V8h4.5L14 3.5z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M6 2h9l5 5v15a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1zm8 1.5V8h4.5L14 3.5z'/></svg>");}
.mi-search{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M15.5 14h-.8l-.3-.3a6.5 6.5 0 1 0-.7.7l.3.3v.8l5 5 1.5-1.5-5-5zm-6 0a4.5 4.5 0 1 1 0-9 4.5 4.5 0 0 1 0 9z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M15.5 14h-.8l-.3-.3a6.5 6.5 0 1 0-.7.7l.3.3v.8l5 5 1.5-1.5-5-5zm-6 0a4.5 4.5 0 1 1 0-9 4.5 4.5 0 0 1 0 9z'/></svg>");}
.mi-err{-webkit-mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z'/></svg>");mask-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z'/></svg>");}

/* ========== UI 现代化优化覆写层 ==========
   统一更轻盈、更紧凑、更现代的设计语言：
   - Header 由深色渐变改为白底细边框，视觉更干净
   - 侧边栏菜单更紧凑，激活态更细腻
   - 卡片/统计卡去掉浮夸上浮与大投影，改用精细描边高亮
   - 圆角、阴影、配色统一为柔和体系
================================================ */
:root {
  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-sm: 8px;
  --shadow-card: 0 1px 2px rgba(16,24,40,0.04), 0 1px 3px rgba(16,24,40,0.06);
  --shadow-card-hover: 0 2px 6px rgba(16,24,40,0.08), 0 6px 18px rgba(16,24,40,0.08);
  --shadow-pop: 0 8px 24px rgba(16,24,40,0.14);
}

/* ===== V1.2.1 通用组件对齐与位置优化 ===== */
.btn { font-weight: 600; }
.form-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.form-actions .btn { min-width: 92px; }
.form-group label { font-weight: 500; color: var(--text-secondary); }
.form-row { align-items: flex-start; }
.card-title, .card-header > span:first-child { font-weight: 600; color: var(--text-color); }
.table-wrapper th { text-align: left; font-weight: 600; white-space: nowrap; color: var(--text-secondary); }
.table-wrapper td { vertical-align: middle; }
.table-wrapper td.num, .table-wrapper th.num { text-align: right; font-variant-numeric: tabular-nums; }
.pagination { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; }
.modal-footer { gap: 12px; }
.modal-footer .btn { min-width: 88px; }
.stats-row { gap: 16px; }
.search-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.btn-primary { background: var(--primary-grad, linear-gradient(135deg, var(--primary-color), var(--primary-dark))); box-shadow: 0 2px 10px color-mix(in srgb, var(--primary-color) 22%, transparent); }
.btn-primary:hover { background: var(--primary-grad, linear-gradient(135deg, var(--primary-color), var(--primary-dark))); filter: brightness(1.05); }

/* ===== Header 现代化：白底细边框，标题融入左侧，右侧徽章描边式 ===== */
.header {
  height: 56px;
  background: var(--card-bg);
  background-image: none;
  color: var(--text-color);
  padding: 0 20px;
  box-shadow: 0 1px 0 var(--border-color), 0 1px 3px rgba(16,24,40,0.04);
  border-bottom: 1px solid var(--border-color);
}
.header-center {
  position: static;
  transform: none;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-color);
  letter-spacing: 0;
  text-shadow: none;
  margin-left: 4px;
}
.header .mobile-menu-btn { color: var(--text-secondary); }
.header .sidebar-toggle-btn { color: var(--text-secondary); }
.header .sidebar-toggle-btn:hover { background: var(--primary-lightest); color: var(--primary-color); }
.header .header-role-badge {
  color: var(--primary-color);
  background: var(--primary-lightest);
  border: 1px solid var(--primary-lighter);
}
.header-user-info:hover { background: var(--primary-lightest); }
.header-right { display: flex; align-items: center; gap: 10px; }

/* 通知按钮适配白底 */
.header-notif-btn {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--text-secondary);
  position: relative;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  transition: background 0.2s, color 0.2s;
}
.header-notif-btn:hover { background: var(--primary-lightest); color: var(--primary-color); }
.notif-badge {
  position: absolute; top: 2px; right: 2px;
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--danger-color); color: #fff;
  font-size: 10px; font-weight: 700; line-height: 16px;
  display: flex; align-items: center; justify-content: center;
}

/* ===== 侧边栏：菜单更紧凑，激活态更精致 ===== */
.sidebar { box-shadow: 1px 0 0 rgba(16,24,40,0.05); }
.sidebar-menu { padding: 8px 0; }
.sidebar-menu a { padding: 10px 14px; margin: 1px 8px; gap: 10px; }
.sidebar-menu a:hover { transform: translateX(2px); background: var(--sidebar-hover-bg); }
.sidebar-menu a.router-link-active {
  background: rgba(255,255,255,0.18);
  box-shadow: inset 2px 0 0 var(--sidebar-text-active);
  transform: none;
}
.sidebar-menu a.router-link-active::before { display: none; }
.sidebar.collapsed .sidebar-menu a { padding: 12px 0; }

/* ===== 卡片：去掉浮夸上浮，改精细描边高亮 ===== */
.card {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
  background: var(--card-bg);
}
.card:hover { box-shadow: var(--shadow-card-hover); transform: none; }
.card-header {
  padding: 14px 20px;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
}
.card-title { font-size: 15px; font-weight: 600; }
.card-body { padding: 20px; }

/* ===== 统计卡：去掉顶部粗色条，改精致圆角+温和投影 ===== */
.stat-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 16px 14px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
}
.stat-card::before { display: none; }
.stat-card:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-2px); }
.stat-value { font-size: 26px; font-weight: 700; }
.stat-label { font-size: 12px; color: var(--text-muted); margin-top: 4px; letter-spacing: 0.3px; }

/* ===== 图表卡：统一圆角与描边 ===== */
.chart-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  background: var(--card-bg);
  box-shadow: var(--shadow-card);
  padding: 18px;
}
.chart-card h3 { font-size: 15px; font-weight: 600; }

/* ===== 表格：更紧凑、表头更干净 ===== */
.data-table th {
  background: var(--card-bg);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-color);
  font-size: 12px; font-weight: 600;
}
.data-table td { padding: 10px 14px; font-size: 13px; }
.data-table tbody tr:hover td { background: var(--primary-bg-color); }

/* ===== 按钮：柔和圆角、去多余投影 ===== */
.btn { border-radius: var(--radius-sm); letter-spacing: 0; }
.btn:hover { transform: translateY(0); }
.btn-primary { box-shadow: 0 1px 2px rgba(16,24,40,0.06); }
.btn-primary:hover { transform: none; box-shadow: 0 2px 6px rgba(16,24,40,0.1); }
.btn-success, .btn-info, .btn-warning, .btn-danger { box-shadow: 0 1px 2px rgba(16,24,40,0.06); }
.btn-success:hover, .btn-info:hover, .btn-warning:hover, .btn-danger:hover { transform: none; }

/* ===== 表单控件：统一圆角 ===== */
.form-group input, .form-group select, .form-group textarea {
  border-radius: var(--radius-sm);
  box-shadow: none;
}

/* 登录页样式已统一至上方主样式表（奶白色毛玻璃 + 多层渐变）：见 .login-page / .login-box / .login-title / .login-input-group input / .login-btn / .login-register-row / .login-footer。
   此处原先的覆写定义已移除，避免覆盖主样式的新设计。 */

/* ========== 图标规范化 + 对齐 + 字体优化覆写层 ==========
   ① 通知铃铛改用规范 CSS 图标（.notif-bell），不再用 emoji 🔔
   ② 声音开关用纯 CSS 音符图标，跨平台统一呈现（不渲染为 emoji）
   ③ 表格/标签/统计卡/操作列统一垂直与水平对齐
   ④ 修正过小字号（标签 11px→12px），保证中文可读性
===================================================== */

/* 通知铃铛在 header 圆形按钮内的适配（白底主题） */
.header-notif-btn .notif-bell {
  width: 17px; height: 17px;
  border-width: 2px;
  border-color: var(--text-secondary);
  color: var(--text-secondary);
  margin-top: 1px;
}
.header-notif-btn .notif-bell::after {
  background: var(--text-secondary);
  bottom: -3px;
}

/* 声音开关：纯 CSS 音符图标（用两个圆点+尾巴组合），muted 状态加斜杠遮罩 */
.notif-sound-icon {
  position: relative;
  display: inline-block;
  width: 14px; height: 14px;
  flex-shrink: 0;
}
.notif-sound-icon::before {
  content: '';
  position: absolute;
  top: 3px; left: 0;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 4px 3px 0 0 currentColor;
}
.notif-sound-icon::after {
  content: '';
  position: absolute;
  top: 1px; left: 6px;
  width: 4px; height: 9px;
  background: currentColor;
  border-radius: 2px;
  transform: skewX(-18deg);
}
.notif-sound-icon.muted::before {
  box-shadow: 4px 3px 0 0 currentColor;
  opacity: 0.35;
}
.notif-sound-icon.muted::after {
  background: linear-gradient(135deg, transparent 42%, currentColor 42%, currentColor 58%, transparent 58%);
  opacity: 0.8;
}
.notif-sound-btn { font-variant-emoji: text; display:inline-flex; align-items:center; justify-content:center; }
/* 状态由内部图标 muted 类表达，去掉按钮级多余圆点 */
.notif-sound-btn.on::after { content: none; }

/* ===== 表格：统一垂直居中，避免含按钮/图标单元格顶对齐 ===== */
.data-table th, .data-table td,
.table-wrapper th, .table-wrapper td {
  text-align: left;
  vertical-align: middle;
}
.data-table td { font-size: 13.5px; }
.data-table th { font-size: 12.5px; }
/* 数字列/金额列右对齐更专业 */
.data-table .num-cell, .data-table td.num, td.amount, td.price, td.quantity {
  text-align: right;
}

/* ===== 状态标签：居中 + 字号提升 ===== */
.tag { text-align: center; line-height: 1.5; font-size: 12px; }
.status-tag { display: inline-flex; align-items: center; justify-content: center; }

/* ===== 统计卡：显式居中，保证不同覆盖定义下稳定 ===== */
.stat-card { text-align: center; }

/* ===== 操作按钮列：统一为一套 flex 样式 ===== */
.action-btns, .action-cell { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }

/* ===== 搜索栏：按钮与输入框垂直居中对齐，去除底对齐不齐 ===== */
.search-bar { align-items: center; }
.search-bar .btn { align-self: center; }
.search-bar .form-group { margin-bottom: 0; }

/* ===== 表单：label 与控件统一字号、label 靠左 ===== */
.form-group label { font-size: 13.5px; color: var(--text-secondary); }
.form-group input, .form-group select, .form-group textarea { font-size: 14px; }

/* ===== 按钮统一字号与行高，保证图标+文字垂直居中 ===== */
.btn { font-size: 13.5px; line-height: 1; }
.btn-sm { font-size: 12.5px; line-height: 1; }

/* ===== 卡片标题/节标题统一字号 ===== */
.card-header .card-title { font-size: 15px; }
.section-icon { display:inline-flex; align-items:center; justify-content:center; }

/* ===== 防 emoji 误渲染：符号类图标（✓ ✎ ＋ ↑↓ ← 等）强制文本呈现，避免个别平台渲染成彩色 emoji ===== */
.btn, .btn-sm, .tag, .status-tag, .tree-op, .action-btns a, .action-cell button,
.btn-back, .data-table td, .card-header, .modal-header, .notif-sound-btn {
  font-variant-emoji: text;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}
/* 操作符号统一内联对齐，保证与文字垂直居中 */
.tree-op { display:inline-flex; align-items:center; justify-content:center; line-height:1; }

/* ========== 数据看板紧凑化覆写层 ==========
   目标：减少看板纵向高度、消除空列、收紧卡片/图表间距，让首屏更紧凑
===================================================== */

/* 看板页头（视图切换所在行）：压缩底部间距 */
.dashboard .page-header, .page-header { margin-bottom: 14px; }
.page-header h2 { font-size: 19px; }

/* 统计卡行：减少行间距 */
.stats-row { gap: 12px; margin-bottom: 14px; }

/* 看板统计卡（用 stat-value 的卡片）：更紧凑 */
.stat-card { padding: 12px 10px; border-radius: 12px; }
.stat-card .stat-value { font-size: 23px; line-height: 1.15; }
.stat-card .stat-label { font-size: 11.5px; margin-top: 2px; letter-spacing: 0.2px; }

/* 图表区：整体压缩高度与间距 */
.chart-container { gap: 12px; margin-bottom: 14px; }
.chart-card { padding: 14px 16px; }
.chart-card h3 { font-size: 14px; margin-bottom: 10px; }
.chart-wrapper { height: 200px; }
/* 看板内联 grid 的图表行（图表行2/3） */
.chart-card .chart-wrapper { height: 200px; }

/* 图表行2/3 的通用 grid 间距（template 内联 margin-bottom:24px -> 用更高优先级覆盖） */
div[style*="grid-template-columns:1fr 1fr"] { gap: 12px; margin-bottom: 14px !important; }

/* 库存预警明细表：收紧 */
.card-header .card-title { font-size: 14px; }
.data-table td, .data-table th { padding: 8px 12px; }

/* 客户看板（CustomerDashboardTab）：统计卡紧凑 + 新建报修按钮收紧 */
.stat-card .stat-num { font-size: 26px; }
.stat-card .stat-icon { transform: scale(0.9); }

/* ========== 数据看板·科技渐变风格覆写层 ==========
   统计卡与图表卡片统一为玻璃渐变质感，紧凑网格布局，信息密度更高
===================================================== */
.dash-page {
    --dash-ico-total: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M3 13h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm4 4h14v-2H7v2zm0 4h14v-2H7v2zM7 7v2h14V7H7z'/></svg>");
    --dash-ico-progress: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M13 3a9 9 0 1 0 8.94 10H19.9A7 7 0 1 1 13 5v4l5-4.5L13 0v3z'/></svg>");
    --dash-ico-done: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/></svg>");
    --dash-ico-paid: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1.41 16.09V20h-2v-1.83c-.88-.2-1.71-.63-2.36-1.3l1.42-1.42c.7.67 1.83 1 2.94 1 .93 0 1.59-.45 1.59-1.3 0-.86-.5-1.2-1.59-1.7-1.3-.6-2.59-1.29-2.59-3.2 0-1.69 1.32-2.84 3-3.06V5h2v1.82c.78.15 1.48.5 2.06 1.1l-1.42 1.42c-.55-.56-1.39-.85-2.24-.85-.94 0-1.4.44-1.4.91 0 .82.63 1.16 1.88 1.75 1.43.65 2.62 1.44 2.62 3.28 0 1.66-1.2 2.9-3 3.16z'/></svg>");
    --dash-ico-unpaid: var(--dash-ico-paid);
    --dash-ico-stock: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M22 9V7h-2V5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-2h2v-2h-2v-2h2v-2h-2V9h2zM6 20H4V5h14v14H6zm8-13v5l-2-2-2 2V7H8v7h8V7h-2z'/></svg>");
    --dash-ico-in: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M9 3V5H5v14h4v2H3V3h6zm3 8V7l-5 5 5 5v-4h8v-2H12z'/></svg>");
    --dash-ico-out: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M3 3h18v2H3V3zm9 5v8l-4-4 4 4 4-4-4 4V8h-2z'/></svg>");
    --dash-ico-pending: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2z'/></svg>");
    /* 经销商看板专用图标 */
    --dash-ico-customer: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z'/></svg>");
    --dash-ico-device: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M17 1H7c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zM7 5h10v14H7V5zm5 15c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z'/></svg>");
    --dash-ico-bind: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'><path d='M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z'/></svg>");
}
/* KPI 网格：紧凑自适应 */
.dash-page .dash-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}
/* KPI 卡片：玻璃渐变质感 */
.dash-page .dash-kpi {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 14px;
    border-radius: 14px;
    border: 1px solid rgba(120,140,200,0.18);
    background: linear-gradient(145deg, rgba(255,255,255,0.92) 0%, rgba(240,246,255,0.85) 100%);
    box-shadow: 0 2px 8px rgba(60,90,160,0.08), inset 0 1px 0 rgba(255,255,255,0.7);
    transition: transform .18s ease, box-shadow .18s ease;
    overflow: hidden;
}
.dash-page .dash-kpi::before {
    content: '';
    position: absolute;
    top: -40%; left: -20%;
    width: 70%; height: 160%;
    background: radial-gradient(circle at 30% 30%, rgba(120,170,255,0.18), transparent 60%);
    pointer-events: none;
}
.dash-page .dash-kpi:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(60,90,160,0.16); }
/* 深色主题适配：玻璃渐变卡片 */
body[data-theme="dark"] .dash-page .dash-kpi,
.theme-dark .dash-page .dash-kpi {
    background: linear-gradient(145deg, rgba(30,36,52,0.92) 0%, rgba(22,28,44,0.88) 100%);
    border-color: rgba(120,140,200,0.25);
    box-shadow: 0 2px 8px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.06);
}
/* KPI 图标：渐变色圆底 + mask 图形 */
.dash-page .dash-kpi-icon {
    width: 40px; height: 40px;
    border-radius: 11px;
    flex-shrink: 0;
    display: inline-block;
    box-shadow: 0 3px 8px rgba(0,0,0,0.12);
    -webkit-mask-size: 22px; mask-size: 22px;
    -webkit-mask-position: center; mask-position: center;
    -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
/* KPI 数值与标签 */
.dash-page .dash-kpi-value {
    font-size: 22px; font-weight: 700; line-height: 1.1;
    color: var(--text-color);
}
.dash-page .dash-kpi-label {
    font-size: 12px; color: var(--text-muted); margin-top: 2px;
}

/* ===== 经销商数据看板：欢迎语 + 顶部 tab 切换 ===== */
.dealer-welcome { display:flex; justify-content:space-between; align-items:flex-end; margin-bottom:14px; gap:12px; flex-wrap:wrap; }
.dealer-welcome-title { font-size:20px; font-weight:700; color:var(--text-color); letter-spacing:.5px; }
.dealer-welcome-sub { font-size:12.5px; color:var(--text-muted); margin-top:4px; }
.dealer-tabs { display:flex; gap:8px; margin-bottom:16px; flex-wrap:wrap; }
.dealer-tab {
    padding:8px 18px; border:1px solid var(--border-color); background:var(--card-bg);
    border-radius:10px; font-size:13px; cursor:pointer; color:var(--text-secondary);
    transition:all .18s ease; font-weight:500; line-height:1.4;
}
.dealer-tab:hover { border-color:var(--primary-color); color:var(--primary-color); }
.dealer-tab.active {
    background:linear-gradient(135deg,var(--primary-color),var(--primary-dark,#1565c0));
    color:#fff; border-color:transparent; box-shadow:0 4px 12px rgba(24,144,255,.25);
}
.dealer-dash .card-header { display:flex; align-items:center; }
.dealer-dash .quick-actions .btn { min-width:116px; }
/* 图表卡片：玻璃渐变质感 + 改小高度 */
.dash-page .chart-card {
    border-radius: 14px;
    border: 1px solid rgba(120,140,200,0.16);
    background: linear-gradient(145deg, rgba(255,255,255,0.94) 0%, rgba(243,247,255,0.88) 100%);
    box-shadow: 0 2px 8px rgba(60,90,160,0.07);
    padding: 14px 16px;
}
body[data-theme="dark"] .dash-page .chart-card,
.theme-dark .dash-page .chart-card {
    background: linear-gradient(145deg, rgba(30,36,52,0.94) 0%, rgba(22,28,44,0.9) 100%);
    border-color: rgba(120,140,200,0.22);
}
.dash-page .chart-card h3 { font-size: 13.5px; margin-bottom: 8px; }
.dash-page .chart-card .chart-wrapper,
.dash-page .chart-card canvas { height: 168px !important; }
/* 看板内饼图容器固定高度，保证紧凑 */
.dash-page [ref="pieChart"], .dash-page [ref="payChart"], .dash-page [ref="deviceChart"] { height: 168px !important; }
/* 排行表：紧凑 */
.dash-page .chart-card .data-table th, .dash-page .chart-card .data-table td { padding: 7px 10px; font-size: 12.5px; }
.dash-page .chart-card .table-wrapper { margin-top: 6px; }
/* 图表行容器间距收紧 */
.dash-page div[style*="grid-template-columns:1fr 1fr"] { gap: 12px; margin-bottom: 14px !important; }
.dash-page .chart-container { gap: 12px; margin-bottom: 14px; }
/* 折叠的库存预警明细：同样玻璃质感 */
.dash-page .card { box-shadow: 0 2px 8px rgba(60,90,160,0.07); }

/* ========== 统一加载界面覆写层 ==========
   刷新/等待数据时，将各页面零散的 loading 骨架统一为专业加载界面
   （渐变 Logo + 旋转加载环 + 系统名 + 提示），替代空白+小转圈
===================================================== */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 60px 20px !important;
    color: var(--text-muted);
}
/* 渐变加载环 */
.loading-spinner {
    width: 44px !important;
    height: 44px !important;
    border-width: 3px !important;
    border-style: solid;
    border-color: var(--border-color) !important;
    border-top-color: var(--primary-color) !important;
    border-right-color: var(--primary-color) !important;
    border-radius: 50% !important;
    animation: cxt-rotate 0.9s linear infinite;
}
@keyframes cxt-rotate { to { transform: rotate(360deg); } }
/* 统一的加载提示文字（若页面已有文字则叠加/紧随） */
.loading::after {
    content: '正在加载，请稍候…';
    font-size: 13px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}
.loading .loading-spinner + *:not(.loading-spinner) { margin-top: 2px; }

/* ===== 初始全屏加载页（刷新瞬间、Vue 未挂载时兜底）===== */
#app-loading {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    background: var(--bg-color, #f6f8fb);
}
#app-loading .al-logo {
    width: 64px; height: 64px;
    border-radius: 18px;
    background: linear-gradient(135deg, #2196f3, #1565c0);
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 24px; font-weight: 700;
    box-shadow: 0 8px 24px rgba(33,150,243,0.35);
}
#app-loading .al-title { font-size: 17px; font-weight: 600; color: var(--text-color, #333); }
#app-loading .al-sub { font-size: 13px; color: var(--text-muted, #999); }
#app-loading .al-ring {
    width: 34px; height: 34px;
    border: 3px solid rgba(120,140,200,0.2);
    border-top-color: var(--primary-color, #2196f3);
    border-radius: 50%;
    animation: cxt-rotate 0.9s linear infinite;
}

/* ========== 侧边栏高级化覆写层 ==========
   将侧边栏从"单轴渐变"升级为"深色玻璃质感 + 光晕层次 + 精致菜单态"
===================================================== */
.sidebar {
    /* 玻璃质感背景：基础渐变 + 顶部/径向光晕制造层次 */
    background:
        radial-gradient(120% 60% at 50% 0%, rgba(255,255,255,0.09) 0%, transparent 55%),
        radial-gradient(80% 50% at 100% 100%, rgba(255,255,255,0.05) 0%, transparent 55%),
        linear-gradient(180deg, var(--sidebar-bg-start) 0%, var(--sidebar-bg-end) 100%);
    border-right: 1px solid rgba(255,255,255,0.06);
}
/* 高级化侧边栏系统 Logo */
.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    flex-shrink: 0;
}
.sidebar-logo .logo-badge {
    width: 34px; height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(255,255,255,0.65));
    color: var(--sidebar-bg-start);
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    flex-shrink: 0;
}
.sidebar-logo .logo-name {
    color: var(--sidebar-text);
    font-size: 15px; font-weight: 700; letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden; text-overflow: ellipsis;
}
.sidebar.collapsed .sidebar-logo { justify-content: center; padding: 12px 0; }
.sidebar.collapsed .sidebar-logo .logo-name { display: none; }

/* 头部（用户区）：更精致的圆角面板感 */
.sidebar-header {
    margin: 10px 12px 4px;
    padding: 14px 10px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.05);
    border-bottom: none;
}
.sidebar-header:hover { background: rgba(255,255,255,0.1); }
.sidebar-avatar {
    border: 2px solid rgba(255,255,255,0.35);
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}
/* 菜单项：更细腻的 hover 与激活态 */
.sidebar-menu a {
    margin: 2px 12px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 13.5px;
    position: relative;
    transition: all 0.2s ease;
}
.sidebar-menu a svg {
    transition: transform 0.2s ease;
}
.sidebar-menu a:hover {
    background: var(--sidebar-hover-bg);
    transform: translateX(2px);
}
.sidebar-menu a:hover svg { transform: scale(1.12); }
/* 激活态：渐变高亮块 + 左侧指示条 + 图标微光 */
.sidebar-menu a.router-link-active {
    background: linear-gradient(135deg, rgba(255,255,255,0.16) 0%, rgba(255,255,255,0.08) 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 2px 10px rgba(0,0,0,0.12);
    font-weight: 600;
    color: var(--sidebar-text-active);
}
.sidebar-menu a.router-link-active::before {
    content: '';
    position: absolute;
    left: -12px; top: 50%; transform: translateY(-50%);
    width: 4px; height: 55%;
    background: linear-gradient(180deg, #fff, rgba(255,255,255,0.4));
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 10px rgba(255,255,255,0.5);
}
.sidebar-menu a.router-link-active svg { filter: drop-shadow(0 0 4px rgba(255,255,255,0.5)); }
/* 折叠态激活：圆形高亮 */
.sidebar.collapsed .sidebar-menu a.router-link-active {
    border-radius: 12px;
}
/* 分隔线：更柔和 */
.sidebar-divider {
    margin: 8px 18px;
    border-top: 1px solid rgba(255,255,255,0.07);
}
/* 隐藏侧边栏滚动条，保持整洁 */
.sidebar-menu::-webkit-scrollbar { width: 0; height: 0; }
.sidebar-menu { scrollbar-width: none; }
/* 底部折叠/退出按钮：与菜单一致圆角 */
.sidebar-menu > a { border-radius: 10px; }

/* ========== 表格表头对比度修复覆写层 ==========
   修复深色主题下表头背景硬编码为浅色导致与文字对比度不足的问题；
   统一表头为"主题背景 + 高对比文字"，深浅主题均清晰
===================================================== */
/* 全局：表头背景改用主题变量，文字用主文字色（浅色主题=浅底深字） */
.data-table th,
.table th,
th {
  background: var(--card-bg, #ffffff);
  color: var(--text-color, #1a1a2e);
  border-bottom: 1px solid var(--border-color, #e0e6ef);
}
/* 深色主题：表头用更亮的深色底 + 高对比浅色文字，与正文区区分 */
[data-theme=dark] .data-table th,
[data-theme=dark] .table th,
[data-theme=dark] th {
  background: #262c46;
  color: #eef1f7;
  border-bottom: 1px solid #3a415f;
}
/* 深色主题下系统默认的 system 深色（prefers-color-scheme:dark）也一并修复 */
@media (prefers-color-scheme: dark) {
  [data-theme=system] .data-table th,
  [data-theme=system] .table th,
  [data-theme=system] th {
    background: #262c46;
    color: #eef1f7;
    border-bottom: 1px solid #3a415f;
  }
}
/* 深色主题表头文字加粗、加字距，强化可读性 */
[data-theme=dark] .data-table th,
[data-theme=dark] .table th {
  font-weight: 600;
  letter-spacing: 0.3px;
}
/* 深色主题表格正文文字对比微调（secondary 在深色下偏暗） */
[data-theme=dark] .data-table td { color: #c3cad9; }
@media (prefers-color-scheme: dark) {
  [data-theme=system] .data-table td { color: #c3cad9; }
}

/* ========== 全局自适应：小屏自动缩放字体 + 防换行横向滚动 (v2692) ========== */
/* 基准字号随视口自动缩放：屏越窄字越小，避免内容被压到下一行。clamp 保证不超 16px、不小于 12.5px */
html { font-size: clamp(12.5px, 0.45vw + 11px, 16px); }

/* 通用：按钮/标签/徽章/表单控件 不换行，防止被挤断 */
.btn, .btn-sm, .btn-primary, .btn-outline, .btn-danger, .btn-success, .btn-danger-outline,
.tag, .badge, .status-badge, .nav-pills a, .erp-tabs .tab-btn, .filter-bar select, .filter-bar input,
.search-bar input, .form-group input, .form-group select, .page-tabs button {
  white-space: nowrap;
}

/* 让所有滚动容器在小屏可横向滚动，而非压缩内容换行 */
.content, .card, .modal-body, .detail-panel {
  -webkit-overflow-scrolling: touch;
}

/* ---- 表格：强制按内容撑开 + 单元格不换行 => 超出横向滚动而非换行 ---- */
.table-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.table-wrapper table {
  width: 100%;
  min-width: max-content;
  table-layout: auto;
}
.table-wrapper th,
.table-wrapper td,
.data-table th,
.data-table td {
  white-space: nowrap !important;
  vertical-align: middle;
}
.table-wrapper thead {
  position: sticky;
  top: 0;
  z-index: 2;
}
.table-wrapper thead th {
  background: var(--card-bg, #fff);
  box-shadow: inset 0 -1px 0 var(--border-color, #e8e8e8);
}
/* 表格区域固定高度滚动，底部操作栏始终可见 */
.table-wrapper-scroll {
  max-height: calc(100vh - 240px);
  overflow-y: auto;
}

/* 状态标签/操作按钮 强制单行 */
.status-tag,
.status-pending,
.status-progress,
.status-done,
.action-btns,
.action-btns .btn {
  white-space: nowrap !important;
  flex-wrap: nowrap !important;
}

/* 保证工单号这类长文本不在 td 内折行 */
.table-wrapper td > strong,
.table-wrapper td > span {
  white-space: nowrap !important;
}

/* ---- 卡片网格 / KPI：列数随屏自适应，避免挤压换行 ---- */
@media (max-width: 1100px) {
  .stats-row { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
}
@media (max-width: 768px) {
  .stats-row { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
}

/* ===== 通讯密钥管理（卡片式） ===== */
.ak-toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ak-batch { flex: 1; min-width: 200px; padding: 8px 12px; border: 1px solid var(--border-color, #e3e6ef); border-radius: var(--radius-sm, 8px); background: var(--input-bg, #fff); font-size: 13px; }
.ak-tip { font-size: 12px; color: var(--text-muted); margin: 12px 0 14px; line-height: 1.6; }
.ak-tip code { background: var(--bg-muted, #f2f4f8); padding: 1px 6px; border-radius: 4px; font-size: 11px; }
.ak-stats { display: flex; gap: 10px; margin-bottom: 14px; }
.ak-stat { font-size: 12px; color: var(--text-muted); background: var(--bg-muted, #f2f4f8); padding: 5px 12px; border-radius: 20px; }
.ak-stat b { color: var(--text-color); }
.ak-stat.ak-used b { color: #52c41a; }
.ak-stat.ak-free b { color: #fa8c16; }
.ak-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; max-height: 56vh; overflow-y: auto; padding-right: 4px; }
.ak-card { border: 1px solid var(--border-color, #e8e8e8); border-radius: 12px; padding: 14px 16px; background: var(--card-bg, #fff); transition: box-shadow .2s, transform .2s, border-color .2s; position: relative; }
.ak-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(16,24,40,0.08); }
.ak-card.is-used { border-left: 3px solid #52c41a; }
.ak-card.is-free { border-left: 3px solid #fa8c16; }
.ak-card-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.ak-card-actions { display: flex; gap: 6px; }
.ak-del { border: 1px solid #ffccc7; background: #fff1f0; color: #cf1322; font-size: 12px; padding: 4px 12px; border-radius: 6px; cursor: pointer; transition: background .15s; }
.ak-del:hover { background: #ffccc7; }
.ak-badge { font-size: 11px; font-weight: 600; padding: 2px 10px; border-radius: 20px; }
.badge-used { background: rgba(82,196,26,0.12); color: #389e0d; }
.badge-free { background: rgba(250,140,22,0.12); color: #d46b08; }
.ak-copy { border: 1px solid var(--border-color, #e3e6ef); background: var(--bg-muted, #f7f9fc); color: var(--primary-dark, #096dd9); font-size: 12px; padding: 4px 12px; border-radius: 6px; cursor: pointer; transition: background .15s; }
.ak-copy:hover { background: var(--primary-lightest, #e6f4ff); }
.ak-key { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; letter-spacing: .5px; color: var(--text-color); background: var(--bg-muted, #f7f9fc); padding: 9px 12px; border-radius: 8px; word-break: break-all; line-height: 1.5; user-select: all; }
.ak-meta { margin-top: 10px; font-size: 11.5px; color: var(--text-muted); display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.ak-time { margin-left: auto; }
.ak-empty { grid-column: 1 / -1; text-align: center; padding: 40px 0; color: var(--text-muted); }
.ak-empty-icon { font-size: 36px; margin-bottom: 8px; opacity: .6; }

/* ===== OTA 升级弹窗：通信单元 / 控制单元 选择 ===== */
.ota-target { margin-bottom: 14px; }
.ota-target-label { display: block; font-size: 12px; color: var(--text-muted); margin-bottom: 6px; }
.ota-target-btns { display: flex; gap: 8px; }

/* ===== 固件发布管理：上传栏 / 类型标签 ===== */
.fw-upload-bar { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 14px; padding: 12px; background: var(--hover, #f7f9fc); border-radius: 8px; overflow-x: auto; }
.fw-upload-bar label { font-size: 12px; color: var(--text-muted); }
.fw-upload-bar input, .fw-upload-bar select { padding: 8px 10px; border: 1px solid var(--border, #e3e6ef); border-radius: 6px; background: var(--input-bg, #fff); font-size: 13px; box-sizing: border-box; min-width: 0; }
.fw-upload-bar .form-group { min-width: 140px; }
.fw-upload-bar > button { flex-shrink: 0; }
.fw-type-tag { display: inline-block; font-size: 11px; font-weight: 600; padding: 2px 10px; border-radius: 20px; }
.fw-esp32 { background: rgba(9, 109, 217, 0.12); color: #096dd9; }
.fw-mcu { background: rgba(250, 140, 22, 0.12); color: #d46b08; }

/* ===== 远程调试：分组独立控制 / 次数输入 ===== */
.dbg-group { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border, #e8e8e8); border-radius: 8px; padding: 4px 8px; background: var(--bg-muted, #f7f9fc); }
.dbg-label { font-size: 11px; color: var(--text-muted); white-space: nowrap; }
.dbg-count { width: 44px; text-align: center; padding: 4px 2px; border: 1px solid var(--border, #d9d9d9); border-radius: 4px; font-size: 12px; background: var(--input-bg, #fff); }

/* 远程调试宽屏弹窗：通道控制并排 */
.debug-modal .modal-body { max-height: 82vh; }
.debug-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(480px, 1fr)); gap: 12px; }
.debug-slot-card { border: 1px solid var(--border, #e8e8e8); border-radius: 8px; padding: 10px 12px; background: var(--card-bg, #fff); }

/* ===== 远程调试：按通道动态 IO 网格（指示灯/继电器/蜂鸣器/查找） ===== */
.io-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.io-card { border: 1px solid var(--border, #e8e8e8); border-radius: 10px; padding: 10px 12px; background: var(--card-bg, #fff); }
.io-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-size: 13px; }
.io-card-path { font-size: 11px; color: var(--text-muted); max-width: 60%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.io-row { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-top: 1px dashed var(--border, #f0f0f0); }
.io-row:first-of-type { border-top: none; }
.io-label { width: 64px; font-size: 12px; color: var(--text-muted); flex-shrink: 0; }
.io-state { font-size: 12px; font-weight: 600; min-width: 42px; }
.io-state.on { color: #52c41a; }
.io-state.off { color: #bfbfbf; }
.io-btn { min-width: 64px; }

@media (max-width: 576px) {
  .stats-row { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
}

/* 商品/备件卡片网格（ErpPage 内联改类后生效）：小屏减小最小列宽，避免横向溢出 */
.erp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

/* ===== 商品卡片（备件仓库）整体美化 ===== */
.product-card {
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: transform .18s, box-shadow .18s, border-color .18s;
  margin: 0;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
/* 模糊搜索 combobox（销售单/采购单/工单明细选择商品、仓库等） */
.combobox-list {
  position: absolute;
  left: 0; right: 0;
  top: 100%;
  margin-top: 2px;
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  max-height: 240px;
  overflow-y: auto;
  z-index: 100;
  text-align: left;
}
.combobox-item {
  padding: 7px 10px;
  cursor: pointer;
  font-size: 13px;
  border-bottom: 1px solid #f5f5f5;
}
.combobox-item:last-child { border-bottom: none; }
.combobox-item:hover { background: var(--primary-bg-color); color: var(--primary-color); }
.combobox-item.muted { color: #999; }
.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.10);
  border-color: var(--primary-color);
}
.pc-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
}
.pc-thumb {
  width: 100%;
  height: 130px;            /* 固定图片区高度，所有卡片对齐（原 1:1 方形过大） */
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--primary-lightest, #f6f8fa) 0%, var(--primary-lighter, #eef1f5) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  position: relative;
}
.pc-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  transition: opacity .25s;
}
.pc-img.loaded { opacity: 1; }
.pc-thumb-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary-bg-color) 0%, var(--primary-lightest) 100%);
}
.pc-thumb-initial {
  font-size: 36px;
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: -1px;
  opacity: .85;
}
.pc-info {
  flex: 1;
  min-width: 0;
  height: 90px;              /* 固定信息区高度，所有卡片对齐（防标签/规格换行撑高） */
  min-height: 90px;
  overflow: hidden;            /* 内容超出截断 */
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.pc-name {
  font-weight: 600;
  font-size: 13px;
  color: var(--text-color);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.3;
}
.pc-tags {
display: flex;
flex-wrap: wrap;
gap: 4px;
font-size: 11px;
}
.pc-tag {
padding: 1px 7px;
background: #f5f5f5;
color: var(--text-secondary);
border-radius: 10px;
font-size: 11px;
white-space: nowrap;
}
.pc-tag-no { background: var(--primary-lightest, #f0f5ff); color: var(--primary-color); }
.pc-tag-brand { background: var(--warning-light, #fff7e6); color: var(--warning-color); }
.pc-spec {
font-size: 11px;
color: var(--text-muted);
line-height: 1.4;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.pc-spec-sep { color: var(--border-color); }
.pc-stock {
  margin-top: 2px;
  padding: 5px 8px;
  height: 44px;                /* 固定库存区高度（容纳头部+一行仓库），所有卡片严格对齐 */
  flex-shrink: 0;
  box-sizing: border-box;
  overflow: hidden;             /* 防止多仓库换行撑高卡片 */
  background: var(--success-light, #f6ffed);
  border-radius: 6px;
  border: 1px solid color-mix(in srgb, var(--success-color) 22%, transparent);
  font-size: 10px;
  line-height: 1.4;
  color: var(--success-dark);
}
.pc-stock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}
.pc-stock-label {
  font-size: 10px;
  color: #666;
}
.pc-stock-total {
  font-weight: 700;
  font-size: 13px;
  font-family: "Menlo", "Consolas", monospace;
  letter-spacing: .3px;
}
.pc-stock-list {
  display: flex;
  flex-wrap: nowrap;          /* 单行，长路径不换行（防 height 溢出） */
  overflow-x: auto;           /* 路径长可横向滚动看到完整内容（原 overflow:hidden 直接隐藏） */
  overflow-y: hidden;
  gap: 2px;
  font-size: 10px;
  scrollbar-width: thin;     /* 细滚动条不抢视觉 */
}
.pc-stock-list::-webkit-scrollbar { height: 4px; }
.pc-stock-list::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 2px; }
.pc-stock-item {
  font-size: 10px;
  padding: 0 5px;
  background: var(--bg-color, #fff);
  border: 1px solid var(--success-light);
  border-radius: 8px;
  white-space: nowrap;
  color: var(--success-dark);
  /* 去掉 max-width/overflow:hidden/ellipsis，让完整路径在父 .pc-stock-list overflow-x:auto 中可横滚查看 */
}
.pc-stock-more {
  font-size: 10px;
  color: #999;
  align-self: center;
}
.pc-no-stock {
  margin-top: 2px;
  font-size: 10px;
  color: var(--warning-color);
}
.pc-flags {
display: flex;
gap: 6px;
margin-top: 2px;
}
.pc-flag {
font-size: 10px;
padding: 1px 7px;
border-radius: 10px;
white-space: nowrap;
}
.pc-flag-img {
background: var(--primary-lightest);
border-color: var(--primary-lighter);
color: var(--primary-color);
}
.pc-flag-pdf {
background: var(--warning-light);
border-color: color-mix(in srgb, var(--warning-color) 22%, transparent);
color: var(--warning-color);
}
@media (max-width: 1100px) {
  .erp-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
}
@media (max-width: 768px) {
  .erp-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}
@media (max-width: 480px) {
  .erp-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
}

/* ---- 字号逐级缩小（px 固定值组件）---- */
@media (max-width: 1200px) {
  .page-header h2 { font-size: 20px; }
  .data-table th { font-size: 12px; }
  .data-table td { font-size: 13px; }
  .header { padding: 0 20px; }
  .header-center { font-size: 17px; }
  .header-title { font-size: 16px; }
}
@media (max-width: 992px) {
  .page-header h2 { font-size: 18px; }
  .card-header h3, .card-title { font-size: 15px; }
  .data-table th { font-size: 11.5px; }
  .data-table td { font-size: 12.5px; }
  th, td { font-size: 13px; }
  .btn, .btn-sm { font-size: 12.5px; }
}
@media (max-width: 768px) {
  .content { padding: 14px; }
  .page-header h2 { font-size: 17px; }
  .page-header h3 { font-size: 16px; }
  .data-table th { font-size: 11px; }
  .data-table td { font-size: 12px; padding: 9px 10px; }
  th, td { font-size: 12.5px; padding: 10px 12px; }
  .btn, .btn-sm { font-size: 12px; padding: 6px 12px; }
  .header { padding: 0 14px; }
  .header-center { font-size: 15px; }
  .header-title { font-size: 14px; }
  .card { border-radius: 10px; }
}
@media (max-width: 576px) {
  .content { padding: 10px; }
  .page-header { margin-bottom: 12px; }
  .page-header h2 { font-size: 16px; }
  .data-table th { font-size: 10.5px; padding: 8px 8px; }
  .data-table td { font-size: 11.5px; padding: 8px 8px; }
  th, td { font-size: 12px; padding: 8px 10px; }
  .btn, .btn-sm { font-size: 11.5px; padding: 5px 10px; }
  .header-center { font-size: 13px; }
  .stats-row { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
}
@media (max-width: 420px) {
  .content { padding: 8px; }
  .page-header h2 { font-size: 15px; }
  .data-table td { font-size: 11px; }
  th, td { font-size: 11.5px; padding: 7px 8px; }
  .btn, .btn-sm { font-size: 11px; padding: 5px 9px; }
}

/* 极窄屏：全局兜底缩小，保证不溢出 */
@media (max-width: 360px) {
  html { font-size: 12px; }
  .page-header h2 { font-size: 14px; }
}
/* ===== 设备详情页 ===== */
.tag-orange { background: linear-gradient(135deg, #fff1e6 0%, #ffd8a8 100%); color: #d9480f; border: 1px solid rgba(250,140,20,0.18); }
.tag-green { background: linear-gradient(135deg, #ebfbee 0%, #b2f2bb 100%); color: #2b8a3e; border: 1px solid rgba(82,196,26,0.18); }
.tag-gray { background: #f1f3f5; color: #868e96; border: 1px solid #e9ecef; }
.device-detail-page { max-width: 1400px; margin: 0 auto; padding: 12px; }
.dd-toolbar { display:flex; align-items:center; gap:12px; margin-bottom:12px; }
.dd-toolbar .dd-title { display:flex; flex-direction:column; }
.dd-title .dd-name { font-size:20px; font-weight:700; }
.dd-title .dd-sn { font-size:12px; color:var(--text-muted); font-family:monospace; }
.dd-sub { font-size:12px; color:var(--text-muted); margin-left:auto; }
.dd-empty { text-align:center; padding:40px; color:var(--text-muted); }
.dd-card { background:#fff; border:1px solid var(--border-color); border-radius:10px; padding:14px; margin-bottom:12px; box-shadow:0 1px 2px rgba(0,0,0,.04); }
.dd-card-h { font-size:15px; font-weight:700; margin-bottom:10px; padding-bottom:8px; border-bottom:1px solid var(--border-color); display:flex; align-items:center; gap:8px; }
.dd-fee-tip { font-size:12px; color:var(--text-muted); font-weight:400; }
.dd-top-row { display:flex; gap:16px; align-items:flex-start; }
.dd-info-grid { flex:1; min-width:0; display:grid; grid-template-columns:repeat(3,1fr); gap:8px 18px; }
.dd-info-item { display:flex; flex-direction:column; font-size:13px; }
.dd-info-item .lbl { color:var(--text-muted); font-size:11.5px; margin-bottom:1px; }
.dd-info-item .val { font-weight:600; }
.dd-info-item .val.mono, .dd-sn, .mono { font-family:monospace; }
.dd-qr-block { flex-shrink:0; width:160px; padding:12px; background:var(--bg-color); border-radius:10px; text-align:center; }
.dd-qr-block img { width:120px; height:120px; border:1px solid var(--border-color); border-radius:8px; }
.dd-qr-title { font-size:12px; color:var(--text-muted); margin-bottom:6px; }
.dd-muted { color:var(--text-muted); font-size:13px; }
.dd-img-section { display:flex; gap:16px; flex-wrap:wrap; }
.dd-img-col { flex:1; min-width:220px; }
.dd-img-label { font-size:13px; font-weight:600; margin-bottom:6px; }
.dd-img-grid { display:flex; gap:8px; flex-wrap:wrap; }
.dd-img-thumb { position:relative; width:90px; height:90px; border:1px solid var(--border-color); border-radius:8px; overflow:hidden; }
.dd-img-thumb img { width:100%; height:100%; object-fit:cover; cursor:pointer; display:block; }
.dd-img-replace { cursor:pointer; }
.dd-img-replace:hover img { opacity:.75; }
.dd-img-replace-hint { position:absolute; left:0; right:0; bottom:0; background:rgba(0,0,0,.55); color:#fff; font-size:11px; text-align:center; line-height:20px; opacity:0; transition:opacity .15s; pointer-events:none; }
.dd-img-replace:hover .dd-img-replace-hint { opacity:1; }
.dd-img-add { width:90px; height:90px; border:1px dashed #ced4da; border-radius:8px; display:flex; align-items:center; justify-content:center; cursor:pointer; color:#adb5bd; font-size:26px; }
.dd-img-add:hover { border-color:var(--primary-color); color:var(--primary-color); }
.dd-nameplate-col { flex:0 0 260px; max-width:260px; }
.dd-nameplate-box { position:relative; width:100%; height:150px; border:1px dashed #ced4da; border-radius:8px; display:flex; align-items:center; justify-content:center; background:var(--bg-color); overflow:hidden; }
.dd-nameplate-img-label { position:relative; width:100%; height:100%; display:flex; align-items:center; justify-content:center; cursor:pointer; }
.dd-nameplate-img-label:hover .dd-nameplate-img { opacity:.75; }
.dd-nameplate-img { width:100%; height:100%; object-fit:contain; cursor:pointer; background:#fff; display:block; }
.dd-nameplate-hint { position:absolute; left:0; right:0; bottom:0; background:rgba(0,0,0,.55); color:#fff; font-size:11px; text-align:center; line-height:22px; opacity:0; transition:opacity .15s; pointer-events:none; }
.dd-nameplate-img-label:hover .dd-nameplate-hint { opacity:1; }
.dd-nameplate-empty { cursor:pointer; color:#adb5bd; font-size:13px; }
.dd-nameplate-empty:hover { color:var(--primary-color); }
.dd-chart-card { background:var(--bg-color); border-radius:10px; padding:12px; margin:4px 0 12px; }
.dd-chart-title { font-size:13px; font-weight:600; margin-bottom:8px; }
.chart-wrapper { position:relative; }
.dd-mini-table, .dd-table { width:100%; border-collapse:collapse; font-size:12.5px; }
.dd-mini-table th, .dd-table th { text-align:left; color:var(--text-muted); font-weight:600; padding:6px 8px; border-bottom:2px solid var(--border-color); }
.dd-mini-table td, .dd-table td { padding:6px 8px; border-bottom:1px solid var(--border-color); vertical-align:top; }
.dd-table td.mono { font-family:monospace; }
.dd-table .dd-desc { max-width:280px; color:var(--text-muted); }
.dd-desc.dd-processing { white-space:pre-line; font-size:12px; line-height:1.5; max-width:420px; min-width:220px; }
.dd-att-list { display:flex; flex-wrap:wrap; gap:8px; }
.dd-att-item { display:flex; align-items:center; }
.dd-thumb { width:48px; height:48px; object-fit:cover; border-radius:6px; border:1px solid var(--border-color); cursor:pointer; }
.dd-mini-table .mono { font-family:monospace; }
.btn-xs { padding:4px 8px; font-size:12px; border-radius:6px; }
.empty { padding:40px 0; text-align:center; color:var(--text-muted); }
.payment-tag { display:inline-block; padding:3px 12px; border-radius:12px; font-size:12px; font-weight:600; line-height:1.6; white-space:nowrap; }
.payment-tag.paid { background:#e6f7ec; color:#1a7f37; border:1px solid #b7e4c7; }
.payment-tag.unpaid { background:#fff4e5; color:#b76e00; border:1px solid #ffd591; }
.payment-tag.empty { background:#f1f3f5; color:#868e96; border:1px solid #dee2e6; }
    .device-code { display:inline-block; max-width:160px; overflow-x:auto; white-space:nowrap; cursor:pointer; font-family:monospace; font-size:13px; color:var(--primary-color); vertical-align:middle; -webkit-user-select:all; user-select:all; }
    .device-code::-webkit-scrollbar { height:4px; }
    .device-code::-webkit-scrollbar-thumb { background:#c1c1c1; border-radius:2px; }
.dd-fee-summary { display:grid; grid-template-columns:repeat(auto-fit, minmax(130px,1fr)); gap:10px; margin-bottom:14px; }
.dd-fee-summary.dd-fee-admin { grid-template-columns:repeat(auto-fit, minmax(120px,1fr)); }
.dd-fee-item { background:var(--bg-color); border-radius:8px; padding:10px 8px; text-align:center; display:flex; flex-direction:column; gap:3px; }
.dd-fee-item .lbl { font-size:11.5px; color:var(--text-muted); }
.dd-fee-item .val { font-size:15px; font-weight:700; }
.dd-fee-total { background:linear-gradient(135deg,#e7f5ff,#bde0fe); }
.dd-fee-total .val { color:var(--primary-dark); }
@media (max-width:900px){ .dd-top-row{flex-direction:column;} .dd-qr-block{width:100%;} .dd-info-grid{grid-template-columns:repeat(2,1fr);} }
@media (max-width:760px){ .dd-info-grid{grid-template-columns:repeat(2,1fr);} .dd-nameplate-col{flex:1; max-width:none;} .dd-fee-summary{grid-template-columns:repeat(2,1fr);} .dd-img-section{flex-direction:column;} }
@media (max-width:480px){ .dd-info-grid{grid-template-columns:1fr;} .dd-fee-summary{grid-template-columns:1fr;} }
/* 顶部快捷出入库确认弹窗：简洁卡片 + 高亮仓库 */
.qb-confirm-modal { width:440px; max-width:95vw; padding:0; border-radius:14px; box-shadow:0 20px 60px rgba(0,0,0,.25); overflow:hidden; outline:none; }
.qb-confirm-head { display:flex; align-items:center; justify-content:space-between; padding:16px 20px; background:linear-gradient(135deg, var(--primary-color), var(--primary-light)); color:#fff; font-weight:600; }
.qb-confirm-title { font-size:16px; letter-spacing:.5px; }
.qb-confirm-timer { font-size:13px; font-weight:500; background:rgba(255,255,255,.22); padding:3px 10px; border-radius:10px; min-width:44px; text-align:center; }
.qb-confirm-body { padding:18px 20px; display:flex; flex-direction:column; gap:12px; }
.qb-confirm-row { display:flex; align-items:center; gap:14px; padding:10px 12px; background:#f7f8fa; border-radius:8px; }
.qb-confirm-label { flex:0 0 76px; color:var(--text-muted); font-size:13px; }
.qb-confirm-val { flex:1; font-size:14px; line-height:1.6; word-break:break-all; }
.qb-confirm-qty { width:90px; height:34px; padding:0 8px; border:1px solid var(--border-color); border-radius:6px; font-size:15px; font-weight:600; text-align:center; outline:none; transition:border-color .15s; }
.qb-confirm-qty:focus { border-color:var(--primary-color); box-shadow:0 0 0 2px rgba(22,119,255,.15); }
.qb-confirm-warehouse { color:var(--primary-color); font-weight:600; max-height:48px; overflow:hidden; text-overflow:ellipsis; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.qb-confirm-stock { padding:10px 14px; background:#fff1f0; border:1px solid #ffccc7; border-radius:8px; color:#cf1322; font-size:13px; }
.qb-confirm-stock.over { background:#fff1f0; border-color:#ff7875; color:#cf1322; animation:qbBlink .8s ease-in-out infinite alternate; }
.qb-confirm-msg { padding:8px 12px; background:#f6ffed; border:1px solid #b7eb8f; border-radius:6px; color:#389e0d; font-size:13px; }
.qb-confirm-msg.err { background:#fff1f0; border-color:#ffccc7; color:#cf1322; }
.qb-confirm-foot { display:flex; justify-content:flex-end; gap:10px; padding:14px 20px 18px; border-top:1px solid var(--border-color); background:#fafbfc; }
@keyframes qbBlink { from { opacity:.85; } to { opacity:1; } }

/* qbConfirm 商品图片+属性+往来对象 */
.qb-confirm-prod { display:flex; gap:14px; align-items:center; padding:10px 12px; background:#fff; border:1px solid var(--border-color); border-radius:8px; }
.qb-confirm-img { flex:0 0 72px; width:72px; height:72px; display:flex; align-items:center; justify-content:center; overflow:hidden; background:#f0f2f5; border-radius:6px; }
.qb-confirm-img-empty { color:var(--text-muted); font-size:12px; }
.qb-confirm-prodinfo { flex:1; min-width:0; }
.qb-confirm-attrs { display:flex; flex-wrap:wrap; gap:6px 10px; padding:8px 12px; background:#f7f8fa; border-radius:8px; font-size:12px; color:var(--text-muted); }
.qb-confirm-attrs span { background:#eef2f7; padding:2px 8px; border-radius:10px; }
.qb-confirm-opts { max-height:120px; overflow:auto; border:1px solid var(--border-color); border-radius:8px; background:#fff; }
.qb-confirm-opt { padding:8px 10px; font-size:13px; cursor:pointer; border-bottom:1px solid #f0f0f0; }
.qb-confirm-opt:hover { background:#f0f6ff; }

/* ===== 智能仓库状态/属性面板 ===== */
.smart-wh-panel { padding:12px 16px; background:linear-gradient(135deg,#f6f9ff,#eef4ff); border-bottom:1px solid var(--border-color); flex-shrink:0; }
.swp-head { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.swp-path { display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; margin: 6px 0 0; padding: 6px 0 0; border-top: 1px dashed rgba(15,23,42,0.06); }
.swp-path-info { display:flex; flex-direction:column; gap:1px; min-width:0; }
.swp-path-metrics { display:flex; gap:18px; align-items:baseline; }
.swp-badge { font-size:12px; padding:2px 10px; border-radius:12px; font-weight:600; }
.swp-title { font-size:15px; font-weight:600; color:var(--text-color); }
.swp-mac { font-size:12px; color:var(--text-muted); margin-left:auto; }
.swp-metrics { display:flex; gap:24px; margin:10px 0 8px; }
.swp-metric { display:inline-flex; align-items:baseline; gap:6px; }
.swp-label { font-size:11px; color:var(--text-muted); }
.swp-val { font-size:18px; font-weight:700; color:var(--primary-color); }
.swp-config { display:flex; flex-wrap:wrap; gap:6px; }
.swp-cfg-item { font-size:12px; padding:3px 10px; border-radius:11px; background:#eef1f5; color:#9aa3af; border:1px solid transparent; }
.swp-cfg-item.on { background:#e6f4ea; color:#135200; border-color:#b7eb8f; }
.swp-controls { display:flex; flex-wrap:wrap; gap:12px; margin-top:10px; padding-top:10px; border-top:1px dashed #d0d7de; }
.swp-state-row { display:flex; align-items:center; gap:8px; font-size:12px; }
.swp-state-row .swp-label { min-width:48px; color:var(--text-muted); }
.swp-state { font-weight:600; min-width:46px; }
.swp-state.on { color:var(--success-dark); }
.swp-state.off { color:var(--text-muted); }
.swp-state-row .btn-xs { padding:2px 8px; font-size:11px; }
