/**
 * admin.css — 后台全局样式合并包
 * 内容 = 生产备份(2026-09-26)中的 6 个全局 CSS 原文合并：
 *   style → modern-theme → modern-ui → modern-theme-integration → pages-modern → custom-select
 * 注意：此前"删除死类"的做法造成过回归（备份中的类有实际用途/热修），已全部还原。
 * 页面专属 CSS 在此之后加载，覆盖关系不变。
 */

/* ===== 来源: style.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */


/* ==================== 通用工具类 ==================== */

/* 紫色文本（用于偏好管理） */
.text-purple {
    color: #2563eb !important;
}

.text-purple:hover {
    color: #2563eb !important;
}

/* 小尺寸头像（列表中） */
.user-avatar-img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
    vertical-align: middle;
    background-color: #f1f5f9;
}

/* 中等尺寸头像（导航栏） */
.navbar img[alt="头像"] {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

/* 大尺寸头像（个人资料页） */
.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    background-color: #f1f5f9;
}

/* 默认文字头像样式 */
.avatar-circle-sm {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    font-weight: 600;
    vertical-align: middle;
}

.avatar-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    font-weight: 600;
}

/* 实时大屏头像 */
.borrower-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    background-color: #f1f5f9;
}

.borrower-avatar-default {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    flex-shrink: 0;
}

/* 头像错误状态 */
img[alt="头像"].error {
    display: none;
}

/* 头像容器 */
.user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* ==================== 首页功能卡片样式 ====================
 * 视觉定义已迁移至 css/homepage-modern.css（首页专属，后加载优先）。
 * 此处仅保留首页内联脚本依赖的遮罩层样式，避免影响入场动画。
 * 注意：不要在此重新定义 .function-grid / .function-card，否则会在
 * 1200px / 900px 断点上与 homepage-modern.css 的列数规则冲突。 */

/* 卡片点击动画遮罩层 */
.card-expand-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 9998;
}

.card-expand-overlay.active {
    opacity: 1;
}

/* ==================== 页脚样式 ==================== */

.site-footer {
    margin-top: 40px;
    padding: 30px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-top: 1px solid #e2e8f0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
}

.footer-logo-img {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.footer-logo-img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.footer-brand-text {
    display: flex;
    flex-direction: column;
}

.footer-brand-name {
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.4;
}

.footer-brand-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.4;
}

.footer-custom-text {
    font-size: 0.875rem;
    color: #6b7280;
    text-align: center;
    max-width: 600px;
}

.footer-text {
    font-size: 0.75rem;
    color: #9ca3af;
    text-align: center;
}

/* 页脚移动端适配 */
@media (max-width: 768px) {
    .site-footer {
        margin-top: 24px;
        padding: 24px 0;
    }
    
    .footer-content {
        gap: 8px;
    }
}

/* ===== 来源: modern-theme.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */
/**
 * 心猫文化借用系统 - 现代化高级UI主题
 * 设计特点：玻璃拟态、卡片式布局、流畅动画、高级配色
 */

/* ==================== CSS变量 - 设计系统 ==================== */
:root {
    /* 主色调 - 科技蓝 */
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-200: #93c5fd;
    --primary-300: #60a5fa;
    --primary-400: #60a5fa;
    --primary-500: #2563eb;
    --primary-600: #1d4ed8;
    --primary-700: #1d4ed8;
    --primary-800: #1e40af;
    --primary-900: #1e40af;
    
    /* 强调色 - 活力珊瑚 */
    --accent-500: #f97316;
    --accent-600: #ea580c;
    
    /* 中性色 */
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* 功能色 */
    --success-500: #10b981;
    --warning-500: #f59e0b;
    --error-500: #ef4444;
    --info-500: #2563eb;
    
    /* 玻璃拟态 */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    
    /* 阴影系统 */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -1px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
    --shadow-glow: 0 0 40px rgba(59, 130, 246, 0.15);
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* 间距 */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    
    /* 过渡 */
    --transition-fast: 0.15s ease;
    --transition-base: 0.25s ease;
    --transition-slow: 0.4s ease;
}

/* ==================== 基础重置与优化 ==================== */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 50%, #f0f9ff 100%);
    background-attachment: fixed;
    color: var(--gray-800);
    line-height: 1.6;
    min-height: 100vh;
}

/* ==================== 玻璃拟态卡片 ==================== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--glass-shadow);
    transition: all var(--transition-base);
}

.glass-card:hover {
    box-shadow: var(--shadow-xl), var(--shadow-glow);
    transform: translateY(-2px);
}

/* ==================== 导航栏现代化 ==================== */
.modern-navbar {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: var(--shadow-sm);
    padding: var(--space-3) var(--space-6);
}

.modern-navbar .navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    background: linear-gradient(135deg, var(--primary-600), var(--primary-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.modern-navbar .nav-link {
    color: var(--gray-600);
    font-weight: 500;
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    position: relative;
}

.modern-navbar .nav-link:hover {
    color: var(--primary-600);
    background: var(--primary-50);
}

.modern-navbar .nav-link.active {
    color: var(--primary-600);
    background: linear-gradient(135deg, var(--primary-50), var(--primary-100));
}

.modern-navbar .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 20%;
    right: 20%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-500), transparent);
    border-radius: var(--radius-full);
}

