/* ============================================
   律所案件管理系统 - 主样式文件
   色调：深蓝(#1a2332) + 金色(#c9a96e)
   字体：Noto Serif SC（思源宋体）作为标题字体
   ============================================ */

/* --- CSS 变量定义 --- */
:root {
  --primary-dark: #1a2332;
  --primary-dark-light: #243044;
  --primary-dark-lighter: #2d3a4f;
  --primary-gold: #c9a96e;
  --primary-gold-light: #d4b97e;
  --primary-gold-dark: #b8944f;
  --primary-gold-bg: rgba(201, 169, 110, 0.08);
  --primary-gold-border: rgba(201, 169, 110, 0.3);
  --bg-main: #f0f2f5;
  --bg-card: #ffffff;
  --bg-sidebar: #141c28;
  --bg-sidebar-hover: #1e2a3a;
  --bg-sidebar-active: rgba(201, 169, 110, 0.12);
  --text-primary: #1a2332;
  --text-secondary: #5a6a7e;
  --text-muted: #8a96a6;
  --text-light: #b0b8c4;
  --text-white: #ffffff;
  --text-gold: #c9a96e;
  --border-color: #e2e6ec;
  --border-light: #eef0f4;
  --shadow-sm: 0 1px 3px rgba(26, 35, 50, 0.06);
  --shadow-md: 0 4px 12px rgba(26, 35, 50, 0.08);
  --shadow-lg: 0 8px 30px rgba(26, 35, 50, 0.12);
  --shadow-xl: 0 16px 48px rgba(26, 35, 50, 0.16);
  --shadow-gold: 0 4px 16px rgba(201, 169, 110, 0.25);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --sidebar-width: 260px;
  --sidebar-collapsed-width: 72px;
  --header-height: 64px;
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-slow: 0.4s ease;

  /* 状态颜色 */
  --status-pending: #e6a23c;
  --status-pending-bg: #fdf6ec;
  --status-assigned: #409eff;
  --status-assigned-bg: #ecf5ff;
  --status-progress: #3b82f6;
  --status-progress-bg: #eff6ff;
  --status-trial: #8b5cf6;
  --status-trial-bg: #f5f3ff;
  --status-closed: #67c23a;
  --status-closed-bg: #f0f9eb;
  --status-archived: #909399;
  --status-archived-bg: #f4f4f5;
  --status-suspended: #f56c6c;
  --status-suspended-bg: #fef0f0;

  /* 字体 */
  --font-serif: 'Noto Serif SC', 'Source Han Serif SC', 'SimSun', serif;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
}

/* --- 全局重置 --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--bg-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: var(--primary-gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--primary-gold-dark);
}

/* --- 滚动条美化 --- */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--text-light);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ============================================
   登录页面
   ============================================ */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary-dark) 0%, #0f1720 50%, #1a2a3a 100%);
  position: relative;
  overflow: hidden;
}

.login-page::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 30% 50%, rgba(201, 169, 110, 0.06) 0%, transparent 60%),
              radial-gradient(ellipse at 70% 20%, rgba(201, 169, 110, 0.04) 0%, transparent 50%);
  animation: loginBgPulse 8s ease-in-out infinite alternate;
}

@keyframes loginBgPulse {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-2%, 1%) scale(1.05); }
}

.login-page::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23c9a96e' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.login-container {
  position: relative;
  z-index: 1;
  width: 420px;
  max-width: 90vw;
  animation: loginFadeIn 0.8s ease;
}

@keyframes loginFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.login-card {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(201, 169, 110, 0.15);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  box-shadow: var(--shadow-xl);
}

.login-logo {
  text-align: center;
  margin-bottom: 36px;
}

.login-logo .logo-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--primary-dark);
  box-shadow: var(--shadow-gold);
}

.login-logo h1 {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-white);
  letter-spacing: 4px;
  margin-bottom: 6px;
}

.login-logo p {
  font-size: 12px;
  color: var(--text-light);
  letter-spacing: 2px;
  text-transform: uppercase;
}

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

.login-form .form-group label {
  display: block;
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 8px;
  font-weight: 500;
}

.login-form .input-wrapper {
  position: relative;
}

.login-form .input-wrapper i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
  transition: color var(--transition-fast);
}

.login-form .form-input {
  width: 100%;
  height: 46px;
  padding: 0 14px 0 42px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--text-white);
  font-size: 14px;
  transition: all var(--transition-fast);
  outline: none;
}

.login-form .form-input:focus {
  border-color: var(--primary-gold);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.login-form .form-input:focus + i,
.login-form .form-input:focus ~ i {
  color: var(--primary-gold);
}

.login-form .form-input::placeholder {
  color: var(--text-muted);
}

.login-form select.form-input {
  appearance: none;
  cursor: pointer;
}

.login-form select.form-input option {
  background: var(--primary-dark);
  color: var(--text-white);
}

.login-btn {
  width: 100%;
  height: 46px;
  background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
  color: var(--primary-dark);
  border: none;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all var(--transition-normal);
  margin-top: 8px;
  position: relative;
  overflow: hidden;
}

.login-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
}

