/* 典当行客户管理系统 - 全局样式 */
:root {
  --primary: #2b2620;
  --primary-light: #4a4034;
  --primary-mid: #3a3329;
  --gold: #d4a84b;
  --gold-light: #e8c677;
  --accent: #d4a84b;
  --accent-light: #e8c677;
  --accent-ink: #fff;
  --accent-shadow-strong: 0 4px 16px rgba(212,168,75,0.4);
  --accent-shadow-soft: 0 0 0 4px rgba(212,168,75,0.12);
  --bg: #f6f1e7;
  --card-bg: #ffffff;
  --text: #333333;
  --text-secondary: #888888;
  --border: #e8dfcc;
  --success: #52c41a;
  --danger: #ff4d4f;
  --warning: #faad14;
  --radius: 12px;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --sidebar-width: 220px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
  padding-bottom: 70px;
  -webkit-font-smoothing: antialiased;
}

/* ========== 侧边栏 (桌面端) ========== */
.sidebar {
  display: none;
}

/* ========== 桌面端页面头部 ========== */
.desktop-header {
  display: none;
}

/* ========== 移动端头部 ========== */
.header {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  padding: 16px 20px;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
}

.header h1 {
  font-size: 18px;
  font-weight: 600;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 8px;
}

.header .back-btn {
  color: #fff;
  font-size: 24px;
  text-decoration: none;
  padding: 4px 8px;
  flex-shrink: 0;
}

.header .user-menu {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.header .user-name-display {
  font-size: 13px;
  color: rgba(255,255,255,0.85);
  max-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.header .logout-btn {
  font-size: 12.5px;
  padding: 6px 14px;
  background: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.9);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  flex-shrink: 0;
  white-space: nowrap;
}
.header .logout-btn:hover {
  background: rgba(255,77,79,0.3);
  border-color: rgba(255,77,79,0.5);
  color: #fff;
}

/* ========== 底部导航 (移动端) ========== */
.tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  display: flex;
  border-top: 1px solid var(--border);
  z-index: 100;
  padding-bottom: env(safe-area-inset-bottom);
}

.tab-bar a {
  flex: 1;
  text-align: center;
  padding: 8px 0;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 11px;
  transition: color 0.2s;
}

.tab-bar a .icon {
  font-size: 22px;
  display: block;
  margin-bottom: 2px;
  line-height: 1;
}

.tab-bar a .icon svg {
  width: 22px;
  height: 22px;
  display: block;
  margin: 0 auto;
}

.tab-bar a.active {
  color: var(--primary);
}

/* ========== 卡片 ========== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 16px;
  margin: 12px 16px;
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-title .badge {
  font-size: 12px;
  background: var(--gold);
  color: #fff;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: normal;
}

/* ========== 统计卡片 ========== */
.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 12px 16px;
}

.stat-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  text-align: center;
}

.stat-card .stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
  margin: 8px 0 4px;
}

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

.stat-card.danger .stat-value {
  color: var(--danger);
}

.stat-card.success .stat-value {
  color: var(--success);
}

.stat-card.gold .stat-value {
  color: var(--gold);
}

/* ========== 业务总览 KPI 醒目条 ========== */
.kpi-strip {
  margin: 12px 16px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%); /* fixed96：跟随主题色 */
  border-radius: 12px;
  padding: 20px 16px;
  box-shadow: 0 4px 16px rgba(26, 42, 74, 0.25);
}

.kpi-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 1px;
}

.kpi-title-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(212, 168, 75, 0.5), transparent);
  margin-left: 8px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.kpi-item {
  text-align: center;
  padding: 8px 4px;
}