/* ==================== 按钮系统 ==================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-5);
    font-weight: 600;
    font-size: 0.9375rem;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.25), transparent);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.btn:hover::before {
    opacity: 1;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-600), var(--primary-500));
    color: white;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.45);
}

.btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
}

.btn-secondary:hover {
    background: var(--gray-200);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-500), #059669);
    color: white;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.btn-danger {
    background: linear-gradient(135deg, var(--error-500), #dc2626);
    color: white;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}

.btn-ghost {
    background: transparent;
    color: var(--gray-600);
}

.btn-ghost:hover {
    background: var(--gray-100);
    color: var(--gray-800);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-6);
}

.feature-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-xl);
    padding: var(--space-8);
    text-decoration: none;
    color: inherit;
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-md);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--card-color, var(--primary-500)), var(--card-color-light, var(--primary-400)));
    opacity: 0;
    transition: opacity var(--transition-base);
}

.feature-card:hover {
    transform: translateY(-4px) scale(1.01);
    box-shadow: var(--shadow-xl);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card .card-icon {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-5);
    font-size: 1.75rem;
    background: linear-gradient(135deg, var(--card-color, var(--primary-500)), var(--card-color-light, var(--primary-400)));
    color: white;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.feature-card .card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: var(--space-2);
}

.feature-card .card-desc {
    font-size: 0.9375rem;
    color: var(--gray-500);
    line-height: 1.6;
}

/* ==================== 表单现代化 ==================== */
.modern-form {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    padding: var(--space-8);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.form-group {
    margin-bottom: var(--space-5);
}

.form-label {
    display: block;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--gray-700);
    margin-bottom: var(--space-2);
}

.form-input {
    width: 100%;
    padding: var(--space-3) var(--space-4);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    transition: all var(--transition-fast);
    background: white;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-400);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-input::placeholder {
    color: var(--gray-400);
}

/* ==================== 表格现代化 ==================== */
.modern-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.modern-table thead {
    background: linear-gradient(135deg, var(--gray-50), var(--gray-100));
}

.modern-table th {
    padding: var(--space-4) var(--space-5);
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gray-600);
    border-bottom: 2px solid var(--gray-200);
}

.modern-table td {
    padding: var(--space-4) var(--space-5);
    border-bottom: 1px solid var(--gray-100);
    color: var(--gray-700);
}

.modern-table tbody tr {
    transition: background var(--transition-fast);
}

.modern-table tbody tr:hover {
    background: var(--primary-50);
}

.modern-table tbody tr:last-child td {
    border-bottom: none;
}

/* ==================== 徽章与标签 ==================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: var(--space-1) var(--space-3);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
}

.badge-primary {
    background: var(--primary-100);
    color: var(--primary-700);
}

.badge-success {
    background: #d1fae5;
    color: #065f46;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-error {
    background: #fee2e2;
    color: #991b1b;
}

/* ==================== 登录页现代化 ==================== */
.modern-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-6);
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 50%, #f093fb 100%);
    position: relative;
    overflow: hidden;
}

.modern-login::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    right: -50%;
    bottom: -50%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    animation: rotate 30s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 420px;
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    padding: var(--space-10);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.login-header {
    text-align: center;
    margin-bottom: var(--space-8);
}

.login-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--space-5);
    background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    box-shadow: 0 10px 30px rgba(79, 70, 229, 0.3);
}

.login-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--gray-800);
    margin-bottom: var(--space-2);
}

.login-subtitle {
    color: var(--gray-500);
    font-size: 0.9375rem;
}

/* ==================== 头像现代化 ==================== */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    object-fit: cover;
    border: 2px solid white;
    box-shadow: var(--shadow-sm);
}

.avatar-lg {
    width: 64px;
    height: 64px;
}

.avatar-default {
    background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* ==================== 提示消息现代化 ==================== */
.modern-alert {
    padding: var(--space-4) var(--space-5);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-5);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

/* ==================== 加载动画 ==================== */
.loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary-500);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==================== 工具类 ==================== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-600), var(--accent-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-hover {
    transition: all var(--transition-base);
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

/* ==================== 响应式优化 ==================== */
@media (max-width: 768px) {
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .modern-navbar {
        padding: var(--space-3);
    }
    
    .login-card {
        padding: var(--space-6);
    }
}

/* ==================== 动画效果 ==================== */
.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ===== 来源: modern-ui.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */
/**
 * 现代化UI组件库 - 用于所有页面的一致性设计
 */

/* ==================== 页面容器 ==================== */
.modern-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #f0f4ff 0%, #f8fafc 50%, #fdf2f8 100%);
    background-attachment: fixed;
    padding-bottom: 40px;
}

.page-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px;
}

/* ==================== 页面头部 ==================== */
.page-header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 24px 32px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.page-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.page-header h1 i {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.125rem;
}

.page-header .breadcrumb {
    color: #64748b;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ==================== 统计卡片 ==================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 24px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--stat-color, #1d4ed8), var(--stat-color-light, #2563eb));
}

