:root {
            --bg-dark: #020617;
            --text-primary: #f8fafc;
            --text-secondary: #94a3b8;
            --accent-main: #8b5cf6;
            --glass-bg: rgba(30, 41, 59, 0.4);
            --glass-border: rgba(255, 255, 255, 0.08);
            --stat-num: #ffffff;
        }
        [data-theme="light"] {
            --bg-dark: #ffffff;
            --text-primary: #020617;
            --text-secondary: #334155;
            --glass-bg: #f8fafc;
            --glass-border: #ccd3e0;
            --stat-num: #020617;
        }
        body {
            background-color: var(--bg-dark);
            color: var(--text-primary);
            font-family: 'Inter', system-ui, sans-serif;
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        }
        html {
            font-size: 15px;
        }
        .dashboard-shell {
            width: min(96vw, 2400px);
        }
        .dashboard-tall-panel {
            height: clamp(680px, 72vh, 980px);
        }
        .dashboard-stat-panel {
            min-height: 2.15rem;
            width: 30rem;
            min-width: 30rem;
            max-width: 30rem;
            justify-content: flex-start;
            font-variant-numeric: tabular-nums;
            white-space: nowrap;
            overflow: hidden;
            box-sizing: border-box;
        }
        .dashboard-monitor-header {
            align-items: center;
            gap: 1rem;
        }
        .dashboard-monitor-title {
            white-space: nowrap;
        }
        .stat-cell {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            white-space: nowrap;
            font-variant-numeric: tabular-nums;
            line-height: 1;
        }
        .stat-cell-day { width: 7.2rem; }
        .stat-cell-active { width: 6.2rem; }
        .stat-cell-metric { width: 4.8rem; }
        .stat-divider {
            display: inline-block;
            width: 1px;
            height: 0.8rem;
            background: rgba(100, 116, 139, 0.2);
            flex: 0 0 auto;
        }
        .dashboard-day-toolbar {
            min-height: 3.25rem;
            height: 3.25rem;
            overflow: hidden;
            box-sizing: border-box;
        }
        .day-toolbar-row {
            height: 100%;
            flex-wrap: nowrap;
            align-items: center;
        }
        .day-nav-btn {
            width: 6.4rem;
            height: 2rem;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            white-space: nowrap;
            font-variant-numeric: tabular-nums;
        }
        .day-badge {
            width: 9.5rem;
            min-width: 9.5rem !important;
            max-width: 9.5rem;
            height: 2rem;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            white-space: nowrap;
            overflow: hidden;
            font-variant-numeric: tabular-nums;
        }
        .day-picker-input {
            width: 9.5rem !important;
            min-width: 9.5rem;
            max-width: 9.5rem;
            height: 2rem;
            font-variant-numeric: tabular-nums;
            box-sizing: border-box;
            appearance: none;
            -webkit-appearance: none;
            flex: 0 0 9.5rem;
        }
        .day-today-btn {
            width: 4.9rem;
            height: 2rem;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            white-space: nowrap;
        }
        .glass { background: var(--glass-bg); border: 1px solid var(--glass-border); box-shadow: 0 10px 30px -10px rgba(0,0,0,0.1); transition: all 0.3s; }
        .gradient-text {
            background: linear-gradient(135deg, #c084fc 0%, #6366f1 50%, #3b82f6 100%);
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
        }
        .section-label {
            color: var(--text-secondary);
            font-weight: 800;
            text-transform: uppercase;
            letter-spacing: 0.1em;
            font-size: 0.85rem;
        }
        .stat-number {
            color: var(--stat-num) !important;
            font-size: 4.5rem;
            font-weight: 900;
            font-style: italic;
            letter-spacing: -0.05em;
        }
        .pulse-online { animation: pulse-red 2s infinite; }
        @keyframes pulse-red {
            0% { transform: scale(1); opacity: 1; }
            50% { transform: scale(1.6); opacity: 0.1; }
            100% { transform: scale(1); opacity: 1; }
        }

        /* 2K/4K: 吃满更多宽度，字号和面板高度提升 */
        @media (min-width: 1920px) {
            html {
                font-size: 16px;
            }
            .dashboard-shell {
                width: min(97vw, 3000px);
            }
            .dashboard-main-grid {
                gap: 2.25rem;
            }
            .dashboard-kpi-grid {
                gap: 1.75rem;
            }
            .dashboard-tall-panel {
                height: clamp(760px, 74vh, 1120px);
            }
            .stat-number {
                font-size: 5rem;
            }
        }

        /* 超宽屏：进一步放大，减少两侧空白 */
        @media (min-width: 2560px) {
            html {
                font-size: 17px;
            }
            .dashboard-shell {
                width: min(98vw, 3600px);
            }
            .dashboard-main-grid {
                gap: 2.5rem;
            }
            .dashboard-kpi-grid {
                gap: 2rem;
            }
            .dashboard-tall-panel {
                height: clamp(840px, 76vh, 1280px);
            }
            .stat-number {
                font-size: 5.6rem;
            }
        }

        /* 1366~1536: 适度收缩字号和间距 */
        @media (max-width: 1536px) {
            html {
                font-size: 14px;
            }
            .dashboard-shell {
                width: min(98vw, 1700px);
            }
            .dashboard-main-grid {
                gap: 1.5rem;
            }
            .dashboard-kpi-grid {
                gap: 1.25rem;
            }
            .dashboard-tall-panel {
                height: clamp(620px, 70vh, 900px);
            }
            .stat-number {
                font-size: 4rem;
            }
        }

        /* 平板/小笔记本：布局允许换行并取消固定高 */
        @media (max-width: 1279px) {
            .dashboard-nav {
                flex-wrap: wrap;
                gap: 1rem;
                margin-bottom: 1.25rem;
            }
            .dashboard-tall-panel {
                height: auto;
                min-height: 0;
            }
            .dashboard-user-grid {
                overflow: visible;
            }
            .dashboard-stat-panel {
                min-width: 0;
                width: 100%;
                max-width: 100%;
            }
            .dashboard-monitor-header {
                flex-wrap: wrap;
                justify-content: space-between;
                align-items: flex-end;
            }
            .dashboard-monitor-title {
                white-space: normal;
            }
        }

        /* 手机：进一步压缩 */
        @media (max-width: 768px) {
            html {
                font-size: 13px;
            }
            .dashboard-shell {
                width: 100%;
            }
            body {
                padding: 0.75rem !important;
            }
            .dashboard-nav {
                align-items: stretch;
                gap: 0.75rem;
            }
            .dashboard-brand {
                gap: 0.6rem;
            }
            .dashboard-logo {
                width: 2.15rem;
                height: 2.15rem;
            }
            .dashboard-title {
                font-size: 1.15rem;
                line-height: 1.25;
            }
            .dashboard-subtitle {
                font-size: 0.56rem;
                letter-spacing: 0.08em;
                margin-top: 0.2rem;
            }
            .dashboard-actions {
                width: 100%;
                justify-content: space-between;
                gap: 0.5rem;
            }
            .dashboard-action-pill {
                width: 100%;
                justify-content: space-between;
            }
            .dashboard-sync-btn {
                flex: 1 1 auto;
                justify-content: center;
                padding-top: 0.55rem;
                padding-bottom: 0.55rem;
                font-size: 0.68rem;
            }
            .dashboard-kpi-grid {
                gap: 0.75rem;
                margin-bottom: 1rem;
            }
            .dashboard-kpi-grid > .glass {
                padding: 1rem;
                border-radius: 0.85rem;
            }
            .dashboard-main-grid {
                gap: 0.85rem;
            }
            .dashboard-main-grid > div {
                border-radius: 0.85rem;
                padding: 1rem;
            }
            .dashboard-user-grid {
                grid-template-columns: minmax(0, 1fr);
                gap: 0.75rem;
                max-height: none;
            }
            .dashboard-user-grid > div {
                height: auto !important;
                min-height: 10rem;
            }
            .dashboard-day-toolbar {
                min-height: 0;
                height: auto;
            }
            .day-nav-btn {
                width: 5.8rem;
                height: 1.9rem;
                font-size: 0.65rem;
            }
            .day-badge {
                width: 8.7rem;
                min-width: 8.7rem !important;
                max-width: 8.7rem;
                height: 1.9rem;
                font-size: 0.68rem;
            }
            .day-picker-input {
                width: 8.7rem !important;
                min-width: 8.7rem;
                max-width: 8.7rem;
                height: 1.9rem;
            }
            .day-today-btn {
                width: 4.45rem;
                height: 1.9rem;
                font-size: 0.62rem;
            }
            .stat-number {
                font-size: 3.2rem;
            }
            .section-label {
                font-size: 0.7rem;
            }
        }

        @media (max-width: 480px) {
            html {
                font-size: 12px;
            }
            body {
                padding: 0.55rem !important;
            }
            .dashboard-title {
                font-size: 1.02rem;
            }
            .dashboard-subtitle {
                display: none;
            }
            .dashboard-kpi-grid > .glass,
            .dashboard-main-grid > div {
                padding: 0.82rem;
            }
            .stat-number {
                font-size: 2.6rem;
            }
        }