.login-btn:active {
  transform: translateY(0);
}

.login-btn .btn-loading {
  display: none;
}

.login-btn.loading .btn-text {
  visibility: hidden;
}

.login-btn.loading .btn-loading {
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.login-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 12px;
  color: var(--text-muted);
}

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

/* --- 左侧导航栏 --- */
.sidebar {
  width: var(--sidebar-width);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  background: var(--bg-sidebar);
  z-index: 100;
  display: flex;
  flex-direction: column;
  transition: width var(--transition-normal);
  overflow: hidden;
}

.sidebar-header {
  padding: 24px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-logo .logo-mark {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--primary-dark);
  flex-shrink: 0;
}

.sidebar-logo .logo-text {
  overflow: hidden;
  white-space: nowrap;
}

.sidebar-logo .logo-text h2 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-white);
  letter-spacing: 2px;
  line-height: 1.3;
}

.sidebar-logo .logo-text span {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 1px;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  overflow-y: auto;
}

.nav-section {
  margin-bottom: 8px;
}

.nav-section-title {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 8px 12px 6px;
  white-space: nowrap;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  color: var(--text-light);
  cursor: pointer;
  transition: all var(--transition-fast);
  margin-bottom: 2px;
  white-space: nowrap;
  position: relative;
}

.nav-item:hover {
  background: var(--bg-sidebar-hover);
  color: var(--text-white);
}

.nav-item.active {
  background: var(--bg-sidebar-active);
  color: var(--primary-gold);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 20px;
  background: var(--primary-gold);
  border-radius: 0 3px 3px 0;
}

.nav-item i {
  width: 20px;
  text-align: center;
  font-size: 15px;
  flex-shrink: 0;
}

.nav-item span {
  font-size: 13px;
  font-weight: 500;
}

.nav-item .nav-badge {
  margin-left: auto;
  background: var(--primary-gold);
  color: var(--primary-dark);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.sidebar-user:hover {
  background: var(--bg-sidebar-hover);
}

.sidebar-user .user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.sidebar-user .user-info {
  overflow: hidden;
}

.sidebar-user .user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-white);
  white-space: nowrap;
}

.sidebar-user .user-role {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
}

/* --- 主内容区 --- */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  transition: margin-left var(--transition-normal);
}

/* --- 顶部栏 --- */
.top-header {
  height: var(--header-height);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 50;
}

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

.header-left .page-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
}

.header-left .breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
}

.header-left .breadcrumb a {
  color: var(--text-secondary);
}

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

.header-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
}

.header-btn:hover {
  border-color: var(--primary-gold-border);
  color: var(--primary-gold);
  background: var(--primary-gold-bg);
}

.header-btn .badge-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 7px;
  height: 7px;
  background: #f56c6c;
  border-radius: 50%;
  border: 2px solid var(--bg-card);
}

/* --- 页面内容容器 --- */
.page-content {
  padding: 28px;
  animation: pageFadeIn 0.35s ease;
}

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   仪表盘
   ============================================ */
.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.stat-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.stat-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.stat-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-gold), var(--primary-gold-light));
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.stat-card:hover::after {
  opacity: 1;
}

.stat-card .stat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.stat-card .stat-label {
  font-size: 13px;
  color: var(--text-secondary);
  font-weight: 500;
}

.stat-card .stat-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.stat-card .stat-icon.blue {
  background: #eff6ff;
  color: #3b82f6;
}
.stat-card .stat-icon.gold {
  background: var(--primary-gold-bg);
  color: var(--primary-gold);
}
.stat-card .stat-icon.green {
  background: #f0f9eb;
  color: #67c23a;
}
.stat-card .stat-icon.purple {
  background: #f5f3ff;
  color: #8b5cf6;
}
.stat-card .stat-icon.red {
  background: #fef0f0;
  color: #f56c6c;
}

.stat-card .stat-value {
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 4px;
}

.stat-card .stat-value .unit {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 4px;
}

.stat-card .stat-change {
  font-size: 12px;
  color: var(--text-muted);
}

.stat-card .stat-change.up {
  color: #67c23a;
}
.stat-card .stat-change.down {
  color: #f56c6c;
}

/* 仪表盘网格 */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 24px;
}

.dashboard-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.dashboard-card .card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
}

.dashboard-card .card-header h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.dashboard-card .card-header .card-action {
  font-size: 13px;
  color: var(--primary-gold);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
}

.dashboard-card .card-body {
  padding: 0;
}

/* 快捷操作 */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  padding: 20px 24px;
}

.quick-action-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--text-primary);
}

.quick-action-btn:hover {
  border-color: var(--primary-gold-border);
  background: var(--primary-gold-bg);
  color: var(--primary-gold);
}

.quick-action-btn i {
  font-size: 16px;
  color: var(--primary-gold);
}