.stat-card.blue { --stat-color: #2563eb; --stat-color-light: #60a5fa; }
.stat-card.green { --stat-color: #10b981; --stat-color-light: #34d399; }
.stat-card.orange { --stat-color: #f97316; --stat-color-light: #fb923c; }
.stat-card.purple { --stat-color: #2563eb; --stat-color-light: #60a5fa; }
.stat-card.red { --stat-color: #ef4444; --stat-color-light: #f87171; }
.stat-card.cyan { --stat-color: #06b6d4; --stat-color-light: #22d3ee; }

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--stat-color), var(--stat-color-light));
    color: white;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 4px;
    letter-spacing: -0.02em;
}

.stat-label {
    font-size: 0.9375rem;
    color: #64748b;
    font-weight: 500;
}

.stat-change {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8125rem;
    font-weight: 600;
    margin-top: 8px;
    padding: 4px 10px;
    border-radius: 20px;
    background: #f1f5f9;
}

.stat-change.positive { color: #059669; background: #d1fae5; }
.stat-change.negative { color: #dc2626; background: #fee2e2; }

/* ==================== 内容卡片 ==================== */
.content-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.content-card .card-header {
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(to right, #f8fafc, #ffffff);
}

.content-card .card-header h2 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.content-card .card-header h2 i {
    color: #1d4ed8;
}

.content-card .card-body {
    padding: 24px;
}

.content-card .card-footer {
    padding: 16px 24px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* ==================== 搜索和筛选 ==================== */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.search-input-wrapper {
    position: relative;
    flex: 1;
    min-width: 280px;
}

.search-input-wrapper i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1rem;
}

.search-input-wrapper input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    transition: all 0.2s;
    background: white;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.filter-select {
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    background: white;
    min-width: 160px;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

/* ==================== 分页组件 ==================== */
.modern-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
}

.pagination-btn {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid #e2e8f0;
    background: white;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s;
}

.pagination-btn:hover:not(:disabled) {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #1e293b;
}

.pagination-btn.active {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-color: transparent;
    color: white;
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-info {
    padding: 0 16px;
    font-size: 0.875rem;
    color: #64748b;
}

/* ==================== 空状态 ==================== */
.empty-state {
    text-align: center;
    padding: 60px 24px;
}

.empty-state .empty-icon {
    width: 120px;
    height: 120px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: #94a3b8;
}

.empty-state h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.empty-state p {
    color: #64748b;
    margin-bottom: 24px;
}

/* ==================== 标签页 ==================== */
.modern-tabs {
    display: flex;
    gap: 4px;
    padding: 4px;
    background: #f1f5f9;
    border-radius: 12px;
    margin-bottom: 24px;
}

.tab-btn {
    padding: 10px 20px;
    border: none;
    background: transparent;
    border-radius: 10px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.tab-btn:hover {
    color: #475569;
}

.tab-btn.active {
    background: white;
    color: #1d4ed8;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* ==================== 步骤条 ==================== */
.modern-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 32px;
    position: relative;
}

.modern-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 50px;
    right: 50px;
    height: 2px;
    background: #e2e8f0;
    z-index: 0;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9375rem;
    background: white;
    border: 2px solid #e2e8f0;
    color: #64748b;
    transition: all 0.3s;
}

.step.active .step-number {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

.step.completed .step-number {
    background: #10b981;
    border-color: #10b981;
    color: white;
}

.step-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #64748b;
}

.step.active .step-label {
    color: #1d4ed8;
}

/* ==================== 下拉菜单 ==================== */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 200px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.6);
    padding: 8px;
    margin-top: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s;
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.9375rem;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s;
}

.dropdown-item:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.dropdown-item i {
    width: 20px;
    color: #64748b;
}

.dropdown-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 8px 0;
}

/* ==================== 开关组件 ==================== */
.toggle-switch {
    position: relative;
    width: 52px;
    height: 28px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #e2e8f0;
    border-radius: 28px;
    transition: 0.3s;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-switch input:checked + .toggle-slider {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(24px);
}

/* ==================== 进度条 ==================== */
.progress-bar {
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1d4ed8, #2563eb);
    border-radius: 4px;
    transition: width 0.5s ease;
}

/* ==================== 时间轴 ==================== */
.timeline {
    position: relative;
    padding-left: 32px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #e2e8f0;
}

.timeline-item {
    position: relative;
    padding-bottom: 24px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -28px;
    top: 4px;
    width: 12px;
    height: 12px;
    background: white;
    border: 3px solid #1d4ed8;
    border-radius: 50%;
}

.timeline-content {
    background: #f8fafc;
    padding: 16px;
    border-radius: 12px;
}

.timeline-time {
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 4px;
}

.timeline-title {
    font-weight: 600;
    color: #1e293b;
}

/* ===== 来源: modern-theme-integration.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */
/**
 * 现代化主题整合文件
 * 这个文件确保新主题与现有样式的兼容性
 */

/* ==================== 与现有Bootstrap的兼容性调整 ==================== */

/* 保持容器一致性 */
.container {
    max-width: 1400px;
}

/* 按钮样式统一 */
.btn {
    font-weight: 600;
    border-radius: 10px;
    padding: 10px 20px;
    transition: all 0.2s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border: none;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.45);
    background: linear-gradient(135deg, #1d4ed8, #1d4ed8);
}

.btn-secondary {
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    color: #374151;
}

.btn-secondary:hover {
    background: #e5e7eb;
    border-color: #d1d5db;
}

/* 表单控件美化 */
.form-control, .form-select {
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 1rem; /* 16px 防 iOS Safari 聚焦自动放大（2026-09-30） */
    transition: all 0.2s ease;
}

.form-control:focus, .form-select:focus {
    border-color: #1d4ed8;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

/* 卡片样式增强 */
.card {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
}

.card-header {
    background: linear-gradient(to right, #f8fafc, #ffffff);
    border-bottom: 1px solid #e2e8f0;
    padding: 20px 24px;
    border-radius: 16px 16px 0 0 !important;
}

.card-body {
    padding: 24px;
}

/* 导航栏增强 */
.navbar {
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    color: #1e293b !important;
}

.nav-link {
    font-weight: 500;
    color: #64748b !important;
    padding: 8px 16px !important;
    border-radius: 8px;
    margin: 0 2px;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #1d4ed8 !important;
    background: rgba(79, 70, 229, 0.05);
}

.nav-link.active {
    color: #1d4ed8 !important;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(124, 58, 237, 0.1));
}

/* 下拉菜单美化 */
.dropdown-menu {
    border: none;
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    padding: 8px;
}

.dropdown-item {
    border-radius: 10px;
    padding: 10px 16px;
    font-weight: 500;
    color: #475569;
    transition: all 0.2s;
}

.dropdown-item:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.dropdown-divider {
    margin: 8px;
    border-color: #e2e8f0;
}

/* 徽章美化 */
.badge {
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
}

.bg-primary {
    background: linear-gradient(135deg, #1d4ed8, #2563eb) !important;
}

.bg-success {
    background: linear-gradient(135deg, #10b981, #059669) !important;
}

.bg-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
}

.bg-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706) !important;
}

/* 警告框美化 */
.alert {
    border: none;
    border-radius: 12px;
    padding: 16px 20px;
    font-weight: 500;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
}

/* 分页美化 */
.pagination {
    gap: 6px;
}

.page-link {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    color: #4b5563;
    font-weight: 600;
    padding: 10px 16px;
    transition: all 0.2s;
}

.page-link:hover {
    background: #f3f4f6;
    border-color: #d1d5db;
    color: #1f2937;
}

.page-item.active .page-link {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

.page-item.disabled .page-link {
    opacity: 0.5;
}

/* 模态框美化 */
.modal-content {
    border: none;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.modal-header {
    border-bottom: 1px solid #e5e7eb;
    padding: 20px 24px;
}

.modal-body {
    padding: 24px;
}

.modal-footer {
    border-top: 1px solid #e5e7eb;
    padding: 16px 24px;
}

/* 表格美化 */
.table {
    border-collapse: separate;
    border-spacing: 0;
}

.table thead th {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    color: #64748b;
    padding: 16px 20px;
    border-bottom: 2px solid #e2e8f0;
}

.table tbody td {
    padding: 16px 20px;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
}

.table tbody tr:hover {
    background: #f8fafc;
}

/* 工具提示美化 */
.tooltip-inner {
    background: #1e293b;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 0.8125rem;
    font-weight: 500;
}

/* 进度条美化 */
.progress {
    background: #e2e8f0;
    border-radius: 10px;
    height: 8px;
}

.progress-bar {
    background: linear-gradient(90deg, #1d4ed8, #2563eb);
    border-radius: 10px;
}

/* 列表组美化 */
.list-group-item {
    border: 1px solid #e2e8f0;
    padding: 16px 20px;
    transition: all 0.2s;
}

.list-group-item:hover {
    background: #f8fafc;
}

.list-group-item.active {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-color: transparent;
}

/* ==================== 动画效果 ==================== */
.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.slide-up {
    animation: slideUp 0.5s ease;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== 打印样式优化 ==================== */
@media print {
    .navbar,
    .site-footer,
    .btn,
    .no-print {
        display: none !important;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #e5e7eb;
    }
}

/* ==================== 移动端右侧侧边栏 ==================== */
@media (max-width: 991px) {
    /* 遮罩层 */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.4);
        z-index: 1040;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }

    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    /* 侧边栏 */
    .mobile-sidebar {
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        max-width: 85vw;
        height: 100%;
        height: 100dvh;
        background: #fff;
        z-index: 1050;
        box-shadow: -8px 0 30px rgba(0, 0, 0, 0.15);
        /* 用 transform 移出屏幕（transform 不参与滚动区计算）：
           right:-300px / visibility 方案在移动内核下仍会把 scrollWidth 撑宽 101px */
        transform: translateX(100%);
        visibility: hidden;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), visibility 0s 0.3s;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }

    .mobile-sidebar.active {
        transform: none;
        visibility: visible;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* 侧边栏头部 */
    .sidebar-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 1rem 1.25rem;
        border-bottom: 1px solid #e2e8f0;
        background: linear-gradient(135deg, #f8fafc, #fff);
        flex-shrink: 0;
    }

    .sidebar-title {
        font-size: 1.1rem;
        font-weight: 700;
        color: #1e293b;
    }

    .sidebar-close {
        width: 32px;
        height: 32px;
        border: none;
        background: #f1f5f9;
        border-radius: 8px;
        font-size: 1.25rem;
        color: #64748b;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s;
    }

    .sidebar-close:hover {
        background: #e2e8f0;
        color: #1e293b;
    }

    /* 侧边栏内容区 */
    .sidebar-body {
        flex: 1;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0.75rem 0;
    }

    /* 侧边栏分区 */
    .sidebar-section {
        padding: 0 0.5rem;
    }

    .sidebar-section-title {
        font-size: 0.75rem; /* 11.2px→12px 手机端可读性下限（2026-09-30） */
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: #94a3b8;
        padding: 0.5rem 0.75rem 0.25rem;
    }

    .sidebar-divider {
        height: 1px;
        background: #e2e8f0;
        margin: 0.5rem 1rem;
    }

    /* 侧边栏菜单项 */
    .sidebar-menu-item {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        padding: 0.75rem 0.75rem;
        border-radius: 10px;
        color: #475569;
        text-decoration: none;
        font-size: 0.95rem;
        font-weight: 500;
        transition: all 0.15s ease;
        margin-bottom: 2px;
        -webkit-tap-highlight-color: transparent;
    }

    .sidebar-menu-item i {
        width: 22px;
        text-align: center;
        font-size: 1rem;
        color: #64748b;
        flex-shrink: 0;
    }

    .sidebar-menu-item:hover,
    .sidebar-menu-item:active {
        background: #f1f5f9;
        color: #1e293b;
    }

    .sidebar-menu-item.active {
        background: linear-gradient(135deg, #eff6ff, #dbeafe);
        color: #1d4ed8;
        font-weight: 600;
    }

    .sidebar-menu-item.active i {
        color: #1d4ed8;
    }

    /* 侧边栏用户区域 */
    .sidebar-user-info {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        padding: 0.75rem 0.75rem;
        margin: 0 0.5rem;
        border-radius: 12px;
        background: #f8fafc;
    }

    .sidebar-avatar {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        object-fit: cover;
        flex-shrink: 0;
    }

    .sidebar-avatar-default {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        background: linear-gradient(135deg, #1d4ed8, #2563eb);
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        font-weight: 600;
        font-size: 1rem;
        flex-shrink: 0;
    }

    .sidebar-user-name {
        font-weight: 600;
        font-size: 0.95rem;
        color: #1e293b;
    }

    /* 退出按钮特殊样式 */
    .sidebar-menu-item.danger {
        color: #ef4444;
    }

    .sidebar-menu-item.danger i {
        color: #ef4444;
    }

    .sidebar-menu-item.danger:hover {
        background: #fef2f2;
    }
}

/* 桌面端恢复显示navbar-collapse，隐藏侧边栏 */
@media (min-width: 992px) {
    .navbar-toggler {
        display: none !important;
    }

    .mobile-sidebar,
    .sidebar-overlay {
        display: none !important;
    }
}

/* ===== 来源: pages-modern.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */
/**
 * 功能页面现代化样式
 * 用于物品入库、借用、管理等页面
 */

/* ==================== 页面头部 ==================== */
.page-header-modern {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 28px 32px;
    margin-bottom: 28px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.8);
    position: relative;
    overflow: hidden;
}

.page-header-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #1d4ed8, #2563eb, #ec4899);
}

.page-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.page-title-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.page-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.3);
}

.page-title-text h1 {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 4px 0;
    letter-spacing: -0.02em;
}

.page-title-text p {
    color: #64748b;
    font-size: 0.9375rem;
    margin: 0;
}

.page-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ==================== 主内容区卡片 ==================== */
.main-content-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.8);
    overflow: hidden;
}

.card-section {
    padding: 28px 32px;
    border-bottom: 1px solid #f1f5f9;
}

.card-section:last-child {
    border-bottom: none;
}

.section-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title i {
    color: #1d4ed8;
    font-size: 1rem;
}

/* ==================== 表单样式优化 ==================== */
.modern-form .form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.modern-form .form-group {
    margin-bottom: 0;
}

.modern-form label {
    display: block;
    font-weight: 600;
    font-size: 0.875rem;
    color: #374151;
    margin-bottom: 8px;
}

.modern-form label .required {
    color: #ef4444;
    margin-left: 2px;
}

.modern-form .form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    transition: all 0.2s ease;
    background: white;
}

.modern-form .form-control:focus {
    outline: none;
    border-color: #1d4ed8;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.modern-form textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

/* ==================== 表格样式优化 ==================== */
.modern-table-wrapper {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.modern-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
}

.modern-table thead {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
}

.modern-table th {
    padding: 16px 20px;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
    border-bottom: 2px solid #e2e8f0;
    white-space: nowrap;
}

.modern-table td {
    padding: 16px 20px;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
    font-size: 0.9375rem;
}

.modern-table tbody tr {
    transition: all 0.2s ease;
}

.modern-table tbody tr:hover {
    background: #f8fafc;
}

.modern-table tbody tr:last-child td {
    border-bottom: none;
}

/* 表格中的头像 */
.table-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.table-avatar-default {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
}

/* ==================== 操作按钮组 ==================== */
.action-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
}

.btn-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.875rem;
}

.btn-icon-view {
    background: #dbeafe;
    color: #1d4ed8;
}

.btn-icon-view:hover {
    background: #1d4ed8;
    color: white;
}

.btn-icon-edit {
    background: #fef3c7;
    color: #d97706;
}

.btn-icon-edit:hover {
    background: #f59e0b;
    color: white;
}

.btn-icon-delete {
    background: #fee2e2;
    color: #dc2626;
}

.btn-icon-delete:hover {
    background: #ef4444;
    color: white;
}

.btn-icon-print {
    background: #d1fae5;
    color: #059669;
}

.btn-icon-print:hover {
    background: #10b981;
    color: white;
}

/* ==================== 搜索和筛选栏 ==================== */
.filter-bar-modern {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 280px;
}

.search-box i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1rem;
}

.search-box input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    transition: all 0.2s;
    background: white;
}

