/* Extracted from v2.5 inline style block #0. v3.0-alpha split packaging. */
  body{font-family:Arial,"Microsoft YaHei",sans-serif;margin:0;background:#f5f6fa;color:#111827}
  .wrap{max-width:1760px;margin:22px auto;padding:0 18px}
  h1{font-size:24px;margin:0 0 14px}
  h2{font-size:22px;margin:0 0 8px}
  .card{background:#fff;border:1px solid #e5e7eb;border-radius:12px;padding:16px;margin-bottom:18px;box-shadow:0 2px 10px rgba(0,0,0,.05)}
  .summary{display:grid;grid-template-columns:repeat(5,minmax(160px,1fr));gap:12px}
  .box{background:#eef9f8;border:1px solid #bfe8e3;border-radius:10px;padding:12px}
  .box b{font-size:21px;color:#008079}
  .section-title{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap}
  .tools{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
  button{border:0;border-radius:8px;padding:8px 12px;cursor:pointer;background:#18b7ad;color:#fff;font-weight:600}
  button.gray{background:#64748b}
  button.red{background:#ef4444}
  button.small{font-size:11px;padding:3px 5px;border-radius:5px;margin:1px;background:#94a3b8}
  button.small.red{background:#ef4444}
  .scroll{overflow:auto;max-height:560px;border:1px solid #ddd}
  table{width:max-content;min-width:100%;border-collapse:collapse;background:#fff;font-size:13px}
  th,td{border:1px solid #a3a3a3;padding:6px;text-align:center;min-width:110px}
  th{background:#f7dfce;position:sticky;top:0;z-index:3;vertical-align:top}
  input,select{width:100%;box-sizing:border-box;border:1px solid #d1d5db;border-radius:6px;padding:6px;text-align:center;background:#fff}
  input[readonly]{background:#f3f4f6;font-weight:700}
  select.colored-select{font-weight:700;color:#fff}
  .serial-col{min-width:48px!important;width:48px!important;max-width:48px!important;background:#f8fafc!important}
  th.serial-col{background:#e5e7eb!important}
  .serial-col input{width:38px!important;min-width:38px!important;padding:4px 2px!important;background:#f8fafc!important;font-weight:700}
  .col-tools{white-space:nowrap;margin-bottom:4px}
  .col-name{font-weight:700;cursor:pointer}
  .hint{font-size:12px;color:#6b7280;margin:4px 0 0}
  .sticky-col{position:sticky!important;background:#fff;z-index:2}
  th.sticky-col{background:#f7dfce;z-index:4}
  th.serial-col.sticky-col{background:#e5e7eb!important}
  .hidden{display:none!important}
  .login-card{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
  .login-card input{width:220px}
  .status{font-size:13px;color:#475569}
  .readonly #appBox input,
  .readonly #appBox select,
  .readonly #appBox button:not(.exportBtn){pointer-events:none;opacity:.55}
  .modalMask{position:fixed;inset:0;background:rgba(0,0,0,.35);z-index:9999;display:flex;align-items:center;justify-content:center;padding:20px}
  .modalBox{background:#fff;border-radius:14px;max-width:1100px;width:100%;max-height:86vh;overflow:auto;padding:18px;box-shadow:0 18px 50px rgba(0,0,0,.25)}
  .modalHeader{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:12px}
  .modalHeader h2{margin:0}
  .modalTable{width:100%;min-width:900px}
  .badge{display:inline-block;border-radius:999px;padding:3px 8px;background:#eef2ff;color:#3730a3;font-size:12px;font-weight:700}
  .diffBox{white-space:pre-wrap;text-align:left;max-width:460px;font-size:12px;color:#334155}

  /* 稳定固定列：避免横向拖动时闪烁 */
  
  #fundTable th.serial-col, #fundTable td.serial-col,
  #accountTable th.serial-col, #accountTable td.serial-col{
    background:#f8fafc!important;
  }


.sidebar-layout{display:flex;gap:18px;align-items:flex-start}
.sidebar-nav{
  width:240px;min-width:240px;background:#0f172a;color:#fff;
  border-radius:16px;padding:16px;position:sticky;top:12px;
  box-shadow:0 10px 25px rgba(0,0,0,.15)
}
.nav-group{margin-bottom:18px}
.nav-title{
  font-size:18px;font-weight:700;padding:12px;border-radius:10px;
  background:#111827;margin-bottom:10px
}
.nav-link{
  display:block;padding:12px 14px;border-radius:10px;
  color:#cbd5e1;text-decoration:none;margin:6px 0;
  transition:.2s
}
.nav-link:hover{
  background:#1e293b;color:#fff;transform:translateX(2px)
}
.main-content-flex{flex:1;min-width:0}
@media (max-width: 980px){
  .sidebar-layout{flex-direction:column}
  .sidebar-nav{width:100%;min-width:100%;position:relative}
}


  .nav-title{
    display:flex;
    align-items:center;
    justify-content:space-between;
    cursor:pointer;
    user-select:none;
  }
  .nav-title .arrow{
    font-size:18px;
    transition:transform .2s ease;
  }
  .nav-group.collapsed .arrow{
    transform:rotate(-90deg);
  }
  .nav-group.collapsed .nav-items{
    display:none;
  }
  .nav-link.active{
    background:#2563eb;
    color:#fff;
    font-weight:700;
  }


  .page-hidden{display:none!important}
  .nav-page-link{
    display:block;padding:14px 16px;border-radius:12px;
    color:#cbd5e1;text-decoration:none;margin:8px 0;
    cursor:pointer;font-size:16px;transition:.2s;
  }
  .nav-page-link:hover{background:#1e293b;color:#fff;transform:translateX(2px)}
  .nav-page-link.active{background:#2563eb;color:#fff;font-weight:700}


  /* ====== 美观布局优化 ====== */
  body{background:linear-gradient(180deg,#f8fafc 0%,#eef2f7 100%)!important}
  .wrap{max-width:none!important;width:100%!important;margin:0!important;padding:18px 22px!important;box-sizing:border-box}
  h1{font-size:30px!important;letter-spacing:.5px}
  h2{font-size:24px!important}
  .card{border-radius:18px!important;border:1px solid #e2e8f0!important;box-shadow:0 12px 32px rgba(15,23,42,.08)!important}
  .summary{grid-template-columns:repeat(5,minmax(180px,1fr))!important;position:sticky;top:0;z-index:20;background:#f8fafc;padding:10px 0}
  .box{border-radius:16px!important;padding:18px!important;background:linear-gradient(135deg,#ecfeff,#f0fdfa)!important}
  .box b{font-size:28px!important}
  .section-title{position:sticky;top:92px;z-index:18;background:#fff;padding:10px 0;border-bottom:1px solid #e5e7eb}
  .tools button{box-shadow:0 6px 14px rgba(15,23,42,.12)}
  .scroll{max-height:70vh!important;border-radius:12px;border:1px solid #cbd5e1!important;background:#fff}
  table{font-size:14px!important}
  th{font-size:14px!important;padding:8px 6px!important;background:#fde7d5!important}
  td{padding:5px!important;height:42px}
  input,select{height:32px!important;font-size:14px!important;border-radius:8px!important}
  input:focus,select:focus{outline:2px solid #22c55e;border-color:#22c55e}
  .sidebar-nav{border-radius:22px!important;background:linear-gradient(180deg,#0f172a,#111827)!important}
  .nav-page-link{font-size:18px!important;padding:16px 18px!important}
  .main-content-flex{overflow:hidden}

  /* 表格列宽优化，减少横向混乱 */
  #fundTable th:nth-child(1),#fundTable td:nth-child(1){min-width:54px!important;width:54px!important}
  #fundTable th:nth-child(2),#fundTable td:nth-child(2){min-width:115px!important;width:115px!important}
  #fundTable th:nth-child(3),#fundTable td:nth-child(3){min-width:230px!important;width:230px!important}
  #fundTable th:nth-child(4),#fundTable td:nth-child(4){min-width:190px!important;width:190px!important}
  #fundTable th:nth-child(5),#fundTable td:nth-child(5){min-width:115px!important;width:115px!important}
  #fundTable th:nth-child(6),#fundTable td:nth-child(6){min-width:100px!important;width:100px!important}
  #fundTable th:nth-child(7),#fundTable td:nth-child(7),
  #fundTable th:nth-child(8),#fundTable td:nth-child(8),
  #fundTable th:nth-child(9),#fundTable td:nth-child(9),
  #fundTable th:nth-child(10),#fundTable td:nth-child(10),
  #fundTable th:nth-child(11),#fundTable td:nth-child(11){min-width:120px!important;width:120px!important}

  

  .quick-panel{
    background:linear-gradient(135deg,#f8fafc,#ecfeff);
    border:1px solid #bae6fd;
    border-radius:18px;
    padding:16px;
    margin:14px 0;
  }
  .quick-grid{
    display:grid;
    grid-template-columns:repeat(8,minmax(120px,1fr));
    gap:10px;
    align-items:end;
  }
  .quick-field label{
    display:block;
    font-size:12px;
    color:#475569;
    margin-bottom:5px;
    font-weight:700;
  }
  .quick-field input,.quick-field select{
    width:100%;
    background:#fff;
  }
  .quick-actions{display:flex;gap:8px;align-items:end}
  .pill-title{
    display:inline-flex;align-items:center;gap:8px;
    border-radius:999px;background:#0f172a;color:#fff;
    padding:8px 14px;margin-bottom:10px;font-weight:800;
  }
  .view-toggle{margin-left:auto}
  .compact-mode td{height:32px!important}
  .compact-mode input,.compact-mode select{height:26px!important;font-size:12px!important;padding:3px!important}
  .compact-mode th{font-size:12px!important;padding:5px!important}

  @media (max-width:1200px){
    .quick-grid{grid-template-columns:repeat(3,minmax(120px,1fr))}
    .summary{grid-template-columns:repeat(2,minmax(180px,1fr))!important}
  }


  /* ===== 搜索筛选 & 动态快速登记 ===== */
  .filter-panel{
    background:linear-gradient(135deg,#ffffff,#f8fafc);
    border:1px solid #cbd5e1;
    border-radius:18px;
    padding:14px;
    margin:14px 0;
  }
  .filter-grid{
    display:grid;
    grid-template-columns:repeat(6,minmax(130px,1fr));
    gap:10px;
    align-items:end;
  }
  .filter-field label{
    display:block;font-size:12px;font-weight:800;color:#475569;margin-bottom:5px;
  }
  .filter-field input,.filter-field select{width:100%;background:#fff}
  .quick-extra-grid{
    display:grid;
    grid-template-columns:repeat(6,minmax(130px,1fr));
    gap:10px;
    margin-top:10px;
  }
  .filter-count{
    font-size:13px;color:#475569;font-weight:700;margin-left:8px;
  }
  .highlight-row{background:#fff7ed!important}
  @media (max-width:1200px){
    .filter-grid,.quick-extra-grid{grid-template-columns:repeat(2,minmax(130px,1fr))}
  }


  /* ===== 权限管理 & Excel 导入 ===== */
  .role-admin{background:#fee2e2;color:#991b1b}
  .role-editor{background:#dcfce7;color:#166534}
  .role-viewer{background:#e0f2fe;color:#075985}
  .role-operator{background:#fef3c7;color:#92400e}
  .user-grid{display:grid;grid-template-columns:1.4fr .8fr 1fr 160px;gap:10px;align-items:center}
  .user-grid input,.user-grid select{width:100%}
  .operator-note{background:#fffbeb;border:1px solid #fde68a;border-radius:12px;padding:10px;margin:10px 0;color:#92400e}


  /* ===== 列设置：排序 / 隐藏 / 固定 / 宽度 ===== */
  .column-manager-list{display:flex;flex-direction:column;gap:8px}
  .column-item{
    display:grid;grid-template-columns:34px 1fr 90px 90px 90px 90px 90px;
    gap:8px;align-items:center;border:1px solid #e2e8f0;border-radius:12px;
    padding:8px;background:#f8fafc
  }
  .column-item.locked{background:#fff7ed}
  .column-item input[type="number"]{width:80px}
  .column-item .drag-handle{cursor:grab;font-size:18px;color:#64748b;text-align:center}
  .column-manager-actions{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
  .hidden-column-note{font-size:12px;color:#64748b;margin:8px 0}


  /* ===== 修复固定前 N 列 ===== */
  .no-sticky-cols th,
  .no-sticky-cols td{
    position:static!important;
    left:auto!important;
    z-index:auto!important;
  }


  /* ===== 修复固定列与固定行冲突 ===== */
  .scroll{position:relative}
  .row-sticky-cell{
    position:sticky!important;
    background:#fff!important;
    z-index:18!important;
  }
  .row-sticky-cell.col-sticky-cell{
    z-index:28!important;
  }
  th.col-sticky-cell{
    z-index:40!important;
  }
  th{
    top:0!important;
    z-index:35!important;
  }
  .col-sticky-cell{
    position:sticky!important;
    background:#fff!important;
    z-index:22!important;
  }
  th.col-sticky-cell{
    background:#fde7d5!important;
  }
  .serial-col.col-sticky-cell,
  .serial-col.row-sticky-cell{
    background:#f8fafc!important;
  }


  /* ===== 渠道月度（充值）核查看板 ===== */
  .audit-filter-panel{
    background:linear-gradient(135deg,#ffffff,#f8fafc);
    border:1px solid #cbd5e1;
    border-radius:18px;
    padding:14px;
    margin:12px 0;
  }
  .audit-grid{
    display:grid;
    grid-template-columns:repeat(6,minmax(130px,1fr));
    gap:10px;
    align-items:end;
  }
  .audit-field label{
    display:block;font-size:12px;font-weight:800;color:#475569;margin-bottom:5px;
  }
  .audit-field input,.audit-field select{width:100%;background:#fff}
  .status-ok{background:#dcfce7;color:#166534;border-radius:999px;padding:4px 10px;font-weight:800;white-space:nowrap}
  .status-warn{background:#fef3c7;color:#92400e;border-radius:999px;padding:4px 10px;font-weight:800;white-space:nowrap}
  .status-danger{background:#fee2e2;color:#991b1b;border-radius:999px;padding:4px 10px;font-weight:800;white-space:nowrap}
  .audit-detail-title{font-size:16px;font-weight:800;margin:8px 0 12px}
  .audit-mini{font-size:12px;color:#64748b;line-height:1.7}
  #channelSummaryTable th,#channelSummaryTable td{min-width:118px}
  #channelSummaryTable th:nth-child(17),#channelSummaryTable td:nth-child(17){min-width:150px}
  #channelSummaryTable th:nth-child(18),#channelSummaryTable td:nth-child(18){min-width:120px}
  @media(max-width:1200px){.audit-grid{grid-template-columns:repeat(2,minmax(130px,1fr))}}


  .audit-kpi-grid{
    display:grid;
    grid-template-columns:repeat(6,minmax(150px,1fr));
    gap:12px;
    margin:14px 0;
  }
  .audit-kpi{
    border-radius:16px;
    padding:14px;
    background:linear-gradient(135deg,#f8fafc,#eef6ff);
    border:1px solid #cbd5e1;
  }
  .audit-kpi .label{font-size:12px;color:#64748b;font-weight:800;margin-bottom:6px}
  .audit-kpi .value{font-size:24px;font-weight:900;color:#0f172a}
  .audit-kpi.warn{background:linear-gradient(135deg,#fffbeb,#fef3c7);border-color:#facc15}
  .audit-kpi.danger{background:linear-gradient(135deg,#fff1f2,#fee2e2);border-color:#f87171}
  .audit-kpi.ok{background:linear-gradient(135deg,#f0fdf4,#dcfce7);border-color:#86efac}
  @media(max-width:1200px){.audit-kpi-grid{grid-template-columns:repeat(2,minmax(150px,1fr))}}



  /* ===== 云端保存状态 / 导入保护 ===== */
  .save-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 10px;font-size:12px;font-weight:800;margin-left:8px}
  .save-idle{background:#e2e8f0;color:#334155}
  .save-saving{background:#fef3c7;color:#92400e}
  .save-saved{background:#dcfce7;color:#166534}
  .save-error,.save-conflict{background:#fee2e2;color:#991b1b}
  .import-choice{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}
  .import-choice button{min-width:120px}
  .danger-note{background:#fff1f2;border:1px solid #fecdd3;color:#991b1b;border-radius:12px;padding:10px;margin-top:10px;line-height:1.7}



  /* ===== 第二优先级优化：分页 / 新导航 / 图表预留 / 移动端加强 ===== */
  .pagination-bar{display:flex;gap:8px;align-items:center;justify-content:flex-end;flex-wrap:wrap;margin:10px 0 0;font-size:13px;color:#475569;font-weight:700}
  .pagination-bar select{width:auto!important;min-width:82px;height:30px!important}
  .pagination-bar button{padding:6px 10px;font-size:12px}
  .sub-page-hidden{display:none!important}
  .mini-kpi-row{display:grid;grid-template-columns:repeat(5,minmax(140px,1fr));gap:10px;margin:12px 0}
  .mini-kpi{border:1px solid #cbd5e1;border-radius:14px;background:#f8fafc;padding:12px}
  .mini-kpi .k{font-size:12px;color:#64748b;font-weight:800}
  .mini-kpi .v{font-size:22px;font-weight:900;color:#0f766e;margin-top:4px}
  .detail-actions{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
  .save-ok{background:#dcfce7!important;color:#166534!important}
  .save-saving{background:#fef3c7!important;color:#92400e!important}
  .save-conflict{background:#fee2e2!important;color:#991b1b!important}
  .save-error{background:#fee2e2!important;color:#991b1b!important}
  @media(max-width:780px){
    .wrap{padding:10px!important}
    h1{font-size:24px!important}
    .summary,.audit-kpi-grid,.mini-kpi-row{grid-template-columns:1fr!important;position:relative!important;top:auto!important}
    .section-title{position:relative!important;top:auto!important}
    .tools{gap:6px}.tools button{padding:7px 9px;font-size:12px}
    .sidebar-nav{padding:10px!important}.nav-page-link{font-size:15px!important;padding:11px 12px!important}
    .scroll{max-height:62vh!important}
    th,td{min-width:96px!important;font-size:12px!important}
    .login-card input{width:100%!important}
  }



  /* ===== 稳定分页条：替代原生 select，避免下拉闪烁/无法选中 ===== */
  .pagination-bar{
    position:sticky;bottom:0;z-index:60;background:rgba(255,255,255,.96);
    backdrop-filter:blur(8px);border:1px solid #cbd5e1;border-radius:14px;
    padding:10px 12px;margin-top:8px;display:flex;align-items:center;justify-content:flex-end;
    gap:10px;flex-wrap:wrap;box-shadow:0 8px 24px rgba(15,23,42,.08)
  }
  .pagination-bar .page-info{font-weight:800;color:#334155}
  .pagination-bar .page-btn{padding:7px 12px;border-radius:10px;background:#64748b;color:#fff;font-weight:800}
  .pagination-bar .page-btn:disabled{opacity:.45;cursor:not-allowed}
  .page-size-wrap{position:relative;display:inline-flex;align-items:center;gap:6px}
  .page-size-btn{min-width:92px;background:#fff!important;color:#0f172a!important;border:2px solid #22c55e!important;border-radius:12px!important;padding:8px 12px!important;font-weight:900!important}
  .page-size-menu{
    position:absolute;right:0;bottom:calc(100% + 8px);z-index:99999;min-width:96px;
    background:#fff;border:1px solid #cbd5e1;border-radius:12px;box-shadow:0 18px 45px rgba(15,23,42,.22);
    padding:6px;display:none
  }
  .page-size-menu.show{display:block}
  .page-size-option{
    display:block;width:100%;border:0;background:#fff!important;color:#111827!important;
    border-radius:8px;padding:9px 12px;text-align:center;font-weight:800;box-shadow:none!important
  }
  .page-size-option:hover,.page-size-option.active{background:#2563eb!important;color:#fff!important}
  .table-rendering{opacity:.72;transition:opacity .12s ease}


/* =========================================================
   第三优先级 V1：UI 美化 + 移动端适配
   说明：只做视觉与响应式优化，不改动数据保存/统计逻辑
   ========================================================= */
:root{
  --ui-bg:#f4f7fb;
  --ui-card:#ffffff;
  --ui-text:#0f172a;
  --ui-muted:#64748b;
  --ui-border:#dbe5f0;
  --ui-primary:#14b8a6;
  --ui-primary-dark:#0f766e;
  --ui-blue:#2563eb;
  --ui-danger:#ef4444;
  --ui-shadow:0 14px 38px rgba(15,23,42,.08);
  --ui-shadow-soft:0 8px 24px rgba(15,23,42,.06);
  --ui-radius:20px;
}

html{scroll-behavior:smooth}
body{
  background:
    radial-gradient(circle at top left, rgba(20,184,166,.12), transparent 34%),
    radial-gradient(circle at top right, rgba(37,99,235,.10), transparent 28%),
    linear-gradient(180deg,#f8fafc 0%,#eef3f8 100%)!important;
  color:var(--ui-text)!important;
}

.wrap{
  padding:18px 28px!important;
  max-width:1920px!important;
}

/* 顶部用户栏：更清晰，不闪动 */
#userBox{
  border-radius:22px!important;
  box-shadow:var(--ui-shadow-soft)!important;
  border:1px solid var(--ui-border)!important;
  align-items:center;
  gap:12px;
  flex-wrap:wrap;
}
#userBox:not(.hidden){display:flex!important}
#userBox b{font-size:18px}
#roleText{font-size:15px!important}
.save-status{
  min-width:96px;
  justify-content:center;
  transition:none!important;
  box-shadow:none!important;
}
.save-saving,.save-saved,.save-error,.save-conflict{
  animation:none!important;
}

/* 页面标题 */
.main-content-flex > h1{
  font-size:34px!important;
  line-height:1.15!important;
  margin:6px 0 18px!important;
  letter-spacing:-.5px!important;
}

/* 左侧导航优化 */
.sidebar-layout{
  display:grid!important;
  grid-template-columns:300px minmax(0,1fr);
  gap:22px!important;
}
.sidebar-nav{
  width:auto!important;
  min-width:0!important;
  padding:18px!important;
  border:1px solid rgba(255,255,255,.08);
  box-shadow:0 18px 40px rgba(15,23,42,.18)!important;
}
.nav-title{
  font-size:20px!important;
  padding:16px!important;
  border-radius:16px!important;
  background:rgba(15,23,42,.72)!important;
}
.nav-page-link{
  border-radius:16px!important;
  margin:10px 0!important;
  display:flex!important;
  align-items:center;
  gap:10px;
  color:#dbeafe!important;
}
.nav-page-link.active{
  background:linear-gradient(135deg,#2563eb,#1d4ed8)!important;
  box-shadow:0 12px 28px rgba(37,99,235,.28);
}
.nav-page-link:hover{
  transform:translateX(4px)!important;
  background:rgba(37,99,235,.22)!important;
}

/* KPI 卡片 */
.summary{
  gap:16px!important;
  background:transparent!important;
  padding:0!important;
  position:relative!important;
  top:auto!important;
}
.box{
  min-height:92px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  border:1px solid rgba(20,184,166,.22)!important;
  background:
    linear-gradient(135deg,rgba(236,254,255,.98),rgba(240,253,250,.98))!important;
  box-shadow:var(--ui-shadow-soft)!important;
  transition:transform .16s ease, box-shadow .16s ease;
}
.box:hover{
  transform:translateY(-2px);
  box-shadow:var(--ui-shadow)!important;
}
.box b{
  font-size:31px!important;
  letter-spacing:-.8px;
}

/* 通用卡片和区块 */
.card{
  border-radius:24px!important;
  border:1px solid var(--ui-border)!important;
  box-shadow:var(--ui-shadow)!important;
  background:rgba(255,255,255,.96)!important;
}
.section-title{
  position:relative!important;
  top:auto!important;
  z-index:auto!important;
  padding:2px 0 14px!important;
  background:transparent!important;
  border-bottom:1px solid #e8eef6!important;
}
.section-title h2{
  font-size:28px!important;
  line-height:1.2!important;
  margin-bottom:6px!important;
}
.hint{
  color:var(--ui-muted)!important;
  line-height:1.6!important;
}

/* 按钮统一 */
button{
  border-radius:12px!important;
  min-height:36px;
  box-shadow:none!important;
  transition:transform .12s ease, opacity .12s ease, box-shadow .12s ease!important;
}
button:hover{
  transform:translateY(-1px);
  box-shadow:0 8px 18px rgba(15,23,42,.12)!important;
}
button:active{transform:translateY(0)}
button.gray{background:#64748b!important}
button.red{background:var(--ui-danger)!important}
button.small{
  min-height:auto!important;
  border-radius:8px!important;
}

/* 工具栏移动端可横向滑动，避免挤压 */
.tools{
  gap:10px!important;
}
.tools button{
  white-space:nowrap;
}

/* 快速登记/筛选区 */
.quick-panel,.filter-panel,.audit-filter-panel{
  border-radius:22px!important;
  border:1px solid #cfe7f1!important;
  background:linear-gradient(135deg,#f8fdff,#ecfeff)!important;
  box-shadow:0 10px 24px rgba(14,165,233,.06);
}
.pill-title{
  border-radius:999px!important;
  background:linear-gradient(135deg,#0f172a,#1e293b)!important;
  box-shadow:0 10px 24px rgba(15,23,42,.16);
}
.quick-grid,.filter-grid,.audit-grid,.quick-extra-grid{
  grid-template-columns:repeat(auto-fit,minmax(150px,1fr))!important;
}
.quick-field label,.filter-field label,.audit-field label{
  color:#334155!important;
  letter-spacing:.2px;
}

/* 输入控件 */
input,select{
  border:1px solid #cfd8e3!important;
  background:#fff!important;
  transition:border-color .14s ease, box-shadow .14s ease!important;
}
input:focus,select:focus{
  outline:none!important;
  border-color:var(--ui-primary)!important;
  box-shadow:0 0 0 3px rgba(20,184,166,.16)!important;
}
input[readonly]{
  color:#0f172a!important;
  background:#f1f5f9!important;
}

/* 表格可读性 */
.scroll{
  border-radius:18px!important;
  border:1px solid #ccd8e5!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.6);
  background:#fff!important;
}
table{
  border-spacing:0!important;
}
th{
  color:#0f172a!important;
  font-weight:900!important;
  background:#ffead9!important;
}
td{
  background:#fff;
}
tbody tr:hover td{
  background:#f8fafc!important;
}
.col-tools button{
  padding:4px 7px!important;
  font-size:12px!important;
}
.col-name{
  line-height:1.35;
}

/* 分页条视觉 */
.pagination-bar{
  position:relative!important;
  bottom:auto!important;
  z-index:5!important;
  background:#fff!important;
  border-radius:18px!important;
  box-shadow:var(--ui-shadow-soft)!important;
}
.page-size-btn,.page-size-option,.page-btn{
  font-size:13px!important;
}

/* 核查看板 KPI */
.audit-kpi{
  border-radius:20px!important;
  box-shadow:var(--ui-shadow-soft);
}
.audit-kpi .value{
  font-size:26px!important;
}

/* 弹窗移动端 */
.modalBox{
  border-radius:24px!important;
}
.modalHeader{
  position:sticky;
  top:0;
  background:#fff;
  z-index:2;
  padding-bottom:10px;
}

/* 桌面窄屏 */
@media(max-width:1200px){
  .sidebar-layout{
    grid-template-columns:250px minmax(0,1fr);
    gap:16px!important;
  }
  .summary{
    grid-template-columns:repeat(2,minmax(180px,1fr))!important;
  }
}

/* 平板/手机：左侧导航变顶部横向导航 */
@media(max-width:900px){
  .wrap{padding:12px!important}
  #userBox{
    position:sticky;
    top:8px;
    z-index:100;
    padding:12px!important;
  }
  #userBox b{
    width:100%;
    font-size:16px!important;
    word-break:break-all;
  }
  .sidebar-layout{
    display:flex!important;
    flex-direction:column!important;
    gap:12px!important;
  }
  .sidebar-nav{
    position:sticky!important;
    top:8px!important;
    z-index:90!important;
    width:100%!important;
    border-radius:20px!important;
    padding:12px!important;
    box-sizing:border-box;
  }
  .nav-title{
    padding:10px 12px!important;
    margin-bottom:8px!important;
    font-size:16px!important;
  }
  .nav-items{
    display:flex!important;
    gap:8px;
    overflow-x:auto;
    padding-bottom:4px;
    scrollbar-width:thin;
  }
  .nav-page-link{
    flex:0 0 auto;
    min-width:max-content;
    margin:0!important;
    padding:11px 14px!important;
    font-size:15px!important;
    transform:none!important;
  }
  .nav-page-link:hover{transform:none!important}
  .main-content-flex > h1{
    font-size:26px!important;
    margin:8px 0 12px!important;
  }
  .summary,.audit-kpi-grid{
    grid-template-columns:1fr 1fr!important;
  }
  .box{
    min-height:78px;
    padding:14px!important;
  }
  .box b{
    font-size:25px!important;
  }
  .section-title h2{
    font-size:24px!important;
  }
  .tools{
    flex-wrap:nowrap!important;
    overflow-x:auto;
    padding-bottom:8px;
  }
  .tools button{
    flex:0 0 auto;
  }
  .quick-grid,.filter-grid,.audit-grid,.quick-extra-grid{
    grid-template-columns:repeat(2,minmax(140px,1fr))!important;
  }
  .scroll{
    max-height:58vh!important;
  }
  th,td{
    min-width:92px!important;
    font-size:12px!important;
    padding:4px!important;
  }
  input,select{
    height:30px!important;
    font-size:13px!important;
    padding:4px!important;
  }
}

/* 小手机 */
@media(max-width:560px){
  .wrap{padding:8px!important}
  .card{border-radius:18px!important;padding:12px!important}
  .summary,.audit-kpi-grid,.mini-kpi-row{
    grid-template-columns:1fr!important;
  }
  .quick-grid,.filter-grid,.audit-grid,.quick-extra-grid{
    grid-template-columns:1fr!important;
  }
  .section-title h2{font-size:22px!important}
  .hint{font-size:11px!important}
  .login-card input{width:100%!important}
  #userBox button{
    min-height:34px;
    padding:7px 10px!important;
  }
  .modalMask{padding:8px!important}
  .modalBox{
    width:100%!important;
    max-height:92vh!important;
    padding:12px!important;
  }
  .pagination-bar{
    justify-content:flex-start!important;
  }
}

/* 减少动画：提升低性能设备体验 */
@media (prefers-reduced-motion: reduce){
  *{animation:none!important;transition:none!important;scroll-behavior:auto!important}
}



  /* ===== 第三优先级：图表化数据看板 ===== */
  .dashboard-card{overflow:hidden}
  .dashboard-header{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;flex-wrap:wrap;margin-bottom:14px}
  .dashboard-header h2{margin:0;font-size:28px!important;color:#0f172a}
  .dashboard-subtitle{font-size:13px;color:#64748b;margin-top:6px;line-height:1.6}
  .dashboard-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
  .dash-refresh-btn{background:#0f172a!important;color:#fff!important;border-radius:12px!important;padding:9px 14px!important}
  .dash-kpi-grid{display:grid;grid-template-columns:repeat(6,minmax(145px,1fr));gap:12px;margin:12px 0 18px}
  .dash-kpi{border:1px solid #cbd5e1;border-radius:18px;padding:15px;background:linear-gradient(135deg,#ffffff,#f8fafc);box-shadow:0 8px 22px rgba(15,23,42,.06)}
  .dash-kpi .label{font-size:12px;color:#64748b;font-weight:900;margin-bottom:6px}
  .dash-kpi .value{font-size:24px;font-weight:950;color:#0f766e;white-space:nowrap}
  .dash-kpi.warn .value{color:#b45309}.dash-kpi.danger .value{color:#b91c1c}
  .dash-grid{display:grid;grid-template-columns:repeat(2,minmax(320px,1fr));gap:14px}
  .dash-panel{border:1px solid #dbeafe;border-radius:20px;background:linear-gradient(135deg,#ffffff,#f8fbff);padding:16px;box-shadow:0 10px 28px rgba(15,23,42,.06);min-height:240px}
  .dash-panel h3{margin:0 0 12px;font-size:18px;color:#0f172a;display:flex;align-items:center;gap:8px}
  .dash-empty{padding:28px;text-align:center;color:#64748b;background:#f8fafc;border-radius:14px;border:1px dashed #cbd5e1}
  .dash-bar-list{display:flex;flex-direction:column;gap:10px}
  .dash-bar-row{display:grid;grid-template-columns:125px 1fr 92px;gap:10px;align-items:center;font-size:13px}
  .dash-bar-label{font-weight:800;color:#334155;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:left}
  .dash-bar-track{height:13px;background:#e2e8f0;border-radius:999px;overflow:hidden;position:relative}
  .dash-bar-fill{height:100%;border-radius:999px;background:linear-gradient(90deg,#14b8a6,#2563eb);min-width:3px}
  .dash-bar-value{text-align:right;font-weight:900;color:#0f172a;font-variant-numeric:tabular-nums}
  .dash-bar-fill.warn{background:linear-gradient(90deg,#f59e0b,#ef4444)}
  .dash-bar-fill.ok{background:linear-gradient(90deg,#22c55e,#14b8a6)}
  .dash-table-mini{width:100%;min-width:0!important;border-collapse:separate;border-spacing:0 7px;background:transparent!important}
  .dash-table-mini th{position:static!important;background:#eef2ff!important;border:0!important;border-radius:10px;padding:9px!important;font-size:12px!important;color:#334155}
  .dash-table-mini td{border:0!important;background:#fff;padding:9px!important;border-top:1px solid #e2e8f0;border-bottom:1px solid #e2e8f0;font-size:13px!important}
  .dash-table-mini tr td:first-child{border-left:1px solid #e2e8f0;border-radius:10px 0 0 10px;font-weight:800;color:#334155}
  .dash-table-mini tr td:last-child{border-right:1px solid #e2e8f0;border-radius:0 10px 10px 0;font-weight:900;color:#0f766e;text-align:right}
  @media(max-width:1200px){.dash-kpi-grid{grid-template-columns:repeat(3,minmax(145px,1fr))}.dash-grid{grid-template-columns:1fr}}
  @media(max-width:780px){.dash-kpi-grid{grid-template-columns:repeat(2,minmax(130px,1fr))}.dash-bar-row{grid-template-columns:88px 1fr 76px}.dashboard-header h2{font-size:23px!important}.dash-panel{padding:12px}.dash-grid{gap:10px}}



  /* ===== 批量选择性能优化：减少勾选时的重绘和布局抖动 ===== */
  .batch-toolbar{contain:layout paint;}
  .batch-row-check,.batch-page-check{width:18px!important;height:18px!important;cursor:pointer;accent-color:#2563eb;}
  .batch-row-check{margin:0 4px 4px 0;vertical-align:middle;}
  td.serial-col{contain:layout paint;}


  /* ===== 第三优先级：自定义字段模板 ===== */
  .field-template-note{
    background:linear-gradient(135deg,#eff6ff,#ecfeff);
    border:1px solid #bfdbfe;
    color:#334155;
    border-radius:14px;
    padding:12px 14px;
    line-height:1.7;
    font-size:13px;
    margin-bottom:12px;
  }
  .field-template-top-actions{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin:12px 0;
  }
  .field-template-list{
    display:flex;
    flex-direction:column;
    gap:10px;
    margin-top:10px;
  }
  .field-template-item{
    display:grid;
    grid-template-columns:1fr auto;
    gap:12px;
    align-items:center;
    border:1px solid #e2e8f0;
    border-radius:16px;
    padding:12px;
    background:#f8fafc;
  }
  .field-template-name{font-weight:900;color:#0f172a;font-size:16px;margin-bottom:4px}
  .field-template-meta{font-size:12px;color:#64748b;font-weight:700}
  .field-template-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
  .field-template-actions button{padding:7px 10px;font-size:12px}
  .field-template-empty{
    border:1px dashed #94a3b8;
    color:#64748b;
    border-radius:14px;
    padding:18px;
    text-align:center;
    font-weight:700;
    background:#fff;
  }
  @media(max-width:780px){
    .field-template-item{grid-template-columns:1fr}
    .field-template-actions{justify-content:flex-start}
  }



/* ===== 继续优化：系统体检 / 本地自动备份 / 数据保护 ===== */
.health-btn{background:#0f766e!important;color:#fff!important}
.health-grid{display:grid;grid-template-columns:repeat(4,minmax(150px,1fr));gap:12px;margin:12px 0}
.health-card{border:1px solid #cbd5e1;border-radius:16px;background:linear-gradient(135deg,#ffffff,#f8fafc);padding:14px}
.health-card .label{font-size:12px;font-weight:800;color:#64748b;margin-bottom:6px}
.health-card .value{font-size:24px;font-weight:900;color:#0f172a}
.health-card.ok{background:linear-gradient(135deg,#f0fdf4,#dcfce7);border-color:#86efac}
.health-card.warn{background:linear-gradient(135deg,#fffbeb,#fef3c7);border-color:#facc15}
.health-card.danger{background:linear-gradient(135deg,#fff1f2,#fee2e2);border-color:#f87171}
.health-section{border:1px solid #e2e8f0;border-radius:16px;background:#fff;margin:12px 0;padding:14px}
.health-section h3{margin:0 0 8px;font-size:18px}
.health-list{display:flex;flex-direction:column;gap:8px;max-height:280px;overflow:auto}
.health-item{display:grid;grid-template-columns:90px 1fr;gap:10px;border:1px solid #e5e7eb;border-radius:12px;padding:8px;background:#f8fafc;font-size:13px;align-items:start}
.health-item b{color:#0f172a}
.health-empty{border:1px dashed #86efac;color:#166534;background:#f0fdf4;border-radius:12px;padding:12px;font-weight:800}
.backup-list{display:flex;flex-direction:column;gap:8px;margin-top:10px}
.backup-row{display:grid;grid-template-columns:1fr auto;gap:10px;align-items:center;border:1px solid #e2e8f0;border-radius:14px;background:#f8fafc;padding:10px}
.backup-meta{font-size:13px;color:#475569;line-height:1.6}
.backup-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.data-protect-note{background:#eff6ff;border:1px solid #bfdbfe;color:#1e3a8a;border-radius:14px;padding:12px;line-height:1.7;margin:10px 0;font-weight:700}
@media(max-width:900px){.health-grid{grid-template-columns:repeat(2,minmax(140px,1fr))}.health-item{grid-template-columns:1fr}.backup-row{grid-template-columns:1fr}.backup-actions{justify-content:flex-start}}
@media(max-width:560px){.health-grid{grid-template-columns:1fr}}



  /* ===== 表头美化：隐藏重复的左插/右插/删列工具，鼠标悬停才显示 ===== */
  .col-tools{
    position:absolute!important;
    top:6px!important;
    right:6px!important;
    display:none!important;
    align-items:center!important;
    gap:4px!important;
    padding:4px!important;
    border-radius:999px!important;
    background:rgba(255,255,255,.96)!important;
    border:1px solid #dbeafe!important;
    box-shadow:0 8px 22px rgba(15,23,42,.16)!important;
    z-index:120!important;
    white-space:nowrap!important;
  }
  th:hover > .col-tools,
  th:focus-within > .col-tools{
    display:flex!important;
  }
  .col-tools button.small{
    padding:3px 6px!important;
    font-size:11px!important;
    line-height:1.2!important;
    border-radius:999px!important;
    box-shadow:none!important;
  }
  .col-tools button.small:not(.red){
    background:#64748b!important;
  }
  .col-tools button.small.red{
    background:#ef4444!important;
  }
  th{
    position:sticky!important;
    top:0!important;
    overflow:visible!important;
  }
  .col-name{
    min-height:34px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:6px 8px!important;
    line-height:1.25!important;
  }
  #fundTable th,
  #accountTable th{
    height:54px!important;
    vertical-align:middle!important;
  }
  #fundTable th:hover,
  #accountTable th:hover{
    background:#ffedd5!important;
  }
  @media (max-width: 900px){
    .col-tools{display:none!important}
    th:hover > .col-tools{display:none!important}
  }


  .account-quick-minimal{grid-template-columns:repeat(5,minmax(150px,1fr))!important;}
  @media(max-width:1200px){.account-quick-minimal{grid-template-columns:repeat(3,minmax(140px,1fr))!important;}}
  @media(max-width:780px){.account-quick-minimal{grid-template-columns:repeat(2,minmax(140px,1fr))!important;}}
  @media(max-width:560px){.account-quick-minimal{grid-template-columns:1fr!important;}}
