/* 贤仕达ERP 样式 — 1:1 还原工程宝界面风格 */
:root {
  --primary: #367ce8;
  --primary-dark: #2b66d9;
  --primary-light: #e8f1ff;
  --danger: #e5534b;
  --text: #303133;
  --text-sub: #909399;
  --border: #e8eaed;
  --bg: #f0f2f5;
  --card: #fff;
  --radius: 4px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
/* ===== 全局填充布局：整页锁定视口高度，列表页表格内部滚动（工程宝式） ===== */
#root { height: 100vh; display: flex; flex-direction: column; overflow: hidden; }
#content { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; }

body { font-family: "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif; font-size: 14px; color: var(--text); background: var(--bg); }
button { font-family: inherit; cursor: pointer; }
a { cursor: pointer; }
.num { font-variant-numeric: tabular-nums; }
.neg { color: var(--danger) !important; }

/* ===== 顶导航（工程宝式：深蓝品牌块 + 亮蓝导航条 + 紧凑） ===== */
.topbar {
  display: flex; align-items: stretch; height: 52px; padding: 0 0 0 0;
  background: #3B8CF7; color: #fff; flex: none; position: relative; z-index: 100;
}
.brand {
  display: flex; align-items: center; gap: 10px; margin-right: 8px;
  background: #3B8CF7; padding: 0 22px 0 6px; height: 52px;
}
.brand-logo {
  width: 36px; height: 36px; border-radius: 7px; background: #fff;
  object-fit: contain; padding: 3px; box-sizing: border-box;
}
.brand-name { font-size: 18px; font-weight: 700; letter-spacing: 1.5px; }
.nav { display: flex; flex: 1; height: 100%; justify-content: center; }
.nav-item {
  background: none; border: none; color: rgba(255,255,255,.94); font-size: 15px;
  padding: 0 24px; height: 52px; transition: background .15s;
}
.nav-item:hover { background: rgba(255,255,255,.12); color: #fff; }
.nav-item.active { background: #2E72D0; color: #fff; font-weight: 600; }
.nav-right { display: flex; align-items: center; gap: 4px; padding-right: 10px; }
.nav-icon-btn {
  background: none; border: none; color: #fff; font-size: 22px; width: 40px; height: 52px;
  position: relative; display: flex; align-items: center; justify-content: center; opacity: .92;
}
.nav-icon-btn:hover { opacity: 1; }
.nav-badge {
  position: absolute; top: 8px; right: 0; background: #f5594c; color: #fff; font-size: 10px;
  min-width: 18px; height: 14px; border-radius: 8px; padding: 0 4px; line-height: 14px;
  text-align: center; display: none;
}
.user-box { display: flex; align-items: center; gap: 7px; margin-left: 6px; position: relative; cursor: pointer; height: 52px; padding: 0 6px; }
.user-box:hover { background: rgba(255,255,255,.12); }
.user-avatar {
  width: 28px; height: 28px; border-radius: 50%; background: #fff; color: var(--primary);
  display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700;
}
.user-name { font-size: 13px; color: #fff; }
.user-caret { font-size: 10px; color: rgba(255,255,255,.85); }
.user-drop {
  display: none; position: absolute; top: 52px; right: 0; background: #fff; border-radius: 6px;
  box-shadow: 0 6px 24px rgba(0,0,0,.15); min-width: 150px; padding: 6px 0; z-index: 300; color: var(--text);
}
.user-box.open .user-drop { display: block; }
.user-drop-head { padding: 14px 16px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px; }
.user-drop-head .ud-avatar-lg { width: 40px; height: 40px; font-size: 17px; border-radius: 50%; flex: none; }
.user-drop-head .ud-info { min-width: 0; }
.user-drop-head .ud-name { font-size: 15px; font-weight: 700; color: #222; }
.user-drop-head .ud-company { font-size: 12px; color: #8a97a8; margin-top: 3px; }
.user-drop-role { padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; font-size: 13px; }
.user-drop-role .ud-role-label { color: var(--text-sub); }
.user-drop-role .ud-role-val { color: #222; font-weight: 600; }
.user-drop-item {
  display: block; width: 100%; text-align: left; background: none; border: none;
  padding: 9px 16px; font-size: 12.5px; color: #555;
}
.user-drop-item:hover { background: #f5f7fa; color: var(--primary); }

/* ===== 页面 ===== */
.page { padding: 14px 16px 40px; }
/* 填充式列表页：整页固定高度，面包屑/工具栏/底部汇总条固定，只有表格区域滚动（工程宝式） */
.page.page-fill {
  flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden;
  padding: 12px 16px 10px; box-sizing: border-box;
}
.page-fill .crumb { flex: none; padding-top: 8px; }
.page-fill .toolbar { flex: none; }
.page-fill .table-wrap.sticky-head { flex: 1; min-height: 0; }
/* 面包屑 */
.crumb {
  font-size: 13px; color: var(--text-sub); margin-bottom: 0;
  padding: 10px 0 8px; line-height: 18px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.crumb b { color: var(--text); font-weight: 600; }
.loading { text-align: center; padding: 80px 0; color: #999; }

/* ===== 工具栏 ===== */
.toolbar {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  padding: 2px 0 8px; margin-bottom: 2px;
}
.toolbar-left { display: flex; align-items: center; gap: 8px; }
.toolbar-right { display: flex; align-items: center; gap: 8px; }
.search-input { width: 240px; height: 34px; border-radius: 4px; }

/* 标签页（工程宝式：文字 + 计数 + 下划线） */
.tabs { display: flex; gap: 0; flex-wrap: wrap; }
.tab {
  background: none; border: none; padding: 7px 2px; margin-right: 22px; font-size: 13px; color: #333;
  border-bottom: 2px solid transparent; border-radius: 0; transition: all .15s;
}
.tab:hover { color: var(--primary); }
.tab.active { color: var(--primary); font-weight: 500; border-bottom-color: var(--primary); background: none; }

/* ===== 按钮/输入 ===== */
.btn {
  height: 34px; padding: 0 16px; border-radius: 4px; font-size: 14px; border: 1px solid transparent;
  display: inline-flex; align-items: center; gap: 4px; transition: all .15s; white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-default { background: #fff; border-color: #dcdfe6; color: #606266; }
.btn-default:hover { border-color: var(--primary); color: var(--primary); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { height: 30px; padding: 0 12px; font-size: 13px; }
.btn-outline { background: #fff; border-color: var(--primary); color: var(--primary); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.input {
  height: 34px; border: 1px solid #dcdfe6; border-radius: 4px; padding: 0 12px; font-size: 14px;
  outline: none; background: #fff; color: var(--text); width: 100%;
}
.input:focus { border-color: var(--primary); }
.input:disabled { background: #f7f8fa; color: #888; }
textarea.input { height: auto; padding: 8px 10px; resize: vertical; }
select.input { appearance: auto; }
.link { color: var(--primary); font-size: 13px; margin: 0 4px; }
.link:hover { text-decoration: underline; }
.link.danger { color: var(--danger); }

/* ===== 面板 ===== */
.panel {
  background: var(--card); border-radius: var(--radius); border: 1px solid var(--border);
  padding: 14px 16px;
}
.panel-title { font-size: 14px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: baseline; gap: 8px; }
.panel-sub { font-size: 12px; color: var(--text-sub); font-weight: 400; }
.panel-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }

/* ===== 首页 ===== */
.dash-greet { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; flex-wrap: wrap; gap: 10px; }
.dash-hello { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; }
.dash-avatar { width: 32px; height: 32px; border-radius: 50%; background: #ffe1b8; color: #b26a00; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; }
.dash-company { font-size: 12px; color: var(--text-sub); margin-top: 4px; }
.dash-actions { display: flex; align-items: center; gap: 18px; font-size: 12.5px; color: #555; }
.dash-action { display: flex; align-items: center; gap: 5px; cursor: pointer; background: none; border: none; color: #555; font-size: 12.5px; }
.dash-action:hover { color: var(--primary); }
.section-head { display: flex; justify-content: space-between; align-items: center; margin: 4px 0 10px; }
.section-title { font-size: 14px; font-weight: 600; }

/* 开关（不包含归档项目） */
.switch { width: 34px; height: 18px; border-radius: 10px; background: #dcdfe6; position: relative; border: none; transition: background .2s; flex-shrink: 0; }
.switch::after {
  content: ''; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%;
  background: #fff; transition: left .2s;
}
.switch.on { background: var(--primary); }
.switch.on::after { left: 18px; }

.scope-switch { display: flex; gap: 0; border: 1px solid #dcdfe6; border-radius: 3px; overflow: hidden; }
.scope-btn { border: none; background: #fff; padding: 5px 12px; font-size: 12px; color: #555; }
.scope-btn + .scope-btn { border-left: 1px solid #dcdfe6; }
.scope-btn.active { background: var(--primary); color: #fff; }

.stat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-bottom: 12px; }
.stat-grid-4 { grid-template-columns: repeat(4, 1fr); }
.stat-card {
  border-radius: 6px; padding: 12px 16px; border: 1px solid transparent;
  display: flex; justify-content: space-between; align-items: center; position: relative; min-height: 96px;
}
.stat-main { display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.stat-row-label { font-size: 11.5px; color: #77889a; }
.stat-row-value { font-size: 16px; font-weight: 700; color: #2b3446; line-height: 1.2; }
.stat-sub { font-size: 11px; color: #889; margin-top: 4px; }
.stat-side { text-align: right; z-index: 1; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.stat-side .stat-name { font-size: 13px; font-weight: 600; color: #445; }
.stat-icircle {
  width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.75);
  display: flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 700;
}

.dash-row { display: grid; grid-template-columns: 1.1fr 1.2fr 1fr; gap: 10px; margin-bottom: 10px; }
.dash-row + .dash-row { grid-template-columns: 1fr 1.2fr 1fr; }

/* 首页三栏区：流程中心 + 通知公告/日志（工程宝式） */
.flow-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.flow-tabs { display: flex; gap: 2px; }
.flow-tab { background: none; border: none; font-size: 13px; color: #667; padding: 5px 10px; cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.flow-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.flow-search { width: 130px; height: 28px; font-size: 12.5px; padding: 0 10px; margin-left: auto; flex: none; }
.flow-node { font-size: 12px; padding: 2px 10px; border-radius: 10px; white-space: nowrap; }
.node-pending { background: #e9f2ff; color: #367ce8; }
.node-done { background: #e6f7ec; color: #2ba868; }
.node-reject { background: #ffece9; color: #e05a47; }
.nl-head { display: flex; align-items: center; gap: 16px; margin-bottom: 10px; }
.nl-title { font-size: 14px; font-weight: 600; }
.nl-add { margin-left: auto; background: none; border: 1px solid #dcdfe6; border-radius: 3px; font-size: 12px; color: #667; padding: 3px 10px; cursor: pointer; white-space: nowrap; }
.nl-add:hover { color: var(--primary); border-color: var(--primary); }
.nl-cols { display: flex; gap: 18px; flex: 1; min-height: 0; }
.nl-col { flex: 1; min-width: 0; overflow-y: auto; max-height: 260px; padding-right: 4px; }
.nl-item { display: flex; gap: 8px; padding: 7px 0; border-bottom: 1px solid #f0f3f8; align-items: flex-start; }
.nl-item:last-child { border-bottom: none; }
.nl-dot { width: 7px; height: 7px; border-radius: 50%; background: #e05a47; margin-top: 6px; flex: none; }
.nl-body { flex: 1; min-width: 0; }
.nl-item-title { font-size: 12.5px; color: #2b3446; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nl-snip { font-size: 11.5px; color: #99a; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.nl-time { font-size: 11px; color: #aab; margin-top: 3px; }

/* 首页现金流面板行 */
.cf-row.dash-row { grid-template-columns: 1.35fr 1fr 1fr; }
.cf-panel { min-width: 0; display: flex; flex-direction: column; }
.cf-scope { margin-left: auto; }
.cf-scope .scope-btn { padding: 2px 10px; font-size: 11.5px; }
.cf-bars { display: flex; flex-direction: column; gap: 12px; padding: 10px 0 4px; }
.cf-bar-item { display: flex; align-items: center; gap: 10px; }
.cf-bar-label { width: 34px; font-size: 12.5px; color: #667; flex: none; }
.cf-bar-track { flex: 1; background: #f0f3f8; border-radius: 5px; height: 26px; overflow: hidden; }
.cf-bar-fill { height: 100%; border-radius: 5px; display: flex; align-items: center; padding: 0 10px; min-width: 0; }
.cf-bar-value { font-size: 12px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cf-net-row { display: flex; align-items: center; gap: 10px; padding: 8px 0 4px 44px; }
.cf-net-label { font-size: 12.5px; color: #667; }
.cf-net { background: #e3f6ec; color: #2ba868; font-size: 12.5px; padding: 3px 14px; border-radius: 12px; }
.cf-pend-head { font-size: 12.5px; color: #667; padding: 10px 0 6px 44px; border-top: 1px solid #eef1f5; margin-top: 8px; }
.cf-pend-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 24px; padding: 0 0 4px 44px; }
.cf-pend-item { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; }
.cf-pend-label { color: #8892a0; }
.cf-pend-item b { font-size: 13px; color: #2b3446; }
.cf-gauge { display: flex; align-items: center; gap: 12px; flex: 1; }
.cf-gauge .donut-wrap { flex: 1; min-width: 0; }
.cf-gauge .donut-svg svg { width: 100%; max-width: 190px; height: auto; }
.cf-stats { flex: 1; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.cf-stat-item { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 12.5px; }
.cf-stat-label { color: #8892a0; white-space: nowrap; }
.cf-stat-item b { font-size: 14px; color: #2b3446; }
.chart-empty { padding: 40px 0; }

/* 成本概览蓝色绶带标题（工程宝式） */
.ribbon {
  height: 26px; background: linear-gradient(180deg, #6ea4ef, #4a86e8); color: #fff;
  text-align: center; line-height: 26px; letter-spacing: 10px; font-size: 13px; font-weight: 600;
  border-radius: 3px 3px 0 0; margin: -14px -16px 12px; text-indent: 10px;
}
.donut-big-total { font-size: 18px; font-weight: 700; color: #2b3446; text-align: center; margin-bottom: 2px; }

/* 动态日志 */
.feed-list { display: flex; flex-direction: column; }
.feed-item { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed #f0f2f5; align-items: flex-start; }
.feed-item:last-child { border-bottom: none; }
.feed-avatar {
  width: 28px; height: 28px; border-radius: 50%; color: #fff; font-size: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-weight: 600;
}
.feed-body { flex: 1; min-width: 0; }
.feed-text { font-size: 12.5px; color: #444; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed-time { font-size: 11px; color: #aab; margin-top: 3px; }

/* 底部四卡 */
.bottom-summary {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 2px;
}
.bottom-card { background: #fff; border: 1px solid var(--border); border-radius: 4px; padding: 14px 16px; text-align: center; }
.bottom-label { font-size: 13px; color: #555; }
.bottom-value { font-size: 18px; font-weight: 700; margin-top: 8px; color: var(--primary); }
.bottom-sub { font-size: 11.5px; color: var(--text-sub); margin-top: 4px; }

/* ===== 环形图/图例 ===== */
.donut-wrap { display: flex; align-items: center; gap: 10px; justify-content: center; flex-wrap: wrap; }
.legend { display: flex; flex-direction: column; gap: 6px; font-size: 12px; }
.legend-center { flex-direction: row; justify-content: center; margin-top: 8px; }
.legend-item { display: flex; align-items: center; gap: 6px; }
.legend-dot { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
.legend-label { color: #666; min-width: 44px; }
.legend-value { color: #333; font-weight: 500; }

.hbars { display: flex; flex-direction: column; gap: 10px; }
.hbar-row { display: flex; align-items: center; gap: 10px; font-size: 12px; }
.hbar-label { width: 100px; text-align: right; color: #666; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 0; }
.hbar-track { flex: 1; height: 14px; background: #f2f4f8; border-radius: 2px; overflow: hidden; }
.hbar-fill { height: 100%; border-radius: 2px; min-width: 2px; transition: width .4s; }
.hbar-value { width: 110px; text-align: right; color: #444; flex-shrink: 0; }

/* ===== 表格（工程宝式紧凑 + 排序箭头） ===== */
.table-wrap { background: #fff; border-radius: var(--radius); border: 1px solid var(--border); overflow: hidden; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  background: #f7f8fa; color: #606266; font-weight: 500; text-align: left;
  padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; position: relative;
}
.table th.sortable { cursor: pointer; user-select: none; }
.table th.sortable:hover { color: #409eff; }
.table th.sortable::after {
  content: '⇅'; font-size: 10px; color: #c0c4cc; margin-left: 4px; display: inline-block; transform: scale(.8);
}
.table th.sort-asc::after { content: '↑'; color: #409eff; }
.table th.sort-desc::after { content: '↓'; color: #409eff; }
.table th.no-sort::after { content: none; }
/* 表头列筛选：漏斗图标 + 浮出搜索框 */
.col-filter-btn {
  display: inline-block; margin-left: 4px; font-size: 10px; color: #c0c4cc;
  transform: scale(.8); cursor: pointer; user-select: none;
}
.col-filter-btn:hover { color: #409eff; }
.col-filter-btn.on { color: #409eff; font-weight: 700; }
.col-filter-drop {
  position: fixed; z-index: 2000; background: #fff; border: 1px solid #dcdfe6; border-radius: 6px;
  box-shadow: 0 6px 20px rgba(0,0,0,.12); padding: 8px; width: 210px;
}
.col-filter-drop .input { width: 100%; box-sizing: border-box; font-size: 14px; }
.col-filter-ops { display: flex; justify-content: flex-end; gap: 6px; margin-top: 8px; }
.col-filter-ops .btn { padding: 3px 10px; font-size: 12px; }
.table td { padding: 10px 12px; border-bottom: 1px solid #f0f2f5; color: #333; white-space: nowrap; }
/* 列表页表头吸顶：表格区域自身滚动，表头固定在其顶部（不依赖视口 sticky，兼容所有浏览器） */
.table-wrap.sticky-head { overflow: auto; --thead-top: 0px; }
.table-wrap.sticky-head .table { border-collapse: separate; border-spacing: 0; }
.table-wrap.sticky-head .table th { position: sticky; top: var(--thead-top); z-index: 12; }
.table tbody tr:nth-child(even) { background: #fafbfd; }
.table tbody tr:hover { background: #f0f7ff; }
.table tbody tr:last-child td { border-bottom: none; }
.td-num { text-align: right; font-variant-numeric: tabular-nums; }
.td-actions { text-align: center; white-space: nowrap; }
.td-ellipsis { max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
.empty-cell { text-align: center; padding: 0 !important; }
.empty { text-align: center; padding: 60px 0; color: #aab; font-size: 13px; }
.empty-icon { font-size: 40px; margin-bottom: 10px; opacity: .6; }
.chart-empty { padding: 36px 0; }
.mini-table th::after { content: none; }
.mini-table th, .mini-table td { padding: 7px 10px; }

/* 底部汇总条（工程宝式：汇 | 金额… + 分页）——填充布局下天然固定在页面底部 */
.bottom-bar {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px;
  background: #fff; border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--radius) var(--radius);
  padding: 9px 14px; font-size: 13px; flex: none;
  box-shadow: 0 -2px 8px rgba(15, 25, 40, .06);
}
.bottom-sums { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; color: #666; }
.sum-tag {
  background: var(--primary); color: #fff; font-size: 11px; width: 18px; height: 18px; border-radius: 3px;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 600;
}
.sum-item b { font-weight: 600; margin-left: 2px; color: var(--primary); }
.sum-count { opacity: .8; }
.bottom-bar .pager { padding: 0; }
.pager-size { height: 26px; border: 1px solid #dcdfe6; border-radius: 4px; background: #fff; font-size: 12px; color: #606a78; padding: 0 4px; cursor: pointer; outline: none; margin-left: 6px; }
.pager-size:focus { border-color: var(--primary); }
.table-wrap.has-bottom-bar { border-radius: var(--radius) var(--radius) 0 0; }

/* ===== 库存报表（工程宝式：筛选区 + 统计表 + 底部双卡片） ===== */
.card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); }
.rep-filter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px 18px; padding: 14px 16px 10px; margin-bottom: 12px; }
.rep-filter-item { display: flex; flex-direction: column; gap: 5px; }
.rep-filter-item label { font-size: 12.5px; color: #606a78; }
.rep-input { height: 32px; font-size: 13px; }
.rep-filter-btns { display: flex; align-items: flex-end; justify-content: flex-end; gap: 8px; grid-column: span 2; padding-bottom: 2px; }
.rep-main { padding: 12px 14px 0; }
.rep-main .table-wrap { border: none; border-radius: 0; }
.rep-main .bottom-bar { margin: 0 -14px; border-radius: 0 0 var(--radius) var(--radius); }
.rep-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.rep-card { padding: 12px 14px; }
.rep-stat-scroll { max-height: 320px; overflow-y: auto; }
.rep-donut { display: flex; justify-content: center; padding: 16px 0; }

.sums-bar {
  background: #fff; color: #666; border: 1px solid var(--border); border-top: none;
  padding: 8px 14px; font-size: 12px; display: flex; gap: 18px; flex-wrap: wrap;
}
.sums-bar .sum-item b { color: var(--primary); }

/* 徽标 */
.badge { display: inline-block; padding: 1px 8px; border-radius: 3px; font-size: 11.5px; line-height: 18px; }
.badge-blue { background: #e8f1ff; color: #367ce8; }
.badge-green { background: #e6f7ee; color: #2ba868; }
.badge-orange { background: #fff3e0; color: #d98c1f; }
.badge-red { background: #fdecec; color: #d64541; }
.badge-gray { background: #eef0f3; color: #7a8494; }
.badge-purple { background: #f1ecff; color: #7e5be0; }
.me-tag { background: var(--primary); color: #fff; font-size: 10px; padding: 1px 5px; border-radius: 8px; margin-left: 6px; }

/* 分页 */
.pager { display: flex; align-items: center; gap: 5px; justify-content: flex-end; padding: 10px 0; font-size: 13px; }
.pager-total, .pager-jump { color: #888; margin-right: 6px; }
.page-btn {
  min-width: 26px; height: 26px; border: 1px solid #dcdfe6; background: #fff; border-radius: 3px;
  font-size: 12px; color: #555;
}
.page-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.page-btn.disabled { opacity: .4; cursor: not-allowed; }
.page-dots { color: #999; padding: 0 2px; }

/* ===== 弹窗 ===== */
.modal-mask {
  position: fixed; inset: 0; background: rgba(15, 25, 40, .45); z-index: 200;
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal {
  background: #fff; border-radius: 8px; width: 520px; max-width: 96vw; max-height: 88vh;
  display: flex; flex-direction: column; box-shadow: 0 12px 40px rgba(0,0,0,.18);
  animation: pop .18s ease-out;
}
@keyframes pop { from { transform: scale(.96); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.modal-sm { width: 380px; }
.modal-lg { width: 680px; }
.modal-header { padding: 13px 18px; font-size: 14px; font-weight: 600; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.modal-close { font-size: 22px; color: #999; cursor: pointer; line-height: 1; }
.modal-close:hover { color: #666; }
.modal-body { padding: 16px 18px; overflow-y: auto; }
.modal-footer { padding: 12px 18px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 10px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.form-item label { display: block; font-size: 12.5px; color: #555; margin-bottom: 5px; }
.form-item .req { color: var(--danger); margin-right: 3px; }
.form-full { grid-column: 1 / -1; }
.form-err { color: var(--danger); font-size: 12.5px; margin-top: 10px; min-height: 18px; }

/* ===== Toast ===== */
.toast-wrap { position: fixed; top: 56px; left: 50%; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: #fff; border-radius: 6px; padding: 9px 18px; font-size: 13px; color: #333;
  box-shadow: 0 4px 16px rgba(0,0,0,.14); opacity: 0; transform: translateY(-8px); transition: all .25s;
  border-left: 3px solid #2ba868;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast-error { border-left-color: var(--danger); }
.toast-success { border-left-color: #2ba868; }

/* ===== 模块布局（工程宝式：左侧贴边白色菜单栏） ===== */
.module-wrap { display: flex; align-items: stretch; flex: 1; min-height: 0; overflow: hidden; }
.module-side {
  width: 148px; flex-shrink: 0; background: #fff; border-right: 1px solid var(--border);
  padding: 12px 0 20px; position: relative;
}
.module-main {
  flex: 1; min-width: 0; padding: 0; overflow-y: auto;
  display: flex; flex-direction: column;
}
.module-side-inner { position: relative; }
.module-item {
  padding: 10px 14px 10px 18px; border-radius: 0; cursor: pointer; color: #444; font-size: 13px;
  display: flex; gap: 8px; align-items: center; border-left: 2px solid transparent;
}
.module-item:hover { background: #f5f8fd; color: var(--primary); }
.module-item.active { background: var(--primary-light); color: var(--primary); font-weight: 600; border-left-color: var(--primary); }
.module-item-icon { font-size: 13px; width: 16px; text-align: center; flex-shrink: 0; }

/* ============ 物品档案：图片 / 二维码 / 详情弹窗 ============ */
.thumb { width: 40px; height: 40px; object-fit: cover; border-radius: 3px; border: 1px solid #e5e9f2; cursor: pointer; display: block; }
.qr-thumb { width: 44px; height: 44px; cursor: pointer; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.qr-thumb svg { width: 42px; height: 42px; display: block; }
.muted { color: #b6bfce; }
.image-field { display: flex; flex-direction: column; gap: 6px; }
.image-box { width: 110px; height: 110px; border: 1px dashed #c3cdde; border-radius: 4px; background: #f7f9fc; display: flex; align-items: center; justify-content: center; cursor: pointer; overflow: hidden; position: relative; }
.image-box:hover { border-color: #367ce8; background: #eef4ff; }
.image-box .img-preview { width: 100%; height: 100%; object-fit: cover; display: block; }
.image-box .image-plus { font-size: 26px; color: #b6bfce; }
.image-box .img-preview + .image-plus { display: none; }
.image-actions { display: flex; align-items: center; gap: 8px; }
.form-hint { font-size: 12px; color: #8a94a6; }
.form-hint.err { color: #e5484d; }
/* 物料选择器下拉 */
.picker-drop {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 30;
  background: #fff; border: 1px solid #dcdfe6; border-top: none;
  border-radius: 0 0 6px 6px; box-shadow: 0 6px 16px rgba(0,0,0,.12);
  max-height: 260px; overflow-y: auto;
}
.picker-item {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 10px; font-size: 13px; cursor: pointer; border-bottom: 1px solid #f2f3f5;
}
.picker-item:last-child { border-bottom: none; }
.picker-item:hover { background: #f0f6ff; }
.picker-empty { color: #909399; cursor: default; justify-content: center; }
.picker-item:hover.picker-empty { background: #fff; }
.picker-name { flex: 0 1 auto; font-weight: 500; color: #303133; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker-meta { flex: 1 1 auto; color: #8a94a6; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker-code { flex: 0 0 auto; color: #4f7cff; font-size: 12px; font-family: Consolas, monospace; }
.item-detail { display: flex; gap: 20px; }
.detail-col { width: 220px; flex-shrink: 0; }
.detail-label { font-size: 12px; color: #8a94a6; margin-bottom: 6px; }
.detail-img { width: 220px; height: 180px; object-fit: contain; border: 1px solid #e5e9f2; border-radius: 4px; background: #f7f9fc; display: flex; align-items: center; justify-content: center; color: #b6bfce; font-size: 12px; }
.empty-img { width: 220px; height: 180px; }
.qr-big { width: 220px; cursor: pointer; background: #fff; border: 1px solid #e5e9f2; border-radius: 4px; padding: 8px; }
.qr-big svg { width: 100%; height: auto; display: block; }
.detail-info { flex: 1; }
.detail-row { display: flex; padding: 8px 0; border-bottom: 1px dashed #eef1f6; font-size: 13px; }
.detail-key { width: 80px; color: #8a94a6; flex-shrink: 0; }
.detail-info .detail-row:last-child { border-bottom: none; }

/* ============ 设置表格字段弹窗（工程宝双栏式） ============ */
.colset2-modal { width: 560px; max-width: 94vw; }
.colset2-body { padding: 0 18px 4px; }
.colset2-cols { display: flex; gap: 14px; }
.colset2-pane { flex: 1; min-width: 0; }
.colset2-pane-title { font-size: 13px; color: #333; padding: 4px 2px 8px; }
.colset2-fixtag { font-size: 12px; color: #8a94a6; padding: 2px 2px 6px; }
.colset2-list { border: 1px solid #e4e9f2; border-radius: 4px; height: 320px; overflow-y: auto; padding: 6px 4px; }
.colset2-check { display: flex; align-items: center; gap: 8px; padding: 6px 8px; font-size: 13px; cursor: pointer; border-radius: 3px; }
.colset2-check:hover { background: #f0f4fb; }
.colset2-check input { accent-color: #367ce8; width: 15px; height: 15px; cursor: pointer; flex-shrink: 0; }
.colset2-item { display: flex; align-items: center; gap: 6px; padding: 5px 6px; font-size: 13px; border-radius: 3px; cursor: default; user-select: none; }
.colset2-item:hover { background: #f0f4fb; }
.colset2-item.dragging { opacity: .5; background: #e8f1fe; }
.colset2-drag { color: #b0b9c9; cursor: grab; font-size: 14px; flex-shrink: 0; padding: 0 2px; }
.colset2-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.colset2-ops { display: inline-flex; gap: 2px; flex-shrink: 0; }
.colset2-ico { color: #8a94a6; font-size: 13px; width: 22px; height: 22px; line-height: 22px; text-align: center; cursor: pointer; border-radius: 3px; text-decoration: none; }
.colset2-ico:hover { background: #e4e9f2; color: #367ce8; }
.colset2-ico.dis { opacity: .35; cursor: default; }
.colset2-ico.del:hover { color: #e64242; }
.colset2-empty { color: #8a94a6; font-size: 12px; text-align: center; padding: 24px 0; }
.colset2-footer { display: flex; align-items: center; gap: 10px; }
.colset2-clear { font-size: 12px; color: #8a94a6; cursor: pointer; text-decoration: none; }
.colset2-clear:hover { color: #e64242; }
/* 工程宝式表格设置齿轮按钮 */
/* 表头「操作」列前的 ⚙ 表格设置入口 */
.th-gear { font-size: 22px; color: #8a94a6; cursor: pointer; margin-right: 12px; line-height: 1; vertical-align: -3px; }
.th-gear:hover { color: var(--primary); }
/* 列宽拖拽手柄：贴在表头右缘，鼠标移上去显示蓝色高亮 */
.th-resizer { position: absolute; top: 0; right: -3px; width: 8px; height: 100%; cursor: col-resize; z-index: 6; user-select: none; }
.th-resizer:hover { background: rgba(59, 140, 247, .22); }
body.col-resizing { cursor: col-resize; user-select: none; }
/* 固定布局表格（列宽调整后）：单元格内容超出时省略号，不挤坏布局 */
.table.table-fixed td, .table.table-fixed th { overflow: hidden; text-overflow: ellipsis; }
.switch { width: 34px; height: 18px; border-radius: 9px; background: #c9d2e0; position: relative; cursor: pointer; display: inline-block; transition: background .15s; flex-shrink: 0; }
.switch::after { content: ''; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: left .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.switch.on { background: #367ce8; }
.switch.on::after { left: 18px; }

/* ============ 二维码标签弹窗 ============ */
.label-modal-body { display: flex; gap: 22px; }
.label-left { flex: 1; min-width: 0; background: #f2f4f8; border-radius: 6px; padding: 22px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.label-tip { font-size: 12px; color: #8a94a6; margin-bottom: 14px; text-align: center; }
.label-preview-wrap { background: #fff; box-shadow: 0 2px 10px rgba(30,50,90,.12); border-radius: 4px; overflow: hidden; }
.label-right { width: 250px; flex-shrink: 0; }
.label-size-title { font-size: 15px; font-weight: bold; margin-bottom: 12px; }
.size-card { border: 1px solid #dbe2ee; border-radius: 6px; padding: 12px 14px; margin-bottom: 10px; cursor: pointer; position: relative; transition: border-color .15s, box-shadow .15s; }
.size-card b { font-size: 14px; display: block; }
.size-card .size-px { font-size: 12px; color: #8a94a6; margin-top: 4px; }
.size-card:hover { border-color: #367ce8; }
.size-card.active { border-color: #367ce8; box-shadow: 0 0 0 1px #367ce8 inset; }
.size-card.active::after { content: '✓'; position: absolute; right: 10px; bottom: 8px; color: #fff; background: #367ce8; width: 18px; height: 18px; border-radius: 50%; font-size: 12px; display: flex; align-items: center; justify-content: center; }
.module-group { font-weight: 500; }
.module-arrow { margin-left: auto; font-size: 10px; color: #999; }
.module-children { overflow: hidden; }
.module-children.closed { display: none; }
.module-child { padding-left: 34px; font-size: 12.5px; }
.side-collapse {
  position: absolute; right: -12px; top: 8px; width: 22px; height: 22px; border-radius: 50%;
  background: #fff; border: 1px solid var(--border); color: #999; font-size: 12px; z-index: 5;
  display: flex; align-items: center; justify-content: center;
}
.side-collapse:hover { color: var(--primary); border-color: var(--primary); }
.module-side.collapsed { width: 0; overflow: hidden; padding: 0; border-right: none; }
.module-side.collapsed .side-collapse { display: none; }

/* ===== 资金账户卡片 ===== */
.acc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.acc-card { background: #fff; border: 1px solid var(--border); border-radius: 4px; padding: 16px; transition: box-shadow .15s; }
.acc-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.07); }
.acc-head { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; }
.acc-icon { width: 38px; height: 38px; border-radius: 50%; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 17px; flex-shrink: 0; }
.acc-name { min-width: 0; }
.acc-title { font-size: 14px; font-weight: 600; }
.acc-sub { font-size: 11.5px; color: var(--text-sub); margin-top: 3px; }
.acc-balance-label { font-size: 11.5px; color: var(--text-sub); }
.acc-balance { font-size: 21px; font-weight: 700; color: #2b3446; margin: 4px 0 12px; }
.acc-actions { display: flex; gap: 8px; justify-content: flex-end; }

/* ===== 设置页 ===== */
.settings-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 14px; }
.role-note-item { padding: 6px 0; font-size: 13px; color: #555; }
.role-note-item b { margin-right: 10px; color: var(--primary); }

/* ===== 登录页 ===== */
.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #367ce8 0%, #4a90ec 55%, #6db3f2 100%);
}
.login-card {
  background: #fff; border-radius: 14px; padding: 40px 44px; width: 400px; max-width: 92vw;
  box-shadow: 0 20px 60px rgba(10, 40, 90, .35); text-align: center;
}
.login-logo {
  width: 54px; height: 54px; border-radius: 13px; background: linear-gradient(135deg, #367ce8, #4a90ec);
  color: #fff; font-size: 26px; font-weight: 700; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 14px;
}
.login-title { font-size: 22px; font-weight: 700; color: #2b3446; }
.login-sub { font-size: 12.5px; color: var(--text-sub); margin: 8px 0 26px; }
.login-form { display: flex; flex-direction: column; gap: 12px; text-align: left; }
.login-input { height: 40px; font-size: 14px; }
.code-row { display: flex; gap: 10px; }
.code-row .input { flex: 1; }
.code-btn { white-space: nowrap; min-width: 110px; }
.login-btn { width: 100%; height: 40px; font-size: 15px; justify-content: center; margin-top: 4px; }
.login-err { color: var(--danger); font-size: 12.5px; min-height: 18px; text-align: center; }
.login-hint { font-size: 11.5px; color: #9aa4b2; text-align: center; }

/* ===== 响应式 ===== */
@media (max-width: 1100px) {
  .stat-grid { grid-template-columns: repeat(3, 1fr); }
  .dash-row { grid-template-columns: 1fr; }
  .bottom-summary { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .nav { overflow-x: auto; }
  .nav-item { padding: 0 10px; }
  .brand-name { display: none; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .module-wrap { flex-direction: column; overflow: visible; }
  .module-side { width: 100%; position: static; min-height: 0; border-right: none; border-bottom: 1px solid var(--border); }
  .module-main { padding: 12px; overflow: visible; }
  .page-fill { display: block; overflow: visible; }
  .page-fill .table-wrap.sticky-head { overflow-x: auto; }
  .table-wrap { overflow-x: auto; }
  /* 移动端横向滚动容器内关闭表头吸顶 */
  .table-wrap.sticky-head { overflow-x: auto; --thead-top: 0; }
  .table-wrap.sticky-head .table th { position: relative; }
  .table { min-width: 640px; }
}

/* ===== 项目详情页（工程宝式） ===== */
.pdetail-head { display: flex; align-items: center; gap: 10px; padding: 2px 0 10px; }
.pdetail-title { font-size: 17px; font-weight: 600; }
.pdetail-tabs { display: flex; gap: 2px; background: var(--card); border-bottom: 1px solid var(--border); padding: 0 12px; z-index: 5; overflow-x: auto; }
.pdetail-tabs .ptab { border: none; background: none; padding: 10px 16px; font-size: 13.5px; color: var(--text-sub); border-bottom: 2px solid transparent; white-space: nowrap; }
.pdetail-tabs .ptab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.ptab-pane { padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.pboard-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.pboard { background: var(--card); border-radius: var(--radius); padding: 12px 16px 14px; position: relative; border: 1px solid var(--border); border-top: 2px solid transparent; }
.pboard-blue { border-top-color: var(--primary); }
.pboard-orange { border-top-color: #f0883a; }
.pboard-green { border-top-color: #3bbb7d; }
.pboard-tag { position: absolute; top: -2px; left: 12px; transform: translateY(-50%); color: #fff; font-size: 11.5px; padding: 1px 10px; border-radius: 3px; }
.pboard-tag.tag-blue { background: var(--primary); }
.pboard-tag.tag-orange { background: #f0883a; }
.pboard-tag.tag-green { background: #3bbb7d; }
.pboard-tag.tag-teal { background: #21b7a6; }
.pboard-row { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--text-sub); padding-top: 9px; }
.pboard-row:first-of-type { padding-top: 16px; }
.pboard-row b { font-weight: 600; color: var(--text); }
.ptoolbar { display: flex; align-items: center; gap: 8px; padding: 4px 0; }
.ptoolbar-title { font-size: 13.5px; font-weight: 600; }
.pchips { display: flex; flex-wrap: wrap; gap: 8px; }
.pchip { background: var(--primary-light); color: var(--primary); border: 1px solid #c9dcfa; border-radius: 3px; padding: 3px 10px; font-size: 12px; cursor: pointer; }
.pchip:hover { background: #dbe9ff; }
.pinfo-grid { background: var(--card); border-radius: var(--radius); padding: 6px 14px; display: grid; grid-template-columns: 1fr 1fr; }
.pinfo-item { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--border); font-size: 12.5px; }
.pinfo-grid .pinfo-item:nth-last-child(-n+2) { border-bottom: none; }
.pinfo-k { color: var(--text-sub); min-width: 72px; }
.pinfo-v { color: var(--text); word-break: break-all; }
.pfile-list { background: var(--card); border-radius: var(--radius); padding: 4px 12px; }
.pfile-row { display: flex; align-items: center; gap: 10px; padding: 9px 6px; border-bottom: 1px solid var(--border); font-size: 13px; cursor: pointer; }
.pfile-row:last-child { border-bottom: none; }
.pfile-row.empty-row { justify-content: center; padding: 26px 0; cursor: default; }
.pfile-icon.folder { font-size: 16px; }
.pfile-name { color: var(--text); max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfile-row:hover .pfile-name { color: var(--primary); }
.pfile-meta { color: var(--text-sub); font-size: 12px; white-space: nowrap; }
.pfile-src { color: var(--text-sub); font-size: 12px; width: 90px; }
.pfile-time { color: var(--text-sub); font-size: 12px; white-space: nowrap; }
.ptimeline { background: var(--card); border-radius: var(--radius); padding: 14px 18px; display: flex; flex-direction: column; gap: 12px; }
.ptimeline-item { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.ptimeline-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--primary); flex: none; }
.pempty { background: var(--card); border-radius: var(--radius); padding: 40px 0; }
@media (max-width: 900px) { .pboard-grid { grid-template-columns: 1fr; } .pinfo-grid { grid-template-columns: 1fr; } }

/* 附件上传字段 */
.file-field { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.file-field .form-hint { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 多附件上传 */
.atch-field { display: flex; flex-direction: column; gap: 8px; }
.atch-actions { display: flex; align-items: center; gap: 10px; }
.atch-list { display: flex; flex-direction: column; gap: 6px; }
.atch-item {
  display: flex; align-items: center; gap: 10px;
  background: #f7f9fc; border: 1px solid #e4e9f2; border-radius: 6px;
  padding: 7px 12px; font-size: 13.5px;
}
.atch-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #333; }
.atch-size { color: #8a94a6; font-size: 12px; flex: none; }
.atch-op { color: var(--primary); cursor: pointer; font-size: 13px; flex: none; }
.atch-op.atch-del { color: #e5484d; }

/* ===== 设置中心 ===== */
.input-sm { padding: 4px 8px; font-size: 12.5px; height: auto; }
.table input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
.table td .link { margin-right: 8px; }
.table td.num.muted { color: #909399; }
.muted { color: #909399; }

/* ===== 组织架构 / 角色设置 / 审批设置 ===== */
.org-wrap { display: flex; gap: 14px; align-items: flex-start; }
.org-tree { width: 250px; flex: none; background: var(--card); border-radius: var(--radius); padding: 12px 10px; min-height: 320px; }
.org-tree .panel-title { padding: 0 4px 6px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.tree-node { padding: 7px 8px; font-size: 13px; cursor: pointer; border-radius: 4px; display: flex; align-items: center; gap: 5px; position: relative; white-space: nowrap; }
.tree-node:hover { background: #f0f4fb; }
.tree-node.active { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.tree-children { margin-left: 16px; }
.tree-arrow { width: 12px; flex: none; text-align: center; color: #a8b3c4; font-size: 11px; cursor: pointer; user-select: none; transition: transform .15s; }
.tree-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tree-cnt { flex: none; color: #98a2b3; font-size: 12px; font-weight: 400; }
.tree-node.active .tree-cnt { color: var(--primary); }
.tree-ops { display: none; position: absolute; right: 6px; top: 50%; transform: translateY(-50%); gap: 8px; background: #f0f4fb; padding: 2px 6px; border-radius: 4px; }
.tree-node.active .tree-ops { background: var(--primary-light); }
.tree-node:hover .tree-ops { display: inline-flex; }
.tree-ops .link { font-size: 13px; line-height: 1; }
.tree-ops .link:hover { color: var(--primary); }
.tree-ico { color: #5a9cf8; font-size: 13px; flex: none; }
/* 人员列表：工程宝式页签标题 + 搜索 */
.emp-tabs { display: flex; align-items: center; border-bottom: 1px solid var(--border); padding: 0 16px; }
.emp-tab { padding: 13px 4px; font-size: 14px; font-weight: 600; color: var(--primary); border-bottom: 2px solid var(--primary); margin-bottom: -1px; }
.emp-search { margin-left: auto; }
.emp-search-input { height: 30px; border: 1px solid #dcdfe6; border-radius: 4px; padding: 0 10px; width: 200px; font-size: 13px; outline: none; transition: border-color .15s, width .2s; }
.emp-search-input:focus { border-color: var(--primary); width: 240px; }
.emp-table td { padding: 9px 12px; }
.emp-table tbody tr:hover { background: #f7faff; }
.emp-name { font-weight: 500; }
.emp-table .td-actions { text-align: right; padding-right: 18px; }
.emp-table th:last-child { text-align: right; padding-right: 18px; }
/* 角色设置：工程宝式角色面板 */
.role-add-btn { padding: 6px 16px; background: #eef4ff; color: var(--primary); border: 1px solid #d5e5ff; border-radius: 4px; font-size: 13px; cursor: pointer; transition: background .15s; }
.role-add-btn:hover { background: #e2edff; }
.role-group { padding: 7px 4px; font-size: 13px; font-weight: 600; color: #37415c; cursor: pointer; user-select: none; }
.role-group:hover { color: var(--primary); }
.approve-group { padding: 8px 8px 4px; font-size: 12px; color: #909399; font-weight: 600; }
/* 开关 */
input.switch { appearance: none; -webkit-appearance: none; width: 40px; height: 22px; background: #c0c4cc; border-radius: 11px; position: relative; cursor: pointer; outline: none; transition: background .2s; vertical-align: middle; margin-left: auto; }
input.switch:checked { background: var(--primary); }
input.switch::after { content: ''; position: absolute; left: 2px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: left .2s; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
input.switch:checked::after { left: 20px; }
input.switch:disabled { opacity: .5; cursor: not-allowed; }
/* 权限矩阵（工程宝大气版式 + 头部固定、矩阵区滚动） */
.role-fill { padding-bottom: 12px; }
.role-wrap { flex: 1; min-height: 0; align-items: stretch; }
.role-tree { display: flex; flex-direction: column; min-height: 0; }
.role-tree-list { flex: 1; min-height: 0; overflow-y: auto; }
.role-main {
  flex: 1; min-width: 0; background: var(--card); border-radius: var(--radius);
  display: flex; flex-direction: column; overflow: hidden;
}
.role-head { flex: none; background: var(--card); border-bottom: 1px solid var(--border); padding: 2px 18px 0; }
.role-tabs { margin-left: 4px; }
.role-tabs .tab { font-size: 15px; padding: 13px 2px; margin-right: 26px; font-weight: 500; }
.role-note { font-size: 13px; color: #555; padding: 0 0 10px; }
.role-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0 18px 16px; }
.perm-table th { padding: 12px; font-size: 13.5px; background: #f7f9fc; position: sticky; top: 0; z-index: 2; }
.perm-table td { padding: 12px; font-size: 14px; }
.perm-mod-label { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.perm-mod-label input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
.perm-ops { display: flex; flex-wrap: wrap; gap: 16px 44px; }
.perm-op { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; cursor: pointer; white-space: nowrap; }
.perm-op input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
/* 表单设置（复用角色页填充布局：头部固定 + 表格滚动 + 大气单元格） */
.role-form-head { display: flex; align-items: center; gap: 14px; padding: 4px 0 10px; }
.form-head-btns { display: inline-flex; gap: 10px; margin-left: auto; }
.form-table th { padding: 12px; font-size: 13.5px; background: #f7f9fc; position: sticky; top: 0; z-index: 2; }
.form-table td { padding: 12px; font-size: 14px; }
.form-table input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
.form-table .td-actions a { font-size: 14px; }
/* 审批设置（工程宝式：开关 + 固定审批流 + 流程图） */
.ap-body { padding-top: 18px; }
.ap-row { display: flex; align-items: center; gap: 14px; margin-bottom: 6px; }
.ap-row input.switch { margin-left: 0; }
.ap-name { font-size: 16px; font-weight: 600; color: var(--text); }
.ap-links { display: inline-flex; gap: 12px; margin-left: 6px; }
.ap-links .link { font-size: 14px; }
.ap-desc { font-size: 12.5px; color: #909399; margin-bottom: 16px; }
.ap-muted { font-size: 13px; color: #8a94a6; background: #f7f9fc; border: 1px dashed #dbe2ec; border-radius: 6px; padding: 12px 14px; margin-top: 4px; }
.ap-flow { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.ap-node { display: flex; align-items: center; gap: 9px; background: #f7f9fc; border: 1px solid #e4e9f2; border-radius: 6px; padding: 8px 12px; }
.ap-avatar { width: 30px; height: 30px; border-radius: 50%; background: #e3edff; color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 14px; flex: none; }
.ap-node-title { font-size: 13.5px; font-weight: 600; color: var(--text); }
.ap-node-sub { font-size: 12px; color: #8a94a6; }
.ap-arrow { color: #b6bfce; font-size: 16px; }

/* ===== 采购工作台（工程宝式卡片布局） ===== */
.pwork-head { display: flex; justify-content: space-between; align-items: center; margin: 20px 0 12px; }
.pwork-head-row { flex-wrap: wrap; gap: 10px; }
.pwork-title { font-size: 14.5px; font-weight: 600; color: var(--text); }
.pwork-more { color: #b6bfce; }
.pwork-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.pwork-card { background: var(--card); border-radius: 8px; padding: 14px 16px; border: 1px solid #eef1f6; box-shadow: 0 1px 3px rgba(30,40,60,.05); }
.pwork-card-top { display: flex; gap: 9px; align-items: center; font-size: 13px; color: #55606f; }
.pwork-ico { width: 34px; height: 34px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-size: 16px; color: #fff; flex: none; }
.pwork-ico.blue { background: #4f7cff; }
.pwork-ico.teal { background: #31c2a6; }
.pwork-ico.orange { background: #ff9440; }
.pwork-ico.red { background: #ff6b81; }
.pwork-num { margin-top: 10px; font-size: 20px; font-weight: 700; color: var(--text); }
.pwork-num .num { font-size: 22px; }
.pwork-unit { font-size: 12.5px; font-weight: 400; color: #8a94a6; }
.pwork-amt { font-size: 12.5px; color: #8a94a6; margin-top: 2px; min-height: 16px; }
.pwork-act { margin-top: 10px; background: none; border: none; padding: 0; font-size: 12.5px; color: var(--primary); cursor: pointer; }
.pwork-act:hover { text-decoration: underline; }
.pwork-ov-head { font-size: 13.5px; font-weight: 600; color: var(--text); padding-bottom: 8px; border-bottom: 1px solid #eef1f6; margin-bottom: 6px; }
.pwork-ov-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 12.5px; color: #55606f; padding: 5px 0; }
.pwork-ov-row .num { font-size: 13px; }
.pwork-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.pwork-pill { padding: 5px 16px; border-radius: 4px; font-size: 12.5px; cursor: pointer; background: #f2f5fa; color: #55606f; border: none; transition: all .15s; }
.pwork-pill:hover { color: var(--primary); }
.pwork-pill.active { background: var(--primary); color: #fff; }
.pwork-quick { display: flex; gap: 10px; flex-wrap: wrap; }
.pwork-chart-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; background: var(--card); border: 1px solid #eef1f6; border-radius: 8px; padding: 16px; box-shadow: 0 1px 3px rgba(30,40,60,.05); }
@media (max-width: 1000px) { .pwork-chart-grid { grid-template-columns: repeat(2, 1fr); } }
.pwork-days { margin-top: 10px; display: flex; flex-direction: column; gap: 4px; }
.pwork-day-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 12.5px; color: #8a94a6; }
.pwork-day-row .num { font-size: 13px; color: #55606f; }
.pwork-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
.pwork-panel { background: var(--card); border: 1px solid #eef1f6; border-radius: 8px; padding: 12px 14px; box-shadow: 0 1px 3px rgba(30,40,60,.05); }
.pwork-panel .pwork-head { margin-bottom: 10px; flex-wrap: wrap; }
.pwork-empty { padding: 34px 0; text-align: center; font-size: 13px; color: #b0b8c7; }
.pwork-panel .input { width: 150px; height: 30px; font-size: 12.5px; padding: 0 8px; }
@media (max-width: 900px) { .pwork-two-col { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .pwork-grid { grid-template-columns: repeat(2, 1fr); } }

/* ===== 导入弹窗 ===== */
.import-desc { font-size: 12.5px; color: #606266; line-height: 1.7; background: #f6f8fc; border: 1px solid #e4e9f2; border-radius: 4px; padding: 10px 12px; margin-bottom: 12px; }
.import-actions { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.import-status { font-size: 13px; color: #606266; padding: 8px 0; }
.import-status.err { color: #e75c5c; }
.import-preview { max-height: 300px; overflow: auto; }
.import-tip { font-size: 12px; color: #909399; padding: 8px 2px; }
.import-preview table { border: 1px solid var(--border); border-radius: 4px; }

/* 标签弹窗加宽 + 小屏自适应 */
.label-modal { width: 760px; max-width: 94vw; }