.quick-action-btn span {
  font-size: 13px;
  font-weight: 500;
}

/* ============================================
   表格样式
   ============================================ */
.table-container {
  overflow-x: auto;
}

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

.data-table thead th {
  background: #f8f9fb;
  padding: 12px 16px;
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
  position: sticky;
  top: 0;
}

.data-table tbody tr {
  transition: background var(--transition-fast);
  border-bottom: 1px solid var(--border-light);
}

.data-table tbody tr:hover {
  background: var(--primary-gold-bg);
}

.data-table tbody tr:nth-child(even) {
  background: #fafbfc;
}

.data-table tbody tr:nth-child(even):hover {
  background: var(--primary-gold-bg);
}

.data-table tbody td {
  padding: 14px 16px;
  font-size: 13px;
  color: var(--text-primary);
  vertical-align: middle;
}

.data-table .cell-link {
  color: var(--primary-gold);
  cursor: pointer;
  font-weight: 500;
}

.data-table .cell-link:hover {
  text-decoration: underline;
}

.data-table .cell-money {
  font-family: var(--font-serif);
  font-weight: 600;
  color: var(--text-primary);
}

/* 表格分页 */
.table-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-top: 1px solid var(--border-light);
}

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

.table-pagination .page-btns {
  display: flex;
  align-items: center;
  gap: 4px;
}

.page-btn {
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.page-btn:hover:not(.active):not(:disabled) {
  border-color: var(--primary-gold-border);
  color: var(--primary-gold);
}

.page-btn.active {
  background: var(--primary-gold);
  border-color: var(--primary-gold);
  color: var(--primary-dark);
  font-weight: 600;
}

.page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ============================================
   状态标签
   ============================================ */
.status-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}

.status-tag::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-tag.pending {
  background: var(--status-pending-bg);
  color: var(--status-pending);
}
.status-tag.pending::before { background: var(--status-pending); }

.status-tag.assigned {
  background: var(--status-assigned-bg);
  color: var(--status-assigned);
}
.status-tag.assigned::before { background: var(--status-assigned); }

.status-tag.progress {
  background: var(--status-progress-bg);
  color: var(--status-progress);
}
.status-tag.progress::before { background: var(--status-progress); }

.status-tag.trial {
  background: var(--status-trial-bg);
  color: var(--status-trial);
}
.status-tag.trial::before { background: var(--status-trial); }

.status-tag.closed {
  background: var(--status-closed-bg);
  color: var(--status-closed);
}
.status-tag.closed::before { background: var(--status-closed); }

.status-tag.archived {
  background: var(--status-archived-bg);
  color: var(--status-archived);
}
.status-tag.archived::before { background: var(--status-archived); }

.status-tag.suspended {
  background: var(--status-suspended-bg);
  color: var(--status-suspended);
}
.status-tag.suspended::before { background: var(--status-suspended); }

/* ============================================
   搜索栏 & 筛选
   ============================================ */
.search-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.search-input-group {
  position: relative;
  flex: 1;
  min-width: 240px;
}

.search-input-group i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
}

.search-input-group input {
  width: 100%;
  height: 40px;
  padding: 0 14px 0 38px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
  background: var(--bg-card);
  transition: all var(--transition-fast);
  outline: none;
}

.search-input-group input:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.filter-select {
  height: 40px;
  padding: 0 32px 0 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
  background: var(--bg-card);
  cursor: pointer;
  outline: none;
  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 fill='%235a6a7e' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  transition: all var(--transition-fast);
}

.filter-select:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

/* 状态筛选标签页 */
.filter-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--border-light);
  padding-bottom: 0;
}

.filter-tab {
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.filter-tab:hover {
  color: var(--primary-gold);
}

.filter-tab.active {
  color: var(--primary-gold);
  border-bottom-color: var(--primary-gold);
}

.filter-tab .tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--border-light);
  font-size: 11px;
  font-weight: 600;
  margin-left: 6px;
  color: var(--text-muted);
}

.filter-tab.active .tab-count {
  background: var(--primary-gold-bg);
  color: var(--primary-gold);
}

/* ============================================
   按钮样式
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
  white-space: nowrap;
  outline: none;
  line-height: 1.4;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-gold), var(--primary-gold-dark));
  color: var(--primary-dark);
  border-color: var(--primary-gold);
  font-weight: 600;
}

.btn-primary:hover {
  box-shadow: var(--shadow-gold);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0) scale(0.97);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-secondary);
  border-color: var(--border-color);
}

.btn-secondary:hover {
  border-color: var(--primary-gold-border);
  color: var(--primary-gold);
  background: var(--primary-gold-bg);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--border-light);
  color: var(--text-primary);
}

.btn-danger {
  background: #fef0f0;
  color: #f56c6c;
  border-color: #fbc4c4;
}

.btn-danger:hover {
  background: #f56c6c;
  color: white;
  border-color: #f56c6c;
}

.btn-success {
  background: #f0f9eb;
  color: #67c23a;
  border-color: #c2e7b0;
}

.btn-success:hover {
  background: #67c23a;
  color: white;
  border-color: #67c23a;
}

.btn-sm {
  padding: 5px 12px;
  font-size: 12px;
}

.btn-lg {
  padding: 12px 28px;
  font-size: 15px;
}

.btn-icon {
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: var(--radius-sm);
}

.btn-group {
  display: flex;
  gap: 6px;
}

/* ============================================
   表单样式
   ============================================ */