.search-box input:focus {
    outline: none;
    border-color: #1d4ed8;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.filter-select-modern {
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    background: white;
    min-width: 160px;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-select-modern:focus {
    outline: none;
    border-color: #1d4ed8;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

/* ==================== 状态标签 ==================== */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 20px;
}

.status-badge::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.status-active {
    background: #d1fae5;
    color: #065f46;
}

.status-active::before {
    background: #10b981;
}

.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.status-pending::before {
    background: #f59e0b;
}

.status-completed {
    background: #dbeafe;
    color: #1e40af;
}

.status-completed::before {
    background: #2563eb;
}

.status-cancelled {
    background: #f3f4f6;
    color: #6b7280;
}

.status-cancelled::before {
    background: #9ca3af;
}

/* ==================== 分页组件 ==================== */
.pagination-modern {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
}

.page-btn {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid #e5e7eb;
    background: white;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #4b5563;
    cursor: pointer;
    transition: all 0.2s;
}

.page-btn:hover:not(:disabled) {
    border-color: #1d4ed8;
    color: #1d4ed8;
}

.page-btn.active {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    border-color: transparent;
    color: white;
}

.page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.page-info {
    padding: 0 16px;
    color: #6b7280;
    font-size: 0.875rem;
}

/* ==================== 空状态 ==================== */
.empty-state-modern {
    text-align: center;
    padding: 60px 24px;
}

.empty-state-modern .empty-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: #9ca3af;
}