.kpi-divider {
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.kpi-num {
  font-size: 32px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
}

.kpi-num.gold { color: #d4a84b; }
.kpi-num.green { color: #52c41a; }
.kpi-num.red { color: #ff7875; }
.kpi-num.orange { color: #ffa940; }

.kpi-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 8px;
}

@media (max-width: 600px) {
  /* fixed92：底部导航7项时紧凑显示 */
  .tab-bar a { font-size: 10px; padding: 6px 0; }
  .tab-bar a .icon { font-size: 19px; margin-bottom: 1px; }
  .tab-bar a .icon svg { width: 20px; height: 20px; }
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .kpi-item.kpi-divider {
    border-left: none;
    border-right: none;
  }
  .kpi-item:nth-child(2n) {
    border-left: 1px solid rgba(255, 255, 255, 0.12);
  }
  .kpi-num { font-size: 28px; }
}

/* ========== 列表 ========== */
.list-item {
  background: var(--card-bg);
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.2s;
}

.list-item:active {
  background: #f0f0f0;
}

.list-item:first-child {
  border-radius: var(--radius) var(--radius) 0 0;
}

.list-item:last-child {
  border-radius: 0 0 var(--radius) var(--radius);
  border-bottom: none;
}

.list-item:only-child {
  border-radius: var(--radius);
}

.list-item .item-info {
  flex: 1;
}

.list-item .item-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}

.list-item .item-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.list-item .item-right {
  text-align: right;
  flex-shrink: 0;
  margin-left: 12px;
}

.list-item .item-amount {
  font-size: 16px;
  font-weight: 600;
  color: var(--primary);
}

.list-container {
  margin: 12px 16px;
  box-shadow: var(--shadow);
  border-radius: var(--radius);
  overflow: hidden;
}

/* ========== 标签 ========== */
.tag {
  display: inline-block;
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 4px;
  margin-right: 4px;
}

.tag-type {
  background: #e6f7ff;
  color: #1890ff;
}

.tag-active {
  background: #f6ffed;
  color: #52c41a;
}

.tag-overdue {
  background: #fff2f0;
  color: #ff4d4f;
}

.tag-paid {
  background: #f6ffed;
  color: #52c41a;
}

.tag-unpaid {
  background: #fffbe6;
  color: #faad14;
}

/* ========== 按钮 ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

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

.btn-primary:active {
  background: var(--primary-light);
}

.btn-gold {
  background: var(--gold);
  color: #fff;
}

.btn-gold:active {
  background: var(--gold-light);
}

.btn-block {
  display: flex;
  width: 100%;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--primary);
  color: var(--primary);
}

/* ========== 表单 ========== */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 14px;
  color: var(--text);
  margin-bottom: 6px;
  font-weight: 500;
}

.form-label .required {
  color: var(--danger);
  margin-left: 2px;
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  color: var(--text);
  background: #fff;
  transition: border-color 0.2s;
  -webkit-appearance: none;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(26,42,74,0.1);
}

.form-input::placeholder {
  color: #bbb;
}

select.form-input {
  background: #fff url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23333' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e") no-repeat right 12px center;
  background-size: 14px;
  padding-right: 36px;
}

/* ========== 搜索栏 ========== */
.search-bar {
  padding: 12px 16px;
  background: #fff;
  position: sticky;
  top: 56px;
  z-index: 90;
}

.search-bar input {
  width: 100%;
  padding: 10px 16px 10px 40px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 14px;
  background: var(--bg) url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3ccircle cx='11' cy='11' r='8'/%3e%3cpath d='M21 21l-4.35-4.35'/%3e%3c/svg%3e") no-repeat 14px center;
  background-size: 16px;
}

.search-bar input:focus {
  outline: none;
  border-color: var(--primary);
}

/* fixed225：付息登记列表搜索栏（与 .search-bar 视觉统一，非吸顶） */
.payment-search225 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 16px 4px;
  padding: 0 14px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--bg);
}
.payment-search225 svg {
  width: 16px;
  height: 16px;
  color: #999;
  flex-shrink: 0;
}
.payment-search225 input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: var(--text);
}
.payment-search225:focus-within {
  border-color: var(--primary);
}

/* ========== 空状态 ========== */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-secondary);
}

.empty-state .icon {
  font-size: 48px;
  margin-bottom: 12px;
}

/* ========== 弹窗 ========== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-content {
  background: #fff;
  border-radius: 16px 16px 0 0;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  padding: 20px;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.modal-header h3 {
  font-size: 18px;
  color: var(--primary);
}

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

/* ========== 浮动操作按钮 ========== */
.fab {
  position: fixed;
  right: 20px;
  bottom: 90px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold);
  color: #fff;
  font-size: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(212,168,75,0.4);
  text-decoration: none;
  z-index: 50;
  transition: transform 0.2s;
}

