:root {
  --bg: #f1f5f9;
  --panel: #ffffff;
  --sidebar: #0f172a;
  --sidebar-2: #1e293b;
  --primary: #2563eb;
  --primary-2: #3b82f6;
  --accent: #06b6d4;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --green: #16a34a;
  --green-bg: #dcfce7;
  --red: #dc2626;
  --red-bg: #fee2e2;
  --amber: #d97706;
  --amber-bg: #fef3c7;
  --blue-bg: #dbeafe;
  --radius: 14px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.08), 0 4px 14px rgba(15, 23, 42, 0.06);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}
.hidden { display: none !important; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 14px; }

/* ---------- 登录页 ---------- */
.login-screen {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  position: relative; padding: 24px; overflow: hidden;
}
.login-bg {
  position: absolute; inset: 0;
  background: radial-gradient(1200px 600px at 20% -10%, #1e3a8a 0%, #0f172a 55%, #020617 100%);
}
.login-bg::after {
  content: ""; position: absolute; inset: 0; opacity: .5;
  background-image: radial-gradient(rgba(59,130,246,.18) 1px, transparent 1px);
  background-size: 28px 28px;
}
.login-card {
  position: relative; z-index: 2; width: 420px; max-width: 100%;
  background: rgba(255,255,255,.98); border-radius: 20px; padding: 36px;
  box-shadow: 0 30px 80px rgba(2,6,23,.55);
}
.login-brand { display: flex; gap: 14px; align-items: center; margin-bottom: 24px; }
.login-brand .logo {
  width: 56px; height: 56px; border-radius: 16px; font-size: 30px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #2563eb, #06b6d4); color: #fff;
  box-shadow: 0 8px 20px rgba(37,99,235,.35);
}
.login-brand h1 { font-size: 20px; font-weight: 700; }
.login-brand p { color: var(--muted); margin-top: 4px; font-size: 13px; }
.login-form label { display: block; margin: 12px 0 6px; font-weight: 600; color: #334155; }
.login-form input {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
  font-size: 15px; outline: none; transition: border .15s, box-shadow .15s;
}
.login-form input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
#login-btn {
  margin-top: 22px; width: 100%; padding: 13px 16px; font-size: 16px; font-weight: 700; letter-spacing: 6px;
  background: linear-gradient(135deg, #2563eb, #06b6d4); border: none; border-radius: 10px; color: #fff;
  box-shadow: 0 8px 20px rgba(37,99,235,.32); transition: transform .15s, box-shadow .15s, background .15s;
}
#login-btn:hover { transform: translateY(-1px); box-shadow: 0 12px 26px rgba(37,99,235,.42); background: linear-gradient(135deg, #1d4ed8, #0891b2); }
#login-btn:active { transform: translateY(0); }
.login-err { color: var(--red); min-height: 18px; margin-top: 10px; font-size: 13px; text-align: center; }
.login-demo { margin-top: 22px; border-top: 1px dashed var(--line); padding-top: 18px; }
.demo-title { font-size: 12px; color: var(--muted); text-align: center; margin-bottom: 12px; }
.demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.demo-chip {
  padding: 11px 8px; border: 1px solid var(--line); background: #fff; border-radius: 10px;
  font-size: 13.5px; font-weight: 600; transition: all .15s;
}
.demo-chip:hover { border-color: var(--primary); background: var(--blue-bg); color: var(--primary); }
.demo-chip.equipment { grid-column: span 2; background: #0f172a; color: #fff; border-color: #0f172a; font-size: 15px; }
.demo-chip.equipment:hover { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ---------- 布局 ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: 236px; background: var(--sidebar); color: #cbd5e1; flex-shrink: 0;
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
}
.side-brand { display: flex; gap: 12px; align-items: center; padding: 20px 18px; border-bottom: 1px solid rgba(255,255,255,.08); }
.side-brand .logo {
  width: 42px; height: 42px; border-radius: 12px; font-size: 22px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}
.side-title { color: #fff; font-weight: 700; font-size: 15px; }
.side-sub { color: #64748b; font-size: 11px; margin-top: 2px; }
.side-nav { flex: 1; padding: 14px 10px; overflow-y: auto; }
.nav-item {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 11px 12px; border-radius: 10px; border: none; background: transparent;
  color: #cbd5e1; font-size: 14px; margin-bottom: 4px; transition: all .15s;
}
.nav-item .nav-ico { font-size: 17px; width: 22px; text-align: center; }
.nav-item:hover { background: var(--sidebar-2); color: #fff; }
.nav-item.active { background: linear-gradient(135deg, #2563eb, #1d4ed8); color: #fff; box-shadow: 0 6px 16px rgba(37,99,235,.35); }
.side-foot { padding: 14px 10px; border-top: 1px solid rgba(255,255,255,.08); }
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 64px; background: var(--panel); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; padding: 0 26px;
  position: sticky; top: 0; z-index: 20;
}
.page-title { font-size: 18px; font-weight: 700; }
.topbar-right { display: flex; align-items: center; gap: 20px; }
.clock { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.user-chip { display: flex; align-items: center; gap: 10px; }
.avatar {
  width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, #2563eb, #06b6d4);
  color: #fff; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 600;
}
.user-name { font-weight: 600; font-size: 14px; }
.user-role { color: var(--muted); font-size: 12px; }
.view { padding: 24px 26px; flex: 1; }

/* ---------- 通用组件 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px; border-radius: 10px; border: 1px solid transparent;
  font-size: 14px; font-weight: 600; transition: all .15s;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: #1d4ed8; }
.btn-ghost { background: transparent; color: #cbd5e1; border-color: transparent; }
.btn-ghost:hover { background: var(--sidebar-2); color: #fff; }
.btn-outline { background: #fff; color: var(--text); border-color: var(--line); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-green { background: var(--green); color: #fff; }
.btn-green:hover { background: #15803d; }
.btn-block { width: 100%; }
.btn-sm { padding: 6px 12px; font-size: 13px; border-radius: 8px; }
.btn-lg { padding: 14px 24px; font-size: 16px; border-radius: 12px; }

.card { background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.card + .card { margin-top: 18px; }
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-title { font-size: 15px; font-weight: 700; }
.card-title .sub { font-weight: 400; color: var(--muted); font-size: 12.5px; margin-left: 8px; }

.grid { display: grid; gap: 18px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 1100px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 700px) { .grid-2, .grid-4 { grid-template-columns: 1fr; } .sidebar { display: none; } }

.stat-card { background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; position: relative; overflow: hidden; }
.stat-card .stat-label { color: var(--muted); font-size: 13px; }
.stat-card .stat-value { font-size: 32px; font-weight: 800; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat-card .stat-ico { position: absolute; right: 14px; top: 14px; font-size: 30px; opacity: .2; }
.stat-card .stat-trend { font-size: 12px; color: var(--muted); margin-top: 6px; }

.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge-available { color: var(--green); background: var(--green-bg); }
.badge-borrowed { color: var(--red); background: var(--red-bg); }
.badge-maintenance { color: var(--amber); background: var(--amber-bg); }
.badge-lost { color: var(--muted); background: #e2e8f0; }
.badge-returned { color: var(--muted); background: #f1f5f9; }
.badge-active { color: var(--red); background: var(--red-bg); }
.badge-admin { color: var(--primary); background: var(--blue-bg); }
.badge-leader { color: #7c3aed; background: #ede9fe; }
.badge-equipment { color: var(--accent); background: #cffafe; }
.badge-reporter { color: #0891b2; background: #cffafe; }
.badge-fixed { color: #7c3aed; background: #ede9fe; }
.badge-circulating { color: #0891b2; background: #cffafe; }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 12px; border-bottom: 1px solid var(--line); font-size: 13.5px; }
th { color: var(--muted); font-weight: 600; font-size: 12.5px; white-space: nowrap; }
tbody tr:hover { background: #f8fafc; }
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar input, .toolbar select {
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; outline: none; background: #fff;
}
.toolbar input:focus, .toolbar select:focus { border-color: var(--primary); }
.toolbar input.search { flex: 1; min-width: 160px; }
.spacer { flex: 1; }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.nowrap { white-space: nowrap; }

/* 分类快捷标签 */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px;
  border: 1px solid var(--line); background: #fff; border-radius: 999px;
  font-size: 13px; font-weight: 600; color: #334155; transition: all .12s;
}
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.chip-n {
  font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 999px;
  background: var(--green-bg); color: var(--green);
}
.chip.active .chip-n { background: rgba(255,255,255,.25); color: #fff; }

/* 分页 */
.pagination {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line);
}
.pg-info { color: var(--muted); font-size: 13px; }
.pg-controls { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pg-btn {
  min-width: 32px; height: 32px; padding: 0 10px; border: 1px solid var(--line); background: #fff;
  border-radius: 8px; font-size: 13px; font-weight: 600; color: #334155; transition: all .12s;
}
.pg-btn:hover:not(:disabled):not(.active) { border-color: var(--primary); color: var(--primary); }
.pg-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.pg-btn:disabled { opacity: .45; cursor: not-allowed; }
.pg-ellipsis { color: var(--muted); padding: 0 2px; }
.pg-size { padding: 7px 8px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; background: #fff; }

/* 图表 */
.donut-wrap { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.legend { display: flex; flex-direction: column; gap: 10px; }
.legend-item { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.legend-dot { width: 11px; height: 11px; border-radius: 3px; }
.legend-item b { margin-left: auto; font-size: 15px; }
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.bar-label { width: 84px; font-size: 12.5px; color: #334155; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { flex: 1; height: 16px; background: #eef2f7; border-radius: 8px; overflow: hidden; display: flex; }
.bar-fill { height: 100%; background: linear-gradient(90deg, #3b82f6, #06b6d4); transition: width .5s; flex-shrink: 0; }
.bar-fill.borrowed { background: linear-gradient(90deg, #f87171, #dc2626); }
.bar-fill.fixed { background: linear-gradient(90deg, #a78bfa, #7c3aed); }
.bar-num { width: 56px; font-size: 12.5px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }

/* 设备列表 */
.device-cat { display: inline-block; font-size: 11px; color: var(--primary); background: var(--blue-bg); padding: 2px 8px; border-radius: 6px; font-weight: 600; }
.actions { display: flex; gap: 6px; }

/* 记者卡片 */
.reporter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.reporter-card { background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; text-align: center; }
.reporter-card .rc-avatar { width: 48px; height: 48px; border-radius: 50%; margin: 0 auto 10px; display: flex; align-items: center; justify-content: center; font-size: 22px; color: #fff; }
.reporter-card .rc-name { font-weight: 700; font-size: 15px; }
.reporter-card .rc-dept { color: var(--muted); font-size: 12.5px; margin: 3px 0 10px; }
.reporter-card .rc-qr { width: 120px; height: 120px; margin: 0 auto 8px; }
.reporter-card .rc-code { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }

/* 二维码大卡 */
.qr-big { text-align: center; }
.qr-big img { width: 200px; height: 200px; border: 1px solid var(--line); border-radius: 12px; padding: 8px; background: #fff; }
.qr-big img.barcode-img { width: 100%; max-width: 360px; height: auto; border: 1px solid var(--line); border-radius: 12px; padding: 10px; background: #fff; }
.qr-big .qr-name { font-size: 18px; font-weight: 700; margin-top: 12px; }
.qr-big .qr-code { color: var(--muted); margin-top: 4px; font-size: 15px; letter-spacing: 1px; }

/* 模态框 */
.modal { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; }
.modal-mask { position: absolute; inset: 0; background: rgba(2,6,23,.5); }
.modal-panel { position: relative; z-index: 2; background: #fff; border-radius: 16px; width: 520px; max-width: calc(100vw - 32px); max-height: 88vh; display: flex; flex-direction: column; box-shadow: 0 30px 80px rgba(2,6,23,.4); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal-title { font-size: 16px; font-weight: 700; }
.modal-close { border: none; background: transparent; font-size: 18px; color: var(--muted); padding: 4px 8px; border-radius: 8px; }
.modal-close:hover { background: #f1f5f9; }
.modal-body { padding: 22px; overflow-y: auto; }
.form-row { margin-bottom: 14px; }
.form-row label { display: block; font-weight: 600; color: #334155; margin-bottom: 6px; font-size: 13px; }
.form-row input, .form-row select, .form-row textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; outline: none; background: #fff;
}
.form-row input:focus, .form-row select:focus, .form-row textarea:focus { border-color: var(--primary); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* 提示 toast */
#toast-wrap { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 10px; }
.toast { padding: 12px 20px; border-radius: 12px; color: #fff; font-weight: 600; box-shadow: 0 10px 30px rgba(2,6,23,.3); animation: slideIn .25s ease; font-size: 14px; }
.toast.success { background: var(--green); }
.toast.error { background: var(--red); }
.toast.info { background: var(--primary); }
@keyframes slideIn { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- 设备室扫码台（老年友好，超大） ---------- */
.scan-station { max-width: 960px; margin: 0 auto; }
.scan-mode { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 22px; }
.scan-mode-btn {
  border: 3px solid var(--line); background: #fff; border-radius: 18px; padding: 30px;
  font-size: 30px; font-weight: 800; display: flex; flex-direction: column; align-items: center; gap: 8px;
  transition: all .15s; color: var(--text);
}
.scan-mode-btn .big-ico { font-size: 54px; }
.scan-mode-btn .mode-hint { font-size: 15px; font-weight: 500; color: var(--muted); }
.scan-mode-btn.borrow { border-color: #93c5fd; }
.scan-mode-btn.borrow:hover, .scan-mode-btn.borrow.selected { background: var(--blue-bg); border-color: var(--primary); }
.scan-mode-btn.return { border-color: #86efac; }
.scan-mode-btn.return:hover, .scan-mode-btn.return.selected { background: var(--green-bg); border-color: var(--green); }

.scan-panel { background: #fff; border-radius: 20px; box-shadow: var(--shadow); padding: 34px; text-align: center; }
.scan-step-badge { display: inline-block; background: var(--primary); color: #fff; font-weight: 700; padding: 6px 18px; border-radius: 999px; font-size: 16px; margin-bottom: 18px; }
.scan-prompt { font-size: 30px; font-weight: 800; margin-bottom: 6px; }
.scan-sub { color: var(--muted); font-size: 16px; margin-bottom: 24px; }
.scan-input {
  width: 100%; max-width: 460px; margin: 0 auto; padding: 18px 20px; font-size: 26px; text-align: center;
  border: 3px dashed var(--primary); border-radius: 14px; outline: none; background: #f8fafc; letter-spacing: 3px;
}
.scan-input:focus { border-style: solid; background: #eff6ff; }
.scan-hint { color: var(--muted); font-size: 14px; margin-top: 16px; }
.scan-slot { display: flex; justify-content: center; gap: 26px; margin-top: 18px; flex-wrap: wrap; }
.scan-slot .slot-card {
  border: 2px solid var(--line); border-radius: 14px; padding: 16px 22px; min-width: 180px;
}
.scan-slot .slot-card.done { border-color: var(--green); background: var(--green-bg); }
.scan-slot .slot-label { font-size: 13px; color: var(--muted); }
.scan-slot .slot-value { font-size: 20px; font-weight: 800; margin-top: 6px; }
.scan-actions { display: flex; gap: 12px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
.scan-actions .btn { padding: 14px 28px; font-size: 18px; border-radius: 12px; }

.scan-result { text-align: center; padding: 24px 0; }
.scan-result .result-ico { font-size: 76px; margin-bottom: 12px; }
.scan-result .result-ok { font-size: 34px; font-weight: 800; color: var(--green); }
.scan-result .result-err { font-size: 30px; font-weight: 800; color: var(--red); }
.scan-result .result-detail { font-size: 18px; margin-top: 12px; color: #334155; line-height: 1.7; }
.scan-result .result-meta { color: var(--muted); font-size: 14px; margin-top: 8px; }

/* 连续扫码（批量借还） */
.scan-reporter-card {
  display: flex; align-items: center; gap: 16px; margin: 18px auto 4px; max-width: 540px;
  background: #eff6ff; border: 2px solid #93c5fd; border-radius: 14px; padding: 14px 18px; text-align: left;
}
.scan-reporter-avatar {
  width: 52px; height: 52px; border-radius: 50%; background: linear-gradient(135deg, #2563eb, #06b6d4);
  color: #fff; font-size: 24px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.scan-reporter-info { flex: 1; min-width: 0; }
.scan-reporter-name { font-size: 22px; font-weight: 800; }
.scan-reporter-code { font-size: 14px; color: var(--muted); margin-top: 2px; }
.scan-count { font-size: 15px; color: #334155; white-space: nowrap; }
.scan-count b { font-size: 28px; color: var(--primary); margin: 0 2px; }

.session-list { max-width: 540px; margin: 8px auto 0; text-align: left; max-height: 230px; overflow-y: auto; }
.session-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px; margin-bottom: 6px;
  background: #f8fafc; border: 1px solid var(--line); border-radius: 10px; font-size: 15px;
}
.session-tag { flex-shrink: 0; font-weight: 800; font-size: 13px; padding: 3px 10px; border-radius: 999px; }
.session-tag.borrow { background: var(--green-bg); color: var(--green); }
.session-tag.return { background: var(--amber-bg); color: var(--amber); }
.session-name { flex: 1; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.session-code { color: var(--muted); font-size: 13px; flex-shrink: 0; }
.scan-count-sub { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }

.scan-notice { max-width: 540px; margin: 14px auto 0; padding: 12px 16px; border-radius: 12px; font-size: 17px; font-weight: 700; }
.scan-notice:empty { display: none; }
.scan-notice.success { background: var(--green-bg); color: var(--green); }
.scan-notice.return { background: var(--amber-bg); color: var(--amber); }
.scan-notice.error { background: var(--red-bg); color: var(--red); }
.scan-notice.info { background: var(--blue-bg); color: var(--primary); }

/* 日报趋势图 */
.trend-chart { display: flex; align-items: flex-end; gap: 14px; height: 190px; padding-top: 12px; }
.trend-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; min-width: 0; }
.trend-bars { flex: 1; width: 100%; display: flex; align-items: flex-end; gap: 4px; justify-content: center; }
.trend-bar { width: 14px; border-radius: 4px 4px 0 0; min-height: 2px; }
.trend-bar.borrow { background: linear-gradient(180deg, #f87171, #dc2626); }
.trend-bar.return { background: linear-gradient(180deg, #4ade80, #16a34a); }
.trend-num { font-size: 11px; color: var(--muted); white-space: nowrap; }
.trend-label { font-size: 12px; color: #334155; }
.trend-label.today { font-weight: 700; color: var(--primary); }

/* 日报打印 */
.print-report { padding: 16px; font-size: 12px; color: #000; }
.print-report h1 { font-size: 20px; text-align: center; margin-bottom: 4px; }
.print-report h2 { font-size: 14px; margin: 14px 0 6px; }
.print-report table { width: 100%; border-collapse: collapse; margin-bottom: 8px; }
.print-report th, .print-report td { border: 1px solid #999; padding: 5px 8px; text-align: left; }
.print-report th { background: #f1f5f9; }
.pr-meta { text-align: center; margin-bottom: 10px; }

/* 打印 */
.print-only { display: none; }
@media print {
  body * { visibility: hidden; }
  #print-area, #print-area * { visibility: visible; }
  #print-area { position: absolute; left: 0; top: 0; width: 100%; display: block !important; }
  .print-label { display: inline-block; width: 46mm; margin: 4mm; text-align: center; page-break-inside: avoid; border: 1px solid #ccc; padding: 3mm; }
  .print-label img { width: 38mm; height: 38mm; }
  .print-label img.barcode { width: 44mm; height: auto; }
  .print-label .pl-name { font-size: 10px; font-weight: 700; margin-top: 1mm; }
  .print-label .pl-code { font-size: 9px; color: #555; }
}