.empty-state-modern h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 8px;
}

.empty-state-modern p {
    color: #6b7280;
    margin-bottom: 24px;
}

/* ==================== 物品列表样式 ==================== */
.items-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.item-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.item-row:hover {
    border-color: #1d4ed8;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.1);
}

.item-emoji {
    width: 45px;
    height: 42px;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.item-info {
    flex: 1;
    min-width: 0;
}

.item-name {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 2px;
}

.item-code {
    font-size: 0.8125rem;
    color: #6b7280;
}

.item-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    color: #6b7280;
    font-size: 0.875rem;
}

.item-quantity {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #f3f4f6;
    border-radius: 8px;
    font-weight: 600;
}

/* ==================== 响应式优化 ==================== */
@media (max-width: 768px) {
    .page-header-modern {
        padding: 20px 24px;
        margin-bottom: 20px;
    }
    
    .page-header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .page-icon {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }
    
    .page-title-text h1 {
        font-size: 1.25rem;
    }
    
    .card-section {
        padding: 20px 24px;
    }
    
    .modern-form .form-row {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-wrap: wrap;
    }
    
    .filter-bar-modern {
        flex-direction: column;
    }
    
    .search-box {
        min-width: auto;
    }

    /* 全局卡片内边距缩减 */
    .card.p-4 {
        padding: 1rem !important;
    }

    /* 全局多按钮头部区域 - 移动端纵向排列 */
    .card.p-4 > .d-flex.justify-content-between:first-of-type {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.75rem;
    }

    .card.p-4 > .d-flex.justify-content-between:first-of-type h3,
    .card.p-4 > .d-flex.justify-content-between:first-of-type .h4 {
        font-size: 1.15rem;
        width: 100%;
    }

    .card.p-4 > .d-flex.justify-content-between:first-of-type > div {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        width: 100%;
    }

    .card.p-4 > .d-flex.justify-content-between:first-of-type > div .btn,
    .card.p-4 > .d-flex.justify-content-between:first-of-type > div a.btn {
        flex: 1;
        min-width: 0;
        white-space: nowrap;
        font-size: 0.8rem;
        padding: 0.4rem 0.6rem;
    }
}