.fab:active {
  transform: scale(0.9);
}

/* ========== 信息行 ========== */
.info-row {
  display: flex;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
}

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

.info-row .label {
  width: 90px;
  color: var(--text-secondary);
  font-size: 14px;
  flex-shrink: 0;
}

.info-row .value {
  flex: 1;
  font-size: 14px;
  color: var(--text);
  word-break: break-all;
}

/* ========== Toast ========== */
.toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.75);
  color: #fff;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 300;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ========== 筛选栏 ========== */
.filter-bar {
  display: flex;
  gap: 8px;
  padding: 8px 16px;
  overflow-x: auto;
  background: #fff;
}

.filter-btn {
  padding: 6px 14px;
  border-radius: 16px;
  font-size: 13px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text-secondary);
  white-space: nowrap;
  cursor: pointer;
}

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

/* ========== 操作按钮组 ========== */
.action-bar {
  display: flex;
  gap: 10px;
  padding: 12px 16px;
}

/* ========== 图表容器 ========== */
.chart-container {
  width: 100%;
  height: 200px;
  margin: 8px 0;
}

/* ========== 页面容器 ========== */
.page {
  min-height: 100vh;
}


/* ================================================
   桌面端响应式样式 (屏幕宽度 >= 768px)
   ================================================ */
@media (min-width: 768px) {

  /* ---- 基础布局 ---- */
  body {
    padding-bottom: 0;
    padding-left: var(--sidebar-width);
    background: var(--bg);
  }

  /* ---- 隐藏移动端专属元素 ---- */
  .header {
    display: none;
  }
  .tab-bar {
    display: none !important;
  }

  /* ---- 侧边栏 ---- */
  .sidebar {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: linear-gradient(180deg, var(--primary) 0%, var(--primary-mid, #1e3260) 50%, var(--primary-light) 100%);
    color: #fff;
    z-index: 200;
    box-shadow: 2px 0 16px rgba(0,0,0,0.12);
    overflow: hidden;
  }

  .sidebar-brand {
    padding: 28px 22px 22px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .sidebar-logo {
    font-size: 30px;
    line-height: 1;
  }

  .sidebar-brand-text {
    display: flex;
    flex-direction: column;
  }

  .sidebar-title {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 0.5px;
  }

  .sidebar-subtitle {
    font-size: 11px;
    color: rgba(255,255,255,0.5);
    margin-top: 2px;
  }

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

  .sidebar-nav-label {
    padding: 8px 24px 6px;
    font-size: 11px;
    color: rgba(255,255,255,0.35);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
  }

  .sidebar-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 24px;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 14.5px;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    margin: 2px 0;
  }

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

  .sidebar-link.active {
    background: rgba(255,255,255,0.12);
    color: var(--accent-light);
    border-left-color: var(--accent);
    font-weight: 500;
  }

  .sidebar-icon {
    font-size: 19px;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .sidebar-icon svg {
    width: 20px;
    height: 20px;
  }

  .sidebar-footer {
    padding: 10px 22px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 11px;
    color: rgba(255,255,255,0.3);
    text-align: center;
  }

  /* ---- 侧边栏底部用户区 ---- */
  /* fixed163 方案A：用户信息独立卡片，修改密码/退出 两按钮并排 */
  .sidebar-user-section {
    padding: 14px;
    border-top: 1px solid rgba(255,255,255,0.1);
  }
  .sidebar-user-card {
    display: flex;
    align-items: center;
    gap: 11px;
    background: rgba(255,255,255,0.07);
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 11px;
  }
  .sidebar-user-avatar {
    width: 38px; height: 38px; border-radius: 50%;
    background: var(--primary); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; font-weight: 700; flex-shrink: 0;
  }
  .sidebar-user-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
  }
  .sidebar-user-name {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .sidebar-user-role {
    font-size: 11px;
    color: rgba(255,255,255,0.5);
    margin-top: 2px;
  }
  .sidebar-user-btns { display: flex; gap: 9px; }
  .sidebar-pwd-btn,
  .sidebar-logout-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 9px 6px;
    border-radius: 8px;
    font-size: 12.5px;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
  }
  .sidebar-pwd-btn svg, .sidebar-logout-btn svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  .sidebar-pwd-btn {
    color: #f3dd9a;
    border: 1px solid rgba(226,190,110,0.8);
    background: rgba(212,168,75,0.18);
  }
  .sidebar-pwd-btn:hover { background: rgba(212,168,75,0.3); }
  .sidebar-logout-btn {
    color: #ffb3b3;
    background: rgba(255,77,79,0.14);
    border: 1px solid rgba(255,110,112,0.65);
  }
  .sidebar-logout-btn:hover {
    background: rgba(255,77,79,0.3);
    border-color: rgba(255,110,112,0.85);
    color: #fff;
  }

  /* ---- 桌面端页面头部 ---- */
  .desktop-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 32px;
    background: #fff;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
    min-height: 64px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  }

  .desktop-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 8px;
  }

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

  .desktop-header .breadcrumb {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
  }

  .desktop-header .breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
  }

  .desktop-header .breadcrumb a:hover {
    color: var(--primary);
  }

  /* ---- 内容区域间距调整 ---- */
  .card {
    margin: 16px 32px;
    padding: 20px 24px;
  }

  .card-title {
    font-size: 17px;
    margin-bottom: 16px;
  }

  /* ---- 统计卡片 - 四列 ---- */
  .stat-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 20px 32px;
  }

  .stat-card {
    padding: 20px 16px;
    transition: transform 0.2s, box-shadow 0.2s;
  }

  .stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  }

  .stat-card .stat-value {
    font-size: 28px;
  }

  .stat-card .stat-label {
    font-size: 13px;
  }

  /* ---- 搜索栏 ---- */
  .search-bar {
    padding: 16px 32px;
    top: 64px;
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
  }

  .search-bar input {
    max-width: 480px;
    border-radius: 8px;
    padding: 10px 16px 10px 42px;
    font-size: 14px;
  }

  /* ---- 列表 ---- */
  .list-container {
    margin: 16px 32px;
  }

  .list-item {
    padding: 14px 20px;
    cursor: pointer;
    transition: background 0.15s;
  }

  .list-item:hover {
    background: #f8f9ff;
  }

  .list-item:active {
    background: #eef0ff;
  }

  .list-item .item-title {
    font-size: 15px;
  }

  /* ---- 筛选栏 ---- */
  .filter-bar {
    padding: 12px 32px;
    border-bottom: 1px solid #f0f0f0;
  }

  .filter-btn {
    padding: 7px 18px;
    font-size: 13.5px;
    transition: all 0.2s;
  }

  .filter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
  }

  .filter-btn.active:hover {
    color: #fff;
  }

  /* ---- 操作按钮组 ---- */
  .action-bar {
    padding: 16px 32px;
  }

  .action-bar .btn {
    min-width: 140px;
  }

  /* ---- 按钮桌面端hover效果 ---- */
  .btn {
    transition: all 0.2s ease;
  }

  .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  }

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

  /* ---- FAB ---- */
  .fab {
    bottom: 32px;
    right: 32px;
    transition: transform 0.2s, box-shadow 0.2s;
  }

  .fab:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(212,168,75,0.5);
  }

  /* ---- 弹窗 - 桌面端居中显示 ---- */
  .modal-overlay {
    align-items: center;
  }

  .modal-content {
    border-radius: 16px;
    max-width: 560px;
    width: 90%;
    max-height: 85vh;
    animation: fadeInScale 0.25s ease;
  }

  @keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
  }

  /* ---- 信息行 ---- */
  .info-row .label {
    width: 100px;
    font-size: 14px;
  }

  .info-row .value {
    font-size: 14.5px;
  }

  /* ---- 图表 ---- */
  .chart-container {
    height: 300px;
  }

  /* ---- 表单 ---- */
  .form-input:focus {
    box-shadow: 0 0 0 3px rgba(26,42,74,0.08);
  }

  /* ---- Toast ---- */
  .toast {
    font-size: 15px;
    padding: 14px 28px;
    border-radius: 10px;
  }

  /* ---- 表格 ---- */
  .payment-table th,
  .payment-table td {
    padding: 10px 12px;
    font-size: 14px;
  }
}

