/* ============================================================
   HealthExamKiosk 管理后台 — 完全自实现，不依赖 Bootstrap
   改风格：只需修改 :root 里的 token
   ============================================================ */

/* ── Token ──────────────────────────────────────────────────*/
:root {
    /* 品牌色 */
    --c-primary:      #12284C;
    --c-accent:       #3B9EFF;
    --c-accent-light: #EEF5FF;

    /* 语义色 */
    --c-success:      #00A870;  --c-success-light: #E6F9F1;
    --c-warning:      #E07B00;  --c-warning-light: #FFF3E0;
    --c-danger:       #D84040;  --c-danger-light:  #FFECEC;
    --c-purple:       #7B6FE8;  --c-purple-light:  #F0EEFF;

    /* 文字 */
    --c-text:         #1C2537;
    --c-text-2:       #5A6478;
    --c-text-3:       #8B92A5;
    --c-text-4:       #B0B7C3;

    /* 背景 */
    --c-bg:           #F0F2F5;
    --c-surface:      #ffffff;
    --c-surface-2:    #F8F9FB;

    /* 边框 */
    --c-border:       #EEF0F4;
    --c-border-2:     #DDE1EA;

    /* 侧边栏（深色独立） */
    --sb-bg:          #0f2240;
    --sb-hover:       rgba(255,255,255,.07);
    --sb-active:      rgba(255,255,255,.13);
    --sb-text:        rgba(255,255,255,.55);
    --sb-text-on:     #fff;
    --sb-divider:     rgba(255,255,255,.08);
    --sb-label:       rgba(255,255,255,.35);
    --sb-indicator:   #3B9EFF;
    --sb-badge:       #D84040;
    --sb-online:      #00D084;
    --sb-w:           236px;
    --sb-w-collapsed: 64px;

    /* 尺寸 */
    --topbar-h:  48px;
    --r-xs:  3px;
    --r-sm:  5px;
    --r-md:  8px;
    --r-lg:  10px;
    --r-xl:  14px;
    --r-pill:999px;

    /* 阴影 */
    --shadow:     0 1px 4px rgba(0,0,0,.07), 0 1px 10px rgba(0,0,0,.04);
    --shadow-lg:  0 4px 20px rgba(0,0,0,.13);

    /* 字体 */
    --font:      'Segoe UI','PingFang SC','Microsoft YaHei',sans-serif;
    --font-mono: 'Consolas','SFMono-Regular',monospace;

    /* 动效 */
    --t: .15s ease;

    /* 旧页面兼容别名：逐步迁移到 --c-* token，避免局部页面颜色失效 */
    --primary:        var(--c-accent);
    --danger:         var(--c-danger);
    --success:        var(--c-success);
    --border:         var(--c-border);
    --bg-card:        var(--c-surface);
    --text-hint:      var(--c-text-3);
    --text-secondary: var(--c-text-2);
}

/* ── Dark Mode ──────────────────────────────────────────────*/
[data-theme="dark"] {
    --c-accent-light:   rgba(59,158,255,.15);
    --c-success-light:  rgba(0,168,112,.15);
    --c-warning-light:  rgba(224,123,0,.15);
    --c-danger-light:   rgba(216,64,64,.15);
    --c-purple-light:   rgba(123,111,232,.15);

    --c-text:           #d4e0ef;
    --c-text-2:         #7d97b8;
    --c-text-3:         #526a88;
    --c-border-2:       #1e3050;
    --c-text-4:         #344f6a;

    /* 蓝调深色，与侧边栏 #0f2240 同色系 */
    --c-bg:             #0a1628;
    --c-surface:        #0f1f36;
    --c-surface-2:      #152540;

    --c-border:         #1a2e48;

    --shadow:           0 1px 4px rgba(0,0,0,.5), 0 1px 10px rgba(0,0,0,.3);
    --shadow-lg:        0 4px 24px rgba(0,0,0,.6);
}

/* ── Reset ──────────────────────────────────────────────────*/
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body {
    font-family: var(--font);
    font-size: .9286rem;   /* 13px */
    color: var(--c-text);
    background: var(--c-bg);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}
a { color: var(--c-accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
button { font-family: var(--font); cursor: pointer; }
input, select, textarea { font-family: var(--font); }
table { border-collapse: collapse; }

/* ── 布局 ──────────────────────────────────────────────────*/
.layout { display: flex; min-height: 100vh; }

/* ── 侧边栏 ─────────────────────────────────────────────────*/
.sidebar {
    width: var(--sb-w); background: var(--sb-bg);
    display: flex; flex-direction: column;
    position: fixed; top: 0; left: 0; height: 100vh;
    z-index: 100; overflow-y: auto; scrollbar-width: none;
    transition: width var(--t), transform var(--t);
}
.sidebar::-webkit-scrollbar { display: none; }

.sb-logo {
    padding: 22px 18px 18px;
    border-bottom: 1px solid var(--sb-divider);
    flex-shrink: 0;
}
.sb-logo .brand {
    color: var(--sb-text-on); font-size: 14px; font-weight: 700;
    letter-spacing: .2px; line-height: 1.3;
}
.sb-logo .brand-sub {
    color: var(--sb-label); font-size: 11px; margin-top: 5px;
    display: flex; align-items: center; gap: 5px;
}
.sb-online-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--sb-online); flex-shrink: 0;
    box-shadow: 0 0 0 2px rgba(0,208,132,.25);
}

/* ── 分区 ── */
.sb-section { padding: 20px 0 6px; }
.sb-section + .sb-section { border-top: 1px solid var(--sb-divider); }

.sb-section-label {
    display: block;
    color: rgba(255,255,255,.75); font-size: 12px; font-weight: 600;
    letter-spacing: .2px;
    padding: 0 14px 8px;
}
.sb-section-toggle {
    width: calc(100% - 20px);
    margin: 0 10px 6px;
    padding: 0 4px;
    border: none;
    background: transparent;
    color: rgba(255,255,255,.75);
    display: flex; align-items: center; justify-content: space-between;
    font-size: 12px; font-weight: 600;
    letter-spacing: .2px;
    line-height: 22px;
    text-align: left;
    border-radius: var(--r-sm);
    transition: color var(--t), background var(--t);
}
.sb-section-toggle:hover {
    color: var(--sb-text-on);
    background: rgba(255,255,255,.04);
}
.sb-section-toggle:focus { outline: none; }
.sb-section-toggle:focus-visible {
    box-shadow: 0 0 0 2px rgba(59,158,255,.32);
}
.sb-section-arrow {
    width: 12px; height: 12px;
    opacity: .65;
    transition: transform var(--t), opacity var(--t);
}
.sb-section.is-collapsed .sb-section-arrow {
    transform: rotate(-90deg);
}
.sidebar.sidebar-collapsible .sb-section.is-collapsed > .sb-item {
    display: none;
}