/* ==================== 动画效果 ==================== */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    animation: slideInUp 0.5s ease;
}

/* 延迟动画 */
.stagger-1 { animation-delay: 0.05s; }
.stagger-2 { animation-delay: 0.1s; }
.stagger-3 { animation-delay: 0.15s; }
.stagger-4 { animation-delay: 0.2s; }
.stagger-5 { animation-delay: 0.25s; }

/* ===== 来源: custom-select.css（取自生产备份 2026-09-26，级联顺序与原 header.php 加载顺序一致） ===== */
/* ==================== 自定义下拉菜单组件样式 ==================== */

/* 自定义下拉菜单容器 - 默认自适应内容宽度 */
.custom-select {
    position: relative;
    width: auto;
    display: inline-block;
    font-size: 0.9rem;
    min-width: 120px;
}

/* 表单中的下拉菜单使用 100% 宽度 */
.form-select-wrapper .custom-select,
.form-group .custom-select,
.col-sm-6 .custom-select,
.col-md-6 .custom-select,
.mb-3 .custom-select {
    width: 100%;
}

/* 下拉菜单触发按钮 */
.custom-select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 1rem;
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 46px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.custom-select-trigger:hover {
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.custom-select.open .custom-select-trigger {
    border-color: #2563eb;
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.15), 0 4px 12px rgba(59, 130, 246, 0.1);
}

