:root {
  --primary: #0f6fbd;
  --primary-dark: #0b5590;
  --primary-light: #e8f3fc;
  --success: #17915c;
  --warn: #c8811a;
  --danger: #c0392b;
  --bg: #f4f7fa;
  --card: #ffffff;
  --border: #e2e8f0;
  --text: #1f2937;
  --muted: #6b7280;
  --radius: 10px;
  --shadow: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", system-ui, sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--primary); text-decoration: none; }
button { font-family: inherit; }

/* ---------- 布局 ---------- */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 216px; background: #fff; border-right: 1px solid var(--border);
  display: flex; flex-direction: column; position: fixed; top: 0; bottom: 0; left: 0; z-index: 30;
}
.sidebar .brand {
  padding: 16px 18px; border-bottom: 1px solid var(--border); display: flex; gap: 10px; align-items: center;
}
.brand .logo {
  width: 34px; height: 34px; border-radius: 8px; background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px;
}
.brand .t1 { font-weight: 700; font-size: 14px; }
.brand .t2 { font-size: 11px; color: var(--muted); }
.nav { flex: 1; overflow-y: auto; padding: 8px 0 20px; }
.nav-group { padding: 12px 18px 4px; font-size: 11px; color: var(--muted); letter-spacing: .5px; }
.nav-item {
  display: flex; align-items: center; gap: 9px; padding: 9px 18px; cursor: pointer;
  color: var(--text); border-left: 3px solid transparent; font-size: 13.5px;
}
.nav-item:hover { background: var(--primary-light); }
.nav-item.active { background: var(--primary-light); border-left-color: var(--primary); color: var(--primary-dark); font-weight: 600; }
.nav-item .ico { width: 18px; text-align: center; }
.nav-parent { margin: 0; }
.nav-parent-row {
  display: flex; align-items: center; gap: 9px; padding: 9px 18px; cursor: pointer;
  color: var(--text); border-left: 3px solid transparent; font-size: 13.5px; user-select: none;
}
.nav-parent-row:hover { background: var(--primary-light); }
.nav-parent-row .caret {
  margin-left: auto; font-size: 10px; color: var(--muted); transition: transform .18s; transform: rotate(0deg);
}
.nav-parent.open > .nav-parent-row .caret { transform: rotate(90deg); }
.nav-parent.open > .nav-parent-row { color: var(--primary-dark); font-weight: 600; border-left-color: var(--primary); background: var(--primary-light); }
.nav-sub { display: none; }
.nav-parent.open > .nav-sub { display: block; }
.nav-sub .nav-item { padding-left: 40px; font-size: 13px; }
.nav-sub .nav-item .ico { width: 16px; }
.nav-item .badge {
  margin-left: auto; background: var(--danger); color: #fff; border-radius: 9px;
  font-size: 11px; padding: 0 6px; min-width: 18px; text-align: center;
}
.main { flex: 1; margin-left: 216px; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 56px; background: #fff; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 20px; gap: 12px; position: sticky; top: 0; z-index: 20;
}
.topbar h1 { font-size: 17px; margin: 0; font-weight: 700; }
.topbar .spacer { flex: 1; }
.user-chip {
  display: flex; align-items: center; gap: 8px; padding: 5px 10px; background: var(--bg);
  border-radius: 20px; font-size: 13px;
}
.user-chip .role { color: var(--primary); font-weight: 600; }
.content { padding: 18px 20px 40px; }