/* ── 菜单项（pill 风格） ── */
.sb-item {
    display: flex; align-items: center; gap: 9px;
    margin: 1px 10px; padding: 8px 10px;
    border-radius: var(--r-md);
    color: var(--sb-text);
    transition: background var(--t), color var(--t);
    font-size: 13px; font-weight: 400;
    text-decoration: none; user-select: none;
    position: relative;
    min-height: 34px;
}
.sb-item:hover {
    background: var(--sb-hover);
    color: rgba(255,255,255,.9);
    text-decoration: none;
}
.sb-item.active {
    background: var(--sb-active);
    color: var(--sb-text-on);
    font-weight: 500;
}
.sb-item.active::before {
    content: ''; position: absolute;
    left: 0; top: 50%; transform: translateY(-50%);
    height: 16px; width: 3px;
    background: var(--sb-indicator);
    border-radius: 0 3px 3px 0;
}
.sb-icon {
    width: 15px; height: 15px; opacity: .5;
    flex-shrink: 0; transition: opacity var(--t);
}
.sb-item:hover .sb-icon  { opacity: .8; }
.sb-item.active .sb-icon { opacity: 1; }

.sb-badge {
    margin-left: auto;
    background: var(--sb-badge); color: #fff;
    font-size: 10px; font-weight: 700;
    min-width: 18px; padding: 1px 5px;
    border-radius: var(--r-pill); line-height: 1.7;
    text-align: center; display: none;
}
.sb-badge.visible { display: inline-block; }