.form-section {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  margin-bottom: 24px;
  overflow: hidden;
}

.form-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
  background: #fafbfc;
}

.form-section-header i {
  color: var(--primary-gold);
  font-size: 16px;
}

.form-section-header h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.form-section-body {
  padding: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

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

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-group label .required {
  color: #f56c6c;
  font-size: 14px;
}

.form-control {
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
  background: var(--bg-card);
  transition: all var(--transition-fast);
  outline: none;
  font-family: var(--font-sans);
}

.form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.form-control::placeholder {
  color: var(--text-muted);
}

.form-control.error {
  border-color: #f56c6c;
  box-shadow: 0 0 0 3px rgba(245, 108, 108, 0.1);
}

.form-control:disabled {
  background: #f5f7fa;
  color: var(--text-muted);
  cursor: not-allowed;
}

textarea.form-control {
  height: auto;
  padding: 10px 12px;
  resize: vertical;
  min-height: 80px;
}

select.form-control {
  appearance: none;
  cursor: pointer;
  padding-right: 32px;
  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 fill='%235a6a7e' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.form-error {
  font-size: 12px;
  color: #f56c6c;
  margin-top: 4px;
  display: none;
}

.form-group.has-error .form-error {
  display: block;
}

.form-group.has-error .form-control {
  border-color: #f56c6c;
}

/* 表单步骤条 */
.form-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 32px;
  padding: 0 20px;
}

.step-item {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

.step-item .step-number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-card);
  transition: all var(--transition-normal);
  flex-shrink: 0;
}

.step-item .step-label {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
  white-space: nowrap;
}

.step-item.active .step-number {
  border-color: var(--primary-gold);
  background: var(--primary-gold);
  color: var(--primary-dark);
  box-shadow: var(--shadow-gold);
}

.step-item.active .step-label {
  color: var(--primary-gold);
  font-weight: 600;
}

.step-item.completed .step-number {
  border-color: var(--primary-gold);
  background: var(--primary-gold);
  color: var(--primary-dark);
}

.step-item.completed .step-label {
  color: var(--text-primary);
}

.step-connector {
  width: 60px;
  height: 2px;
  background: var(--border-color);
  margin: 0 8px;
  flex-shrink: 0;
}

.step-connector.completed {
  background: var(--primary-gold);
}

/* ============================================
   卡片样式
   ============================================ */
.info-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.info-card .card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
}

.info-card .card-header h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.info-card .card-header h3 i {
  color: var(--primary-gold);
  font-size: 16px;
}

.info-card .card-body {
  padding: 24px;
}

/* 详情信息网格 */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

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

.info-item .info-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

.info-item .info-value {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
}

.info-item .info-value.money {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--primary-gold-dark);
  font-size: 16px;
}

/* ============================================
   时间线样式
   ============================================ */
.timeline {
  position: relative;
  padding-left: 32px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 11px;
  top: 4px;
  bottom: 4px;
  width: 2px;
  background: var(--border-color);
}

.timeline-item {
  position: relative;
  padding-bottom: 28px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item .timeline-dot {
  position: absolute;
  left: -32px;
  top: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.timeline-item .timeline-dot i {
  font-size: 10px;
  color: var(--text-muted);
}

.timeline-item.completed .timeline-dot {
  border-color: var(--primary-gold);
  background: var(--primary-gold);
}

.timeline-item.completed .timeline-dot i {
  color: var(--primary-dark);
}

.timeline-item.current .timeline-dot {
  border-color: var(--primary-gold);
  background: var(--bg-card);
  box-shadow: 0 0 0 4px var(--primary-gold-bg);
}

.timeline-item.current .timeline-dot i {
  color: var(--primary-gold);
}

.timeline-item .timeline-content {
  padding-left: 8px;
}

.timeline-item .timeline-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.timeline-item .timeline-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.timeline-item .timeline-date {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ============================================
   Modal 弹窗
   ============================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26, 35, 50, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 560px;
  max-width: 90vw;
  max-height: 85vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: scale(0.95) translateY(10px);
  transition: transform var(--transition-normal);
}

.modal-overlay.active .modal {
  transform: scale(1) translateY(0);
}

.modal-lg {
  width: 720px;
}

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

.modal-header h3 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: var(--border-light);
  color: var(--text-primary);
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

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

/* ============================================
   Toast 通知
   ============================================ */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  box-shadow: var(--shadow-lg);
  border-left: 4px solid;
  min-width: 300px;
  max-width: 420px;
  animation: toastSlideIn 0.3s ease;
  transition: all var(--transition-normal);
}

.toast.removing {
  animation: toastSlideOut 0.3s ease forwards;
}

@keyframes toastSlideIn {
  from { opacity: 0; transform: translateX(100%); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastSlideOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(100%); }
}

.toast.success {
  border-left-color: #67c23a;
}
.toast.success i {
  color: #67c23a;
}

.toast.error {
  border-left-color: #f56c6c;
}
.toast.error i {
  color: #f56c6c;
}

.toast.warning {
  border-left-color: #e6a23c;
}
.toast.warning i {
  color: #e6a23c;
}

.toast.info {
  border-left-color: #409eff;
}
.toast.info i {
  color: #409eff;
}

.toast .toast-content {
  flex: 1;
}

.toast .toast-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.toast .toast-message {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.toast .toast-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  font-size: 14px;
  transition: color var(--transition-fast);
}

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

/* ============================================
   确认对话框
   ============================================ */
.confirm-dialog .modal {
  width: 420px;
}

.confirm-dialog .confirm-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 16px;
}