/* 选中的文本 */
.custom-select-text {
    color: #1e293b;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.custom-select-text.placeholder {
    color: #94a3b8;
    /* 抵消 Bootstrap .placeholder 骨架屏类（同名冲突）：灰底/半透明/min-height 会让
       自定义下拉的占位文字渲染成一整块灰色（logs/inbound 等页的类型下拉均受影响） */
    background-color: transparent;
    display: inline;
    min-height: 0;
    opacity: 1;
    cursor: pointer;
}

/* 下拉箭头图标 */
.custom-select-arrow {
    width: 20px;
    height: 20px;
    margin-left: 0.75rem;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.custom-select-arrow svg {
    width: 100%;
    height: 100%;
    fill: #64748b;
}

.custom-select.open .custom-select-arrow {
    transform: rotate(180deg);
}

.custom-select.open .custom-select-arrow svg {
    fill: #2563eb;
}

/* 下拉选项面板 */
.custom-select-options {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: white;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
    z-index: 1080; /* 9999→1080：仍高于页面与 Bootstrap 弹窗(1055)，不再盖住弹窗标题栏；toast(1090) 保持最上（2026-09-30） */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px) scale(0.98);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 320px;
    overflow-y: auto;
    overflow-x: hidden;
}

.custom-select.open .custom-select-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* 搜索框（可选项） */
.custom-select-search {
    padding: 0.75rem;
    border-bottom: 1px solid #f1f5f9;
    position: sticky;
    top: 0;
    background: white;
    z-index: 1;
}

.custom-select-search input {
    width: 100%;
    padding: 0.5rem 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem; /* 16px 防 iOS 聚焦放大（2026-09-30） */
    outline: none;
    transition: all 0.2s ease;
}

.custom-select-search input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.1);
}

.custom-select-search input::placeholder {
    color: #94a3b8;
}

/* 选项列表 */
.custom-select-option {
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid #f8fafc;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.custom-select-option:last-child {
    border-bottom: none;
}

.custom-select-option:hover {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.custom-select-option.selected {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
}

.custom-select-option.selected .custom-select-option-icon,
.custom-select-option.selected .custom-select-option-text {
    color: white;
}

/* 选项图标 */
.custom-select-option-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.custom-select-option-icon svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* 选项文本 */
.custom-select-option-text {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 选中标记 */
.custom-select-check {
    width: 18px;
    height: 18px;
    opacity: 0;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.custom-select-option.selected .custom-select-check {
    opacity: 1;
}

.custom-select-check svg {
    width: 100%;
    height: 100%;
    fill: white;
}

/* 空状态 */
.custom-select-empty {
    padding: 2rem 1rem;
    text-align: center;
    color: #94a3b8;
}

.custom-select-empty-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    opacity: 0.5;
}

/* 分组标题 */
.custom-select-group-title {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: #f8fafc;
}

/* 分割线 */
.custom-select-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.5rem 0;
}

/* 小尺寸变体 */
.custom-select.sm .custom-select-trigger {
    padding: 0.4rem 0.75rem;
    min-height: 38px;
    font-size: 0.85rem;
    border-radius: 10px;
}

.custom-select.sm .custom-select-arrow {
    width: 16px;
    height: 16px;
    margin-left: 0.5rem;
}

.custom-select.sm .custom-select-options {
    border-radius: 10px;
}

.custom-select.sm .custom-select-option {
    padding: 0.6rem 0.75rem;
    font-size: 0.85rem;
}

/* 大尺寸变体 */
.custom-select.lg .custom-select-trigger {
    padding: 0.75rem 1.25rem;
    min-height: 54px;
    font-size: 1rem;
    border-radius: 14px;
}

.custom-select.lg .custom-select-arrow {
    width: 24px;
    height: 24px;
}

.custom-select.lg .custom-select-options {
    border-radius: 14px;
}

.custom-select.lg .custom-select-option {
    padding: 0.875rem 1.25rem;
    font-size: 1rem;
}

/* 禁用状态 */
.custom-select.disabled .custom-select-trigger {
    background: #f1f5f9;
    cursor: not-allowed;
    opacity: 0.7;
}

.custom-select.disabled .custom-select-trigger:hover {
    border-color: #e2e8f0;
    transform: none;
    box-shadow: none;
}

/* 错误状态 */
.custom-select.error .custom-select-trigger {
    border-color: #ef4444;
}

.custom-select.error .custom-select-trigger:hover {
    border-color: #dc2626;
}

/* 带动画的高亮效果 */
@keyframes customSelectPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(59, 130, 246, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    }
}

.custom-select.highlight .custom-select-trigger {
    animation: customSelectPulse 0.6s ease-out;
}

/* 滚动条美化 */
.custom-select-options::-webkit-scrollbar {
    width: 6px;
}

.custom-select-options::-webkit-scrollbar-track {
    background: transparent;
    margin: 4px 0;
}

