/* ===== 前海工程中心招标管理工作台 ===== */
/* 色彩体系：白底 + 黑字 + 蓝链接（参照「全流程工程管理数字化系统」的政企管理台风格）。
   要点：正文/标题一律近黑（#1f2329 / #26292e），蓝色只给链接、主按钮、选中态；
   页面底浅灰、卡片纯白、边框中性灰、圆角 4px、阴影极淡——靠线条和留白分区，不靠色块。
   2026-11-02 定版：文字改近黑（前两版蓝灰字用户否决），整体密度收紧。 */
:root {
  --primary: #1677ff;          /* 链接、主按钮、选中描边 */
  --primary-dark: #0d5fd6;     /* hover 加深 */
  --primary-light: #eaf2ff;    /* 淡蓝底：选中行、标签 */
  --primary-soft: #f5f9ff;     /* 近白蓝，大区块 hover 底 */
  --primary-line: #d8e6fb;     /* 淡蓝描边 */
  --accent: #7fb2f5;           /* 装饰浅蓝 */
  --success: #16a34a;
  --warning: #d97706;
  --danger: #dc2626;
  --gray-50: #f4f5f7;          /* 页面底：浅灰 */
  --gray-100: #f0f1f4;
  --gray-200: #e5e7eb;         /* 边框：中性灰 */
  --gray-300: #d5d8de;
  --gray-400: #9fa6b0;
  --gray-500: #8b9199;         /* 次级文字 */
  --gray-600: #5c636d;         /* 标签、表头辅助 */
  --gray-700: #26292e;         /* 表格正文：近黑 */
  --gray-800: #1f2329;
  --gray-900: #1f2329;         /* 标题：近黑 */
  --sidebar-bg: #ffffff;
  --sidebar-active: #1677ff;
  --radius: 4px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.04);
  --shadow: 0 2px 8px rgba(0,0,0,.06);
  --shadow-lg: 0 8px 24px rgba(0,0,0,.12);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
