/* ══════════════════════════════════════
   万成假期 V3 — 克制专业风格
   基于 Direction 2 · Stripe Clean
   ══════════════════════════════════════ */

/* ===== 字体自托管（本地，绕开 CSP 外链拦截）===== */
@font-face { font-family:'HarmonyOS Sans SC'; font-style:normal; font-weight:400; font-display:swap; src:url('../fonts/HarmonyOS-Sans-SC-Regular.woff2') format('woff2'); }
@font-face { font-family:'HarmonyOS Sans SC'; font-style:normal; font-weight:500; font-display:swap; src:url('../fonts/HarmonyOS-Sans-SC-Medium.woff2') format('woff2'); }
@font-face { font-family:'HarmonyOS Sans SC'; font-style:normal; font-weight:700; font-display:swap; src:url('../fonts/HarmonyOS-Sans-SC-Bold.woff2') format('woff2'); }
@font-face { font-family:'Archivo'; font-style:normal; font-weight:400; font-display:swap; src:url('../fonts/archivo-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family:'Archivo'; font-style:normal; font-weight:500; font-display:swap; src:url('../fonts/archivo-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family:'Archivo'; font-style:normal; font-weight:600; font-display:swap; src:url('../fonts/archivo-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family:'Archivo'; font-style:normal; font-weight:700; font-display:swap; src:url('../fonts/archivo-latin-700-normal.woff2') format('woff2'); }

/* 字号归一化：<small> 兜底 12px（无显式规则的 small 不再走浏览器 smaller=13.33px） */
small { font-size: 12px; }

:root {
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --success: #1c7c4d;
  --success-light: #e9f5ee;
  --warning: #b45309;
  --warning-light: #fdf3e7;
  --danger: #c0392b;
  --danger-light: #fbeceb;
  --bg: #edf1f4;
  --bg-card: #ffffff;
  --sidebar-bg: #16293c;
  --border: #d7dfe6;
  --border-light: #e5eaef;
  --text: #1a2733;
  --text2: #5b6a7a;
  --text3: #8594a3;
  --white: #ffffff;
  /* Spacing */
  /* Radius */
  --radius: 8px;
  --radius-lg: 10px;
  --radius-sm: 6px;
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.08);
  /* Typography */
  --font-mono: 'SF Mono', 'JetBrains Mono', monospace;
  --transition: 0.15s ease;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
}

/* ===== 布局 ===== */
.app-layout { display: flex; min-height: 100vh; }

/* 侧边栏 — 白色克制 */
.sidebar {
  width: 220px; min-width: 220px;
  background: var(--sidebar-bg);
  border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; height: 100vh;
  z-index: 100; overflow-y: auto;
}
.sidebar-logo,
.sidebar-header {
  padding: 18px 18px 20px; font-size: 16px; font-weight: 700;
  color: #fff; border-bottom: 1px solid var(--border-light);
  display: flex; align-items: center; gap: 10px;
}
.sidebar-logo-img { width: 32px; height: 32px; border-radius: 8px; object-fit: contain; }
.sidebar-header h2 { font-size: 15px; font-weight: 700; line-height: 1.2; color: #fff; }
.sidebar-header span { font-size: 12px; color: rgba(255,255,255,0.62); display: block; font-weight: 400; }
.sidebar-menu,
.nav-menu { flex: 1; padding: 8px 0; }

.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 14px; margin: 0 8px; border-radius: 6px;
  cursor: pointer; transition: all var(--transition);
  color: var(--text2); font-size: 13px; font-weight: 500;
  user-select: none;
}
.nav-icon-dot {
  width: 6px; height: 6px; border-radius: 2px;
  flex-shrink: 0; transition: all var(--transition);
  opacity: 0.5;
}
.nav-item:hover .nav-icon-dot,
.nav-item.active .nav-icon-dot { opacity: 1; }
.nav-dashboard .nav-icon-dot { background: #7fa8d4; border-radius: 50%; }
.nav-tours .nav-icon-dot { background: #7fa8d4; }
.nav-orders .nav-icon-dot { background: #7fa8d4; }
.nav-customers .nav-icon-dot { background: #7fa8d4; border-radius: 50%; }
.nav-resources .nav-icon-dot { background: #7fa8d4; }
.nav-finances .nav-icon-dot { background: #7fa8d4; }
.nav-reports .nav-icon-dot { background: #7fa8d4; border-radius: 50%; }
.nav-operations .nav-icon-dot { background: #7fa8d4; }
.nav-users .nav-icon-dot { background: #7fa8d4; border-radius: 50%; }
.nav-item:hover { background: rgba(31,78,121,0.15); color: #e8f4f8; }
.nav-item.active {
  background: var(--primary-light); color: var(--primary-dark); font-weight: 600;
}
.nav-divider { height: 1px; margin: 6px 20px; background: rgba(255,255,255,0.08); }
/* 二级菜单 */
.nav-arrow {
  margin-left: auto; font-size: 10px; opacity: 0.55;
  transition: transform 0.2s; flex-shrink: 0;
}
.nav-arrow.open { transform: rotate(180deg); }
.nav-children { margin: 2px 0; }
.nav-child {
  padding-left: 36px; font-size: 13px; font-weight: 400;
}
.sidebar-footer { padding: 12px 18px; border-top: 1px solid rgba(255,255,255,0.08); font-size: 12px; color: rgba(255,255,255,0.5); }

.main {
  margin-left: 220px; flex: 1;
  padding: 24px 28px; min-height: 100vh;
}

.topbar {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 20px;
}
.topbar h2 { font-size: 20px; font-weight: 700; letter-spacing: -0.3px; font-weight: 700; color: var(--text); }
.topbar-right { display: flex; align-items: center; gap: 12px; position: relative; }

/* 用户头像下拉 */
.user-dropdown {
  display: flex; align-items: center; gap: 10px; padding: 6px 12px 6px 6px;
  border-radius: 30px; cursor: pointer; transition: all 0.2s;
  background: #f3f4f6; border: 2px solid transparent;
}
.user-dropdown:hover { background: #d7dfe6; border-color: var(--primary-light); }
.user-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; flex-shrink: 0;
}
.user-meta { display: flex; flex-direction: column; line-height: 1.2; }
.user-display { font-size: 13px; font-weight: 600; color: var(--text); }
.user-role { font-size: 11px; color: var(--text3); }
.user-arrow { font-size: 10px; color: var(--text3); margin-left: 2px; transition: transform 0.2s; }
.user-dropdown:hover .user-arrow { transform: rotate(180deg); }

.user-menu-popper {
  position: absolute; top: 48px; right: 0; min-width: 140px;
  background: #fff; border-radius: 12px; box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  border: 1px solid #d7dfe6; overflow: hidden; z-index: 500; animation: menuIn 0.15s ease;
}
@keyframes menuIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }
.user-menu-item {
  padding: 10px 16px; font-size: 13px; cursor: pointer; display: flex; align-items: center; gap: 8px;
  color: #33414f; transition: background 0.15s;
}
.user-menu-item:hover { background: #f3f4f6; color: var(--danger); }

/* ===== 卡片 ===== */
.card { background: var(--bg-card); border-radius: var(--radius-lg); box-shadow: var(--shadow); margin-bottom: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}
.card:hover { box-shadow: var(--shadow-lg); }
.card-header { background: #fafbfc;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.card-header h3 { font-size: 15px; font-weight: 700; color: var(--text); letter-spacing: -0.2px; }
.card-body { padding: 20px; overflow-x: auto; min-width: 0; }

/* ===== 表格 ===== */
table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14px; }
thead { position: sticky; top: 0; z-index: 5; background: #f8fafb; border-bottom: 1px solid var(--border); }
th { font-size: 13px; font-weight: 600; color: var(--text2);
  padding: 11px 14px; text-align: left;
  border-bottom: 2px solid var(--primary-light);
  background: var(--bg); white-space: nowrap;
}
td { border-bottom: 1px solid var(--border-light);
  padding: 11px 14px;
  color: var(--text);
  font-size: 14px; line-height: 1.6;
}
tr:hover td { border-bottom: 1px solid var(--border-light); background: var(--primary-light); }
/* 金额列右对齐 + 等宽数字 */
td.money-pos, td.money-neg, th.r, td.r {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-family: -apple-system, 'SF Mono', 'JetBrains Mono', monospace;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 16px; border-radius: var(--radius);
  min-height: 34px; line-height: 1.4; vertical-align: middle;
  border: 1px solid var(--border); cursor: pointer;
  font-size: 13px; font-weight: 500;
  background: var(--white); color: var(--text);
  transition: all var(--transition);
  white-space: nowrap;
}
.btn:hover { background: var(--bg); border-color: var(--text3); }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--primary); color: #fff; border: none; border-radius: 8px; padding: 8px 16px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all var(--transition);
  background: var(--primary); color: var(--white); border-color: var(--primary);
}
.btn-primary:hover { background: var(--primary-dark); box-shadow: 0 2px 8px rgba(31,78,121,0.3); }
.btn-success { background: var(--success); color: var(--white); border-color: var(--success); }
.btn-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: var(--danger-light); border-color: var(--danger); color: var(--danger); }
.btn-outline { background: transparent; border-color: var(--border); }
.btn-sm { padding: 5px 12px; font-size: 13px; min-height: 28px; gap: 4px; }

/* ===== 标签 ===== */
.tag {
  display: inline-block; padding: 3px 12px; border-radius: 20px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.2px;
  line-height: 1.6;
}
.tag-open { background: var(--primary-light); color: var(--primary); }
.tag-warning { background: var(--warning-light); color: #7a5536; }
.tag-danger { background: var(--danger-light); color: var(--danger); }
.tag-success { background: var(--success-light); color: var(--success); }

/* ===== 筛选栏 ===== */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px;
}
.filter-bar input, .filter-bar select {
  padding: 6px 12px; border: 1px solid var(--border);
  border-radius: var(--radius); font-size: 13px;
  background: var(--white); color: var(--text);
}
.filter-bar input:focus, .filter-bar select:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light);
}
/* 高级筛选折叠 */
.filter-advanced { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.filter-toggle {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; color: var(--text3); cursor: pointer;
  padding: 4px 8px; border-radius: var(--radius); transition: all var(--transition);
  user-select: none; white-space: nowrap;
}
.filter-toggle:hover { color: var(--primary); background: var(--primary-light); }
.filter-toggle::after { content: ' ▾'; font-size: 10px; transition: transform 0.2s; }
.filter-toggle.open::after { transform: rotate(180deg); }
/* 日期输入框美化 */
input[type="date"] {
  appearance: none; -webkit-appearance: none;
  padding-right: 8px; cursor: pointer;
}
input[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0.6; cursor: pointer; transition: opacity 0.2s;
}
input[type="date"]:hover::-webkit-calendar-picker-indicator { opacity: 1; }
input[type="month"] {
  appearance: none; -webkit-appearance: none;
  padding-right: 8px; cursor: pointer;
}

/* ===== 表单 ===== */
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block; font-size: 12px; font-weight: 600;
  color: var(--text2); margin-bottom: 4px;
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 8px 12px;
  border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 13px; color: var(--text); background: var(--white);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
/* 控件统一 34px 高度基线：与 .btn 对齐，输入框与按钮并排时不再错开 */
.form-group input, .form-group select { min-height: 34px; }
.form-group textarea { min-height: 72px; line-height: 1.6; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.req { color: var(--danger); }

/* 表单校验反馈 */
/* 必填标记 */
.form-group label .req { color: var(--danger); margin-left: 2px; }
/* 聚焦增强 */
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light), 0 0 0 1px var(--primary);
  transition: all 0.2s ease;
}
/* 错误状态 — 红色边框 + 抖动动画 */
.form-group input.error, .form-group select.error, .form-group textarea.error,
.form-group input:user-invalid, .form-group select:user-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px var(--danger-light);
  animation: shake 0.4s ease;
}
/* 成功状态 — 绿色对勾 */
.form-group input.success, .form-group select.success {
  border-color: var(--success);
  box-shadow: 0 0 0 3px var(--success-light);
  padding-right: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M13.3 4.3L6 11.6 2.7 8.3' fill='none' stroke='%23059669' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 8px center; background-size: 18px;
}
/* 错误提示文字 */
.form-error {
  font-size: 11px; color: var(--danger); margin-top: 4px;
  display: flex; align-items: center; gap: 4px;
}
.form-error::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--danger); flex-shrink: 0; }
/* 抖动动画 */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-4px); }
  40% { transform: translateX(4px); }
  60% { transform: translateX(-3px); }
  80% { transform: translateX(3px); }
}

/* ===== 骨架屏 ===== */
.skeleton {
  background: linear-gradient(90deg, var(--border) 25%, #e8edee 37%, var(--border) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: 4px;
}
@keyframes shimmer {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}
/* 文本骨架 */
.skeleton-text { height: 14px; margin: 8px 0; width: 100%; }
.skeleton-text.short { width: 60%; }
.skeleton-text.medium { width: 80%; }
/* 标题骨架 */
.skeleton-title { height: 22px; width: 40%; margin-bottom: 16px; }
/* 卡片骨架 */
.skeleton-card {
  height: 100px; border-radius: var(--radius-lg);
  padding: 20px;
}
/* 表格骨架 */
.skeleton-table-row {
  display: flex; gap: 16px; padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}
.skeleton-table-row .skeleton-cell { height: 14px; flex: 1; }
.skeleton-table-row .skeleton-cell:nth-child(2) { flex: 2; }
.skeleton-table-row .skeleton-cell:last-child { flex: 0.5; }
/* 圆形容器骨架 */
.skeleton-circle { width: 40px; height: 40px; border-radius: 50%; }

/* ===== 弹窗 ===== */
.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: #1f4e79;
  background-image: linear-gradient(135deg, #1f4e79 0%, #163a5c 100%);
  background-size: cover; background-position: center;
  position: relative;
}
.login-page::before {
  content: ""; position: absolute; inset: 0;
  background: rgba(10,25,45,0.50); z-index: 0;
}
.login-page > * { position: relative; z-index: 1; }
.login-panel {
  display: flex; flex-direction: row; width: 760px; max-width: 95vw;
  background: rgba(255,255,255,0.92); backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 8px 40px rgba(0,0,0,0.25);
}
.login-brand {
  flex: 0 0 42%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(160deg,#1f4e79 0%,#1a4568 50%,#163a5c 100%);
  padding: 48px 36px; text-align: center; position: relative; overflow: hidden;
}
.login-brand::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 80%,rgba(199,145,92,.15) 0%,transparent 60%);
}
.login-brand > * { position: relative; z-index: 1; }
.login-brand img.login-logo-whale { height: 100px; filter: drop-shadow(0 2px 12px rgba(0,0,0,.25)); margin-bottom: 28px; }
.login-brand h1 { font-size: 32px; font-weight: 700; letter-spacing: 8px; color: #fff; margin: 0 0 12px; }
.login-brand .brand-tagline { font-size: 16px; font-weight: 300; color: rgba(255,255,255,.85); letter-spacing: 4px; margin-bottom: 12px; }
.login-brand > p { font-size: 13px; color: rgba(255,255,255,.55); letter-spacing: 3px; margin: 0; }
.login-tagline { display: none; }
.login-features { display: none; }
.login-brand::after { display: none; }
.login-form-area {
  flex: 1; display: flex; flex-direction: column; justify-content: center;
  padding: 48px 40px;
}
.login-form-area::before { display: none; }
.login-form-title { font-size: 20px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.login-form { margin-top: 16px; }
.login-form .form-group { margin-bottom: 14px; }
.login-form label { font-size: 12px; font-weight: 600; color: var(--text2); margin-bottom: 5px; display: block; }
.login-form input { width: 100%; padding: 10px 13px; font-size: 14px; border: 1.5px solid var(--border); border-radius: 8px; background: #fff; transition: all 0.15s; box-sizing: border-box; }
.login-form input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(31,78,121,0.08); }
.btn-login { width: 100%; padding: 12px; background: var(--primary); color: #fff; border: none; border-radius: 8px; font-size: 15px; font-weight: 700; cursor: pointer; letter-spacing: 4px; transition: all 0.15s; margin-top: 8px; }
.btn-login:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(31,78,121,0.35); }
.btn-login:active { transform: translateY(0); }
.btn-login:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
@media (max-width: 640px) {
  .login-panel { flex-direction: column; }
  .login-brand { flex: 0 0 auto; padding: 36px 24px; }
  .login-brand img.login-logo-whale { height: 72px; }
  .login-brand h1 { font-size: 24px; letter-spacing: 6px; }
  .login-brand .brand-tagline { font-size: 15px; }
  .login-form-area { padding: 32px 24px; }
}

/* Final cascade lock: brand UI */
:root {
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --warning: #b45309;
  --warning-light: #fdf6ee;
  --bg: #f5f8f9;
  --bg-card: #ffffff;
  --border: #dce6e8;
  --border-light: #edf3f4;
  --text: #102326;
  --text2: #4c6269;
  --text3: #7c8f96;
}

body,
button,
input,
select,
textarea {
  font-family: var(--font-sans);
  letter-spacing: 0;
}

body {
  background: linear-gradient(180deg, #fbfdfd 0%, #f5f8f9 260px), #f5f8f9;
  color: var(--text);
}

.sidebar {
  background: #16293c;
  border-right-color: rgba(255,255,255,0.1);
}

.nav-item {
  color: rgba(255,255,255,0.7);
  border-radius: 7px;
}

.nav-item:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.nav-item.active {
  background: #e8eef5;
  color: #163a5c;
}

.nav-dashboard .nav-icon-dot,
.nav-tours .nav-icon-dot,
.nav-orders .nav-icon-dot,
.nav-customers .nav-icon-dot,
.nav-resources .nav-icon-dot,
.nav-finances .nav-icon-dot,
.nav-reports .nav-icon-dot,
.nav-operations .nav-icon-dot,
.nav-users .nav-icon-dot {
  width: 6px;
  height: 6px;
  background: #7fa8d4;
  border-radius: 50%;
}

.main {
  padding: 24px 28px 32px;
}

.topbar {
  padding-bottom: 14px;
  border-bottom: 1px solid #e3ecee;
}

.topbar h2 {
  color: #102326;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
}

.card {
  border: 1px solid #dce6e8;
  border-left: 1px solid #dce6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}

.card:hover {
  border-left-color: #dce6e8;
  box-shadow: 0 8px 18px rgba(15,23,42,0.06);
}

.card-header {
  background: #fff;
  border-bottom-color: #e7eef0;
}

.btn-primary,
.btn-login,
.segmented-control button.active {
  background: #1f4e79;
  border-color: #1f4e79;
  color: #fff;
}

.btn-primary:hover,
.btn-login:hover {
  background: #163a5c;
  box-shadow: 0 6px 14px rgba(31,78,121,0.18);
}

.login-page {
  padding: 40px 18px;
  background: linear-gradient(135deg, rgba(31,78,121,0.94), rgba(8,79,82,0.86)), linear-gradient(135deg, #1f4e79 0%, #163a5c 100%);
  background-size: cover;
  background-position: center;
}

.login-page::before {
  background: linear-gradient(90deg, rgba(7,31,33,0.08), rgba(7,31,33,0.34)), rgba(7,31,33,0.08);
}

.login-panel {
  width: 880px;
  min-height: 520px;
  background: #fff;
  border: 1px solid rgba(255,255,255,0.46);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(7,31,33,0.26);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.login-brand {
  flex: 0 0 44%;
  align-items: flex-start;
  justify-content: center;
  padding: 54px 46px;
  text-align: left;
  background: linear-gradient(180deg, #1f4e79 0%, #163a5c 100%);
}

.login-brand img.login-logo-whale {
  height: 74px;
  margin: 0 0 22px;
}

.login-brand h1,
.login-brand .brand-tagline,
.login-brand > p {
  letter-spacing: 0;
}

.brand-kicker,
.login-brand-features,
.login-form-eyebrow,
.login-form-subtitle,
.login-support {
  display: block;
}

.login-brand-features {
  display: flex;
}

.login-form-area {
  padding: 58px 52px;
  background: #fff;
}

.login-form-title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.login-form input:focus,
.global-search input:focus,
.tour-toolbar input:focus,
.tour-toolbar select:focus {
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}

.global-search input,
.tour-toolbar,
.tour-table-wrap {
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.dashboard-alert-grid,
.ranking-grid {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.dashboard-alert-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ranking-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-card {
  background: #fff !important;
  border-radius: 8px;
}

.stat-card::after {
  display: none;
}

.tour-toolbar {
  padding: 13px 14px;
}

.tour-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}

.tour-toolbar input,
.tour-toolbar select {
  min-height: 34px;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
}

.segmented-control {
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background: #f7fafb;
}

.tour-table th {
  background: #f8fbfb;
  color: #60737a;
  letter-spacing: 0;
  text-transform: none;
}

.tour-table tr:hover td,
.tour-table .row-open td {
  background: #f2f8f8;
}

.tour-no {
  color: #1f4e79;
  font-weight: 700;
}

@media (max-width: 1024px) {
  .ranking-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .dashboard-alert-grid {
    grid-template-columns: 1fr;
  }

  .main {
    padding: 12px 12px 84px !important;
  }

  .login-panel {
    width: min(100%, 420px);
    min-height: 0;
    flex-direction: column;
  }

  .login-brand,
  .login-form-area {
    padding: 32px 24px;
  }
}

/* Final brand polish: Huashu Design / Stripe restrained */
:root {
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --bg: #f5f8f9;
  --bg-card: #ffffff;
  --border: #dce6e8;
  --border-light: #edf3f4;
  --text: #102326;
  --text2: #4c6269;
  --text3: #7c8f96;
  --sidebar-bg: #16293c;
}

html,
body,
button,
input,
select,
textarea {
  font-family: var(--font-sans);
  letter-spacing: 0;
}

body {
  background:
    linear-gradient(180deg, #fbfdfd 0%, #f5f8f9 260px),
    #f5f8f9;
  color: var(--text);
}

.main {
  padding: 24px 28px 32px;
}

.sidebar {
  background: var(--sidebar-bg);
  border-right: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header {
  border-bottom-color: rgba(255,255,255,0.1);
}

.sidebar-footer {
  border-top-color: rgba(255,255,255,0.1);
}

.sidebar-footer span,
.sidebar-header span {
  color: rgba(255,255,255,0.58) !important;
}

.nav-item {
  color: rgba(255,255,255,0.7);
  border-radius: 7px;
}

.nav-item:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.nav-item.active {
  background: #e8eef5;
  color: #163a5c;
  font-weight: 700;
}

.nav-dashboard .nav-icon-dot,
.nav-tours .nav-icon-dot,
.nav-orders .nav-icon-dot,
.nav-customers .nav-icon-dot,
.nav-resources .nav-icon-dot,
.nav-finances .nav-icon-dot,
.nav-reports .nav-icon-dot,
.nav-operations .nav-icon-dot,
.nav-users .nav-icon-dot {
  width: 6px;
  height: 6px;
  background: #7fa8d4;
  border-radius: 50%;
}

.topbar {
  padding-bottom: 14px;
  border-bottom: 1px solid #e3ecee;
}

.topbar h2 {
  color: #102326;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
}

.card {
  border: 1px solid #dce6e8;
  border-left: 1px solid #dce6e8;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
  background: #fff;
}

.card:hover {
  border-left-color: #dce6e8;
  box-shadow: 0 8px 18px rgba(15,23,42,0.06);
}

.card-header {
  background: #fff;
  padding: 14px 18px;
  border-bottom-color: #e7eef0;
}

.card-header h3 {
  color: #102326;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
}

.btn,
.btn-primary,
.btn-outline,
.btn-login {
  border-radius: 7px;
  letter-spacing: 0;
}

.btn-primary,
.btn-login {
  background: #1f4e79;
  border-color: #1f4e79;
}

.btn-primary:hover,
.btn-login:hover {
  background: #163a5c;
  box-shadow: 0 6px 14px rgba(31,78,121,0.18);
}

.btn-outline {
  border-color: #d3e0e3;
  color: #315157;
  background: #fff;
}

.btn-outline:hover {
  border-color: #1f4e79;
  color: #1f4e79;
  background: #f4fbfb;
}

.login-page {
  min-height: 100vh;
  padding: 40px 18px;
  background:
    linear-gradient(135deg, rgba(31,78,121,0.94), rgba(8,79,82,0.86)),
    linear-gradient(135deg, #1f4e79 0%, #163a5c 100%);
  background-size: cover;
  background-position: center;
}

.login-page::before {
  background:
    linear-gradient(90deg, rgba(7,31,33,0.08), rgba(7,31,33,0.34)),
    rgba(7,31,33,0.08);
}

.login-panel {
  width: 880px;
  min-height: 520px;
  background: #fff;
  border: 1px solid rgba(255,255,255,0.46);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(7,31,33,0.26);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.login-brand {
  flex: 0 0 44%;
  align-items: flex-start;
  justify-content: center;
  padding: 54px 46px;
  text-align: left;
  background: linear-gradient(180deg, #1f4e79 0%, #163a5c 100%);
}

.login-brand::before {
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0));
}

.brand-kicker {
  margin-bottom: 30px;
  color: rgba(255,255,255,0.7);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

.login-brand img.login-logo-whale {
  height: 74px;
  margin: 0 0 22px;
  filter: drop-shadow(0 10px 22px rgba(0,0,0,0.2));
}

.login-brand h1 {
  margin: 0 0 10px;
  color: #fff;
  font-size: 34px;
  font-weight: 700;
  letter-spacing: 0;
}

.login-brand .brand-tagline {
  margin: 0 0 8px;
  color: rgba(255,255,255,0.84);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
}

.login-brand > p {
  margin: 0 0 28px;
  color: rgba(255,255,255,0.58);
  font-size: 13px;
  letter-spacing: 0;
}

.login-brand-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.login-feature {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 6px;
  color: rgba(255,255,255,0.86);
  font-size: 12px;
  background: rgba(255,255,255,0.08);
}

.login-feature span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #9dd9db;
}

.login-form-area {
  padding: 58px 52px;
  background: #fff;
}

.login-form-eyebrow {
  margin-bottom: 8px;
  color: #1f4e79;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
}

.login-form-title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.login-form-subtitle {
  margin-top: 8px;
  color: var(--text3);
  font-size: 13px;
}

.login-form {
  margin-top: 28px;
}

.login-form .form-group {
  margin-bottom: 16px;
}

.login-form input,
.captcha-img {
  min-height: 42px;
}

.login-form input {
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background: #fbfcfc;
}

.login-form input:focus {
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.12);
  background: #fff;
}

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

.captcha-input {
  flex: 1;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 5px;
  text-transform: uppercase;
}

.captcha-img {
  height: 42px;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  cursor: pointer;
}

.btn-login {
  padding: 12px;
  font-size: 15px;
  font-weight: 700;
}

.login-support {
  margin-top: 14px;
  color: var(--text3);
  font-size: 12px;
  text-align: center;
}

.global-search {
  margin-bottom: 16px;
}

.global-search input {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
  font-size: 14px;
}

.global-search input:focus {
  outline: none;
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}

.dashboard-alert-grid,
.ranking-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.ranking-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.todo-link {
  cursor: pointer;
  font-weight: 700;
}

.todo-link.danger {
  color: var(--danger);
}

.todo-link.warning {
  color: #9a6a3c;
}

.insight-card {
  border-left: 1px solid var(--line) !important;
}

.subtle-brand,
.subtle-cyan,
.subtle-green,
.subtle-warm {
  background: #fff;
}

.trend-card {
  border-top: 3px solid #1f4e79;
}

.stats-grid {
  gap: 14px;
}

.stat-card {
  padding: 18px;
  border-radius: 8px;
  background: #fff !important;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}

.stat-card::after {
  display: none;
}

.stat-card::before {
  background: #e2ecee;
}

.stat-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(15,23,42,0.07);
}

.stat-card .stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  flex: none;
}
.stat-card .stat-icon svg {
  width: 20px;
  height: 20px;
}

.stat-card .stat-label {
  letter-spacing: 0;
  text-transform: none;
}

.stat-card .stat-value {
  letter-spacing: 0;
}

.empty-icon:empty {
  width: 42px;
  height: 42px;
  margin: 0 auto 10px;
  border-radius: 50%;
  background: #e8eef5;
  position: relative;
}

.empty-icon:empty::after {
  content: "";
  position: absolute;
  left: 14px;
  top: 12px;
  width: 13px;
  height: 8px;
  border-left: 2px solid #1f4e79;
  border-bottom: 2px solid #1f4e79;
  transform: rotate(-45deg);
}

.tour-toolbar {
  margin-bottom: 16px;
  padding: 13px 14px;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.tour-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}

.filter-label {
  color: var(--text2);
  font-size: 12px;
  font-weight: 700;
}

.tour-toolbar input,
.tour-toolbar select {
  min-height: 34px;
  padding: 6px 10px;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background-color: #fff;
  color: var(--text);
  font-size: 13px;
}

.tour-toolbar input[type="date"] {
  width: 136px;
}

.tour-search-input {
  width: 176px;
}

.tour-toolbar input:focus,
.tour-toolbar select:focus {
  outline: none;
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}

.segmented-control {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background: #f7fafb;
}

.segmented-control button {
  min-height: 32px;
  padding: 0 12px;
  border: 0;
  border-right: 1px solid #dbe6e8;
  background: transparent;
  color: var(--text2);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.segmented-control button:last-child {
  border-right: 0;
}

.segmented-control button.active {
  background: #1f4e79;
  color: #fff;
}

.tour-table-wrap {
  overflow: hidden;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.tour-table {
  background: #fff;
}

.tour-table th {
  padding: 11px 13px;
  border-bottom: 1px solid #dbe6e8;
  background: #f8fbfb;
  color: #60737a;
  letter-spacing: 0;
  text-transform: none;
}

.tour-table td {
  padding: 12px 13px;
  border-bottom: 1px solid #eef3f4;
  font-size: 13px;
}

.tour-table tr:hover td,
.tour-table tr:nth-child(even):hover td {
  background: #f2f8f8;
}

.tour-table tr:nth-child(even) td {
  background: #fff;
}

.tour-table .row-open td {
  background: #f2f8f8;
}

.tour-no {
  color: #1f4e79;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 1024px) {
  .ranking-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .main {
    padding: 12px 12px 84px !important;
  }

  .dashboard-alert-grid {
    grid-template-columns: 1fr;
  }

  .tour-toolbar input,
  .tour-toolbar select,
  .tour-search-input {
    flex: 1 1 140px;
    width: auto;
  }

  .login-page {
    padding: 18px;
  }

  .login-panel {
    flex-direction: column;
    min-height: 0;
  }

  .login-brand,
  .login-form-area {
    padding: 34px 24px;
  }

  .login-brand {
    flex: 0 0 auto;
  }
}

/* ===== 花叔 Design 覆盖：万成假期品牌与 Stripe 克制风 ===== */
html {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  background:
    linear-gradient(180deg, #fbfdfd 0%, #f4f7f8 280px),
    #f4f7f8;
  letter-spacing: 0;
}

.sidebar {
  background: #16293c;
  border-right: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header {
  border-bottom-color: rgba(255,255,255,0.1);
}

.nav-item {
  color: rgba(255,255,255,0.68);
}

.nav-item:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.nav-item.active {
  background: #e8eef5;
  color: #163a5c;
}

.nav-dashboard .nav-icon-dot,
.nav-tours .nav-icon-dot,
.nav-orders .nav-icon-dot,
.nav-customers .nav-icon-dot,
.nav-resources .nav-icon-dot,
.nav-finances .nav-icon-dot,
.nav-reports .nav-icon-dot,
.nav-operations .nav-icon-dot,
.nav-users .nav-icon-dot {
  background: #7fa8d4;
}

.sidebar-action {
  position: relative;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 4px 9px;
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 6px;
  color: rgba(255,255,255,0.82);
  font-size: 11px;
  font-weight: 600;
  background: rgba(255,255,255,0.06);
}

.notif-badge {
  position: absolute;
  top: -7px;
  right: -8px;
  background: var(--danger);
  color: #fff;
  border-radius: 10px;
  font-size: 10px;
  min-width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  padding: 0 4px;
}

.topbar {
  padding: 0 0 14px;
  border-bottom: 1px solid #e7edef;
}

.topbar h2 {
  font-size: 22px;
  letter-spacing: 0;
}

.card {
  border: 1px solid #dde7e9;
  border-left: 1px solid #dde7e9;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}

.card:hover {
  border-left-color: #dde7e9;
  box-shadow: 0 8px 18px rgba(15,23,42,0.06);
}

.card-header {
  background: #fff;
  padding: 14px 18px;
}

.card-header h3 {
  letter-spacing: 0;
  font-weight: 700;
}

.btn,
.btn-primary,
.btn-outline,
.btn-login {
  border-radius: 7px;
  letter-spacing: 0;
}

.btn-primary,
.btn-login {
  background: #1f4e79;
  border-color: #1f4e79;
}

.btn-primary:hover,
.btn-login:hover {
  background: #163a5c;
  box-shadow: 0 6px 14px rgba(31,78,121,0.18);
}

.login-page {
  min-height: 100vh;
  padding: 40px 18px;
  background:
    linear-gradient(135deg, rgba(31,78,121,0.94), rgba(8,79,82,0.86)),
    linear-gradient(135deg, #1f4e79 0%, #163a5c 100%);
  background-size: cover;
  background-position: center;
}

.login-page::before {
  background:
    linear-gradient(90deg, rgba(7,31,33,0.1), rgba(7,31,33,0.36)),
    rgba(7,31,33,0.1);
}

.login-panel {
  width: 880px;
  min-height: 520px;
  background: #fff;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.46);
  box-shadow: 0 24px 70px rgba(7,31,33,0.26);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.login-brand {
  flex: 0 0 44%;
  align-items: flex-start;
  padding: 54px 46px;
  text-align: left;
  background: linear-gradient(180deg, #1f4e79 0%, #163a5c 100%);
}

.login-brand::before {
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0));
}

.brand-kicker {
  margin-bottom: 30px;
  color: rgba(255,255,255,0.7);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

.login-brand img.login-logo-whale {
  height: 74px;
  margin: 0 0 22px;
  filter: drop-shadow(0 10px 22px rgba(0,0,0,0.2));
}

.login-brand h1 {
  margin: 0 0 10px;
  font-size: 34px;
  letter-spacing: 0;
  font-weight: 700;
}

.login-brand .brand-tagline {
  margin: 0 0 8px;
  color: rgba(255,255,255,0.84);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
}

.login-brand > p {
  margin: 0 0 28px;
  color: rgba(255,255,255,0.58);
  font-size: 13px;
  letter-spacing: 0;
}

.login-brand-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.login-feature {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 6px;
  color: rgba(255,255,255,0.86);
  font-size: 12px;
  background: rgba(255,255,255,0.08);
}

.login-feature span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #9dd9db;
}

.login-form-area {
  padding: 58px 52px;
  background: #fff;
}

.login-form-eyebrow {
  margin-bottom: 8px;
  color: #1f4e79;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
}

.login-form-title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.login-form-subtitle {
  margin-top: 8px;
  color: var(--text3);
  font-size: 13px;
}

.login-form {
  margin-top: 28px;
}

.login-form .form-group {
  margin-bottom: 16px;
}

.login-form input,
.captcha-img {
  min-height: 42px;
}

.login-form input {
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background: #fbfcfc;
}

.login-form input:focus {
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.12);
  background: #fff;
}

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

.captcha-input {
  flex: 1;
  letter-spacing: 5px;
  font-size: 15px;
  text-align: center;
  font-weight: 700;
  text-transform: uppercase;
}

.captcha-img {
  height: 42px;
  border-radius: 7px;
  cursor: pointer;
  border: 1px solid #dbe6e8;
}

.btn-login {
  padding: 12px;
  font-size: 15px;
  font-weight: 700;
}

.login-support {
  margin-top: 14px;
  color: var(--text3);
  font-size: 12px;
  text-align: center;
}

.global-search {
  margin-bottom: 16px;
}

.global-search input {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  font-size: 14px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.global-search input:focus {
  outline: none;
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}

.dashboard-alert-grid,
.ranking-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.ranking-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.todo-link {
  cursor: pointer;
  font-weight: 600;
}

.todo-link.danger { color: var(--danger); }
.todo-link.warning { color: #9a6a3c; }

.insight-card {
  border-left: 1px solid var(--line) !important;
}

.subtle-brand,
.subtle-cyan,
.subtle-green,
.subtle-warm {
  background: #fff;
}

.trend-card {
  border-top: 3px solid #1f4e79;
}

.stats-grid {
  gap: 14px;
}

.stat-card {
  padding: 18px;
  border-radius: 8px;
  background: #fff !important;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}

.stat-card::after {
  display: none;
}

.stat-card::before {
  background: #e2ecee;
}

.stat-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(15,23,42,0.07);
}

.stat-card .stat-label {
  letter-spacing: 0;
  text-transform: none;
}

.stat-card .stat-value {
  letter-spacing: 0;
}

.tour-toolbar {
  margin-bottom: 16px;
  padding: 13px 14px;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.tour-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}

.filter-label {
  color: var(--text2);
  font-size: 12px;
  font-weight: 700;
}

.tour-toolbar input,
.tour-toolbar select {
  min-height: 34px;
  padding: 6px 10px;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  color: var(--text);
  font-size: 13px;
  background-color: #fff;
}

.tour-toolbar input[type="date"] {
  width: 136px;
}

.tour-search-input {
  width: 176px;
}

.tour-toolbar input:focus,
.tour-toolbar select:focus {
  outline: none;
  border-color: #1f4e79;
  box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}

.segmented-control {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid #dbe6e8;
  border-radius: 7px;
  background: #f7fafb;
}

.segmented-control button {
  min-height: 32px;
  padding: 0 12px;
  border: 0;
  border-right: 1px solid #dbe6e8;
  background: transparent;
  color: var(--text2);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.segmented-control button:last-child {
  border-right: 0;
}

.segmented-control button.active {
  background: #1f4e79;
  color: #fff;
}

.tour-table-wrap {
  overflow: hidden;
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}

.tour-table {
  background: #fff;
}

.tour-table th {
  padding: 11px 13px;
  border-bottom: 1px solid #dbe6e8;
  background: #f8fbfb;
  color: #60737a;
  letter-spacing: 0;
  text-transform: none;
}

.tour-table td {
  padding: 12px 13px;
  border-bottom: 1px solid #eef3f4;
  font-size: 13px;
}

.tour-table tr:hover td,
.tour-table tr:nth-child(even):hover td {
  background: #f2f8f8;
}

.tour-table tr:nth-child(even) td {
  background: #fff;
}

.tour-table .row-open td {
  background: #f2f8f8;
}

.tour-no {
  color: #1f4e79;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 1024px) {
  .ranking-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .dashboard-alert-grid {
    grid-template-columns: 1fr;
  }

  .tour-toolbar input,
  .tour-toolbar select,
  .tour-search-input {
    flex: 1 1 140px;
    width: auto;
  }

  .login-page {
    padding: 18px;
  }

  .login-panel {
    min-height: 0;
  }

  .login-brand,
  .login-form-area {
    padding: 34px 24px;
  }
}
.modal-mask {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.4); z-index: 1000;
  display: flex; align-items: center; justify-content: center;
}
.modal {
  background: var(--bg-card); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); width: 90%; max-width: 600px;
  max-height: 85vh; overflow-y: auto;
}
.modal-header {
  padding: 16px 20px; border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.modal-header h3 { font-size: 16px; font-weight: 700; }
.modal-body { padding: 20px; }
.modal-footer {
  padding: 14px 20px; border-top: 1px solid var(--border);
  display: flex; justify-content: flex-end; gap: 8px;
}

/* ===== Tab 切换 ===== */
.tabs { display: flex; gap: 2px; border-bottom: 2px solid var(--border); margin-bottom: 16px; display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 16px; }
.tab { padding: 9px 16px; font-size: 13px; cursor: pointer; color: var(--text2); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all var(--transition);
  padding: 10px 20px; cursor: pointer; font-size: 14px; font-weight: 500;
  color: var(--text2); border-bottom: 2px solid transparent;
  margin-bottom: -2px; transition: all var(--transition);
  user-select: none;
}
.tab:hover { color: var(--primary); }
.tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; color: var(--primary); border-bottom-color: var(--primary); }
/* 团期展开区 · 操作按钮（与 tab 同排同字号；锁团黑 / 删除红） */
.tab-op { padding: 10px 20px; font-size: 14px; font-weight: 500; cursor: pointer; color: var(--text2); border: none; background: none; border-bottom: 2px solid transparent; margin-bottom: -2px; user-select: none; transition: color var(--transition); }
.tab-op:hover { color: var(--primary); }
.tab-op-lock { color: var(--ink); font-weight: 700; }
.tab-op-danger { color: var(--danger); font-weight: 600; }

/* ===== 弹窗关闭按钮 ===== */
.modal-close {
  width: 28px; height: 28px; border-radius: 50%;
  border: none; background: var(--bg);
  font-size: 16px; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--text3); transition: all var(--transition);
}
.modal-close:hover { background: var(--danger); color: var(--white); }

/* ===== 下拉箭头美化 ===== */
select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 5l3 3 3-3' fill='none' stroke='%238aa4a8' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
  padding-right: 32px !important;
}

/* ===== 页面过渡 ===== */
.main > div {
  animation: pageEnter 0.25s ease;
}
@keyframes pageEnter {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== 状态 ===== */
.empty {
  text-align: center; padding: 56px 20px; color: var(--text3);
  position: relative;
}
.empty::before {
  content: '';
  display: block; width: 80px; height: 80px; margin: 0 auto 20px;
  background: var(--primary-light); border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 80'%3E%3Crect x='20' y='30' width='40' height='5' rx='2' fill='%230d7377' opacity='.3'/%3E%3Crect x='24' y='40' width='32' height='5' rx='2' fill='%230d7377' opacity='.2'/%3E%3Crect x='28' y='50' width='24' height='5' rx='2' fill='%230d7377' opacity='.15'/%3E%3Ccircle cx='40' cy='20' r='12' fill='none' stroke='%230d7377' stroke-width='2' opacity='.25'/%3E%3Cpath d='M36 17l8 6-8 6' fill='none' stroke='%230d7377' stroke-width='1.5' stroke-linecap='round' opacity='.2'/%3E%3C/svg%3E");
  background-size: cover;
}
.empty p { font-size: 14px; color: var(--text3); margin-top: 4px; }
.empty-icon { display: none; } /* 批次D：.empty 已由 ::before 提供空状态插画，隐藏冗余的旧对勾图标 */
/* 团期展开·报名空态·紧凑版：去掉大圆形装饰图标，缩小留白，只留一行「暂无报名」+ 报名按钮 */
.empty-tight { padding: 18px 16px !important; }
.empty-tight::before { display: none !important; }
.empty-tight p { margin-top: 0; font-size: 14px; }
.empty .empty-action {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 16px; padding: 10px 24px;
  background: var(--primary); color: var(--white);
  border: none; border-radius: var(--radius);
  font-size: 14px; font-weight: 600; cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 2px 8px rgba(31,78,121,0.25);
}
.empty .empty-action:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(31,78,121,0.35); }
.empty .empty-action:active { transform: scale(0.97); }
.money-pos { color: var(--success); font-weight: 600; }
.money-neg { color: var(--danger); font-weight: 600; }

/* ===== 页面专属 ===== */
/* 统计卡片 — 仪表盘 + 报表 */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }
@media (max-width: 1024px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
.stat-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px 20px; box-shadow: var(--shadow-sm);
  background: var(--bg-card); border-radius: var(--radius-lg);
  padding: 16px 14px; box-shadow: var(--shadow);
  border: 1px solid var(--border); position: relative; overflow: hidden;
  transition: all 0.25s ease;
}
.stat-card:nth-child(n) { background: #ffffff; }
.stat-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--border); transition: background 0.25s ease;
}
.stat-card:hover {
  box-shadow: var(--shadow-lg); transform: translateY(-2px);
}
.stat-card:hover::before { background: var(--primary); }
.stat-card::after {
  content: ''; position: absolute; right: -12px; bottom: -12px;
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--primary-light); opacity: 0; transition: opacity 0.3s ease;
}
.stat-card:hover::after { opacity: 0.6; }
/* KPI主卡片 — 大字号+趋势指示 */
.stat-card.kpi { grid-column: span 2; padding: 24px 20px; }
.stat-card.kpi .stat-value { font-size: 28px; }
.stat-card.kpi .stat-label { font-size: 13px; margin-bottom: 8px; }
.stat-card .stat-trend {
  font-size: 12px; margin-top: 6px; display: flex; align-items: center; gap: 4px;
}
.stat-card .stat-trend.up { color: var(--success); }
.stat-card .stat-trend.down { color: var(--danger); }
.stat-card .stat-label {
  font-size: 12px; color: var(--text3); font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px;
}
.stat-card .stat-value {
  font-size: 22px; font-weight: 800; color: var(--text);
  line-height: 1.2; letter-spacing: -0.5px;
}

/* 仪表盘今日提醒 */
.dash-alert-row {
  padding: 8px 0; border-bottom: 1px solid var(--border);
  cursor: pointer; font-size: 13px; transition: background 0.15s ease;
}
.dash-alert-row:hover { background: var(--primary-light); padding-left: 4px; }

/* AI 洞察卡片 */
.ai-insight-card .card-body { font-size: 14px; line-height: 2; }
.ai-insight-card .card-body > div { padding: 2px 0; }

/* ===== 报表专属 ===== */
.report-table table { font-size: 14px; }
.report-table th { font-size: 11px; font-weight: 600; color: var(--text3); text-transform: uppercase; letter-spacing: 0.5px; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; padding: 10px 14px; }
.report-table td { border-bottom: 1px solid var(--border-light); padding: 10px 14px; }
.report-table .r { text-align: right; font-variant-numeric: tabular-nums; }

/* ===== 响应式（移动端适配） ===== */
@media (max-width: 768px) {
  .sidebar { display: none; }
  .main { margin-left: 0; padding: 10px; }
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px; display: none !important; }
  .main { margin-left: 0 !important; padding: 0 !important; }
}


/* ===== 登录页 — 左右分栏 ===== */

.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: #1f4e79;
  background-image: linear-gradient(135deg, #1f4e79 0%, #163a5c 100%);
  background-size: cover; background-position: center;
  position: relative;
}
.login-page::before {
  content: ''; position: absolute; inset: 0;
  background: rgba(10,25,45,0.50);
  z-index: 0;
}
.login-page > * { position: relative; z-index: 1; }
.login-panel {
  display: flex; flex-direction: row; width: 760px; max-width: 95vw; min-height: 480px;
  background: rgba(255,255,255,0.92); backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 8px 40px rgba(0,0,0,0.25);
}
.login-brand {
  flex: 0 0 42%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(160deg,#1f4e79 0%,#1a4568 50%,#163a5c 100%);
  padding: 48px 36px; text-align: center; position: relative; overflow: hidden;
}
.login-brand::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 80%,rgba(199,145,92,.15) 0%,transparent 60%);
}
.login-brand > * { position: relative; z-index: 1; }
.login-brand img.login-logo-whale { height: 100px; filter: drop-shadow(0 2px 12px rgba(0,0,0,.25)); margin-bottom: 28px; }
.login-brand h1 { font-size: 32px; font-weight: 700; letter-spacing: 8px; color: #fff; margin: 0 0 12px; }
.login-brand .brand-tagline { font-size: 16px; font-weight: 300; color: rgba(255,255,255,.85); letter-spacing: 4px; margin-bottom: 12px; }
.login-brand > p { font-size: 13px; color: rgba(255,255,255,.55); letter-spacing: 3px; margin: 0; }
.login-tagline { display: none; }
.login-features { display: none; }
.login-brand::after { display: none; }
.login-form-area {
  flex: 1; display: flex; flex-direction: column; justify-content: center;
  padding: 48px 40px;
}
.login-form-area::before { display: none; }
.login-form-title {
  font-size: 20px; font-weight: 700; color: var(--text); margin-bottom: 4px;
}
.login-form { margin-top: 16px; }
.login-form .form-group { margin-bottom: 14px; }
.login-form label { font-size: 12px; font-weight: 600; color: var(--text2); margin-bottom: 5px; display: block; }
.login-form input {
  width: 100%; padding: 10px 13px; font-size: 14px;
  border: 1.5px solid var(--border); border-radius: 8px;
  background: #fff; transition: all 0.15s;
  box-sizing: border-box;
}
.login-form input:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(31,78,121,0.08);
}
.btn-login { width: 100%; padding: 12px; background: var(--primary); color: #fff; border: none; border-radius: 8px; font-size: 15px; font-weight: 700; cursor: pointer; letter-spacing: 4px; transition: all 0.15s; margin-top: 8px; }
.btn-login:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(31,78,121,0.35); }
.btn-login:active { transform: translateY(0); }
.btn-login:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

@media (max-width: 640px) {
  .login-panel { flex-direction: column; }
  .login-brand { flex: 0 0 auto; padding: 36px 24px; }
  .login-brand img.login-logo-whale { height: 72px; }
  .login-brand h1 { font-size: 24px; letter-spacing: 6px; }
  .login-brand .brand-tagline { font-size: 15px; }
  .login-form-area { padding: 32px 24px; }
}

/* Final EOF cascade lock: Huashu Design */
:root {
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --warning: #b45309;
  --warning-light: #fdf6ee;
  --bg: #f5f8f9;
  --border: #dce6e8;
  --border-light: #edf3f4;
  --text: #102326;
  --text2: #4c6269;
  --text3: #7c8f96;
}

body,
button,
input,
select,
textarea {
  font-family: var(--font-sans);
  letter-spacing: 0;
}

body {
  background: linear-gradient(180deg, #fbfdfd 0%, #f5f8f9 260px), #f5f8f9;
  color: var(--text);
}

.sidebar { background: #16293c; border-right-color: rgba(255,255,255,0.1); }
.nav-item { color: rgba(255,255,255,0.7); border-radius: 7px; }
.nav-item:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-item.active { background: #e8eef5; color: #163a5c; }
.nav-dashboard .nav-icon-dot,
.nav-tours .nav-icon-dot,
.nav-orders .nav-icon-dot,
.nav-customers .nav-icon-dot,
.nav-resources .nav-icon-dot,
.nav-finances .nav-icon-dot,
.nav-reports .nav-icon-dot,
.nav-operations .nav-icon-dot,
.nav-users .nav-icon-dot {
  width: 6px;
  height: 6px;
  background: #7fa8d4;
  border-radius: 50%;
}

.main { padding: 24px 28px 32px; }
.topbar { padding-bottom: 14px; border-bottom: 1px solid #e3ecee; }
.topbar h2 { color: #102326; font-size: 22px; font-weight: 700; letter-spacing: 0; }
.card {
  border: 1px solid #dce6e8;
  border-left: 1px solid #dce6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}
.card:hover { border-left-color: #dce6e8; box-shadow: 0 8px 18px rgba(15,23,42,0.06); }
.card-header { background: #fff; border-bottom-color: #e7eef0; }
.btn-primary,
.btn-login,
.segmented-control button.active {
  background: #1f4e79;
  border-color: #1f4e79;
  color: #fff;
}
.btn-primary:hover,
.btn-login:hover { background: #163a5c; box-shadow: 0 6px 14px rgba(31,78,121,0.18); }

.login-page {
  min-height: 100vh;
  padding: 40px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  background: #0f2740 url('https://images.unsplash.com/photo-1507525428034-b723cf961d3e?auto=format&fit=crop&w=1920&q=80') center center / cover no-repeat;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}
.login-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7, 19, 32, 0.72), rgba(7, 19, 32, 0.34) 42%, rgba(255,255,255,0.12) 42%, rgba(255,255,255,0.18) 100%);
}
.login-page > * { position: relative; z-index: 1; }
.login-panel {
  width: min(1180px, 100%);
  min-height: 620px;
  display: flex;
  overflow: hidden;
  border-radius: 16px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(255,255,255,0.42);
  box-shadow: 0 28px 80px rgba(4, 20, 34, 0.34);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.login-brand {
  flex: 0 0 42%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 32px;
  padding: 56px 48px;
  color: #fff;
  text-align: left;
  background: linear-gradient(160deg, #1a3a5c 0%, #2d6a9f 56%, #3490c4 100%);
  position: relative;
  overflow: hidden;
}
.login-brand::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 22%, rgba(255,255,255,0.16) 0, rgba(255,255,255,0) 32%),
    radial-gradient(circle at 82% 78%, rgba(255,255,255,0.10) 0, rgba(255,255,255,0) 30%);
}
.login-brand > * { position: relative; z-index: 1; }
.login-brand-main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}
.brand-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
}
.login-brand img.login-logo-whale {
  width: 88px;
  height: 88px;
  margin: 4px 0 8px;
  filter: drop-shadow(0 10px 24px rgba(0,0,0,0.24));
}
.login-brand h1 {
  margin: 0;
  color: #fff;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0;
}
.login-brand .brand-tagline {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0;
  color: rgba(255,255,255,0.94);
}
.login-brand .brand-copy {
  max-width: 22ch;
  font-size: 14px;
  line-height: 1.8;
  color: rgba(255,255,255,0.82);
}
.brand-kicker,
.login-form-eyebrow,
.login-form-subtitle,
.login-support { display: block; }
.login-brand-features {
  display: grid;
  gap: 12px;
  align-content: end;
}
.login-feature {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.92);
}
.login-feature span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.92);
  flex: 0 0 auto;
}
.login-form-area {
  flex: 1 1 58%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 60px;
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.login-form-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  color: #2d6a9f;
  margin-bottom: 10px;
}
.login-form-title {
  margin: 0;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 0;
  color: #16324d;
}
.login-form-subtitle {
  margin-top: 8px;
  margin-bottom: 28px;
  font-size: 14px;
  line-height: 1.75;
  color: #5a6d80;
}
.login-form { margin-top: 0; }
.login-form .form-group { margin-bottom: 18px; }
.login-form label {
  font-size: 12px;
  font-weight: 700;
  color: #35536f;
  margin-bottom: 8px;
  display: block;
}
.login-form input {
  width: 100%;
  min-height: 48px;
  padding: 12px 15px;
  font-size: 15px;
  color: #16324d;
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(119, 146, 171, 0.34);
  border-radius: 10px;
  box-sizing: border-box;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.captcha-row {
  display: flex;
  gap: 12px;
  align-items: stretch;
}
.captcha-row .captcha-input { flex: 1 1 auto; min-width: 0; }
.captcha-img {
  width: 128px;
  height: 48px;
  flex: 0 0 128px;
  border-radius: 10px;
  border: 1px solid rgba(119, 146, 171, 0.34);
  background: rgba(255,255,255,0.96);
}
.btn-login {
  width: 100%;
  min-height: 48px;
  margin-top: 6px;
  padding: 12px 16px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #1a3a5c 0%, #2d6a9f 55%, #3490c4 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}
.btn-login:hover {
  background: linear-gradient(135deg, #1a3a5c 0%, #2d6a9f 55%, #3490c4 100%);
  box-shadow: 0 12px 24px rgba(26,58,92,0.24);
  transform: translateY(-1px);
}
.btn-login:active { transform: translateY(0); }
.btn-login:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
.login-support {
  margin-top: 14px;
  font-size: 12px;
  color: #7a8b9b;
}
.login-form input:focus,
.global-search input:focus,
.tour-toolbar input:focus,
.tour-toolbar select:focus {
  outline: none;
  border-color: #2d6a9f;
  box-shadow: 0 0 0 3px rgba(45,106,159,0.14);
  background: #fff;
}

.global-search input,
.tour-toolbar,
.tour-table-wrap {
  border: 1px solid #dbe6e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,0.03);
}
.dashboard-alert-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.ranking-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat-card { background: #fff !important; border-radius: 8px; }
.stat-card::after { display: none; }
.tour-toolbar { padding: 13px 14px; }
.tour-filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
.tour-toolbar input,
.tour-toolbar select { min-height: 34px; border: 1px solid #dbe6e8; border-radius: 7px; }
.segmented-control { border: 1px solid #dbe6e8; border-radius: 7px; background: #f7fafb; }
.tour-table th { background: #f8fbfb; color: #60737a; letter-spacing: 0; text-transform: none; }
.tour-table tr:hover td,
.tour-table .row-open td { background: #f2f8f8; }
.tour-no { color: #1f4e79; font-weight: 700; }

@media (max-width: 1024px) {
  .ranking-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .dashboard-alert-grid { grid-template-columns: 1fr; }
  .main { padding: 12px 12px 84px !important; }
  .login-page {
    padding: 16px;
    background-position: center top;
  }
  .login-panel { width: min(100%, 520px); min-height: 0; flex-direction: column; }
  .login-brand,
  .login-form-area { padding: 28px 22px; }
  .login-brand,
  .login-form-area { flex-basis: auto; }
  .login-brand img.login-logo-whale { width: 72px; height: 72px; }
  .login-brand h1 { font-size: 28px; }
  .login-form-title { font-size: 24px; }
  .captcha-img { width: 112px; flex-basis: 112px; }
}

/* Blue Beach Login (huashu-a-blue reference) */
.login-page {
  position: fixed !important;
  inset: 0 !important;
  z-index: 9999 !important;
  min-height: 100vh !important;
  padding: 40px 24px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  background: #0f2740 url('/img/login-beach-unsplash.jpg') center center / cover no-repeat !important;
}

.login-page::before {
  content: '' !important;
  position: absolute !important;
  inset: 0 !important;
  z-index: 0 !important;
  background: rgba(10, 25, 45, 0.72) !important;
}

.login-page > * {
  position: relative !important;
  z-index: 1 !important;
}

.login-panel {
  width: min(920px, 100%) !important;
  min-height: 520px !important;
  display: flex !important;
  flex-direction: row !important;
  overflow: hidden !important;
  border-radius: 16px !important;
  background: rgba(255, 255, 255, 0.88) !important;
  border: 1px solid rgba(255, 255, 255, 0.38) !important;
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.32), 0 2px 8px rgba(0, 0, 0, 0.12) !important;
  backdrop-filter: blur(18px) !important;
  -webkit-backdrop-filter: blur(18px) !important;
}

.login-brand {
  flex: 0 0 42% !important;
  min-width: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 28px !important;
  padding: 48px 36px !important;
  text-align: center !important;
  color: #fff !important;
  background: linear-gradient(160deg, #1a3a5c 0%, #2d6a9f 62%, #3490c4 100%) !important;
  position: relative !important;
  overflow: hidden !important;
}

.login-brand::before {
  content: '' !important;
  position: absolute !important;
  inset: 0 !important;
  background: radial-gradient(ellipse at 20% 80%, rgba(255, 255, 255, 0.16) 0%, transparent 58%) !important;
}

.login-brand > * {
  position: relative !important;
  z-index: 1 !important;
}

.brand-stack {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 18px !important;
}

.brand-logos {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 20px !important;
}

.brand-logo {
  display: block !important;
  width: 80px !important;
  height: 80px !important;
  flex: 0 0 80px !important;
  overflow: hidden !important;
  max-width: none !important;
  object-fit: contain !important;
}

.brand-logo-whale,
.login-logo-whale {
  filter: brightness(0) invert(1) !important;
}

.brand-logo-company {
  filter: none !important;
}

.login-brand h1 {
  margin: 0 !important;
  color: #fff !important;
  font-size: 2rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
}

.login-brand .brand-subtitle {
  margin: 0 !important;
  color: rgba(255, 255, 255, 0.86) !important;
  font-size: 1rem !important;
  font-weight: 400 !important;
  line-height: 1.6 !important;
  letter-spacing: 0 !important;
  font-style: normal !important;
}

.login-brand p,
.login-brand > p,
.login-brand .brand-kicker,
.login-brand-main,
.login-brand-features,
.login-feature,
.brand-copy {
  display: none !important;
}

.login-form-area {
  flex: 0 0 58% !important;
  min-width: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  padding: 48px 44px !important;
  background: #fff !important;
}

.login-form-title {
  margin: 0 0 6px !important;
  color: #1a3a5c !important;
  font-size: 1.25rem !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
  letter-spacing: 0 !important;
}

.login-form-subtitle {
  display: block !important;
  margin: 0 0 28px !important;
  color: #6b8298 !important;
  font-size: 0.8125rem !important;
  line-height: 1.6 !important;
}

.login-form {
  margin-top: 0 !important;
}

.login-form .form-group {
  margin-bottom: 20px !important;
}

.login-form input,
.login-form-area input {
  width: 100% !important;
  height: 44px !important;
  padding: 0 14px !important;
  border: 1.5px solid #d4dfe7 !important;
  border-radius: 8px !important;
  background: #f8fafc !important;
  color: #1a2a3a !important;
  font-size: 0.9375rem !important;
  box-sizing: border-box !important;
  outline: none !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease !important;
}

.login-form input::placeholder,
.login-form-area input::placeholder {
  color: #9aaaba !important;
}

.login-form input:focus,
.login-form-area input:focus {
  border-color: #2d6a9f !important;
  background: #fff !important;
  box-shadow: 0 0 0 3px rgba(45, 106, 159, 0.12) !important;
}

.captcha-row {
  display: flex !important;
  gap: 12px !important;
  align-items: stretch !important;
}

.captcha-row input {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

.captcha-img {
  width: 110px !important;
  height: 44px !important;
  flex: 0 0 110px !important;
  border-radius: 8px !important;
  border: 1.5px solid #d4dfe7 !important;
  background: #e8f4f8 !important;
  cursor: pointer !important;
  object-fit: cover !important;
}

.btn-login {
  width: 100% !important;
  height: 46px !important;
  margin-top: 8px !important;
  border: none !important;
  border-radius: 8px !important;
  background: #2d6a9f !important;
  color: #fff !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  letter-spacing: 0 !important;
  cursor: pointer !important;
  transition: background 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease, opacity 0.2s ease !important;
}

.btn-login:hover {
  background: #1a3a5c !important;
  box-shadow: 0 8px 18px rgba(45, 106, 159, 0.24) !important;
  transform: translateY(-1px) !important;
}

.btn-login:active {
  transform: scale(0.98) !important;
}

.btn-login:disabled {
  opacity: 0.6 !important;
  cursor: not-allowed !important;
  transform: none !important;
  box-shadow: none !important;
}

.login-form .form-footer {
  display: flex !important;
  justify-content: space-between !important;
  gap: 16px !important;
  margin-top: 16px !important;
}

.login-icp {
  position: absolute !important;
  left: 24px !important;
  right: 24px !important;
  bottom: 14px !important;
  z-index: 2 !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: 12px !important;
  line-height: 1.4 !important;
  text-align: center !important;
  letter-spacing: 0 !important;
}

.login-form-eyebrow,
.login-support {
  display: none !important;
}

@media (max-width: 768px) {
  .login-page {
    padding: 16px !important;
    align-items: center !important;
    background-position: center center !important;
  }

  .login-panel {
    width: min(100%, 420px) !important;
    min-height: 0 !important;
    flex-direction: column !important;
  }

  .login-brand {
    flex: 0 0 auto !important;
    padding: 32px 24px !important;
  }

  .brand-logos {
    gap: 16px !important;
  }

  .brand-logo {
    width: 64px !important;
    height: 64px !important;
    flex-basis: 64px !important;
  }

  .login-brand h1 {
    font-size: 1.5rem !important;
  }

  .login-brand .brand-subtitle {
    font-size: 14px !important;
  }

  .login-form-area {
    flex: 0 0 auto !important;
    padding: 32px 24px !important;
  }

  .captcha-img {
    width: 104px !important;
    flex-basis: 104px !important;
  }
}

/* ============================================================
   编辑部浅色主题（Bold Big-Type Editorial）
   ============================================================ */
:root {
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --bg: #faf9f6;
  --bg-card: #ffffff;
  --sidebar-bg: #ffffff;
  --border: #e7e4dc;
  --border-light: #efede7;
  --text: #0c0c0c;
  --text2: #6f6b60;
  --text3: #9b978c;
}

body {
  background: var(--paper-deep);
  color: var(--ink);
  font-family: var(--font-sans);
}

/* 侧边栏 — 三主题变量化（风格1 墨黑 / 风格2 冷白 / 风格3 深松针绿）*/
.sidebar {
  background: var(--side-bg);
  border-right: 1px solid var(--side-line);
}
.sidebar-header,
.sidebar-logo {
  color: var(--side-text-hover);
  border-bottom-color: var(--side-line);
}
.sidebar-header h2 { color: var(--side-text-hover); }
.sidebar-header span { color: var(--side-text) !important; }
.sidebar-footer {
  color: var(--side-text);
  border-top-color: var(--side-line);
}
.sidebar-footer span { color: var(--side-text) !important; }
.nav-divider {
  background: var(--side-line);
}
.nav-item {
  color: var(--side-text);
  font-weight: 500;
}
.nav-item:hover {
  background: var(--side-hover-bg);
  color: var(--side-text-hover);
}
.nav-item.active {
  background: var(--side-active-bg);
  color: var(--side-active-text);
  font-weight: 600;
}
.nav-item.active .nav-icon-dot {
  background: var(--side-accent);
}
.sidebar-action {
  color: var(--side-text-hover);
  border-color: var(--side-line);
  background: var(--side-hover-bg);
}

/* 顶栏 */
.topbar {
  border-bottom-color: var(--line);
}
.topbar h2 {
  color: var(--ink);
}

/* 卡片 — 面板 + 发丝线 + 直角感 */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: none;
}
.card:hover {
  border-left-color: var(--line);
  box-shadow: none;
}
.card-header {
  background: var(--panel);
  border-bottom-color: var(--line);
}

/* KPI 数字放大加粗 */
.stat-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: none;
}
.stat-card .stat-value {
  font-weight: 800;
  letter-spacing: -0.02em;
}
/* 表格 */
thead,
th {
  background: var(--paper);
}
th {
  border-bottom-color: var(--line);
  color: var(--muted);
}
td {
  border-bottom-color: var(--line);
}
tr:hover td {
  background: var(--paper);
}

/* 按钮 */
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-deep);
  box-shadow: none;
}

/* 表单 */
input,
select,
textarea {
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  color: var(--ink);
}
input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-wash);
}

/* 金额 / 数字 tabular */
.money-pos,
.money-neg,
.amount,
.stat-value,
.k-detail {
  font-variant-numeric: tabular-nums;
}

/* 滚动条浅色 */
::-webkit-scrollbar-thumb {
  background: var(--line-strong);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--faint);
}
.sidebar::-webkit-scrollbar-thumb {
  background: var(--line-strong);
}

/* 字体排版增强 — 编辑部巨型数字 */
.stat-card.kpi .stat-value {
  font-size: 40px;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
}
.stat-card .stat-value {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.stat-card .stat-label {
  letter-spacing: 0.14em;
  font-weight: 700;
}
.trend-card .card-body > div > div > div:first-child {
  font-weight: 900;
  letter-spacing: -0.02em;
}

/* ══════════════════════════════════════
   工作台 Dashboard · Bold Big-Type Editorial
   落地设计稿 design-demos/roulette.html
   ══════════════════════════════════════ */
/* dashboard 继承全局主题令牌（--ink/--paper/--line/--accent 等由 :root 提供，随主题切换）*/

/* 眉题 · 刻度线 + 字母距 */
.dash-hero .overline {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.3em;
  color: var(--muted);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 14px;
}
.dash-hero .overline .tick { width: 26px; height: 2px; background: var(--ink); flex: 0 0 auto; }
.dash-hero .overline .en { color: var(--faint); font-weight: 600; letter-spacing: 0.26em; }

/* 巨型营收数字 */
.dash-hero { margin-bottom: 28px; }
.hero-num {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-top: 16px;
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 0.86;
  color: var(--ink);
  font-size: clamp(64px, 7.5vw, 132px);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.hero-num .cur {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-top: 0.28em;
  color: var(--accent);
}
.hero-num .frac { color: var(--ink); }
.hero-meta { margin-top: 20px; display: flex; align-items: center; gap: 16px; }
.hero-meta .cap { font-size: 14px; color: var(--muted); }
.hero-meta .cap b { color: var(--ink); font-weight: 700; }
.meta-sep { width: 1px; height: 16px; background: var(--line-strong); }

/* 次级 KPI · 左列底部，border-top 发丝线 + 组间 border-left */
.kpis {
  display: flex;
  align-items: stretch;
  border-top: 1px solid var(--line);
  padding-top: 24px;
  margin-top: auto;
}
.kpi { flex: 1; padding: 0 26px; min-width: 0; }
.kpi:first-child { padding-left: 0; }
.kpi + .kpi { border-left: 1px solid var(--line); }
.kpi .k-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.kpi .k-label .en { color: var(--faint); font-weight: 600; letter-spacing: 0.2em; }
.kpi .k-num {
  font-size: 48px;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-top: 12px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.kpi .k-num small { font-size: 20px; font-weight: 800; color: var(--muted); letter-spacing: -0.01em; }
.kpi .k-sub { margin-top: 8px; font-size: 13px; color: var(--faint); }

/* 左右分栏主区（对照设计稿 1.32fr / 1fr） */
.dash-main {
  display: grid;
  grid-template-columns: 1.32fr 1fr;
  margin-bottom: 30px;
}
.dash-col-left {
  display: flex;
  flex-direction: column;
  padding-right: 56px;
}
.dash-col-right {
  border-left: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 38px;
  padding-left: 48px;
}

/* 节标题 · 板块序号 + 发丝线 */
.sec-head { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.sec-head .idx { font-size: 12px; font-weight: 800; color: var(--faint); letter-spacing: 0.1em; }
.sec-head .t { font-size: 13px; font-weight: 700; letter-spacing: 0.14em; color: var(--ink); }
.sec-head .line { flex: 1; height: 1px; background: var(--line); }

/* 今日提醒 */
.reminder { display: flex; flex-direction: column; }
.rem-row {
  display: flex;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: padding-left 0.15s ease;
}
.rem-row:hover { padding-left: 6px; }
.rem-row:last-child { border-bottom: none; padding-bottom: 0; }
.rem-tag {
  flex: 0 0 auto;
  width: 52px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  border: 1px solid var(--ink);
  border-radius: 4px;
}
.rem-tag.depart { background: var(--accent); border-color: var(--accent); color: #fff; }
.rem-tag.return { background: transparent; color: var(--ink); }
.rem-main { flex: 1; padding-left: 16px; min-width: 0; }
.rem-code { font-size: 20px; font-weight: 900; letter-spacing: -0.01em; color: var(--ink); line-height: 1; font-variant-numeric: tabular-nums; }
.rem-dest { margin-top: 5px; font-size: 14px; color: var(--muted); letter-spacing: 0.02em; }
.rem-side { flex: 0 0 auto; text-align: right; }
.rem-side .n { font-size: 16px; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.rem-empty { padding: 16px 0; font-size: 13px; color: var(--faint); }

/* 待办 */
.todos { display: flex; gap: 12px; }
.todo {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 16px 16px 14px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.todo:hover { border-color: var(--accent); }
.todo .t-num { font-size: 34px; font-weight: 900; letter-spacing: -0.03em; color: var(--ink); line-height: 1; font-variant-numeric: tabular-nums; }
.todo .t-lbl { margin-top: 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.16em; color: var(--muted); }
.todo .t-lbl .dot { color: var(--accent); margin-right: 6px; }

/* 收客趋势柱状图 */
.chart-band { border-top: 1px solid var(--line); padding: 20px 0 8px; margin-bottom: 26px; }
.chart-head { display: flex; align-items: baseline; justify-content: space-between; }
.chart-head .l { display: flex; align-items: center; gap: 12px; }
.chart-head .t { font-size: 13px; font-weight: 700; letter-spacing: 0.14em; color: var(--ink); }
.chart-head .idx { font-size: 12px; font-weight: 800; color: var(--faint); letter-spacing: 0.1em; }
.chart-body {
  display: flex;
  align-items: flex-end;
  gap: 26px;
  height: 118px;
  margin-top: 14px;
  position: relative;
}
.chart-body::before {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--line-strong);
}
.bar-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
}
.bar-val { font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: 0.02em; margin-bottom: 7px; font-variant-numeric: tabular-nums; }
.bar { width: 100%; max-width: 64px; background: var(--ink); border-radius: 2px 2px 0 0; min-height: 4px; }
.bar.hot { background: var(--accent); }
.bar-col.hot .bar-val { color: var(--accent-deep); font-weight: 800; }
.bar-day { margin-top: 9px; font-size: 12px; color: var(--faint); letter-spacing: 0.04em; }
.bar-col.hot .bar-day { color: var(--ink); font-weight: 700; }

/* 排行榜 · 编辑部化 */
.ranking-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.ranking-grid .card { border: 1px solid var(--line); border-radius: 4px; box-shadow: none; }
.ranking-grid .card:hover { border-left-color: var(--line); box-shadow: none; }
.ranking-grid .card-header h3 { letter-spacing: 0.14em; font-weight: 700; font-size: 13px; }
.rank-no {
  width: 22px; height: 22px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; border-radius: 4px;
  flex-shrink: 0;
}

/* 响应式 */
@media (max-width: 1024px) {
  .dash-main { grid-template-columns: 1fr; }
  .dash-col-left { padding-right: 0; }
  .dash-col-right { border-left: none; padding-left: 0; padding-top: 30px; gap: 24px; }
  .kpis { flex-wrap: wrap; }
  .kpi { flex: 1 1 40%; padding: 0 18px; }
  .kpi:nth-child(3) { border-left: none; padding-left: 0; }
  .kpi + .kpi { border-left: 1px solid var(--line); }
}
@media (max-width: 768px) {
  .hero-num { font-size: 56px; }
  .kpi { flex: 1 1 50%; }
  .kpi .k-num { font-size: 34px; }
  .chart-body { gap: 14px; }
}

/* ═══════════════════════════════════════════════════════════
   全系统编辑部风 · 全局覆盖（Global Editorial Override）
   覆盖页面：工作台 / 团期 / 订单 / 分销商 / 财务 / 报表 / 经营 / 人员 / HR
   设计源：design-demos/roulette.html
   原则：直角 4px、发丝线替代阴影、墨黑 #0c0c0c、暖白纸 #faf9f6、青绿 #1f4e79 点缀
   ═══════════════════════════════════════════════════════════ */

/* —— 设计令牌 —— */
/* ============================================================
   三套主题令牌（Theme Tokens）
   风格1 编辑部浅色 light / 风格2 冷白极简 cold / 风格3 松针票券 pine
   切换方式：<html data-theme="cold|pine">；默认（无 data-theme / "light"）= 风格1
   组件层只引用令牌，不感知主题。
   ============================================================ */

/* —— 风格1 深色稳重 · 方向B（默认）—— */
:root,
:root[data-theme="light"] {
  /* 色板 —— 深蓝稳重 */
  --paper: #edf1f4;
  --paper-deep: #e2e7ec;
  --panel: #ffffff;
  --surface-muted: #e9edf1;
  --surface-hairline: #edf1f4;
  --ink: #1a2733;
  --ink-soft: #33414f;
  --muted: #5b6a7a;
  --faint: #8594a3;
  --line: #d7dfe6;
  --line-strong: #c3cdd6;
  --accent: #1f4e79;
  --accent-deep: #163a5c;
  --accent-wash: #e8eef5;
  --success: #1c7c4d;
  --success-wash: #e9f5ee;
  --warning: #b45309;
  --warning-wash: #fdf3e7;
  --danger: #c0392b;
  --danger-wash: #fbeceb;

  /* 侧边栏 —— 深墨蓝纯色（无渐变）*/
  --side-bg: #16293c;
  --side-text: rgba(226,236,245,.68);
  --side-text-hover: rgba(244,250,255,.96);
  --side-line: rgba(255,255,255,.12);
  --side-hover-bg: rgba(255,255,255,.07);
  --side-active-bg: rgba(255,255,255,.14);
  --side-active-text: #ffffff;
  --side-accent: #7fa8d4;

  /* 旧变量映射（保证基础 CSS 规则照常工作）*/
  --primary: #1f4e79;
  --primary-light: #e8eef5;
  --primary-dark: #163a5c;
  --success-light: #e9f5ee;
  --warning-light: #fdf3e7;
  --danger-light: #fbeceb;
  --bg: #edf1f4;
  --bg-card: #ffffff;
  --sidebar-bg: #16293c;
  --border: #d7dfe6;
  --border-light: #e5eaef;
  --text: #1a2733;
  --text2: #5b6a7a;
  --text3: #8594a3;
  --white: #ffffff;

  /* 字体 / 字号 / 字重 / 字距（三主题一致）*/
  --font-sans: "Archivo","HarmonyOS Sans SC",-apple-system,"PingFang SC","Microsoft YaHei",sans-serif;
  --font-mono: "SF Mono","JetBrains Mono","Cascadia Mono",Consolas,monospace;

  /* 间距 / 圆角 / 阴影 */
  --r-sm: 6px; --r: 8px; --r-pill: 999px;
  --radius: 8px; --radius-lg: 10px; --radius-sm: 6px;
  --shadow-lift: 0 8px 24px rgba(12,12,12,.10);
  --shadow-sm: none; --shadow: none;
  --shadow-lg: 0 18px 40px rgba(12,12,12,.12);
  --transition: 0.15s ease;
}

/* —— 风格2 冷白极简 —— */
:root[data-theme="cold"] {
  --paper: #f1f3f8;
  --paper-deep: #e2e7ec;
  --panel: #ffffff;
  --surface-muted: #e5eaef;
  --surface-hairline: #f5f7f9;
  --ink: #1a2733;
  --ink-soft: #33414f;
  --muted: #5b6a7a;
  --faint: #8594a3;
  --line: #d7dfe6;
  --line-strong: #c3cdd6;
  --accent: #3b5bdb;
  --accent-deep: #2e46a8;
  --accent-wash: #e8ecfb;
  --success: #12805c;
  --success-wash: #e9f5ee;
  --warning: #b45309;
  --warning-wash: #fdf3e7;
  --danger: #c0392b;
  --danger-wash: #fbeceb;

  --side-bg: #1b2440;
  --side-text: rgba(226,236,245,.68);
  --side-text-hover: rgba(244,250,255,.96);
  --side-line: rgba(255,255,255,.12);
  --side-hover-bg: rgba(255,255,255,.07);
  --side-active-bg: rgba(127,168,212,.22);
  --side-active-text: #ffffff;
  --side-accent: #8ea3f0;

  --primary: #3b5bdb;
  --primary-light: #e8ecfb;
  --primary-dark: #2e46a8;
  --success-light: #e9f5ee;
  --warning-light: #fdf3e7;
  --danger-light: #fbeceb;
  --bg: #f1f3f8;
  --bg-card: #ffffff;
  --sidebar-bg: #1b2440;
  --border: #d7dfe6;
  --border-light: #e5eaef;
  --text: #1a2733;
  --text2: #33414f;
  --text3: #5b6a7a;
  --white: #ffffff;

  --shadow-lift: 0 12px 32px rgba(17,24,39,.14);
  --shadow-lg: 0 12px 32px rgba(17,24,39,.14);
}

/* —— 风格3 松针票券 —— */
:root[data-theme="pine"] {
  --paper: #eef2ef;
  --paper-deep: #e2e7ec;
  --panel: #ffffff;
  --surface-muted: #e9edf1;
  --surface-hairline: #eef2ef;
  --ink: #1a2733;
  --ink-soft: #33414f;
  --muted: #5b6a7a;
  --faint: #8594a3;
  --line: #d7dfe6;
  --line-strong: #c3cdd6;
  --accent: #1f5f4e;
  --accent-deep: #17483a;
  --accent-wash: #e6efe9;
  --success: #1c7c4d;
  --success-wash: #e9f5ee;
  --warning: #b45309;
  --warning-wash: #fdf3e7;
  --danger: #c0392b;
  --danger-wash: #fbeceb;

  --side-bg: #14493b;
  --side-text: rgba(226,236,245,.68);
  --side-text-hover: rgba(244,250,255,.96);
  --side-line: rgba(255,255,255,.12);
  --side-hover-bg: rgba(255,255,255,.07);
  --side-active-bg: rgba(127,168,212,.22);
  --side-active-text: #ffffff;
  --side-accent: #7fb8a4;

  --primary: #1f5f4e;
  --primary-light: #e6efe9;
  --primary-dark: #17483a;
  --success-light: #e9f5ee;
  --warning-light: #fdf3e7;
  --danger-light: #fbeceb;
  --bg: #eef2ef;
  --bg-card: #ffffff;
  --sidebar-bg: #14493b;
  --border: #d7dfe6;
  --border-light: #e5eaef;
  --text: #1a2733;
  --text2: #33414f;
  --text3: #5b6a7a;
  --white: #ffffff;

  /* 深蓝稳重：统一圆角 */
  --r: 8px;
  --radius: 8px;
  --radius-lg: 10px;
  --radius-sm: 6px;
  --shadow-lift: 0 12px 32px rgba(18,42,61,.14);
  --shadow-lg: 0 12px 32px rgba(18,42,61,.14);
}

/* —— 页面底色（纸面层次：body 暖灰 / main 暖白纸 / 卡片纯白）—— */
body { background: var(--paper-deep); color: var(--ink); font-family: var(--font-sans); }
.main { background: var(--paper); }
.topbar h2 { font-weight: 800; letter-spacing: -.01em; color: var(--ink); }

/* —— 卡片 —— */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: none;
}
.card:hover { border-left-color: var(--line); box-shadow: none; }
.card-header { background: var(--panel); border-bottom: 1px solid var(--line); }
.card-header h3 { font-size: 14px; font-weight: 600; letter-spacing: 0; color: var(--ink); }

/* —— 统计卡片（KPI 大数字）—— */
.stat-card {
  background: var(--panel) !important;
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: none;
}
.stat-card::after { display: none !important; }
.stat-card::before { background: var(--line); }
.stat-card:hover { transform: none; box-shadow: none; }
.stat-card .stat-label { letter-spacing: .02em; font-weight: 600; text-transform: none; color: var(--muted); }
.stat-card .stat-value {
  font-size: 28px; font-weight: 800; letter-spacing: -.01em; line-height: 1.1;
  color: var(--ink); font-variant-numeric: tabular-nums;
}
.stat-card.kpi .stat-value { font-size: 40px; letter-spacing: -.02em; }

/* —— 表格：系统核心，全站统一 ——
   表头墨黑文字 + 发丝线底边；单元格发丝线分隔；去斑马纹；
   hover 极淡暖白 #faf9f6；直角；数字 tabular-nums */
table, .tour-table, .report-table { background: var(--panel); }
thead { background: var(--panel) !important; }
th, .tour-table th, .report-table th {
  background: var(--panel);
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: none;
  white-space: nowrap;
}
td, .tour-table td, .report-table td {
  border-bottom: 1px solid var(--border-light);
  background: var(--panel);
  color: var(--ink);
  font-size: 14px;
}
/* 去白色斑马纹 */
tr:nth-child(even) td,
.tour-table tr:nth-child(even) td,
.report-table tr:nth-child(even) td { background: var(--panel); }
/* hover 极淡表面 */
tr:hover td,
.tour-table tr:hover td,
.tour-table tr:nth-child(even):hover td,
.report-table tr:hover td,
.tour-table .row-open td { background: var(--surface-muted); }
/* 金额 / 数字：tabular-nums + Archivo（不用等宽字体） */
td.money-pos, td.money-neg, th.r, td.r,
.money-pos, .money-neg, .amount, .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1, 'lnum' 1;
  /* Archivo 缺失或不支持等宽数字时，回退到系统自带等宽字体，保证小数点始终对齐 */
  font-family: 'Archivo', 'SF Mono', 'Cascadia Mono', Consolas, 'Liberation Mono', monospace;
  letter-spacing: 0;
}
.money-pos { color: var(--success); font-weight: 600; }
.money-neg { color: var(--danger); font-weight: 600; }
.tour-no { color: var(--accent); font-weight: 700; font-variant-numeric: tabular-nums; }

/* —— 按钮 —— */
.btn {
  border-radius: var(--r); border: 1px solid var(--line-strong);
  background: var(--panel); color: var(--ink); box-shadow: none; font-weight: 600;
}
.btn:hover { background: var(--surface-muted); border-color: var(--ink); box-shadow: none; }
.btn:active { transform: none; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #ffffff; }
.btn-primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); box-shadow: none; }
.btn-outline { background: var(--panel); border-color: var(--line-strong); color: var(--ink); }
.btn-outline:hover { border-color: var(--ink); color: var(--ink); background: var(--surface-muted); }
.btn-success { background: var(--success); border-color: var(--success); color: #ffffff; }
.btn-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: var(--danger-light); border-color: var(--danger); color: var(--danger); }

/* —— 状态徽章：克制色阶（青绿 / 墨黑 / 灰）—— */
.tag {
  display: inline-block; padding: 2px 8px; border-radius: var(--r-sm);
  font-size: 12px; font-weight: 700; letter-spacing: .04em; line-height: 1.6;
  border: 1px solid transparent;
}
.tag-open { background: var(--accent-wash); color: var(--accent-deep); border-color: var(--accent-wash); }
.tag-success, .tag-completed { background: var(--success-wash); color: var(--success); border-color: var(--success-wash); }
.tag-pending, .tag-info, .tag-neutral, .tag-muted {
  background: var(--surface-muted); color: var(--muted); border-color: var(--line);
}
.tag-warning {
  background: var(--warning-wash); color: var(--warning); border-color: var(--warning-wash);
}
.tag-danger {
  background: var(--danger-wash); color: var(--danger); border-color: var(--danger-wash);
}

/* —— 筛选栏 / 工具条 —— */
.filter-bar input, .filter-bar select,
.tour-toolbar input, .tour-toolbar select,
.global-search input {
  border: 1px solid var(--line-strong); border-radius: var(--r);
  background: var(--panel); color: var(--ink); font-size: 13px;
}
.filter-bar input:focus, .filter-bar select:focus,
.tour-toolbar input:focus, .tour-toolbar select:focus,
.global-search input:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-wash);
}
.tour-toolbar { border: 1px solid var(--line); border-radius: var(--r); background: var(--panel); box-shadow: none; padding: 12px 14px; }
.tour-table-wrap { border: 1px solid var(--line); border-radius: var(--r); box-shadow: none; }
.global-search input { border-radius: var(--r); box-shadow: none; }
.segmented-control { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-muted); }
.segmented-control button { border-right: 1px solid var(--line); color: var(--muted); font-weight: 600; }
.segmented-control button.active { background: var(--accent); color: #ffffff; }

/* —— 表单 —— */
.form-group input, .form-group select, .form-group textarea {
  border: 1px solid var(--line-strong); border-radius: var(--r);
  background: var(--panel); color: var(--ink);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-wash);
}

/* —— 弹窗 —— */
.modal-mask { background: rgba(12,12,12,.42); }
.modal {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow-lift);
}
.modal-header { border-bottom: 1px solid var(--line); }
.modal-header h3 { font-weight: 800; letter-spacing: .02em; color: var(--ink); }
.modal-footer { border-top: 1px solid var(--line); }
.modal-close { border-radius: var(--r-sm); background: var(--surface-muted); color: var(--muted); }
.modal-close:hover { background: var(--danger); color: #ffffff; }

/* —— Tab —— */
.tabs { border-bottom: 1px solid var(--line); }
.tab { color: var(--muted); border-bottom: 2px solid transparent; font-weight: 600; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); border-bottom-color: var(--accent); font-weight: 700; }

/* —— 顶栏用户下拉 —— */
.user-dropdown { border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.user-dropdown:hover { background: var(--surface-muted); border-color: var(--line-strong); }
.user-avatar { background: var(--ink); color: var(--paper); }
.user-menu-popper { border-radius: var(--r); border: 1px solid var(--line); box-shadow: 0 12px 32px rgba(12,12,12,.14); }

/* —— 中性化个别彩色强调（去花哨左侧色条 / 顶部色条）—— */
.insight-card { border-left: 1px solid var(--line) !important; }
.trend-card { border-top: 1px solid var(--line); }

/* —— 空状态 —— */
.empty::before {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--r);
  background-image: none;
}
.skeleton { border-radius: var(--r); }

/* ═══════════════════════════════════════════════════════════
   反 AI-Slop 去味覆盖（Anti-AI-Slop Cleanup）
   目标：去掉「编辑部海报」式过度设计，回归 Linear / Stripe 式内敛后台
   原则：数字该大就大（这是功能），排版细节克制自然
         - 超重字 800 / 900 → 600 / 700
         - 大字母距 0.12em ~ 0.3em → 0
         - 编号眉题 / 刻度线装饰 → 关闭
         - 硬编码 #ffffff → var(--white)
   ═══════════════════════════════════════════════════════════ */

/* —— 页面标题：800 → 600 —— */
.topbar h2 { font-weight: 600; letter-spacing: 0; }

/* —— 表头：去 0.06em 字母距与 700 超重，回归自然 —— */
th,
.tour-table th,
.report-table th {
  font-weight: 600;
  letter-spacing: 0;
}

/* —— 状态徽章：去 0.04em 字母距与 700 超重 —— */
.tag {
  font-weight: 600;
  letter-spacing: 0;
}

/* —— KPI 数值：醒目靠字号，不用 900 超重字 —— */
.stat-card .stat-value {
  font-weight: 700;
  letter-spacing: -0.01em;
}
.stat-card.kpi .stat-value {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* —— 弹窗标题：800 → 600，去 0.02em 字母距 —— */
.modal-header h3 { font-weight: 600; letter-spacing: 0; }

/* —— Tab 激活态：700 → 600 —— */
.tab.active { font-weight: 600; }

/* —— 按钮 / 选中态反白文字：硬编码 #ffffff → var(--white) —— */
.btn-primary,
.btn-success,
.btn-danger,
.segmented-control button.active { color: var(--white); }
.modal-close:hover { color: var(--white); }

/* —— 趋势卡小字：900 → 600，去负字距 —— */
.trend-card .card-body > div > div > div:first-child {
  font-weight: 600;
  letter-spacing: 0;
}

/* ═══════════════════════════════════════════════════════════
   工作台 Dashboard · 去「编辑部巨型大字」风
   ═══════════════════════════════════════════════════════════ */

/* 眉题：去 uppercase + 0.3em 大字母距 + 刻度线装饰 */
.dash-hero .overline {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--muted);
  text-transform: none;
  gap: 8px;
}
.dash-hero .overline .tick { display: none; }
.dash-hero .overline .en {
  color: var(--faint);
  font-weight: 500;
  letter-spacing: 0;
}

/* 巨型营收数字：保留大字号（功能），900 → 700、负字距收紧 */
.hero-num {
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.05;
  font-size: clamp(40px, 5vw, 72px);
}
.hero-num .cur { font-weight: 600; letter-spacing: 0; }

/* 次级 KPI 标签：去 0.16em / 0.2em 大字母距 */
.kpi .k-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--muted);
}
.kpi .k-label .en { color: var(--faint); font-weight: 500; letter-spacing: 0; }

/* 次级 KPI 数字：46px / 900 → 32px / 700 */
.kpi .k-num {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.1;
}
.kpi .k-num small { font-size: 16px; font-weight: 600; letter-spacing: 0; }

/* 节标题：关闭编号眉题（01 / 02 / 03），去 0.14em 字母距 */
.sec-head .idx,
.chart-head .idx { display: none; }
.sec-head { gap: 0; }
.sec-head .t {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--ink);
}
.sec-head .line { flex: 1; height: 1px; background: var(--line); margin-left: 12px; }

/* 今日提醒标签：描边编辑部风 → 克制徽章 */
.rem-tag {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  border-radius: 4px;
  border: none;
}
.rem-tag.depart { background: var(--accent-wash); color: var(--accent-deep); }
.rem-tag.return { background: var(--surface-muted); color: var(--muted); }
.rem-code { font-size: 16px; font-weight: 700; letter-spacing: 0; }
.rem-side .n { font-size: 14px; font-weight: 600; }
.rem-row:hover { background: var(--surface-muted); padding-left: 0; }

/* 待办卡：34px / 900 → 28px / 700，去 0.16em 字母距 */
.todo .t-num { font-size: 28px; font-weight: 700; letter-spacing: -0.01em; }
.todo .t-lbl { font-size: 12px; font-weight: 600; letter-spacing: 0; }

/* 收客趋势：去 0.14em 字母距、柱值 800 → 600 */
.chart-head .t { font-size: 13px; font-weight: 600; letter-spacing: 0; }
.bar-val { font-size: 12px; font-weight: 600; letter-spacing: 0; }
.bar-col.hot .bar-val { font-weight: 600; }

/* 排行榜标题：去 0.14em 字母距 */
.ranking-grid .card-header h3 { letter-spacing: 0; font-weight: 600; font-size: 13px; }

/* ══════════════════════════════════════
   侧边栏导航 · Linear 风格线性图标 + 克制选中态
   替换彩色圆点 .nav-icon-dot → 单色内联 SVG（stroke=currentColor）
   ══════════════════════════════════════ */
.nav-item {
  position: relative;
  gap: 11px;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
}

/* 图标容器：18px，SVG 颜色跟随文字 currentColor（限定 .nav-menu，避免误伤移动端 .nav-icon 圆点）*/
.nav-menu .nav-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.nav-menu .nav-icon svg {
  width: 18px;
  height: 18px;
  display: block;
}

/* 彩色菜单图标（海洋色系）：每个菜单各有颜色，SVG stroke=currentColor 跟随 */
.nav-dashboard .nav-icon { color: #7fa8d4; }
.nav-tours .nav-icon { color: #38bdf8; }
.nav-orders .nav-icon { color: #7fa8d4; }
.nav-customers .nav-icon { color: #fbbf24; }
.nav-resources .nav-icon { color: #60a5fa; }
.nav-finances .nav-icon { color: #34d399; }
.nav-bank .nav-icon { color: #818cf8; }
.nav-commission .nav-icon { color: #fb923c; }
.nav-reports .nav-icon { color: #94a3b8; }
.nav-operations .nav-icon { color: #f472b6; }
.nav-users .nav-icon { color: #a78bfa; }
.nav-private .nav-icon { color: #f87171; }

/* hover / 选中：图标提亮，保持色相；选中态仍靠左侧指示条+背景表达 */
.nav-item:hover .nav-icon,
.nav-item.active .nav-icon {
  filter: brightness(1.32) saturate(1.15);
}

/* 选中态：左侧 2px 圆角指示条（主题强调色），背景沿用 --side-active-bg */
.nav-item.active::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 2px;
  height: 16px;
  border-radius: 999px;
  background: var(--side-accent);
}

/* ═══════════════════════════════════════════════════════════
   层次与节奏打磨 · Linear / Stripe 式内敛后台
   目标：解决「所有区块都长一样」——标题区 / 数据区 / 操作区分明，
        留白作构图，表格精细层次，状态徽章克制可读
   原则：引用主题 token，不新增 AI 指纹（无渐变卡 / 左彩边 / 编号眉题 / 超重字+大字母距）
   ═══════════════════════════════════════════════════════════ */

/* ── 顶栏 · 标题 + 副标题分层，操作区靠右 ── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
  padding: 0 0 2px;
}
.topbar-titles {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.topbar h2.page-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
  color: var(--ink);
}
.page-subtitle {
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
  line-height: 1.2;
}
.topbar-right { display: flex; align-items: center; gap: 10px; position: relative; }

.topbar-search { position: relative; }
.topbar-search svg {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  color: var(--muted);
  pointer-events: none;
}
.topbar-search input {
  width: 230px;
  padding: 8px 12px 8px 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  font-family: var(--font-sans);
  transition: border-color .15s ease, box-shadow .15s ease, width .18s ease;
}
.topbar-search input::placeholder { color: var(--faint); }
.topbar-search input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-wash);
  width: 270px;
}
.topbar-icon-btn {
  position: relative;
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.topbar-icon-btn:hover { background: var(--surface-muted); border-color: var(--ink); }
.topbar-icon-btn svg { width: 17px; height: 17px; }
.notif-dot {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: var(--r-pill);
  background: var(--danger);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 17px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* 用户下拉 · 去胶囊，改克制矩形，与操作区同节奏 */
.user-dropdown {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 4px 10px 4px 5px;
  border-radius: var(--r);
  background: var(--panel);
  border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.user-dropdown:hover { background: var(--surface-muted); border-color: var(--line-strong); }
.user-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.user-meta { display: flex; flex-direction: column; line-height: 1.2; }
.user-display { font-size: 13px; font-weight: 600; color: var(--ink); }
.user-role { font-size: 11px; color: var(--muted); }
.user-arrow { font-size: 10px; color: var(--muted); margin-left: 1px; transition: transform .15s ease; }
.user-dropdown:hover .user-arrow { transform: rotate(180deg); }

/* ── 工作台 · 层次节奏：营收主视觉（无框留白）→ KPI 次级卡 → 提醒/待办 → 图表 ── */
.dashboard-page { display: flex; flex-direction: column; gap: 22px; }

/* 主视觉 · 营收（primary：无卡片外壳，靠字重与留白构成主次）*/
.dash-hero {
  padding: 4px 2px 0;
  margin-bottom: 0;
}
.dash-hero-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}
.dash-hero .overline {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--muted);
  display: block;
  text-transform: none;
}
.hero-num {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-top: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--ink);
  font-size: clamp(42px, 4.5vw, 56px);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.hero-num .cur {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1;
  margin-top: 0.3em;
  color: var(--accent);
}
.hero-num .frac { color: var(--ink); }
.hero-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 0;
}
.hero-meta .cap { font-size: 13px; color: var(--muted); }
.hero-meta .cap b { color: var(--ink); font-weight: 600; }
.meta-sep { width: 1px; height: 14px; background: var(--line-strong); }

/* 次级 KPI · 卡片网格，主指标（利润）以微底色领先 */
.kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-top: 0;
  padding-top: 0;
  border: none;
  background: none;
  overflow: visible;
}
.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 18px 20px;
  min-width: 0;
}
.kpi:first-child { padding-left: 20px; }
.kpi .k-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--muted);
  white-space: nowrap;
  display: block;
}
.kpi .k-num {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin-top: 10px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.kpi .k-num small { font-size: 15px; font-weight: 600; letter-spacing: 0; color: var(--muted); }
.kpi .k-sub {
  margin-top: 7px;
  font-size: 12px;
  color: var(--faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kpi-lead { background: var(--accent-wash); border-color: #d5e1ee; }
.kpi-lead .k-num { font-size: 28px; color: var(--accent-deep); }

/* 提醒 · 待办 · 双栏卡（操作区，比数据区更紧凑）*/
.dash-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 14px;
  align-items: start;
}
.dash-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 18px 20px;
  min-width: 0;
}
.sec-head { display: flex; align-items: center; margin-bottom: 4px; }
.sec-head .t { font-size: 13px; font-weight: 600; letter-spacing: 0; color: var(--ink); }

.reminder { display: flex; flex-direction: column; }
.rem-row {
  display: flex;
  align-items: center;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background .15s ease;
}
.rem-row:hover { padding-left: 0; background: var(--surface-hairline); }
.rem-row:last-child { border-bottom: none; padding-bottom: 2px; }
.rem-tag {
  flex: 0 0 auto;
  width: 44px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  border-radius: var(--r-sm);
  border: none;
}
.rem-tag.depart { background: var(--accent-wash); color: var(--accent-deep); }
.rem-tag.return { background: var(--surface-muted); color: var(--muted); }
.rem-main { flex: 1; padding-left: 14px; min-width: 0; }
.rem-code { font-size: 15px; font-weight: 700; letter-spacing: 0; color: var(--ink); line-height: 1.2; font-variant-numeric: tabular-nums; }
.rem-dest { margin-top: 3px; font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rem-side { flex: 0 0 auto; text-align: right; }
.rem-side .n { font-size: 13px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.rem-empty { padding: 14px 0; font-size: 13px; color: var(--faint); }

/* 航线签名：去程 ● → 返程 ○ */
.rem-route {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 12px;
  margin-right: 2px;
}
.rem-route .rd { width: 7px; height: 7px; border-radius: 50%; }
.rem-route .rd.on { background: var(--accent); }
.rem-route .rd.off { border: 1.5px solid var(--faint); background: transparent; }
.rem-route .rl { width: 1.5px; height: 12px; background: var(--line-strong); }

.todos { display: flex; gap: 12px; }
.todo {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.todo:hover { border-color: var(--accent); background: var(--surface-hairline); }
.todo .t-num { font-size: 24px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); line-height: 1; font-variant-numeric: tabular-nums; }
.todo .t-lbl { margin-top: 7px; font-size: 12px; font-weight: 600; letter-spacing: 0; color: var(--muted); }
.todo .t-lbl .dot { color: var(--accent); margin-right: 5px; }

/* 收客趋势 · 卡（与上方区块同外壳，内部为可视化）*/
.chart-band {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 18px 22px 16px;
  margin-bottom: 0;
}
.chart-head { display: flex; align-items: baseline; justify-content: space-between; }
.chart-head .l { display: flex; align-items: center; }
.chart-head .t { font-size: 13px; font-weight: 600; letter-spacing: 0; color: var(--ink); }
.chart-body {
  display: flex;
  align-items: flex-end;
  gap: 26px;
  height: 108px;
  margin-top: 16px;
  position: relative;
}
.chart-body::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--line);
}
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.bar-val { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: 0; margin-bottom: 7px; font-variant-numeric: tabular-nums; }
.bar { width: 100%; max-width: 56px; background: color-mix(in srgb, var(--accent) 34%, transparent); border-radius: var(--r-sm) var(--r-sm) 0 0; min-height: 4px; }
.bar.hot { background: var(--accent); }
.bar-col.hot .bar-val { color: var(--accent-deep); font-weight: 700; }
.bar-day { margin-top: 9px; font-size: 12px; color: var(--faint); }
.bar-col.hot .bar-day { color: var(--ink); font-weight: 600; }

/* ── 表格 · 精细层次：表头 muted 小字 + 发丝线，行密度适中 ── */
th,
.tour-table th,
.report-table th {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--muted);
  border-bottom: 1px solid var(--line-strong);
  background: var(--panel);
  padding: 10px 14px;
}
td,
.tour-table td,
.report-table td {
  font-size: 14px;
  padding: 10px 14px;
  line-height: 1.55;
  border-bottom: 1px solid var(--border-light);
}

/* 列表更紧凑的间距 + 横向列宽均匀（像汇旅通那样，行距窄、列距整齐） */
.tour-table th,
.tour-table td,
.order-list-table th,
.order-list-table td {
  padding: 4px 8px;
}
.tour-table th,
.order-list-table th {
  white-space: nowrap;
}
.tour-table,
.order-list-table {
  table-layout: fixed;
  width: 100%;
}
/* 团期列表 12 列：团号/线路/出发/天/类型/成人价/机位/确认/预留/余位/状态/计调，均衡排列 */
.tour-table th:nth-child(1) { width: 11%; }
.tour-table th:nth-child(2) { width: 17%; }
.tour-table th:nth-child(3) { width: 10%; }
.tour-table th:nth-child(4) { width: 4%; }
.tour-table th:nth-child(5) { width: 6%; }
.tour-table th:nth-child(6) { width: 9%; }
.tour-table th:nth-child(7) { width: 6%; }
.tour-table th:nth-child(8) { width: 6%; }
.tour-table th:nth-child(9) { width: 6%; }
.tour-table th:nth-child(10) { width: 6%; }
.tour-table th:nth-child(11) { width: 8%; }
.tour-table th:nth-child(12) { width: 11%; }
/* 订单列表·销售视图（12 列，含备注，无操作列）：格子感均匀列宽 */
.order-list-table.order-grid th:nth-child(1) { width: 7%; }   /* 团号 */
.order-list-table.order-grid th:nth-child(2) { width: 12%; }  /* 线路 */
.order-list-table.order-grid th:nth-child(3) { width: 8%; }   /* 出发日 */
.order-list-table.order-grid th:nth-child(4) { width: 10%; }  /* 分销商(含联系人) */
.order-list-table.order-grid th:nth-child(5) { width: 6%; }   /* 销售 */
.order-list-table.order-grid th:nth-child(6) { width: 5%; }   /* 人数 */
.order-list-table.order-grid th:nth-child(7) { width: 8%; }   /* 已录名单 */
.order-list-table.order-grid th:nth-child(8) { width: 8.5%; } /* 应收款 */
.order-list-table.order-grid th:nth-child(9) { width: 8.5%; } /* 已收款 */
.order-list-table.order-grid th:nth-child(10) { width: 8.5%; } /* 未收款 */
.order-list-table.order-grid th:nth-child(11) { width: 9.5%; } /* 备注 */
.order-list-table.order-grid th:nth-child(12) { width: 8.5%; } /* 状态 */
/* 订单列表·管理视图（11 列，无备注，无操作列） */
.order-list-table.order-grid-12 th:nth-child(1) { width: 8%; }   /* 团号 */
.order-list-table.order-grid-12 th:nth-child(2) { width: 14%; }  /* 线路 */
.order-list-table.order-grid-12 th:nth-child(3) { width: 8%; }   /* 出发日 */
.order-list-table.order-grid-12 th:nth-child(4) { width: 12%; }  /* 分销商(含联系人) */
.order-list-table.order-grid-12 th:nth-child(5) { width: 7%; }   /* 销售 */
.order-list-table.order-grid-12 th:nth-child(6) { width: 6%; }   /* 人数 */
.order-list-table.order-grid-12 th:nth-child(7) { width: 8%; }   /* 已录名单 */
.order-list-table.order-grid-12 th:nth-child(8) { width: 9.5%; } /* 应收款 */
.order-list-table.order-grid-12 th:nth-child(9) { width: 9.5%; } /* 已收款 */
.order-list-table.order-grid-12 th:nth-child(10) { width: 9.5%; } /* 未收款 */
.order-list-table.order-grid-12 th:nth-child(11) { width: 8.5%; } /* 状态 */
/* 订单列表·旅客护照名单（11 列：证件图片/姓名/拼音名/性别/出生日期/证件号/有效期/国籍/订单号/订单归属/状态） */
.order-list-table.order-grid-passport th:nth-child(1) { width: 8%; }   /* 证件图片 */
.order-list-table.order-grid-passport th:nth-child(2) { width: 9%; }   /* 旅客姓名 */
.order-list-table.order-grid-passport th:nth-child(3) { width: 9%; }   /* 拼音名 */
.order-list-table.order-grid-passport th:nth-child(4) { width: 5%; }   /* 性别 */
.order-list-table.order-grid-passport th:nth-child(5) { width: 8%; }   /* 出生日期 */
.order-list-table.order-grid-passport th:nth-child(6) { width: 11%; }  /* 证件号 */
.order-list-table.order-grid-passport th:nth-child(7) { width: 8%; }   /* 有效期至 */
.order-list-table.order-grid-passport th:nth-child(8) { width: 7%; }   /* 国籍 */
.order-list-table.order-grid-passport th:nth-child(9) { width: 9%; }   /* 订单号 */
.order-list-table.order-grid-passport th:nth-child(10) { width: 9%; }  /* 订单归属 */
.order-list-table.order-grid-passport th:nth-child(11) { width: 8%; }  /* 状态 */
/* 长文本截断，避免撑破列宽 */
.tour-table td,
.order-list-table td {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 团期列表：每行卡片化（每个团期独立框感，像分开的卡片） */
.tour-table {
  border-collapse: separate;
  border-spacing: 0 6px;
}
.tour-table th {
  background: #f5f7f9 !important;
  padding: 8px 10px !important;
  border-bottom: 1px solid var(--line-strong) !important;
}
.tour-table tbody tr {
  background: #fff;
  box-shadow: 0 1px 2px rgba(15,23,42,.05), 0 1px 3px rgba(15,23,42,.04);
  transition: box-shadow .15s;
}
.tour-table tbody tr:hover { box-shadow: 0 3px 8px rgba(15,23,42,.08); }
.tour-table tbody td { border-bottom: none !important; }
.tour-table td:first-child { border-radius: 8px 0 0 8px; }
.tour-table td:last-child { border-radius: 0 8px 8px 0; }
.tour-table .row-open td, .tour-table .row-open td:first-child, .tour-table .row-open td:last-child { background: var(--accent-wash); }

/* ── 团期卡片 · 扫视增强（v2）──
   整行可点：给明确的指针与按压反馈；鼠标停留时在行首加品牌色"定位条"，计调一眼能看出在看哪一行 */
.tour-table tbody tr.clickable { cursor: pointer; }
.tour-table tbody tr:active,
.tour-table tbody tr.clickable:active td { background: var(--accent-wash); }
.tour-table tbody tr:active { box-shadow: 0 1px 2px rgba(15,23,42,.14); }
/* 定位引导条：仅 hover 显示，不影响布局宽度 */
.tour-table tbody tr.clickable:hover td:first-child { box-shadow: inset 3px 0 0 var(--primary); }

/* ── 团期卡片 · 响应式（v3）──
   12 列固定宽度在小屏会挤压破版：给表格一个保底宽度，外层横向滚动而非压扁 */
.tour-table-wrap { overflow-x: auto; }
.tour-table { min-width: 980px; }

/* ── 报名订单列表 · 固定列宽 + 备注列（v1）──
   普通 table 原由内容撑宽，导致「谢珊珊」这类短内容行显得很空。
   改用 table-layout:fixed + 明确列宽占比，均匀紧凑；备注列单独收窄并截断，hover 看全。 */
.bookings-table {
  table-layout: fixed;
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}
.bookings-table th,
.bookings-table td {
  padding: 8px 10px;
  vertical-align: middle;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bookings-table th { background: #f5f7f9; color: #60737a; font-weight: 600; border-bottom: 1px solid var(--line-strong); }
/* 列宽占比：客户/销售/备注/状态用固定宽，金额列右对齐 */
.bookings-table th:nth-child(1) { width: 12%; }  /* 客户 */
.bookings-table th:nth-child(2) { width: 9%; }   /* 销售 */
.bookings-table th:nth-child(3) { width: 6%; }   /* 人数 */
.bookings-table th:nth-child(4) { width: 9%; }   /* 单价 */
.bookings-table th:nth-child(5) { width: 10%; }  /* 应收款 */
.bookings-table th:nth-child(6) { width: 10%; }  /* 已收款 */
.bookings-table th:nth-child(7) { width: 10%; }  /* 未收款 */
.bookings-table th:nth-child(8) { width: 22%; }  /* 备注 */
.bookings-table th:nth-child(9) { width: 7%; }   /* 状态 */
.bookings-table th:nth-child(10) { width: auto; }/* 操作（按钮多，弹性） */
.bookings-table td.bk-notes { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bookings-table tbody tr:nth-child(even) td { background: #fafbfc; }
.bookings-table tbody tr:hover td { background: #f2f6f9; }
/* 操作列：按钮多、不截断，靠外层横向滚动 */
.bookings-table td:last-child { white-space: nowrap; overflow: visible; }
/* 外层横向滚动：窄屏时操作列/长内容可滑动，不挤破 */
.bookings-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-sm); }
.bookings-table-wrap .bookings-table { min-width: 860px; }

/* ── 状态徽章 · 克制四阶：绿(正常/已确认) / 灰(暂停/待定) / 琥珀(满位/警示) / 红(取消/逾期) ──
   .tag-open 保持品牌青绿，兼顾「正常收客」状态与通用类型标签（跟团/角色/科目等）*/
.tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.6;
  border: 1px solid transparent;
  white-space: nowrap;
}
.tag-open,
.tag-departed { background: var(--accent-wash); color: var(--accent-deep); border-color: var(--accent-wash); }
.tag-success,
.tag-completed,
.tag-confirmed,
.tag-paid { background: var(--success-wash); color: var(--success); border-color: var(--success-wash); }
.tag-pending,
.tag-info,
.tag-neutral,
.tag-muted,
.tag-reserved,
.tag-cancelled { background: var(--surface-muted); color: var(--muted); border-color: var(--line); }
.tag-warning,
.tag-paused,
.tag-reserved_full { background: var(--warning-wash); color: var(--warning); border-color: var(--warning-wash); }
.tag-danger,
.tag-full { background: var(--danger-wash); color: var(--danger); border-color: var(--danger-wash); }

/* 团期列表 · 机位余位徽章（绿=充足 / 黄=紧张 / 红=满 / 灰=未配置） */
.seat-pill { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 13px; font-weight: 700; line-height: 1.6; white-space: nowrap; }
.pill-success { background: var(--success-wash); color: var(--success); }
.pill-warning { background: var(--warning-wash); color: var(--warning); }
.pill-danger { background: var(--danger-wash); color: var(--danger); }
.pill-neutral { background: var(--surface-muted); color: var(--muted); }

/* 团期列表 · 线路主/次信息 + 类型标签 + 机位小字 + 日期等宽 */
.line-title { font-weight: 600; }
.line-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.type-tag { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--muted); background: var(--surface-muted); white-space: nowrap; }
.seat-sub { font-size: 12px; color: var(--muted); margin-top: 3px; white-space: nowrap; }
.seat-line { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.seat-meta { font-size: 12px; color: var(--muted); }
.tour-meta-line { display: flex; align-items: center; justify-content: flex-end; gap: 7px; white-space: nowrap; }
.price-num { font-weight: 600; }
.tour-date { font-variant-numeric: tabular-nums; white-space: nowrap; }
.holiday-tag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: 12px; font-weight: 700; color: #fff; background: #e6482e; white-space: nowrap; vertical-align: middle; }

/* 表格内联空状态（统一样式） */
.empty-inline { text-align: center; color: var(--muted); font-size: 13px; padding: 20px; }

/* 记账明细弹窗 · 纵向键值列表（label 左 / value 右对齐） */
.detail-list { display: flex; flex-direction: column; }
.detail-row { display: flex; align-items: baseline; justify-content: space-between; padding: 10px 2px; border-bottom: 1px solid var(--border-light); }
.detail-row:last-child { border-bottom: none; }
.detail-row .dt { flex: 0 0 72px; font-size: 13px; color: var(--muted); }
.detail-row .dd { flex: 1; font-size: 14px; font-weight: 600; color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; }

/* ── 响应式 ── */
@media (max-width: 1024px) {
  .dash-grid { grid-template-columns: 1fr; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 768px) {
  .topbar { flex-wrap: wrap; gap: 12px; }
  .topbar-titles { flex: 1 1 auto; }
  .topbar h2.page-title { font-size: 18px; }
  .topbar-right { flex: 1 1 100%; }
  .topbar-search { flex: 1; }
  .topbar-search input { width: 100%; }
  .page-subtitle { display: none; }
  .dash-hero-head { flex-direction: column; align-items: flex-start; gap: 8px; margin-bottom: 12px; }
  .hero-num { font-size: 40px; }
  .kpis { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kpi { padding: 14px 14px; }
  .kpi:first-child { padding-left: 14px; }
  .kpi .k-num { font-size: 22px; }
  .kpi-lead .k-num { font-size: 24px; }
  .dash-grid { gap: 10px; }
  .chart-body { gap: 14px; }
}

/* ═══════════════════════════════════════════════════════════
   列表页筛选栏 / 工具条 与 表单弹窗 · 统一打磨
   目标：多页筛选栏与表单弹窗视觉统一，克制、紧凑、可读
   原则：引用主题 token（--panel/--line/--ink/--muted/--accent 等），
         focus 用强调色描边 + wash 光晕，错误态清晰，
         筛选栏靠留白与表格分隔（无生硬边框），信息密度优先
   ═══════════════════════════════════════════════════════════ */

/* ── 1. 筛选栏 / 工具条容器：去卡片外壳，靠留白与表格分隔 ── */
.filter-bar,
.tour-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}
.tour-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  width: 100%;
}

/* ── 2. 筛选控件：统一尺寸 / 圆角 / 边框 / 字体 ── */
.filter-bar input,
.filter-bar select,
.tour-toolbar input,
.tour-toolbar select {
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  font-family: var(--font-sans);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.filter-bar input::placeholder,
.tour-toolbar input::placeholder {
  color: var(--faint);
}
.filter-bar input:hover,
.filter-bar select:hover,
.tour-toolbar input:hover,
.tour-toolbar select:hover {
  border-color: var(--faint);
}
.filter-bar input:focus,
.filter-bar select:focus,
.tour-toolbar input:focus,
.tour-toolbar select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-wash);
}
.filter-bar input[type="date"],
.tour-toolbar input[type="date"] {
  padding-right: 8px;
}
/* 筛选栏内按钮与输入框等高 */
.filter-bar .btn,
.tour-toolbar .btn {
  height: 34px;
  padding: 0 14px;
  font-size: 13px;
}
/* 状态分段控件对齐 */
.segmented-control {
  height: 34px;
  align-self: center;
}
.segmented-control button {
  min-height: 32px;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
}
.segmented-control button.active {
  background: var(--accent);
  color: #fff;
}

/* ── 3. 弹窗：标题 / 内容 / 底部按钮分层，footer 固定 body 滚动 ── */
.modal-mask {
  background: rgba(12,12,12,.46);
}
.modal {
  display: flex;
  flex-direction: column;
  max-height: 86vh;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lift);
}
.modal-lg { max-width: 760px; }
.modal-header {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
}
.modal-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--ink);
}
.modal-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 20px;
}
.modal-footer {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: var(--panel);
}
/* 订单列表·可点击行 hover/active + 展开高亮（与团期管理一致的交互） */
.order-list-table tbody tr.clickable { cursor: pointer; }
.order-list-table tbody tr.clickable:hover td { background: var(--accent-wash); }
.order-list-table tbody tr.clickable:active td { background: var(--accent-wash); }
.order-list-table tbody tr.clickable:hover td:first-child { box-shadow: inset 3px 0 0 var(--primary); }
.order-list-table tbody tr.row-open td { background: var(--accent-wash); }
.order-list-table tbody tr.row-open:hover td { background: var(--accent-wash); }
.modal-close {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.modal-close:hover {
  background: var(--danger);
  color: #fff;
}

/* ── 4. 表单控件：默认 / hover / focus / placeholder / 错误态 ── */
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--ink);
}
.form-group label .req {
  color: var(--danger);
  margin-left: 2px;
}
.form-group input,
.form-group select {
  width: 100%;
  height: 36px;
  padding: 0 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  font-family: var(--font-sans);
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.form-group textarea {
  width: 100%;
  min-height: 72px;
  padding: 9px 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  font-family: var(--font-sans);
  line-height: 1.5;
  resize: vertical;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--faint);
}
.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
  border-color: var(--faint);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-wash);
}
.form-group input:disabled,
.form-group select:disabled,
.form-group textarea:disabled {
  background: var(--surface-muted);
  color: var(--faint);
  cursor: not-allowed;
}
/* 错误态：危险色描边 + wash 光晕，提示文字带圆点 */
.form-group input.error,
.form-group select.error,
.form-group textarea.error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px var(--danger-wash);
}
.form-error {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 5px;
  font-size: 12px;
  color: var(--danger);
}
.form-error::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--danger);
  flex-shrink: 0;
}

/* ── 5. 表单网格：两列自适应，full 跨整行 ── */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  column-gap: 16px;
  row-gap: 0;
}
.form-group.full {
  grid-column: 1 / -1;
}

/* ── 6. 按钮：主/次/危险统一尺寸，主操作在右（footer 已 flex-end）── */
.btn {
  height: 34px;
  padding: 0 14px;
  border-radius: var(--r);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1;
}
.btn-sm {
  height: 26px;
  padding: 0 10px;
  font-size: 12px;
}
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); box-shadow: none; }
.btn-outline { background: var(--panel); border-color: var(--line-strong); color: var(--ink); }
.btn-outline:hover { background: var(--surface-muted); border-color: var(--ink); color: var(--ink); }
.btn-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: var(--danger-light); border-color: var(--danger); color: var(--danger); }
.btn-success { background: var(--success); border-color: var(--success); color: #fff; }

/* ── 7. 详情描述网格（团期详情弹窗）── */
.desc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px 20px;
}
.desc-item { min-width: 0; }
.desc-label {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 3px;
}
.desc-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

/* ── 响应式：窄屏筛选控件自适应、弹窗贴边 ── */
@media (max-width: 768px) {
  .filter-bar input,
  .filter-bar select,
  .tour-toolbar input,
  .tour-toolbar select {
    flex: 1 1 120px;
  }
  .form-grid { grid-template-columns: 1fr; }
  .modal { max-width: 100%; border-radius: var(--r); }
}

/* ═══════════════════════════════════════════════════════════
   工作台 · 排行榜（销售双维度 / 收客 / 昨日线路）
   设计：销售排行单独整行，其余两榜另起一行，用发丝线 + 留白拉开层次。
         每种数据按性质选表达，减少条状、形成节奏——
           销售额=排名榜单 + 右侧大号金额（前三突出，无条轨，占比给显式数字）
           销售收客=纯数字榜单（人数为锚点，靠字号层次）
           收客排行=名字为主（计数收为次要信息，行内克制）
           昨日线路=横向条形（唯一保留的条，目的地对比合理）+ 清晰数值
   要点：排名数字仅前三强调、金额/人数 tabular-nums 等宽对齐、
         禁彩色徽章 / 斑马纹 / 渐变，全部引用主题 token。
   ═══════════════════════════════════════════════════════════ */
.rank-band {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 24px 26px 26px;
  margin-bottom: 0;
}
.rank-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 22px;
}
.rank-head .t {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--ink);
}
.rank-head .sub {
  font-size: 12px;
  color: var(--faint);
}

/* 销售排行：占满整行，与下方两榜用发丝线 + 大间距分隔 */
.rank-group-sales {
  padding-bottom: 26px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.rank-group-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
}
.rank-group-head .t {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--ink);
}
.rank-sub-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 44px;
}