.custom-select-options::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.custom-select-options::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* 移动端优化 */
@media (max-width: 576px) {
    .custom-select-options {
        max-height: 280px;
        border-radius: 10px;
    }
    
    .custom-select-option {
        padding: 0.875rem 1rem;
    }
}

/* 多选模式 */
.custom-select.multiple .custom-select-option.selected {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    color: #2563eb;
}

.custom-select.multiple .custom-select-option.selected .custom-select-option-text {
    color: #1e293b;
}

.custom-select.multiple .custom-select-option.selected .custom-select-check svg {
    fill: #2563eb;
}

/* 显示标签的多选 */
.custom-select-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    flex: 1;
}

.custom-select-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.6rem;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.custom-select-tag-remove {
    width: 14px;
    height: 14px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.custom-select-tag-remove:hover {
    opacity: 1;
}

.custom-select-tag-remove svg {
    width: 100%;
    height: 100%;
    fill: white;
}

/* ===== 导航溢出收纳（2026-09-27） =====
 * 菜单项过多时不再逐字竖排：nowrap 保证文字完整，
 * 超出容器宽度的项由 footer.php 的脚本自动移入「更多 ▾」下拉。 */
.modern-navbar .nav-link {
    white-space: nowrap;
}
.modern-navbar .navbar-nav {
    flex-wrap: nowrap;
}
.nav-more-item { position: relative; }
.nav-more-toggle {
    display: none;              /* 无溢出时隐藏「更多」 */
    align-items: center;
    gap: 4px;
    cursor: pointer;
}
.nav-more-menu {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    list-style: none;
    margin: 0;
    min-width: 180px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,.12);
    padding: 6px;
    z-index: 2000;
}
.nav-more-item.open .nav-more-menu { display: block; }
.nav-more-menu .nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 8px;
    color: #374151;
}
.nav-more-menu .nav-link:hover { background: #f3f4f6; }
.nav-more-menu .nav-link.active { color: #1d4ed8; background: #eff6ff; }

/* ===== 移动端图标按钮热区（操作按钮 ≥40px，带描边可见） ===== */
@media (max-width: 768px) {
    .btn-sm.btn-icon-only {
        min-width: 42px;
        min-height: 40px;
        padding: .35rem .55rem;
        background-color: #fff;
        border: 1px solid currentColor;
    }
}

/* ===== 移动端防横向晃动（2026-09-27） =====
 * 首页存在来源不明的 101px 幽灵横向溢出（无盒子超出视口但 scrollWidth=491），
 * 根元素 overflow-x: clip 直接禁止横向滚动（clip 不会创建滚动容器） */
@media (max-width: 768px) {
    html, body {
        overflow-x: clip;
    }
}

/* ==================== 手机端触控热区（2026-09-27） ====================
 * 复选框视觉尺寸基本不变，但热区扩到 ≥40px（叠透明 ::before 层）；
 * 表格/卡片内的小徽章保持尺寸。仅手机端生效。 */
@media (max-width: 767.98px) {
    /* 复选框热区放大（透明覆盖层不改变视觉） */
    .form-check-input[type="checkbox"] {
        position: relative;
    }
    .form-check-input[type="checkbox"]::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 40px;
        height: 40px;
        transform: translate(-50%, -50%);
    }
    /* 徽章保持尺寸即可点击（自身就是展示元素，热区由所在行承担） */

    /* 小型操作按钮（非 icon-only）热区增高 */
    .btn-sm {
        min-height: 36px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

/* ==================== 手机端触控热区补丁扩展（2026-09-30） ====================
 * 扩展上方 2026-09-27 的热区补丁（不重复其选择器）：
 * 1) 纳入审计点名的 5 个漏网独立复选框类（尺寸定义在各页面 css，这里只叠 40px 透明热区层）；
 * 2) .toggle-switch 可点区域从 52×28 补足到 40px 高；
 * 3) .sidebar-close 32×32 → 40×40。
 * .btn-sm 宽度评估：文字型小按钮实际宽度均 ≥40px（中文两字+内边距），
 * 且上方 3346 行补丁已给 icon-only 变体 42×40，无需再补 min-width。 */
@media (max-width: 767.98px) {
    /* 漏网复选框：视觉不变，热区扩到 ≥40px（透明覆盖层写法同 .form-check-input） */
    .checkbox-input,
    .preference-checkbox,
    .category-checkbox,
    .item-select-checkbox,
    .user-checkbox {
        position: relative;
    }
    .checkbox-input::before,
    .preference-checkbox::before,
    .category-checkbox::before,
    .item-select-checkbox::before,
    .user-checkbox::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 40px;
        height: 40px;
        transform: translate(-50%, -50%);
    }

    /* 开关组件：input 为 0×0，滑轨仅 28px 高；叠 40px 高透明层补足上下热区。
       .toggle-switch 自带 position:relative，::after 属于 label 点击即触发 input */
    .toggle-switch::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 52px;
        height: 40px;
        transform: translate(-50%, -50%);
    }

    /* 侧边栏关闭按钮 32×32 → 40×40（手机端触控标准，直改视觉尺寸） */
    .sidebar-close {
        width: 40px;
        height: 40px;
    }
}

/* 首页 hero 与卡片区间距已随 v2 主页重构（2026-10-02）在
 * css/homepage-modern.css 内直接定义，此处旧覆写规则已移除。 */