.confirm-dialog .confirm-icon.warning {
  background: #fdf6ec;
  color: #e6a23c;
}

.confirm-dialog .confirm-icon.danger {
  background: #fef0f0;
  color: #f56c6c;
}

.confirm-dialog .confirm-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.confirm-dialog .confirm-message {
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
}

/* ============================================
   多选人员选择器
   ============================================ */
.multi-select {
  position: relative;
}

.multi-select .select-trigger {
  min-height: 40px;
  padding: 4px 32px 4px 8px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  cursor: pointer;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  transition: all var(--transition-fast);
  position: relative;
}

.multi-select .select-trigger:hover {
  border-color: var(--primary-gold-border);
}

.multi-select .select-trigger.open {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.multi-select .select-trigger::after {
  content: '\f107';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 12px;
  pointer-events: none;
}

.multi-select .select-trigger .placeholder {
  color: var(--text-muted);
  font-size: 13px;
}

.multi-select .select-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: var(--primary-gold-bg);
  border: 1px solid var(--primary-gold-border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--primary-gold-dark);
}

.multi-select .select-tag .tag-remove {
  cursor: pointer;
  font-size: 10px;
  color: var(--primary-gold);
  transition: color var(--transition-fast);
}

.multi-select .select-tag .tag-remove:hover {
  color: #f56c6c;
}

.multi-select .select-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  z-index: 60;
  max-height: 200px;
  overflow-y: auto;
  display: none;
}

.multi-select .select-dropdown.open {
  display: block;
  animation: dropdownFadeIn 0.15s ease;
}

@keyframes dropdownFadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.multi-select .select-option {
  padding: 8px 12px;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background var(--transition-fast);
}

.multi-select .select-option:hover {
  background: var(--primary-gold-bg);
}

.multi-select .select-option.selected {
  color: var(--primary-gold);
  font-weight: 500;
}

.multi-select .select-option .checkbox {
  width: 16px;
  height: 16px;
  border: 2px solid var(--border-color);
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  transition: all var(--transition-fast);
}

.multi-select .select-option.selected .checkbox {
  background: var(--primary-gold);
  border-color: var(--primary-gold);
  color: var(--primary-dark);
}

/* ============================================
   提成管理
   ============================================ */
.commission-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.commission-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.commission-card .commission-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.commission-card .commission-value {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-gold-dark);
}

.commission-card .commission-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ============================================
   报表中心
   ============================================ */
.report-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.report-preview {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.report-preview .report-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px;
  border-bottom: 2px solid var(--primary-dark);
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-dark-light));
  color: var(--text-white);
}

.report-preview .report-header h2 {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 2px;
}

.report-preview .report-header .report-period {
  font-size: 13px;
  color: var(--primary-gold-light);
}

.report-preview .report-body {
  padding: 24px;
}

.report-preview .report-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-light);
  text-align: right;
  font-size: 12px;
  color: var(--text-muted);
}

/* ============================================
   系统管理
   ============================================ */
.system-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 4px;
  border: 1px solid var(--border-light);
}

.system-tab {
  flex: 1;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: var(--radius-sm);
  text-align: center;
  transition: all var(--transition-fast);
}

.system-tab:hover {
  color: var(--text-primary);
  background: var(--border-light);
}

.system-tab.active {
  background: var(--primary-gold);
  color: var(--primary-dark);
  font-weight: 600;
}

/* 操作日志 */
.log-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}

.log-item:last-child {
  border-bottom: none;
}

.log-item .log-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}

.log-item .log-icon.create {
  background: #ecf5ff;
  color: #409eff;
}
.log-item .log-icon.update {
  background: #f0f9eb;
  color: #67c23a;
}
.log-item .log-icon.delete {
  background: #fef0f0;
  color: #f56c6c;
}
.log-item .log-icon.system {
  background: #f5f3ff;
  color: #8b5cf6;
}

.log-item .log-content {
  flex: 1;
}