/* ── 用户区 ── */
.sb-user {
    margin-top: auto; padding: 12px 14px;
    border-top: 1px solid var(--sb-divider);
    display: flex; align-items: center; gap: 10px; flex-shrink: 0;
}
.sb-avatar {
    width: 34px; height: 34px; border-radius: var(--r-md);
    background: linear-gradient(135deg, var(--c-accent) 0%, #1a6fd4 100%);
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 13px; font-weight: 700; flex-shrink: 0;
}
.sb-user-name { color: var(--sb-text-on); font-size: 12px; font-weight: 600; }
.sb-user-role {
    color: var(--sb-label); font-size: 10px; margin-top: 2px;
    text-transform: uppercase; letter-spacing: .5px;
}

/* ── 管理员侧边栏收缩态 ───────────────────────────────────── */
.admin-sidebar-collapsed .sidebar.sidebar-collapsible {
    width: var(--sb-w-collapsed);
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-logo {
    padding: 16px 12px;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-logo .brand {
    width: 40px; height: 40px;
    border-radius: var(--r-md);
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,.08);
    font-size: 0;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-logo .brand::before {
    content: "驾";
    font-size: 15px; font-weight: 700;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-logo .brand-sub {
    justify-content: center;
    margin-top: 8px;
    font-size: 0;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section {
    padding: 10px 0 4px;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section-label {
    height: 1px;
    margin: 4px 18px 6px;
    padding: 0;
    overflow: hidden;
    background: var(--sb-divider);
    font-size: 0;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section-toggle {
    height: 1px;
    margin: 4px 18px 6px;
    padding: 0;
    overflow: hidden;
    background: var(--sb-divider);
    font-size: 0;
    pointer-events: none;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section-toggle span,
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section-arrow {
    display: none;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-item {
    justify-content: center;
    gap: 0;
    margin: 2px 10px;
    padding: 9px 0;
    font-size: 0 !important;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-section.is-collapsed > .sb-item {
    display: flex;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-icon {
    width: 17px; height: 17px;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-badge {
    position: absolute;
    top: 5px; right: 6px;
    min-width: 15px;
    height: 15px;
    padding: 0 4px;
    font-size: 9px;
    line-height: 15px;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-user {
    justify-content: center;
    padding: 12px 0;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-avatar {
    width: 34px; height: 34px;
}
.admin-sidebar-collapsed .sidebar.sidebar-collapsible .sb-user > div:not(.sb-avatar) {
    display: none;
}

/* ── 主区域 ─────────────────────────────────────────────────*/
.main {
    flex: 1; margin-left: var(--sb-w);
    display: flex; flex-direction: column; min-height: 100vh;
    min-width: 0;
    transition: margin-left var(--t);
}
.admin-sidebar-collapsed .layout-sidebar-collapsible .main {
    margin-left: var(--sb-w-collapsed);
}

.topbar {
    background: var(--c-surface);
    height: var(--topbar-h); padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
    border-bottom: 1px solid var(--c-border);
    position: sticky; top: 0; z-index: 90;
}
.topbar-left {
    display: flex; align-items: center; gap: 10px;
    min-width: 0;
}
.topbar-icon-btn {
    width: 30px; height: 30px;
    border: 1px solid var(--c-border);
    border-radius: var(--r-md);
    background: var(--c-surface);
    color: var(--c-text-3);
    display: inline-flex; align-items: center; justify-content: center;
    transition: background var(--t), border-color var(--t), color var(--t);
}
.topbar-icon-btn:hover {
    background: var(--c-surface-2);
    color: var(--c-text-2);
    border-color: var(--c-border-2);
}
.topbar-icon-btn:focus { outline: none; }
.topbar-icon-btn:focus-visible {
    border-color: var(--c-accent);
    box-shadow: 0 0 0 3px rgba(59,158,255,.16);
}
.mobile-sidebar-btn { display: none; }
.sidebar-toggle-btn .icon-expand { display: none; }
.admin-sidebar-collapsed .sidebar-toggle-btn .icon-collapse { display: none; }
.admin-sidebar-collapsed .sidebar-toggle-btn .icon-expand { display: block; }
.topbar-crumb {
    display: flex; align-items: center; gap: 6px;
    font-size: 12px; color: var(--c-text-3);
    min-width: 0;
}
.topbar-crumb .sep { opacity: .4; }
.topbar-crumb .cur { color: var(--c-text); font-weight: 500; }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.topbar-date {
    background: var(--c-accent-light); color: var(--c-accent);
    font-size: 11px; padding: 3px 10px; border-radius: var(--r-pill);
}

/* 用户下拉 */
.user-menu { position: relative; }
.user-menu-btn {
    display: flex; align-items: center; gap: 6px;
    background: none; border: 1px solid var(--c-border-2);
    border-radius: var(--r-md); padding: 5px 10px;
    font-size: 12px; color: var(--c-text-2);
    transition: background var(--t);
}
.user-menu-btn:hover { background: var(--c-surface-2); }
.user-dropdown {
    display: none; position: absolute; right: 0; top: calc(100% + 6px);
    background: var(--c-surface); border: 1px solid var(--c-border);
    border-radius: var(--r-lg); box-shadow: var(--shadow-lg);
    min-width: 140px; overflow: hidden; z-index: 200;
}
.user-dropdown.open { display: block; }
.user-dropdown-item {
    display: block; padding: 9px 14px; font-size: 12px;
    color: var(--c-text-2); transition: background var(--t);
}
.user-dropdown-item:hover { background: var(--c-surface-2); text-decoration: none; }
.user-dropdown-item.danger { color: var(--c-danger); }
.user-dropdown-divider { border: none; border-top: 1px solid var(--c-border); margin: 3px 0; }

.page-body { padding: 22px 24px; flex: 1; min-width: 0; }

/* ── Grid ───────────────────────────────────────────────────*/
.row { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.row > * { padding: 0 8px; }
.row.g-2 { margin: 0 -6px; gap: 0; }
.row.g-2 > * { padding: 0 6px; margin-bottom: 12px; }
.row.g-3 { margin: 0 -8px; }
.row.g-3 > * { padding: 0 8px; margin-bottom: 16px; }
.row.g-4 { margin: 0 -10px; }
.row.g-4 > * { padding: 0 10px; margin-bottom: 20px; }
.col    { flex: 1 1 0; min-width: 0; }
.col-12 { width: 100%; }
.col-6  { width: 50%; }
.col-4  { width: 33.333%; }
.col-3  { width: 25%; }
@media (min-width: 576px) {
    .col-sm-6  { width: 50%; }
}
@media (min-width: 768px) {
    .col-md-2  { width: 16.667%; }
    .col-md-3  { width: 25%; }
    .col-md-4  { width: 33.333%; }
    .col-md-6  { width: 50%; }
}
@media (min-width: 992px) {
    .col-lg-3  { width: 25%; }
    .col-lg-4  { width: 33.333%; }
    .col-lg-5  { width: 41.667%; }
    .col-lg-7  { width: 58.333%; }
}
@media (min-width: 1200px) {
    .col-xl-3  { width: 25%; }
    .col-xl-4  { width: 33.333%; }
    .col-xl-6  { width: 50%; }
    .col-xl-8  { width: 66.667%; }
}

/* ── Flex 工具 ──────────────────────────────────────────────*/
.flex        { display: flex; }
.flex-col    { display: flex; flex-direction: column; }
.items-center{ align-items: center; }
.items-start { align-items: flex-start; }
.items-end   { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center  { justify-content: center; }
.justify-end     { justify-content: flex-end; }
.flex-wrap   { flex-wrap: wrap; }
.flex-1      { flex: 1; }
.flex-shrink-0 { flex-shrink: 0; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.ml-auto { margin-left: auto; }

/* ── Spacing 工具 ───────────────────────────────────────────*/
.mt-1{margin-top:4px}  .mt-2{margin-top:8px}  .mt-3{margin-top:12px} .mt-4{margin-top:16px}
.mb-1{margin-bottom:4px}.mb-2{margin-bottom:8px}.mb-3{margin-bottom:12px}.mb-4{margin-bottom:20px}
.ml-1{margin-left:4px} .ml-2{margin-left:8px}  .mr-1{margin-right:4px}.mr-2{margin-right:8px}
.px-3{padding-left:12px;padding-right:12px}
.py-2{padding-top:8px;padding-bottom:8px}
.py-4{padding-top:20px;padding-bottom:20px}
.p-0{padding:0}

/* ── 显示工具 ───────────────────────────────────────────────*/
.hidden  { display: none !important; }
.block   { display: block; }
.w-full  { width: 100%; }
.h-full  { height: 100%; }
.min-h-screen { min-height: 100vh; }

/* ── 文字工具 ───────────────────────────────────────────────*/
.text-xs    { font-size: 11px; }
.text-sm    { font-size: 12px; }
.text-base  { font-size: 13px; }
.text-lg    { font-size: 16px; }
.text-xl    { font-size: 20px; }
.text-2xl   { font-size: 26px; }
.font-medium{ font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold  { font-weight: 700; }
.font-mono  { font-family: var(--font-mono); }
.text-center{ text-align: center; }
.truncate   { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

.text-primary { color: var(--c-text) !important; }
.text-2      { color: var(--c-text-2) !important; }
.text-muted  { color: var(--c-text-3) !important; }
.text-accent { color: var(--c-accent) !important; }
.text-success{ color: var(--c-success) !important; }
.text-warning{ color: var(--c-warning) !important; }
.text-danger { color: var(--c-danger) !important; }

/* ── 卡片 ───────────────────────────────────────────────────*/
.card {
    background: var(--c-surface);
    border-radius: var(--r-lg);
    border: 1px solid var(--c-border);
    box-shadow: var(--shadow);
    min-width: 0;
}
.card-header {
    padding: 14px 18px 12px;
    border-bottom: 1px solid var(--c-border);
    display: flex; align-items: center; justify-content: space-between;
}
.card-title  { font-size: 13px; font-weight: 600; }
.card-body   { padding: 18px; }
.card-flush  { padding: 0; }           /* 表格贴边用 */
.card-footer {
    padding: 12px 18px;
    border-top: 1px solid var(--c-border);
    display: flex; justify-content: center;
}
.card-pad { padding: 16px; }
.card-table-title {
    padding: 12px 16px;
    border-bottom: 1px solid var(--c-border);
    font-size: 13px;
    color: var(--c-text-3);
}

/* ── 列表筛选 / 经营指标 ───────────────────────────────────*/
.filter-card { padding: 16px; margin-bottom: 16px; }
.filter-row {
    display: flex; flex-wrap: wrap; gap: 12px;
    align-items: flex-end;
}
.filter-field {
    margin: 0;
    min-width: 140px;
}
.filter-field.wide { min-width: 160px; }
.filter-submit { height: 36px; }
.metric-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}
.metric-card {
    padding: 16px;
    text-align: center;
}
.metric-label {
    font-size: 12px;
    color: var(--c-text-3);
}
.metric-value {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.2;
}
.metric-value.primary { color: var(--c-accent); }
.metric-value.success { color: var(--c-success); }
.metric-value.danger  { color: var(--c-danger); }
.chart-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}
.chart-grid > .card,
.metric-grid > .card {
    min-width: 0;
}
.chart-title {
    font-weight: 600;
    margin-bottom: 12px;
}
.empty-panel {
    background: var(--c-surface);
    border: 1px solid var(--c-border);
    color: var(--c-text-3);
    text-align: center;
    padding: 40px;
}
.async-list {
    position: relative;
}
/* 切筛选/翻页时旧列表柔和变淡(140ms)，让用户感知"点击已响应" */
.async-list > * {
    transition: opacity 140ms ease;
}
.async-list.is-loading {
    min-height: 120px;
}
.async-list.is-loading > * {
    opacity: .48;
    pointer-events: none;
}
/* "加载中"遮罩常驻+透明，靠 opacity 淡入淡出(伪元素 content 切换本身无法过渡) */
.async-list::after {
    content: "加载中...";
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--c-text-2);
    font-size: 13px;
    font-weight: 600;
    background: rgba(255,255,255,.58);
    backdrop-filter: blur(1px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 140ms ease;
}
.async-list.is-loading::after {
    opacity: 1;
}
[data-theme="dark"] .async-list::after {
    background: rgba(15,23,42,.52);
}
.review-overview {
    display: flex;
    align-items: stretch;
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--c-border);
    border-radius: var(--r-md);
    background: linear-gradient(180deg, var(--c-surface), var(--c-surface-2));
    box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 22px rgba(15, 23, 42, .05);
}
.review-overview-block {
    display: flex;
    align-items: center;
    min-width: 0;
    padding: 12px 14px;
}
.review-overview-work {
    flex: 1 1 330px;
    gap: 12px;
}
.review-overview-todo {
    flex: 1.6 1 520px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}
.review-overview-divider {
    width: 1px;
    margin: 12px 0;
    background: var(--c-border);
    flex-shrink: 0;
}
.review-overview-icon,
.review-todo-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.review-overview-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--r-md);
    color: var(--c-success);
    background: var(--c-success-light);
    border: 1px solid rgba(0, 168, 112, .16);
}
.review-overview-icon svg { width: 22px; height: 22px; }
.review-overview-main {
    min-width: 76px;
}
.review-overview-label,
.review-todo-label {
    display: block;
    color: var(--c-text-3);
    font-size: 11px;
    line-height: 1.2;
    white-space: nowrap;
}
.review-overview-value {
    display: block;
    color: var(--c-text);
    font-size: 25px;
    line-height: 1.05;
    margin-top: 3px;
}
.review-overview-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 0;
}
.review-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 7px;
    border-radius: var(--r-sm);
    font-size: 11px;
    line-height: 1;
    white-space: nowrap;
}
.review-chip strong { font-size: 12px; }
.review-chip.is-success { color: #005C3D; background: var(--c-success-light); }
.review-chip.is-danger  { color: #8B1A1A; background: var(--c-danger-light); }
.review-chip.is-warning { color: #7A4400; background: var(--c-warning-light); }
.review-todo-item {
    display: grid;
    grid-template-columns: 25px minmax(54px, 1fr) auto;
    align-items: center;
    gap: 7px;
    min-width: 0;
    padding: 8px 9px;
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    background: rgba(255,255,255,.66);
    color: var(--c-text);
    text-decoration: none;
}
.review-todo-item:hover {
    text-decoration: none;
    border-color: var(--c-border-2);
    background: var(--c-surface);
}
.review-todo-item.is-hot {
    background: var(--c-danger-light);
    border-color: rgba(216, 64, 64, .18);
}
.review-todo-item.is-hot .review-todo-value {
    color: var(--c-danger);
}
.review-todo-icon {
    width: 25px;
    height: 25px;
    border-radius: var(--r-sm);
    background: var(--c-surface-2);
}
.review-todo-icon svg { width: 16px; height: 16px; }
.review-todo-icon.is-pending   { color: var(--c-warning); background: var(--c-warning-light); }
.review-todo-icon.is-reviewing { color: var(--c-accent);  background: var(--c-accent-light); }
.review-todo-icon.is-risk,
.review-todo-icon.is-failed    { color: var(--c-danger);  background: var(--c-danger-light); }
.review-todo-value {
    justify-self: end;
    color: var(--c-text);
    font-size: 18px;
    line-height: 1;
}
[data-theme="dark"] .review-overview {
    background: linear-gradient(180deg, var(--c-surface), rgba(21, 37, 64, .72));
    box-shadow: 0 1px 2px rgba(0,0,0,.22), 0 8px 22px rgba(0,0,0,.18);
}
[data-theme="dark"] .review-todo-item {
    background: rgba(255,255,255,.03);
}
[data-theme="dark"] .review-todo-item:hover {
    background: rgba(255,255,255,.05);
}
.inline-refund-form {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: nowrap;
}
.inline-refund-input {
    width: 130px;
}

/* ── 统计卡片 ────────────────────────────────────────────────*/
.stat-card {
    background: var(--c-surface);
    border-radius: var(--r-lg); border: 1px solid var(--c-border);
    box-shadow: var(--shadow); padding: 16px 18px;
    border-top: 3px solid var(--c-border-2);   /* 默认无彩色，子类覆盖 */
}
.stat-card.blue   { border-top-color: var(--c-accent); }
.stat-card.green  { border-top-color: var(--c-success); }
.stat-card.orange { border-top-color: var(--c-warning); }
.stat-card.purple { border-top-color: var(--c-purple); }
.stat-card.red    { border-top-color: var(--c-danger); }
.stat-label  { font-size: 10px; color: var(--c-text-3); margin-bottom: 8px; text-transform: uppercase; letter-spacing: .5px; }
.stat-value  { font-size: 26px; font-weight: 700; line-height: 1; }
.stat-sub    { font-size: 11px; color: var(--c-text-3); margin-top: 6px; }
.stat-sub.up { color: var(--c-success); }
.stat-sub.warn { color: var(--c-warning); }

/* ── 表格 ───────────────────────────────────────────────────*/
.table-wrap { overflow-x: auto; }
.hek-table  { width: 100%; border-collapse: collapse; }
.hek-table thead th {
    font-size: 10px; color: var(--c-text-3); font-weight: 500;
    padding: 9px 18px; text-align: left;
    border-bottom: 1px solid var(--c-border);
    letter-spacing: .5px; text-transform: uppercase; white-space: nowrap;
}
.hek-table tbody td {
    font-size: 12px; padding: 11px 18px;
    border-bottom: 1px solid var(--c-surface-2);
    vertical-align: middle;
    transition: background 120ms ease;
}
.hek-table tbody tr:last-child td { border-bottom: none; }
.hek-table tbody tr:hover td { background: var(--c-surface-2); }
/* 审核队列行可点击(openPreview)，hover 用 accent-light 比普通行更明显，暗示可点 */
.hek-table tbody tr.hek-queue-row:hover td { background: var(--c-accent-light); }
.hek-table .mono  { font-family: var(--font-mono); font-size: 11px; color: var(--c-text-3); }
.hek-table .muted { color: var(--c-text-3); }
.hek-table .empty { text-align: center; color: var(--c-text-3); padding: 32px 18px; }

/* ── Badge ──────────────────────────────────────────────────*/
.badge {
    display: inline-flex; align-items: center; gap: 3px;
    font-size: 11px; font-weight: 500;
    padding: 3px 7px; border-radius: var(--r-xs); white-space: nowrap;
}
.badge.success  { background: var(--c-success-light); color: #005C3D; }
.badge.warning  { background: var(--c-warning-light); color: #7A4400; }
.badge.danger   { background: var(--c-danger-light);  color: #8B1A1A; }
.badge.info     { background: var(--c-accent-light);  color: #1A5EA8; }
.badge.neutral  { background: var(--c-surface-2);     color: var(--c-text-2); }
.badge.purple   { background: var(--c-purple-light);  color: #4535A8; }
/* 审核状态 */
.badge.pending  { background: var(--c-warning-light); color: #7A4400; }
.badge.passed   { background: var(--c-success-light); color: #005C3D; }
.badge.failed   { background: var(--c-danger-light);  color: #8B1A1A; }
.badge.timeout  { background: var(--c-surface-2);     color: var(--c-text-3); }
.badge.reviewing{ background: var(--c-accent-light);  color: #1A5EA8; }
/* 设备状态 */
.badge.online   { background: var(--c-success-light); color: #005C3D; }
.badge.offline  { background: var(--c-surface-2);     color: var(--c-text-3); }
.badge.disabled { background: var(--c-danger-light);  color: #8B1A1A; }
.badge.soft-dis { background: var(--c-warning-light); color: #7A4400; }

/* ── 按钮 ───────────────────────────────────────────────────*/
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 5px;
    padding: 7px 14px; font-size: 12px; font-weight: 500;
    border-radius: var(--r-md); border: 1px solid transparent;
    cursor: pointer; transition: background var(--t), border-color var(--t), color var(--t);
    white-space: nowrap; text-decoration: none; font-family: var(--font); line-height: 1.4;
    -webkit-appearance: none;
}
.btn:active { opacity: .85; }
.btn:hover  { text-decoration: none; }
.btn-primary   { background: var(--c-accent);   color: #fff; border-color: var(--c-accent); }
.btn-primary:hover  { background: #2D8FEF; border-color: #2D8FEF; }
.btn-secondary { background: var(--c-surface-2);color: var(--c-text-2); border-color: var(--c-border-2); }
.btn-secondary:hover{ background: var(--c-surface-2); }
.btn-danger    { background: var(--c-danger);   color: #fff; border-color: var(--c-danger); }
.btn-danger:hover   { background: #bc3030; }
.btn-success   { background: var(--c-success);  color: #fff; border-color: var(--c-success); }
.btn-success:hover  { background: #008a5c; }
.btn-outline-primary { background: transparent; color: var(--c-accent);   border-color: var(--c-accent); }
.btn-outline-primary:hover  { background: var(--c-accent-light); }
.btn-outline-danger  { background: transparent; color: var(--c-danger);   border-color: var(--c-danger); }
.btn-outline-danger:hover   { background: var(--c-danger-light); }
.btn-outline-success { background: transparent; color: var(--c-success);  border-color: var(--c-success); }
.btn-outline-success:hover  { background: var(--c-success-light); }
.btn-outline-warning { background: transparent; color: var(--c-warning);  border-color: var(--c-warning); }
.btn-outline-warning:hover  { background: var(--c-warning-light); }
.btn-outline-secondary { background: transparent; color: var(--c-text-2); border-color: var(--c-border-2); }
.btn-outline-secondary:hover{ background: var(--c-surface-2); }
.btn-ghost { background: var(--c-accent-light); color: var(--c-accent); border-color: transparent; }
.btn-ghost:hover { background: #dce9ff; }
[data-theme="dark"] .btn-ghost:hover { background: rgba(59,158,255,.28); }
.btn-sm { padding: 4px 10px; font-size: 11px; border-radius: var(--r-sm); }
.btn-lg { padding: 10px 20px; font-size: 14px; }
.btn-block { width: 100%; }
.btn-group { display: flex; }
.btn-group .btn { border-radius: 0; }
.btn-group .btn:first-child { border-radius: var(--r-md) 0 0 var(--r-md); }
.btn-group .btn:last-child  { border-radius: 0 var(--r-md) var(--r-md) 0; }
.btn-group .btn.active { background: var(--c-surface-2); }

/* ── 表单 ───────────────────────────────────────────────────*/
.form-group  { margin-bottom: 14px; }
.form-label  {
    display: block; font-size: 11px; color: var(--c-text-3);
    margin-bottom: 5px; font-weight: 500;
    text-transform: uppercase; letter-spacing: .3px;
}
.form-control, .form-select {
    display: block; width: 100%; padding: 7px 11px;
    font-size: 12px; font-family: var(--font);
    color: var(--c-text); background: var(--c-surface);
    border: 1px solid var(--c-border-2); border-radius: var(--r-md);
    transition: border-color var(--t), box-shadow var(--t);
    outline: none; line-height: 1.5;
    -webkit-appearance: none; appearance: none;
}
.form-control:hover, .form-select:hover { border-color: #b8c0d0; }
.form-control:focus, .form-select:focus {
    border-color: var(--c-accent);
    box-shadow: 0 0 0 3px rgba(59,158,255,.15);
}
.form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238B92A5' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}
.form-control-sm, .form-select-sm { padding: 5px 9px; font-size: 11px; }
.form-select-sm { padding-right: 26px; }
textarea.form-control { resize: vertical; min-height: 80px; }
.form-check { display: flex; align-items: center; gap: 7px; }
.form-check-input {
    width: 15px; height: 15px; border: 1px solid var(--c-border-2);
    border-radius: 3px; cursor: pointer; flex-shrink: 0;
    accent-color: var(--c-accent);
}
.form-check-label { font-size: 12px; color: var(--c-text-2); cursor: pointer; }

/* ── Alert ──────────────────────────────────────────────────*/
.alert {
    padding: 10px 14px; border-radius: var(--r-md);
    font-size: 12px; border: 1px solid transparent;
    margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
}
.alert-success { background: var(--c-success-light); color: #005C3D; border-color: #a8dfc7; }
.alert-danger  { background: var(--c-danger-light);  color: #8B1A1A; border-color: #f5bfbf; }
.alert-warning { background: var(--c-warning-light); color: #7A4400; border-color: #f5d5a0; }
.alert-info    { background: var(--c-accent-light);  color: #1A5EA8; border-color: #b3d4f5; }
.alert-close {
    margin-left: auto; background: none; border: none; font-size: 16px;
    cursor: pointer; color: inherit; opacity: .5; padding: 0 2px; line-height: 1;
}
.alert-close:hover { opacity: 1; }

/* ── 分页 ───────────────────────────────────────────────────*/
.pagination { display: flex; gap: 4px; align-items: center; list-style: none; }
.page-link {
    display: flex; align-items: center; justify-content: center;
    min-width: 30px; height: 30px; padding: 0 8px;
    font-size: 12px; color: var(--c-text-2);
    border: 1px solid var(--c-border); border-radius: var(--r-md);
    text-decoration: none; transition: background var(--t);
}
.page-link:hover { background: var(--c-surface-2); text-decoration: none; }
.page-item.active .page-link { background: var(--c-accent); color: #fff; border-color: var(--c-accent); }
.page-item.disabled .page-link { opacity: .4; pointer-events: none; }

/* ── Modal ──────────────────────────────────────────────────*/
.modal-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,.45); z-index: 500;
    align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
/* 全局确认弹窗必须压在所有页面级弹框之上（个别页面有内联 z-index:2000 的弹框） */
#adminConfirmModal { z-index: 3000; }
.modal-box {
    background: var(--c-surface); border-radius: var(--r-xl);
    box-shadow: var(--shadow-lg); width: 480px; max-width: calc(100vw - 32px);
    max-height: calc(100vh - 60px); display: flex; flex-direction: column;
    animation: modal-in var(--t);
}
.modal-box.modal-lg { width: 720px; }
.modal-box.modal-sm { width: 360px; }
@keyframes modal-in {
    from { opacity: 0; transform: scale(.96) translateY(-8px); }
    to   { opacity: 1; transform: scale(1)   translateY(0); }
}
.modal-header {
    padding: 18px 22px 14px; border-bottom: 1px solid var(--c-border);
    display: flex; align-items: center; justify-content: space-between; flex-shrink: 0;
}
.modal-title  { font-size: 14px; font-weight: 600; }
.modal-close  {
    background: none; border: none; font-size: 20px; color: var(--c-text-3);
    cursor: pointer; padding: 0 4px; line-height: 1;
}
.modal-close:hover { color: var(--c-text); }
.modal-body   { padding: 20px 22px; overflow-y: auto; }
.modal-footer {
    padding: 14px 22px; border-top: 1px solid var(--c-border);
    display: flex; justify-content: flex-end; gap: 8px; flex-shrink: 0;
}

/* ── 图片灯箱 ───────────────────────────────────────────────*/
.hek-image-lightbox {
    background: rgba(0,0,0,.72);
    z-index: 1200;
    padding: 20px;
}
.hek-image-lightbox .modal-box {
    position: relative;
    width: auto;
    max-width: 92vw;
    max-height: 92vh;
    padding: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}
.hek-lightbox-img {
    max-width: 92vw;
    max-height: 92vh;
    object-fit: contain;
    border-radius: var(--r-md);
    box-shadow: 0 18px 60px rgba(0,0,0,.45);
    background: #111;
    transition: transform .2s;
}
.hek-lightbox-close {
    position: absolute;
    top: -14px;
    right: -14px;
    z-index: 10;
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255,255,255,.9);
    border-radius: 50%;
    background: var(--c-danger);
    color: #fff;
    font-size: 26px;
    line-height: 34px;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(0,0,0,.35);
    opacity: 1;
}
.hek-lightbox-close:hover {
    background: #b92d2d;
    transform: scale(1.04);
}
.hek-lightbox-tools {
    position: absolute;
    left: 50%;
    bottom: -46px;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 8px;
}
.hek-lightbox-tool {
    height: 36px;
    padding: 0 14px;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: var(--r-pill);
    background: rgba(18,24,34,.86);
    color: #fff;
    font-size: 12px;
    box-shadow: 0 6px 18px rgba(0,0,0,.25);
}
.hek-lightbox-tool:hover {
    background: rgba(18,24,34,.96);
}
.hek-preview-thumb {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    text-align: left;
}
.hek-preview-thumb img {
    height: 84px;
    width: 100%;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--c-border);
    transition: border-color var(--t), box-shadow var(--t), transform var(--t);
}
.hek-preview-thumb:hover img {
    border-color: var(--c-accent);
    box-shadow: 0 4px 14px rgba(59,158,255,.22);
    transform: translateY(-1px);
}

/* ── 审核卡片 ────────────────────────────────────────────────*/
.review-card {
    background: var(--c-surface); border-radius: var(--r-lg);
    border: 1px solid var(--c-border); box-shadow: var(--shadow);
    padding: 16px 18px; cursor: pointer;
    transition: transform var(--t), box-shadow var(--t);
}
.review-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

/* ── 登录页 ──────────────────────────────────────────────────*/
.login-page {
    min-height: 100vh; display: flex;
    align-items: center; justify-content: center;
    background: linear-gradient(140deg, #12284C 0%, #1d4080 60%, #0d2a52 100%);
}
.login-card {
    width: 400px; background: var(--c-surface);
    border-radius: var(--r-xl); padding: 40px 36px;
    box-shadow: 0 20px 60px rgba(0,0,0,.28);
}
.login-logo { text-align: center; margin-bottom: 28px; }
.login-title    { font-size: 20px; font-weight: 700; color: var(--c-primary); }
.login-subtitle { font-size: 12px; color: var(--c-text-3); margin-top: 4px; }

/* ── 辅助 ───────────────────────────────────────────────────*/
.divider { border: none; border-top: 1px solid var(--c-border); margin: 12px 0; }
.rounded-full { border-radius: 50%; }

@keyframes pulse {
    0%,100% { transform: scale(1); }
    50%     { transform: scale(1.2); }
}

/* ── 检测详细数据折叠节 ─────────────────────────────────────*/
.hek-detail-section {
    border-bottom: 1px solid var(--c-border);
}
.hek-detail-section:last-child {
    border-bottom: none;
}
.hek-detail-summary {
    list-style: none;
    display: flex; align-items: center; gap: 6px;
    padding: 11px 18px;
    font-size: 13px; font-weight: 600; color: var(--c-text);
    cursor: pointer; user-select: none;
}
.hek-detail-summary::-webkit-details-marker { display: none; }
.hek-detail-summary::before {
    content: "▶";
    font-size: 9px; color: var(--c-text-3);
    transition: transform 0.15s;
}
details[open] > .hek-detail-summary::before {
    transform: rotate(90deg);
}
.hek-detail-summary:hover {
    background: var(--c-surface-2);
}

/* ── Bootstrap 命名兼容别名 ─────────────────────────────────*/
/* 供使用 Bootstrap class 命名的模板页（如 Detail.cshtml）使用  */
.d-flex         { display: flex; }
.d-inline-block { display: inline-block; }
.d-none         { display: none !important; }
.d-block        { display: block; }
.justify-content-between { justify-content: space-between; }
.justify-content-center  { justify-content: center; }
.align-items-center      { align-items: center; }
.align-items-start       { align-items: flex-start; }
.fw-semibold { font-weight: 600; }
.fw-medium   { font-weight: 500; }
.fw-bold     { font-weight: 700; }
.img-fluid   { max-width: 100%; height: auto; display: block; }
.border          { border: 1px solid var(--c-border) !important; }
.border-top      { border-top: 1px solid var(--c-border) !important; }
.border-top-0    { border-top: 0 !important; }
.border-warning  { border-color: var(--c-warning) !important; }
.rounded         { border-radius: var(--r-md); }
.rounded-bottom  { border-bottom-left-radius: var(--r-md); border-bottom-right-radius: var(--r-md); }
.bg-white        { background: #fff !important; }
.bg-warning-subtle { background: var(--c-warning-light) !important; }
/* margin-start / margin-end */
.ms-1 { margin-left: 4px; }  .ms-2 { margin-left: 8px; }  .ms-3 { margin-left: 12px; }
.me-1 { margin-right: 4px; } .me-2 { margin-right: 8px; }
/* padding 补全 */
.p-3  { padding: 12px; }
.pt-3 { padding-top: 12px; } .pt-4 { padding-top: 16px; }
.pb-3 { padding-bottom: 12px; }
.px-1 { padding-left: 4px;  padding-right: 4px; }
.mb-0 { margin-bottom: 0 !important; }
/* Badge Bootstrap 颜色兼容 */
.badge.bg-success   { background: var(--c-success-light) !important; color: #005C3D !important; }
.badge.bg-danger    { background: var(--c-danger-light)  !important; color: #8B1A1A !important; }
.badge.bg-secondary { background: var(--c-surface-2)     !important; color: var(--c-text-2) !important; }
.badge.bg-warning   { background: var(--c-warning-light) !important; color: #7A4400 !important; }
.badge.text-dark    { color: var(--c-text) !important; }

/* ── Tab 组件 ───────────────────────────────────────────────*/
.nav {
    list-style: none;
    margin: 0; padding: 0;
    display: flex; flex-wrap: wrap;
}
.nav-tabs {
    border-bottom: 2px solid var(--c-border);
    gap: 6px;
    padding-bottom: 0;
}
.nav-tabs .nav-item { margin-bottom: -2px; }
.nav-tabs .nav-link {
    display: block;
    padding: 6px 14px;
    font-size: 12px; font-weight: 500;
    color: var(--c-text-2);
    border: 1px solid var(--c-border);
    border-bottom: none;
    border-radius: var(--r-sm) var(--r-sm) 0 0;
    cursor: pointer;
    background: linear-gradient(180deg, var(--c-surface) 0%, var(--c-surface-2) 100%);
    text-decoration: none;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.65);
    transition: color var(--t), background var(--t), border-color var(--t), box-shadow var(--t);
}
.nav-tabs .nav-link:hover {
    color: var(--c-text);
    background: var(--c-surface-2);
    border-color: var(--c-accent);
    border-bottom: none;
}
.nav-tabs .nav-link.active {
    color: var(--c-accent);
    font-weight: 600;
    background: var(--c-surface);
    border-color: var(--c-accent);
    border-bottom: 2px solid var(--c-surface);
    box-shadow: 0 -1px 0 rgba(59,158,255,.12), 0 2px 8px rgba(59,158,255,.08);
}
.tab-pane          { display: none; }
.tab-pane.show.active { display: block; }
.tab-pane.fade     { opacity: 0; transition: opacity 0.15s linear; }
.tab-pane.fade.show { opacity: 1; }

/* ── 表格横向滚动容器 ───────────────────────────────────────*/
/* 多个列表页引用 .hek-table-wrap（设备/退款/支付/用户/轮播/体检记录/审核队列），
   此前仅定义了 .table-wrap，导致窄屏下宽表无法横向滚动。这里补齐别名。 */
.hek-table-wrap { overflow-x: auto; }

/* ── 审核工作台：任务队列行（超时风险标红条）──────────────*/
.hek-queue-row.is-risk td:first-child { box-shadow: inset 3px 0 0 var(--c-danger); }

/* ── 审核详情：检测结果汇总项（异常高亮 / 正常弱化）────────*/
.hek-summary-item { padding: 4px 8px; border-radius: var(--r-sm); }
.hek-summary-item .hek-summary-label { color: var(--c-text-3); }
.hek-summary-item.is-abnormal { background: var(--c-danger-light); }
.hek-summary-item.is-abnormal .hek-summary-label { color: var(--c-danger); font-weight: 600; }

/* ── 审核详情：吸底操作栏 ───────────────────────────────────*/
.hek-review-bar {
    position: fixed; left: var(--sb-w); right: 0; bottom: 0; z-index: 80;
    background: var(--c-surface); border-top: 1px solid var(--c-border);
    box-shadow: 0 -2px 12px rgba(0,0,0,.08);
    padding: 10px 24px;
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.admin-sidebar-collapsed .layout-sidebar-collapsible .hek-review-bar { left: var(--sb-w-collapsed); }
.hek-review-bar-info { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── 支付验证弹窗 ───────────────────────────────────────────*/
.payment-verify-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.5);
}
.payment-verify-panel {
    width: calc(100% - 32px);
    max-width: 420px;
    padding: 28px 32px;
    text-align: center;
    background: var(--c-surface);
    border-radius: var(--r-xl);
    box-shadow: var(--shadow-lg);
}
.payment-verify-title {
    margin: 0 0 20px;
    font-size: 17px;
    color: var(--c-text);
}
.payment-verify-loading {
    color: var(--c-text-2);
    font-size: 14px;
    padding: 24px 0;
}
.payment-spinner {
    animation: spin 1s linear infinite;
    display: block;
    margin: 0 auto 12px;
}
.payment-verify-qr {
    width: 200px;
    height: 200px;
    display: block;
    margin: 0 auto 16px;
    border-radius: var(--r-md);
    border: 1px solid var(--c-border);
}
.payment-verify-message {
    font-size: 13px;
    color: var(--c-text-2);
    line-height: 1.6;
    margin: 0 0 16px;
}
.payment-verify-refund {
    border-top: 1px solid var(--c-border);
    padding-top: 14px;
    margin-bottom: 14px;
}
.payment-verify-result {
    display: none;
    font-size: 12px;
    line-height: 1.5;
    margin: 10px 0 0;
}
.payment-verify-error-icon {
    font-size: 32px;
    margin-bottom: 12px;
}
.payment-verify-error {
    font-size: 13px;
    color: var(--c-danger);
    line-height: 1.6;
    margin: 0 0 20px;
    word-break: break-all;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── 响应式 ─────────────────────────────────────────────────*/
@media (max-width: 992px) {
    .sidebar { transform: translateX(-100%); transition: transform var(--t); }
    .sidebar.open { transform: translateX(0); }
    .main { margin-left: 0; }
    .admin-sidebar-collapsed .layout-sidebar-collapsible .main { margin-left: 0; }
    .hek-review-bar { left: 0; }
    .admin-sidebar-collapsed .layout-sidebar-collapsible .hek-review-bar { left: 0; }
    .sidebar-toggle-btn { display: none; }
    .mobile-sidebar-btn { display: inline-flex; }
    .topbar { padding: 0 14px; }
    .metric-grid, .chart-grid { grid-template-columns: 1fr; }
    .review-overview {
        flex-direction: column;
    }
    .review-overview-divider {
        width: auto;
        height: 1px;
        margin: 0 14px;
    }
    .review-overview-todo {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .page-body { padding: 18px 14px; }
    .filter-card { padding: 14px; }
    .filter-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
    }
    .filter-field,
    .filter-field.wide {
        min-width: 0;
        width: 100%;
    }
    .filter-submit { width: 100%; }
    .chart-grid [id^="chart-"] {
        width: 100% !important;
        max-width: 100%;
        overflow: hidden;
    }
    .review-overview-block {
        padding: 11px 12px;
    }
    .review-overview-work {
        align-items: flex-start;
        flex-wrap: wrap;
    }
    .review-overview-main {
        min-width: 0;
    }
    .review-overview-chips {
        width: 100%;
    }
    .review-overview-todo {
        grid-template-columns: minmax(0, 1fr);
        gap: 6px;
    }
    .review-todo-item {
        grid-template-columns: 25px minmax(0, 1fr) auto;
    }
}

/* ── 通知中心铃铛 ───────────────────────────────────────────── */
.notif-menu { position: relative; display: flex; align-items: center; }
.notif-badge {
    position: absolute; top: -4px; right: -4px;
    min-width: 16px; height: 16px; padding: 0 4px;
    background: var(--c-danger); color: #fff;
    font-size: 10px; line-height: 16px; font-weight: 600;
    text-align: center; border-radius: 8px; box-sizing: border-box;
}
.notif-dropdown {
    position: absolute; top: calc(100% + 8px); right: 0;
    width: 340px; max-width: 92vw;
    background: var(--c-surface); border: 1px solid var(--c-border);
    border-radius: 10px; box-shadow: 0 8px 28px rgba(0,0,0,.16);
    z-index: 1200; display: none; overflow: hidden;
}
.notif-dropdown.open { display: block; }
.notif-dropdown-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 14px; border-bottom: 1px solid var(--c-border);
    font-size: 13px; font-weight: 600; color: var(--c-text);
}
.notif-allread-btn {
    background: none; border: none; cursor: pointer;
    color: var(--c-primary); font-size: 12px;
}
.notif-dropdown-body { max-height: 380px; overflow-y: auto; }
.notif-empty { padding: 28px 14px; text-align: center; color: var(--c-text-3); font-size: 12px; }
.notif-item {
    display: flex; gap: 9px; padding: 10px 14px;
    border-bottom: 1px solid var(--c-border); cursor: pointer;
}
.notif-item:hover { background: var(--c-surface-2); }
.notif-item.is-read { opacity: .55; }
.notif-dot { flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; margin-top: 5px; }
.notif-item-main { flex: 1; min-width: 0; }
.notif-item-title { font-size: 13px; font-weight: 600; color: var(--c-text); }
.notif-item-body {
    font-size: 12px; color: var(--c-text-2); margin-top: 2px;
    overflow: hidden; text-overflow: ellipsis; display: -webkit-box;
    -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.notif-item-time { font-size: 11px; color: var(--c-text-3); margin-top: 3px; }
.notif-dropdown-foot {
    display: block; padding: 10px 14px; text-align: center;
    font-size: 12px; color: var(--c-primary); text-decoration: none;
    border-top: 1px solid var(--c-border);
}
.notif-dropdown-foot:hover { background: var(--c-surface-2); }
