/* 通用组件规范：尺寸与语义分离，所有输入方式共用状态规则。 */
:root {
    --t-fast: 150ms;
    --t-med: 220ms;
    --ease: cubic-bezier(.2, 0, .2, 1);
    --control-radius: 10px;
    --control-height: 44px;
}
.ui-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: var(--control-height); padding: 10px 18px;
    border: 1px solid var(--line-strong); border-radius: var(--control-radius);
    font-size: 14px; font-weight: 600; line-height: 1.4;
    background: var(--surface-2); color: var(--text-2); box-shadow: none;
    transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.btn-primary { background: var(--primary-600); border-color: var(--primary-600); color: #fff; width: 100%; box-shadow: 0 2px 5px rgb(37 99 235 / 16%); }
.btn-ghost { background: var(--surface); border-color: var(--line-strong); color: var(--text-2); }
.btn-danger { background: var(--danger-50); border-color: #fecaca; color: var(--danger); }
.btn-sm { min-height: 36px; padding: 7px 12px; font-size: 13px; width: auto; border-radius: var(--control-radius); }
.btn-submit { margin-top: 6px; min-height: 48px; font-size: 15px; }
.confirm-btns .btn, .modal-foot .btn { flex: 1 1 0; width: auto; }
/* 页面卡片的操作区自带留白；弹窗由外层面板提供留白。 */
.card > .confirm-btns:last-child { padding: 12px 16px 20px; }
.card > .form-actions:last-child { padding: 0 16px 20px; }
.btn:active:not(:disabled) { transform: scale(.98); }
.btn:disabled { opacity: .55; cursor: not-allowed; box-shadow: none; transform: none; }
.btn.is-busy { position: relative; opacity: 1; color: transparent; pointer-events: none; }
.btn.is-busy svg { visibility: hidden; }
.btn.is-busy::after {
    content: ''; position: absolute; left: calc(50% - 9px); top: calc(50% - 9px);
    width: 18px; height: 18px; border: 2px solid rgb(37 99 235 / 25%); border-top-color: var(--primary-600);
    border-radius: 50%; animation: ui-spin .7s linear infinite;
}
.btn-primary.is-busy::after { border-color: rgb(255 255 255 / 35%); border-top-color: #fff; }
.btn-danger.is-busy::after { border-color: #fecaca; border-top-color: var(--danger); }
@keyframes ui-spin { to { transform: rotate(360deg); } }
:is(.ui-link-btn, .modal-close, .ui-seg-btn, .kb-chip, .cats-tab, .user-avatar) {
    transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
:is(.ui-link-btn, .modal-close, .ui-seg-btn, .kb-chip, .cats-tab, .user-avatar):active:not(:disabled) { transform: scale(.98); }
.modal-close { width: 40px; height: 40px; flex-shrink: 0; }
:is(.shortcut-item, .ui-item, .service-card, .choose-card, .mt-type-card, .mt-room-card) {
    transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
:is(.shortcut-item, .ui-item, .service-card, .choose-card, .mt-type-card, .mt-room-card):active { transform: scale(.98); }
button:focus-visible, a:focus-visible, [role="button"]:focus-visible { outline: 2px solid var(--primary-600); outline-offset: 3px; }
.filter-select:focus, .cu-field select:focus { outline: none; }
.stats-month-select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgb(37 99 235 / 10%); }
.field-error { display: block; margin: 6px 0 0; color: var(--danger); font-size: 12px; line-height: 1.6; }
.ui-action-error { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; margin-bottom: 12px; background: var(--danger-50); border: 1px solid #fecaca; border-radius: var(--control-radius); color: var(--danger); font-size: 13px; line-height: 1.6; }
.ui-action-error .ui-link-btn { flex-shrink: 0; color: var(--danger); }
:is(input, textarea, select)[aria-invalid="true"] { border-color: var(--danger); box-shadow: 0 0 0 2px rgb(220 38 38 / 8%); }
.gs-item.is-selected { background: var(--primary-50); outline: 2px solid var(--primary); outline-offset: -2px; }
.gs-status { padding: 12px 16px; color: var(--text-2); font-size: 13px; }
.gs-status.is-error { color: var(--danger); }
.modal > :is(.modal-sheet, .confirm-sheet, .choose-sheet, .more-sheet) { animation: ui-enter var(--t-med) var(--ease) both; }
.modal.ui-leaving.hidden { display: flex !important; pointer-events: none; }
.modal.ui-leaving > :is(.modal-sheet, .confirm-sheet, .choose-sheet, .more-sheet) { animation: ui-exit 140ms var(--ease) both; }
.modal.ui-leaving .modal-mask { opacity: 0; transition: opacity 140ms var(--ease); }
@keyframes ui-enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes ui-exit { to { opacity: 0; transform: translateY(6px); } }
.input-shake { animation: shake 180ms var(--ease); }
@keyframes shake { 0%, 100% { transform: translateX(0); } 30% { transform: translateX(-3px); } 65% { transform: translateX(3px); } }
@media (hover: hover) and (pointer: fine) {
    .btn:hover:not(:disabled) { background: var(--surface-2); border-color: var(--primary); box-shadow: var(--shadow-sm); }
    .btn-primary:hover:not(:disabled) { background: #1d4ed8; border-color: #1d4ed8; box-shadow: 0 3px 8px rgb(37 99 235 / 20%); }
    .btn-danger:hover:not(:disabled) { background: #fee2e2; border-color: #fca5a5; }
    :is(.shortcut-item, .ui-item, .service-card, .choose-card, .mt-type-card, .mt-room-card):hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
    :is(.shortcut-item, .ui-item, .service-card, .choose-card, .mt-type-card, .mt-room-card):hover:active { transform: scale(.98); }
}
@media (pointer: coarse) {
    :is(.btn, .btn-sm, .ui-link-btn, .modal-close, .ui-seg-btn, .cats-tab) { min-height: 44px; }
    .modal-close { width: 44px; height: 44px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
    :is(.btn, .shortcut-item, .ui-item, .service-card, .choose-card, .mt-type-card, .mt-room-card):is(:hover, :active) { transform: none; }
    .input-shake, .srv-dot, #viewHome .marquee-track { animation: none; transform: none; }
    .btn.is-busy::after { animation: none; }
}
/* 待办导入预览沿用表单留白，标题与描述可在提交前修订。 */
.todo-import-row { padding: 12px 0; border-top: 1px solid var(--line); }
.todo-import-row label { display: block; margin-bottom: 8px; font-size: 13px; }
.todo-import-row input, .todo-import-row textarea, #todoImportCategory { width: 100%; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: var(--control-radius); background: var(--surface-2); }
/* 仅交班时间线：左侧轨迹，右侧独立记录卡片。 */
#todoDetailBody .todo-handoff-timeline { margin: 16px 0 0; padding-left: 4px; }
#todoDetailBody .todo-handoff-entry { padding: 0 0 16px 28px; }
#todoDetailBody .todo-handoff-entry .timeline-content { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow-sm); }
#todoDetailBody .todo-handoff-entry:first-child .timeline-content { border-color: var(--primary-100); background: #f8fbff; }
#todoDetailBody .todo-handoff-entry .timeline-head { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
#todoDetailBody .todo-handoff-entry .timeline-action { font-size: 13px; color: var(--primary-600); }
#todoDetailBody .todo-timeline-person { display: block; font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 10px; }
#todoDetailBody .todo-handoff-entry .timeline-detail { font-size: 13px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 8px; color: var(--text-2); }
#todoDetailBody .todo-handoff-entry .timeline-detail:has(strong) { padding: 8px 10px; background: var(--surface-2); border-radius: 8px; }
.todo-operator-label { display: block; margin-bottom: 10px; font-weight: 600; font-size: 14px; }
.todo-operator-hint { font-size: 12px; color: var(--text-2); margin-top: 8px; }
#todoOperatorChoices input:focus-visible + span { outline: 2px solid var(--primary-600); outline-offset: 3px; }
@media (max-width: 600px) { #todoDetailBody .todo-handoff-entry .timeline-content { padding: 12px; } }
/* 值班室人员名单：独立人员卡片、显式字段标签。 */
.ds-panel-note { margin: 0; padding: 14px 16px 0; color: var(--text-2); font-size: 12px; line-height: 1.7; }
.duty-staff-list { display: grid; gap: 12px; padding: 16px; }
.duty-staff-empty { padding: 28px 16px; border: 1px dashed var(--line-strong); border-radius: 12px; background: var(--surface-2); text-align: center; color: var(--text-2); font-size: 13px; }
.duty-staff-row { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.ds-row-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.ds-index { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--primary-50); color: var(--primary-600); font-size: 12px; font-weight: 600; }
.ds-row-title { font-size: 13px; font-weight: 600; color: var(--text); }
.ds-row-head .ds-del { margin-left: auto; color: var(--danger); }
.ds-fields { display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: 12px; }
.ds-fields label { display: block; color: var(--text-2); font-size: 12px; }
.ds-fields input { display: block; width: 100%; min-width: 0; margin-top: 6px; padding: 10px 12px; height: 42px; border: 1px solid var(--line-strong); border-radius: 9px; background: var(--surface-2); color: var(--text); font-size: 14px; transition: border-color var(--t-fast), box-shadow var(--t-fast); }
.ds-fields input:focus { border-color: var(--primary); background: var(--surface); box-shadow: 0 0 0 3px rgb(37 99 235 / 10%); }
.ds-optional { color: var(--text-3); font-weight: 400; margin-left: 4px; }
@media (max-width: 600px) { .ds-fields { grid-template-columns: repeat(2,minmax(0,1fr)); } .ds-phone-field { grid-column: 1/-1; } .duty-staff-list { padding: 12px 16px; } }
.training-record-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.training-record-grid label,.training-block label,#trainingRecordBody>label { display: block; font-size: 13px; color: var(--text-2); }
#trainingRecordBody input,#trainingRecordBody textarea,#trainingRecordBody select { width: 100%; margin-top: 6px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 9px; background: var(--surface-2); }
#trainingRecordBody .chip input { width: auto; }
.training-wide { grid-column: 1/-1; }
.training-stage { padding: 14px 16px; border: 1px solid var(--primary-100); border-radius: 12px; background: var(--primary-50); }
.training-stage span { display: block; margin-top: 6px; font-size: 12px; }
.training-note,.training-block p { font-size: 12px; line-height: 1.8; color: var(--text-2); margin: 12px 0; }
.training-block { padding: 16px 0; margin: 16px 0; border-top: 1px solid var(--line); }
.training-block h3 { margin: 0 0 12px; font-size: 14px; }
.training-evidence { margin-bottom: 12px; overflow-wrap: anywhere; }
.training-record-actions { flex-wrap: wrap; }
.training-record-actions .btn { flex: 1 1 44%; }
@media(max-width:600px){.training-record-grid { grid-template-columns: 1fr; }}
.training-version { padding: 10px 12px; margin: 10px 0; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-2); font-size: 12px; }
.training-version summary { cursor: pointer; color: var(--primary-600); }
.training-version pre { white-space: pre-wrap; overflow-wrap: anywhere; max-height: 240px; overflow: auto; margin: 8px 0; color: var(--text-2); }
.training-readiness { padding: 12px 14px; margin-bottom: 16px; border: 1px solid var(--line); border-radius: 10px; }
.training-readiness strong { font-size: 13px; }
.training-readiness div { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.training-readiness span { font-size: 12px; color: var(--warning); background: var(--warning-50); padding: 4px 8px; border-radius: 6px; }
.training-readiness span.is-ready { color: var(--success); background: var(--success-50); }
.training-readiness small { color: var(--text-2); }

/* 运行统计：统一数据卡与频次图表，仅影响统计页面 */
#viewStats .dashboard{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;align-items:start}
#viewStats .ui-hero{grid-column:1/-1;background:linear-gradient(115deg,#183b73,#2865b6);padding:28px 32px;box-shadow:0 12px 30px #224f8d20}
#viewStats .ui-hero-num{font-size:64px;font-variant-numeric:tabular-nums}
#viewStats .ui-stat-grid{grid-column:1/-1;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
#viewStats .ui-stat{padding:22px;border-radius:16px;box-shadow:0 4px 18px #193b6710}
#viewStats .ui-stat-num{font-size:36px;font-variant-numeric:tabular-nums}
#viewStats .ui-panel{border-radius:18px;overflow:hidden;width:100%;min-width:0}
#viewStats .ui-panel-body{padding:22px}
#viewStats .ui-panel-head{padding:18px 22px;flex-wrap:wrap;gap:8px}
#viewStats .stats-insight{padding:12px 14px;background:#edf4ff;color:#234d87;border-radius:10px;font-size:13px;line-height:1.6;margin-bottom:20px}
#viewStats .system-ranking{display:grid;gap:18px}
#viewStats .system-row{display:flex;gap:12px;align-items:center}
#viewStats .system-rank{font-size:12px;font-weight:700;border-radius:8px;background:#f0f4fa;color:#64748b;width:26px;height:26px;display:grid;place-items:center;flex-shrink:0}
#viewStats .system-row:first-child .system-rank{background:#e4edff;color:#2563eb}
#viewStats .system-data{flex:1;min-width:0}
#viewStats .system-label{display:flex;justify-content:space-between;gap:8px;font-size:13px;margin-bottom:7px}
#viewStats .system-label b{font-size:18px;font-variant-numeric:tabular-nums}
#viewStats .system-label small{color:#64748b;margin-left:6px}
#viewStats .system-track{height:9px;background:#f0f4fa;border-radius:6px;overflow:hidden}
#viewStats .system-track>div{height:100%;background:var(--system-color);border-radius:6px;transition:width .35s ease}
#viewStats .stats-note{font-size:12px;color:#64748b;line-height:1.8;margin-top:20px}
#viewStats .dept-row{padding:12px 0;border-bottom:1px solid #edf1f7}
#viewStats .dept-bar{background:linear-gradient(90deg,#7fa7ee,#356fce);border-radius:6px}
#viewStats .monthly-chart{display:flex;gap:12px;height:260px;align-items:stretch;overflow-x:auto;padding:8px 0}
#viewStats .monthly-col{display:flex;flex:1;min-width:30px;align-items:center;flex-direction:column;border-radius:8px;gap:8px;padding:4px 0}
#viewStats .monthly-col:hover,#viewStats .monthly-col:focus-visible{background:#edf4ff;outline:2px solid #aac8ff;outline-offset:0}
#viewStats .monthly-track{flex:1;width:60%;display:flex;align-items:flex-end;background:repeating-linear-gradient(to top,transparent 0,transparent 39px,#edf1f7 40px)}
#viewStats .monthly-bar{width:100%;background:linear-gradient(0deg,#abc7f4,#5c8fe3);border-radius:6px 6px 0 0;transition:height .35s ease}
#viewStats .is-selected .monthly-bar{background:linear-gradient(0deg,#2157aa,#347df0)}
#viewStats .monthly-value{font-weight:700;font-size:14px;color:#28456b}
#viewStats .monthly-label{font-size:12px;white-space:nowrap}
#viewStats .monthly-col small{font-size:10px;color:#64748b}
@media(min-width:1024px){#viewStats .ui-stat-grid{grid-column:auto}#viewStats .ui-hero{grid-column:1/-1}}
@media(max-width:700px){#viewStats .dashboard{grid-template-columns:minmax(0,1fr);gap:14px}#viewStats .ui-panel-body{padding:16px}#viewStats .ui-hero{padding:24px}#viewStats .ui-stat{padding:16px}#viewStats .monthly-chart{gap:4px;height:230px}#viewStats .monthly-col{min-width:20px}#viewStats .ui-panel-tag{font-size:11px}}
@media(prefers-reduced-motion:reduce){#viewStats .system-track>div,#viewStats .monthly-bar{transition:none}}

/* 机柜模板导入预览 */
#importModal .imp-room{margin-top:22px;flex-wrap:wrap;gap:8px}
#importModal .imp-target{display:grid;grid-template-columns:100px minmax(0,1fr);align-items:center;gap:12px;margin:12px 0;color:var(--text-2);font-size:13px}
#importModal .imp-target input{width:100%;min-height:44px;border:1px solid var(--line);border-radius:10px;padding:10px 12px;background:var(--surface);color:var(--text)}
#importModal .imp-rack{border:1px solid var(--line);border-radius:10px;margin:8px 0;overflow:hidden}
#importModal .imp-rack summary{padding:12px;cursor:pointer;background:var(--surface-2);font-weight:600}
#importModal .imp-device{display:grid;grid-template-columns:minmax(0,1fr) 80px 35px;align-items:start;gap:8px;padding:10px 0;border-bottom:1px solid var(--line);font-size:12px}
#importModal .imp-device span{overflow-wrap:anywhere}
#importModal .imp-device b{color:var(--primary);text-align:right;white-space:nowrap}
#importModal .imp-device small{text-align:right;color:var(--text-3)}
.r3d-overlay .r3d-btn{min-height:40px;transition:background .15s,border-color .15s,transform .15s}
.r3d-overlay .r3d-btn:active{transform:scale(.97)}
.r3d-overlay button:focus-visible{outline:2px solid #35c8e8;outline-offset:3px}
.r3d-overlay .r3d-devlist{max-height:50vh;overflow-y:auto}
@media(max-width:600px){#importModal .imp-target{grid-template-columns:1fr}.r3d-overlay .r3d-btn{min-height:44px}.r3d-overlay .r3d-panel{width:calc(100% - 24px);max-height:55%;top:auto;bottom:12px}}

/* 交班流程 */
.handover-sheet{max-width:860px}
.handover-notice{background:#edf5ff;border:1px solid #d3e4fa;border-radius:12px;padding:14px 16px;color:#3d5e82;font-size:13px;line-height:1.8;margin-bottom:18px}
.handover-people{display:grid;grid-template-columns:1fr 1fr;gap:16px}
#handoverBody label{display:grid;gap:8px;font-size:13px;color:var(--text-2);margin:12px 0}
#handoverBody select,#handoverBody textarea{width:100%;min-height:44px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--text);font:inherit;box-sizing:border-box}
.handover-muted{font-size:12px;line-height:1.7;color:var(--text-3);overflow-wrap:anywhere}
.handover-counter{position:sticky;top:0;z-index:1;background:#f4f8fd;border:1px solid #dbe7f4;padding:12px 16px;border-radius:10px;font-size:13px;color:#426284;margin:20px 0}
.handover-item{border:1px solid var(--line);border-radius:14px;padding:20px;margin:16px 0;background:var(--surface)}
.handover-item header{display:flex;align-items:start;gap:12px}.handover-item h3{font-size:15px;line-height:1.6;margin:0 0 5px;overflow-wrap:anywhere}.handover-item header small{color:var(--text-3);font-size:12px}
.handover-number{display:grid;place-items:center;width:30px;height:30px;flex-shrink:0;border-radius:9px;background:#eaf2ff;color:#3b70ad;font-weight:600}
.handover-last{background:var(--surface-2);border-radius:9px;padding:12px;margin:12px 0;font-size:12px;line-height:1.8;white-space:pre-wrap;overflow-wrap:anywhere}
.handover-item summary{font-size:12px;color:#587392;cursor:pointer;padding:8px 0}
.handover-warning{color:#a35e15;background:#fff6e8;padding:12px;border-radius:10px;font-size:13px}
.handover-receipt{background:#edf7f3;color:#356a56;padding:22px;border-radius:14px;margin-bottom:20px}.handover-receipt strong{font-size:20px}.handover-receipt p,.handover-receipt small{font-size:12px;line-height:1.8}
.handover-tag{display:inline-block;padding:4px 9px;background:#edf3fa;color:#506d8b;border-radius:7px;font-size:12px}.handover-text{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.8;font-size:13px}
.handover-history-row{display:grid;gap:8px;text-align:left;width:100%;border:1px solid var(--line);background:var(--surface);color:var(--text);padding:18px;border-radius:12px;margin-bottom:12px;cursor:pointer}.handover-history-row span{font-size:12px;color:var(--text-3)}
@media(max-width:600px){.handover-people{grid-template-columns:1fr;gap:0}.handover-item{padding:14px}}

/* 首页版本号下方的交班入口 */
#viewHome .home-shift-entry{position:absolute;top:10px;right:14px;display:flex;flex-direction:column;align-items:flex-end;gap:8px;z-index:1}
#viewHome .home-shift-entry .home-version{position:static}
#viewHome .home-handover-btn{min-height:40px;padding:8px 18px;border:1px solid #ffffff80;background:#ffffffef;color:#376fc0;box-shadow:0 3px 9px #18488a18;font-size:13px}
#viewHome .home-handover-btn:hover{background:#fff;border-color:#fff}
#viewHome .home-hello,#viewHome .home-sub{padding-right:90px}
#handoverModal .modal-head{gap:10px}
#handoverModal #handoverTitle{flex:1;min-width:0}
@media(pointer:coarse){#viewHome .home-handover-btn{min-height:44px}}

/* 首页交班按钮：融入问候卡片 */
#viewHome .home-handover-btn{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:38px;padding:7px 15px;border-radius:999px;border:1px solid rgba(255,255,255,.48);background:rgba(255,255,255,.16);color:#fff;box-shadow:inset 0 1px 0 rgba(255,255,255,.14),0 3px 9px rgba(30,64,175,.08);backdrop-filter:blur(10px);font-size:13px;font-weight:600;letter-spacing:1px;transition:background .16s,border-color .16s,box-shadow .16s,transform .12s}
#viewHome .home-handover-btn svg{width:17px;height:17px;flex-shrink:0}
@media(hover:hover){#viewHome .home-handover-btn:hover{background:rgba(255,255,255,.28);border-color:rgba(255,255,255,.8);box-shadow:inset 0 1px 0 rgba(255,255,255,.22),0 5px 12px rgba(30,64,175,.12);transform:translateY(-1px)}}
#viewHome .home-handover-btn:active{transform:scale(.96);background:rgba(255,255,255,.33)}
#viewHome .home-handover-btn:focus-visible{outline:2px solid #fff;outline-offset:3px}
@media(pointer:coarse){#viewHome .home-handover-btn{min-height:44px;padding:9px 15px}}
@media(prefers-reduced-motion:reduce){#viewHome .home-handover-btn{transition:none}}
#viewHome .home-shift-entry{top:8px;gap:5px}
#viewHome .home-greeting:has(.home-handover-btn:not(.hidden)){min-height:82px}

/* 交班分步填写：保留输入节点，返回上一步不会丢失填写。 */
#handoverBasics[hidden],#handoverReview[hidden],#handoverItems .handover-item[hidden],#handoverFoot button[hidden]{display:none!important}
#handoverItems .handover-item{margin-top:16px}
.handover-review-card{border:1px solid var(--line);border-radius:12px;padding:20px;margin-top:14px;background:var(--surface)}
.handover-review-card header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
#handoverCounter{padding:12px 16px;border-radius:9px;background:#f1f6fc;color:#526b85;margin:16px 0;font-size:13px}
#handoverFoot{gap:10px;padding:20px}#handoverRefresh{margin-right:auto}
@media(max-width:600px){#handoverFoot{flex-wrap:wrap}#handoverRefresh{font-size:12px}.handover-review-card{padding:16px}}

#handoverBody .handover-important{display:flex;align-items:center;gap:10px;padding:12px;background:#fff8e6;border-radius:9px;color:#8a5a13}#handoverBody .handover-important input{width:18px;height:18px;flex:0 0 auto}.handover-priority{display:inline-block;background:#fff0cc;color:#8a5a13;border-radius:5px;padding:3px 7px;font-size:12px;margin-right:6px}#handoverAccount{margin-top:8px;margin-bottom:8px}
/* 培训结束后的材料上传与归档 */
#trainingRecordBody .te-evidence-row{display:grid;grid-template-columns:minmax(0,1fr) 130px auto;align-items:center;gap:16px;padding:14px 16px;margin:10px 0;border:1px solid var(--line);border-radius:10px;background:var(--surface)}
.te-evidence-row a{display:block;font-size:14px;line-height:1.6;overflow-wrap:anywhere;color:var(--primary)}
.te-evidence-row small{display:block;margin-top:5px;color:var(--text-3);font-size:12px}
#trainingRecordBody .te-evidence-row select{margin:0;min-height:44px}
#trainingRecordBody .te-upload-tools{display:flex;align-items:flex-end;flex-wrap:wrap;gap:14px;margin-top:18px;padding:18px;border-radius:10px;background:var(--surface-2)}
#trainingRecordBody .te-upload-tools>label:first-child{min-width:150px}
#trainingRecordBody .te-upload-tools select{background:var(--surface);height:44px}
#trainingRecordBody .te-upload-button{position:relative;display:flex;align-items:center;justify-content:center;min-height:44px;padding:10px 20px;margin:0;border-radius:9px;background:var(--primary);color:#fff;cursor:pointer;overflow:hidden}
#trainingRecordBody .te-upload-button input{position:absolute;inset:0;opacity:0;margin:0;cursor:pointer}
#trainingRecordBody .te-upload-button:focus-within{outline:3px solid var(--primary-100);outline-offset:3px}
#teUploadStatus{width:100%;font-size:12px;line-height:1.7;color:var(--text-2)}
.te-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.training-history>summary{font-size:14px;font-weight:600;cursor:pointer;padding:6px 0}
#trainingCorrectionModal{z-index:2000}
#trainingCorrectionModal .te-reason-sheet{max-width:520px}
#trainingCorrectionModal .modal-body p{font-size:14px;line-height:1.8;color:var(--text-2);margin:0 0 20px}
#trainingCorrectionModal label{display:grid;gap:10px;font-size:14px}
#trainingCorrectionModal textarea{width:100%;padding:12px;border:1px solid var(--line-strong);border-radius:9px;font:inherit;resize:vertical}
#trainingCorrectionModal .te-reason-error{color:#c24134;margin:10px 0 0}
#trainingCorrectionModal .modal-foot{display:flex;justify-content:flex-end;gap:12px}
@media(max-width:600px){#trainingRecordBody .te-evidence-row{grid-template-columns:minmax(0,1fr) auto;gap:12px}#trainingRecordBody .te-evidence-row>div{grid-column:1/-1}#trainingRecordBody .te-upload-tools>label:first-child{flex:1}#trainingRecordBody .te-upload-button{flex:1;white-space:nowrap}}
.training-readiness{margin:16px 0 22px;padding:16px;border:1px solid var(--line);border-radius:10px;background:var(--surface-2)}
.training-readiness>strong{display:block;font-size:14px;margin-bottom:12px;color:var(--text)}
.training-readiness>div{display:flex;flex-wrap:wrap;gap:8px}
.training-readiness span{padding:5px 9px;border-radius:6px;background:#fff1dd;color:#94611a;font-size:12px;line-height:1.6}
.training-readiness .is-ready{background:#e4f4ea;color:#287449}
#trainingRecordBody .te-upload-tools[hidden]{display:none!important}