/* ================================================
   大屏幕进一步优化 (>= 1200px)
   ================================================ */
@media (min-width: 1200px) {
  .stat-grid {
    margin: 20px 40px;
  }

  .card {
    margin: 16px 40px;
  }

  .list-container {
    margin: 16px 40px;
  }

  .search-bar {
    padding: 16px 40px;
  }

  .filter-bar {
    padding: 12px 40px;
  }

  .action-bar {
    padding: 16px 40px;
  }

  .desktop-header {
    padding: 18px 40px;
  }
}

/* ================================================
   超宽屏幕 (>= 1400px) - 内容限宽
   ================================================ */
@media (min-width: 1400px) {
  .stat-grid {
    max-width: 1100px;
  }
}

/* ================================================
   逾期备注 - 快捷标签 & 录入优化
   ================================================ */
.note-quick-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}
.note-quick-tag {
  display: inline-block;
  padding: 4px 10px;
  font-size: 12px;
  background: #f0f3f8;
  color: var(--primary);
  border: 1px solid #d8dee8;
  border-radius: 12px;
  cursor: pointer;
  user-select: none;
  transition: all 0.15s ease;
  line-height: 1.4;
}
.note-quick-tag:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.note-quick-tag:active {
  transform: scale(0.96);
}

/* 整体美化微调 */
.card, .stat-card, .overdue-card {
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.card:hover, .stat-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}
.btn {
  transition: all 0.18s ease;
}
.btn:active {
  transform: translateY(1px);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 2px rgba(26,42,74,0.1);
}