/* ---------- 组件 ---------- */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card + .card { margin-top: 16px; }
.pad { padding: 16px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.toolbar .grow { flex: 1; min-width: 120px; }

.btn {
  border: 1px solid var(--border); background: #fff; color: var(--text);
  padding: 7px 13px; border-radius: 7px; cursor: pointer; font-size: 13.5px;
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
}
.btn:hover { border-color: var(--primary); color: var(--primary); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-dark); color: #fff; }
.btn.danger { color: var(--danger); border-color: #f0c9c4; }
.btn.danger:hover { background: #fdf1ef; color: var(--danger); border-color: var(--danger); }
.btn.sm { padding: 4px 9px; font-size: 12.5px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

input, select, textarea {
  border: 1px solid var(--border); border-radius: 7px; padding: 7px 10px; font-size: 13.5px;
  font-family: inherit; background: #fff; color: var(--text); width: 100%; outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15, 111, 189, .1); }
textarea { resize: vertical; min-height: 68px; }
label.fl { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 4px; }
label.fl .req { color: var(--danger); }

table.grid { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.grid th, table.grid td { padding: 9px 10px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
table.grid th { background: #fafbfc; font-weight: 600; color: var(--muted); font-size: 12.5px; white-space: nowrap; }
table.grid tbody tr:hover { background: #fafdff; }
table.grid td.nowrap { white-space: nowrap; }
.table-wrap { overflow-x: auto; }

.tag { display: inline-block; padding: 1px 8px; border-radius: 11px; font-size: 12px; border: 1px solid transparent; }
.tag.approved { background: #e7f6ee; color: var(--success); border-color: #bfe5d2; }
.tag.submitted { background: #fff5e6; color: var(--warn); border-color: #f3ddb8; }
.tag.rejected { background: #fdeceb; color: var(--danger); border-color: #f5cdc9; }
.tag.draft { background: #eef1f5; color: var(--muted); border-color: #dde3ea; }
.tag.cancelled { background: #f1f3f5; color: #6b7280; border-color: #dde3ea; text-decoration: line-through; }
.tag.info { background: var(--primary-light); color: var(--primary-dark); border-color: #c8e2f7; }
.cb { display: inline-flex; align-items: center; gap: 2px; margin: 0 4px; font-size: 12.5px; white-space: nowrap; cursor: pointer; }
.cb input { margin: 0 2px 0 0; }
.ms-box { display: flex; flex-wrap: wrap; gap: 4px 6px; padding: 6px 0; }
.area-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.area-row { display: flex; gap: 8px; align-items: center; }
.area-row .area-in { flex: 1; }

.empty { padding: 40px 16px; text-align: center; color: var(--muted); }
.empty .big { font-size: 30px; margin-bottom: 8px; opacity: .5; }

.modal-mask {
  position: fixed; inset: 0; background: rgba(17, 24, 39, .45); display: flex;
  align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; z-index: 100;
}
.modal {
  background: #fff; border-radius: 12px; width: 100%; max-width: 720px; box-shadow: 0 20px 40px rgba(0, 0, 0, .18);
}
.modal .head { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; }
.modal .head h3 { margin: 0; font-size: 16px; }
.modal .body { padding: 16px 18px; }
.modal .foot { padding: 12px 18px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 8px; }
.grid-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }
.grid-form .full { grid-column: 1 / -1; }

.toast {
  position: fixed; left: 50%; top: 20px; transform: translateX(-50%); z-index: 300;
  background: rgba(24, 32, 44, .94); color: #fff; padding: 9px 18px; border-radius: 8px; font-size: 13.5px;
}
.toast.err { background: var(--danger); }
.toast.ok { background: var(--success); }

/* ---------- 统计卡 ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.stat {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px;
}
.stat .v { font-size: 24px; font-weight: 700; color: var(--primary-dark); }
.stat .l { font-size: 12.5px; color: var(--muted); }
.stat.alert .v { color: var(--danger); }

/* ---------- 扫码 ---------- */
.qr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.qr-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; text-align: center; }
.qr-card img { width: 168px; height: 168px; image-rendering: pixelated; }
.qr-card .t { font-weight: 600; margin-bottom: 2px; }
.qr-card .d { font-size: 12px; color: var(--muted); margin-bottom: 8px; }

/* ---------- 登录页 ---------- */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-box { width: 100%; max-width: 380px; }
.login-box .card { padding: 26px 24px; }
.login-box h2 { margin: 0 0 4px; font-size: 19px; }
.login-box .sub { color: var(--muted); font-size: 13px; margin-bottom: 20px; }
.login-box .field { margin-bottom: 13px; }
.login-foot { margin-top: 14px; font-size: 12.5px; color: var(--muted); text-align: center; line-height: 1.8; }
/* 外来人员登记入口：醒目按钮，引导访客免登录登记 */
.login-foot .guest-entry {
  display: block; margin-top: 14px; padding: 14px 16px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff !important; font-size: 16px; font-weight: 700;
  text-align: center; border-radius: 10px; text-decoration: none;
  box-shadow: 0 4px 14px rgba(239, 68, 68, .35);
}
.login-foot .guest-entry:hover { filter: brightness(1.06); }

/* ---------- 外来人员登记 ----------
   面向外来/年长访客：整体放大字号、输入框与点击区域，避免看不清、点不准 */
.guest-wrap { max-width: 720px; margin: 0 auto; padding: 20px 16px 40px; }
.guest-head { text-align: center; padding: 18px 0 8px; }
.guest-head h2 { margin: 0 0 6px; font-size: 27px; letter-spacing: 1px; }
.guest-head p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.6; }
.guest-wrap .grid-form { gap: 14px 16px; }
.guest-wrap label.fl { font-size: 16.5px; font-weight: 700; color: #243044; margin-bottom: 6px; }
/* 姓名、所在单位等关键栏目更醒目 */
.guest-wrap label.fl.key { font-size: 18px; color: var(--primary-dark); }
.guest-wrap label.fl.key::before {
  content: ''; display: inline-block; width: 5px; height: 17px; margin-right: 7px;
  background: var(--primary); border-radius: 3px; vertical-align: -2px;
}
.guest-wrap label.fl .req { font-size: 15px; }
.guest-wrap input, .guest-wrap select, .guest-wrap textarea { font-size: 17px; padding: 11px 12px; border-radius: 9px; }
.guest-wrap textarea { min-height: 78px; }
.guest-wrap .card.pad { padding: 18px 18px 20px; }
.guest-wrap .btn { font-size: 17px; padding: 12px 16px; border-radius: 9px; }
.guest-wrap .cb {
  font-size: 16.5px; margin: 0 10px 8px 0; padding: 7px 12px; gap: 6px;
  border: 1px solid var(--border); border-radius: 9px; background: #fafbfc; white-space: nowrap;
}
.guest-wrap .cb input { width: 18px; height: 18px; margin: 0; }
.guest-wrap .ms-box { padding: 8px 0; gap: 0; }
.guest-wrap .ms-hint { font-size: 15px; color: var(--muted); }
.guest-wrap .form-tip { font-size: 14px; line-height: 1.7; }
.guest-wrap #outList div { font-size: 16px; }
@media (max-width: 520px) {
  .guest-head h2 { font-size: 22px; }
  .guest-wrap .btn { font-size: 16px; }
}

/* ---------- 移动端 ---------- */
.menu-toggle { display: none; }
@media (max-width: 860px) {
  .sidebar { transform: translateX(-100%); transition: transform .22s; width: 250px; }
  .sidebar.open { transform: none; box-shadow: 6px 0 24px rgba(0, 0, 0, .14); }
  .main { margin-left: 0; }
  .menu-toggle { display: inline-flex; }
  .grid-form { grid-template-columns: 1fr; }
  .content { padding: 14px 12px 40px; }
  .topbar { padding: 0 12px; }
  .topbar h1 { font-size: 15.5px; }
  table.grid th, table.grid td { padding: 8px 8px; font-size: 13px; }
  .modal-mask { padding: 12px 8px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 420px) {
  .user-chip .name { display: none; }
}

/* ---------- 体系文件：目录树 + PDF 导入 + 文件浏览 ---------- */
.docs-wrap { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 14px; align-items: start; }
@media (max-width: 900px) { .docs-wrap { grid-template-columns: 1fr; } }
.docs-tree { position: sticky; top: 8px; max-height: calc(100vh - 140px); overflow-y: auto; }
.docs-main { min-width: 0; }
.sec-label { font-size: 11px; color: var(--muted); letter-spacing: .5px; padding-bottom: 6px; }
.tree-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 7px 10px; border-radius: 7px; cursor: pointer; font-size: 13.5px; color: var(--text);
}
.tree-item:hover { background: #f1f5f9; }
.tree-item.active { background: var(--primary-light); color: var(--primary-dark); font-weight: 600; }
.tree-item.lv2 { font-weight: 500; }
.tree-item.lv3 { padding-left: 24px; font-size: 13px; color: #45505f; }
/* 目录里的档案条目（PDF 原件） */
.tree-item.lv-doc {
  padding-left: 26px; font-size: 12.5px; color: #374151; justify-content: flex-start;
}
.tree-item.lv-doc .ti-ico { font-size: 12px; opacity: .8; }
.tree-item.lv-doc .ti-txt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 虚拟三级子模块 = PDF 自带书签（只显示、不入库、可点着跳页） */
.tree-item.lv-bm {
  padding-left: 42px; font-size: 12px; color: #55606f; justify-content: flex-start;
  padding-top: 4px; padding-bottom: 4px;
}
.tree-item.lv-bm.bm2 { padding-left: 56px; }
.tree-item.lv-bm.bm3 { padding-left: 70px; font-size: 11.5px; color: #6b7280; }
.tree-item.lv-bm .ti-txt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-item.lv-bm .bm-pg {
  margin-left: auto; font-size: 10.5px; color: var(--muted);
  background: #f1f5f9; border-radius: 8px; padding: 0 6px; flex: none;
}
.tree-item.lv-bm.muted { color: var(--muted); font-size: 11.5px; cursor: default; }
.tree-item.lv-bm.muted:hover { background: transparent; }
.tree-item .cnt {
  font-size: 11px; color: var(--muted); background: #f1f5f9; border-radius: 9px;
  padding: 1px 7px; margin-left: auto;
}
.tree-item.active .cnt { background: #fff; color: var(--primary-dark); }
.tree-add {
  font-size: 12px; color: var(--muted); padding: 2px 10px 8px 24px; cursor: pointer;
}
.tree-add:hover { color: var(--primary); }

.doc-head { border-bottom: 1px solid var(--border); padding-bottom: 12px; }
.doc-title-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.doc-title-row h3 { margin: 0; font-size: 16px; font-weight: 600; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 8px; font-size: 12.5px; color: var(--muted); }
.doc-ops { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.doc-body { padding-top: 6px; }
.doc-note { color: var(--muted); font-size: 12.5px; line-height: 1.8; padding: 8px 2px; }
.doc-tip { color: #6b7280; font-size: 12.5px; line-height: 1.7; }
.file-card {
  display: flex; align-items: center; gap: 10px; margin-bottom: 10px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: #f8fafc;
}
.file-card .fc-ico { font-size: 20px; }
.file-card .fc-name { font-size: 13.5px; font-weight: 600; }
.file-card .fc-size { font-size: 11.5px; color: var(--muted); margin-left: 6px; }
.file-card .grow { flex: 1; }

/* ---------- 在线阅读：Word 页面 ---------- */
.docs-main.reading { display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.wv-head { padding: 14px 16px 12px; border-bottom: 1px solid var(--border); }
.wv-note { padding: 10px 16px; font-size: 12.5px; color: #92400e; background: #fffbeb; border-bottom: 1px solid var(--border); }
.wv-scroll { flex: 1; overflow-y: auto; background: #eef1f5; padding: 18px; max-height: calc(100vh - 230px); }
/*
 * 阅读区 · 总原则：
 *   本模块只在线呈现 PDF 原件 —— 版式、页眉页脚、分页与页码全部由原件自己决定，
 *   CSS 只负责外壳（滚动背景、卡片、内嵌阅读器尺寸），绝不二次排版。
 */
.wv-paper {
  margin: 0 auto; background: #fff; padding: 12px;
  box-shadow: 0 1px 5px rgba(15, 23, 42, .14); border-radius: 2px;
  width: 100%; max-width: 980px; box-sizing: border-box;
}
/* PDF 内嵌阅读器：撑满阅读区，高度跟着滚动容器走 */
.wv-paper .wv-pdf {
  display: block; width: 100%; height: calc(100vh - 300px); min-height: 480px;
  border: 0; background: #f1f5f9; border-radius: 2px;
}
.wv-pdf-tip { margin-top: 8px; color: #6b7280; font-size: 12.5px; line-height: 1.7; }
@media (max-width: 900px) {
  .wv-paper { padding: 8px; }
  .wv-paper .wv-pdf { height: 70vh; min-height: 360px; }
}

.dm-head { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.dm-list { max-height: 52vh; overflow-y: auto; border: 1px solid var(--border); border-radius: 8px; }
.dm-row {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  border-bottom: 1px solid var(--border); font-size: 13.5px;
}
.dm-row:last-child { border-bottom: none; }
.dm-row.lv3 { background: #fafbfc; padding-left: 28px; }
.dm-name { flex: 1; }
.dm-cnt { font-size: 12px; color: var(--muted); min-width: 66px; text-align: right; }
.dm-ops { display: flex; gap: 6px; }

/* ---------- 排班考勤：两周动态排班表 ---------- */
.sched-tabs { display: flex; gap: 6px; margin-bottom: 12px; }
.sched-tab {
  padding: 7px 16px; border-radius: 8px; cursor: pointer; font-size: 13.5px;
  background: #fff; border: 1px solid var(--border); color: #45505f;
}
.sched-tab:hover { background: #f1f5f9; }
.sched-tab.active { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }

.sched-status {
  margin: 0 0 10px; font-size: 12.5px; color: var(--muted);
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.sched-scroll { overflow-x: auto; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.sched-tbl { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 12.5px; }
.sched-tbl th, .sched-tbl td { border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.sched-tbl thead th { background: #f4f7fa; padding: 6px 4px; font-weight: 600; color: #374151; }
.sched-nm {
  position: sticky; left: 0; z-index: 3; background: #fff !important;
  min-width: 118px; max-width: 148px; text-align: left; padding: 7px 9px !important;
  box-shadow: 2px 0 0 rgba(0, 0, 0, .05);
}
.sched-tbl thead .sched-nm { z-index: 4; background: #f4f7fa !important; }
.sched-nm .nm { font-weight: 600; font-size: 13.5px; color: var(--text); }
.sched-nm .sub { font-size: 11px; color: var(--muted); margin-top: 2px; }
.sched-nm .hint { font-size: 10.5px; color: #9aa3af; font-weight: 400; margin-top: 3px; }
.sched-flag {
  display: inline-block; margin-left: 5px; padding: 0 5px; border-radius: 8px; font-size: 10px;
  background: var(--primary-light); color: var(--primary-dark); font-weight: 500; vertical-align: 1px;
}
.rowops { margin-top: 4px; display: flex; gap: 4px; }
.rowops .mini {
  border: 1px solid var(--border); background: #fff; border-radius: 5px; cursor: pointer;
  font-size: 11px; padding: 1px 6px; color: #5b6675; line-height: 1.6;
}
.rowops .mini:hover { background: var(--primary-light); color: var(--primary-dark); border-color: var(--primary); }

.sched-day { min-width: 62px; text-align: center; cursor: default; }
.sched-day .dd { font-size: 13px; font-weight: 600; }
.sched-day .ww { font-size: 11px; color: var(--muted); font-weight: 400; margin-top: 1px; }
/* 医疗机构执行轮换休：周末与节假日不做特殊底色标记，仅保留当天标记便于定位 */
.sched-day.today { background: #e8f1ff !important; }
.sched-day.today .dd { color: var(--primary-dark); }
.sched-cell.today { box-shadow: inset 0 0 0 1.5px #bfd6f7; }

.sched-cell {
  min-width: 62px; text-align: center; padding: 5px 3px !important; vertical-align: middle;
  cursor: default; position: relative; height: 46px;
}
.sched-cell.clickable:hover, .sched-cell:hover { background: #f2f7ff; }
.sched-cell .sh {
  display: inline-block; border-radius: 5px; padding: 1px 7px; font-weight: 600;
  font-size: 12.5px; line-height: 1.7; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sched-cell .tm { font-size: 10.5px; color: #6b7280; margin-top: 2px; white-space: nowrap; }
/* 作息季节角标：夏 / 冬 */
.sched-cell .tm .rz, .print-doc .tm .rz { display: inline-block; margin-left: 4px; padding: 0 4px; border-radius: 4px; font-size: 9.5px; font-weight: 700; vertical-align: middle; }
.sched-cell .tm .rz { background: #e0f2fe; color: #0369a1; }
.print-doc .tm .rz { background: #dbeafe; color: #1d4ed8; }
.rz-sel { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: #374151; }
.rz-sel select { padding: 5px 6px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.sched-cell .nt { font-size: 10px; color: #9aa3af; margin-top: 1px; max-width: 62px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sched-cell .ph { color: transparent; font-size: 15px; }
.sched-cell:hover .ph { color: #c3ccd8; }
.sched-cell .stwrap { position: absolute; top: 2px; right: 3px; display: flex; gap: 2px; z-index: 2; }
.sched-cell .st {
  font-size: 9px; font-style: normal;
  border-radius: 6px; padding: 0 4px; line-height: 1.5; font-weight: 600;
}
.sched-cell .st.ok { background: #dcfce7; color: #15803d; }
.sched-cell .st.ap { background: #dbeafe; color: #1d4ed8; }
.sched-cell .st.wait { background: #fef3c7; color: #b45309; }
.sched-cell .st.no { background: #fee2e2; color: #b91c1c; }
.sched-cell .st.sub { background: #e5e7eb; color: #6b7280; }
/* ---------- 换班 / 顶班：班次格左下角标记 ---------- */
.sched-cell.has-swap { padding-bottom: 15px !important; }
.sched-cell .swwrap { position: absolute; left: 3px; bottom: 2px; z-index: 2; line-height: 1; }
.sched-cell .sw {
  font-size: 9.5px; font-style: normal; border-radius: 6px; padding: 0 4px;
  line-height: 1.55; font-weight: 700; display: inline-block;
}
.sched-cell .sw.swap { background: #f3e8ff; color: #7e22ce; }
.sched-cell .sw.cover { background: #ffedd5; color: #c2410c; }
.sched-legend .lg .sw { font-style: normal; border-radius: 6px; padding: 0 5px; font-size: 10px; font-weight: 700; margin: 0 1px; }
.sched-legend .lg .sw.swap { background: #f3e8ff; color: #7e22ce; }
.sched-legend .lg .sw.cover { background: #ffedd5; color: #c2410c; }
.sched-sum { min-width: 58px; text-align: center; font-weight: 600; color: #374151; background: #fafbfc; }
.sched-tbl tbody tr.dragging { opacity: .45; background: #eef4ff; }
.sched-tbl tbody tr:hover td { background: #fafcfd; }
.sched-tbl tbody tr:hover .sched-nm { background: #f2f7ff !important; }

.sched-legend { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.sched-legend .lg-t { font-size: 12px; color: var(--muted); margin-bottom: 7px; font-weight: 600; }
.sched-legend .lg-wrap { display: flex; flex-wrap: wrap; gap: 7px; }
.sched-legend .lg {
  border-radius: 6px; padding: 3px 9px; font-size: 12px; line-height: 1.8; white-space: nowrap;
}
.sched-legend .lg b { font-weight: 600; }
.sched-legend .lg i { font-style: normal; color: #b91c1c; font-size: 11px; }
.sched-legend .lg .st { font-style: normal; border-radius: 6px; padding: 0 5px; font-size: 10px; font-weight: 600; margin: 0 1px; }
.sched-legend .lg .st.ok { background: #dcfce7; color: #15803d; }
.sched-legend .lg .st.ap { background: #dbeafe; color: #1d4ed8; }
.sched-legend .lg .st.wait { background: #fef3c7; color: #b45309; }
.sched-legend .lg .st.no { background: #fee2e2; color: #b91c1c; }
.sched-legend .lg .st.sub { background: #e5e7eb; color: #6b7280; }

/* ---------- 排班考勤角标 ---------- */
.sched-cell .stwrap { position: absolute; top: 2px; right: 3px; display: flex; gap: 2px; z-index: 2; }

/* ---------- 提交审核 / 审核：自选日期与人员 ---------- */
.sc-hint {
  grid-column: 1 / -1; font-size: 12.5px; color: #4b5563; line-height: 1.7;
  background: #f6f9fc; border: 1px solid #e3ebf3; border-radius: 8px; padding: 8px 10px;
}
.fl .sc-quick { float: right; display: flex; gap: 6px; font-weight: 400; }
.sc-quick .lq {
  cursor: pointer; font-size: 12px; color: #1d4ed8; background: #eef4ff;
  border-radius: 6px; padding: 1px 7px; user-select: none;
}
.sc-quick .lq:hover { background: #dbe7ff; }
.sc-box {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 6px;
  max-height: 168px; overflow-y: auto; padding: 8px;
  border: 1px solid var(--border); border-radius: 8px; background: #fbfcfe;
}
.sc-box .cb {
  display: flex; align-items: center; gap: 6px; font-size: 12.5px; cursor: pointer;
  padding: 5px 7px; border: 1px solid var(--border); border-radius: 6px; background: #fff;
}
.sc-box .cb.on { border-color: #93b4ff; background: #eef4ff; color: #1d4ed8; }
.sc-box .cb .d { font-weight: 600; }
.sc-box .cb .w { color: #6b7280; font-size: 11.5px; }
.sc-sum { font-size: 12.5px; color: #374151; background: #f6f9fc; border-radius: 8px; padding: 8px 10px; }
.sc-sum b { color: #1d4ed8; }

/* 单日 / 单格快捷操作菜单 */
.sc-menu { display: flex; flex-direction: column; gap: 6px; }
.sc-mi {
  cursor: pointer; font-size: 13px; padding: 9px 12px; border: 1px solid var(--border);
  border-radius: 8px; background: #fff; transition: all .12s;
}
.sc-mi:hover { border-color: #93b4ff; background: #eef4ff; color: #1d4ed8; }
.sc-mi .mu { color: #9aa3af; font-size: 12px; }

/* ---------- 换班记录 ---------- */
.swap-form .swap-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.swap-tip {
  font-size: 12.5px; color: #6b7280; line-height: 1.8; background: #f6f9fc;
  border: 1px solid #e3ebf3; border-radius: 8px; padding: 8px 10px; margin-bottom: 10px;
}


/* ---------- 大类入口页（container）的子记录本卡片 ---------- */
.mod-card {
  cursor: pointer; width: 232px; padding: 14px 14px 12px; background: #fff;
  border: 1px solid var(--border); border-radius: 10px; transition: all .12s;
}
.mod-card:hover { border-color: #93b4ff; background: #f7faff; box-shadow: 0 2px 8px rgba(29,78,216,.08); }
.mod-card .mod-ico { font-size: 24px; line-height: 1; }
.mod-card .mod-name { font-weight: 600; font-size: 14.5px; margin-top: 8px; color: #1f2937; }
.mod-card .mod-desc { font-size: 12.5px; color: #6b7280; line-height: 1.7; margin-top: 5px; min-height: 42px; }
.mod-card .mod-num { font-size: 12px; color: #1d4ed8; margin-top: 6px; }

/* ---------- 技能考核评分表（人员×月度测评矩阵） ---------- */
table.mx { border-collapse: collapse; min-width: 980px; }
table.mx th, table.mx td { border: 1px solid #d7dde5; padding: 6px 8px; text-align: center; font-size: 13px; }
table.mx thead th { background: #eef7ee; color: #14532d; font-weight: 600; white-space: nowrap; }
table.mx thead th.now { background: #d5efda; }
table.mx td.mx-name { text-align: left; white-space: nowrap; min-width: 110px; background: #fafcfa; }
table.mx td.mx-cell { min-width: 64px; height: 32px; }
table.mx td.mx-cell.edit { cursor: pointer; }
table.mx td.mx-cell.edit:hover { background: #f2f8ff; box-shadow: inset 0 0 0 1px #93b4ff; }
table.mx td.mx-cell.miss { color: #dc2626; font-weight: 600; }
table.mx td.mx-total { font-weight: 600; background: #fafcfa; }
table.mx td.mx-deduct { color: #dc2626; font-size: 11.5px; font-weight: 600; }
table.mx td.mx-total.neg { color: #dc2626; }
