/* ============================================================
   监云 · 监理资料云平台
   视觉体系：深海军蓝 + 工程蓝 + 白色卡片
   ============================================================ */
:root {
  --primary: #1D5FD1;
  --primary-2: #2E74F0;
  --primary-3: #5FA8FF;
  --navy: #0A1B31;
  --navy-2: #0E2440;
  --navy-3: #12345C;
  --bg: #F4F6FA;
  --card: #FFFFFF;
  --ink: #0F1B2D;
  --ink-2: #34445C;
  --ink-3: #6B7A90;
  --ink-4: #98A6B8;
  --line: #E5EAF1;
  --line-2: #EFF3F8;
  --green: #0E9F6E;
  --green-bg: #E9F8F1;
  --amber: #C77A08;
  --amber-bg: #FFF5E4;
  --red: #D63F3F;
  --red-bg: #FDEDED;
  --violet: #6D5BD0;
  --violet-bg: #F0EDFC;
  --cyan: #0E8FA8;
  --cyan-bg: #E6F7FA;
  --radius: 16px;
  --shadow: 0 10px 30px -24px rgba(15, 35, 65, .28);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --num: "Bahnschrift", "DIN Alternate", "SF Pro Display", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  font-size: 13px;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 13px; color: var(--ink); }
img, svg { display: block; }
h1, h2, h3, h4, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
code { font-family: var(--num); background: var(--line-2); padding: 1px 5px; border-radius: 4px; }
.mono { font-family: var(--num); letter-spacing: .2px; }
.muted { color: var(--ink-4); }
.ta-r { text-align: right; }
.full { width: 100%; }
.hint { font-size: 11px; color: var(--ink-4); }