/* hidden 属性优先于任何 display 声明（.form-grid/.dt-grid 等 grid 容器会盖掉默认行为） */
[hidden] { display: none !important; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  font-size: 14px; color: var(--gray-900); background: var(--gray-50);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 14px; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #cbe0f2; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #b1cfe8; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- 启动加载 ---------- */
.boot-loading {
  height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 16px; color: var(--gray-500);
}
.spinner {
  width: 32px; height: 32px; border: 3px solid var(--gray-200);
  border-top-color: var(--primary); border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 登录页 ---------- */
.login-wrap {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(760px 420px at 12% 6%, rgba(124,198,243,.16), transparent 62%),
    radial-gradient(680px 380px at 88% 94%, rgba(124,198,243,.13), transparent 64%),
    linear-gradient(180deg, #ffffff 0%, #f7f8fa 100%);
  padding: 20px;
}
.login-card {
  width: 400px; max-width: 100%; background: #fff; border: 1px solid var(--primary-line);
  border-radius: 14px;
  box-shadow: 0 12px 34px rgba(28,86,140,.10), 0 1px 3px rgba(28,86,140,.05);
  padding: 40px 36px 32px;
}
.login-logo { text-align: center; margin-bottom: 26px; }
.login-logo .mark {
  width: 60px; height: 60px; border-radius: 0; margin: 0 auto 14px;
  display: block; object-fit: contain;
  box-shadow: 0 4px 12px rgba(28,86,140,.12);
}
.login-logo h1 { font-size: 19px; font-weight: 600; letter-spacing: .5px; }
.login-logo p { font-size: 12px; color: var(--gray-400); margin-top: 6px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; color: var(--gray-600); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--gray-200);
  border-radius: var(--radius); outline: none; transition: all .15s; background: #fff;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--primary); box-shadow: 0 0 0 3px rgba(44,135,214,.12);
}
/* 时间字段：文本输入 + 右侧日历按钮（空值时不显示任何占位文字） */
.field .input-time { position: relative; display: flex; align-items: center; }
.field .input-time input { padding-right: 38px; }
.field .time-pick {
  position: absolute; right: 1px; top: 1px; bottom: 1px; width: 34px;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-left: 1px solid var(--gray-200); background: #fff;
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--gray-500); cursor: pointer; transition: color .15s, background .15s;
}
.field .time-pick:hover { color: var(--primary); background: var(--primary-light); }

/* 日期 / 时间选择面板（自绘，固定定位在字段下方；原生 showPicker 位置不受控已弃用） */
.dp-panel {
  position: fixed; z-index: 2000; background: #fff;
  border: 1px solid var(--gray-200); border-radius: 10px;
  box-shadow: 0 10px 28px rgba(15, 40, 70, .18);
  padding: 10px 12px 8px; font-size: 12.5px; color: #26292e; user-select: none;
}
.dp-head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.dp-title { flex: 1; text-align: center; font-weight: 600; font-size: 13px; }
.dp-nav {
  width: 22px; height: 22px; padding: 0; line-height: 1;
  border: 1px solid var(--gray-200); background: #fff; border-radius: 6px;
  color: #55657a; cursor: pointer; font-size: 13px;
}
.dp-nav:hover { border-color: var(--primary); color: var(--primary); }
.dp-today { border: 0; background: none; color: var(--primary); cursor: pointer; font-size: 12px; padding: 0 2px; }
.dp-week, .dp-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.dp-grid.months { grid-template-columns: repeat(4, 1fr); }
.dp-week span { text-align: center; color: var(--gray-500); font-size: 11.5px; padding: 3px 0; }
.dp-cell {
  text-align: center; padding: 5px 0; border-radius: 6px; cursor: pointer;
  font-variant-numeric: tabular-nums; line-height: 1.6;
}
.dp-cell:hover { background: #eef4fb; }
.dp-cell.other { color: #c3ccd8; }
.dp-cell.today { color: var(--primary); font-weight: 600; }
.dp-cell.on, .dp-cell.on:hover { background: var(--primary); color: #fff; font-weight: 600; }
/* 超出可选窗口（如只能约未来 30 天内）的日期：置灰且不可点 */
.dp-cell.off, .dp-cell.off:hover {
  background: transparent; color: #d8dee7; cursor: not-allowed; font-weight: 400;
}
.dp-time {
  display: flex; align-items: center; gap: 6px; margin-top: 8px; padding-top: 8px;
  border-top: 1px solid var(--gray-100); color: var(--gray-600);
}
.dp-time select {
  height: 28px; padding: 0 4px; font-family: inherit; font-size: 12.5px;
  border: 1px solid var(--gray-200); border-radius: 6px; background: #fff;
}
.dp-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.dp-clear { color: var(--danger); }

/* 下拉浮层多选（标段名称等）：触发器 + 浮层搜索 + 复选框列表 + 全选 */
.dd-trigger {
  width: 100%; height: 40px; padding: 0 34px 0 12px; position: relative;
  display: flex; align-items: center; text-align: left;
  border: 1px solid var(--gray-200); border-radius: var(--radius); background: #fff;
  font-family: inherit; font-size: 14px; color: #26292e; cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.dd-trigger:hover { border-color: #c7d4e2; }
.dd-trigger.on { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(44,135,214,.12); }
.dd-value { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dd-value.ph { color: var(--gray-400); }
.dd-arrow {
  position: absolute; right: 13px; top: 50%; width: 7px; height: 7px;
  border-right: 1.6px solid #8b939d; border-bottom: 1.6px solid #8b939d;
  transform: translateY(-70%) rotate(45deg); transition: transform .15s;
}
.dd-trigger.on .dd-arrow { transform: translateY(-30%) rotate(-135deg); }

.dd-pop {
  position: fixed; z-index: 2000; background: #fff; overflow: hidden;
  border: 1px solid var(--gray-200); border-radius: 8px;
  box-shadow: 0 10px 28px rgba(15,40,70,.18);
}
.dd-pop[hidden] { display: none !important; }
.dd-search {
  display: flex; align-items: center; gap: 8px; padding: 10px 12px;
  border-bottom: 1px solid var(--gray-100); color: var(--gray-500);
}
.dd-search input {
  flex: 1; padding: 0; border: 0; outline: none; background: transparent;
  font-family: inherit; font-size: 13.5px; color: #26292e;
}
.dd-list { max-height: 240px; overflow-y: auto; padding: 4px 0; }
.dd-item {
  display: flex; align-items: center; gap: 8px; padding: 7px 12px;
  font-size: 13px; color: #26292e; cursor: pointer;
}
.dd-item:hover { background: #f4f7fb; }
.dd-item input[type="checkbox"] {
  width: 15px; height: 15px; flex: none; margin: 0; padding: 0;
  accent-color: var(--primary);
}
.dd-text { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dd-all { border-bottom: 1px solid var(--gray-100); margin-bottom: 2px; }
.dd-all .dd-text { color: var(--primary); font-weight: 500; }
/* 粘贴成功后的短暂高亮，提示「已经填进去了」 */
.field input.paste-flash {
  border-color: var(--success) !important;
  box-shadow: 0 0 0 3px rgba(22,163,74,.18) !important;
  transition: none;
}
/* 带单位的输入框（如 中标净下浮率 %） */
.field .input-unit { position: relative; }
.field .input-unit input { padding-right: 34px; }
.field .input-unit .unit {
  position: absolute; right: 1px; top: 1px; bottom: 1px; width: 30px;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--gray-500, #64748b);
  background: var(--gray-50, #f8fafc); border-left: 1px solid var(--gray-200);
  border-radius: 0 var(--radius) var(--radius) 0; pointer-events: none;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px; border-radius: var(--radius); border: 1px solid transparent;
  font-size: 14px; font-weight: 500; transition: all .15s; white-space: nowrap;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-dark);
}
.btn-default { background: #fff; color: var(--gray-700); border-color: var(--gray-200); }
.btn-default:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-block { width: 100%; padding: 11px; }
.btn-sm { padding: 4px 10px; font-size: 13px; }
.btn:disabled { opacity: .6; cursor: not-allowed; }
.login-err {
  background: #fef2f2; color: var(--danger); border: 1px solid #fecaca;
  padding: 8px 12px; border-radius: var(--radius); font-size: 13px; margin-bottom: 14px;
}
.login-tip { text-align: center; font-size: 12px; color: var(--gray-400); margin-top: 18px; }

/* ---------- 主布局 ---------- */
.layout { display: flex; height: 100vh; overflow: hidden; }
/* 侧边栏：浅蓝底 + 深蓝灰文字（原来深藏青，改为浅蓝后整体更轻） */
.sidebar {
  width: 220px;
  background: #ffffff;
  border-right: 1px solid var(--gray-200);
  color: #26292e;
  display: flex; flex-direction: column; flex-shrink: 0;
}
.sidebar-brand {
  padding: 18px 16px; border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center; gap: 10px;
}
.sidebar-brand .mark {
  width: 34px; height: 34px; border-radius: 0; flex-shrink: 0;
  display: block; object-fit: contain;
  box-shadow: 0 1px 3px rgba(28,86,140,.14);
}
.sidebar-brand .txt b { display: block; color: #1f2329; font-size: 14px; font-weight: 600; letter-spacing: .3px; }
.sidebar-brand .txt span { font-size: 11px; color: #9fa6b0; }
.nav { flex: 1; padding: 10px 0 16px; overflow-y: auto; }
/* 顶部固定区：流程管理四个入口（不参与分组折叠）
   字号/行高/图标尺寸与下方功能项完全一致，只靠区块留白区分 */
.nav-pinned { padding: 2px 0 12px; }
.nav-pinned .nav-item { padding: 7px 16px; }
.nav-pinned .nav-item .ico { color: #3d4653; }
.nav-pinned .nav-item:hover .ico,
.nav-pinned .nav-item.active .ico { color: var(--primary); }
/* 侧栏搜索：胶囊输入框，夹在流程入口与功能菜单之间 */
.nav-search { position: relative; margin: 0 12px 14px; }
.nav-search .ns-ico {
  position: absolute; left: 11px; top: 50%; transform: translateY(-50%);
  display: flex; color: #9aa3af; pointer-events: none;
}
.nav-search input {
  width: 100%; height: 34px; padding: 0 12px 0 32px;
  border: 1px solid #e4e7ec; border-radius: 17px; background: #f5f6f8;
  font-size: 13px; color: #26292e; outline: none;
  transition: border-color .15s, background .15s;
  -webkit-appearance: none; appearance: none;
}
.nav-search input::placeholder { color: #a6adb8; }
.nav-search input:focus { background: #fff; border-color: var(--primary); }
/* input[type=search] 在 WebKit 下自带清除按钮，去掉以免与圆角冲突 */
.nav-search input::-webkit-search-cancel-button { -webkit-appearance: none; }
/* 搜索过滤用：.nav-item 是 flex，hidden 属性会被 display 覆盖，必须显式声明 */
.nav-item[hidden], .nav-group[hidden], .nav-pinned[hidden] { display: none !important; }
/* 分组之间留出呼吸感：收起状态下靠上下留白区分，不画分割线 */
.nav-group + .nav-group { margin-top: 12px; }
.nav-group-title {
  padding: 8px 16px; font-size: 13px; color: var(--gray-900); font-weight: 500; line-height: 1.5;
  letter-spacing: 0; text-transform: none;
  display: flex; align-items: center; gap: 6px;
  cursor: pointer; user-select: none;
}
.nav-group-title:hover { color: var(--primary); }
.nav-group-title .ng-ico { flex: none; display: flex; align-items: center; color: #d8a12a; }
.nav-group-title .ng-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 折叠箭头：展开时朝下，收起时朝右 */
.nav-caret {
  flex: none; width: 8px; height: 8px; margin-top: -3px;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg); transition: transform .15s;
}
.nav-group.collapsed .nav-caret { transform: rotate(-45deg); margin-top: 0; }
.nav-group.collapsed .nav-group-body { display: none; }
.nav-group.collapsed .nav-group-title { padding-bottom: 6px; }
.nav-item {
  display: flex; align-items: center; gap: 9px; padding: 7px 16px;
  color: #26292e; font-size: 13px; line-height: 1.5; cursor: pointer; transition: all .15s;
  border-left: 3px solid transparent;
}
.nav-item:hover { background: #f0f1f4; color: var(--primary); }
.nav-item.active {
  background: #eaf2ff;
  color: #0d5fd6;
  border-left-color: var(--sidebar-active); font-weight: 600;
}
.nav-item .ico {
  width: 16px; height: 16px; flex: none; text-align: center;
  color: #8b9199; opacity: .95; transition: color .15s;
}
.nav-item:hover .ico { color: var(--primary); }
.nav-item.active .ico { color: var(--primary); opacity: 1; }
/* 侧栏待办角标：有未读时红色，仅剩已读待办时灰色，避免「有新活儿」和「有几条」混在一起 */
.nav-badge {
  margin-left: auto; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
  background: #eaedf1; color: #5f6b7a; font-size: 10.5px; font-style: normal; font-weight: 500;
  line-height: 16px; text-align: center; font-variant-numeric: tabular-nums;
}
.nav-badge.is-new { background: #e8453c; color: #fff; }
.nav-badge[hidden] { display: none !important; }
.sidebar-foot {
  padding: 12px 16px; border-top: 1px solid var(--gray-200);
  font-size: 11px; color: #9fa6b0; background: #fff;
}

.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.topbar {
  height: 56px; background: #ffffff;
  border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center; padding: 0 22px; gap: 14px; flex-shrink: 0;
}
.topbar h2 {
  position: relative; padding-left: 11px;
  font-size: 15.5px; font-weight: 600; flex: 1; color: var(--gray-900);
}
/* 页面标题前的蓝色短竖条：全站唯一的“结构蓝”，让顶部不发灰 */
.topbar h2::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 14px; border-radius: 1px;
  background: var(--primary);
}
.topbar .user {
  display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--gray-600);
}
/* ---------- 顶栏账号下拉（点姓名展开：修改密码 / 退出登录） ---------- */
.user-menu-wrap { position: relative; }
.user-trigger {
  display: flex; align-items: center; gap: 8px;
  background: none; border: 1px solid transparent; border-radius: 18px;
  padding: 3px 9px 3px 3px; cursor: pointer; font: inherit; color: inherit;
  transition: background .15s, border-color .15s;
}
.user-trigger:hover { background: var(--primary-soft); border-color: var(--primary-line); }
.user-trigger .avatar { flex-shrink: 0; }
.user-name {
  max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--gray-700); font-size: 13px;
}
.user-caret {
  width: 0; height: 0; flex-shrink: 0; margin-left: 1px;
  border-left: 4px solid transparent; border-right: 4px solid transparent;
  border-top: 5px solid var(--gray-400);
}
.user-drop {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 176px; z-index: 200;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 6px;
  box-shadow: 0 8px 24px rgba(18, 51, 80, .13); padding: 4px;
}
.user-drop-item {
  display: block; width: 100%; text-align: left; background: none; border: none;
  padding: 8px 12px; font-size: 13px; color: var(--gray-700); cursor: pointer;
  border-radius: 4px; font-family: inherit; transition: background .12s, color .12s;
}
.user-drop-item:hover { background: var(--primary-light); color: var(--primary); }
.user-drop-item + .user-drop-item { margin-top: 2px; }
/* ---------- 账号下拉 · 系统设置（仅系统管理员）：与「修改密码 / 退出登录」同一菜单 ---------- */
.user-drop-sec-head {
  display: flex; align-items: center; gap: 7px; width: 100%;
  padding: 8px 12px; background: none; border: none; border-radius: 4px;
  font: inherit; font-size: 13px; color: var(--gray-700); text-align: left; cursor: pointer;
  transition: background .12s, color .12s;
}
.user-drop-sec-head:hover { background: var(--primary-soft); color: var(--primary); }
.uds-ico { display: flex; flex-shrink: 0; color: var(--gray-400); }
.user-drop-sec-head:hover .uds-ico { color: var(--primary); }
.uds-name { flex: 1; }
/* 展开=向下三角，收起=-90°朝右；与顶栏账号箭头同一套三角，看得出一家人 */
.uds-caret {
  width: 0; height: 0; flex-shrink: 0;
  border-left: 4px solid transparent; border-right: 4px solid transparent;
  border-top: 5px solid var(--gray-400); transition: transform .15s;
}
.user-drop-sec.collapsed .uds-caret { transform: rotate(-90deg); }
.user-drop-sec.collapsed .user-drop-sec-body { display: none; }
.user-drop-item.is-sub {
  display: flex; align-items: center; gap: 7px; padding-left: 28px;
}
.udi-ico { display: flex; flex-shrink: 0; color: var(--gray-400); }
.user-drop-item.is-sub:hover .udi-ico { color: var(--primary); }
/* 当前所在页：淡蓝底 + 蓝字，和侧栏选中态一致 */
.user-drop-item.active { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.user-drop-item.active .udi-ico { color: var(--primary); }
.user-drop-sep { height: 1px; background: var(--gray-100); margin: 4px 8px; }
/* 下拉顶部：当前账号信息（姓名 / 角色 / 单位），纯展示 */
.user-drop-info {
  padding: 7px 12px 9px; border-bottom: 1px solid var(--gray-100); margin-bottom: 4px;
}
.user-drop-info b {
  display: block; font-size: 13px; font-weight: 600; color: var(--gray-900);
  line-height: 1.4;
}
.user-drop-info span {
  display: block; margin-top: 3px; font-size: 11.5px; color: var(--gray-500);
  line-height: 1.5; word-break: break-all;
}
/* 首次登录强制改密提示条 */
.pwd-force-tip {
  margin: 0 0 14px; padding: 10px 12px; border-radius: 4px;
  background: #fff8e8; border: 1px solid #ffe1a8; color: #96650a;
  font-size: 12.5px; line-height: 1.7;
}
.avatar {
  width: 30px; height: 30px; border-radius: 50%; background: var(--primary-light);
  color: var(--primary); display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 13px;
}
.tag {
  display: inline-block; padding: 0 6px; border-radius: 2px;
  font-size: 11px; line-height: 18px; background: var(--primary-light); color: var(--primary);
}
.tag-gray { background: #f0f1f4; color: var(--gray-600); }
.tag-green { background: #dcfce7; color: var(--success); }
.tag-orange { background: #fef3c7; color: var(--warning); }
.tag-blue { background: #dbeafe; color: #1d6fe0; }
.tag-purple { background: #ede9fe; color: #6d28d9; }
.tag-red { background: #fee2e2; color: var(--danger); }
.tag-ok { background: #dcfce7; color: #15803d; }
.tag-warn { background: #fef3c7; color: #b45309; }

/* 附件上传（对齐简道云 upload 控件） */
.up-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.up-item {
  display: flex; align-items: center; gap: 8px; padding: 6px 10px;
  background: var(--gray-50, #f8fafc); border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 6px; font-size: 13px;
}
.up-item a { color: var(--primary); text-decoration: none; }
.up-item a:hover { text-decoration: underline; }
.up-size { color: var(--gray-400, #94a3b8); font-size: 11.5px; }
.up-links { display: flex; flex-direction: column; gap: 4px; }
.up-links a { color: var(--primary); text-decoration: none; font-size: 13px; }
.up-links a:hover { text-decoration: underline; }

/* 多选（简道云 checkboxgroup） */
.chk-group { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 4px 0; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; cursor: pointer; }
.chk input { accent-color: var(--primary); }
/* 复选框不能被 .field input 的 width:100% / padding 拉成文本框（否则会把标签文字挤成 0 宽） */
.chk input[type="checkbox"],
.chk input[type="radio"] {
  width: 15px; height: 15px; padding: 0; margin: 0; flex: none;
  border: 0; background: none; box-shadow: none; border-radius: 0;
}
/* 多选（备选较多时）：搜索框 + 限高滚动列表，右侧可带截标日期等辅助说明 */
.chk-search {
  width: 100%; height: 32px; margin-bottom: 6px; padding: 0 10px; font-size: 13px;
  border: 1px solid var(--gray-200); border-radius: 6px; font-family: inherit; color: #26292e;
}
.chk-search:focus { border-color: var(--primary); outline: none; }
.chk-count { margin-left: 8px; font-size: 12px; font-weight: 500; color: var(--primary); }
/* 可折叠多选：点标题行展开（默认收起，选项多时不占屏） */
.field label.chk-head {
  display: flex; align-items: center; gap: 8px;
  cursor: pointer; user-select: none;
}
.field label.chk-head:hover { color: var(--primary); }
/* 星号紧跟在标题文字后，不要被 flex 排到最右 */
.field label.chk-head.req::after { order: 1; }
.field label.chk-head .chk-count { order: 2; }
/* 提权覆盖 .field label 的 display:block */
.chk-arrow {
  order: 3;
  width: 0; height: 0; margin-left: auto; margin-right: 2px;
  border-left: 5px solid transparent; border-right: 5px solid transparent;
  border-top: 6px solid #9aa3ad; transition: transform .15s;
}
.field.open .chk-arrow { transform: rotate(180deg); }
.chk-body[hidden] { display: none !important; }
.chk-empty { padding: 16px 8px; text-align: center; color: var(--gray-500); font-size: 12.5px; }
.chk-group.with-search {
  display: block; max-height: 172px; overflow-y: auto; padding: 4px 10px;
  border: 1px solid var(--gray-200); border-radius: 6px; background: #fff;
}
.chk-group.with-search .chk { display: flex; width: 100%; align-items: flex-start; gap: 8px; padding: 6px 0; }
.chk-group.with-search .chk + .chk { border-top: 1px dashed #f0f3f7; }
.chk-group.with-search .chk input { margin-top: 2px; flex: none; }
.chk-text { flex: 1 1 auto; min-width: 0; word-break: break-all; line-height: 1.5; }
.chk-note {
  flex: none; font-style: normal; font-size: 11.5px; color: var(--gray-500);
  white-space: nowrap; margin-top: 1px;
}

.content {
  /* 上下留白只保留底部 40px：右侧容器顶边=顶栏下沿、底边=侧栏底部横线，二者严格对齐 */
  flex: 1; overflow-y: auto; padding: 0 22px 40px;
  background: var(--gray-50);
  /* 滚动条槽位常驻：滚动条宽 8px，出现/消失会让内容宽度变 8px，
     4 列筛选区每列随之缩/放 2px（切换项目进展时最明显，即用户看到的「列宽位移」） */
  scrollbar-gutter: stable;
  /* 所有页面统一铺满：页面根节点作为 flex item 吃掉剩余高度（见下方 #view > :last-child） */
  display: flex; flex-direction: column;
}
/* 页面根节点撑满内容区；flex-shrink:0 保证内容本身超高的页面（权限管理、投标人看板）正常滚动而不是被压扁 */
#view > :last-child { flex: 1 0 auto; min-height: 0; }

/* ---------- 卡片 & 工具栏 ---------- */
.card {
  background: #fff; border: 1px solid var(--gray-200);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.toolbar {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  padding: 14px 16px; background: #fff;
  border: 1px solid var(--gray-200); border-radius: var(--radius);
  margin-bottom: 14px; box-shadow: var(--shadow-sm);
}
.toolbar .spacer { flex: 1; }
.search-box { position: relative; }
.search-box input {
  width: 220px; padding: 8px 12px 8px 31px; border: 1px solid var(--gray-200);
  border-radius: var(--radius); outline: none; background: #fff;
  font-size: 13px;   /* 同上：与列表正文一致 */
}
.search-box input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(44,135,214,.12); }
/* 放大镜：与全站线性图标同风格（24 栅格 / 线宽 1.9） */
.search-box::before {
  content: ""; position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  width: 14px; height: 14px; opacity: .75;
  background: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238b9199' stroke-width='1.9' stroke-linecap='round'%3E%3Ccircle cx='10.8' cy='10.8' r='6.6'/%3E%3Cpath d='M15.6 15.6 20 20'/%3E%3C/svg%3E") center/contain no-repeat;
}
select.filter {
  padding: 8px 10px; border: 1px solid var(--gray-200); border-radius: var(--radius);
  outline: none; background: #fff; color: var(--gray-700); max-width: 160px;
  font-size: 13px;   /* 与下方列表正文（13px）统一，原来继承 body 的 14px 显得偏大 */
}
select.filter:focus { border-color: var(--primary); }

/* ---------- 表格 ---------- */
.table-wrap { background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius); overflow-x: auto; box-shadow: var(--shadow-sm); }
/* 列表页铺满：工具栏与分页固定，表格区吃掉剩余高度——行少时下方留白在白色卡片内，行多时在卡片内滚动。
   这里用 height:100% 锁死高度，让 table-wrap 能被压缩；只靠 flex-grow 的话，行数多时表格会把根节点顶高。 */
.lp-list { display: flex; flex-direction: column; min-height: 0; height: 100%; }
.lp-list > .toolbar, .lp-list > .pager { flex: none; }
.lp-list > .table-wrap { flex: 1 1 auto; min-height: 0; overflow: auto; border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
/* 分页条在表格卡片下方：去掉上边框与圆角，与表格拼成一体 */
.lp-list > .pager {
  flex: none; margin-top: -1px;
  border: 1px solid var(--gray-200); border-top: 1px solid var(--gray-100);
  border-radius: 0 0 var(--radius) var(--radius); background: #fff;
}
table.grid { width: 100%; border-collapse: collapse; font-size: 13px; }
table.grid th {
  background: #fafafa; color: var(--gray-900); font-weight: 600;
  text-align: center; padding: 9px 12px; border-bottom: 1px solid var(--gray-200);
  white-space: nowrap; position: sticky; top: 0; z-index: 1;
}
table.grid th.sortable { cursor: pointer; user-select: none; }
table.grid th.sortable:hover { color: var(--primary); }
table.grid th .arrow { font-size: 10px; opacity: .55; margin-left: 3px; }
table.grid td {
  padding: 8px 12px; border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700); vertical-align: middle; text-align: center;
}
table.grid td a { color: var(--primary); text-decoration: none; }
table.grid tbody tr:hover { background: #f7f9fc; }
table.grid tbody tr:last-child td { border-bottom: none; }
/* 数字列：用等宽数字便于对位（对齐方式由 table.grid 统一控制为居中） */
.num { font-variant-numeric: tabular-nums; }
/* 长文本单元格：单行省略，悬停查看全文 */
.cell-ellipsis {
  display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* 编码类单元格（统一社会信用代码等）：等宽字体便于逐位核对 */
.cell-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: .2px; font-variant-numeric: tabular-nums;
}
table.grid td, table.grid th { white-space: nowrap; }
table.grid td.wrap { white-space: normal; }
.actions { display: flex; gap: 6px; }
.link-btn { color: var(--primary); cursor: pointer; font-size: 13px; background: none; border: none; padding: 0; }
.link-btn:hover { text-decoration: underline; }
.link-btn.danger { color: var(--danger); }
.empty { padding: 50px 20px; text-align: center; color: var(--gray-400); }
.empty .big { margin-bottom: 10px; color: var(--gray-300); line-height: 1; }
.empty .big svg { width: 40px; height: 40px; stroke-width: 1.3; }
/* 无权限 / 提示类大图标，与空状态同风格 */
.empty-ico { color: var(--gray-300); line-height: 1; margin-bottom: 10px; }

/* ---------- 分页 ---------- */
.pager {
  display: flex; align-items: center; gap: 8px; justify-content: flex-end;
  padding: 12px 16px; font-size: 13px; color: var(--gray-500);
  background: #fff; border-top: 1px solid var(--gray-100);
}
.pager button {
  min-width: 30px; height: 30px; padding: 0 8px; border: 1px solid var(--gray-200);
  background: #fff; border-radius: 3px; color: var(--gray-600);
}
.pager button:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.pager button:disabled { opacity: .45; cursor: not-allowed; }
.pager button.on { background: #fff; border-color: var(--primary); color: var(--primary); font-weight: 600; }
/* 左下角：每页条数选择 + 条数统计 */
.pager-left { display: flex; align-items: center; gap: 16px; margin-right: auto; }
.pager-size { display: flex; align-items: center; gap: 5px; color: var(--gray-500); font-size: 12.5px; }
.pager select.size-sel {
  height: 26px; padding: 0 4px; border: 1px solid var(--gray-200); border-radius: 6px;
  background: #fff; color: var(--gray-700); font-size: 12.5px; outline: none; cursor: pointer;
}
.pager select.size-sel:hover { border-color: var(--primary); }
.pager select.size-sel:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(44,135,214,.12); }
.pager-stat { color: var(--gray-500); white-space: nowrap; }

/* ---------- 序号列 ---------- */
th.idx-col { width: 62px; }
table.grid td.idx { color: var(--gray-400); font-variant-numeric: tabular-nums; }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(29,74,112,.36);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 40px 20px; z-index: 100; overflow-y: auto;
  animation: fade .15s ease;
}
@keyframes fade { from { opacity: 0; } }
.modal {
  background: #fff; border-radius: 12px; width: 720px; max-width: 100%;
  box-shadow: var(--shadow-lg); animation: pop .18s ease;
}
@keyframes pop { from { transform: translateY(-12px); opacity: 0; } }
.modal-head {
  display: flex; align-items: center; padding: 16px 22px;
  border-bottom: 1px solid var(--gray-200);
}
.modal-head h3 { font-size: 15px; font-weight: 600; flex: 1; }
.modal-head .x {
  border: none; background: none; font-size: 20px; line-height: 1;
  color: var(--gray-400); padding: 0 4px;
}
.modal-head .x:hover { color: var(--danger); }
.modal-body { padding: 20px 22px; max-height: 66vh; overflow-y: auto; }
.modal-foot {
  display: flex; justify-content: flex-end; gap: 10px;
  padding: 14px 22px; border-top: 1px solid var(--gray-200); background: var(--gray-50);
  border-radius: 0 0 12px 12px;
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }

/* ---------- 表单标签页（对应简道云 multitab 布局） ---------- */
.form-tabs {
  display: flex; gap: 6px; margin: 0 0 18px;
  border-bottom: 1px solid var(--gray-200);
}
.form-tab {
  position: relative; top: 1px;
  padding: 8px 18px; font-size: 13px; color: var(--gray-600);
  background: transparent; border: 1px solid transparent; border-bottom: none;
  border-radius: 6px 6px 0 0; cursor: pointer; transition: color .15s, background .15s;
}
.form-tab:hover { color: var(--primary); background: var(--gray-50); }
.form-tab.on {
  color: var(--primary); font-weight: 600; background: #fff;
  border-color: var(--gray-200); border-bottom-color: #fff;
}
.form-pane[hidden] { display: none; }
.form-pane { animation: fadeIn .15s ease; }
/* 详情页的分页容器同样带 grid 布局，必须显式声明 hidden 才盖得住 display:grid */
.dt-pane[hidden] { display: none; }
@keyframes fadeIn { from { opacity: 0; } }

/* ---------- 列表行 → 详情页 ---------- */
tr.row-click { cursor: pointer; }
tr.row-click:hover td { background: var(--primary-light); }
.detail-page { display: flex; flex-direction: column; gap: 14px; }
.detail-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.detail-head .spacer { flex: 1; }
.detail-title {
  font-size: 16px; font-weight: 600; color: var(--gray-900);
  max-width: 46%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.detail-pos { font-size: 12.5px; color: var(--gray-500); margin-right: 4px; }
.detail-body {
  background: #fff; border: 1px solid var(--gray-200); border-radius: 10px;
  padding: 18px 20px; box-shadow: var(--shadow-sm);
}
.dt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 28px; }
.dt-grid .full { grid-column: 1 / -1; }
.dt-item label { display: block; font-size: 12.5px; color: var(--gray-500); margin-bottom: 4px; }
.dt-val {
  font-size: 13.5px; color: var(--gray-900); min-height: 20px;
  padding: 7px 10px; background: var(--gray-50); border-radius: 6px;
  word-break: break-word; line-height: 1.5;
}
.dt-empty { color: var(--gray-400); }
.dt-unit { margin-left: 2px; color: var(--gray-500); }
.dt-sub-note { color: var(--gray-500); font-size: 12.5px; }
.dt-sub { margin-top: 2px; font-size: 12.5px; }
.detail-meta {
  display: flex; gap: 20px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--gray-500); padding: 0 4px;
}
.btn.danger { color: var(--danger); border-color: #fecaca; }
.btn.danger:hover { background: #fef2f2; border-color: var(--danger); }
@media (max-width: 900px) {
  .dt-grid { grid-template-columns: 1fr; }
  .detail-title { max-width: 100%; }
}
/* 表单分组标题（对应简道云的三段式分组） */
.form-group-title {
  grid-column: 1 / -1;
  font-size: 13px; font-weight: 600; color: var(--primary);
  padding: 6px 0 2px 10px; margin-top: 4px;
  border-left: 3px solid var(--primary);
  background: linear-gradient(90deg, rgba(44,135,214,.07), transparent 70%);
  border-radius: 2px;
}
.form-group-title:first-child { margin-top: 0; }
.req::after { content: " *"; color: var(--danger); }
.hint { font-size: 12px; color: var(--gray-400); margin-top: 4px; }

/* ---------- 子表单（对应简道云 subform） ---------- */
.form-group-title.sub { margin-top: 0; }
.sub-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-bottom: 10px; }
.sub-table th {
  background: var(--gray-50); color: var(--gray-600); font-weight: 600;
  padding: 8px; border: 1px solid var(--gray-200); white-space: nowrap; font-size: 12.5px;
  text-align: center;
}
.sub-table td { padding: 5px 6px; border: 1px solid var(--gray-200); }
.sub-table input, .sub-table select {
  width: 100%; height: 30px; border: 1px solid var(--gray-200); border-radius: 6px;
  padding: 0 8px; font-size: 13px; outline: none; background: #fff; color: var(--gray-800);
}
.sub-table input:focus, .sub-table select:focus {
  border-color: var(--primary); box-shadow: 0 0 0 2px rgba(44,135,214,.12);
}
.sub-table td:last-child { text-align: center; }
/* 只读（公式）字段 */
input.ro { background: var(--gray-50); color: var(--gray-500); cursor: not-allowed; }

/* ---------- 仪表盘 ---------- */
.kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(168px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 18px 20px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
}
.kpi::after {
  content: ""; position: absolute; right: -18px; top: -18px; width: 70px; height: 70px;
  border-radius: 50%; background: var(--primary-light); opacity: .55;
}
.kpi .label { font-size: 13px; color: var(--gray-500); margin-bottom: 10px; position: relative; }
.kpi .value {
  font-size: 25px; font-weight: 700; color: var(--gray-900);
  font-variant-numeric: tabular-nums; position: relative; white-space: nowrap;
}
.kpi .value .unit { font-size: 13px; font-weight: 500; color: var(--gray-400); margin-left: 4px; }
.chart-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
/* 卡片统一总高 300px（含边框）：标题固定，内容区自适应填充 */
.chart-card {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  height: 300px; display: flex; flex-direction: column;
}
.chart-card.full { grid-column: 1 / -1; }
/* 多图同排：跨满整行后再内部等分 */
.chart-row-3 {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.chart-title {
  flex: none;
  padding: 14px 18px; font-size: 14px; font-weight: 600;
  border-bottom: 1px solid var(--gray-100); color: var(--gray-700);
}
.chart-body { flex: 1 1 auto; min-height: 0; padding: 8px; }
@media (max-width: 1120px) {
  .chart-grid { grid-template-columns: 1fr; }
  .chart-row-3 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}

/* ---------- 仪表盘：筛选区 ---------- */
.dash-filters {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 12px 14px; margin-bottom: 12px; box-shadow: var(--shadow-sm);
  flex: none;   /* .content 是 flex 列：不锁住会被表格/图表挤扁 */
}
.dash-filter-row {
  /* 10 个筛选项 + 1 个按钮组 = 12 格（招标估价占 2 格），6 列 × 2 行正好排满，
     1440 宽下一屏两行搞定，不再拖到第三行 */
  display: grid; grid-template-columns: repeat(auto-fit, minmax(178px, 1fr)); gap: 10px 14px;
}
/* 招标估价：最小值—最大值，占两格 */
.dash-filter-row .f-range-wide { grid-column: span 2; }
.dash-filter-row .dash-filter-actions { display: flex; gap: 8px; align-items: flex-end; align-self: end; }
/* 重置 / 导出 各占一半宽度（flex-basis:0 + 等分），文字不换行 */
.dash-filter-row .dash-filter-actions .btn {
  flex: 1 1 0; min-width: 0; padding-left: 8px; padding-right: 8px; white-space: nowrap;
}
/* 中等宽度（笔记本 1280~1400）仍保持 6 列，筛选项压窄一点也要维持两行 */
@media (max-width: 1400px) {
  .dash-filter-row { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
}
.dash-filter-row label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 12px; color: var(--gray-500);
}
.dash-filter-row input, .dash-filter-row select {
  padding: 6px 9px; border: 1px solid var(--gray-200); border-radius: 6px;
  font-size: 13px; outline: none; background: #fff; width: 100%; color: var(--gray-900);
}
.dash-filter-row input:focus, .dash-filter-row select:focus {
  border-color: var(--primary); box-shadow: 0 0 0 3px rgba(44,135,214,.1);
}
.dash-filter-row .range { display: flex; align-items: center; gap: 4px; }
.dash-filter-row .range input { min-width: 0; }
#f-reset, #f-export { align-self: end; height: 32px; }

/* ---------- 仪表盘：分组标签页 ---------- */
.dash-tabs {
  display: flex; gap: 2px; background: #fff; border: 1px solid var(--gray-200);
  border-radius: var(--radius); padding: 5px; margin-bottom: 14px;
  box-shadow: var(--shadow-sm); overflow-x: auto;
  /* ⚠️ 必须 flex:none：overflow-x:auto 让这个 flex item 的自动最小高度变成 0，
     .content 高度不够时它会被压成 12px 的一条空白带（标签页整体消失） */
  flex: none;
}
.dash-tab {
  padding: 8px 18px; border: none; background: none; border-radius: 6px;
  font-size: 13.5px; color: var(--gray-600); white-space: nowrap; transition: all .15s;
}
.dash-tab:hover { background: var(--gray-50); color: var(--primary); }
.dash-tab.active { background: #eaf2ff; color: #0d5fd6; font-weight: 600; box-shadow: inset 0 0 0 1px #cfe4f9; }

/* 表格类标签页（招标计划 / 对外发布）：占满剩余高度，只有表格区内部滚动，
   分页条钉在底部不动——整页不再跟着滚动条跑。 */
#view > #dash-body.dash-body-fill {
  flex: 1 1 auto; min-height: 0;
  display: flex; flex-direction: column; overflow: hidden;
}
#dash-body.dash-body-fill > .lp-list { flex: 1 1 auto; min-height: 0; }

.chart-title .sub {
  font-weight: 400; color: var(--gray-400); font-size: 12px; margin-left: 8px;
}
/* 透视表：卡片总高由 .chart-card 统一为 300px，内容区自适应填充 */
.pivot-body { flex: 1 1 auto; min-height: 0; padding: 0 0 4px; overflow: auto; }
/* 透视表内边距更紧凑（居中由 table.grid 全局统一控制） */
.pivot-body table.grid th, .pivot-body table.grid td { padding: 10px 12px; }
/* 透视表卡片只有 1/3 宽：固定布局按卡片宽度分列，不再横向滚动；
   维度列（区域/部门）占 40% 放得下全称，数字列等分单行显示 */
.pivot-body table.grid { table-layout: fixed; width: 100%; }
.pivot-body table.grid th,
.pivot-body table.grid td { padding: 8px 5px; overflow: hidden; text-overflow: ellipsis; }
.pivot-body table.grid th { white-space: normal; line-height: 1.3; vertical-align: middle; }
.pivot-body table.grid th .th-unit { white-space: nowrap; }
/* 维度列（第 1 列）占 40%，其余数字列等分 */
.pivot-body table.grid th:first-child { width: 40%; }
.pivot-body table.grid th { position: static; }
.pivot-body table.grid td:first-child { font-weight: 500; }
.pivot-body .empty { padding: 30px 16px; }
table.grid tr.total-row td {
  background: var(--gray-50); font-weight: 600; color: var(--gray-900);
  border-top: 2px solid var(--gray-200);
}

/* KPI 六色（对齐简道云指标卡配色） */
.kpi-0::after { background: #f0f1f4; }
.kpi-1::after { background: #e6f7ee; }
.kpi-2::after { background: #fef3e2; }
.kpi-3::after { background: #f0ebfe; }
.kpi-4::after { background: #fdeaea; }
.kpi-5::after { background: #e6f7f9; }
.kpi-0 { border-top: 3px solid #4aa3ea; }
.kpi-1 { border-top: 3px solid #16a34a; }
.kpi-2 { border-top: 3px solid #f59e0b; }
.kpi-3 { border-top: 3px solid #a855f7; }
.kpi-4 { border-top: 3px solid #ef4444; }
.kpi-5 { border-top: 3px solid #14b8a6; }

/* ---------- 权限：导航与徽标 ---------- */
.tag-admin { background: #ede9fe; color: #6d28d9; }
.nav-perm { font-size: 10px; opacity: .6; margin-left: auto; }
.perm-hint { font-size: 12px; color: var(--gray-400); margin-right: 4px; }
.perm-hint b { color: var(--primary); font-weight: 600; }
.perm-mini { font-size: 12px; color: var(--gray-600); }
.perm-mini.none { color: var(--gray-400); font-style: italic; }

/* ---------- 权限管理页 ---------- */
.perm-layout { display: grid; grid-template-columns: 260px 1fr; gap: 16px; align-items: start; }
@media (max-width: 980px) { .perm-layout { grid-template-columns: 1fr; } }

.perm-resources {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); overflow: hidden;
}
.perm-panel-title {
  padding: 13px 16px; font-size: 13px; font-weight: 600; color: var(--gray-700);
  border-bottom: 1px solid var(--gray-100); background: var(--gray-50);
}
.perm-res-item {
  padding: 12px 16px; border-bottom: 1px solid var(--gray-100);
  cursor: pointer; transition: all .15s; border-left: 3px solid transparent;
}
.perm-res-item:hover { background: #f7f8fa; }
.perm-res-item.active {
  background: var(--primary-light); border-left-color: var(--primary);
}
.pri-name { font-size: 13.5px; font-weight: 500; color: var(--gray-900); margin-bottom: 5px; }
.pri-meta { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--gray-400); }
.pri-type { background: var(--gray-100); color: var(--gray-500); padding: 1px 7px; border-radius: 9px; }
.pri-count { color: #16a34a; }
.pri-count.zero { color: var(--gray-400); }
.perm-tip {
  padding: 12px 16px; font-size: 11.5px; color: var(--gray-400); line-height: 1.7;
  background: var(--gray-50);
}

.perm-detail {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); min-height: 300px;
}
.perm-detail-head {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--gray-100);
}
.perm-detail-head h3 { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.perm-detail-head p { font-size: 12px; color: var(--gray-400); margin-top: 5px; }
.perm-detail-head button { margin-left: auto; flex-shrink: 0; }
.perm-type-badge {
  font-size: 11px; font-weight: 400; color: var(--primary);
  background: var(--primary-light); padding: 2px 8px; border-radius: 10px;
}

.perm-groups { padding: 16px 20px 22px; display: flex; flex-direction: column; gap: 14px; }
.perm-group { border: 1px solid var(--gray-200); border-radius: var(--radius); overflow: hidden; }
.pg-head {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  background: var(--gray-50); border-bottom: 1px solid var(--gray-100);
}
.pg-head button { margin-left: auto; flex-shrink: 0; }
.pg-title { font-size: 13.5px; font-weight: 600; color: var(--gray-700); display: flex; align-items: center; gap: 7px; }
.pg-num {
  min-width: 20px; height: 18px; padding: 0 6px; border-radius: 9px;
  background: var(--gray-200); color: var(--gray-600);
  font-size: 11px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center;
}
.pg-desc { font-size: 11.5px; color: var(--gray-400); margin-top: 4px; }
.pg-members { padding: 12px 16px; display: flex; flex-wrap: wrap; gap: 8px; min-height: 48px; }
.pg-empty { font-size: 12.5px; color: var(--gray-400); font-style: italic; }

.perm-group.perm-manage { border-left: 3px solid #16a34a; }
.perm-group.perm-manage .pg-num { background: #dcfce7; color: #15803d; }
.perm-group.perm-view { border-left: 3px solid #1677ff; }
.perm-group.perm-view .pg-num { background: var(--primary-light); color: var(--primary); }
.perm-group.perm-add { border-left: 3px solid #f59e0b; }
.perm-group.perm-add .pg-num { background: #fef3c7; color: #b45309; }
.perm-group.perm-none { border-left: 3px solid var(--gray-300); }

.member-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px 4px 5px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 16px;
  font-size: 12.5px; color: var(--gray-700); transition: all .15s;
}
.member-chip:hover { border-color: var(--gray-300); box-shadow: var(--shadow-sm); }
.member-chip.muted { background: var(--gray-50); color: var(--gray-400); }
.member-chip.is-admin { background: #f5f3ff; border-color: #ddd6fe; color: #6d28d9; }
.mc-avatar {
  width: 20px; height: 20px; border-radius: 50%; background: var(--primary-light);
  color: var(--primary); font-size: 11px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.member-chip.is-admin .mc-avatar { background: #ede9fe; color: #6d28d9; }
.member-chip.muted .mc-avatar { background: var(--gray-200); color: var(--gray-400); }
.mc-name { max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-lock { font-size: 10px; color: #7c3aed; }
.mc-x {
  border: none; background: none; color: var(--gray-400); font-size: 14px;
  line-height: 1; padding: 0 2px; cursor: pointer;
}
.mc-x:hover { color: var(--danger); }

/* 成员选择弹窗 */
.picker-tip { font-size: 13px; color: var(--gray-600); margin-bottom: 12px; }
.picker-tip b { color: var(--primary); }
.picker-list { max-height: 340px; overflow-y: auto; border: 1px solid var(--gray-200); border-radius: var(--radius); }
.picker-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-bottom: 1px solid var(--gray-100); cursor: pointer; font-size: 13.5px;
}
.picker-item:last-child { border-bottom: none; }
.picker-item:hover { background: var(--gray-50); }
.pi-avatar {
  width: 24px; height: 24px; border-radius: 50%; background: var(--primary-light);
  color: var(--primary); font-size: 12px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pi-name { display: flex; flex-direction: column; line-height: 1.35; }
.pi-name em { font-style: normal; font-size: 11px; color: var(--gray-400); }
.pi-cur { margin-left: auto; font-size: 11.5px; color: var(--gray-400); }

/* ---------- 提示条 ---------- */
.toast-wrap { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  padding: 10px 18px; border-radius: var(--radius); font-size: 13.5px; color: #fff;
  box-shadow: var(--shadow-lg); animation: drop .2s ease; min-width: 160px; text-align: center;
}
@keyframes drop { from { transform: translateY(-10px); opacity: 0; } }
.toast.ok { background: #16a34a; }
.toast.err { background: #dc2626; }
.toast.info { background: #26292e; }

/* ---------- Excel 批量导入 ---------- */
.imp-head {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding-bottom: 12px; border-bottom: 1px dashed var(--gray-200);
}
.imp-pick { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.imp-pick input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.imp-name { font-size: 12.5px; color: var(--gray-400); max-width: 380px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.imp-mode { margin-left: auto; display: flex; gap: 16px; font-size: 13px; color: var(--gray-600); }
.imp-mode label { display: flex; align-items: center; gap: 5px; cursor: pointer; }
.imp-hint {
  margin: 12px 0; padding: 9px 12px; background: var(--primary-light); color: #0d5fd6;
  border-radius: var(--radius); font-size: 12.5px; line-height: 1.7;
}
.imp-empty, .imp-loading { padding: 26px 0; text-align: center; color: var(--gray-400); font-size: 13px; }
.imp-fail {
  padding: 12px 14px; background: #fef2f2; border: 1px solid #fecaca;
  color: var(--danger); border-radius: var(--radius); font-size: 13px; line-height: 1.7;
}
.imp-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.imp-stat {
  font-size: 12.5px; padding: 5px 11px; border-radius: 20px;
  background: var(--gray-100); color: var(--gray-600);
}
.imp-stat b { font-size: 13.5px; }
.imp-stat.ok { background: #dcfce7; color: #15803d; }
.imp-stat.ok b { color: #15803d; }
.imp-stat.err { background: #fee2e2; color: var(--danger); }
.imp-stat.err b { color: var(--danger); }
.imp-stat.warn { background: #fef3c7; color: #b45309; }
.imp-stat.warn b { color: #b45309; }
.imp-stat.mute { background: var(--gray-100); color: var(--gray-500); }
.imp-notes { font-size: 12px; color: var(--gray-500); line-height: 1.85; margin-bottom: 10px; }
.imp-sec { font-size: 12.5px; font-weight: 600; margin: 14px 0 7px; display: flex; align-items: center; gap: 6px; }
.imp-sec::before { content: ""; width: 3px; height: 13px; border-radius: 2px; background: var(--gray-300); }
.imp-sec.err { color: var(--danger); }
.imp-sec.err::before { background: var(--danger); }
.imp-sec.warn { color: #b45309; }
.imp-sec.warn::before { background: #f59e0b; }
.imp-table-wrap { max-height: 240px; overflow: auto; border: 1px solid var(--gray-200); border-radius: var(--radius); }
table.imp-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
table.imp-table th {
  position: sticky; top: 0; z-index: 1; background: var(--gray-50);
  color: var(--gray-600); font-weight: 600; text-align: left;
  padding: 7px 10px; border-bottom: 1px solid var(--gray-200); white-space: nowrap;
}
table.imp-table td {
  padding: 7px 10px; border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700); vertical-align: top; line-height: 1.6;
}
table.imp-table tr:last-child td { border-bottom: none; }
table.imp-table tbody tr:hover { background: #f7f8fa; }
.imp-ok-all {
  margin-top: 12px; padding: 10px 14px; border-radius: var(--radius);
  background: #dcfce7; color: #15803d; font-size: 13px;
}
.imp-done {
  padding: 14px 16px; border-radius: var(--radius); background: #dcfce7;
  color: #15803d; font-size: 13.5px;
}
.imp-done .red { color: var(--danger); }

/* ---------- 组织架构（单位 → 部门） ---------- */
.org-stat { font-size: 13px; color: var(--gray-500); }
.org-stat b { color: var(--gray-900); font-weight: 600; }
.org-link { color: var(--primary); }

.org-layout { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }
@media (max-width: 980px) { .org-layout { grid-template-columns: 1fr; } }

.org-tree-panel {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); overflow: hidden;
}
.org-panel-title {
  padding: 13px 16px; font-size: 13px; font-weight: 600; color: var(--gray-700);
  border-bottom: 1px solid var(--gray-100); background: var(--gray-50);
}
.org-tree { padding: 6px 0; max-height: 560px; overflow-y: auto; }
.org-node {
  display: flex; align-items: center; gap: 6px; padding: 8px 12px 8px 8px;
  cursor: pointer; border-left: 3px solid transparent; font-size: 13px; color: var(--gray-700);
}
.org-node:hover { background: #f7f8fa; }
.org-node.active { background: var(--primary-light); border-left-color: var(--primary); }
.org-node.dept { padding-left: 28px; font-size: 12.5px; color: var(--gray-600); }
.org-node.none { border-top: 1px dashed var(--gray-200); margin-top: 4px; color: var(--gray-500); }
.org-caret { width: 14px; flex: none; text-align: center; color: var(--gray-400); font-size: 11px; }
.org-ico { flex: none; font-size: 13px; }
.org-nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.org-cnt {
  flex: none; font-size: 11px; color: var(--gray-500);
  background: var(--gray-100); border-radius: 9px; padding: 1px 7px;
}
.org-cnt.warn { background: #fef3c7; color: #b45309; }
.org-off { font-size: 10px; color: var(--danger); border: 1px solid #fecaca; border-radius: 8px; padding: 0 5px; }
.org-ops { flex: none; display: none; gap: 2px; }
.org-node:hover .org-ops { display: flex; }
.org-ops button {
  border: none; background: transparent; cursor: pointer; color: var(--gray-400);
  font-size: 12px; line-height: 1; padding: 3px 4px; border-radius: 4px;
}
.org-ops button:hover { background: var(--gray-100); color: var(--gray-700); }
.org-tip {
  padding: 12px 16px; font-size: 11.5px; color: var(--gray-400); line-height: 1.7;
  background: var(--gray-50); border-top: 1px solid var(--gray-100);
}
.org-empty { padding: 24px 16px; text-align: center; font-size: 12.5px; color: var(--gray-400); }

.org-detail {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); min-height: 300px;
}
.org-detail .empty { padding: 60px 20px; }
.org-detail-head { display: flex; align-items: flex-start; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--gray-100); }
.odh-main h3 { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.org-path { font-size: 12px; color: var(--gray-400); margin-top: 6px; }
.odh-actions { margin-left: auto; display: flex; gap: 8px; flex-shrink: 0; }

.org-meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--gray-100); }
@media (max-width: 1200px) { .org-meta { grid-template-columns: repeat(2, 1fr); } }
.org-meta > div { background: #fff; padding: 11px 20px; display: flex; flex-direction: column; gap: 4px; }
.org-meta span { font-size: 11.5px; color: var(--gray-400); }
.org-meta b { font-size: 13px; color: var(--gray-800); font-weight: 500; }

.org-section { padding: 14px 20px 18px; border-top: 1px solid var(--gray-100); }
.org-section-head {
  display: flex; align-items: center; gap: 10px; margin-bottom: 10px;
  font-size: 13px; font-weight: 600; color: var(--gray-700);
}
.org-section-head button { margin-left: auto; }
.org-badge {
  font-style: normal; font-size: 11px; font-weight: 600; color: var(--gray-500);
  background: var(--gray-100); border-radius: 9px; padding: 1px 7px;
}
.org-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.org-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px;
  border: 1px solid var(--gray-200); border-radius: 16px; font-size: 12.5px;
  color: var(--gray-700); cursor: pointer; transition: all .15s;
}
.org-chip:hover { border-color: var(--primary); color: var(--primary); }
.org-chip em { font-style: normal; font-size: 11px; color: var(--gray-400); }
.org-hint { margin-top: 10px; font-size: 11.5px; color: var(--gray-400); }
.org-kind-fixed {
  font-size: 13px; color: var(--gray-700); padding: 8px 10px;
  background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: var(--radius);
}

.mc-type { font-size: 10px; color: var(--gray-400); }
.org-cell {
  display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; color: var(--gray-700);
}
.org-cell.none { color: var(--gray-400); font-style: italic; }
.picker-item .pi-cur.warn { color: #b45309; }

/* ---------- 组织架构（左树 + 右成员表，对齐简道云通讯录） ---------- */
.org2-layout {
  display: grid; grid-template-columns: 240px 1fr; min-height: 620px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); overflow: hidden;
}
@media (max-width: 900px) { .org2-layout { grid-template-columns: 1fr; } }

.org2-side {
  display: flex; flex-direction: column; background: #ffffff;
  border-right: 1px solid var(--gray-100);
}
.org2-side-head {
  display: flex; align-items: center; padding: 12px 14px;
  font-size: 13px; font-weight: 600; color: var(--gray-700);
  border-bottom: 1px solid var(--gray-100);
}
.org2-add {
  margin-left: auto; border: none; background: transparent; cursor: pointer;
  color: var(--primary); font-size: 15px; line-height: 1; padding: 3px 6px; border-radius: 4px;
}
.org2-add:hover { background: var(--primary-light); }
.org2-search { padding: 10px 12px 6px; }
.org2-search input {
  width: 100%; height: 32px; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 0 10px; font-size: 12.5px; outline: none; background: #fff;
}
.org2-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(44,135,214, .08); }
.org2-tree { flex: 1 1 auto; overflow-y: auto; padding: 4px 0 10px; max-height: 560px; }
.org2-node {
  display: flex; align-items: center; gap: 6px; padding: 8px 12px;
  font-size: 13px; color: var(--gray-700); cursor: pointer;
  border-left: 3px solid transparent; transition: background .12s;
}
.org2-node:hover { background: #f2f8ff; }
.org2-node.active { background: var(--primary-light); border-left-color: var(--primary); color: var(--primary); font-weight: 500; }
.org2-node.dept { padding-left: 30px; font-size: 12.5px; }
.org2-node.special { color: var(--gray-600); }
.org2-caret { width: 12px; flex: none; text-align: center; font-size: 10px; color: var(--gray-400); }
.org2-ico {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  vertical-align: -2px; opacity: .75;
}
.org2-node.active .org2-ico { opacity: 1; }
.org2-title .org2-ico { color: var(--primary); opacity: 1; }
.nav-item .ico svg { display: block; margin: 0 auto; }
.org2-nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.org2-cnt { flex: none; font-size: 11px; color: var(--gray-400); }
.org2-cnt.warn { color: #b45309; }
.org2-off { font-size: 10px; color: var(--danger); border: 1px solid #fecaca; border-radius: 8px; padding: 0 5px; }
.org2-sep { height: 1px; background: var(--gray-100); margin: 6px 12px; }
.org2-empty { padding: 18px 14px; text-align: center; font-size: 12px; color: var(--gray-400); }
.org2-side-foot {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-top: 1px solid var(--gray-100);
  font-size: 11.5px; color: var(--gray-400); background: var(--gray-50);
}
.org2-link { margin-left: auto; color: var(--primary); text-decoration: none; flex: none; }
.org2-link:hover { text-decoration: underline; }
.org2-danger-zone {
  display: flex; align-items: center; gap: 10px; margin-top: 16px; padding-top: 14px;
  border-top: 1px dashed var(--gray-200);
}
.org2-danger-zone span { font-size: 11.5px; color: var(--gray-400); }
.btn.danger, .btn-default.danger { color: var(--danger); border-color: #fecaca; }
.btn-default.danger:hover { background: #fef2f2; border-color: var(--danger); }

.org2-main { min-width: 0; display: flex; flex-direction: column; }
.org2-head {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--gray-100);
}
.org2-title h3 { font-size: 15.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.org2-sub { font-size: 12px; color: var(--gray-400); margin-top: 6px; }
.org2-acts { margin-left: auto; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.link-act {
  border: none; background: transparent; color: var(--primary);
  font-size: 12.5px; cursor: pointer; padding: 2px 0;
}
.link-act:hover { text-decoration: underline; }
.link-act.danger { color: var(--danger); }

.org2-toolbar { display: flex; align-items: center; gap: 10px; padding: 12px 20px; flex-wrap: wrap; }
.org2-toolbar .spacer { flex: 1; }
.org2-selnum { font-size: 12px; color: var(--gray-500); }
.org2-tool-search input {
  height: 32px; width: 190px; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 0 10px; font-size: 12.5px; outline: none;
}
.org2-tool-search input:focus { border-color: var(--primary); }
.org2-sel {
  height: 32px; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 0 8px; font-size: 12.5px; color: var(--gray-700); background: #fff;
}

.org2-table-wrap { padding: 0 20px 16px; }
.org2-ck { width: 38px; text-align: center; }
.org2-ck input { cursor: pointer; }
.org2-user { display: inline-flex; align-items: center; gap: 8px; }
.org2-user b { font-weight: 500; color: var(--gray-800); }

/* ===== 招标项目仪表盘（工作台，对齐简道云 dash 654cfc51d64c69b0c99826ef） ===== */
.tb-top { display: flex; gap: 12px; margin-bottom: 12px; align-items: stretch; }
.tb-filters {
  flex: 1 1 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: minmax(70px, auto);   /* 行高下限固定：切换筛选条件时筛选区不抖动 */
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  overflow: visible;   /* 多选下拉面板要能溢出单元格 */
}
.tb-cell {
  padding: 8px 12px 9px; border-right: 1px solid var(--gray-100);
  border-bottom: 1px solid var(--gray-100); min-width: 0; min-height: 70px;
}
.tb-cell:nth-child(4n) { border-right: none; }
.tb-cell:nth-child(n+5) { border-bottom: none; }
.tb-cell > label { display: block; font-size: 12px; color: var(--gray-500); margin-bottom: 6px; }
/* 注意：排除 checkbox —— 多选下拉面板里的复选框不能被撑成 100% 宽/30px 高，
   否则文字会被挤成 0 宽而看不见（2026-10-21 实测） */
.tb-cell input:not([type="checkbox"]), .tb-cell select {
  width: 100%; height: 30px; border: none; outline: none; background: transparent;
  font-size: 13px; color: var(--gray-900); font-family: inherit;
}
.tb-cell select { cursor: pointer; }
.tb-cell input::placeholder { color: var(--gray-300); }
.tb-range { display: flex; align-items: center; gap: 4px; }
.tb-range input { min-width: 0; font-size: 12.5px; }
.tb-range span { color: var(--gray-300); flex: none; }

.tb-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.tb-chip {
  height: 27px; padding: 0 12px; border-radius: 4px; border: 1px solid var(--gray-200);
  background: #fff; color: var(--gray-600); font-size: 12.5px; cursor: pointer;
  font-family: inherit; transition: all .12s;
}
.tb-chip:hover { border-color: var(--primary); color: var(--primary); }
.tb-chip.on { background: #eaf2ff; border-color: #bcd9f4; color: #0d5fd6; font-weight: 600; }
/* 两三个按钮的筛选项（企业类型等）：平分单元格宽度，不要挤在左侧留一大片空白 */
.tb-chips-even > .tb-chip { flex: 1 1 0; min-width: 0; }

.tb-kpis {
  flex: 0 0 320px; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr;
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius); overflow: hidden;
}
.tb-kpi {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 8px; border-right: 1px solid var(--gray-100); border-bottom: 1px solid var(--gray-100);
}
.tb-kpi:nth-child(2n) { border-right: none; }
.tb-kpi:nth-child(n+3) { border-bottom: none; }
.tb-kpi .label { font-size: 12.5px; color: var(--gray-500); }
.tb-kpi .value {
  font-size: 26px; font-weight: 600; color: #1f2329; line-height: 1;
  font-variant-numeric: tabular-nums;
}

.tb-tabs { display: flex; gap: 3px; align-items: flex-end; padding-left: 1px; }
.tb-tab {
  height: 36px; padding: 0 18px; border: 1px solid var(--gray-200); border-bottom: none;
  border-radius: 6px 6px 0 0; background: #eef5fd; color: var(--gray-600);
  font-size: 13.5px; cursor: pointer; font-family: inherit;
}
.tb-tab:hover { color: var(--primary); }
.tb-tab.active { background: #fff; color: var(--primary); font-weight: 600; }
.tb-panel {
  background: #fff; border: 1px solid var(--gray-200); border-radius: 0 8px 8px 8px;
  padding: 14px 16px 10px;
}

/* 多表标签页：对齐简道云栅格（总宽 60，span=30 两列并排、span=60 整宽） */
.tb-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 22px; align-items: start; }
.tb-grid > .tb-table { margin: 0; padding: 0; border-top: none; min-width: 0; }
.tb-grid > .tb-table[data-span="60"] { grid-column: 1 / -1; }
.tb-grid > .tb-table[data-span="30"] .tb-table-title { font-size: 13px; }
.tb-grid > .tb-table[data-span="30"] .pager { font-size: 12px; gap: 4px; }
.tb-grid > .tb-table[data-span="30"] .pager button { padding: 0 8px; }
.tb-grid > .tb-table[data-span="30"] table.grid { font-size: 12.5px; }
.tb-grid > .tb-table[data-span="30"] table.grid th,
.tb-grid > .tb-table[data-span="30"] table.grid td { padding: 8px 8px; }
/* 注意：不要再写 `.tb-table + .tb-table { margin-top/padding-top }`。
   多表一律包在 .tb-grid 里，网格 gap 负责间距；相邻兄弟选择器会给右列表格
   额外加外边距/内边距，表现为「右列比左列整体下移」（2026-10-21 修复）。 */
.tb-table-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; min-height: 22px; }
.tb-table-title { font-size: 13.5px; font-weight: 600; color: var(--gray-900); }
.tb-table-tools { display: flex; align-items: center; gap: 14px; font-size: 12.5px; color: var(--gray-500); }
.tb-link { color: var(--primary); text-decoration: none; }
.tb-link:hover { text-decoration: underline; }
.tb-foot { display: flex; justify-content: flex-end; padding-top: 10px; }
.tb-foot .pager { margin: 0; }
.tb-sub { display: flex; flex-direction: column; gap: 3px; text-align: left; }
.tb-sub-row { font-size: 12px; line-height: 1.45; }
.tb-sub-name { color: var(--gray-900); }
.tb-sub-meta { color: var(--gray-400); margin-left: 6px; }
.tb-muted { color: var(--gray-300); }

/* 甘特图 */
.tb-gantt { font-size: 12.5px; }
/* 甘特按 10 行铺满面板：不足 10 条补空行，行高由 flex 均分（不再留大片空白） */
.tb-panel.tb-gantt-panel { display: flex; flex-direction: column; min-height: 0; }
.tb-gantt-panel > .tb-gantt { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: auto; }
.tb-gantt-panel > .tb-gantt-legend,
.tb-gantt-panel > .tb-gantt-note { flex: none; }
.tb-gantt-panel .tb-gantt-head { flex: none; }
.tb-gantt-panel .tb-gantt-row { flex: 1 1 0; height: auto; min-height: 34px; }
.tb-gantt-panel .tb-gantt-seg { top: 50%; transform: translateY(-50%); }
.tb-gantt-row.is-empty .tb-gantt-name { color: transparent; }
.tb-gantt-head { border-bottom: 1px solid var(--gray-200); color: var(--gray-500); }
.tb-gantt-hrow { display: flex; align-items: stretch; }
.tb-gantt-hrow + .tb-gantt-hrow { border-top: 1px solid var(--gray-100); }
.tb-gantt-hrow-days .tb-gantt-name,
.tb-gantt-hrow-days .tb-gantt-days { padding: 0; }
.tb-gantt-head .tb-gantt-mon { font-weight: 500; }
.tb-gantt-day {
  flex: 1 1 0; min-width: 0; text-align: center; font-size: 10.5px; line-height: 20px;
  border-left: 1px solid var(--gray-100); overflow: hidden;
  color: var(--gray-400); font-variant-numeric: tabular-nums;
}
.tb-gantt-day:first-child { border-left: none; }
.tb-gantt-name {
  flex: 0 0 260px; padding: 8px 10px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}
.tb-gantt-tl { flex: 1 1 auto; display: flex; min-width: 0; }
.tb-gantt-mon { text-align: center; padding: 8px 0; border-left: 1px solid var(--gray-100); overflow: hidden; white-space: nowrap; }
.tb-gantt-days { flex: 0 0 70px; text-align: center; padding: 8px 0; }
.tb-gantt-row { display: flex; align-items: center; border-bottom: 1px solid var(--gray-50); height: 38px; }
.tb-gantt-track { flex: 1 1 auto; position: relative; height: 100%; min-width: 0; }
/* 甘特条：按「公告开始 → 质疑截止 → 答疑截止 → 公告截止」分三段上色 */
.tb-gantt-seg { position: absolute; top: 11px; height: 16px; }
.tb-gantt-seg.s1 { background: #4a9be8; }   /* 公告期 */
.tb-gantt-seg.s2 { background: #f59e0b; }   /* 质疑期 */
.tb-gantt-seg.s3 { background: #10b981; }   /* 答疑至截标 */
.tb-gantt-seg.first { border-radius: 3px 0 0 3px; }
.tb-gantt-seg.last { border-radius: 0 3px 3px 0; }
.tb-gantt-seg.first.last { border-radius: 3px; }

.tb-gantt-legend {
  display: flex; flex-wrap: wrap; gap: 22px; margin-bottom: 12px; padding-bottom: 10px;
  border-bottom: 1px dashed var(--gray-200); font-size: 12.5px; color: var(--gray-600);
}
.tb-gantt-legend span { display: inline-flex; align-items: center; gap: 7px; }
.tb-gantt-legend i { width: 26px; height: 10px; border-radius: 2px; display: inline-block; }
.tb-gantt-legend i.s1 { background: #4a9be8; }
.tb-gantt-legend i.s2 { background: #f59e0b; }
.tb-gantt-legend i.s3 { background: #10b981; }
.tb-gantt-note { margin-top: 10px; font-size: 12px; color: var(--gray-400); }

@media (max-width: 1240px) {
  .tb-top { flex-wrap: wrap; }
  .tb-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tb-cell:nth-child(4n) { border-right: 1px solid var(--gray-100); }
  .tb-cell:nth-child(2n) { border-right: none; }
  .tb-cell:nth-child(n+5) { border-bottom: 1px solid var(--gray-100); }
  .tb-cell:nth-last-child(-n+2) { border-bottom: none; }
  .tb-kpis { flex: 1 1 100%; grid-template-columns: repeat(4, 1fr); grid-template-rows: 1fr; }
  .tb-kpi { border-bottom: none; }
  .tb-grid { grid-template-columns: 1fr; }
  .tb-grid > .tb-table[data-span="60"] { grid-column: auto; }
}

/* 多选下拉（交易平台 / 采购工程师） */
.tb-ms { position: relative; }
.tb-ms-btn {
  width: 100%; height: 30px; display: flex; align-items: center; justify-content: space-between;
  gap: 6px; border: none; background: transparent; padding: 0; cursor: pointer;
  font-family: inherit; font-size: 13px; color: var(--gray-900); text-align: left;
}
.tb-ms-btn .tb-ms-text { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tb-ms-btn:not(.has) .tb-ms-text { color: var(--gray-300); }
.tb-ms-caret {
  flex: none; width: 0; height: 0; border-left: 4px solid transparent;
  border-right: 4px solid transparent; border-top: 5px solid var(--gray-400);
}
.tb-ms-panel {
  position: absolute; z-index: 40; top: calc(100% + 7px); left: -12px; right: -12px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 6px;
  box-shadow: var(--shadow-lg); padding: 4px; max-height: 232px; overflow: auto;
}
.tb-ms-panel[hidden] { display: none !important; }
.tb-ms-clear {
  padding: 7px 10px; font-size: 13px; color: var(--gray-500);
  cursor: pointer; border-radius: 4px;
}
.tb-ms-clear:hover { background: var(--gray-50); color: var(--primary); }
.tb-ms-item {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px; font-size: 13px;
  color: var(--gray-900); cursor: pointer; border-radius: 4px;
}
.tb-ms-item:hover { background: var(--gray-50); }
.tb-ms-item input[type="checkbox"] {
  flex: none; width: 14px; height: 14px; margin: 0; padding: 0;
  accent-color: var(--primary); cursor: pointer;
}
/* 选项保持单行 + 省略号（不折行）：完整内容由 title 悬停显示，见 ui.js 的 msTips() */
.tb-ms-item span {
  flex: 1 1 auto; min-width: 0;
  overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}

/* 甘特时间轴：悬停指示线与浮层 */
.tb-gantt-cursor {
  position: absolute; top: 0; bottom: 0; width: 1px; display: none;
  background: rgba(44,135,214, .45); pointer-events: none; z-index: 3;
}
.tb-tip {
  position: fixed; z-index: 70; pointer-events: none; white-space: nowrap;
  background: rgba(18, 49, 76, .94); color: #fff; font-size: 12px; line-height: 1.5;
  padding: 6px 9px; border-radius: 5px; box-shadow: 0 4px 14px rgba(18, 49, 76, .24);
}
.tb-tip b { font-weight: 500; font-variant-numeric: tabular-nums; }
.tb-tip span { display: block; color: #c9dcf0; margin-top: 1px; }

/* ===== 数据统计仪表盘（对齐简道云 dash 6819ca4bc22721653103d385，画布 60 栅格） ===== */
/* 筛选器 6 列（简道云 6 个筛选器各占 10/60） */
.sb-filters { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.sb-filters .tb-cell { border-bottom: none; }
.sb-filters .tb-cell:nth-child(4n) { border-right: 1px solid var(--gray-100); }
.sb-filters .tb-cell:nth-child(6n) { border-right: none; }

/* 栅格：60 列模拟简道云画布。行高原为 145px（2 行 = 300px），按用户要求整体压缩 1/3 → 97px（2 行 ≈ 204px） */
.sb-grid {
  display: grid;
  grid-template-columns: repeat(60, minmax(0, 1fr));
  grid-auto-rows: 97px;
  gap: 10px;
  align-items: stretch;
}
.sb-card {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); min-width: 0; overflow: hidden;
  display: flex; flex-direction: column;
}
.sb-grid .chart-card { height: 100%; }

/* 指标卡（本月公告/截标/定标、正在招标、平均数） */
.sb-metric { align-items: center; justify-content: center; gap: 8px; padding: 10px; text-align: center; }
.sb-metric .label { font-size: 12.5px; color: var(--gray-500); line-height: 1.35; }
.sb-metric .value {
  font-size: 26px; font-weight: 600; color: #1f2329; line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.sb-metric .value .unit { font-size: 13px; font-weight: 500; color: var(--gray-400); margin-left: 2px; }

/* 大指标卡（完成标段数量 / 累计中标金额，简道云为通栏色块） */
.sb-hero { border: none; color: #fff; padding: 18px; justify-content: center; gap: 10px; }
.sb-hero.blue { background: linear-gradient(135deg, #7cc6f3 0%, #1677ff 100%); }
.sb-hero.orange { background: linear-gradient(135deg, #f7a94a 0%, #f08a3c 100%); }
.sb-hero .label { font-size: 13.5px; opacity: .95; }
.sb-hero .value { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1; }
.sb-hero .value .unit { font-size: 15px; font-weight: 500; margin-left: 3px; }

/* 分组容器「中标结果统计信息」（简道云 y=60，首屏外） */
.sb-group {
  grid-column: span 60; background: #fff; border: 1px solid var(--gray-200);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
  padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; min-height: 0;
}
.sb-group-title { font-size: 13px; font-weight: 600; color: var(--gray-700); }
.sb-group-cards {
  flex: 1 1 auto; min-height: 0;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-template-rows: 1fr 1fr; gap: 8px;
}
.sb-group-cards .sb-card { box-shadow: none; border-color: var(--gray-100); }
.sb-group-cards .sb-metric .value { font-size: 21px; }

@media (max-width: 1200px) {
  .sb-filters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: auto; }
  .sb-grid > * { grid-column: auto !important; grid-row: auto !important; min-height: 145px; }
  .sb-grid > .sb-card.has-chart { min-height: 300px; }
  .sb-group { grid-column: auto; min-height: 520px; }
  .sb-group-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; grid-auto-rows: 110px; }
}

/* ===== 属地企业情况仪表盘（对齐简道云 dash 69b9562722a95d7139c00e92，画布 60 栅格） ===== */
/* 顶部一条：4 个筛选（各 10 列）+ 中标企业组合卡（8 列）+ 2 张指标卡（各 6 列）= 60 列 */
.sx-bar {
  display: grid; grid-template-columns: repeat(60, minmax(0, 1fr));
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  margin-bottom: 12px; overflow: visible;   /* 多选下拉面板要能溢出单元格 */
}
.sx-cell {
  padding: 9px 12px; min-width: 0; min-height: 72px;
  display: flex; flex-direction: column; justify-content: center; gap: 6px;
  border-right: 1px solid var(--gray-100);
}
.sx-cell:last-child { border-right: none; }
.sx-cell > label { display: block; font-size: 12px; color: var(--gray-500); }
.sx-cell input:not([type="checkbox"]), .sx-cell select.sx-select {
  width: 100%; height: 30px; border: none; outline: none; background: transparent;
  font-size: 13px; color: var(--gray-900); font-family: inherit;
}
.sx-cell select.sx-select { cursor: pointer; }
.sx-cell input::placeholder { color: var(--gray-300); }
.sx-hint { font-size: 11px; color: #d97706; line-height: 1.2; }

/* 指标卡（项目数量 / 投标人平均数量） */
.sx-metric { align-items: center; text-align: center; gap: 6px; }
.sx-metric .label { font-size: 12.5px; color: var(--gray-500); }
.sx-metric .value {
  font-size: 26px; font-weight: 600; color: #1f2329; line-height: 1;
  font-variant-numeric: tabular-nums;
}

/* 明细表面板 */
.sx-panel {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); padding: 12px 16px 10px;
  /* 面板最多占满一屏：内容超长（如投标人看板「主表 + 子表」）时表格在面板内滚动，页面不整页滚 */
  display: flex; flex-direction: column; min-height: 0; max-height: 100%;
}
.sx-panel > .pager { flex: none; }
/* 直接挂在内容区的面板：允许收缩到「上方筛选条之外的剩余高度」，实现「页面不滚、表格内部滚」 */
#view > .sx-panel { flex: 1 1 auto; min-height: 0; }
/* 表格滚动区：横向、纵向都在这里滚，表头 sticky 相对它生效 */
.sx-panel > .sx-table-wrap { flex: 1 1 auto; min-height: 0; overflow: auto; }
.sx-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; min-height: 22px; }
/* 只有工具链接、没有标题的表头（如框架协议明细：标题与页面标题重复已去掉）：
   链接靠右，行高压到最小，不给表格上方留空行 */
.sx-head-end { justify-content: flex-end; margin-bottom: 8px; min-height: 18px; }
.sx-title { font-size: 13.5px; font-weight: 600; color: var(--gray-900); }
.sx-tools { display: flex; align-items: center; gap: 14px; font-size: 12.5px; }
.sx-table-wrap { overflow-x: auto; }
/* ⚠️ 必须带 table.grid 前缀提权：`table.grid th{white-space:nowrap}` 是 (0,1,2)，
   单写 `.sx-table th`(0,1,1) 压不住，表头会挤成一行带省略号 */
table.grid.sx-table { table-layout: fixed; width: 100%; min-width: 1340px; }
/* 投标人基础信息：该页列少，取消 1340 的最小宽并收窄固定列，1440 视口下不出横向滚动条 */
table.grid.sx-table.tbr-table { min-width: 0; }
table.grid.sx-table.tbr-table td.sx-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
table.grid.sx-table th, table.grid.sx-table td { padding: 8px; }
table.grid.sx-table th { white-space: normal; line-height: 1.4; vertical-align: middle; }
table.grid.sx-table td { overflow: hidden; text-overflow: ellipsis; }
.sx-table tbody tr:hover { background: #f7f8fa; }
.sx-table td.sx-flag { text-align: center; }
/* 中标企业两张卡：并排（用户要求，等宽平分卡片宽度） */
.sx-combine .tb-chips { flex-direction: row; flex-wrap: nowrap; gap: 6px; }
.sx-combine .tb-chip {
  flex: 1 1 0; min-width: 0; height: 24px; padding: 0 4px; font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

@media (max-width: 1200px) {
  .sx-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sx-cell { grid-column: auto !important; border-right: none; border-bottom: 1px solid var(--gray-100); }
  .sx-cell:last-child { border-bottom: none; }
  /* 指标块用了显式列号（41 / span 20），两列布局下必须放回自动流，否则会溢出 */
  .nb-bar .nb-metrics { grid-column: auto !important; }
}

/* ===== 招投标信息分组：仪表盘与列表补充样式 ===== */
.cell-sub { color: var(--gray-400); font-size: 11px; line-height: 1.4; }
a.file-link { color: var(--primary); text-decoration: none; }
a.file-link:hover { text-decoration: underline; }

/* 投标人基础信息仪表盘：子表按人分行展示 */
.tbr-credits { display: flex; flex-direction: column; gap: 6px; }
.tbr-credit { border-bottom: 1px dashed var(--gray-100); padding-bottom: 5px; }
.tbr-credit:last-child { border-bottom: none; padding-bottom: 0; }
.tbr-credit-main { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.tbr-idx { color: var(--gray-400); font-size: 11.5px; min-width: 14px; }
.tbr-name { font-weight: 500; }
.tbr-credit-sub {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 2px;
  color: var(--gray-400); font-size: 11.5px;
}
/* 备案清单：18 列需要横向滚动 */
table.grid.fb-table { min-width: 2600px; }
.sx-bar-single .sx-cell:last-child { border-right: none; }
/* 子表单元格内的长文本（注册地址/信用代码）必须能收缩，否则会把表格撑出容器 */
.tbr-credit-sub span {
  max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tbr-credit-main { min-width: 0; }
.tbr-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 子表单列多时（如「投标人基础信息查询」7 列）允许横向滚动，避免操作列被挤出弹窗 */
.field[data-subform] { overflow-x: auto; }
.field[data-subform] .sub-table { min-width: 100%; }

/* ===== 流程设置（系统设置 → 流程设置） ===== */
.fl-page { display: flex; flex-direction: column; gap: 12px; }
.fl-card { padding: 0; overflow: hidden; }
.fl-head {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 16px; border-bottom: 1px solid var(--gray-100);
}
.fl-tabs { display: flex; gap: 4px; background: var(--gray-50); padding: 3px; border-radius: 8px; }
.fl-tab {
  border: none; background: transparent; padding: 6px 14px; border-radius: 6px;
  font-size: 13px; color: var(--gray-500); cursor: pointer;
}
.fl-tab:hover { color: var(--primary); }
.fl-tab.on { background: #fff; color: var(--primary); font-weight: 500; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.fl-hint { font-size: 12px; color: var(--gray-400); }
.fl-body { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.fl-empty {
  padding: 26px; text-align: center; font-size: 13px; color: var(--gray-400);
  background: var(--gray-50); border: 1px dashed var(--gray-200); border-radius: 8px;
}
.fl-node {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px; border: 1px solid var(--gray-200); border-radius: 8px; background: #fff;
}
.fl-node:hover { border-color: var(--primary-line); }
.fl-node-no {
  flex: none; width: 24px; height: 24px; border-radius: 50%; margin-top: 2px;
  background: var(--primary-light); color: var(--primary);
  font-size: 12px; font-weight: 600; display: flex; align-items: center; justify-content: center;
}
.fl-node-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.fl-node-ops { flex: none; display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.fl-node-ops .link-btn[disabled] { color: var(--gray-300); cursor: not-allowed; }
.fl-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fl-lb { flex: none; width: 68px; font-size: 12.5px; color: var(--gray-500); }
.fl-lb2 { width: auto; margin-left: 8px; }
.fl-input {
  height: 30px; padding: 0 8px; font-size: 13px; border: 1px solid var(--gray-200);
  border-radius: 6px; background: #fff; color: var(--gray-800); min-width: 150px;
}
.fl-input:focus { outline: none; border-color: var(--primary); }
.fl-name { width: 240px; }
.fl-row select.fl-input { min-width: 170px; }
.fl-check { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--gray-500); cursor: pointer; }
.fl-chips {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  min-height: 30px; padding: 3px 6px; border: 1px solid var(--gray-200); border-radius: 6px;
  min-width: 240px; flex: 1;
}
.fl-chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px;
  background: var(--primary-light); color: var(--primary); border-radius: 10px; font-size: 12px;
}
.fl-chip i { cursor: pointer; font-style: normal; opacity: .7; }
.fl-chip i:hover { opacity: 1; }
.fl-chip-input { border: none; outline: none; font-size: 12.5px; min-width: 110px; flex: 1; background: transparent; }
.fl-foot {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 16px; border-top: 1px solid var(--gray-100); background: #fafbfc;
}
/* 详情页审批记录 */
.flow-logs { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.flow-logs th, .flow-logs td { padding: 6px 8px; border-bottom: 1px solid var(--gray-100); text-align: left; }
.flow-logs th { color: var(--gray-500); font-weight: 500; background: var(--gray-50); }
/* 流程：详情页当前节点提示 + 审批记录容器 */
.flow-node-tip {
  display: inline-block; margin-left: 6px; font-size: 11.5px; color: var(--gray-400);
  max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle;
}
.detail-flow { padding: 4px 20px 18px; }
.detail-flow .form-logs { margin-bottom: 0; }
/* 流程设置：抄送人输入框占满剩余宽度 */
.fl-row-2 .fl-input { flex: 1; min-width: 220px; }

/* ===== 招标代理业务分配记录（对齐简道云 dash 695ddf01a733124d14adfef5） ===== */
/* 4 个筛选器单行排布（简道云 15+12+10+10 栅格，本地等分） */
.ab-filters {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  overflow: visible; margin-bottom: 12px;
}
.ab-filters .tb-cell { border-bottom: none; }
.ab-filters .tb-cell:nth-child(4n) { border-right: none; }
.ab-filters .tb-ms-panel { max-height: 300px; }
/* 业务范围候选有 50+ 项，面板内加过滤框 */
.ab-ms-search {
  width: 100%; height: 28px; border: 1px solid var(--gray-200); border-radius: 4px;
  padding: 0 8px; margin-bottom: 3px; font-size: 12.5px; font-family: inherit;
  outline: none; color: var(--gray-900);
}
.ab-ms-search:focus { border-color: var(--primary); }
/* 表格 + 右侧图表（简道云：表 43/60，图 17/60 上下叠） */
.ab-split { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 18px; align-items: start; }
/* 关键：grid 子项必须允许收缩，否则表格的 min-width 会把右栏图表挤出视口 */
.ab-split > * { min-width: 0; }
.ab-chart-col { display: grid; gap: 14px; }
.ab-stack { display: grid; gap: 16px; }
/* 标签面板撑满到底：与招标项目等页面一致（白卡到视口底，表格吃掉剩余高度） */
#ab-panel { display: flex; flex-direction: column; }
#ab-panel > .ab-stack { flex: 1 1 auto; min-height: 0; }
#ab-panel > .ab-stack.ab-stack-single { grid-template-rows: minmax(0, 1fr); }
#ab-panel > .ab-stack > .sx-panel { min-height: 0; }
/* 表 + 图表标签页：左表吃满剩余高度，右栏两张图等高平分，两边底边齐平 */
#ab-panel > .ab-split { flex: 1 1 auto; min-height: 0; }
#ab-panel > .ab-split > .ab-table-col { display: flex; flex-direction: column; min-height: 0; align-self: stretch; }
#ab-panel > .ab-split > .ab-table-col > .sx-panel { flex: 1 1 auto; min-height: 0; }
#ab-panel > .ab-split > .ab-chart-col { display: flex; flex-direction: column; gap: 14px; align-self: stretch; }
#ab-panel > .ab-split > .ab-chart-col > .ab-chart { flex: 1 1 0; min-height: 0; height: auto; }
.ab-chart-col { align-content: start; }
.ab-table { min-width: 0; overflow: hidden; }
.ab-table .sx-head { margin-bottom: 8px; }
.ab-table .sx-table-wrap { overflow-x: auto; max-width: 100%; }
.ab-table table.grid.sx-table { min-width: 0; }
/* 表头单行不换行：列被压缩时换行会把表头撑成 2~3 行（「序号」竖排），
   行高被挤掉一截，看起来表格高度不对；超长用省略号 + title 悬停 */
.ab-table table.grid.sx-table thead th {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-size: 11px; padding: 4px 4px;
}
.ab-table table.grid.sx-table th.ab-th-void { background: #f7f8fa; }
.ab-table td { height: 34px; }
.ab-table td.idx { color: var(--gray-400); font-variant-numeric: tabular-nums; }
@media (max-width: 1240px) {
  .ab-split { grid-template-columns: 1fr; }
  /* 单栏：表格在上、两张图并排在下方，高度按内容，整页滚动（不再撑满） */
  #ab-panel > .ab-split { flex: 0 0 auto; }
  #ab-panel > .ab-split > .ab-table-col > .sx-panel { flex: none; }
  #ab-panel > .ab-split > .ab-chart-col {
    display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: 280px; gap: 14px;
  }
  #ab-panel > .ab-split > .ab-chart-col > .ab-chart { flex: none; height: 280px; }
}
@media (max-width: 900px) {
  .ab-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ab-filters .tb-cell:nth-child(4n) { border-right: 1px solid var(--gray-100); }
  .ab-filters .tb-cell:nth-child(2n) { border-right: none; }
  #ab-panel > .ab-split > .ab-chart-col { grid-template-columns: 1fr; }
}

/* ===== 框架协议管理 / 标准化体系 / 履约管理：仪表盘与列表 ===== */
/* 标题（对齐简道云 description 组件：蓝色加粗居中） */
.nb-title {
  font-size: 22px; font-weight: 700; color: #1677ff; text-align: center;
  letter-spacing: 0.5px; padding: 12px 0 16px;
}
.nb-title-lg { font-size: 30px; letter-spacing: 1px; }

/* 两栏（主表 + 右栏筛选/图表） */
.nb-split { display: grid; grid-template-columns: minmax(0, 1fr) 272px; gap: 14px; }
.nb-split > * { min-width: 0; }
/* 整块占满内容区剩余高度：左主表铺满、右侧筛选栏内部滚动，页面不再整页滚 */
#view > .nb-split { flex: 1 1 auto; min-height: 0; }
.nb-split > .nb-main { display: flex; flex-direction: column; min-height: 0; }
.nb-split > .nb-main > .sx-panel { flex: 1 1 auto; min-height: 0; }
.nb-split > .nb-side { min-height: 0; overflow-y: auto; }
.nb-split-std { grid-template-columns: minmax(0, 1fr) 300px; }
.nb-side { display: flex; flex-direction: column; gap: 12px; }
.nb-main { min-width: 0; }

/* 右栏竖向筛选堆叠 */
.nb-filter-stack {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 10px; display: flex; flex-direction: column; gap: 10px;
}
/* 右栏（筛选 + 两张小图）要在一屏内放下、不出滚动条：图表压到 136px */
.nb-side .nb-mini-chart .chart-box { height: 136px; }
/* 右栏里的说明块行高略紧，避免整栏超高触发滚动条（标准化文件页） */
.nb-side .nb-note { line-height: 1.6; padding: 8px 10px; font-size: 12px; }
.nb-fitem { display: flex; flex-direction: column; gap: 5px; }
.nb-fitem > label { font-size: 12px; color: var(--gray-500); }
.nb-input {
  width: 100%; height: 32px; border: 1px solid var(--gray-200); border-radius: 8px;
  padding: 0 10px; font-size: 13px; color: var(--gray-900); font-family: inherit;
  outline: none; background: #fff;
}
.nb-input:focus { border-color: var(--primary); }
.nb-fitem .tb-ms, .nb-fitem .tb-ms-btn { width: 100%; }
.nb-fitem .tb-chips { flex-wrap: wrap; }

/* tab 条（简道云 group_container 的 tabList） */
.nb-tabs {
  display: flex; align-items: flex-end; gap: 2px;
  border-bottom: 1px solid var(--gray-200); margin-bottom: 12px;
}
.nb-tab {
  height: 34px; padding: 0 18px; border: none; background: transparent; cursor: pointer;
  font-size: 13px; color: #5c636d; font-family: inherit; border-radius: 8px 8px 0 0;
  border-bottom: 2px solid transparent;
}
.nb-tab:hover { color: #0d5fd6; }
.nb-tab.on { background: #eaf2ff; color: #0d5fd6; font-weight: 600; border-bottom-color: var(--primary); }

/* 指标卡（对齐 metric_table） */
.nb-metrics { display: flex; gap: 10px; padding: 9px 12px; align-items: stretch; }
.nb-metric {
  flex: 1 1 0; min-width: 0; background: #fff; border: 1px solid var(--gray-200);
  border-radius: 8px; padding: 6px 8px; display: flex; flex-direction: column;
  justify-content: center; align-items: center; gap: 4px; text-align: center;
}
/* 标题必须留在卡片里：flex 居中会让 <div> 收缩成文字宽度、撑出卡片边框，
   所以显式限宽 + 允许折行（不截断、不省略号） */
.nb-metric-t {
  max-width: 100%; align-self: stretch; font-size: 12px; color: var(--gray-500);
  white-space: normal; line-height: 1.3; word-break: break-word;
}
.nb-metric-v { font-size: 24px; font-weight: 700; color: #1f2329; line-height: 1.1; font-variant-numeric: tabular-nums; }

/* 框架协议筛选条：与右侧指标卡统一"白卡 + 圆角边框"的分隔方式，
   不再用 1px 分隔线（条本身透明，靠 8px 间隙把各格分开） */
.nb-bar-fw { background: transparent; border: none; gap: 8px; }
.nb-bar-fw > .sx-cell {
  background: #fff; border: 1px solid var(--gray-200); border-radius: 8px;
}
/* 指标块去掉内边距，两张卡与左侧筛选卡同高同宽、同样留 8px 缝 */
.nb-bar-fw > .nb-metrics { padding: 0; gap: 8px; }

/* 右侧小图表 / 说明 */
.nb-mini-chart { height: auto; }
.nb-mini-chart .chart-title { padding: 10px 14px; font-size: 13px; }
.nb-mini-chart .chart-box { height: 180px; padding: 6px; }
/* 标准化文件右栏：整体高度跟着左栏走（右侧内容不参与行高计算，避免把整行撑高），
   图表卡片吃掉「使用说明」占位之后的剩余高度 */
.nb-split-std { align-items: start; }
.nb-side-std { min-height: 0; }
.nb-side-std .nb-note { flex: 0 0 auto; }
.nb-side-std .nb-mini-chart { flex: 1 1 auto; min-height: 0; height: auto; }
.nb-side-std .nb-mini-chart .chart-box { height: auto; flex: 1 1 auto; min-height: 0; max-height: 480px; }
.nb-note {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 12px 14px; font-size: 12.5px; color: #5c636d; line-height: 1.85;
}
.nb-note b { color: #0d5fd6; }
.nb-note p { margin: 6px 0 0; text-indent: 0; }
.nb-hint { font-size: 12.5px; color: #7c99b3; line-height: 1.7; }
.nb-update { font-size: 15px; font-weight: 600; color: #eb5050; }

/* 统计 tab 的两张图并排 */
.nb-stats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.nb-stats-row .nb-mini-chart .chart-box { height: 230px; }

/* 不良行为记录：表头红（对齐简道云该仪表盘红色主题） */
.nb-panel-bad table.grid.sx-table th { background: #fdecec; color: #b0322f; }
.nb-panel-bad table.grid.sx-table tbody tr:nth-child(-n+16) { background: #fff7f7; }

/* 制度文件：右栏「筛选 + 发布部门 + 制度层级」整体铺满左栏高度，两张图均分剩余空间
   （grid 默认 stretch 已把 .nb-side 拉到行高，这里让卡片 flex 填满，不再留 90+px 空白） */
.nb-split-reg > .nb-side { min-height: 0; }
.nb-split-reg > .nb-side > .nb-filter-stack { flex: 0 0 auto; }
.nb-split-reg > .nb-side > .nb-mini-chart { flex: 1 1 0; min-height: 0; height: auto; }
.nb-split-reg > .nb-side > .nb-mini-chart .chart-box { height: auto; flex: 1 1 auto; min-height: 0; }

@media (max-width: 1240px) {
  .nb-split, .nb-split-std { grid-template-columns: 1fr; }
  .nb-stats-row { grid-template-columns: 1fr; }
  /* 单列堆叠时不再等高，图表回到固定高度（内联高度由 JS 清空） */
  .nb-side-std { min-height: 0; }
  .nb-side-std .nb-mini-chart { flex: none; }
  .nb-side-std .nb-mini-chart .chart-box { height: 180px; flex: none; }
  /* 制度文件右栏在单列时同样回归固定高度，避免 flex:1 把图压成 0；
     单列改 block 排布，让内容自然撑高、由内容区滚动，而不是被 grid 行压扁 */
  .nb-split-reg { display: block; height: auto; }
  .nb-split-reg > .nb-main { margin-bottom: 14px; }
  .nb-split-reg > .nb-side { height: auto; }
  .nb-split-reg > .nb-side > .nb-mini-chart { flex: none; }
  .nb-split-reg > .nb-side > .nb-mini-chart .chart-box { height: 180px; flex: none; }
}

/* 表格一屏铺满：取消通用 .sx-table 的 1340px 最小宽，列宽按比例收缩 */
table.grid.sx-table.nb-table { min-width: 0; }
table.grid.sx-table.nb-table th, table.grid.sx-table.nb-table td { padding: 8px 6px; }
/* 制度层级等长文本允许两行显示，避免被省略号切断 */
.nb-table td .tag { display: inline-block; white-space: normal; line-height: 1.35; text-align: left; }

/* 制度文件：列宽按比例铺满容器（colgroup 输出百分比），单元格单行 + 省略号，
   行距压紧 —— 横向不溢出、纵向 10 行 + 表头 + 分页一屏放得下，横竖都不出滚动条 */
table.grid.sx-table.nb-table.nb-fit { width: 100%; min-width: 0; }
table.grid.sx-table.nb-table.nb-fit th,
table.grid.sx-table.nb-table.nb-fit td {
  padding: 7px 6px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; line-height: 1.45;
}
/* 表头宁可折成两行也不省略：列窄时仍能读全「委托期开始时间」这类长表头 */
table.grid.sx-table.nb-table.nb-fit thead th { white-space: normal; line-height: 1.3; }
table.grid.sx-table.nb-table.nb-fit td .tag { white-space: nowrap; }
/* 附件图标原本 28×30 且按 baseline 对齐，会把行盒顶到 56px；压到 24px 并改居中对齐 */
table.grid.sx-table.nb-table.nb-fit td .file-chips { vertical-align: middle; }
table.grid.sx-table.nb-table.nb-fit td .file-chip { width: 22px; height: 24px; font-size: 8px; }

/* 子表附件单元格（版本记录 / 版本信息） */
.sub-up { display: flex; align-items: center; gap: 8px; min-width: 0; }
.sub-up-list { flex: 1 1 auto; min-width: 0; font-size: 12px; line-height: 1.5; }
.sub-up-list a { color: var(--primary); text-decoration: none; }
.sub-up-list a:hover { text-decoration: underline; }
.sub-up .link-btn { flex: none; }

/* ===== 招投标室信息（常用工具） ===== */
/* 与下方 .rb-body（2fr : 1fr 列表 + 图表）用同一套列宽，上下分割线才对得齐 */
.rb-top { display: grid; grid-template-columns: minmax(0,2fr) minmax(0,1fr); gap: 14px; margin-bottom: 14px; }
.rb-time-card, .rb-title {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
}
.rb-time-card { padding: 10px 12px; }
/* 会议时间 / 会议类型两组筛选各占一半 */
.rb-filters { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 18px; }
.rb-filter { min-width: 0; }
.rb-time-title { font-size: 12px; color: var(--gray-500); margin-bottom: 8px; }
.rb-time-btns { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 6px; }
.rb-range {
  height: 28px; border: 1px solid var(--gray-200); background: #fff; border-radius: 6px;
  font-size: 12.5px; color: #5c636d; font-family: inherit; cursor: pointer;
}
.rb-range:hover { border-color: var(--primary); color: #0d5fd6; }
.rb-range.on { background: #eaf2ff; border-color: var(--primary); color: #0d5fd6; font-weight: 600; }
/* 会议室密码弹窗内容 */
.rb-pwd-body { display: flex; flex-direction: column; gap: 12px; font-size: 13.5px; line-height: 1.6; }
.rb-pwd-body > div { display: flex; gap: 14px; align-items: baseline; }
.rb-pwd-body b { flex: none; width: 76px; color: #0d5fd6; }
.rb-pwd-body span { color: var(--gray-700); }
.rb-title {
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; font-weight: 800; color: #1677ff; letter-spacing: 3px;
}
.rb-actions { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 0 12px; letter-spacing: 0; }
.rb-act { height: 42px; min-width: 136px; font-size: 15px; border-radius: 8px; letter-spacing: .5px; }
.rb-mine-empty { padding: 44px 0; text-align: center; color: var(--gray-500); font-size: 13px; }
.rb-mine-empty .big { color: #c8d2de; margin-bottom: 8px; }
.rb-mine-tip { font-size: 12px; color: var(--gray-500); margin-bottom: 8px; }
/* 我的预约：提示行固定，表格区自己滚动；弹窗内边距不参与滚动，吸顶表头上方才不会漏出半行 */
.rb-mine-body { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.rb-mine-body .rb-mine-tip { flex: none; margin: 0; padding: 14px 22px 8px; }
.rb-mine-body .rb-mine-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 0 22px 14px; }
.rb-mine-body .rb-mine-empty { padding: 44px 22px; }
.rb-mine-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 12.5px; }
.rb-mine-table th {
  background: #f7f9fc; color: #334155; font-weight: 600; text-align: center;
  padding: 9px 10px; border-bottom: 1px solid var(--gray-200); white-space: nowrap;
  /* 本人预约可能很多，表头在弹窗滚动时吸顶 */
  position: sticky; top: 0; z-index: 2;
}
.rb-mine-table td {
  padding: 9px 10px; border-bottom: 1px solid #eef2f7; color: var(--gray-700);
  vertical-align: middle; text-align: center;
}
.rb-mine-table tbody tr:hover { background: #f9fbff; }
.rb-mine-table tbody tr:last-child td { border-bottom: none; }
.rb-mine-sec { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 「投标文件清标会」7 个字不能被折成两行 */
.rb-mine-table .tag { white-space: nowrap; }
.rb-mine-time { line-height: 1.45; white-space: nowrap; }
.rb-mine-time .to { color: var(--gray-500); }
.rb-mine-na { color: #aab4c0; font-size: 12px; }
/* 页面整体撑满可视区：顶部筛选固定，下方列表 + 图表吃掉剩余高度，底部不留大片空白 */
.rb-page { height: 100%; min-height: 0; display: flex; flex-direction: column; }
.rb-page .rb-top { flex: none; }
.rb-body {
  display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 14px;
  flex: 1 1 auto; min-height: 0;
}
.rb-body > * { min-width: 0; }
/* 右列两张图按剩余高度等分 */
.rb-charts { display: grid; gap: 14px; align-content: stretch; grid-auto-rows: minmax(0, 1fr); min-height: 0; }
.rb-charts .nb-mini-chart { min-height: 0; }
.rb-charts .nb-mini-chart .chart-box { height: auto; flex: 1 1 auto; min-height: 150px; }
.rb-kw { width: 190px; height: 28px; font-size: 12.5px; }
table.grid.sx-table.rb-table { min-width: 0; }
/* 左侧列表面板：与右侧图表区等高，表体占满剩余空间（数据条数变化不改变面板高度） */
.rb-body > .sx-panel { display: flex; flex-direction: column; }
.rb-body > .sx-panel .sx-table-wrap { flex: 1 1 auto; min-height: 0; overflow: auto; }
/* 空态时让表格撑满，占位提示才居中 */
table.grid.sx-table.rb-table.is-empty { height: 100%; }
@media (max-width: 1240px) {
  .rb-top { grid-template-columns: 1fr; }
  .rb-body { grid-template-columns: 1fr; }
  .rb-title { height: 72px; }
  /* 窄屏改单列后不再强制铺满，按内容自然高度排布（整页滚动） */
  .rb-page { height: auto; }
  .rb-body { flex: none; }
  .rb-charts { grid-auto-rows: auto; }
  .rb-charts .nb-mini-chart .chart-box { height: 180px; flex: none; }
}

/* ---------- 附件格式块（列表/详情统一：只显示格式，不显示长文件名） ---------- */
.file-chips { display: inline-flex; flex-wrap: nowrap; gap: 4px; align-items: center; justify-content: center; }
.file-chip {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 30px; border-radius: 4px;
  background: #9aa3ad; color: #fff; text-decoration: none;
  font-size: 9px; font-weight: 700; letter-spacing: 0; line-height: 1;
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.08);
  transition: filter .15s;
}
.file-chip .file-chip-txt { transform: scale(.98); }
.file-chip.k-pdf   { background: #e5534b; }
.file-chip.k-word  { background: #2f73c9; }
.file-chip.k-excel { background: #1f9d5a; }
.file-chip.k-ppt   { background: #e07a2f; }
.file-chip.k-img   { background: #7a5bd6; }
.file-chip.k-zip   { background: #7d8792; }
.file-chip.k-other { background: #9aa3ad; }
a.file-chip:hover { filter: brightness(1.08); }
.file-chip.is-dead { opacity: .42; cursor: default; box-shadow: none; }
.file-none { color: var(--gray-400); }
/* 上传控件里：格式块 + 文件名（表单编辑时需要分辨文件） */
.up-item .up-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up-item a.file-chip { flex: none; }
/* 格式块强制白字：表格里 `td a` 的蓝色链接色会盖掉 .file-chip 的 color，这里按 a 选择器补回来 */
a.file-chip, a.file-chip:visited, a.file-chip:hover,
table.grid td a.file-chip, .up-item a.file-chip,
.file-chip, .file-chip.is-dead { color: #fff !important; text-decoration: none !important; }

/* ===== 流程设计器（系统设置 → 流程设置） =====
   竖向画布：发起 → 节点 → 结束；分支节点横向展开多条分支列。
   配色沿用全站蓝白，节点用左侧 3px 色条区分类型，避免大面积色块。 */
.fd-page { display: flex; flex-direction: column; gap: 12px; height: calc(100vh - 118px); min-height: 520px; }
.fd-top {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 10px 14px; background: #fff;
  border: 1px solid var(--gray-200); border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.fd-tabs { display: flex; gap: 4px; background: var(--gray-50); padding: 3px; border-radius: 6px; }
.fd-tab {
  border: none; background: transparent; padding: 5px 11px; border-radius: 4px;
  font-size: 12.5px; color: var(--gray-600); cursor: pointer; font-family: inherit;
}
.fd-tab:hover { color: var(--primary); }
.fd-tab.on { background: #fff; color: var(--primary); font-weight: 500; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.fd-hint { font-size: 12px; color: var(--gray-400); }
.fd-top-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.fd-form-name { font-size: 13px; font-weight: 600; color: var(--gray-800); }
.fd-main { flex: 1; display: flex; gap: 12px; min-height: 0; }
.fd-canvas-wrap {
  flex: 1; min-width: 0; overflow: auto;
  background: #f7f8fa; border: 1px solid var(--gray-200); border-radius: var(--radius);
}
.fd-canvas { display: flex; flex-direction: column; align-items: center; padding: 22px 20px 40px; min-height: 100%; }

/* 发起 / 结束 */
.fd-start, .fd-end {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 15px; border-radius: 16px; font-size: 12.5px;
  background: #fff; border: 1px solid var(--gray-200); color: var(--gray-600);
}
.fd-end { color: var(--gray-500); }
.fd-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); }
.fd-end .fd-dot { background: var(--gray-300); }

/* 节点列表 */
.fd-list { display: flex; flex-direction: column; align-items: center; width: 100%; }
.fd-item { width: 100%; display: flex; flex-direction: column; align-items: center; }
.fd-sep { position: relative; display: flex; flex-direction: column; align-items: center; }
.fd-sep i { display: block; width: 1px; height: 34px; background: var(--gray-300); }
/* 插入按钮常显（原默认半透明，用户找不到），hover 变实心蓝 */
.fd-plus {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 22px; height: 22px; line-height: 1; border-radius: 50%;
  border: 1px solid var(--gray-300); background: #fff; color: var(--gray-500);
  font-size: 14px; cursor: pointer; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 1px 2px rgba(0,0,0,.05);
  transition: opacity .12s, color .12s, border-color .12s, background .12s;
  opacity: 1;
}
.fd-sep:hover .fd-plus { color: var(--primary); border-color: var(--primary); }
.fd-plus:hover { background: var(--primary); color: #fff !important; border-color: var(--primary) !important; }

/* 节点卡片 */
.fd-node {
  position: relative; width: 330px; max-width: 100%; display: flex; align-items: center; gap: 9px;
  padding: 9px 12px 9px 13px; background: #fff; cursor: pointer;
  border: 1px solid var(--gray-200); border-radius: 6px; box-shadow: var(--shadow-sm);
  transition: border-color .12s, box-shadow .12s;
}
.fd-node::before {
  content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px;
  border-radius: 2px; background: var(--primary); opacity: .55;
}
.fd-node.fd-t-cc::before { background: var(--gray-400); }
.fd-node.fd-t-branch::before { background: var(--warning); }
.fd-node:hover { border-color: var(--primary-line); box-shadow: var(--shadow); }
.fd-node.on { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(22,119,255,.12); }
.fd-node.dragging { opacity: .45; }
.fd-node-ico { flex: none; width: 26px; height: 26px; border-radius: 5px; display: flex;
  align-items: center; justify-content: center; background: var(--primary-light); color: var(--primary); }
.fd-t-cc .fd-node-ico { background: var(--gray-100); color: var(--gray-500); }
.fd-t-branch .fd-node-ico { background: #fef3c7; color: #b45309; }
.fd-node-main { flex: 1; min-width: 0; }
.fd-node-name { font-size: 13px; font-weight: 500; color: var(--gray-900);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-node-sub { font-size: 11.5px; color: var(--gray-500); margin-top: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-node-tag { flex: none; font-size: 11px; color: var(--gray-400);
  border: 1px solid var(--gray-200); border-radius: 3px; padding: 0 5px; line-height: 16px; }

/* 拖拽落点提示 */
.fd-item.drop-after { position: relative; }
.fd-item.drop-after::after {
  content: ""; position: absolute; left: 50%; transform: translateX(-50%);
  bottom: -1px; width: min(330px, 100%); height: 2px; background: var(--primary); border-radius: 2px;
}

/* 分支容器 */
.fd-branch { width: 100%; display: flex; flex-direction: column; align-items: center; margin-top: 8px; }
.fd-branch-cols { display: flex; gap: 10px; align-items: flex-start; justify-content: center;
  flex-wrap: nowrap; width: 100%; overflow-x: auto; padding: 2px; }
.fd-branch-col {
  flex: 1 1 0; min-width: 232px; background: #fff; border: 1px solid var(--gray-200);
  border-radius: 6px; padding: 8px 8px 4px;
}
/* 分支列内的节点撑满列宽，不再固定 330px */
.fd-branch-col .fd-node { width: 100%; }
.fd-branch-head { display: flex; align-items: baseline; gap: 6px; padding: 2px 4px 8px;
  border-bottom: 1px dashed var(--gray-200); margin-bottom: 2px; cursor: pointer; }
.fd-branch-name { font-size: 12px; font-weight: 500; color: var(--gray-700); flex: none;
  max-width: 46%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-branch-cond { font-size: 11px; color: var(--gray-400); flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-branch-add {
  margin-top: 8px; border: 1px dashed var(--gray-300); background: #fff; color: var(--gray-500);
  border-radius: 6px; padding: 5px 14px; font-size: 12px; cursor: pointer; font-family: inherit;
}
.fd-branch-add:hover { color: var(--primary); border-color: var(--primary); }

/* 插入菜单 */
.fd-menu {
  position: absolute; z-index: 3000; min-width: 132px; padding: 4px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 6px; box-shadow: var(--shadow-lg);
}
.fd-menu button {
  display: flex; align-items: center; gap: 8px; width: 100%;
  border: none; background: transparent; padding: 7px 10px; border-radius: 4px;
  font-size: 12.5px; color: var(--gray-700); cursor: pointer; font-family: inherit; text-align: left;
}
.fd-menu button:hover { background: var(--primary-light); color: var(--primary); }
.fd-menu-ico { display: inline-flex; color: var(--gray-500); }
.fd-menu button:hover .fd-menu-ico { color: var(--primary); }

/* 右侧属性面板 */
.fd-panel {
  flex: none; width: 344px; overflow-y: auto; padding: 14px 16px 24px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.fd-panel-empty { color: var(--gray-500); font-size: 12.5px; line-height: 1.9; }
.fd-panel-empty .fd-panel-title { font-size: 13px; font-weight: 600; color: var(--gray-800); margin-bottom: 8px; }
.fd-panel-empty ul { margin: 10px 0 0 16px; padding: 0; }
.fd-panel-empty li { margin-bottom: 4px; color: var(--gray-400); }
.fd-panel-head { display: flex; align-items: flex-start; gap: 9px; padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-100); margin-bottom: 12px; }
.fd-panel-ico { flex: none; width: 28px; height: 28px; border-radius: 5px; display: flex;
  align-items: center; justify-content: center; background: var(--primary-light); color: var(--primary); }
.fd-panel-ico.fd-t-cc { background: var(--gray-100); color: var(--gray-500); }
.fd-panel-ico.fd-t-branch { background: #fef3c7; color: #b45309; }
.fd-panel-hd { flex: 1; min-width: 0; }
.fd-panel-title { font-size: 13px; font-weight: 600; color: var(--gray-800); }
.fd-panel-sub { font-size: 11.5px; color: var(--gray-400); margin-top: 3px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-field { margin-bottom: 13px; }
.fd-field > label { display: block; font-size: 12px; color: var(--gray-600); margin-bottom: 5px; }
.fd-input {
  width: 100%; padding: 6px 9px; font-size: 12.5px; font-family: inherit; color: var(--gray-800);
  border: 1px solid var(--gray-200); border-radius: 4px; background: #fff; outline: none;
}
.fd-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(22,119,255,.1); }
.fd-input-sm { padding: 4px 7px; font-size: 12px; }
.fd-w80 { width: 80px; flex: none; }
.fd-static { font-size: 12.5px; color: var(--gray-500); padding: 5px 0; }
.fd-static-sm { padding: 2px 0; }
.fd-note { font-size: 11.5px; color: var(--gray-400); line-height: 1.6; margin-top: 4px; }
.fd-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px;
  color: var(--gray-600); cursor: pointer; }
.fd-check input { accent-color: var(--primary); }
.fd-block { width: 100%; margin-top: 4px; }
.fd-chips { display: flex; flex-wrap: wrap; gap: 5px; align-items: center;
  border: 1px solid var(--gray-200); border-radius: 4px; padding: 5px 7px; min-height: 32px; }
.fd-chip { display: inline-flex; align-items: center; gap: 4px; background: var(--primary-light);
  color: var(--primary); border-radius: 3px; padding: 1px 6px; font-size: 12px; }
.fd-chip i { font-style: normal; cursor: pointer; opacity: .65; }
.fd-chip i:hover { opacity: 1; }
.fd-chip-input { border: none; outline: none; font-size: 12.5px; flex: 1; min-width: 100px;
  background: transparent; font-family: inherit; }
.fd-perms { display: flex; flex-wrap: wrap; gap: 4px 12px; max-height: 150px; overflow-y: auto;
  padding: 6px 8px; border: 1px solid var(--gray-200); border-radius: 4px; }
.fd-perm { display: inline-flex; align-items: center; gap: 5px; font-size: 12px;
  color: var(--gray-600); cursor: pointer; }
.fd-perm input { accent-color: var(--primary); }

/* 分支条件编辑 */
.fd-branch-edit { border: 1px solid var(--gray-200); border-radius: 5px; padding: 9px 10px; margin-bottom: 9px; }
.fd-be-head { display: flex; align-items: center; gap: 7px; margin-bottom: 7px; }
.fd-be-no { flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--primary-light);
  color: var(--primary); font-size: 11px; display: flex; align-items: center; justify-content: center; }
.fd-be-op { display: flex; align-items: center; gap: 7px; margin-bottom: 6px; }
.fd-be-op .fd-input { width: 108px; }
.fd-be-op .fd-note { margin-top: 0; }
.fd-rule { display: flex; align-items: center; gap: 5px; margin-bottom: 5px; }
.fd-rule .fd-input { min-width: 0; }
.fd-rule [data-rfield] { flex: 1.3; }
.fd-rule [data-rcmp] { flex: none; }
.fd-rule [data-rval] { flex: 1; }
/* 不截断的单元格（如框架协议名称）：一行放不下就换行，绝不省略号 */
table.grid td .cell-keep { display: inline-block; white-space: nowrap; line-height: 1.45; }
/* 同值合并单元格：竖排居中，与相邻行共用一条分隔线 */
table.grid td.merged { vertical-align: middle; }
/* 允许换行的单元格（如框架协议名称 550px 放不下长名称时折行，不省略） */
table.grid td .cell-wrap { display: inline-block; white-space: normal; line-height: 1.5; word-break: break-word; }
/* 固定列宽模式：完全按列定义里的 px 分配，不再让浏览器按内容比例压缩；
   总宽超出容器时由 .table-wrap 横向滚动承接。 */
table.grid.fixed-width { table-layout: fixed; width: auto; }

/* 列表表格贴合容器（ListPage 统一使用）：列宽由 JS 折算成百分比 + table-layout:fixed，
   整表严格等于容器宽度，任何视口下都不出现横向滚动条；
   窄屏时各列按比例收窄，长文本在单元格内省略（悬停 title 看全文），表头允许折行不截断。 */
table.grid.lp-fit { table-layout: fixed; width: 100%; }
table.grid.lp-fit th,
table.grid.lp-fit td {
  padding-left: 8px; padding-right: 8px;
  overflow: hidden; text-overflow: ellipsis;
}
table.grid.lp-fit th { white-space: normal; line-height: 1.35; vertical-align: middle; }
/* 表头括号里的单位（如「（万元）」）作为一个整体换行，不出现「（万 / 元）」断字 */
table.grid.lp-fit th .th-unit { white-space: nowrap; }
table.grid.lp-fit .cell-ellipsis { max-width: 100% !important; }
/* 管理员拖拽列宽：表头右缘 7px 热区（平时不可见，悬停显示蓝色竖条） */
table.grid.lp-fit th .col-rs {
  position: absolute; top: 0; right: 0; width: 8px; height: 100%;
  cursor: col-resize; z-index: 3; touch-action: none;
}
table.grid.lp-fit th .col-rs:hover { background: rgba(22,119,255,.16); }
/* 拖拽中：整页显示对应光标并禁用选中，避免拖到表格外就失灵或选中文字 */
body.col-dragging { cursor: col-resize; user-select: none; }
body.col-dragging * { cursor: col-resize !important; }
body.row-dragging { cursor: ns-resize; user-select: none; }
body.row-dragging * { cursor: ns-resize !important; }
/* 管理员：整块列表/面板的宽高拖拽（右缘=宽度，下缘=高度；右下角抓手=同时改宽高；双击恢复自动） */
.ui-rs { position: relative; }
.ui-rs > .ui-rs-bar { position: absolute; z-index: 6; touch-action: none; }
.ui-rs > .ui-rs-e { top: 0; right: 0; width: 8px; height: 100%; cursor: ew-resize; }
.ui-rs > .ui-rs-s { left: 0; bottom: 0; height: 8px; width: 100%; cursor: ns-resize; }
.ui-rs > .ui-rs-bar:hover { background: rgba(22,119,255,.18); }
/* 抓手：浮在容器右下角（fixed，不会被 overflow 裁剪），拖动改宽高 */
.ui-rs-grip {
  position: fixed; width: 16px; height: 16px; z-index: 60;
  border-radius: 3px; cursor: nwse-resize; touch-action: none;
  background-color: rgba(255,255,255,.92);
  border: 1px solid rgba(22,119,255,.35);
  box-shadow: 0 1px 4px rgba(18,49,76,.18);
  background-image:
    linear-gradient(135deg, transparent 42%, rgba(22,119,255,.65) 42%, rgba(22,119,255,.65) 50%, transparent 50%),
    linear-gradient(135deg, transparent 64%, rgba(22,119,255,.65) 64%, rgba(22,119,255,.65) 72%, transparent 72%);
}
.ui-rs-grip:hover { background-color: #fff; border-color: rgba(22,119,255,.75); box-shadow: 0 2px 8px rgba(18,49,76,.28); }
/* 标签列（区域、交易平台等）：窄屏时按格宽省略，不硬裁掉半个字 */
table.grid.lp-fit td .tag { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 附件图标列：一个格子放不下多个图标时换行，不横向溢出 */
table.grid.lp-fit td .file-chips { flex-wrap: wrap; max-width: 100%; }
/* 多值小标签（如多个交易平台）：可换行、单个超宽时省略 */
table.grid.lp-fit td .chip-mini {
  display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; vertical-align: bottom;
}
/* 允许折行的列（如日期时间从空格处断成两行），只在放不下时才折 */
table.grid.lp-fit td.wrap { white-space: normal; word-break: keep-all; }

/* ───────── 系统设置 · 自动化规则 ───────── */
.auto-page { display: flex; flex-direction: column; gap: 14px; }
.auto-card { padding: 0; }
.auto-card .card-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--gray-200);
}
.auto-card .card-title { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 500; color: var(--gray-900); }
.auto-card .card-title svg { width: 16px; height: 16px; color: var(--primary); }
.auto-stats { display: flex; align-items: center; gap: 16px; }
.auto-stat { font-size: 12px; color: var(--gray-500); }
.auto-stat b { font-size: 14px; color: var(--gray-900); font-variant-numeric: tabular-nums; margin-left: 2px; }
.auto-stat.ok b { color: var(--success); }
.auto-stat.err b { color: var(--danger); }
.auto-hint {
  padding: 8px 16px; font-size: 12px; color: var(--gray-500);
  background: var(--primary-soft); border-bottom: 1px solid var(--gray-200); line-height: 1.7;
}
.auto-hint code { background: #fff; border: 1px solid var(--gray-200); border-radius: 3px; padding: 1px 4px; font-size: 11px; }
.auto-table-wrap { padding: 0 4px 4px; }
.auto-table { text-align: center; }
.auto-table th { text-align: center; }
.auto-table td { text-align: center; vertical-align: middle; padding: 10px 8px; }
.auto-table tr.is-off { background: var(--gray-50); }
.auto-table tr.is-off .auto-name b { color: var(--gray-400); }
.auto-name { text-align: left !important; }
.auto-name b { font-weight: 500; color: var(--gray-900); }
.auto-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 6px; background: var(--gray-300); }
.auto-dot.on { background: var(--success); }
.auto-tag {
  margin-left: 6px; font-size: 11px; color: var(--primary); background: var(--primary-light);
  border-radius: 3px; padding: 1px 5px;
}
.auto-sub { font-size: 12px; color: var(--gray-500); margin-top: 2px; }
.auto-sub-inline { font-size: 11px; color: var(--gray-500); margin-left: 4px; }
.auto-time { font-size: 12px; color: var(--gray-500); font-variant-numeric: tabular-nums; }
.auto-msg { text-align: left !important; font-size: 12px; color: var(--gray-600); }
.auto-ops { white-space: nowrap; }
.auto-link { color: var(--primary); font-size: 12px; margin-left: 10px; }
.auto-link:hover { text-decoration: underline; }
.auto-table .ok { color: var(--success); }
.auto-table .err { color: var(--danger); }
.auto-table .muted { color: var(--gray-400); }
.auto-switch {
  position: relative; width: 34px; height: 18px; border-radius: 9px; border: none;
  background: var(--gray-300); cursor: pointer; padding: 0; vertical-align: middle;
  transition: background .16s;
}
.auto-switch i {
  position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .16s;
}
.auto-switch.on { background: var(--success); }
.auto-switch.on i { transform: translateX(16px); }
.auto-switch:disabled { opacity: .6; cursor: default; }
.auto-log-filter { display: flex; align-items: center; gap: 8px; }
.auto-log-filter select {
  height: 28px; border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: 0 8px; font-size: 12px; color: var(--gray-700); background: #fff;
}
/* 仪表盘表格里允许换行的单元格（框架协议名称）：固定列宽 + 自动折行，不省略 */
.sx-table td .nb-wrap { display: block; white-space: normal; line-height: 1.45; word-break: break-word; text-align: left; }

/* 面板顶部：在选中节点之后插入 · 条件分支给主色描边，因为最容易被漏掉 */
.fd-ins {
  display: flex; gap: 6px; margin: 0 0 14px; padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-100);
}
.fd-ins button {
  flex: 1; padding: 6px 0; font-size: 12px; font-family: inherit;
  border: 1px solid var(--gray-200); background: #fff; border-radius: 4px;
  color: var(--gray-700); cursor: pointer; white-space: nowrap;
}
.fd-ins button:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.fd-ins button[data-ins="branch"] {
  color: var(--primary); border-color: var(--primary-line); background: var(--primary-soft);
}
.fd-ins button[data-ins="branch"]:hover { background: var(--primary-light); }
/* 列表内容统一居中：压掉各页遗留的 text-align:left（含 JS 内联样式） */
table.grid th, table.grid td { text-align: center !important; }
table.grid td .cell-wrap,
table.grid td .cell-ellipsis,
.sx-table td .nb-wrap { text-align: center; }

/* ===================== 首页（默认落地页） ===================== */
/* 布局：2×2 四宫格 —— 左上流程管理 / 右上时间+本月指标 / 左下招标工作日历 / 右下招投标信息+常用网站 */
.nav-solo { padding: 4px 0 2px; }
.nav-solo .nav-item { padding-top: 8px; padding-bottom: 8px; }

/* 首页整页铺满内容区（与「招投标室信息」页一致）：四张卡片吃掉剩余高度，底边与页面底边对齐 */
.hm-page { display: flex; flex-direction: column; gap: 10px; height: 100%; min-height: 0; }
.hm-quad {
  flex: 1 1 auto; min-height: 0;
  display: grid;
  grid-template-columns: 2fr 1fr;  /* 左 2/3、右 1/3 */
  grid-template-rows: auto minmax(0, 1fr);  /* 第一行按内容，第二行吸收剩余高度（日历格随之变高） */
  gap: 10px;
  align-items: stretch;
}
.hm-quad > * { min-width: 0; }
.hm-card {
  background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); min-width: 0;
}
/* 左上角：流程管理 —— 标题右侧四个分类标签，标签下面直接列该分类的流程 */
.hm-flows { display: flex; flex-direction: column; }
.hm-flows-h { gap: 10px; }
.hm-flows-more {
  flex: none; display: inline-flex; align-items: center; gap: 1px;
  font-size: 12px; color: var(--gray-500);
}
.hm-flows-more:hover { color: var(--primary); }
.hm-flow-tabs { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.hm-flow-tabs a {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 0; font-size: 12.5px; color: var(--gray-600);
  border-bottom: 2px solid transparent; transition: color .15s, border-color .15s;
}
.hm-flow-tabs a:hover { color: var(--primary); }
.hm-flow-tabs a.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.hm-flow-tabs i {
  font-style: normal; font-size: 10.5px; color: #fff; background: #e8453c;
  min-width: 15px; height: 15px; padding: 0 4px; border-radius: 8px;
  line-height: 15px; text-align: center; font-variant-numeric: tabular-nums;
}
.hm-flow-body {
  flex: 1 1 auto; min-height: 0; max-height: 190px; overflow-y: auto;
  padding: 0 10px 10px; scrollbar-gutter: stable;
}
.hm-fi {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 10px; border-radius: var(--radius);
}
.hm-fi + .hm-fi { box-shadow: inset 0 1px 0 var(--gray-50); }
.hm-fi:hover { background: var(--primary-soft); }
/* 四段：流程类型（定宽）| 流程名称（自适应截断）| 时间（右对齐）| 状态（定宽胶囊） */
.hm-fi-ty {
  flex: 0 0 100px; min-width: 0;
  font-size: 12.5px; color: var(--primary);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hm-fi-ti {
  flex: 1 1 auto; min-width: 0;
  font-size: 13px; color: #26292e;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hm-fi-dt {
  flex: 0 0 76px; text-align: right;
  font-size: 11.5px; color: var(--gray-400); font-variant-numeric: tabular-nums;
}
.hm-fi-st {
  flex: 0 0 52px; height: 19px; line-height: 19px; border-radius: 10px;
  font-size: 11px; text-align: center;
}
.hm-fi-st.wait { background: #fff4e5; color: #b76b00; }
.hm-fi-st.done { background: #e8f6ee; color: #1b7a44; }
.hm-fi-st.back { background: #fdecec; color: #c33; }
.hm-flow-empty { padding: 34px 10px; text-align: center; font-size: 12.5px; color: var(--gray-400); }

.hm-hero { padding: 12px; display: grid; grid-template-rows: repeat(4, minmax(0, 1fr)); gap: 8px; }   /* 时钟 1 行 + 指标 3 行，四行等分、行距一致 */
.hm-clock { align-self: center; display: flex; align-items: baseline; justify-content: center; gap: 8px; flex-wrap: wrap; text-align: center; }
.hm-clock b {
  font-size: 28px; font-weight: 700; color: #1f2329; letter-spacing: .5px;
  font-variant-numeric: tabular-nums; line-height: 1.15;
}
.hm-clock span { font-size: 15px; color: #26292e; }

/* 四个指标 2×2：每格独立白卡（细边框 + 圆角），标题在上、数值在下；
   指标区横跨时钟行下面的两行，两个行各占 1/3，使「时钟行 / 指标行1 / 指标行2」三等分 */
.hm-kpis {
  grid-row: span 3; min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.hm-kpi {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  padding: 6px; text-align: center; min-width: 0;
  border: 1px solid var(--gray-200); border-radius: var(--radius); background: #fff;
}
.hm-kpi .t { font-size: 13px; color: var(--gray-600); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.hm-kpi .v { font-size: 26px; font-weight: 700; color: #1f2329; line-height: 1.1; font-variant-numeric: tabular-nums; }
.hm-kpi .v small { font-size: 13px; font-weight: 600; margin-left: 2px; color: var(--gray-600); }

.hm-side2 { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.hm-side2 > .hm-card { flex: 1 1 0; display: flex; flex-direction: column; min-height: 0; }
.hm-card-h {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px 6px; font-size: 13px; font-weight: 600; color: #1f2329;
}
.hm-links {
  display: grid; gap: 0 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));   /* 右列只占 1/3，两列刚好 */
  padding: 0 8px 9px; flex: 1 1 auto; align-content: space-evenly;
}
.hm-link {
  display: flex; align-items: center; gap: 8px; min-width: 0;
  padding: 5px 4px; border-radius: var(--radius); color: #26292e; font-size: 13.5px;
}
.hm-link span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hm-link:hover { background: var(--primary-soft); color: var(--primary); }
.hm-ico {
  flex: none; width: 22px; height: 22px; border-radius: 4px;
  background: var(--c, var(--primary)); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
}
.hm-none { padding: 6px 6px 14px; font-size: 12.5px; color: var(--gray-400); }

.hm-win { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; }
.hm-win button {
  min-width: 26px; height: 24px; padding: 0 7px; font-size: 12px; font-family: inherit;
  border: 1px solid var(--gray-200); background: #fff; border-radius: var(--radius);
  color: var(--gray-700); cursor: pointer;
}
.hm-win button:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }

/* 招标工作日历：左侧月历（节点用色点标注），右侧当日明细 */
.hm-cal-card { display: flex; flex-direction: column; }
/* 左列（标题+翻月按钮+月历+图例）整体成列，翻月按钮就贴在这个列的正上方 */
.hm-cal-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); flex: 1 1 auto; min-height: 0; }
.hm-cal-side {
  padding: 0 12px 12px; border-right: 1px solid var(--gray-200);
  display: flex; flex-direction: column; min-width: 0; min-height: 0;
}
.hm-cal-head { display: flex; align-items: center; gap: 8px; padding: 8px 2px 5px; }
.hm-cal-head .ttl { font-size: 13px; font-weight: 600; color: #1f2329; }
.hm-cal-title { font-size: 12.5px; color: var(--gray-500); }
.hm-cal-head .hm-win { margin-left: auto; }
.hm-cal-weeks { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
/* 月历吃掉卡片剩余高度：6 行等分，格子随屏幕变高（矮屏由 .hm-cal-d 的 min-height 兜底） */
.hm-cal-grid {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px;
  flex: 1 1 auto; min-height: 0; grid-auto-rows: minmax(0, 1fr);
  /* 上限 384px（6 行约 61px）：大屏下不让日期格无限长高，多出的高度留在卡片内 */
  max-height: 384px;
}
.hm-cal-weeks span { text-align: center; font-size: 12px; color: var(--gray-500); padding: 2px 0 4px; }
.hm-cal-weeks span:nth-child(6), .hm-cal-weeks span:nth-child(7) { color: var(--gray-400); }
.hm-cal-d {
  position: relative; min-height: 30px; border: 1px solid transparent; border-radius: var(--radius);
  padding: 4px 5px 3px; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  transition: background .12s, border-color .12s;
}
.hm-cal-d:hover { background: var(--primary-soft); }
.hm-cal-d.out { color: var(--gray-300); }
.hm-cal-d.out .hm-cal-dot { opacity: .45; }
.hm-cal-d.today { border-color: var(--primary-line); }
.hm-cal-d.sel { background: var(--primary-light); border-color: var(--primary); }
.hm-cal-d.sel .hm-cal-n { color: #0d5fd6; font-weight: 700; }
.hm-cal-n { font-size: 12.5px; line-height: 1.1; font-variant-numeric: tabular-nums; text-align: center; }
.hm-cal-d.today .hm-cal-n { color: var(--primary); font-weight: 600; }
.hm-cal-dots { display: flex; align-items: center; justify-content: center; gap: 2px; flex-wrap: wrap; min-height: 5px; }
.hm-cal-dot { width: 5px; height: 5px; border-radius: 50%; display: inline-block; }
.hm-cal-more { font-size: 9.5px; color: var(--gray-400); line-height: 1; }
.hm-cal-cnt {
  position: absolute; top: 4px; right: 5px; font-size: 10px; color: var(--gray-400);
  font-variant-numeric: tabular-nums;
}
.hm-cal-loading { grid-column: 1 / -1; padding: 30px 0; text-align: center; font-size: 12.5px; color: var(--gray-400); }
.hm-cal-legend {
  display: flex; flex-wrap: wrap; gap: 4px 12px; justify-content: center; margin-top: 7px; padding-top: 7px;
  border-top: 1px dashed var(--gray-200); font-size: 11.5px; color: var(--gray-500);
}
.hm-cal-legend span { display: inline-flex; align-items: center; gap: 5px; }
.hm-cal-legend i { width: 6px; height: 6px; border-radius: 50%; display: inline-block; }

.hm-day { padding: 10px 14px 14px; display: flex; flex-direction: column; min-width: 0; }
.hm-day-h { display: flex; align-items: baseline; gap: 10px; padding: 2px 2px 9px; }
.hm-day-h b { font-size: 14px; font-weight: 600; color: #1f2329; }
.hm-day-c { font-size: 12.5px; color: var(--gray-500); }
.hm-day-empty { padding: 26px 6px; font-size: 12.5px; color: var(--gray-400); line-height: 1.8; }
.hm-day-list { display: flex; flex-direction: column; gap: 6px; max-height: 320px; overflow-y: auto; scrollbar-gutter: stable; }
.hm-ev {
  display: flex; align-items: flex-start; gap: 9px; padding: 8px 10px;
  border: 1px solid var(--gray-100); border-radius: var(--radius); min-width: 0;
}
.hm-ev:hover { background: var(--primary-soft); border-color: var(--primary-line); }
.hm-ev.done { opacity: .62; }
.hm-ev-time {
  flex: 0 0 42px; font-size: 12px; color: var(--gray-500); line-height: 1.6;
  font-variant-numeric: tabular-nums;
}
.hm-ev-tag {
  flex: none; height: 18px; line-height: 18px; padding: 0 7px; border-radius: 9px;
  font-size: 11.5px; color: #fff; white-space: nowrap;
}
.hm-ev-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 auto; }
.hm-ev-name {
  font-size: 13px; color: #26292e; line-height: 1.45; word-break: break-word;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.hm-ev-sub {
  font-size: 11.5px; color: var(--gray-400); line-height: 1.45; word-break: break-word;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 矮屏（1366×768、1280×720 等笔记本）：按视口高度压缩日历与指标，保证首页一屏放下、不出滚动条。
   必须放在 .hm-cal-d / .hm-kpi 基础规则之后，否则同优先级会被覆盖。 */
@media (max-height: 800px) {
  .hm-cal-d { min-height: 34px; }
  .hm-cal-legend { margin-top: 5px; padding-top: 5px; }
  .hm-kpi .v { font-size: 22px; }
  .hm-hero { padding: 10px; gap: 6px; }
}
@media (max-height: 740px) {
  .hm-cal-d { min-height: 30px; }
  .hm-cal-legend { display: none; }
  .hm-kpi .v { font-size: 20px; }
  .hm-flow-body { max-height: 160px; }
}

@media (max-width: 1100px) {
  .hm-cal-wrap { grid-template-columns: minmax(0, 1fr); }
  .hm-cal-side { border-right: none; border-bottom: 1px solid var(--gray-200); }
}

@media (max-width: 1100px) {
  .hm-quad { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; }
  .hm-side2 > .hm-card { flex: 0 0 auto; }
  .hm-flow-list a { min-height: 40px; }
  .hm-info .hm-links, .hm-sites .hm-links { align-content: start; }
}

/* ===================== 流程管理（我的待办 / 我发起的 / 我处理的 / 抄送我的） ===================== */
.wf-page { display: flex; flex-direction: column; gap: 10px; min-height: 0; }
.wf-page > .table-wrap { flex: 1 1 auto; min-height: 0; overflow: auto; }
.wf-page > .pager { flex: none; }
.wf-page .toolbar { margin-bottom: 0; }
/* 页头：左侧标题（+浅灰副标题），右侧文字链式分类导航 */
.wf-head { display: flex; align-items: center; gap: 8px; padding: 0 2px; }
.wf-h3 { font-size: 15px; font-weight: 600; color: #1f2329; }
/* 标签页：四个分类用下划线式 tab，下面直接是流程列表 */
.wf-bar { display: flex; align-items: flex-end; gap: 16px; border-bottom: 1px solid var(--gray-200); }
.wf-tabs { display: flex; gap: 24px; }
.wf-tab {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 8px 2px 9px; margin-bottom: -1px;
  font-size: 13.5px; color: var(--gray-600);
  border-bottom: 2px solid transparent; transition: color .15s, border-color .15s;
}
.wf-tab:hover { color: var(--primary); }
.wf-tab.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.wf-tools { margin-left: auto; display: flex; align-items: center; gap: 12px; padding-bottom: 6px; }
.wf-tools .search-box input { width: 200px; padding: 6px 10px 6px 30px; font-size: 12.5px; }
.wf-badge {
  min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
  background: #e8453c; color: #fff; font-size: 10.5px; font-style: normal;
  line-height: 16px; text-align: center; font-variant-numeric: tabular-nums;
}
.wf-tab.on .wf-badge { background: #dc2626; }
/* 空态插画 */
.wf-empty-cell { padding: 0 !important; }
.wf-empty { padding: 34px 0 30px; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.wf-empty-t { font-size: 13px; color: var(--gray-400); margin-top: 4px; }
.wf-empty-s { font-size: 12px; color: var(--gray-300); }
.wf-tip { font-size: 12.5px; color: var(--gray-500); white-space: nowrap; }
.wf-table tbody tr { cursor: pointer; }
.wf-table tbody tr:hover { background: var(--primary-soft); }
/* 标题列左对齐（全局 table.grid 是居中，这里按内容形态破例两行显示） */
.wf-table .wf-title-cell { text-align: left !important; padding-left: 12px; }
/* 未读待办：标题前的「新」标；已等待时长超 24 小时转红 */
.wf-new {
  display: inline-block; margin-right: 5px; padding: 0 4px; height: 15px; line-height: 15px;
  border-radius: 3px; background: #fdecec; color: #d93025;
  font-size: 10.5px; font-style: normal; font-weight: 500; vertical-align: 1px;
}
.wf-wait { color: var(--gray-500); font-variant-numeric: tabular-nums; }
.wf-wait-late { color: #d93025; font-weight: 500; font-variant-numeric: tabular-nums; }
.wf-title {
  font-size: 13px; color: #26292e; line-height: 1.45;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.wf-sub {
  font-size: 11.5px; color: var(--gray-400); line-height: 1.4; margin-top: 1px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