.log-item .log-text {
  font-size: 13px;
  color: var(--text-primary);
}

.log-item .log-text strong {
  color: var(--primary-gold-dark);
}

.log-item .log-time {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ============================================
   空状态
   ============================================ */
.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-state i {
  font-size: 48px;
  color: var(--text-light);
  margin-bottom: 16px;
}

.empty-state h3 {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================
   加载状态
   ============================================ */
.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border-color);
  border-top-color: var(--primary-gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* 骨架屏 */
.skeleton {
  background: linear-gradient(90deg, var(--border-light) 25%, #e8ecf0 50%, var(--border-light) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.5s ease-in-out infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeletonShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ============================================
   收款明细动态行
   ============================================ */
.payment-rows {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.payment-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 10px;
  padding: 10px 12px;
  align-items: center;
  border-bottom: 1px solid var(--border-light);
}

.payment-row:last-child {
  border-bottom: none;
}

.payment-row .form-control {
  height: 36px;
  font-size: 12px;
}

.payment-row .remove-row-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.payment-row .remove-row-btn:hover {
  background: #fef0f0;
  color: #f56c6c;
}

.add-row-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--primary-gold);
  cursor: pointer;
  border: 1px dashed var(--primary-gold-border);
  border-radius: var(--radius-md);
  background: transparent;
  transition: all var(--transition-fast);
}

.add-row-btn:hover {
  background: var(--primary-gold-bg);
  border-color: var(--primary-gold);
}

/* ============================================
   页面工具栏
   ============================================ */
.page-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-toolbar .toolbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.page-toolbar .toolbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ============================================
   详情页操作栏
   ============================================ */
.detail-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

/* ============================================
   响应式布局
   ============================================ */
@media (max-width: 1200px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 992px) {
  .sidebar {
    width: var(--sidebar-collapsed-width);
  }
  .sidebar .logo-text,
  .sidebar .nav-section-title,
  .sidebar .nav-item span,
  .sidebar .nav-item .nav-badge,
  .sidebar .user-info {
    display: none;
  }
  .sidebar .nav-item {
    justify-content: center;
    padding: 12px;
  }
  .sidebar .nav-item::before {
    display: none;
  }
  .main-content {
    margin-left: var(--sidebar-collapsed-width);
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .form-steps {
    flex-wrap: wrap;
    gap: 8px;
  }
  .step-connector {
    width: 30px;
  }
  .step-item .step-label {
    display: none;
  }
}

@media (max-width: 768px) {
  .page-content {
    padding: 16px;
  }
  .dashboard-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .search-bar {
    flex-direction: column;
  }
  .search-input-group {
    min-width: 100%;
  }
  .page-toolbar {
    flex-direction: column;
    align-items: flex-start;
  }
  .login-card {
    padding: 32px 24px;
  }
  .info-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .dashboard-stats {
    grid-template-columns: 1fr;
  }
  .quick-actions {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   工具类
   ============================================ */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-gold { color: var(--primary-gold); }
.text-muted { color: var(--text-muted); }
.text-success { color: #67c23a; }
.text-danger { color: #f56c6c; }
.text-warning { color: #e6a23c; }
.font-serif { font-family: var(--font-serif); }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }
.hidden { display: none !important; }

/* ============================================
   打印样式
   ============================================ */
@media print {
  .sidebar, .top-header, .page-toolbar, .detail-actions, .btn {
    display: none !important;
  }
  .main-content {
    margin-left: 0 !important;
  }
  .page-content {
    padding: 0 !important;
  }
  .info-card, .form-section, .dashboard-card {
    box-shadow: none !important;
    border: 1px solid #ddd !important;
    break-inside: avoid;
  }
}

/* ============================================
   语音输入组件
   ============================================ */
.voice-input-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.voice-input-wrapper.voice-unsupported {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #f0f0f0;
  color: #999;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: not-allowed;
}

.voice-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid #d4a054;
  background: #fff;
  color: #d4a054;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: all 0.2s;
  flex-shrink: 0;
}

.voice-btn:hover {
  background: #faf6ee;
  transform: scale(1.05);
}

.voice-btn.recording {
  background: #f56c6c;
  border-color: #f56c6c;
  color: white;
  animation: voice-pulse-ring 1.5s ease-out infinite;
}

.voice-btn.recording:hover {
  background: #f56c6c;
}

.voice-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: #faf6ee;
  border-radius: 8px;
  border: 1px solid #e8d5a3;
  max-width: 400px;
}

.voice-text {
  font-size: 13px;
  color: #333;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  min-width: 0;
}

.voice-wave {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 20px;
}

.voice-wave span {
  width: 3px;
  height: 12px;
  background: #d4a054;
  border-radius: 2px;
  animation: voice-wave 0.8s ease-in-out infinite;
}

.voice-wave span:nth-child(2) { animation-delay: 0.1s; }
.voice-wave span:nth-child(3) { animation-delay: 0.2s; }
.voice-wave span:nth-child(4) { animation-delay: 0.3s; }
.voice-wave span:nth-child(5) { animation-delay: 0.4s; }

@keyframes voice-wave {
  0%, 100% { height: 4px; opacity: 0.4; }
  50% { height: 16px; opacity: 1; }
}

@keyframes voice-pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(245, 108, 108, 0.5); }
  70% { box-shadow: 0 0 0 12px rgba(245, 108, 108, 0); }
  100% { box-shadow: 0 0 0 0 rgba(245, 108, 108, 0); }
}

/* 语音录入确认弹窗样式 */
.voice-fields-list {
  margin: 8px 0;
}

.voice-field-group {
  display: flex;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
}

.voice-field-group:last-child { border-bottom: none; }

.voice-field-label {
  width: 100px;
  font-size: 13px;
  color: #666;
  font-weight: 500;
  flex-shrink: 0;
}

.voice-field-value {
  flex: 1;
  font-size: 13px;
  color: #333;
}

.voice-field-confidence {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 3px;
  margin-left: 8px;
  flex-shrink: 0;
}

.voice-field-confidence.high {
  background: #f0f9eb;
  color: #67c23a;
}

.voice-field-confidence.medium {
  background: #fdf6ec;
  color: #e6a23c;
}

.voice-field-confidence.low {
  background: #fef0f0;
  color: #f56c6c;
}

.voice-missing-warning {
  background: #fef0f0;
  border: 1px solid #fbc4c4;
  border-radius: 8px;
  padding: 12px 16px;
  margin-top: 12px;
  font-size: 13px;
  color: #f56c6c;
}

/* 语音录入引导对话框 */
.voice-qa-dialog {
  padding: 8px 0;
}

.voice-qa-step {
  margin-bottom: 16px;
}

.voice-qa-prompt {
  font-size: 14px;
  color: #333;
  font-weight: 500;
  margin-bottom: 8px;
}

.voice-qa-result {
  padding: 8px 12px;
  background: #f0f9eb;
  border-radius: 6px;
  font-size: 13px;
  color: #67c23a;
  margin-top: 4px;
}

.voice-qa-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.voice-qa-actions button {
  padding: 4px 12px;
  font-size: 12px;
  border-radius: 4px;
  border: 1px solid #ddd;
  background: #fff;
  cursor: pointer;
}

.voice-qa-actions button:hover {
  background: #f5f5f5;
}

/* 语音录入浮动按钮 */
.voice-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d4a054, #b8860b);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  transition: all 0.2s;
}

.voice-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(212, 160, 84, 0.3);
}

.voice-fab.recording {
  background: #f56c6c;
  color: white;
  animation: voice-pulse-ring 1.5s ease-out infinite;
}

/* 语音录入引导条 */
.voice-bar {
  padding: 12px 16px;
  background: #faf6ee;
  border-radius: 8px;
  border: 1px solid #e8d5a3;
  margin-bottom: 16px;
}

/* 按住说话按钮 */
.voice-hold-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px;
  touch-action: none;
  -webkit-touch-callout: none;
  user-select: none;
  -webkit-user-select: none;
}