/* ========== f153 Lucide 内联图标统一样式 ========== */
.li {
  width: 1em; height: 1em;
  display: inline-block;
  vertical-align: -0.14em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.empty-state .icon .li { width: 48px; height: 48px; }
.backup-icon .li { width: 40px; height: 40px; }
.search-box .li, input .li { vertical-align: middle; }

/* ===== fixed190：股东方分组折叠 ===== */
.inv-group-fold.inv-group-open > tr:not(.inv-grp-head):not(.loan-fold-body) { display: table-row !important; }
.inv-group-fold > tr:not(.inv-grp-head) { display: none; }
.inv-grp-head td {
  background: linear-gradient(90deg, #f7eccb, #f1e2b4);
  border-bottom: 1px solid #e0cc92;
  cursor: pointer;
  padding: 11px 14px;
  color: #6e5410;
}
.inv-grp-head:hover td { background: linear-gradient(90deg, #f5e6bd, #ecdaa3); }
.inv-grp-arrow { display: inline-block; width: 18px; color: #8b6914; font-weight: 700; }
.inv-grp-name { font-weight: 700; font-size: 14px; margin-right: 12px; }
.inv-grp-meta { font-size: 12px; font-weight: 400; color: #7d6620; }
.inv-grp-meta b { font-weight: 700; }
.inv-grp-hint { float: right; font-size: 11px; color: #a8914a; font-weight: 400; }

/* ===== fixed191：服务费按年下钻 ===== */
.sf-yr-head td { background: #fffdf6; }
.sf-yr-head:hover td { background: #faf3dd; }
.sf-yr-arrow { display:inline-block; width:16px; color:#8b6914; font-weight:700; }

/* 股东月报月份钻取行 */
tr.im-drill-row{cursor:pointer;transition:background .12s;}
tr.im-drill-row:hover{background:#eef5fc !important;}
tr.im-drill-row td:first-child{color:#2f6db0;}

/* ========== fixed226：手机端统一隐藏头部右上角退出键（退出入口收到底导"我的"内） ========== */
@media (max-width: 767px) {
  .header .logout-btn { display: none !important; }
  /* fixed227：手机端隐藏头部左上角返回箭头（返回走底导/系统返回手势） */
  .header .back-btn { display: none !important; }
}