/* ---------- 图标 ---------- */
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ic {
  width: 18px; height: 18px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- 应用骨架 ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  position: fixed; z-index: 60; left: 0; top: 0; bottom: 0;
  width: 232px; display: flex; flex-direction: column;
  background: linear-gradient(180deg, #0A1B31 0%, #0B1F39 55%, #0C2442 100%);
  color: #D7E3F4; overflow-y: auto;
}
.sidebar::-webkit-scrollbar { width: 0; }
.sidebar-overlay { display: none; }
.main {
  width: calc(100% - 232px); margin-left: 232px;
  min-height: 100vh; display: flex; flex-direction: column;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 20px 18px 16px; }
.brand-logo {
  width: 40px; height: 40px; border-radius: 12px; flex: none;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(145deg, #2E74F0, #1D5FD1);
  box-shadow: 0 8px 18px -8px rgba(46,116,240,.9);
}
.brand-logo svg { width: 25px; height: 25px; }
.brand-logo.lg { width: 46px; height: 46px; border-radius: 14px; }
.brand-logo.lg svg { width: 29px; height: 29px; }
.brand-txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.brand-txt strong { color: #fff; font-size: 17px; font-weight: 700; letter-spacing: .3px; }
.brand-txt span { font-size: 10px; color: #7F98B8; letter-spacing: 1.6px; }

.project-box { padding: 4px 12px 12px; }
.project-switch-form {
  position: relative; display: flex; align-items: center; gap: 9px;
  padding: 9px 10px; border-radius: 11px;
  background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.08);
}
.ps-ic {
  width: 30px; height: 30px; border-radius: 8px; flex: none;
  display: grid; place-items: center; background: rgba(46,116,240,.2); color: #8AB8FF;
}
.ps-ic .ic { width: 16px; height: 16px; }
.ps-main { flex: 1; min-width: 0; }
.ps-main select {
  width: 100%; border: 0; outline: 0; background: transparent;
  color: #F2F7FF; font-size: 11.5px; font-weight: 600;
  appearance: none; padding: 0 12px 0 0; cursor: pointer;
  white-space: nowrap; text-overflow: ellipsis;
}
.ps-main select option { color: var(--ink); background: #fff; }
.ps-main span { display: block; font-size: 9.5px; color: #7F98B8; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ps-arrow { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 13px; height: 13px; color: #7891B1; pointer-events: none; }

.nav-group { padding: 8px 10px; }
.nav-label { font-size: 9.5px; letter-spacing: 1.4px; color: #5F7899; padding: 6px 10px; }
.nav-item {
  position: relative; display: flex; align-items: center; gap: 10px;
  height: 40px; padding: 0 11px; margin: 2px 0; border-radius: 9px;
  color: #A9BCD5; font-size: 12.5px; transition: .16s;
}
.nav-item .ic { width: 17px; height: 17px; color: #7E99BB; }
.nav-item:hover { background: rgba(255,255,255,.055); color: #EAF2FF; }
.nav-item.active { background: linear-gradient(90deg, rgba(46,116,240,.28), rgba(46,116,240,.1)); color: #fff; }
.nav-item.active::before { content: ""; position: absolute; left: -10px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: #4D9BFF; }
.nav-item.active .ic { color: #7BB6FF; }
.nav-badge {
  margin-left: auto; min-width: 18px; height: 17px; padding: 0 5px;
  border-radius: 9px; background: rgba(214,63,63,.9); color: #fff;
  font-family: var(--num); font-size: 9.5px; font-style: normal;
  display: grid; place-items: center;
}
.sidebar-foot { margin-top: auto; padding: 12px; }
.storage-card { padding: 11px 12px; border-radius: 11px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.07); }
.storage-top, .storage-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.storage-top { font-size: 10px; color: #8FA6C3; }
.storage-top b { font-family: var(--num); font-size: 10.5px; color: #D8E6F8; font-weight: 600; }
.storage-bar { height: 5px; border-radius: 4px; background: rgba(255,255,255,.1); margin: 8px 0 6px; overflow: hidden; }
.storage-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #4D9BFF, #2E74F0); }
.storage-bottom { font-size: 9.5px; color: #6F89A9; }
.chip.tiny { height: 17px; padding: 0 6px; font-size: 9px; background: rgba(255,255,255,.09); color: #AFC4DE; }
.user-mini { display: flex; align-items: center; gap: 9px; padding: 12px 2px 2px; }
.user-mini > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.user-mini strong { color: #EAF2FF; font-size: 12px; font-weight: 600; }
.user-mini span { color: #7189A8; font-size: 9.5px; }
.mini-logout { color: #6F89A9; padding: 4px; border-radius: 6px; }
.mini-logout:hover { color: #fff; background: rgba(255,255,255,.08); }
.mini-logout .ic { width: 15px; height: 15px; }

/* ---------- 手机底部导航 ---------- */
.tabbar { display: none; }
.tab-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; height: 100%; color: #8A9AAE; font-size: 9px; font-weight: 500;
}
.tab-item.active { color: var(--primary); font-weight: 600; }
.tab-item.active .ic { color: var(--primary); }
.tab-ic { position: relative; display: inline-flex; }
.tab-ic .ic { width: 20px; height: 20px; }
.tab-ic i { position: absolute; top: -2px; right: -4px; width: 5px; height: 5px; border-radius: 50%; background: var(--red); border: 1px solid #fff; }

/* ---------- 头像 ---------- */
.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  display: inline-grid; place-items: center; color: #fff;
  font-size: 12px; font-weight: 600; background: #1D5FD1;
}
.avatar.sm { width: 30px; height: 30px; font-size: 11px; }
.avatar.xs { width: 22px; height: 22px; font-size: 9px; }
.avatar.xl { width: 58px; height: 58px; font-size: 20px; }
.avatar.blue { background: linear-gradient(145deg,#3B82F6,#1D5FD1); }
.avatar.green { background: linear-gradient(145deg,#2BC48A,#0E9F6E); }
.avatar.violet { background: linear-gradient(145deg,#8B7BEE,#6D5BD0); }
.avatar.amber { background: linear-gradient(145deg,#E7A23B,#C77A08); }
.avatar.red { background: linear-gradient(145deg,#EC6A6A,#D63F3F); }

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  height: 66px; flex: none; display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 0 24px; background: rgba(255,255,255,.94);
  backdrop-filter: blur(14px); border-bottom: 1px solid var(--line);
}
.topbar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.page-title h1 { font-size: 18px; font-weight: 700; letter-spacing: .2px; line-height: 1.2; }
.page-title p { font-size: 10.5px; color: var(--ink-4); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 420px; }
.topbar-right { display: flex; align-items: center; gap: 8px; }
.top-search {
  display: flex; align-items: center; gap: 8px; width: 310px; height: 36px;
  padding: 0 10px; border: 1px solid var(--line); border-radius: 9px; background: #F7F9FC;
}
.top-search .ic { width: 15px; height: 15px; color: var(--ink-4); }
.top-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 12px; }
.top-search input::placeholder { color: var(--ink-4); }
.top-search kbd { font-family: var(--font); font-size: 9px; color: var(--ink-4); background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 2px 5px; }
.icon-btn {
  position: relative; width: 34px; height: 34px; display: inline-grid; place-items: center;
  border: 0; border-radius: 9px; background: transparent; color: var(--ink-3);
}
.icon-btn:hover { background: var(--line-2); color: var(--ink); }
.icon-btn.sm { width: 28px; height: 28px; }
.icon-btn.sm .ic { width: 15px; height: 15px; }
.icon-btn.danger:hover { background: var(--red-bg); color: var(--red); }
.bell i {
  position: absolute; top: 3px; right: 3px; min-width: 14px; height: 14px; padding: 0 3px;
  border-radius: 8px; background: var(--red); color: #fff; font-style: normal;
  font-family: var(--num); font-size: 8px; display: grid; place-items: center;
  border: 2px solid #fff;
}
.menu-btn { display: none; }
.user-menu { position: relative; }
.user-trigger {
  display: flex; align-items: center; gap: 8px; padding: 3px 6px 3px 3px;
  border: 0; background: transparent; border-radius: 10px;
}
.user-trigger:hover { background: var(--line-2); }
.user-trigger-txt { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding-right: 2px; }
.user-trigger-txt strong { font-size: 11.5px; font-weight: 600; }
.user-trigger-txt span { font-size: 9px; color: var(--ink-4); }
.user-trigger > .ic { width: 13px; height: 13px; color: var(--ink-4); }
.user-dropdown {
  position: absolute; right: 0; top: calc(100% + 8px); width: 178px;
  background: #fff; border: 1px solid var(--line); border-radius: 11px;
  box-shadow: 0 18px 40px -18px rgba(15,35,65,.25); padding: 6px;
  display: none; z-index: 80;
}
.user-menu.open .user-dropdown { display: block; }
.user-dropdown a { display: flex; align-items: center; gap: 9px; padding: 9px 10px; border-radius: 7px; font-size: 12px; color: var(--ink-2); }
.user-dropdown a:hover { background: var(--line-2); }
.user-dropdown a .ic { width: 15px; height: 15px; color: var(--ink-4); }
.user-dropdown a.danger { color: var(--red); }
.user-dropdown a.danger .ic { color: var(--red); }
.user-dropdown .sep { height: 1px; background: var(--line); margin: 4px 6px; }

/* ---------- 内容 ---------- */
.content { flex: 1; overflow-x: hidden; padding: 22px 26px 40px; }
.content-inner { max-width: 1420px; margin: 0 auto; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 2px 0 16px; }
.page-desc { font-size: 11.5px; color: var(--ink-4); line-height: 1.7; }
.page-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.flash {
  display: flex; align-items: center; gap: 9px; padding: 11px 14px; margin-bottom: 14px;
  border-radius: 10px; border: 1px solid; font-size: 12px; transition: .3s;
}
.flash.success { background: var(--green-bg); border-color: #BDEBD8; color: #076E4C; }
.flash.error { background: var(--red-bg); border-color: #F6CECE; color: #A62B2B; }
.flash.warn { background: var(--amber-bg); border-color: #F5DDB4; color: #8A5503; }
.flash .ic { width: 16px; height: 16px; }
.flash button { margin-left: auto; border: 0; background: transparent; color: inherit; opacity: .6; padding: 2px; }
.flash.fade { opacity: 0; transform: translateY(-4px); }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 36px; padding: 0 14px; border-radius: 9px; border: 1px solid transparent;
  font-size: 12px; font-weight: 600; white-space: nowrap; transition: .16s;
}
.btn .ic { width: 15px; height: 15px; }
.btn.sm { height: 30px; padding: 0 11px; font-size: 11px; border-radius: 8px; }
.btn.lg { height: 44px; font-size: 13px; border-radius: 10px; }
.btn.full { width: 100%; }
.btn-primary { background: linear-gradient(135deg,#2E74F0,#1D5FD1); color: #fff; box-shadow: 0 8px 18px -10px rgba(29,95,209,.8); }
.btn-primary:hover { filter: brightness(1.05); transform: translateY(-1px); }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--ink-2); }
.btn-ghost:hover { border-color: #C7D4E5; background: #FBFCFE; }
.btn-danger { background: var(--red-bg); color: var(--red); border-color: #F3C6C6; }
.btn-danger:hover { background: #FBE0E0; }
.btn-light { background: #fff; color: var(--primary); }
.btn-glass { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.18); color: #EAF3FF; }
.btn-glass:hover { background: rgba(255,255,255,.16); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.link-btn {
  display: inline-flex; align-items: center; gap: 3px; border: 0; background: transparent;
  color: var(--primary); font-size: 11px; font-weight: 600; padding: 2px;
}
.link-btn .ic { width: 13px; height: 13px; }
.link-btn:hover { color: var(--primary-2); }
.mini-btn {
  width: 28px; height: 28px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink-3);
}
.mini-btn .ic { width: 15px; height: 15px; }
.mini-btn:hover { background: var(--line-2); }

/* ---------- 标签 ---------- */
.chip {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  height: 22px; padding: 0 8px; border-radius: 6px;
  background: var(--line-2); color: var(--ink-3); font-size: 10px; font-weight: 600;
  white-space: nowrap;
}
.chip.blue { background: #EAF2FF; color: var(--primary); }
.chip.green, .chip.ok { background: var(--green-bg); color: var(--green); }
.chip.amber, .chip.warn { background: var(--amber-bg); color: var(--amber); }
.chip.red, .chip.err { background: var(--red-bg); color: var(--red); }
.chip.pending { background: #F1F4F8; color: var(--ink-3); }
.chip.violet { background: var(--violet-bg); color: var(--violet); }
.chip.dot-green::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.status {
  display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
  border-radius: 6px; font-size: 10px; font-weight: 600;
}
.status.ok { background: var(--green-bg); color: var(--green); }
.status.warn { background: var(--amber-bg); color: var(--amber); }
.status.pending { background: #F1F4F8; color: var(--ink-3); }
.icon-tile {
  width: 34px; height: 34px; border-radius: 9px; flex: none;
  display: grid; place-items: center;
}
.icon-tile .ic { width: 17px; height: 17px; }
.icon-tile.blue { background: #EAF2FF; color: var(--primary); }
.icon-tile.green { background: var(--green-bg); color: var(--green); }
.icon-tile.amber { background: var(--amber-bg); color: var(--amber); }
.icon-tile.red { background: var(--red-bg); color: var(--red); }
.icon-tile.violet { background: var(--violet-bg); color: var(--violet); }
.icon-tile.cyan { background: var(--cyan-bg); color: var(--cyan); }
.icon-tile.big { width: 44px; height: 44px; border-radius: 12px; }
.icon-tile.big .ic { width: 21px; height: 21px; }

/* ---------- 卡片与网格 ---------- */
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px 20px; min-width: 0;
}
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h3 { font-size: 14px; font-weight: 700; letter-spacing: .1px; }
.card-head p { font-size: 10.5px; color: var(--ink-4); margin-top: 4px; line-height: 1.5; }
.card-head-actions { display: flex; align-items: center; gap: 10px; }
.grid { display: grid; gap: 16px; margin-top: 16px; }
.grid-half { grid-template-columns: 1fr 1fr; }
.grid-2-1 { grid-template-columns: 1.75fr 1fr; }
.empty-state { text-align: center; padding: 54px 22px; margin-top: 20px; }
.empty-ic { width: 58px; height: 58px; border-radius: 16px; background: #EAF2FF; color: var(--primary); display: grid; place-items: center; margin: 0 auto 14px; }
.empty-ic .ic { width: 26px; height: 26px; }
.empty-state h3 { font-size: 16px; margin-bottom: 6px; }
.empty-state p { color: var(--ink-4); font-size: 12px; margin-bottom: 18px; }
.empty-mini { color: var(--ink-4); font-size: 11.5px; padding: 18px 4px; text-align: center; }
.empty-mini a { color: var(--primary); font-weight: 600; }

/* ---------- 工作台 Hero ---------- */
.hero {
  position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between;
  gap: 26px; padding: 26px 30px; border-radius: 20px; color: #fff;
  background: linear-gradient(115deg, #0A1B31 0%, #0D2A4D 48%, #144A8C 100%);
  box-shadow: 0 22px 50px -30px rgba(10,27,49,.8);
}
.hero-grid-bg {
  position: absolute; inset: 0; opacity: .45; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,.055) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.055) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(90deg, transparent, #000 40%, #000);
}
.hero-copy { position: relative; z-index: 2; max-width: 680px; }
.hero-eyebrow { display: flex; align-items: center; gap: 8px; font-size: 10px; color: #9DB6D6; letter-spacing: .3px; }
.live-dot { width: 6px; height: 6px; border-radius: 50%; background: #46D39A; box-shadow: 0 0 0 4px rgba(70,211,154,.14); }
.tag-glass { padding: 2px 7px; border-radius: 4px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.14); color: #D6E7FF; font-size: 9px; }
.hero h2 { font-size: 27px; font-weight: 700; letter-spacing: .3px; margin: 12px 0 8px; }
.hero p { color: #A9C0DC; font-size: 11.5px; line-height: 1.8; }
.hero p b { color: #fff; font-family: var(--num); font-size: 13px; }
.hero-actions { display: flex; gap: 9px; margin-top: 18px; }
.hero-side { position: relative; z-index: 2; display: flex; align-items: center; gap: 26px; flex: none; }
.ring {
  width: 142px; height: 142px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(#4D9BFF calc(var(--p) * 1%), rgba(255,255,255,.12) 0);
  box-shadow: 0 0 0 1px rgba(255,255,255,.05), 0 18px 40px -22px rgba(77,155,255,.9);
}
.ring-inner {
  width: 112px; height: 112px; border-radius: 50%; background: #0D2440;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.06);
}
.ring-inner b { font-family: var(--num); font-size: 30px; line-height: 1; font-weight: 600; }
.ring-inner b em { font-style: normal; font-size: 14px; margin-left: 1px; color: #BBD5F5; }
.ring-inner span { font-size: 9px; color: #8FA9C8; letter-spacing: .6px; }
.hero-nums { display: flex; flex-direction: column; gap: 16px; }
.hero-nums b { display: block; font-family: var(--num); font-size: 23px; line-height: 1; font-weight: 600; }
.hero-nums span { display: block; font-size: 9.5px; color: #8FA9C8; margin-top: 5px; }

/* ---------- KPI ---------- */
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 16px; }
.kpi { padding: 15px 17px 13px; }
.kpi-top { display: flex; align-items: center; gap: 9px; }
.kpi-top .icon-tile { width: 30px; height: 30px; border-radius: 8px; }
.kpi-top .icon-tile .ic { width: 15px; height: 15px; }
.kpi-label { font-size: 10.5px; color: var(--ink-3); }
.kpi-num { font-family: var(--num); font-size: 30px; font-weight: 600; line-height: 1.2; margin: 9px 0 7px; letter-spacing: -.5px; }
.kpi-num em { font-style: normal; font-size: 11px; color: var(--ink-4); font-family: var(--font); margin-left: 3px; font-weight: 500; }
.kpi-foot { display: flex; align-items: center; gap: 8px; font-size: 9.5px; color: var(--ink-4); }
.kpi-foot .up { color: var(--green); font-weight: 600; }
.kpi-foot .down { color: var(--red); font-weight: 600; }
.mini-bars { margin-left: auto; display: flex; align-items: flex-end; gap: 3px; height: 18px; }
.mini-bars i { width: 3px; border-radius: 2px; background: #BFD7FB; display: block; }
.mini-bars i:nth-child(1) { height: 7px; }
.mini-bars i:nth-child(2) { height: 12px; }
.mini-bars i:nth-child(3) { height: 9px; }
.mini-bars i:nth-child(4) { height: 16px; background: var(--primary-2); }
.mini-bars i:nth-child(5) { height: 11px; }
.mini-bars.amber i { background: #F3D9AE; }
.mini-bars.amber i:nth-child(4) { background: var(--amber); }
.mini-bars.red i { background: #F3C6C6; }
.mini-bars.red i:nth-child(4) { background: var(--red); }
.mini-bars.green i { background: #BFEBD8; }
.mini-bars.green i:nth-child(4) { background: var(--green); }

/* ---------- 趋势图 ---------- */
.trend-card { display: flex; flex-direction: column; }
.seg { display: inline-flex; padding: 3px; border-radius: 8px; background: var(--line-2); }
.seg a, .seg button { height: 26px; padding: 0 10px; border: 0; border-radius: 6px; background: transparent; color: var(--ink-3); font-size: 10.5px; font-weight: 600; }
.seg a.active, .seg button.active { background: #fff; color: var(--ink); box-shadow: 0 1px 4px rgba(15,35,65,.1); }
.seg.small a, .seg.small button { height: 23px; padding: 0 8px; font-size: 10px; }
.legend-row { display: flex; align-items: center; gap: 16px; font-size: 10px; color: var(--ink-3); margin: 2px 0 4px; }
.dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; margin-right: 5px; }
.dot.blue { background: var(--primary-2); }
.dot.green { background: #12A67C; }
.legend-row .unit { margin-left: auto; color: var(--ink-4); }
.trend-wrap { flex: 1; min-height: 200px; margin: 2px -4px 0; }
.trend-svg { width: 100%; height: 210px; display: block; }
.trend-foot { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 6px; }
.trend-foot > div { padding-left: 10px; border-left: 2px solid #DCE8FA; }
.trend-foot > div:first-child { border-left-color: var(--primary-2); }
.trend-foot > div:nth-child(2) { border-left-color: var(--green); }
.trend-foot > div:nth-child(3) { border-left-color: var(--amber); }
.trend-foot b { display: block; font-family: var(--num); font-size: 18px; font-weight: 600; }
.trend-foot b em { font-style: normal; font-size: 10px; color: var(--ink-4); }
.trend-foot span { display: block; font-size: 9.5px; color: var(--ink-4); margin-top: 3px; }

/* ---------- 待办 ---------- */
.todo-add-form { display: flex; gap: 6px; margin: -4px 0 10px; }
.todo-add-form .input { height: 32px; }
.todo-list { display: flex; flex-direction: column; gap: 1px; }
.todo {
  display: flex; align-items: center; gap: 9px; padding: 10px 2px;
  border-bottom: 1px dashed var(--line); margin: 0;
}
.todo:last-child { border-bottom: 0; }
.tick {
  width: 17px; height: 17px; border-radius: 50%; border: 1.5px solid #C8D3E1;
  background: #fff; flex: none; position: relative;
}
.tick.checked { background: var(--green); border-color: var(--green); }
.tick.checked::after { content: ""; position: absolute; left: 5px; top: 2px; width: 4px; height: 8px; border: solid #fff; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.todo-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.todo-main strong { font-size: 11.5px; font-weight: 600; line-height: 1.4; }
.todo-main span { font-size: 9.5px; color: var(--ink-4); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.todo.done .todo-main strong { color: var(--ink-4); text-decoration: line-through; }
.todo .chip { flex: none; }

/* ---------- 进度 ---------- */
.progress-card { display: flex; flex-direction: column; }
.progress-list { display: flex; flex-direction: column; gap: 14px; margin-top: 2px; }
.p-row { display: grid; grid-template-columns: 104px 1fr 82px; align-items: center; gap: 10px; }
.p-name { font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.p-track { height: 6px; border-radius: 5px; background: #EFF3F9; overflow: hidden; }
.p-fill { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, #5FA8FF, #2E74F0); transition: width .5s ease; }
.p-fill.warn { background: linear-gradient(90deg, #F6C15B, #E0980B); }
.p-fill.full { background: linear-gradient(90deg, #3DD6A2, #0E9F6E); }
.p-num { font-family: var(--num); font-size: 10.5px; color: var(--ink-4); text-align: right; }
.p-num b { color: var(--ink-2); font-weight: 600; font-size: 11px; }
.progress-total { margin-top: auto; padding-top: 13px; border-top: 1px dashed var(--line); display: flex; align-items: baseline; gap: 5px; font-size: 10.5px; color: var(--ink-4); }
.progress-total b { font-family: var(--num); font-size: 17px; color: var(--ink); font-weight: 600; }
.progress-total em { margin-left: auto; font-style: normal; font-family: var(--num); font-size: 13px; color: var(--primary); font-weight: 600; }

/* ---------- 提醒 ---------- */
.remind-list { display: flex; flex-direction: column; }
.remind { display: flex; align-items: center; gap: 11px; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.remind:last-child { border-bottom: 0; }
.remind-date {
  width: 40px; height: 42px; border-radius: 9px; background: #F1F5FB; color: var(--ink-2);
  display: flex; flex-direction: column; align-items: center; justify-content: center; flex: none;
}
.remind-date b { font-family: var(--num); font-size: 14px; line-height: 1; }
.remind-date span { font-size: 8px; color: var(--ink-4); margin-top: 2px; }
.remind-date.hot { background: var(--amber-bg); color: var(--amber); }
.remind-date.hot span { color: #B98A3A; }
.remind-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.remind-main strong { font-size: 11.5px; font-weight: 600; line-height: 1.4; }
.remind-main span { font-size: 9.5px; color: var(--ink-4); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.remind .chip { flex: none; }

/* ---------- 快捷操作 ---------- */
.quick-card { margin-top: 16px; }
.quick-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.quick {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 6px;
  padding: 12px 12px 11px; border: 1px solid var(--line); border-radius: 11px;
  background: #FBFCFE; text-align: left; transition: .16s;
}
.quick:hover { background: #fff; border-color: #C9D9EF; transform: translateY(-1px); box-shadow: 0 8px 20px -18px rgba(15,35,65,.4); }
.quick .icon-tile { width: 29px; height: 29px; border-radius: 8px; }
.quick strong { font-size: 11.5px; font-weight: 600; }
.quick > span:last-child { font-size: 9px; color: var(--ink-4); }
.quick .arrow { position: absolute; right: 9px; top: 12px; color: #C3D1E4; }
.quick .arrow .ic { width: 13px; height: 13px; }
.quick:hover .arrow { color: var(--primary); }

/* ---------- 动态 / 工程 ---------- */
.timeline { display: flex; flex-direction: column; gap: 0; }
.tl-item { position: relative; padding: 0 0 14px 17px; border-left: 1px solid var(--line); margin-left: 4px; }
.tl-item:last-child { border-left-color: transparent; padding-bottom: 0; }
.tl-item::before { content: ""; position: absolute; left: -4px; top: 3px; width: 7px; height: 7px; border-radius: 50%; background: #9DB6D6; box-shadow: 0 0 0 3px #fff; }
.tl-item.blue::before { background: var(--primary-2); }
.tl-item.amber::before { background: var(--amber); }
.tl-item.green::before { background: var(--green); }
.tl-item p { font-size: 11.5px; color: var(--ink-2); line-height: 1.6; }
.tl-item p b { font-weight: 600; }
.tl-item span { display: block; font-size: 9.5px; color: var(--ink-4); margin-top: 4px; }
.proj-list { display: flex; flex-direction: column; gap: 4px; }
.proj-form { margin: 0; }
.proj {
  width: 100%; display: flex; align-items: center; gap: 9px; padding: 9px 7px;
  border: 0; border-radius: 9px; background: transparent; text-align: left;
}
.proj:hover { background: #F7FAFE; }
.proj.active { background: #F0F6FF; }
.proj-ic { width: 30px; height: 30px; border-radius: 8px; background: #EAF2FF; color: var(--primary); display: grid; place-items: center; flex: none; }
.proj-ic .ic { width: 15px; height: 15px; }
.proj-main { flex: 1; min-width: 0; }
.proj-main strong { display: block; font-size: 11px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.proj-main .p-track { height: 4px; margin: 5px 0 4px; max-width: 210px; }
.proj-main > span { font-size: 9px; color: var(--ink-4); }
.proj-num { font-family: var(--num); font-size: 15px; color: var(--ink); flex: none; }
.proj-num em { font-style: normal; font-size: 9px; color: var(--ink-4); }

/* ---------- 统计卡 / 资料页 ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 16px; }
.stat { display: flex; align-items: center; gap: 11px; padding: 14px 16px; }
.stat .icon-tile { width: 34px; height: 34px; }
.stat b { display: block; font-family: var(--num); font-size: 21px; font-weight: 600; line-height: 1.1; }
.stat span { display: block; font-size: 10px; color: var(--ink-4); margin-top: 3px; }
.docs-layout { display: grid; grid-template-columns: 258px 1fr; gap: 16px; align-items: start; }
.tree-card { padding: 16px 14px; position: sticky; top: 82px; }
.tree-card .card-head { padding: 0 4px; }
.tree { display: flex; flex-direction: column; gap: 2px; }
.tree-group { margin: 0; }
.tree-group > summary { list-style: none; cursor: pointer; }
.tree-group > summary::-webkit-details-marker { display: none; }
.tree-row {
  display: flex; align-items: center; gap: 6px; width: 100%; height: 32px;
  padding: 0 7px; border: 0; border-radius: 7px; background: transparent;
  color: var(--ink-2); font-size: 11.5px; text-align: left;
}
.tree-row:hover { background: #F5F8FC; }
.tree-row.group { font-weight: 600; color: var(--ink); }
.tree-row .tw { width: 12px; height: 12px; color: var(--ink-4); transition: .15s; }
.tree-group[open] > summary .tw { transform: rotate(90deg); }
.tree-row .folder { width: 15px; height: 15px; color: #7FA6D9; }
.tree-row em { margin-left: auto; font-family: var(--num); font-size: 9px; font-style: normal; color: var(--ink-4); }
.tree-children { padding: 1px 0 3px 21px; display: flex; flex-direction: column; gap: 1px; }
.tree-row.child { height: 29px; font-size: 11px; color: var(--ink-3); }
.tree-row.child em { font-size: 9px; }
.tree-row.child.active { background: #EAF2FF; color: var(--primary); font-weight: 600; }
.tree-row.child.all { color: var(--ink-2); font-weight: 600; }
.tree-summary { border-top: 1px solid var(--line); margin-top: 10px; padding: 12px 6px 2px; }
.tree-summary > div:first-child { display: flex; align-items: center; justify-content: space-between; font-size: 10px; color: var(--ink-4); margin-bottom: 7px; }
.tree-summary b { font-family: var(--num); font-size: 10.5px; color: var(--ink-2); }
.docs-card { padding: 0; overflow: hidden; }
.tabs { display: flex; align-items: center; gap: 4px; padding: 0 18px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { position: relative; display: inline-flex; align-items: center; gap: 5px; height: 46px; padding: 0 12px; font-size: 11.5px; color: var(--ink-3); white-space: nowrap; }
.tab span { font-family: var(--num); font-size: 9.5px; color: var(--ink-4); background: var(--line-2); border-radius: 5px; padding: 1px 5px; }
.tab.active { color: var(--primary); font-weight: 600; }
.tab.active::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--primary); }
.tab.active span { background: #EAF2FF; color: var(--primary); }
.toolbar { display: flex; align-items: center; gap: 10px; padding: 13px 18px; border-bottom: 1px solid var(--line-2); flex-wrap: wrap; }
.search-inline { display: flex; align-items: center; gap: 7px; width: 300px; height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: #FBFCFE; }
.search-inline .ic { width: 15px; height: 15px; color: var(--ink-4); }
.search-inline input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 11.5px; }
.toolbar-right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.current-filter { display: inline-flex; align-items: center; gap: 4px; font-size: 10.5px; color: var(--ink-3); }
.current-filter .ic { width: 13px; height: 13px; color: var(--ink-4); }
.select-inline { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); }
.select-inline .ic { width: 13px; height: 13px; color: var(--ink-4); }
.select-inline select { border: 0; outline: 0; background: transparent; font-size: 10.5px; color: var(--ink-3); cursor: pointer; }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.table th { text-align: left; font-size: 9.5px; font-weight: 500; color: var(--ink-4); padding: 10px 12px; background: #FAFBFD; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 11px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; color: var(--ink-2); }
.table tbody tr { transition: .12s; }
.table tbody tr[data-row-href] { cursor: pointer; }
.table tbody tr:hover { background: #FAFCFF; }
.table tbody tr:last-child td { border-bottom: 0; }
.table .mono { font-size: 10px; color: var(--ink-3); white-space: nowrap; }
.doc-name { display: flex; align-items: center; gap: 9px; min-width: 220px; }
.file-tile { width: 30px; height: 34px; border-radius: 7px; display: grid; place-items: center; flex: none; background: #EAF2FF; color: var(--primary); }
.file-tile .ic { width: 15px; height: 15px; }
.file-tile.green { background: var(--green-bg); color: var(--green); }
.file-tile.amber { background: var(--amber-bg); color: var(--amber); }
.doc-name > div { min-width: 0; }
.doc-name strong { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 300px; }
.doc-name span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 3px; }
.person { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.row-actions { white-space: nowrap; }
.inline-form { display: inline-flex; margin: 0; }
.table-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line); font-size: 10px; color: var(--ink-4); }
.pager { display: flex; align-items: center; gap: 3px; }
.pg { min-width: 25px; height: 25px; padding: 0 6px; display: inline-grid; place-items: center; border-radius: 6px; font-size: 10px; color: var(--ink-3); }
a.pg:hover { background: var(--line-2); }
.pg.active { background: var(--primary); color: #fff; font-weight: 600; }
.pg.disabled { color: #C7D1DE; }
.pg.dots { color: var(--ink-4); }

/* ---------- 通用表单 ---------- */
.form-layout { display: grid; grid-template-columns: 1.7fr 1fr; gap: 16px; align-items: start; }
.form-main, .form-side { min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.form-card { padding: 18px 20px; }
.form-card.narrow-card { max-width: 760px; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.field { margin-bottom: 14px; }
.field:last-child { margin-bottom: 0; }
.field label { display: block; font-size: 10.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.input, .select, .textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 8px; background: #FBFCFE;
  outline: 0; transition: .15s; color: var(--ink);
}
.input, .select { height: 37px; padding: 0 11px; }
.input.lg { height: 42px; font-size: 14px; font-weight: 500; }
.select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, #8FA0B6 50%), linear-gradient(135deg, #8FA0B6 50%, transparent 50%); background-position: calc(100% - 15px) 16px, calc(100% - 10px) 16px; background-size: 4px 4px; background-repeat: no-repeat; padding-right: 28px; }
.select.sm { height: 29px; font-size: 10px; padding: 0 24px 0 8px; background-position: calc(100% - 12px) 13px, calc(100% - 8px) 13px; }
.textarea { padding: 10px 11px; line-height: 1.8; resize: vertical; min-height: 180px; }
.input:focus, .select:focus, .textarea:focus { border-color: #9CC2F8; background: #fff; box-shadow: 0 0 0 3px rgba(46,116,240,.08); }
.input::placeholder, .textarea::placeholder { color: #B2BECE; }
.form-actions { display: flex; align-items: center; gap: 9px; margin-top: 16px; }
.form-errors { display: flex; gap: 10px; padding: 12px 14px; border-radius: 10px; background: var(--red-bg); border: 1px solid #F4CBCB; color: #A62B2B; font-size: 11.5px; margin-bottom: 14px; }
.form-errors .ic { width: 17px; height: 17px; flex: none; margin-top: 1px; }
.date-range { display: flex; align-items: center; gap: 6px; }
.date-range span { font-size: 10px; color: var(--ink-4); flex: none; }
.status-flow { display: flex; align-items: center; gap: 0; margin: 4px 0 12px; }
.status-flow.vertical { flex-direction: column; align-items: stretch; gap: 12px; }
.sf { flex: 1; display: flex; align-items: center; gap: 6px; position: relative; }
.sf i { width: 9px; height: 9px; border-radius: 50%; background: #D5DDE8; flex: none; }
.sf span { font-size: 9.5px; color: var(--ink-4); white-space: nowrap; }
.sf.active i { background: var(--primary); box-shadow: 0 0 0 3px #EAF2FF; }
.sf.active span { color: var(--primary); font-weight: 600; }
.status-flow.vertical .sf { align-items: flex-start; }
.status-flow.vertical .sf i { margin-top: 4px; }
.status-flow.vertical .sf div { display: flex; flex-direction: column; gap: 2px; }
.status-flow.vertical .sf b { font-size: 11.5px; color: var(--ink-2); }
.status-flow.vertical .sf span { font-size: 9.5px; color: var(--ink-4); white-space: normal; }
.status-flow.vertical .sf.active b { color: var(--primary); }
.hint-box { display: flex; gap: 9px; padding: 11px; border-radius: 9px; background: #F7F9FC; border: 1px solid var(--line-2); }
.hint-box .ic { width: 15px; height: 15px; color: var(--ink-4); margin-top: 1px; }
.hint-box p { font-size: 10px; color: var(--ink-4); line-height: 1.7; }
.side-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.side-actions form { margin: 0; }
.color-picker { display: flex; gap: 9px; }
.color-dot { position: relative; width: 26px; height: 26px; cursor: pointer; }
.color-dot input { position: absolute; opacity: 0; }
.color-dot i { display: block; width: 26px; height: 26px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 2px #fff; }
.color-dot input:checked + i { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--c); }

/* ---------- 资料详情 / A4 纸张 ---------- */
.view-layout { display: grid; grid-template-columns: 1fr 300px; gap: 16px; align-items: start; }
.paper-wrap { min-width: 0; }
.paper {
  background: #fff; border: 1px solid var(--line); border-radius: 4px;
  box-shadow: 0 18px 50px -32px rgba(15,35,65,.35);
  padding: 36px 42px 30px; width: 100%; max-width: 880px; margin: 0 auto;
  font-family: "SimSun", "Songti SC", "Noto Serif SC", serif; color: #111;
}
.paper-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; border-bottom: 1px solid #333; padding-bottom: 10px; }
.paper-brand { display: flex; align-items: center; gap: 8px; }
.paper-logo { width: 31px; height: 31px; border-radius: 8px; background: var(--primary); color: #fff; display: grid; place-items: center; }
.paper-logo svg { width: 20px; height: 20px; }
.paper-brand strong { display: block; font-family: var(--font); font-size: 11px; font-weight: 600; color: #222; }
.paper-brand span { display: block; font-family: var(--font); font-size: 8.5px; color: #777; margin-top: 2px; letter-spacing: 1px; }
.paper-no { font-size: 10px; color: #444; padding-top: 3px; }
.paper-title { font-size: 23px; text-align: center; letter-spacing: 2px; margin: 22px 0 5px; font-weight: 700; }
.paper-sub { text-align: center; font-size: 10px; color: #666; letter-spacing: .5px; margin-bottom: 18px; }
.paper-meta { width: 100%; border-collapse: collapse; font-size: 10.5px; margin-bottom: 18px; }
.paper-meta td { border: 1px solid #444; padding: 7px 8px; line-height: 1.5; }
.paper-meta .lbl { width: 92px; background: #F5F5F5; color: #333; font-weight: 600; text-align: center; }
.paper-content { min-height: 280px; font-size: 12px; line-height: 2.05; }
.paper-content p { margin: 0 0 2px; text-indent: 2em; }
.paper-content .paper-gap { height: 8px; }
.paper-empty { color: #999; text-align: center; text-indent: 0 !important; padding: 40px 0; }
.paper-sign { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; margin-top: 34px; font-size: 10.5px; }
.paper-sign > div { display: flex; flex-direction: column; gap: 8px; }
.paper-sign span { color: #555; }
.paper-sign b { font-size: 11px; font-weight: 500; }
.paper-sign em { font-style: normal; color: #777; border-bottom: 1px solid #999; height: 18px; }
.paper-stamp { margin-top: 22px; width: 132px; height: 52px; border: 1px dashed #C9C9C9; border-radius: 6px; color: #B5B5B5; font-size: 9px; display: grid; place-items: center; }
.paper-foot { margin-top: 16px; padding-top: 8px; border-top: 1px solid #ddd; text-align: center; font-size: 8px; color: #999; font-family: var(--font); }
.doc-side { display: flex; flex-direction: column; gap: 14px; }
.doc-side .card { padding: 16px; }
.info-list { display: flex; flex-direction: column; gap: 0; }
.info-list > div { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 10.5px; }
.info-list > div:last-child { border-bottom: 0; }
.info-list span { color: var(--ink-4); flex: none; }
.info-list b { font-weight: 500; color: var(--ink-2); text-align: right; }
.tip-card { display: flex; gap: 9px; align-items: flex-start; }
.tip-card .icon-tile { width: 30px; height: 30px; }
.tip-card strong { font-size: 11.5px; }
.tip-card p { font-size: 10px; color: var(--ink-4); line-height: 1.7; margin-top: 3px; }

/* ---------- 台账 ---------- */
.check-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.check-card {
  display: flex; align-items: flex-start; gap: 10px; padding: 13px 14px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  border-left: 3px solid #D5DDE8; box-shadow: var(--shadow);
}
.check-card.ok { border-left-color: var(--green); }
.check-card.warn { border-left-color: var(--amber); }
.check-card.err { border-left-color: var(--red); }
.check-card .icon-tile { width: 29px; height: 29px; border-radius: 8px; }
.check-main { flex: 1; min-width: 0; }
.check-main strong { display: block; font-size: 11.5px; font-weight: 600; }
.check-main p { font-size: 9.5px; color: var(--ink-4); line-height: 1.6; margin-top: 4px; }
.check-status { display: inline-flex; align-items: center; gap: 3px; font-size: 9px; font-weight: 600; white-space: nowrap; }
.check-status .ic { width: 12px; height: 12px; }
.check-status.ok { color: var(--green); }
.check-status.warn { color: var(--amber); }
.check-status.err { color: var(--red); }
.matrix-card { padding: 0; overflow: hidden; margin-bottom: 16px; }
.matrix-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 16px 20px 12px; flex-wrap: wrap; }
.matrix-head h3 { font-size: 14px; }
.matrix-head p { font-size: 10.5px; color: var(--ink-4); margin-top: 4px; }
.matrix-hint { display: none; font-size: 9.5px; color: var(--ink-4); margin-top: 6px; }
.legend { display: flex; align-items: center; gap: 12px; font-size: 9.5px; color: var(--ink-4); flex-wrap: wrap; }
.legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; margin-right: 4px; vertical-align: -1px; }
.legend .ok { background: #D8F3E8; border: 1px solid #A9E2CB; }
.legend .warn { background: #FCEBCF; border: 1px solid #F0CE95; }
.legend .miss { background: #FBE0E0; border: 1px solid #F2BDBD; }
.legend .none { background: #F1F4F8; border: 1px solid #E0E6EE; }
.matrix-wrap { overflow-x: auto; padding: 0 20px 16px; }
.matrix { width: 100%; border-collapse: separate; border-spacing: 0; min-width: 620px; font-size: 11px; }
.matrix th { font-size: 9.5px; font-weight: 500; color: var(--ink-4); padding: 8px 6px; text-align: center; border-bottom: 1px solid var(--line); }
.matrix th:first-child { text-align: left; padding-left: 8px; }
.matrix th:last-child { text-align: left; padding-left: 14px; }
.matrix td { padding: 7px 6px; text-align: center; border-bottom: 1px solid var(--line-2); }
.matrix td:first-child { text-align: left; font-size: 10.5px; color: var(--ink-2); padding-left: 8px; position: sticky; left: 0; background: #fff; z-index: 2; min-width: 92px; white-space: nowrap; }
.matrix td:last-child { text-align: left; padding-left: 14px; white-space: nowrap; }
.matrix tr:hover td { background: #FAFCFF; }
.matrix tr:hover td:first-child { background: #FAFCFF; }
.cell {
  width: 27px; height: 27px; border-radius: 7px; display: inline-grid; place-items: center;
  border: 1px solid transparent; margin: 0 auto;
}
.cell .ic { width: 13px; height: 13px; }
.cell.ok { background: #E9F8F1; border-color: #BFEAD7; color: var(--green); }
.cell.warn { background: #FFF5E4; border-color: #F5DDB4; color: var(--amber); }
.cell.miss { background: #FDEDED; border-color: #F6CECE; color: var(--red); }
.cell.none { background: #F1F4F8; border-color: #E3E9F1; color: #B6C2D2; }
a.cell:hover, button.cell:hover { transform: scale(1.08); }
.cell-form { display: inline-flex; margin: 0; }
.m-prog { width: 64px; height: 5px; border-radius: 4px; background: #EFF3F9; display: inline-block; vertical-align: middle; margin-right: 6px; overflow: hidden; }
.m-prog i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg,#5FA8FF,#2E74F0); }
.m-pct { font-family: var(--num); font-size: 9.5px; color: var(--ink-3); }
.ledger-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 16px; }
.miss-list { display: flex; flex-direction: column; gap: 2px; }
.miss-item { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.miss-item:last-child { border-bottom: 0; }
.miss-idx { width: 20px; height: 20px; border-radius: 6px; background: var(--red-bg); color: var(--red); font-family: var(--num); font-size: 9.5px; display: grid; place-items: center; flex: none; }
.miss-main { flex: 1; min-width: 0; }
.miss-main strong { display: block; font-size: 11px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.miss-main span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 2px; }
.tool-list { display: flex; flex-direction: column; gap: 1px; }
.tool-row { display: flex; align-items: center; gap: 9px; width: 100%; padding: 9px 0; border: 0; border-bottom: 1px dashed var(--line); background: transparent; text-align: left; color: var(--ink); }
.tool-row:last-child { border-bottom: 0; }
.tool-row .icon-tile { width: 30px; height: 30px; border-radius: 8px; }
.tool-row > div { flex: 1; min-width: 0; }
.tool-row strong { display: block; font-size: 11px; font-weight: 600; }
.tool-row span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 2px; }
.tool-row > .ic { width: 13px; height: 13px; color: #C3D1E4; }
.ledger-summary { display: flex; align-items: center; gap: 5px; margin-top: 11px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 9.5px; color: var(--ink-4); }
.ledger-summary b { color: var(--ink-2); font-family: var(--num); }

/* ---------- 模板 ---------- */
.ai-banner {
  display: flex; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 14px;
  border-radius: 14px; border: 1px solid #DCE8FA;
  background: linear-gradient(100deg,#F3F8FF, #FAF7FF 70%, #F4F0FF);
}
.ai-orb { width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(145deg,#6D5BD0,#4A3CB0); color: #fff; display: grid; place-items: center; flex: none; box-shadow: 0 10px 22px -12px rgba(109,91,208,.9); }
.ai-orb .ic { width: 21px; height: 21px; }
.ai-copy { flex: 1; min-width: 0; }
.ai-copy h3 { font-size: 14px; display: flex; align-items: center; gap: 6px; }
.ai-copy p { font-size: 10.5px; color: var(--ink-4); margin-top: 4px; }
.ai-input { display: flex; align-items: center; gap: 7px; width: 380px; height: 38px; padding: 3px 3px 3px 12px; border: 1px solid #DCE3EF; border-radius: 10px; background: #fff; }
.ai-input input { flex: 1; min-width: 0; border: 0; outline: 0; font-size: 11px; background: transparent; }
.ai-input .btn { height: 31px; font-size: 10.5px; padding: 0 11px; }
.tpl-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.chip-filters { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.filter-chip { height: 28px; padding: 0 12px; display: inline-flex; align-items: center; border-radius: 7px; background: #fff; border: 1px solid var(--line); color: var(--ink-3); font-size: 10.5px; }
.filter-chip.active { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.tpl-search { display: flex; align-items: center; gap: 7px; width: 250px; height: 32px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.tpl-search .ic { width: 14px; height: 14px; color: var(--ink-4); }
.tpl-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 10.5px; }
.tpl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tpl-card { display: flex; flex-direction: column; padding: 16px 17px 14px; background: #fff; border: 1px solid var(--line); border-radius: 13px; box-shadow: var(--shadow); }
.tpl-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.star { border: 0; background: transparent; color: #C4D0E0; padding: 2px; }
.star .ic { width: 16px; height: 16px; }
.star.on { color: #E6A50C; }
.star.on .ic { fill: currentColor; }
.tpl-title { font-size: 12.5px; line-height: 1.5; font-weight: 700; min-height: 38px; }
.tpl-code { font-family: var(--num); font-size: 9.5px; color: var(--ink-4); margin: 4px 0 8px; letter-spacing: .2px; }
.tpl-desc { font-size: 10px; color: var(--ink-3); line-height: 1.7; flex: 1; min-height: 34px; }
.tpl-meta { display: flex; align-items: center; gap: 12px; border-top: 1px solid var(--line-2); padding-top: 9px; margin-top: 10px; font-size: 9px; color: var(--ink-4); }
.tpl-meta span { display: inline-flex; align-items: center; gap: 4px; }
.tpl-meta .ic { width: 12px; height: 12px; }
.tpl-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 9px; font-size: 9.5px; color: var(--ink-4); }
.tpl-foot b { font-family: var(--num); color: var(--ink-2); }

/* ---------- 归档 ---------- */
.archive-banner {
  display: flex; align-items: center; gap: 16px; padding: 15px 18px; margin-bottom: 16px;
  border-radius: 13px; border: 1px solid #F3DDB8; background: linear-gradient(100deg,#FFF9EE,#FFFDF8);
}
.archive-banner-main { display: flex; align-items: flex-start; gap: 10px; flex: 1; min-width: 0; }
.archive-banner-main strong { display: block; font-size: 12.5px; }
.archive-banner-main p { font-size: 9.5px; color: var(--ink-4); margin-top: 4px; }
.archive-progress { width: 250px; flex: none; }
.archive-progress .p-track { height: 7px; }
.archive-progress span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 5px; }
.archive-grid { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }
.volume-list { display: flex; flex-direction: column; gap: 4px; }
.volume { display: flex; align-items: center; gap: 8px; padding: 9px 8px; border-radius: 8px; border: 1px solid transparent; }
.volume:hover { background: #F7FAFE; }
.volume.active { background: #F0F6FF; border-color: #D6E6FB; }
.cbx { width: 14px; height: 14px; border-radius: 4px; border: 1px solid #C9D4E3; background: #fff; flex: none; display: inline-grid; place-items: center; }
.cbx.checked { background: var(--primary); border-color: var(--primary); }
.cbx.checked::after { content: ""; width: 4px; height: 7px; border: solid #fff; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); margin-top: -1px; }
.volume > div { flex: 1; min-width: 0; }
.volume strong { display: block; font-size: 10.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.volume span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 3px; }
.volume .chip { flex: none; }
.dir-wrap { overflow-x: auto; }
.dir-table { width: 100%; border-collapse: collapse; font-size: 10.5px; }
.dir-table th { text-align: left; font-size: 9px; font-weight: 500; color: var(--ink-4); background: #FAFBFD; border-bottom: 1px solid var(--line); padding: 9px 8px; white-space: nowrap; }
.dir-table td { padding: 9px 8px; border-bottom: 1px solid var(--line-2); color: var(--ink-2); }
.dir-table tbody tr[data-row-href] { cursor: pointer; }
.dir-table tbody tr:hover { background: #FAFCFF; }
.dir-table td:first-child { color: var(--ink-4); font-family: var(--num); }
.archive-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.export-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: 10.5px; color: var(--ink-3); }
.export-row:last-of-type { border-bottom: 0; }
.check-line { display: inline-flex; align-items: center; gap: 7px; font-size: 10.5px; color: var(--ink-3); cursor: pointer; }
.check-line .cbx { pointer-events: none; }
.check-line input[type="checkbox"] { display: none; }
.export-actions { display: flex; gap: 8px; margin-top: 13px; }
.export-actions .btn { flex: 1; }
.deliver-form { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.deliver-form .field { margin-bottom: 10px; }
.deliver-form .input, .deliver-form .select { height: 33px; }
.delivery-list { display: flex; flex-direction: column; }
.delivery { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.delivery:last-child { border-bottom: 0; }
.delivery > div { flex: 1; min-width: 0; }
.delivery strong { display: block; font-size: 10.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.delivery span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 3px; }
.delivery .chip { flex: none; }

/* ---------- 工程 ---------- */
.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.project-card { padding: 18px; display: flex; flex-direction: column; }
.project-card.current { border-color: #BBD5F8; box-shadow: 0 0 0 3px rgba(46,116,240,.06), var(--shadow); }
.project-card-top { display: flex; align-items: flex-start; gap: 10px; }
.project-card-title { flex: 1; min-width: 0; }
.project-card-title h3 { font-size: 13px; font-weight: 700; line-height: 1.45; }
.project-card-title span { display: block; font-size: 9.5px; color: var(--ink-4); margin-top: 4px; }
.project-addr { display: flex; align-items: flex-start; gap: 5px; font-size: 9.5px; color: var(--ink-4); margin: 12px 0; line-height: 1.6; }
.project-addr .ic { width: 12px; height: 12px; margin-top: 1px; flex: none; }
.project-progress { display: flex; align-items: center; gap: 8px; }
.project-progress .p-track { flex: 1; }
.project-progress b { font-family: var(--num); font-size: 11px; color: var(--ink-2); }
.project-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 12px 0; padding: 10px 0; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.project-meta b { display: block; font-family: var(--num); font-size: 17px; font-weight: 600; }
.project-meta span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 2px; }
.project-units { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 9.5px; color: var(--ink-4); }
.project-units b { font-weight: 500; color: var(--ink-3); text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-actions { display: flex; gap: 7px; margin-top: 14px; }
.project-actions form { margin: 0; flex: 1; }
.project-actions .btn { width: 100%; }

/* ---------- 团队 ---------- */
.team-layout { display: grid; grid-template-columns: 1.5fr 1fr; gap: 16px; align-items: start; }
.team-side { display: flex; flex-direction: column; gap: 16px; }
.member-list { display: flex; flex-direction: column; }
.member { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px dashed var(--line); }
.member:last-child { border-bottom: 0; }
.member-main { flex: 1; min-width: 0; }
.member-main strong { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; }
.member-main .you { font-style: normal; font-size: 8px; color: var(--primary); background: #EAF2FF; border-radius: 4px; padding: 1px 4px; }
.member-main span { display: block; font-size: 9px; color: var(--ink-4); margin-top: 3px; }
.role-form { margin: 0; }
.role-list { display: flex; flex-direction: column; gap: 10px; }
.role-row { display: flex; align-items: flex-start; gap: 8px; }
.role-row .chip { flex: none; }
.role-row p { font-size: 9.5px; color: var(--ink-4); line-height: 1.6; }
.member-form .field { margin-bottom: 11px; }

/* ---------- 设置 ---------- */
.settings-layout { display: grid; grid-template-columns: 210px 1fr; gap: 16px; align-items: start; }
.settings-nav { padding: 10px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 82px; }
.settings-nav a { display: flex; align-items: center; gap: 9px; height: 38px; padding: 0 11px; border-radius: 8px; font-size: 11.5px; color: var(--ink-3); }
.settings-nav a .ic { width: 15px; height: 15px; color: var(--ink-4); }
.settings-nav a:hover { background: #F7FAFE; }
.settings-nav a.active { background: #EAF2FF; color: var(--primary); font-weight: 600; }
.settings-nav a.active .ic { color: var(--primary); }
.settings-main { min-width: 0; }
.profile-head { display: flex; align-items: center; gap: 13px; padding: 4px 0 18px; margin-bottom: 16px; border-bottom: 1px solid var(--line); }
.profile-head strong { display: block; font-size: 15px; }
.profile-head span { display: block; font-size: 10px; color: var(--ink-4); margin-top: 4px; }
.help-list { display: flex; flex-direction: column; gap: 14px; }
.help-list strong { display: block; font-size: 11.5px; margin-bottom: 4px; }
.help-list p { font-size: 10.5px; color: var(--ink-3); line-height: 1.8; }

/* ---------- 登录 / 安装 ---------- */
.login-body { background: #EDF2F9; }
.login-page { min-height: 100vh; display: grid; grid-template-columns: 1.12fr .88fr; }
.login-brand {
  position: relative; overflow: hidden; display: flex; flex-direction: column;
  padding: 34px 46px; color: #fff;
  background: linear-gradient(145deg, #08172B 0%, #0B2445 52%, #12447F 100%);
}
.login-brand-bg {
  position: absolute; inset: 0; opacity: .5;
  background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse at 60% 40%, #000 20%, transparent 75%);
}
.login-brand-top { position: relative; z-index: 2; display: flex; align-items: center; gap: 10px; }
.login-copy { position: relative; z-index: 2; margin: auto 0; max-width: 560px; }
.login-eyebrow { font-family: var(--num); font-size: 9.5px; letter-spacing: 2.6px; color: #6FA6E8; }
.login-copy h1 { font-size: 39px; line-height: 1.3; letter-spacing: .5px; margin: 15px 0 14px; font-weight: 700; }
.login-copy > p { font-size: 12px; color: #A8C0DD; line-height: 1.9; max-width: 470px; }
.login-features { margin-top: 26px; display: flex; flex-direction: column; gap: 13px; }
.login-features li { display: flex; align-items: center; gap: 9px; font-size: 11.5px; color: #C9DAEF; }
.lf-ic { width: 24px; height: 24px; border-radius: 7px; background: rgba(46,116,240,.18); color: #7BB6FF; display: grid; place-items: center; flex: none; }
.lf-ic svg { width: 14px; height: 14px; }
.login-stats { position: relative; z-index: 2; display: flex; gap: 34px; padding: 18px 0; border-top: 1px solid rgba(255,255,255,.1); }
.login-stats b { display: block; font-family: var(--num); font-size: 20px; font-weight: 600; }
.login-stats span { display: block; font-size: 9px; color: #7896B8; margin-top: 3px; }
.login-brand-foot { position: relative; z-index: 2; font-size: 9.5px; color: #6884A5; }
.login-main { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 24px; }
.login-card { width: 100%; max-width: 420px; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 26px 60px -30px rgba(15,35,65,.25); padding: 31px 32px 24px; }
.login-card-head h2 { font-size: 23px; font-weight: 700; letter-spacing: .2px; }
.login-card-head p { font-size: 11px; color: var(--ink-4); margin-top: 7px; line-height: 1.6; }
.login-mobile-brand { display: none; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 16px; font-weight: 700; }
.login-error { display: flex; align-items: center; gap: 7px; background: var(--red-bg); color: #A62B2B; border: 1px solid #F4CBCB; border-radius: 8px; padding: 9px 11px; font-size: 10.5px; margin-top: 16px; }
.login-error svg { width: 15px; height: 15px; flex: none; }
.login-form { margin-top: 21px; }
.login-field { display: block; margin-bottom: 13px; }
.login-field span { display: block; font-size: 10.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.login-field input { width: 100%; height: 42px; border: 1px solid var(--line); border-radius: 9px; background: #FBFCFE; padding: 0 12px; outline: 0; font-size: 12px; }
.login-field input:focus { border-color: #9CC2F8; background: #fff; box-shadow: 0 0 0 3px rgba(46,116,240,.08); }
.login-options { display: flex; align-items: center; justify-content: space-between; margin: 4px 0 18px; font-size: 10px; }
.login-options a { color: var(--primary); }
.login-card-foot { margin-top: 18px; padding-top: 13px; border-top: 1px solid var(--line-2); font-size: 8.5px; color: var(--ink-4); text-align: center; line-height: 1.7; }
.demo-accounts { margin-top: 20px; padding: 12px; border-radius: 11px; background: #F7F9FC; border: 1px solid var(--line-2); }
.demo-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 9px; }
.demo-title span { font-size: 10px; font-weight: 600; color: var(--ink-2); }
.demo-title em { font-style: normal; font-size: 8.5px; color: var(--ink-4); }
.demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.demo-account { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 7px 8px; border: 1px solid var(--line); border-radius: 7px; background: #fff; text-align: left; }
.demo-account:hover { border-color: #BFD7F8; background: #FAFCFF; }
.demo-account b { font-size: 10px; font-weight: 600; }
.demo-account span { font-size: 8px; color: var(--ink-4); }
.login-main-foot { margin-top: 18px; font-size: 8.5px; color: #98A6B8; text-align: center; }

.install-page { grid-template-columns: .9fr 1.1fr; }
.install-page .login-copy h1 { font-size: 34px; }
.install-steps { margin-top: 28px; display: flex; flex-direction: column; gap: 16px; }
.install-steps li { display: flex; align-items: flex-start; gap: 11px; opacity: .55; }
.install-steps li.active { opacity: 1; }
.install-steps b { font-family: var(--num); font-size: 10px; color: #7BB6FF; border: 1px solid rgba(123,182,255,.35); border-radius: 6px; padding: 3px 6px; }
.install-steps strong { display: block; font-size: 11.5px; font-weight: 600; }
.install-steps span { display: block; font-size: 9.5px; color: #8FA9C8; margin-top: 3px; }
.install-card { max-width: 590px; }
.install-checks { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin-top: 15px; }
.install-check { display: flex; align-items: center; gap: 6px; font-size: 9.5px; color: var(--ink-3); }
.install-check span { width: 15px; height: 15px; border-radius: 50%; display: grid; place-items: center; font-size: 9px; color: #fff; }
.install-check.ok span { background: var(--green); }
.install-check.bad { color: var(--red); }
.install-check.bad span { background: var(--red); }
.install-form { margin-top: 17px; }
.install-form h3 { font-size: 11px; color: var(--ink-2); margin: 15px 0 9px; padding-left: 8px; border-left: 3px solid var(--primary); }
.install-form .form-grid-2 { gap: 9px; }
.install-form .login-field { margin-bottom: 9px; }
.install-form .login-field input { height: 36px; font-size: 11px; }
.install-demo { margin: 10px 0 14px; font-size: 10px; }
.install-demo input { accent-color: var(--primary); }
.install-done { text-align: center; padding: 22px 4px 4px; }
.done-ic { width: 62px; height: 62px; border-radius: 50%; background: var(--green-bg); color: var(--green); display: grid; place-items: center; margin: 0 auto 15px; }
.done-ic svg { width: 30px; height: 30px; }
.install-done h2 { font-size: 22px; }
.install-done > p { font-size: 11px; color: var(--ink-4); line-height: 1.7; margin: 8px 0 18px; }
.install-result { display: flex; align-items: center; justify-content: space-between; padding: 11px 13px; border-radius: 9px; background: #F7F9FC; border: 1px solid var(--line-2); margin-bottom: 16px; font-size: 10.5px; }
.install-result b { font-family: var(--num); color: var(--ink); }
.install-warning { margin-top: 18px; padding: 12px; border-radius: 9px; background: var(--amber-bg); border: 1px solid #F5DDB4; text-align: left; }
.install-warning strong { display: block; font-size: 10.5px; color: #8A5503; margin-bottom: 4px; }
.install-warning p { font-size: 9.5px; color: #8A5503; line-height: 1.7; }

/* ---------- Toast ---------- */
.toast-wrap { position: fixed; z-index: 200; right: 20px; bottom: 22px; display: flex; flex-direction: column; gap: 8px; }
.toast { display: flex; align-items: center; gap: 10px; max-width: 360px; padding: 10px 13px; border-radius: 9px; background: #0F2138; color: #EAF3FF; font-size: 11px; box-shadow: 0 16px 34px -18px rgba(10,27,49,.7); opacity: 0; transform: translateY(8px); transition: .22s; }
.toast.show { opacity: 1; transform: translateY(0); }
.toast button { border: 0; background: transparent; color: #8FA9C8; font-size: 14px; margin-left: 4px; }
.toast.info { background: #0F2138; }

/* ---------- 打印 ---------- */
@media print {
  body { background: #fff; }
  .sidebar, .topbar, .tabbar, .page-head, .doc-side, .flash, .toast-wrap, .sidebar-overlay { display: none !important; }
  .main { width: 100%; margin: 0; }
  .content { padding: 0; overflow: visible; }
  .content-inner { max-width: none; }
  .view-layout { display: block; }
  .paper { border: 0; box-shadow: none; max-width: none; padding: 0; }
  .paper-content { min-height: 0; }
}
.print-mode .sidebar, .print-mode .topbar, .print-mode .tabbar, .print-mode .page-head, .print-mode .doc-side, .print-mode .flash { display: none !important; }
.print-mode .main { width: 100%; margin: 0; }
.print-mode .content { padding: 0; }
.print-mode .paper { border: 0; box-shadow: none; max-width: none; }

/* ---------- 响应式 ---------- */
@media (max-width: 1200px) {
  .top-search { width: 240px; }
  .quick-grid { grid-template-columns: repeat(3, 1fr); }
  .tpl-grid { grid-template-columns: repeat(2, 1fr); }
  .project-grid { grid-template-columns: repeat(2, 1fr); }
  .hero h2 { font-size: 24px; }
}

@media (max-width: 980px) {
  .sidebar { transform: translateX(-102%); transition: transform .24s ease; box-shadow: 0 0 50px rgba(10,27,49,.4); }
  .app.sidebar-open .sidebar { transform: translateX(0); }
  .sidebar-overlay { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(7,18,33,.45); opacity: 0; pointer-events: none; transition: .24s; }
  .app.sidebar-open .sidebar-overlay { opacity: 1; pointer-events: auto; }
  .main { width: 100%; margin-left: 0; }
  .menu-btn { display: inline-grid; }
  .topbar { height: 60px; padding: 0 13px; }
  .page-title h1 { font-size: 16px; }
  .page-title p { max-width: 190px; font-size: 9.5px; }
  .top-search { display: none; }
  .user-trigger-txt { display: none; }
  .hide-sm { display: none; }
  .content { padding: 14px 13px 90px; }
  .tabbar {
    display: flex; position: fixed; z-index: 50; left: 0; right: 0; bottom: 0;
    height: calc(56px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: rgba(255,255,255,.97); border-top: 1px solid var(--line);
    backdrop-filter: blur(14px); box-shadow: 0 -8px 24px -20px rgba(15,35,65,.4);
  }
  .hero { padding: 20px 18px; flex-direction: column; align-items: stretch; gap: 18px; }
  .hero h2 { font-size: 23px; }
  .hero-side { justify-content: space-between; }
  .ring { width: 112px; height: 112px; }
  .ring-inner { width: 88px; height: 88px; }
  .ring-inner b { font-size: 24px; }
  .hero-nums { flex-direction: row; gap: 26px; }
  .kpi-grid, .stat-grid { grid-template-columns: 1fr 1fr; }
  .grid-half, .grid-2-1, .ledger-grid, .archive-bottom, .team-layout, .form-layout, .view-layout, .docs-layout, .archive-grid, .settings-layout { grid-template-columns: 1fr; }
  .tree-card, .settings-nav { position: static; }
  .docs-layout .tree-card { order: 2; }
  .check-grid { grid-template-columns: 1fr; }
  .quick-grid { grid-template-columns: repeat(3, 1fr); }
  .tpl-grid, .project-grid { grid-template-columns: 1fr 1fr; }
  .ai-banner { flex-wrap: wrap; }
  .ai-input { width: 100%; }
  .archive-banner { flex-wrap: wrap; }
  .archive-progress { width: 100%; }
  .page-head { align-items: flex-start; flex-direction: column; gap: 9px; }
  .page-actions { width: 100%; }
  .toolbar { align-items: stretch; }
  .search-inline { width: 100%; }
  .toolbar-right { margin-left: 0; width: 100%; justify-content: space-between; }
  .tabs { padding: 0 10px; }
  .table th, .table td { padding: 10px 8px; }
  .doc-name strong { max-width: 210px; }
  .matrix-hint { display: block; }
  .paper { padding: 24px 18px; }
  .paper-title { font-size: 19px; }
  .paper-meta { font-size: 9px; }
  .paper-meta .lbl { width: 68px; }
  .paper-content { min-height: 180px; font-size: 11px; }
  .paper-sign { grid-template-columns: 1fr; gap: 12px; }
  .paper-sign > div { flex-direction: row; align-items: center; gap: 8px; }
  .paper-sign em { flex: 1; }
  .login-page { grid-template-columns: 1fr; }
  .login-brand { display: none; }
  .login-main { min-height: 100vh; padding: 24px 16px; }
  .login-mobile-brand { display: flex; }
  .login-card { padding: 24px 20px 20px; }
  .install-page .login-brand { display: none; }
}

@media (max-width: 700px) {
  .tabs { padding: 0 6px; gap: 0; }
  .tab { padding: 0 7px; font-size: 10.5px; }
  .tab span { padding: 1px 4px; font-size: 8.5px; }
  .quick-grid { grid-template-columns: 1fr 1fr; }
  .tpl-grid, .project-grid { grid-template-columns: 1fr; }
  .kpi-grid, .stat-grid { gap: 10px; }
  .kpi { padding: 13px; }
  .kpi-num { font-size: 25px; }
  .form-grid-2, .form-grid-3 { grid-template-columns: 1fr; }
  .card { padding: 15px; }
  .docs-card { padding: 0; }
  .matrix-wrap { padding: 0 12px 12px; }
  .matrix { min-width: 0; }
  .matrix th, .matrix td { padding: 6px 3px; }
  .matrix td:first-child { min-width: 66px; font-size: 9.5px; }
  .matrix th:last-child, .matrix td:last-child { display: none; }
  .matrix .cell { width: 24px; height: 24px; border-radius: 6px; }
  .matrix .cell .ic { width: 11px; height: 11px; }
  .legend { gap: 8px; }
  .hero-nums b { font-size: 19px; }
  .hero-nums { gap: 20px; }
  .trend-foot { grid-template-columns: 1fr; gap: 8px; }
  .trend-foot > div { display: flex; align-items: baseline; gap: 7px; }
  .trend-foot b { font-size: 15px; }
  .trend-svg { height: 180px; }
  .card-head { flex-wrap: wrap; }
  .table-foot { flex-direction: column; align-items: flex-start; }
  .pager { flex-wrap: wrap; }
  .doc-table thead { display: none; }
  .doc-table, .doc-table tbody, .doc-table tr, .doc-table td { display: block; width: 100%; }
  .doc-table tr { padding: 11px 13px; border-bottom: 1px solid var(--line); }
  .doc-table tr:hover { background: transparent; }
  .doc-table td { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 0; border: 0; text-align: left; }
  .doc-table td::before { content: attr(data-label); font-size: 9px; color: var(--ink-4); flex: none; }
  .doc-table td:first-child { display: block; padding: 0 0 7px; }
  .doc-table td:first-child::before { display: none; }
  .doc-table td.row-actions { justify-content: flex-end; padding-top: 7px; }
  .doc-table td.row-actions::before { display: none; }
  .doc-table td[data-label="资料名称"] .doc-name { width: 100%; }
  .doc-name strong { max-width: none; white-space: normal; }
  .doc-table td.mono, .doc-table td.muted { justify-content: flex-end; }
  .doc-table td.mono::before, .doc-table td.muted::before { margin-right: auto; }
  .tree-card { order: 0; }
  .archive-banner-main { flex: 1 1 100%; }
  .export-actions { flex-direction: column; }
  .settings-nav { flex-direction: row; overflow-x: auto; }
  .settings-nav a { white-space: nowrap; }
  .toast-wrap { left: 12px; right: 12px; bottom: 12px; }
  .toast { max-width: none; }
}

@media (max-width: 430px) {
  .content { padding-left: 10px; padding-right: 10px; }
  .hero { border-radius: 16px; }
  .hero-actions { flex-wrap: wrap; }
  .hero-side { gap: 12px; }
  .hero-nums { gap: 14px; }
  .hero-nums b { font-size: 17px; }
  .ring { width: 96px; height: 96px; }
  .ring-inner { width: 76px; height: 76px; }
  .ring-inner b { font-size: 21px; }
  .ring-inner span { font-size: 7.5px; }
  .kpi-num { font-size: 23px; }
  .quick-grid { grid-template-columns: 1fr 1fr; }
  .quick > span:last-child { display: none; }
  .topbar { padding: 0 10px; }
  .page-title p { max-width: 150px; }
  .card { border-radius: 13px; }
  .install-checks { grid-template-columns: 1fr; }
}
