/* admin 全部样式（自 public/admin.html 原样拆出，保持原顺序） */
  :root {
    --navy: #1f3a5f; --navy-active: #2d5f9e; --gold: #c9a35c; --gold-bright: #e0bd7e;
    --sidebar-grad: radial-gradient(130% 55% at 8% -6%, rgba(201,163,92,.14), rgba(201,163,92,0) 55%),
                    linear-gradient(172deg, #26436b 0%, #1f3a5f 42%, #182c49 74%, #111f36 100%);
    --sidebar-item: rgba(224,189,126,.16);
    --sidebar-item-hover: rgba(255,255,255,.10);
    --bg: #f6f8fb; --card: #ffffff; --text: #22314a; --muted: #8b97ab;
    --border: #e5e7eb;
  }
  * { margin: 0; padding: 0; box-sizing: border-box; }
  body { font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; background: var(--bg); color: var(--text); }

  .layout {
    display: grid;
    grid-template-columns: 242px 1fr;
    height: 100vh; min-height: 0; overflow: hidden;
    transition: grid-template-columns .5s ease;
  }
  .layout.collapsed { grid-template-columns: 72px 1fr; }
  .layout > .main { min-width: 0; min-height: 0; }

  /* ===== 侧边栏（深色分组折叠，参照财务系统） ===== */
  .sidebar {
    display: grid;
    grid-template-rows: auto 1fr auto auto;
    background: var(--sidebar-grad); color: #ffffff;
    box-shadow: inset 0 3px 0 var(--gold), inset 0 1px 0 rgba(255,255,255,.06), 4px 0 24px rgba(15,26,45,.18);
    padding: 18px 14px; min-height: 0; overflow: hidden;
  }
  .brand { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; margin-bottom: 18px; padding: 4px 8px; overflow: hidden; }
  .brand-text { overflow: hidden; white-space: nowrap; text-align: center; max-width: 200px; opacity: 1; transform: translateX(0); transition: opacity .2s ease .22s, transform .3s ease .16s, max-width .5s ease; }
  .brand-system { font-size: 17px; font-weight: 700; color: var(--gold-bright); letter-spacing: 2px; text-shadow: 0 1px 2px rgba(0,0,0,.35); line-height: 1.25; }
  .brand-mini { display: none; }
  .collapsed .brand { gap: 0; padding-inline: 0; }
  .collapsed .brand-text { max-width: 80px; opacity: 1; transform: translateX(0); }
  .collapsed .brand-full { display: none; }
  .collapsed .brand-mini { display: inline; letter-spacing: 1px; }

  .menu { display: grid; align-content: start; gap: 8px; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding-right: 4px; }
  .menu::-webkit-scrollbar { width: 6px; }
  .menu::-webkit-scrollbar-thumb { border-radius: 999px; background: rgba(255,255,255,.22); }
  .menu::-webkit-scrollbar-track { background: transparent; }
  .menu-group { display: grid; gap: 4px; }
  .menu-primary, .submenu-item { width: 100%; border: 0; border-radius: 6px; background: transparent; color: rgba(255,255,255,.88); cursor: pointer; font-family: inherit; text-align: left; text-shadow: 0 1px 1px rgba(0,0,0,.28); transition: background .15s ease, color .15s ease; }
  .menu-primary { display: grid; grid-template-columns: 22px 1fr; align-items: center; gap: 10px; height: 40px; padding: 0 10px; font-size: 15px; font-weight: 700; }
  .menu-icon { font-size: 18px; line-height: 1; }
  .menu-label { overflow: hidden; white-space: nowrap; max-width: 150px; opacity: 1; transform: translateX(0); transition: opacity .2s ease .22s, transform .3s ease .16s, max-width .5s ease; }
  .collapsed .menu-primary { grid-template-columns: 1fr; justify-items: center; padding: 0; }
  .collapsed .menu-label { max-width: 0; opacity: 0; transform: translateX(-8px); transition: opacity .12s ease, transform .2s ease, max-width .5s ease; }
  .menu-primary:hover, .submenu-item:hover { background: var(--sidebar-item-hover); color: #fff; }  .submenu { display: grid; gap: 2px; padding-left: 30px; }
  .submenu.closed { display: none; }
  .collapsed .submenu { display: none; }
  .submenu-item { height: 34px; padding: 0 10px; font-size: 14px; }
  .menu-group.active .menu-primary { background: var(--sidebar-item); color: var(--gold-bright); }
  .submenu-item.active { background: var(--sidebar-item); color: var(--gold-bright); box-shadow: inset 2px 0 0 var(--gold); }

  .sidebar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
  .collapsed .sidebar-actions { justify-content: center; }
  .collapsed [data-collapse] { display: none; }
  .collapsed .brand { cursor: pointer; }
  .sidebar-action { display: grid; place-items: center; width: 42px; height: 38px; border: 0; border-radius: 6px; background: rgba(255,255,255,.12); color: #ffffff; cursor: pointer; font-size: 16px; transition: background .15s ease; }
  .sidebar-action:hover { background: rgba(224,189,126,.28); color: #fff; }

  /* ===== 主区 ===== */
  .main { overflow-y: auto; padding: 24px 28px; }
  .view-title { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
  .view-sub { font-size: 13px; color: var(--muted); margin-bottom: 20px; }
  .view { display: none; }
  .view.active { display: block; }
  .card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 40px 20px; text-align: center; }
  .card .icon { font-size: 40px; margin-bottom: 12px; }
  .card h3 { font-size: 16px; margin-bottom: 8px; }
  .card p { font-size: 13px; color: var(--muted); line-height: 1.7; }
  .badge { display: inline-block; margin-top: 14px; font-size: 12px; color: var(--gold); border: 1px dashed var(--gold); border-radius: 20px; padding: 4px 14px; }

  /* ===== 银行流水导入 ===== */
  .toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
  .btn-primary { background: #2563eb; color: #fff; border: 0; border-radius: 6px; padding: 8px 14px; font-size: 14px; cursor: pointer; font-family: inherit; }
  .btn-primary:hover { background: #1d4ed8; }
  .btn-plain { background: #fff; color: #344054; border: 1px solid #d0d5dd; border-radius: 6px; padding: 8px 14px; font-size: 14px; cursor: pointer; font-family: inherit; }
  .btn-plain:hover { border-color: #98a2b3; }
  .btn-danger { background: #fff; color: #b42318; border: 1px solid #fda29b; border-radius: 6px; padding: 4px 10px; font-size: 12px; cursor: pointer; font-family: inherit; }
  .btn-danger:hover { background: #fef3f2; }
  .list-summary { color: var(--muted); font-size: 13px; }
  .toolbar-left { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
  .bank-stats { display: flex; align-items: flex-end; gap: 22px; flex-wrap: wrap; }
  .bank-stats .stat { display: flex; flex-direction: column; gap: 2px; }
  .bank-stats .stat-label { font-size: 12px; color: var(--muted); }
  .bank-stats .stat-value { font-size: 15px; font-weight: 700; color: #1f3a5f; }
  .table-shell { overflow: auto; border: 1px solid #e5e7eb; border-radius: 8px; background: #fff; }
  table.list { width: 100%; border-collapse: collapse; font-size: 13px; }
  table.list th, table.list td { padding: 9px 10px; border-bottom: 1px solid #eef2f6; text-align: left; white-space: nowrap; }
  table.list th { background: #f8fafc; color: #344054; font-weight: 600; position: sticky; top: 0; }
  /* 表头统一居中（含覆盖模块级右对齐特例）；嵌套明细表不受影响（只匹配直属表头） */
  table.list > thead > tr > th { text-align: center !important; }
  /* 嵌套在列表单元格里的明细表保持左对齐，不继承外层对齐 */
  table.list td > table { text-align: left; }
  table.list tr:hover td { background: #f8fafc; }
  .empty-tip { padding: 32px; text-align: center; color: #98a2b3; font-size: 13px; }

  /* 发票模块 */
  .seg-toggle { display: inline-flex; border: 1px solid #d0d5dd; border-radius: 8px; overflow: hidden; }
  .seg-toggle button { border: none; background: #fff; color: #344054; padding: 7px 14px; font-size: 13px; cursor: pointer; }
  .seg-toggle button + button { border-left: 1px solid #d0d5dd; }
  .seg-toggle button.active { background: #1668dc; color: #fff; font-weight: 600; }
  .inv-detail-row > td { background: #f8fafc; }
  .inv-detail-box { padding: 6px 14px 12px; }
  .inv-items { width: 100%; border-collapse: collapse; font-size: 12.5px; background: #fff; border: 1px solid #e5e7eb; border-radius: 6px; }
  .inv-items th, .inv-items td { padding: 7px 10px; border-bottom: 1px solid #eef2f6; text-align: left; white-space: nowrap; }
  .inv-items th { background: #f8fafc; color: #344054; font-weight: 600; }
  .inv-arrow { user-select: none; }

  /* 付款与发票比对 */
  .ivc-diff.pos { color: #d4380d; }
  .ivc-diff.neg { color: #1f9254; }
  .ivc-diff.zero { color: #98a2b3; }
  .ivc-arrow { user-select: none; }

  /* 下拉支出明细 */
  .ivc-detail-row > td { background: #f8fafc; }
  .ivc-detail-box { padding: 8px 14px 12px; }
  .ivc-items { width: 100%; border-collapse: collapse; background: #fff; font-size: 12px; }
  .ivc-items th, .ivc-items td { border: 1px solid #e5e7eb; padding: 5px 8px; white-space: nowrap; text-align: left; }
  .ivc-items th { background: #f1f5f9; font-weight: 600; color: #344054; }
  .ivc-items tfoot td { font-weight: 700; background: #f8fafc; color: #1f3a5f; }
  .ivc-excluded td { background: #fff7d6; }
  .ivc-excluded td.ivc-diff { background: #fff7d6; }
  .ivc-refund td { background: #e8f7ef; }
  .ivc-flag-btn { cursor: pointer; border: 1px solid #d0d5dd; border-radius: 12px; padding: 2px 10px; font-size: 12px; background: #fff; }
  .ivc-flag-btn.on { color: #1f9254; border-color: #b7dfc9; }
  .ivc-flag-btn.on:hover { background: #f0faf4; }
  .ivc-flag-btn.off { color: #b8860b; background: #fff3bf; border-color: #e8c766; font-weight: 600; }
  .ivc-flag-btn.off:hover { background: #ffec99; }
  .ivc-flag-btn:disabled { opacity: .5; cursor: wait; }

  /* 「不显示数据」弹窗 */
  .ivc-modal-mask { position: fixed; inset: 0; background: rgba(15, 23, 42, .45); display: none; align-items: center; justify-content: center; z-index: 60; }
  .ivc-modal { background: #fff; border-radius: 10px; width: 860px; max-width: 92vw; max-height: 86vh; display: flex; flex-direction: column; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
  .ivc-modal-head { font-size: 16px; font-weight: 700; color: #101828; padding: 16px 20px 6px; display: flex; align-items: center; justify-content: space-between; }
  .ivc-modal-close { cursor: pointer; color: #98a2b3; font-size: 20px; line-height: 1; padding: 0 4px; }
  .ivc-modal-close:hover { color: #d4380d; }
  .ivc-modal-tip { font-size: 12px; color: #667085; padding: 0 20px 10px; }
  .ivc-modal-body { display: flex; gap: 12px; padding: 0 20px; overflow: hidden; }
  .ivc-pane { flex: 1 1 0; display: flex; flex-direction: column; border: 1px solid #e5e7eb; border-radius: 8px; overflow: hidden; min-height: 320px; max-height: 52vh; }
  .ivc-pane-title { font-size: 13px; font-weight: 600; color: #344054; background: #f8fafc; padding: 8px 10px; border-bottom: 1px solid #e5e7eb; }
  .ivc-remark-input { width: 100%; height: 28px; padding: 0 6px; border: 1px solid transparent; border-radius: 4px; background: transparent; font-family: inherit; font-size: 12px; color: #344054; }
  .ivc-remark-input:hover { border-color: #d0d5dd; background: #fff; }
  .ivc-remark-input:focus { outline: none; border-color: #2d5fad; background: #fff; box-shadow: 0 0 0 2px rgba(45,95,173,.12); }
  .ivc-remark-td { white-space: normal !important; }
  .ivc-remark-text { white-space: normal; word-break: break-all; line-height: 1.45; cursor: text; color: #344054; }
  .ivc-remark-ph { color: #c2c7d0; cursor: text; font-size: 12px; }
  .ivc-search { margin: 8px; padding: 6px 10px; border: 1px solid #d0d5dd; border-radius: 6px; font-size: 13px; outline: none; }
  .ivc-search:focus { border-color: #1668dc; }
  .ivc-pane-list { flex: 1; overflow-y: auto; padding: 0 6px 8px; }
  .ivc-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 6px; cursor: pointer; font-size: 13px; color: #101828; }
  .ivc-item:hover { background: #f0f6ff; }
  .ivc-item-head { position: sticky; top: 0; background: #fff; font-weight: 600; color: #344054; border-bottom: 1px dashed #e5e7eb; border-radius: 0; }
  .ivc-pane-empty { padding: 18px 10px; color: #98a2b3; font-size: 12px; text-align: center; }
  .ivc-middle { display: flex; flex-direction: column; gap: 10px; justify-content: center; align-items: stretch; }
  .ivc-middle .btn-primary, .ivc-middle .btn-plain { white-space: nowrap; padding: 7px 14px; font-size: 13px; }
  .ivc-modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px 16px; }

  .overlay { position: fixed; inset: 0; background: rgba(15, 23, 42, .45); display: none; align-items: center; justify-content: center; z-index: 50; }
  .overlay.open { display: flex; }
  .dialog-sm { width: min(560px, 94vw); }
  .toolbar-right { display: flex; align-items: center; gap: 8px; }
  .ie-keyword { border: 1px solid #d0d5dd; border-radius: 6px; padding: 7px 10px; font-size: 13px; font-family: inherit; width: 220px; }
  .ie-keyword:focus { outline: none; border-color: #2563eb; }
  .ie-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
  .ie-field { display: flex; flex-direction: column; gap: 6px; }
  .ie-field:first-child, .ie-field:nth-child(2) { grid-column: span 1; }
  .ie-label { font-size: 13px; color: #344054; font-weight: 600; }
  .ie-form input, .ie-form select { border: 1px solid #d0d5dd; border-radius: 6px; padding: 8px 10px; font-size: 13px; font-family: inherit; }
  .ie-form input:focus, .ie-form select:focus { outline: none; border-color: #2563eb; background: #f8faff; }
  .ie-form input[readonly] { background: #f8fafc; color: #667085; }
  .ie-toggle { border: 0; background: transparent; cursor: pointer; color: #667085; font-size: 11px; width: 16px; padding: 0; margin-right: 4px; }
  .ie-toggle.leaf { visibility: hidden; }
  .ie-code-cell { display: flex; align-items: center; }
  .ie-code-text { font-variant-numeric: tabular-nums; }
  .ie-row-actions { display: flex; gap: 10px; }
  .ie-link { border: 0; background: transparent; color: #2563eb; cursor: pointer; font-size: 13px; padding: 0; font-family: inherit; }
  .ie-link:hover { text-decoration: underline; }
  .ie-link.danger { color: #b42318; }
  .sel-hint { font-size: 13px; color: var(--muted); }
  .bank-item-cell { display: flex; align-items: center; gap: 6px; }
  .bank-item-text { font-size: 13px; color: #1f3a5f; }
  .bank-item-empty { font-size: 13px; color: #b0b8c4; }
  /* 未填制收支项目的行：黄色高亮 */
  tr.bank-row-unfilled td { background: #fff8d1; }
  table.list tr.bank-row-unfilled:hover td { background: #ffefad; }
  tr.bank-row-unfilled .bank-item-empty { color: #b45309; font-weight: 600; }

  /* ===== 银行流水列表筛选 ===== */
  .bank-filters {
    display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap;
    margin: 0 0 14px; padding: 12px 14px; background: #fff;
    border: 1px solid #e5e7eb; border-radius: 8px;
  }
  .bank-filters .flt-label { white-space: nowrap; }
  .bank-filters input[type="date"],
  .bank-filters input[type="text"],
  .bank-filters select {
    height: 36px; padding: 0 10px; border: 1px solid var(--border); border-radius: 8px;
    background: #fff; color: var(--text); font-family: inherit; font-size: 13.5px;
  }
  .bank-filters input[type="date"]:focus,
  .bank-filters input[type="text"]:focus,
  .bank-filters select:focus { outline: 0; border-color: var(--navy-active); }
  .bank-filters .flt-amount { width: 108px; }
  .bank-filters .flt-text { width: 148px; }
  .bank-filters .rp-select { min-width: 108px; }
  .bank-item-edit { border: 0; background: transparent; color: #2563eb; cursor: pointer; font-size: 12px; padding: 0; font-family: inherit; }
  /* ===== 拆分流水：父/子标识 ===== */
  .bank-split-badge { display: inline-block; font-size: 11px; line-height: 1; padding: 3px 6px; border-radius: 4px; margin-right: 5px; vertical-align: 1px; }
  .bank-split-badge.parent { background: #f7ecd7; color: #8a6a1f; border: 1px solid #e2cd9e; }
  .bank-split-badge.child { background: #e8eefb; color: #2d5fad; border: 1px solid #c4d4ef; }
  /* ===== 股东投资+借款 汇总表 ===== */
  .sh-ratio-input { width: 92px; height: 30px; padding: 0 8px; border: 1px solid var(--border); border-radius: 6px; font-family: inherit; font-size: 13px; }
  .sh-ratio-input:focus { outline: none; border-color: #2d5fad; box-shadow: 0 0 0 2px rgba(45,95,173,.12); }
  .sh-amt { color: #c0392b; font-weight: 600; }
  .sh-code { margin-left: 6px; font-size: 11px; color: #98a2b3; }
  #shTable th, #shTable td, #dvTable th, #dvTable td, #rpTable th, #rpTable td { white-space: nowrap; }
  #shTable th:nth-child(2), #shTable td:nth-child(2),
  #dvTable th:nth-child(2), #dvTable td:nth-child(2),
  #rpTable th:nth-child(2), #rpTable td:nth-child(2) { text-align: left; }
  #shTable th:nth-child(3), #shTable td:nth-child(3),
  #dvTable th:nth-child(3), #dvTable td:nth-child(3),
  #rpTable th:nth-child(3), #rpTable td:nth-child(3) { text-align: left; }
  #shTable th:nth-child(n+4), #shTable td:nth-child(n+4),
  #dvTable th:nth-child(n+4), #dvTable td:nth-child(n+4),
  #rpTable th:nth-child(n+4), #rpTable td:nth-child(n+4) { text-align: right; }
  .sh-num { color: #1f2937; }
  .sh-muted { color: #98a2b3; }
  #shTable tfoot td, #dvTable tfoot td, #rpTable tfoot td { font-weight: 700; background: #f8fafc; border-top: 2px solid #e5e7eb; color: #1f3a5f; }
  .sh-share { color: #1f3a5f; font-weight: 600; }
  .sh-pending { color: #1668dc; font-weight: 600; font-variant-numeric: tabular-nums; }
  /* 股东计划筹措资金总额行（合计下方） */
  .sh-plan-row td { font-weight: 400; color: #1f2937; text-align: left !important; }
  .sh-plan-label { font-weight: 700; color: #1f3a5f; }
  .sh-plan-input { width: 110px; padding: 4px 8px; border: 1px solid #d0d5dd; border-radius: 6px; font-size: 13px; text-align: right; }
  .sh-plan-input:focus { outline: none; border-color: #1668dc; box-shadow: 0 0 0 2px rgba(22,104,220,.12); }
  .sh-plan-unit { font-weight: 700; margin-left: 4px; }
  .sh-plan-tip { font-size: 12px; color: #0e9f6e; margin-left: 10px; }
  .sh-plan-note { font-size: 12px; color: #98a2b3; margin-left: 10px; }
  .sh-drag-tip { font-size: 12px; color: #98a2b3; margin-left: 4px; }
  /* 筹备期投入明细 */
  #view-precost_invest table.list th:nth-child(n+4), #view-precost_invest table.list td:nth-child(n+4) { text-align: right; }
  #view-precost_invest table.list td:nth-child(3) { text-align: left; }
  #view-precost_invest table.list tfoot td { font-weight: 700; background: #f8fafc; border-top: 2px solid #e5e7eb; color: #1f3a5f; }
  #view-precost_invest .pi-amt { color: #b42318; font-weight: 600; }
  #view-precost_invest .pi-num { color: #1f2937; }
  #view-precost_invest .pi-src { display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 10px; }
  #view-precost_invest .pi-src.bank { background: #e8eefb; color: #2d5fad; }
  #view-precost_invest .pi-src.cash { background: #e6f5ec; color: #1c7a43; }
  #view-precost_invest .pi-src.huazhu { background: #fdf0e7; color: #b25e12; }
  /* 两张逐笔明细：收支项目/对方户名/摘要内容左对齐（投入金额仍右对齐） */
  #view-precost_invest #piDetailTable td:nth-child(4),
  #view-precost_invest #piDetailTable td:nth-child(5),
  #view-precost_invest #piDetailTable td:nth-child(6),
  #view-precost_invest #piHzTable td:nth-child(4),
  #view-precost_invest #piHzTable td:nth-child(5),
  #view-precost_invest #piHzTable td:nth-child(6) { text-align: left; }
  .sh-sub-tip { font-size: 12px; color: #667085; margin: 0 0 12px; }
  td.pi-seq { color: #667085; font-variant-numeric: tabular-nums; text-align: center; width: 52px; }
  /* 银行收支明细（台账） */
  #view-finance table.list th:nth-child(n+6), #view-finance table.list td:nth-child(n+6) { text-align: right; }
  #view-finance table.list tfoot td { font-weight: 700; background: #f8fafc; border-top: 2px solid #e5e7eb; color: #1f3a5f; }
  #view-finance .pi-amt { color: #b42318; font-weight: 600; }
  #view-finance .pi-num { color: #1f2937; }
  /* ===== 表格列宽拖拽（表头右边界） ===== */
  table.list.dg-col-drag { table-layout: fixed; }
  table.list.dg-col-drag th { position: sticky; overflow: hidden; text-overflow: ellipsis; }
  table.list.dg-col-drag td { overflow: hidden; text-overflow: ellipsis; }
  .dg-col-resizer { position: absolute; top: 0; right: 0; width: 10px; height: 100%; cursor: col-resize; user-select: none; z-index: 3; }
  .dg-col-resizer::after { content: ""; position: absolute; top: 8px; right: 2px; width: 3px; height: calc(100% - 16px); background: rgba(31,58,95,.28); border-radius: 2px; transition: background .15s ease, box-shadow .15s ease; }
  .dg-col-resizer:hover::after, .dg-col-resizer.active::after { background: var(--gold, #c9a35f); box-shadow: 0 0 4px rgba(201,163,95,.85); }
  body.dg-col-resizing { cursor: col-resize !important; user-select: none; }
  body.dg-col-resizing .dg-col-resizer { cursor: col-resize; }
  /* ===== 股东行展开：归集明细 ===== */
  .sh-expand { width: 18px; height: 18px; margin-right: 6px; padding: 0; border: 1px solid var(--border); border-radius: 4px; background: #fff; color: #2d5fad; font-size: 11px; line-height: 1; cursor: pointer; font-family: inherit; }
  .sh-expand:hover { background: #eef4fd; border-color: #bcd0ee; }
  .sh-expand.open { background: #1f3a5f; border-color: #1f3a5f; color: #fff; }
  #shTable tr.sh-detail-row > td, #dvTable tr.sh-detail-row > td, #rpTable tr.sh-detail-row > td { background: #fafcff; padding: 0; white-space: normal; overflow: visible; text-align: left; }
  #shTable tr.sh-detail-row:hover > td, #dvTable tr.sh-detail-row:hover > td, #rpTable tr.sh-detail-row:hover > td { background: #fafcff; }
  /* 筹备期投入明细：分项行下拉展开逐笔明细 */
  #piTable tr.pi-detail-row > td { background: #fafcff; padding: 0; white-space: normal; overflow: visible; text-align: left; }
  #piTable tr.pi-detail-row:hover > td { background: #fafcff; }
  #piSupplierTable tr.pi-detail-row > td { background: #fafcff; padding: 0; white-space: normal; overflow: visible; text-align: left; }
  #piSupplierTable tr.pi-detail-row:hover > td { background: #fafcff; }
  /* 供应商表列序与投入统计差一列：银行/现金/华住/合计/占比从第 3 列起右对齐 */
  #view-precost_invest #piSupplierTable th:nth-child(n+3),
  #view-precost_invest #piSupplierTable td:nth-child(n+3) { text-align: right; }
  #piTable .sh-detail, #piSupplierTable .sh-detail { overflow-x: auto; }
  #piTable .sh-detail-table.dg-det-drag, #piSupplierTable .sh-detail-table.dg-det-drag { table-layout: fixed; }
  #piTable .sh-detail-table.dg-det-drag th, #piTable .sh-detail-table.dg-det-drag td,
  #piSupplierTable .sh-detail-table.dg-det-drag th, #piSupplierTable .sh-detail-table.dg-det-drag td { overflow: hidden; text-overflow: ellipsis; }
  #piTable .sh-detail-table th, #piSupplierTable .sh-detail-table th { position: relative; }
  .sh-detail { padding: 10px 14px 14px; }
  .sh-detail-head { font-size: 13px; color: #1f3a5f; margin-bottom: 8px; }
  .sh-detail-sub { margin-left: 10px; font-size: 12px; color: #667085; }
  .sh-detail-tip { font-size: 12px; color: #98a2b3; padding: 6px 0; }
  .sh-detail-table { width: 100%; border-collapse: collapse; font-size: 12.5px; margin-bottom: 10px; background: #fff; }
  .sh-detail-table th, .sh-detail-table td { padding: 6px 10px; border-bottom: 1px solid #eef2f6; text-align: left; white-space: nowrap; }
  .sh-detail-table th { background: #f4f7fb; color: #475467; font-weight: 600; }
  .sh-detail-table td.num, .sh-detail-table th.num { text-align: right; }
  .sh-detail-table td.strong { font-weight: 600; color: #c0392b; }
  .sh-detail-table td.mono, .sh-detail-code { font-family: ui-monospace, Menlo, Consolas, monospace; }
  .sh-detail-code { color: #98a2b3; margin-right: 6px; }
  .sh-detail-table td.pos { color: #c0392b; }
  .sh-detail-table td.neg { color: #0f9d58; }
  .sh-detail-table td.sh-detail-summary { max-width: 300px; overflow: hidden; text-overflow: ellipsis; }
  .sh-side { display: inline-block; font-size: 11px; line-height: 1; padding: 3px 6px; border-radius: 4px; }
  .sh-side.invest { background: #f7ecd7; color: #8a6a1f; border: 1px solid #e2cd9e; }
  .sh-side.loan { background: #e8eefb; color: #2d5fad; border: 1px solid #c4d4ef; }
  tr.bank-row-parent td { background: #fdfaf3; }
  tr.bank-row-child td:first-child { padding-left: 14px; }
  tr.bank-row-child td { color: #475467; }
  tr.bank-row-child .bank-child-mark { color: #98a2b3; margin-right: 4px; font-size: 12px; }
  .bank-split-meta { font-size: 12px; color: #667085; margin: 4px 0 12px; }
  .bank-split-meta b { color: #1f3a5f; }
  /* 拆分行编辑器：金额 + 收支项目 */
  .bank-split-row { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
  .bank-split-row .row-idx { width: 18px; text-align: right; color: #667085; font-size: 13px; flex: none; }
  .bank-split-row input[type="text"] {
    width: 118px; height: 34px; padding: 0 8px; border: 1px solid var(--border);
    border-radius: 8px; font-size: 13.5px; font-family: inherit; box-sizing: border-box; flex: none;
  }
  .bank-split-row select {
    flex: 1; min-width: 0; height: 34px; padding: 0 6px; border: 1px solid var(--border);
    border-radius: 8px; font-size: 13px; font-family: inherit; background: #fff; color: var(--text);
  }
  .bank-split-row input:focus, .bank-split-row select:focus { outline: 0; border-color: var(--navy-active); }
  .bank-split-row .row-del { border: 0; background: transparent; color: #b42318; cursor: pointer; font-size: 16px; flex: none; }
  #bankSplitSum.ok, #bankSplitSumHint.ok { color: #067647; }
  #bankSplitSum.bad, #bankSplitSumHint.bad { color: #b42318; }
  .bank-item-edit:hover { text-decoration: underline; }
  table.list th input[type="checkbox"], table.list td input[type="checkbox"] { cursor: pointer; }
  .ie-level { color: #475467; font-variant-numeric: tabular-nums; }
  .ie-status { display: inline-block; padding: 1px 9px; border-radius: 10px; font-size: 12px; line-height: 18px; }
  .ie-status.on { background: #ecfdf3; color: #067647; border: 1px solid #abefc6; }
  .ie-status.off { background: #f2f4f7; color: #667085; border: 1px solid #e4e7ec; }
  /* 收支项目设置：收入/支出方向列 */
  .ie-direction-select { min-width: 86px; padding: 3px 6px; font-size: 12.5px; border: 1px solid #d0d5dd; border-radius: 6px; background: #fff; color: #101828; }
  .ie-direction-select:focus { outline: none; border-color: #1f3a5f; }
  .ie-direction-inherit { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; line-height: 18px; background: #eef4ff; color: #1f3a5f; border: 1px solid #c7d7f5; }
  /* 财务指标-收支汇总表：双栏树形 */
  .fs-panels { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; margin-top: 14px; }
  @media (max-width: 1100px) { .fs-panels { grid-template-columns: 1fr; } }
  .fs-panel { background: #fff; border: 1px solid #e4e7ec; border-radius: 10px; overflow: hidden; }
  .fs-panel-head { padding: 10px 14px; font-weight: 600; font-size: 14px; color: #fff; }
  .fs-panel-head.fs-income { background: #0e9f6e; }
  .fs-panel-head.fs-expense { background: #c2410c; }
  .fs-name-cell { display: inline-flex; align-items: center; gap: 6px; }
  .fs-code { color: #667085; font-size: 12px; }
  .fs-name { color: #101828; }
  /* 一级项目行：加粗蓝字醒目 */
  .fs-root-row td { font-weight: 700; color: #1668dc; }
  .fs-root-row td .fs-code, .fs-root-row td .fs-name { color: #1668dc; }
  /* 收入/支出项目汇总：合计行加粗蓝字 */
  #fsIncomeTable tfoot td, #fsExpenseTable tfoot td { color: #1668dc; font-weight: 700; }
  .fs-footnote { margin-top: 10px; font-size: 12px; color: #98a2b3; padding: 0 2px; }
  .fs-balances { margin-top: 14px; padding: 12px 16px; background: #f8fafc; border: 1px solid #eef2f6; border-radius: 10px; display: flex; flex-direction: column; gap: 6px; max-width: 420px; }
  .fs-balance-row { display: flex; align-items: baseline; justify-content: space-between; font-size: 13px; }
  .fs-balance-label { color: #667085; }
  .fs-balance-value { color: #101828; font-weight: 700; font-variant-numeric: tabular-nums; }
  .fs-balance-total { margin-top: 2px; padding-top: 8px; border-top: 1px dashed #d0d5dd; font-size: 14px; }
  .fs-balance-total .fs-balance-label { color: #1668dc; font-weight: 700; }
  .fs-balance-total .fs-balance-value { color: #1668dc; font-size: 15px; }
    .dialog { width: min(1400px, 96vw); max-height: 94vh; display: flex; flex-direction: column; background: #fff; border-radius: 12px; box-shadow: 0 20px 60px rgba(15,23,42,.25); }
  .dialog-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid #eef2f6; }
  .dialog-head h3 { font-size: 16px; font-weight: 700; }
  .dialog-head-left { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
  .dialog-head-hint { font-size: 12px; color: var(--muted); white-space: nowrap; }
  .dialog-close { border: 0; background: transparent; font-size: 20px; cursor: pointer; color: #667085; line-height: 1; }
  .dialog-actions-top { display: flex; gap: 8px; }
  .dialog-body { overflow: auto; padding: 18px 20px; }
  .file-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
  .file-row .file-name { font-size: 13px; color: #344054; }
  .file-row .file-name.parsed { color: #7c3aed; font-weight: 600; }
  .dialog-grid { width: 100%; border-collapse: collapse; font-size: 13px; }
  .dialog-grid th, .dialog-grid td { border: 1px solid #e5e7eb; padding: 4px; text-align: left; }
  .dialog-grid th { background: #f8fafc; color: #344054; font-weight: 600; white-space: nowrap; padding: 9px 10px; }
  .dialog-grid td input { width: 100%; min-width: 108px; border: 1px solid transparent; border-radius: 4px; padding: 6px 8px; font-size: 13px; font-family: inherit; box-sizing: border-box; }
  .dialog-grid td input:focus { outline: none; border-color: #2563eb; background: #f8faff; }
  .dialog-grid td .cell-del { border: 0; background: transparent; color: #b42318; cursor: pointer; font-size: 16px; }
  .dialog-body-actions { display: flex; gap: 10px; margin-top: 14px; justify-content: flex-end; }
  .ie-label .req { color: #d92d20; font-weight: 700; }
  /* ===== 角色 / 权限 ===== */
  .perm-tree { max-height: 46vh; overflow: auto; border: 1px solid #e5e7eb; border-radius: 8px; padding: 6px; background: #fff; }
  .perm-node { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border-radius: 6px; font-size: 13px; }
  .perm-node:hover { background: #f8fafc; }
  .perm-node label { display: flex; align-items: center; gap: 8px; cursor: pointer; min-width: 0; }
  .perm-node .perm-code { color: #98a2b3; font-size: 12px; font-variant-numeric: tabular-nums; }
  /* ===== 现金明细账筛选 ===== */
  .flt-label { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: #344054; }
  .flt-sep { font-size: 13px; color: #98a2b3; }
  /* ===== 区间选择控件（筛选用） ===== */
  .range-picker { position: relative; display: inline-block; }
  .rp-trigger {
    display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px;
    border: 1px solid var(--border); border-radius: 8px; background: #fff;
    color: var(--text); font-family: inherit; font-size: 13.5px; cursor: pointer; min-width: 216px;
    transition: border-color .15s ease, box-shadow .15s ease;
  }
  .rp-trigger:hover { border-color: #c3d0e4; }
  .rp-trigger .rp-text { flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .rp-trigger .rp-text.ph { color: #98a2b3; }
  .rp-caret { width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent; border-top: 5px solid #98a2b3; transition: transform .18s ease; }
  .range-picker.open .rp-trigger { border-color: var(--navy-active); box-shadow: 0 0 0 3px rgba(45,95,158,.12); }
  .range-picker.open .rp-caret { transform: rotate(180deg); }
  .rp-panel {
    position: absolute; z-index: 60; top: calc(100% + 6px); left: 0; width: 296px; padding: 12px;
    background: #fff; border: 1px solid var(--border); border-radius: 10px;
    box-shadow: 0 14px 34px rgba(15,26,45,.16); display: none;
  }
  .range-picker.open .rp-panel { display: block; }
  .rp-presets { display: flex; gap: 6px; margin-bottom: 10px; }
  .rp-preset {
    flex: 1; height: 28px; border: 1px solid var(--border); border-radius: 6px; background: #f8fafd;
    color: #475467; font-family: inherit; font-size: 12.5px; cursor: pointer; transition: all .15s ease;
  }
  .rp-preset:hover { border-color: var(--navy-active); color: var(--navy-active); }
  .rp-preset.on { background: rgba(45,95,158,.1); border-color: var(--navy-active); color: var(--navy-active); font-weight: 700; }
  .rp-fields { display: flex; align-items: center; gap: 8px; }
  .rp-fields input {
    flex: 1; min-width: 0; height: 34px; padding: 0 8px; border: 1px solid var(--border);
    border-radius: 6px; background: #fff; color: var(--text); font-family: inherit; font-size: 13px;
  }
  .rp-fields input:focus { outline: 0; border-color: var(--navy-active); }
  .rp-dash { color: #98a2b3; font-size: 13px; }
  .rp-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
  .rp-clear { height: 32px; padding: 0 14px; border: 1px solid var(--border); border-radius: 6px; background: #fff; color: #667085; font-family: inherit; font-size: 13px; cursor: pointer; }
  .rp-clear:hover { border-color: #c3d0e4; }
  .rp-ok { height: 32px; padding: 0 18px; border: 0; border-radius: 6px; background: var(--navy-active); color: #fff; font-family: inherit; font-size: 13px; cursor: pointer; }
  .rp-ok:hover { background: #24507f; }
  .rp-select {
    height: 36px; min-width: 152px; padding: 0 10px; border: 1px solid var(--border); border-radius: 8px;
    background: #fff; color: var(--text); font-family: inherit; font-size: 13.5px; cursor: pointer;
  }
  .rp-select:focus { outline: 0; border-color: var(--navy-active); }
  .cd-stat-alt { color: #b45309; }
  .perm-node .perm-type { font-size: 12px; color: #7c3aed; background: #f5f3ff; border: 1px solid #ddd6fe; border-radius: 8px; padding: 0 6px; }
  .perm-children { margin-left: 16px; border-left: 1px dashed #e5e7eb; padding-left: 6px; }
  /* ===== 现金移交 ===== */
  .ct-grid { display: grid; grid-template-columns: 1fr 320px 1fr; gap: 14px; }
  .ct-panel { border: 1px solid #e5e7eb; border-radius: 10px; background: #fbfcfe; padding: 14px; display: flex; flex-direction: column; min-height: 320px; }
  .ct-panel h4 { margin: 0 0 12px; font-size: 14px; color: #344054; }
  .ct-panel .ct-muted { font-size: 12px; color: #98a2b3; margin-left: 8px; font-weight: 400; }
  .ct-from-box { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; border: 1px dashed #d0d5dd; border-radius: 8px; background: #fff; padding: 24px 12px; }
  .ct-from-avatar { width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(160deg, #26436b, #1f3a5f 60%, #111f36); box-shadow: inset 0 1px 0 rgba(224,189,126,.4); color: #e0bd7e; display: grid; place-items: center; font-size: 24px; }
  .ct-from-name { font-size: 16px; font-weight: 700; }
  .ct-from-role { font-size: 12px; color: #8b97ab; }
  .ct-mid { display: flex; flex-direction: column; gap: 12px; justify-content: center; }
  .ct-mid .ie-field { gap: 6px; }
  .ct-arrow { text-align: center; color: #98a2b3; font-size: 18px; }
  .ct-inbox { flex: 1; overflow: auto; display: flex; flex-direction: column; gap: 10px; }
  .ct-item { border: 1px solid #e5e7eb; border-radius: 8px; background: #fff; padding: 10px 12px; }
  .ct-item-head { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
  .ct-item-name { font-size: 13px; font-weight: 600; color: #1f3a5f; }
  .ct-item-meta { font-size: 12px; color: #8b97ab; white-space: nowrap; }
  .ct-item-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .ct-item-remark { font-size: 12px; color: #667085; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ct-btn-sm { padding: 5px 12px; font-size: 13px; }
  @media (max-width: 1100px) { .ct-grid { grid-template-columns: 1fr; } }

  /* ===== 侧栏用户区（登录态） ===== */
  .sidebar-user {
    display: flex; align-items: center; gap: 9px; margin-bottom: 10px;
    padding: 8px; border-radius: 8px; background: rgba(255,255,255,.1); overflow: hidden;
  }
  .sidebar-user .su-avatar {
    flex: 0 0 auto; width: 34px; height: 34px; border-radius: 50%;
    display: grid; place-items: center; font-size: 14px; font-weight: 700; color: #fff;
    background: rgba(224,189,126,.22); border: 1px solid rgba(224,189,126,.45);
  }
  .sidebar-user .su-text { min-width: 0; flex: 1; overflow: hidden; }
  .sidebar-user .su-name { font-size: 13.5px; font-weight: 700; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sidebar-user .su-role { font-size: 11.5px; color: rgba(255,255,255,.74); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sidebar-user .su-logout {
    flex: 0 0 auto; width: 30px; height: 30px; border: 0; border-radius: 6px; cursor: pointer;
    background: rgba(255,255,255,.16); color: #fff; font-size: 14px; display: grid; place-items: center;
  }
  .sidebar-user .su-logout:hover { background: rgba(255,120,90,.55); }
  .collapsed .sidebar-user { justify-content: center; padding: 6px; gap: 0; }
  .collapsed .sidebar-user .su-text, .collapsed .sidebar-user .su-logout { display: none; }

  /* ===== 修改密码 ===== */
  .pwd-card { max-width: 460px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 28px; }
  .pwd-field { margin-bottom: 18px; }
  .pwd-field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 7px; }
  .pwd-field input {
    width: 100%; height: 42px; padding: 0 12px; font-size: 14px; font-family: inherit; color: var(--text);
    background: #fff; border: 1px solid var(--border); border-radius: 8px; outline: none;
    transition: border-color .16s ease;
  }
  .pwd-field input:focus { border-color: var(--navy-active); }
  .pwd-tip { font-size: 12px; color: var(--muted); margin: -6px 0 18px; line-height: 1.7; }
  .pwd-msg { display: none; margin: 4px 0 14px; padding: 9px 13px; border-radius: 8px; font-size: 12.5px; line-height: 1.6;
    background: #f3f7fd; border: 1px solid var(--border); color: var(--text); }
  .pwd-msg.show { display: block; }
  .pwd-msg.err { background: #fdf3f3; border-color: #eccfce; color: #a94442; }
  .dg-hidden { display: none !important; }