.voice-hold-btn {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 3px solid #d4a054;
  background: linear-gradient(135deg, #d4a054, #b8860b);
  color: #fff;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  box-shadow: 0 4px 16px rgba(212, 160, 84, 0.3);
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}

.voice-hold-btn i {
  font-size: 36px;
  margin-bottom: 8px;
  transition: none;
}

.voice-hold-btn span {
  font-size: 14px;
  font-weight: 500;
  transition: opacity 0.2s;
}

.voice-hold-btn:hover {
  box-shadow: 0 6px 20px rgba(212, 160, 84, 0.4);
}

.voice-hold-btn.recording {
  background: linear-gradient(135deg, #f56c6c, #e04444);
  border-color: #f56c6c;
  box-shadow: 0 4px 16px rgba(245, 108, 108, 0.4);
  animation: voice-pulse-ring 1.5s ease-out infinite;
}

.voice-hold-btn.recording i {
  animation: mic-bounce 0.6s ease-in-out infinite;
}

.voice-hold-btn:disabled {
  background: #f0f0f0;
  border-color: #ddd;
  color: #999;
  cursor: not-allowed;
  box-shadow: none;
}

@keyframes mic-bounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* 录音中指示器 */
.voice-recording-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px;
}

.recording-wave {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 24px;
}

.recording-wave span {
  width: 4px;
  height: 16px;
  background: #f56c6c;
  border-radius: 2px;
  animation: voice-wave 0.8s ease-in-out infinite;
}

.recording-wave span:nth-child(2) { animation-delay: 0.1s; }
.recording-wave span:nth-child(3) { animation-delay: 0.2s; }
.recording-wave span:nth-child(4) { animation-delay: 0.3s; }
.recording-wave span:nth-child(5) { animation-delay: 0.4s; }

.recording-text {
  font-size: 14px;
  color: #f56c6c;
  font-weight: 500;
}

.recording-timer {
  font-size: 18px;
  color: #333;
  font-family: 'Courier New', monospace;
  font-weight: 600;
}

/* 全局FAB按钮 */
.voice-fab-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d4a054, #b8860b);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  transition: all 0.2s;
}