/* 第二行：收客 / 线路 两列，用留白分隔；仅一行时自动占满 */
.rank-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  column-gap: 44px;
  row-gap: 28px;
}
.rank-col { min-width: 0; }
.rank-col-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 12px;
}
.rank-col-head .t {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--ink);
}
.rank-col-head .hint {
  font-size: 11px;
  color: var(--faint);
}

/* 榜单行：排名 / 姓名 / 数值 三级层次 */
.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.rank-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.rank-item:last-child { border-bottom: none; padding-bottom: 2px; }
.r-no {
  flex: 0 0 20px;
  font-size: 13px;
  font-weight: 700;
  color: var(--faint);
  text-align: left;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.rank-item.top .r-no { color: var(--accent-deep); }
.r-name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.r-val {
  flex: 0 0 auto;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* 占比：以显式数字替代条轨，等宽右对齐，克制淡色 */
.r-share {
  flex: 0 0 auto;
  min-width: 34px;
  font-size: 11px;
  color: var(--faint);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* 销售额：大号金额为锚点，前三名金额强调（无条轨） */
.r-val-money {
  flex: 0 0 auto;
  min-width: 80px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.rank-item.top .r-val-money { color: var(--accent-deep); }

/* 纯数字榜单（销售·收客人数）：大数字为锚点，靠字号层级而非条轨 */
.r-val-big {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.r-val-big small {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}
.r-val-big em {
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  margin-left: 7px;
}
/* 名字为主（收客排行）：计数收为次要信息，行内克制 */
.r-val-inline {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.r-val-inline small {
  font-size: 11px;
  font-weight: 500;
  color: var(--faint);
}
.r-val-inline em {
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  margin-left: 7px;
}

/* 昨日线路 · 横向条形（唯一保留的条，目的地对比） */
.route-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}
.route-name {
  flex: 0 0 72px;
  font-size: 13px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.route-track {
  flex: 1 1 auto;
  height: 7px;
  background: var(--surface-muted);
  border-radius: var(--r-pill);
  overflow: hidden;
}
.route-track i {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: inherit;
  min-width: 3px;
}
.route-num {
  flex: 0 0 auto;
  min-width: 38px;
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 2px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.route-num small {
  font-size: 11px;
  font-weight: 500;
  color: var(--faint);
}

@media (max-width: 1024px) {
  .rank-band { padding: 18px 16px 20px; }
  .rank-sub-cols { grid-template-columns: 1fr; column-gap: 0; }
  .rank-sub-cols .rank-col + .rank-col {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
  }
  .rank-cols { grid-template-columns: 1fr; row-gap: 24px; }
}

/* ═══════════════════════════════════════════════════════════
   图表改造 · 收客排行横向柱状 + 昨日线路环形图
   原则：引用主题 token，单色阶（无彩虹/无渐变），数字 tabular-nums，
         前三强调色、其余中性色；环形图小占比合并「其他」。
   ═══════════════════════════════════════════════════════════ */

/* —— 环形图单色阶（随三主题，品牌色明度递降；1=最大扇区）—— */
:root,
:root[data-theme="light"] {
  --chart-1: #1f4e79;
  --chart-2: #2f6a9e;
  --chart-3: #4a88bd;
  --chart-4: #6ba3d0;
  --chart-5: #8fbcdd;
  --chart-6: #b3d2e8;
  --chart-7: #cfe3f0;
  --chart-8: #e6eef6;
}
:root[data-theme="cold"] {
  --chart-1: #1f4e79;
  --chart-2: #5570e0;
  --chart-3: #7389e6;
  --chart-4: #94a4ec;
  --chart-5: #b3bef1;
  --chart-6: #ccd5f5;
  --chart-7: #dee4f8;
  --chart-8: #eaeefa;
}
:root[data-theme="pine"] {
  --chart-1: #1f4e79;
  --chart-2: #39766a;
  --chart-3: #568d82;
  --chart-4: #77a69d;
  --chart-5: #9bbdb6;
  --chart-6: #bcd3ce;
  --chart-7: #d3e2de;
  --chart-8: #e4eeeb;
}

/* —— 收客排行 · 横向柱状 —— */
.agent-chart { display: flex; flex-direction: column; }
.agent-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}
.agent-name {
  flex: 0 0 88px;
  min-width: 0;
  font-size: 13px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.agent-track {
  flex: 1 1 auto;
  height: 18px;
  background: var(--surface-muted);
  border-radius: var(--r-sm);
  overflow: hidden;
}
.agent-bar {
  display: block;
  height: 100%;
  min-width: 3px;
  background: color-mix(in srgb, var(--accent) 34%, transparent);
  border-radius: inherit;
  transition: width .3s ease;
}
.agent-row.top .agent-bar { background: var(--accent); }
.agent-num {
  flex: 0 0 auto;
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.agent-num small { font-size: 11px; font-weight: 500; color: var(--muted); }
.agent-num em {
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  margin-left: 6px;
}

/* —— 昨日线路 · 环形图 + 图例 —— */
.donut-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
}
.donut-chart {
  position: relative;
  flex: 0 0 auto;
  width: 340px;
  max-width: 100%;
  aspect-ratio: 1 / 1;
}
.donut { width: 100%; height: 100%; display: block; }
.donut-bg { stroke: var(--surface-muted); }
.donut-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  pointer-events: none;
}
.donut-num {
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.donut-unit { font-size: 14px; color: var(--faint); }
.donut-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
  max-width: 340px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.donut-legend li {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.lg-swatch {
  flex: 0 0 12px;
  width: 12px;
  height: 12px;
  border-radius: 3px;
}
.lg-name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 16px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lg-val {
  flex: 0 0 auto;
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.lg-val small { font-size: 13px; font-weight: 500; color: var(--muted); }
.lg-val em {
  font-style: normal;
  font-size: 13px;
  font-weight: 500;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  margin-left: 6px;
}

@media (max-width: 768px) {
  .donut-wrap { align-items: center; }
  .donut-chart { margin: 0 auto; }
}

/* 复制团期 · 勾选日历 */
.copy-cal { border: 1px solid var(--line); border-radius: 8px; padding: 12px; background: var(--panel); }
.copy-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.copy-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.copy-cal-wd { text-align: center; font-size: 12px; color: var(--muted); padding: 4px 0; }
.copy-cal-day { text-align: center; padding: 9px 0; border-radius: 6px; cursor: pointer; font-size: 13px; color: var(--ink); transition: background .12s ease; }
.copy-cal-day:hover { background: var(--surface-muted); }
.copy-cal-day.sel { background: var(--accent); color: #fff; font-weight: 600; }
.copy-cal-day.blank { cursor: default; }
.copy-cal-day.blank:hover { background: none; }

/* 团期分页 */
.tour-pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 4px; font-size: 13px; }
.tour-pagination select { min-width: 56px; }

/* 团队结算单 · 一张表分上下两块（收入 / 成本） */
/* ===== 团队结算表（印刷风格）===== */
.settle-table { width: 100%; border-collapse: collapse; font-size: 13px; background: #fff; }
.settle-table th, .settle-table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--border-light); }
.settle-table .r { text-align: right; font-variant-numeric: tabular-nums; }
/* 表格内金额等宽，整体更接近打印排版 */
.settle-table td.r, .settle-table th.r { font-family: -apple-system, 'SF Mono', 'JetBrains Mono', monospace; }
/* 列宽规整：金额/人数数字列收窄右对齐，文本列放宽，避免列宽不均 */
.settle-table { table-layout: auto; }
.settle-table th, .settle-table td { white-space: nowrap; }
.settle-table td.r, .settle-table th.r { width: 13%; min-width: 96px; }

/* 单据签字/盖章区 */
.settle-sign {
  margin-top: 26px; padding-top: 14px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
  font-size: 13px; color: var(--ink);
}
.settle-sign .sig-box { text-align: center; }
.settle-sign .sig-label { font-size: 12px; color: var(--text3); letter-spacing: 1px; }
.settle-sign .sig-line { margin-top: 22px; border-bottom: 1px solid var(--ink-soft); }
.settle-stamp {
  margin-top: 16px; display: flex; justify-content: space-between; align-items: center;
}
.settle-stamp .stamp {
  width: 120px; height: 120px; border: 3px solid #c0392b; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; text-align: center;
  color: #c0392b; font-weight: 800; font-size: 13px; line-height: 1.5; letter-spacing: 3px;
  transform: rotate(-6deg); opacity: .85;
}

/* ============================================================
   团队结算单 · v3 设计系统
   设计依据：ui-ux-pro-max 评审（数据密集财务表格 · 克制专业）
     · 金额统一等宽 + tabular-nums 右对齐
     · 状态统一胶囊标签 + 语义圆点（替代纯色块）
     · 分区行左侧色条 + 可旋转箭头（替代 ▾/▸ 文字）
     · 软边框、浅底分区条，去掉重网格线
     · ≤760px 整表堆叠，每个数值由 td[data-k] 自带列标签
   放在 main.css 末尾，靠顺序覆盖上面的“印刷风格”旧规则。

   ⚠️ 本项目两条硬约定（2026-09-11 与 WorkBuddy 复核后固化，勿再动）：

   一、任何针对 th / td 的自定义样式【必须带 !important】
       原因：第 4215 行起有一条【裸 th】规则（th, .tour-table th, .report-table th），
       六条属性带 !important（font-size / font-weight / letter-spacing /
       text-transform / color / background），第 4227 行起还有对应的裸 td
       （border-bottom: … !important）。非 !important 的规则一律压不过它。

   二、裸 th / 裸 td 服务于全站 78 张无类表格，【禁止给它加作用域】
       实测 index.html 共 80 张 <table>，其中带 tour-table 的只有 2 张、
       带 report-table 的 0 张 —— 那条裸 th 是其余 78 张表唯一的表头样式来源。
       若改成 .tour-table th, .report-table th，78 张表会一次性丢掉表头样式
       （font-size / color / background / border-bottom），回退到旧打印配色。
       要彻底解耦，只能给需要自定义的表加基础类（.ds-table）再逐一覆盖，
       属跨 80 张表的重构，收益低于风险，当前不做。
   ============================================================ */

/* ---------- 表格骨架 ---------- */
.settle-table { font-size: 13px; border-collapse: collapse; }
.settle-table th, .settle-table td { padding: 9px 12px; vertical-align: top; }
/* 表头行。
   两个坑必须一起绕开：
   1) 这个 table 里写了 5 个 <thead>，HTML 解析器只保留前 2 个，后 3 个被丢弃并塞进隐式 <tbody>，
      所以「地接/酒店/其它成本」的表头行不在 thead 里 —— 不能只用 thead 后代选择器，改用 .settle-head 类；
   2) 文件上半部分有一条未加作用域的 th{ ... !important }（约 4215 行），
      非 !important 的规则一律压不过它，这里必须同级 !important。 */
.settle-table thead th,
.settle-table tr.settle-head th {
  background: #f7f9fb !important; color: var(--text2) !important;
  font-size: 13px !important; font-weight: 600 !important;
  letter-spacing: .04em !important; text-transform: none !important;
  padding: 7px 12px !important; border-bottom: 1px solid var(--border) !important;
}
.settle-table tbody tr > td { border-bottom: 1px solid var(--border-light); }
.settle-table tbody tr:last-child > td { border-bottom: 0; }

/* 数字列：等宽 + 表格数字 */
.settle-table td.r { font-family: var(--font-mono); font-size: 13px; color: var(--text2); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.settle-table th.r { font-variant-numeric: tabular-nums; }

/* 分区标题条：浅底 + 左侧主题色竖条（原为整条深蓝，视觉噪音大）
   同样需要 !important 才压得过全局 th 规则 */
.settle-table .settle-section th {
  background: #eef3f8 !important; color: var(--primary) !important;
  font-weight: 700 !important; font-size: 12px !important;
  letter-spacing: .08em !important; text-transform: none !important;
  padding: 8px 12px !important; border-bottom: 1px solid var(--border) !important;
  border-left: 3px solid var(--primary);
}
/* 小计行 */
.settle-table .settle-subtotal td {
  background: #f7f9fb; color: var(--text2); font-weight: 600;
  border-top: 1px solid var(--border-light); border-bottom: 1px solid var(--border-light);
}
.settle-table .settle-subtotal td.r { color: var(--text); font-weight: 700; }
/* 总计行（毛利） */
.settle-table .settle-total td {
  background: var(--primary-light); font-weight: 800; font-size: 14px;
  border-top: 2px solid var(--primary); border-bottom: 0;
}

/* ---------- 状态胶囊：语义圆点 ---------- */
.settle-table .tag {
  display: inline-flex; align-items: center; gap: 5px; padding: 1px 9px;
  border-radius: 999px; border: 1px solid transparent;
  font-size: 12px; font-weight: 600; line-height: 1.75; white-space: nowrap;
}
.settle-table .tag::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.settle-table .tag-success { background: var(--success-light); color: var(--success); border-color: rgba(28,124,77,.2); }
.settle-table .tag-warning { background: var(--warning-light); color: var(--warning); border-color: rgba(180,83,9,.2); }
.settle-table .tag-pending { background: #eef1f4; color: var(--text3); border-color: var(--border-light); }

/* ---------- 行内操作按钮：统一小胶囊 ---------- */
.settle-table .btn-sm { padding: 2px 10px; font-size: 12px; line-height: 1.75; border-radius: 999px; }

/* ---------- 弹窗顶部动作按钮：图标 + 文字对齐 ---------- */
.settle-acts .btn { display: inline-flex; align-items: center; gap: 6px; }
.settle-acts .btn svg { flex: 0 0 auto; }

/* ---------- 总览：标题/毛利率/KPI 卡片 ---------- */
.settle-overview-meta { padding: 8px 0 10px; margin-bottom: 10px; border-bottom: 2px solid var(--primary); color: var(--text3); font-size: 12px; }
.settle-overview-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 10px; }
.settle-overview-kpi {
  min-width: 0; padding: 10px 12px; background: #fff; border: 1px solid var(--border-light);
  border-left: 3px solid var(--primary); border-radius: var(--radius-sm);
}
.settle-overview-kpi:nth-child(2) { border-left-color: var(--warning); }
.settle-overview-kpi:nth-child(3) { border-left-color: var(--success); }
.settle-overview-kpi-label { color: var(--text3); font-size: 12px; letter-spacing: .04em; line-height: 1.4; }
.settle-overview-kpi-value {
  margin-top: 3px; color: var(--text); font-family: var(--font-mono); font-size: 18px;
  font-weight: 700; line-height: 1.3; font-variant-numeric: tabular-nums; letter-spacing: -.01em;
}
.settle-overview-profit {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 9px 12px; margin-bottom: 10px; background: var(--primary-light);
  border-left: 3px solid var(--primary); border-radius: var(--radius-sm);
}
.settle-overview-profit-main { font-size: 12px; color: var(--text2); }
.settle-overview-profit-main b { display: block; margin-top: 2px; font-size: 22px; line-height: 1.2; }
.settle-overview-profit-side { color: var(--text2); font-size: 12px; line-height: 1.7; text-align: right; }

/* ---------- 总览：分区汇总 ---------- */
.settle-overview-groups { margin-bottom: 0; }
.settle-overview-group-row { cursor: pointer; }
.settle-overview-group-row > td { padding-top: 9px; padding-bottom: 9px; }
.settle-overview-group-row:hover > td { background: #f7f9fb; }
.settle-overview-group-row.disabled { cursor: default; }
.settle-overview-group-row.disabled:hover > td { background: transparent; }
.settle-overview-group-row > td:nth-child(2) { font-weight: 600; color: var(--text); }
.settle-overview-group-row.disabled > td:nth-child(2) { font-weight: 500; color: var(--text3); }
/* 每行左侧色条：区分收入/大交通/地接/酒店/其它 */
.settle-overview-group-row > td:first-child { border-left: 3px solid var(--border); }
.settle-overview-group-row.grp-signup > td:first-child { border-left-color: var(--success); }
.settle-overview-group-row.grp-transport > td:first-child { border-left-color: #2f6fb0; }
.settle-overview-group-row.grp-ground > td:first-child { border-left-color: #7a5cad; }
.settle-overview-group-row.grp-hotel > td:first-child { border-left-color: var(--warning); }
.settle-overview-group-row.grp-other > td:first-child { border-left-color: #8a97a4; }
.settle-overview-group-row.disabled > td:first-child { border-left-color: var(--border-light); }
.settle-caret { width: 42px; text-align: center; color: var(--text3); }
.settle-caret svg { display: block; margin: 0 auto; transition: transform .16s ease; }
.settle-caret svg.open { transform: rotate(90deg); }
.settle-cnt { color: var(--text3); font-size: 12px; }
.settle-cnt::after { content: ' 笔'; font-size: 11px; }
/* 展开的明细区 */
.settle-table .settle-overview-detail > td { padding: 0; background: #fbfcfd; }
.settle-overview-detail .settle-table { margin: 0; font-size: 12px; background: transparent; }
.settle-overview-detail .settle-table th, .settle-overview-detail .settle-table td { padding: 6px 10px; }

/* ---------- 窄屏：整表堆叠，数值自带列标签 ---------- */
@media (max-width: 760px) {
  .settle-overview-kpis { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; }
  .settle-overview-profit { align-items: flex-start; flex-direction: column; }
  .settle-overview-profit-side { text-align: left; }

  .settle-table { display: block; width: 100%; max-width: 100%; }
  .settle-table thead, .settle-table tbody, .settle-table tfoot,
  .settle-table tr, .settle-table td, .settle-table th {
    display: block; width: auto !important; max-width: 100% !important;
  }
  /* 列头行隐藏（数值由 td[data-k] 自带标签），分区条保留。
     .settle-head 覆盖被解析器丢进隐式 tbody 的那几个表头行 */
  .settle-table thead tr:not(.settle-section),
  .settle-table tr.settle-head { display: none; }
  .settle-table td, .settle-table th { white-space: normal; border-bottom: 0; padding: 3px 0; }
  .settle-table tbody > tr {
    padding: 9px 11px; margin-bottom: 8px; background: #fff;
    border: 1px solid var(--border-light); border-radius: var(--radius-sm);
  }
  .settle-table tbody > tr:last-child { margin-bottom: 0; }
  .settle-table .settle-section th { border-radius: var(--radius-sm); margin-bottom: 8px; }

  /* 数值单元格：左列标签 + 右值（用悬挂缩进，续行与数值左边缘对齐。
     不能用 flex：单元格里的裸文本与「备注」span 会各自成为 flex item 互相抢宽，
     导致「机票」被压成一列一个字） */
  .settle-table td[data-k] { display: block; padding-left: 68px; text-indent: -68px; }
  /* text-indent 会被后代块容器继承（胶囊/按钮也是块容器），必须逐层清零，
     否则胶囊里的文字会被整体左移压到标签上 */
  .settle-table td[data-k] * { text-indent: 0; }
  .settle-table td[data-k]::before {
    content: attr(data-k); display: inline-block; min-width: 60px; margin-right: 8px;
    text-indent: 0; color: var(--text3); font-size: 11px; font-weight: 500; vertical-align: baseline;
  }
  .settle-table td.r { text-align: left; }

  /* 小计/总计在窄屏不再用底色块，靠字重区分（全局 td 规则里 border-bottom 带 !important，需同级覆盖） */
  .settle-table .settle-subtotal td, .settle-table .settle-total td {
    background: transparent !important; border: 0 !important; padding: 4px 0 !important;
  }
  /* 基础信息/团队毛利这类「标签|值」表：窄屏去掉左侧灰底标签块 */
  .settle-table td[style*="background:#fafbfc"] {
    background: transparent !important; color: var(--text3);
    font-weight: 500 !important; font-size: 11px;
  }
  /* 标签|值 表窄屏排两列，而不是一行一个 */
  .settle-table.settle-kv tbody > tr {
    display: grid; grid-template-columns: 88px minmax(0, 1fr);
    column-gap: 10px; row-gap: 1px; align-items: baseline;
  }
  .settle-table.settle-kv tbody > tr > td { padding: 2px 0; }
  .settle-table.settle-kv tbody > tr > td[colspan] { grid-column: 1 / -1; }
  .settle-table .settle-subtotal td:first-child, .settle-table .settle-total td:first-child {
    color: var(--text3); font-size: 12px; font-weight: 500;
  }

  .settle-overview-detail > td { padding: 0; background: transparent; }
  .settle-overview-detail .settle-table tbody > tr { background: #fff; }

  /* 分区汇总行：网格两行，名称/笔数 + 金额/待处理 */
  .settle-overview-groups .settle-overview-group-row {
    display: grid; grid-template-columns: 30px minmax(0, 1fr) auto;
    grid-template-areas: "caret name count" "caret amount due";
    align-items: center; column-gap: 8px; row-gap: 2px;
  }
  .settle-overview-groups .settle-overview-group-row > td { padding: 0; border-bottom: 0; background: transparent; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(1) { grid-area: caret; align-self: stretch; display: flex; align-items: center; justify-content: center; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(2) { grid-area: name; font-size: 13px; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(3) { grid-area: count; text-align: right; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(4) { grid-area: amount; text-align: right; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(5) { grid-area: due; text-align: right; font-size: 12px; }
  /* 第二行两个金额在窄屏没有表头，用静态标签点明含义 */
  .settle-overview-groups .settle-overview-group-row > td:nth-child(4)::before { content: '金额'; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(5)::before { content: '待处理'; }
  .settle-overview-groups .settle-overview-group-row > td:nth-child(4)::before,
  .settle-overview-groups .settle-overview-group-row > td:nth-child(5)::before {
    margin-right: 5px; color: var(--text3); font-size: 11px; font-weight: 500;
  }
}

/* ===== 打印样式（从窄屏媒体查询拆出，桌面打印生效）===== */
@media print {
  body { background: #fff; font-size: 12px; color: #000; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  .card-header { background: #f5f5f5; border-bottom: 2px solid #333; }
  table { font-size: 11px; }
  th { font-size: 11px; color: #000; background: #eee; border-bottom: 2px solid #333; }
  td { border-bottom: 1px solid #ddd; }
  .stat-card { box-shadow: none; border: 1px solid #ccc; }
  @page { margin: 1.5cm; }
}

/* ===== W3：Vue 挂载前不渲染任何弹窗遮罩（修复登录页首屏黑闪） ===== */
/* 未挂载时 .modal-mask 是普通 div，会被 .modal-mask 的 display:flex 画成全屏遮罩盖住登录页；
   加 .vue-ready 标记后（mounted 里加），Vue 已接管，此规则失效，遮罩恢复 display:flex */
html:not(.vue-ready) .modal-mask { display: none !important; }

/* ============================================================
   批次 G3-1（14 组）+ G3-2（2 组）：老 token → 新 token 别名
   G3-1：14 组在三套主题下取值完全相同 → 视觉零变化。
   G3-2：原 3 组，现 2 组。--text2 / --border-light 老值 ≠ 新值，
        兵哥已确认接受「变浅一档」。
        --text3 已于同批复核后回滚：松针/冷白下财务总账 71 处 11px 小字
        对比度 5.54:1 → 3.11:1，低于 WCAG AA 的 4.5:1；浅色下 --text3 本就
        等于 --faint，回滚无任何影响。故此处不再声明 --text3。
   ⚠ 选择器（关键）：必须与主题块同特异性(0,2,0)。单独用 :root 是 (0,1,0)，
      会被 :root[data-theme="x"](0,2,0) 压过 → 别名不生效（G3-1 v1 的 bug）。
      故 :root 与各 data-theme 一并列出，靠源顺序（本块在文件最末）取胜。
   回滚：删掉这个块即可。
   ============================================================ */
:root,
:root[data-theme="light"],
:root[data-theme="cold"],
:root[data-theme="pine"] {
  /* --- G3-1：14 组（零视觉变化） --- */
  --primary: var(--accent);
  --primary-light: var(--accent-wash);
  --primary-dark: var(--accent-deep);
  --text: var(--ink);
  --border: var(--line);
  --bg: var(--paper);
  --bg-card: var(--panel);
  --white: var(--panel);
  --success-light: var(--success-wash);
  --warning-light: var(--warning-wash);
  --danger-light: var(--danger-wash);
  --sidebar-bg: var(--side-bg);
  --radius: var(--r);
  --radius-sm: var(--r-sm);
  /* --- G3-2：2 组（变浅；--text3 因对比度未达标已回滚） --- */
  --text2: var(--muted);
  --border-light: var(--surface-hairline);
}