.voice-fab-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(212, 160, 84, 0.3);
}

/* FAB语音对话框 */
.voice-fab-dialog {
  padding: 8px 0;
}

.voice-fab-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e8e8e8;
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 500;
  color: #333;
}

.voice-fab-body {
  min-height: 150px;
}

/* 语音确认对话框 */
.voice-confirm-dialog {
  padding: 8px 0;
}

.voice-confirm-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px;
  background: #f9f9f9;
  border-radius: 8px;
  margin-bottom: 16px;
}

.voice-field-item {
  display: flex;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px solid #e8e8e8;
}

.voice-field-item:last-child {
  border-bottom: none;
}

.voice-field-label {
  width: 100px;
  font-size: 13px;
  color: #666;
  font-weight: 500;
  flex-shrink: 0;
}

.voice-field-value {
  flex: 1;
  font-size: 13px;
  color: #333;
  font-weight: 400;
}

.voice-missing-warning {
  padding: 12px;
  background: #fff3cd;
  border-radius: 6px;
  border-left: 3px solid #ffc107;
  font-size: 13px;
  color: #856404;
  line-height: 1.6;
}

.voice-missing-warning i {
  color: #ffc107;
  margin-right: 6px;
}

/* 语音搜索结果对话框 */
.voice-search-dialog {
  padding: 8px 0;
}

.voice-search-list {
  max-height: 400px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.voice-search-item {
  padding: 12px;
  background: #f9f9f9;
  border-radius: 6px;
  border: 1px solid #e8e8e8;
  transition: all 0.2s;
  cursor: pointer;
}

.voice-search-item:hover {
  background: #faf6ee;
  border-color: #d4a054;
  box-shadow: 0 2px 8px rgba(212, 160, 84, 0.15);
}

.voice-search-row {
  display: flex;
  align-items: center;
  padding: 4px 0;
  font-size: 13px;
}

.voice-search-label {
  width: 70px;
  color: #666;
  flex-shrink: 0;
}

.voice-search-value {
  flex: 1;
  color: #333;
}

/* 案件信息展示 */
.voice-case-info {
  padding: 12px;
  background: #f9f9f9;
  border-radius: 8px;
}

/* 语音录入对话框（类似微信） */
.voice-dialog-container {
  padding: 8px 0;
}

.voice-dialog-header {
  text-align: center;
  padding: 16px 0;
  border-bottom: 1px solid #e8e8e8;
  margin-bottom: 20px;
}

.voice-dialog-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 20px 0;
}

.voice-transcript-area {
  width: 100%;
  min-height: 80px;
  padding: 16px;
  background: #f5f5f5;
  border-radius: 8px;
  font-size: 14px;
  color: #666;
  line-height: 1.6;
}

.voice-transcript-placeholder {
  color: #999;
  font-style: italic;
}

.voice-transcript-loading {
  color: #d4a054;
}

.voice-transcript-success {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #333;
}

.voice-transcript-error {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #f56c6c;
}

.voice-dialog-btn {
  width: 100%;
  max-width: 300px;
  height: 60px;
  border-radius: 30px;
  border: 2px solid #d4a054;
  background: linear-gradient(135deg, #d4a054, #b8860b);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(212, 160, 84, 0.3);
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s, border-color 0.2s;
}

.voice-dialog-btn i {
  font-size: 20px;
}

.voice-dialog-btn:active {
  background: linear-gradient(135deg, #b8860b, #9a7209);
}

.voice-dialog-btn.recording {
  background: linear-gradient(135deg, #f56c6c, #e04444);
  border-color: #f56c6c;
  animation: voice-btn-pulse 1.5s ease-out infinite;
}

.voice-dialog-btn.disabled {
  background: #f0f0f0;
  border-color: #ddd;
  color: #999;
  cursor: not-allowed;
}

@keyframes voice-btn-pulse {
  0% { box-shadow: 0 0 0 0 rgba(245, 108, 108, 0.5); }
  70% { box-shadow: 0 0 0 12px rgba(245, 108, 108, 0); }
  100% { box-shadow: 0 0 0 0 rgba(245, 108, 108, 0); }
}

@media (max-width: 768px) {
  .voice-status {
    max-width: 200px;
  }
  .voice-fab-btn {
    bottom: 16px;
    right: 16px;
    width: 50px;
    height: 50px;
    font-size: 20px;
  }
  .voice-hold-btn {
    width: 100px;
    height: 100px;
  }
  .voice-hold-btn i {
    font-size: 28px;
  }
  .voice-field-item {
    flex-direction: column;
    gap: 4px;
  }
  .voice-field-label {
    width: auto;
  }
  .voice-search-row {
    flex-direction: column;
    gap: 2px;
  }
  .voice-search-label {
    width: auto;
  }
}
