/* ==========================================
   Premium Design System & Modern Global Styles
   ========================================== */

:root {
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    
    /* Light Mode - Warm Glass & HSL Tailored Hues */
    --bg-gradient: linear-gradient(135deg, #f5f7fa 0%, #e4ebf0 100%);
    --bg: hsl(210, 20%, 98%);
    --surface: rgba(255, 255, 255, 0.72);
    --surface-solid: #ffffff;
    --surface-muted: rgba(241, 245, 249, 0.5);
    --text: hsl(222, 47%, 12%);
    --text-muted: hsl(215, 16%, 47%);
    --border: rgba(148, 163, 184, 0.12);
    --border-strong: rgba(148, 163, 184, 0.25);
    
    /* Vibrant Harmonies */
    --primary: hsl(162, 84%, 38%);
    --primary-dark: hsl(162, 84%, 30%);
    --primary-soft: rgba(16, 185, 129, 0.12);
    
    --blue: hsl(239, 84%, 66%);
    --blue-dark: hsl(239, 84%, 58%);
    --blue-soft: rgba(99, 102, 241, 0.12);
    
    --amber: hsl(36, 100%, 48%);
    --amber-dark: hsl(36, 100%, 40%);
    --amber-soft: rgba(245, 158, 11, 0.12);
    
    --rose: hsl(343, 89%, 56%);
    --rose-dark: hsl(343, 89%, 48%);
    --rose-soft: rgba(244, 63, 94, 0.12);
    
    --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 10px 30px -10px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 20px 50px -12px rgba(15, 23, 42, 0.12);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    /* Dark Mode - Obsidian Depth & Neon Accents */
    --bg-gradient: linear-gradient(135deg, #0b0f17 0%, #0f172a 100%);
    --bg: hsl(220, 24%, 6%);
    --surface: rgba(15, 23, 42, 0.65);
    --surface-solid: #0f172a;
    --surface-muted: rgba(30, 41, 59, 0.45);
    --text: hsl(210, 40%, 98%);
    --text-muted: hsl(215, 20%, 65%);
    --border: rgba(255, 255, 255, 0.06);
    --border-strong: rgba(255, 255, 255, 0.15);
    
    --primary: hsl(162, 84%, 42%);
    --primary-dark: hsl(162, 84%, 48%);
    --primary-soft: rgba(16, 185, 129, 0.18);
    
    --blue: hsl(239, 84%, 72%);
    --blue-dark: hsl(239, 84%, 78%);
    --blue-soft: rgba(99, 102, 241, 0.18);
    
    --amber: hsl(36, 100%, 58%);
    --amber-dark: hsl(36, 100%, 65%);
    --amber-soft: rgba(245, 158, 11, 0.18);
    
    --rose: hsl(343, 89%, 64%);
    --rose-dark: hsl(343, 89%, 70%);
    --rose-soft: rgba(244, 63, 94, 0.18);
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 20px 50px -12px rgba(0, 0, 0, 0.6);
}

/* ==========================================
   Base resets & layouts
   ========================================== */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    min-width: 320px;
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    color: var(--text);
    background: var(--bg-gradient);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    transition: background 0.4s ease, color 0.4s ease;
}

/* Background Ambient Lighting blobs */
.glass-bg-blur {
    position: absolute;
    width: 600px;
    height: 600px;
    top: -200px;
    left: 20%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.08) 0%, rgba(16, 185, 129, 0.05) 50%, transparent 100%);
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
}

[data-theme="dark"] .glass-bg-blur {
    background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, rgba(16, 185, 129, 0.08) 50%, transparent 100%);
}

.container {
    width: min(1520px, calc(100% - 48px));
    margin: 0 auto;
    padding: 40px 0 60px;
    position: relative;
    z-index: 1;
}

/* ==========================================
   Header section
   ========================================== */

.header-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 35px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 24px;
}

.header-main-info {
    flex: 1;
}

.header-kicker {
    display: inline-block;
    color: var(--primary);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 6px;
}

h1 {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 2.3rem;
    font-weight: 900;
    letter-spacing: -0.025em;
    line-height: 1.15;
}

.header-subtitle {
    margin-top: 8px;
    color: var(--text-muted);
    font-size: 0.98rem;
    font-weight: 500;
}

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-muted);
    background: var(--surface);
    backdrop-filter: blur(8px);
    font-size: 1.3rem;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.theme-toggle:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: var(--primary-soft);
    transform: rotate(15deg) scale(1.05);
    box-shadow: 0 0 15px var(--primary-soft);
}

/* ==========================================
   Action Bar
   ========================================== */

.action-bar {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}

.add-record-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 22px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: var(--radius-md);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.add-record-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
    filter: brightness(1.05);
}

.add-record-btn:active {
    transform: translateY(0);
}

.btn-icon-svg {
    width: 18px;
    height: 18px;
}

/* ==========================================
   Dashboard Grid Layout (Main Content + Sidebar)
   ========================================== */

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 30px;
    align-items: start;
}

@media (min-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr 340px;
    }
}

.dashboard-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0;
}

.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ==========================================
   Premium Stats Section (KPI Cards Hierarchy)
   ========================================== */

.stats-section {
    margin-bottom: 0px;
}

.stats-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 1200px) {
    .stats-cards {
        grid-template-columns: 1.15fr 2fr;
    }
}

/* Big Hero Card Styling */
.hero-stat-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%) !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.35) !important;
    position: relative;
    overflow: hidden;
}

.hero-stat-card .stat-label {
    color: rgba(255, 255, 255, 0.8) !important;
    font-size: 0.9rem;
    font-weight: 700;
}

.hero-stat-card .stat-value {
    color: #ffffff !important;
    font-size: 2.2rem !important;
    font-weight: 900;
    margin-top: 12px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.hero-stat-card .stat-icon {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.18) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Secondary Stats Grid */
.sub-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

@media (max-width: 768px) {
    .sub-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .sub-stats-grid {
        grid-template-columns: 1fr;
    }
}

.stat-card {
    position: relative;
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: var(--transition);
}

.stat-card-glow {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

.card-1 .stat-card-glow { background: rgba(16, 185, 129, 0.15); top: -20px; right: -20px; }
.card-2 .stat-card-glow { background: rgba(99, 102, 241, 0.15); top: -20px; right: -20px; }
.card-3 .stat-card-glow { background: rgba(245, 158, 11, 0.15); top: -20px; right: -20px; }
.card-4 .stat-card-glow { background: rgba(244, 63, 94, 0.15); top: -20px; right: -20px; }

.stat-card:not(.hero-stat-card):hover {
    transform: translateY(-4px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.hero-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 30px -5px rgba(16, 185, 129, 0.45) !important;
}

.stat-card:hover .stat-card-glow {
    opacity: 1;
}

.stat-header {
    display: flex;
    align-items: center;
    gap: 14px;
    height: 100%;
}

.stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--radius-md);
    flex-shrink: 0;
    transition: var(--transition);
}

.stat-icon svg {
    width: 20px;
    height: 20px;
}

.card-1 .stat-icon { color: var(--primary); background: var(--primary-soft); }
.card-2 .stat-icon { color: var(--blue); background: var(--blue-soft); }
.card-3 .stat-icon { color: var(--amber); background: var(--amber-soft); }
.card-4 .stat-icon { color: var(--rose); background: var(--rose-soft); }

.stat-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.stat-value {
    margin-top: 6px;
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.stat-value-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
}

.year-end-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    margin: 0;
    padding: 4px 10px;
    background: var(--rose-soft);
    border: 1px solid rgba(244, 63, 94, 0.2);
    border-radius: var(--radius-sm);
    color: var(--rose);
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    z-index: 5;
}

.year-end-btn:hover {
    background: var(--rose);
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(244, 63, 94, 0.2);
}

/* ==========================================
   Sidebar Card & Lists
   ========================================== */

.sidebar-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}

.sidebar-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.sidebar-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
}

.sidebar-card-title {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.settings-mini-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.settings-mini-btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.5s ease;
}

.settings-mini-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-soft);
}

.settings-mini-btn:hover svg {
    transform: rotate(45deg);
}

.sidebar-month-progress-section {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 24px;
    background: var(--surface-muted);
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.progress-ring-container {
    position: relative;
    width: 120px;
    height: 120px;
    flex-shrink: 0;
}

.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring__circle-bg {
    stroke: var(--border);
}

.progress-ring__circle {
    stroke-dasharray: 314.159;
    stroke-dashoffset: 314.159;
    transition: stroke-dashoffset 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: 50% 50%;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: none;
}

.progress-percentage {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.1;
}

.progress-label {
    font-size: 0.6rem;
    color: var(--text-muted);
    font-weight: 700;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.progress-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.progress-summary h4 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text);
}

.summary-desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.summary-desc strong {
    color: var(--text);
    font-weight: 700;
}

/* Sidebar Stat Items List */
.sidebar-stats-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sidebar-stat-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    transition: var(--transition);
}

.sidebar-stat-item:hover {
    border-color: var(--border-strong);
    background: var(--surface);
    transform: translateX(4px);
}

.item-label {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
}

.item-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.worked-dot { background: var(--blue); }
.remaining-dot { background: var(--amber); }
.earned-dot { background: var(--primary); }
.expected-dot { background: var(--rose); }

.item-value {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

/* Sidebar Highlight Items */
.highlight-item-1 {
    background: var(--primary-soft);
    border-color: rgba(16, 185, 129, 0.2);
}
.highlight-item-1 .item-value {
    color: var(--primary);
}

.highlight-item-2 {
    background: var(--rose-soft);
    border-color: rgba(244, 63, 94, 0.2);
}
.highlight-item-2 .item-value {
    color: var(--rose);
}

/* Yearly Sidebar Icons */
.sidebar-stat-item .stat-icon-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    margin-right: 4px;
}

.sidebar-stat-item .worked-icon { color: var(--primary); background: var(--primary-soft); }
.sidebar-stat-item .rest-icon { color: var(--blue); background: var(--blue-soft); }
.sidebar-stat-item .overtime-icon { color: var(--amber); background: var(--amber-soft); }
.sidebar-stat-item .tiaoxiu-icon { color: hsl(290, 84%, 60%); background: rgba(232, 121, 249, 0.12); }

[data-theme="dark"] .sidebar-stat-item .tiaoxiu-icon { color: hsl(290, 84%, 70%); background: rgba(240, 171, 252, 0.18); }

/* ==========================================
   Charts Section
   ========================================== */

.charts-section {
    margin-bottom: 0px;
}

.charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 768px) {
    .charts-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .charts-grid > .chart-container:first-child {
        grid-column: 1 / -1;
    }
}

.chart-container {
    padding: 24px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.chart-container h3 {
    font-family: var(--font-heading);
    margin-bottom: 18px;
    color: var(--text);
    font-size: 1rem;
    font-weight: 800;
}

.chart-inner-wrap {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.chart-container canvas {
    width: 100% !important;
    max-height: 240px;
}

.chart-container:hover {
    transform: translateY(-2px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
}

/* ==========================================
   Table View & Salary Records
   ========================================== */

.records-section {
    margin-bottom: 30px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-md);
    padding: 24px;
}

.records-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.filter-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.filter-controls label {
    font-family: var(--font-heading);
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 700;
}

#monthFilter {
    min-height: 38px;
    min-width: 160px;
    padding: 0 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text);
    background: var(--surface-muted);
    font-family: var(--font-body);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    outline: none;
}

#monthFilter:hover {
    border-color: var(--border-strong);
}

#monthFilter:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-soft);
    background: var(--surface-solid);
}

.table-container {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-solid);
    box-shadow: var(--shadow-sm);
}

#recordsTable {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    min-width: 1200px;
}

#recordsTable thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
    background: var(--surface-muted);
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: left;
}

#recordsTable tbody td {
    padding: 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
    white-space: nowrap;
}

#recordsTable tbody tr:last-child td {
    border-bottom: none;
}

#recordsTable tbody tr {
    transition: var(--transition);
}

#recordsTable tbody tr:hover {
    background: var(--surface-muted);
}

#recordsTable tbody td:first-child {
    font-family: var(--font-heading);
    color: var(--text);
    font-weight: 800;
}

.salary-highlight {
    color: var(--primary) !important;
    font-family: var(--font-heading);
    font-weight: 800 !important;
}

.year-end-highlight {
    color: var(--amber) !important;
    font-family: var(--font-heading);
    font-weight: 800 !important;
}

.remark-cell {
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.table-action-col {
    width: 120px;
}

.edit-btn-table,
.delete-btn-table {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid var(--border);
    background: var(--surface-solid);
    color: var(--text);
}

.edit-btn-table:hover {
    border-color: var(--blue);
    color: var(--blue);
    background: var(--blue-soft);
}

.delete-btn-table:hover {
    border-color: var(--rose);
    color: var(--rose);
    background: var(--rose-soft);
}

.editing-row {
    background: var(--primary-soft) !important;
}

.editing-row td:first-child {
    box-shadow: inset 4px 0 0 var(--primary);
}

.empty-table {
    padding: 60px 20px !important;
    text-align: center;
}

.empty-table p:first-child {
    color: var(--text);
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 800;
    margin-bottom: 6px;
}

.empty-table p + p {
    color: var(--text-muted);
    font-size: 0.88rem;
}

/* ==========================================
   Modern Modals (Settings, Salary, Year End)
   ========================================== */

.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(12px);
    transition: opacity 0.3s ease;
}

[data-theme="dark"] .modal {
    background: rgba(0, 0, 0, 0.7);
}

.modal.active {
    display: flex;
    animation: fadeIn 0.25s ease;
}

.modal-content {
    width: min(800px, 100%);
    max-height: min(90vh, 850px);
    overflow-y: auto;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-lg);
    background: var(--surface-solid);
    box-shadow: var(--shadow-lg);
    animation: modalPop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    flex-direction: column;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    background: var(--surface-muted);
}

.modal-title {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 1.2rem;
    font-weight: 800;
}

.close-modal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    background: transparent;
    border: none;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    transition: var(--transition);
}

.close-modal:hover {
    color: var(--text);
    background: var(--border);
}

.modal-body {
    padding: 24px;
}

/* Form layouts */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 700;
}

.hint-text {
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 600;
}

input[type="number"],
input[type="month"],
input[type="text"],
input[type="date"],
select {
    width: 100%;
    min-height: 42px;
    padding: 0 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text);
    background: var(--surface-muted);
    font-family: var(--font-body);
    font-weight: 600;
    outline: none;
    transition: var(--transition);
}

input[type="number"]:hover,
input[type="month"]:hover,
input[type="text"]:hover,
input[type="date"]:hover,
select:hover {
    border-color: var(--border-strong);
}

input[type="number"]:focus,
input[type="month"]:focus,
input[type="text"]:focus,
input[type="date"]:focus,
select:focus {
    border-color: var(--primary);
    background: var(--surface-solid);
    box-shadow: 0 0 0 3px var(--primary-soft);
}

input:read-only {
    color: var(--text-muted);
    background: rgba(148, 163, 184, 0.08);
    cursor: not-allowed;
    border-color: var(--border);
}

input:disabled,
select:disabled {
    color: var(--text-muted);
    background: rgba(148, 163, 184, 0.08);
    cursor: not-allowed;
    border-color: var(--border);
    opacity: 0.7;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
}

.submit-btn,
.cancel-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 100px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.submit-btn {
    border: none;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.submit-btn:hover {
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.3);
    transform: translateY(-1px);
}

.cancel-btn {
    border: 1px solid var(--border);
    background: var(--surface-solid);
    color: var(--text);
}

.cancel-btn:hover {
    border-color: var(--border-strong);
    background: var(--surface-muted);
}

/* ==========================================
   Year End Modal Specific
   ========================================== */

.year-end-modal {
    width: min(580px, 100%);
}

.year-end-modal .modal-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.year-end-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--amber) 0%, var(--amber-dark) 100%);
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.85rem;
}

.year-end-input-section {
    padding: 18px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
}

.year-end-form-row {
    display: flex;
    align-items: flex-end;
    gap: 12px;
}

.year-end-form-group {
    flex: 1;
}

.year-end-form-group label {
    display: block;
    margin-bottom: 6px;
    color: var(--text);
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 700;
}

.year-end-submit-btn {
    min-height: 42px;
    padding: 0 22px;
    border: none;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--amber) 0%, var(--amber-dark) 100%);
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.year-end-submit-btn:hover {
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.25);
    transform: translateY(-1px);
}

.year-end-remark-row {
    margin-top: 12px;
}

.year-end-history {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-solid);
    overflow: hidden;
}

.year-end-history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    border-bottom: 1px solid var(--border);
    background: var(--surface-muted);
}

.year-end-history-header h3 {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--text);
    font-weight: 800;
}

.year-end-total {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
}

.year-end-list {
    max-height: 280px;
    overflow-y: auto;
    padding: 16px;
}

.year-end-item {
    position: relative;
    padding: 14px 16px;
    margin-bottom: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    transition: var(--transition);
}

.year-end-item:last-child {
    margin-bottom: 0;
}

.year-end-item:hover {
    border-color: var(--border-strong);
    background: var(--surface-solid);
    box-shadow: var(--shadow-sm);
}

.year-end-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 30px;
}

.year-end-year {
    display: inline-flex;
    padding: 3px 10px;
    border-radius: 20px;
    background: var(--amber-soft);
    color: var(--amber-dark);
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 800;
}

[data-theme="dark"] .year-end-year {
    color: var(--amber);
}

.year-end-amount {
    color: var(--amber);
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.1rem;
}

.year-end-remark {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed var(--border);
    color: var(--text-muted);
    font-size: 0.82rem;
}

.delete-year-end {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    border: none;
    border-radius: 50%;
    color: var(--text-muted);
    background: transparent;
    font-size: 1.1rem;
    cursor: pointer;
    transition: var(--transition);
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.year-end-item:hover .delete-year-end {
    opacity: 1;
}

.delete-year-end:hover {
    color: var(--rose);
    background: var(--rose-soft);
}

.empty-year-end {
    padding: 40px 10px;
    color: var(--text-muted);
    text-align: center;
    font-size: 0.88rem;
}

/* ==========================================
   Calendar Settings Modal Specific (Grid Layout)
   ========================================== */

.calendar-settings-modal {
    width: min(1080px, 95vw);
    max-height: min(92vh, 800px);
}

.modal-grid-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 24px;
    padding: 24px;
    align-items: start;
    overflow-y: auto;
    max-height: calc(min(92vh, 800px) - 76px);
}

.settings-left-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    border-right: 1px solid var(--border);
    padding-right: 24px;
}

.settings-right-panel {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.settings-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.settings-form label {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 700;
}

.field-section-title {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 4px;
}

/* Weekdays Custom Checkboxes */
.custom-days-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 6px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    user-select: none;
}

.checkbox-label:hover {
    border-color: var(--primary);
    background: var(--primary-soft);
}

.checkbox-label input {
    margin: 0;
    width: 14px;
    height: 14px;
    accent-color: var(--primary);
}

.form-tip {
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.form-tip p {
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
}

.form-tip ul {
    padding-left: 14px;
}

.form-tip li {
    margin-bottom: 2px;
}

.danger-outline-btn {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--rose);
    border-radius: var(--radius-md);
    color: var(--rose);
    background: transparent;
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.danger-outline-btn:hover {
    background: var(--rose);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(244, 63, 94, 0.2);
}

/* ==========================================
   Heatmap Contribution Grid (Annual Calendar)
   ========================================== */

.contribution-section {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface-muted);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.contribution-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    background: var(--surface-solid);
}

.contribution-header h3 {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 0.92rem;
    font-weight: 800;
}

.contribution-legend {
    display: flex;
    gap: 12px;
}

.legend-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 600;
}

.legend-color {
    width: 10px;
    height: 10px;
    border-radius: 2px;
}

/* Colors for States */
.legend-color.work, .day-cell.work { background: var(--primary); }
.legend-color.rest, .day-cell.rest { background: rgba(148, 163, 184, 0.2); }
.legend-color.holiday, .day-cell.holiday { background: var(--blue); }
.legend-color.overtime, .day-cell.overtime { background: var(--amber); }
.legend-color.tiaoxiu, .day-cell.tiaoxiu { background: #e879f9; }

[data-theme="dark"] .legend-color.rest, 
[data-theme="dark"] .day-cell.rest { 
    background: rgba(255, 255, 255, 0.08); 
}

[data-theme="dark"] .legend-color.tiaoxiu, 
[data-theme="dark"] .day-cell.tiaoxiu { 
    background: #f0abfc; 
}

.contribution-grid {
    padding: 16px;
}

.contribution-months {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.contribution-month {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-solid);
}

.month-label {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 0.78rem;
    font-weight: 800;
    text-align: center;
    border-bottom: 1px dashed var(--border);
    padding-bottom: 4px;
    margin-bottom: 4px;
}

.month-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
    justify-items: center;
}

.weekday-label {
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.62rem;
    font-weight: 800;
}

.day-cell {
    width: 14px;
    height: 14px;
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    transition: transform 0.15s ease, filter 0.15s ease;
}

.check-mark {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.95);
    font-size: 8px;
    font-weight: 900;
    line-height: 1;
    pointer-events: none;
    text-shadow: 0 0.5px 1.5px rgba(0, 0, 0, 0.3);
}

.day-cell:not(.empty):hover {
    transform: scale(1.35);
    z-index: 5;
    filter: brightness(1.2);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.day-cell.empty {
    background: transparent;
    cursor: default;
}

/* Tooltips */
.day-tooltip {
    position: absolute;
    bottom: 140%;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    background: var(--surface-solid);
    border: 1px solid var(--border-strong);
    color: var(--text);
    font-size: 0.68rem;
    font-weight: 700;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.2s ease;
    pointer-events: none;
    z-index: 10;
}

.day-cell:hover .day-tooltip {
    opacity: 1;
    visibility: visible;
}

/* ==========================================
   Date Status Popover (Absolute Positioned Selector)
   ========================================== */

.date-status-popover {
    position: absolute;
    z-index: 2000;
    width: 200px;
    padding: 12px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    background: var(--surface-solid);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(12px);
    animation: popoverFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes popoverFadeIn {
    from { opacity: 0; transform: translateY(8px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.popover-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.popover-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 8px 4px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    background: var(--surface-solid);
    transition: var(--transition);
}

.popover-option:hover {
    border-color: var(--border-strong);
    background: var(--surface-muted);
}

.popover-option.active {
    border-color: var(--primary);
    background: var(--primary-soft);
}

.popover-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.popover-color.work { background: var(--primary); }
.popover-color.rest { background: rgba(148, 163, 184, 0.3); }
.popover-color.holiday { background: var(--blue); }
.popover-color.overtime { background: var(--amber); }
.popover-color.tiaoxiu { background: #e879f9; }

[data-theme="dark"] .popover-color.tiaoxiu { background: #f0abfc; }

.popover-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text);
}

/* ==========================================
   System Messages / Toast Notifications
   ========================================== */

.message {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 2500;
    max-width: 360px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 700;
    animation: slideInRight 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid transparent;
}

.message.success {
    color: hsl(162, 84%, 25%);
    border-color: rgba(16, 185, 129, 0.25);
    background: hsl(162, 84%, 94%);
}

.message.error {
    color: hsl(343, 89%, 30%);
    border-color: rgba(244, 63, 94, 0.25);
    background: hsl(343, 89%, 95%);
}

[data-theme="dark"] .message.success {
    color: hsl(162, 84%, 85%);
    border-color: rgba(16, 185, 129, 0.4);
    background: hsl(162, 84%, 12%);
}

[data-theme="dark"] .message.error {
    color: hsl(343, 89%, 85%);
    border-color: rgba(244, 63, 94, 0.4);
    background: hsl(343, 89%, 12%);
}

/* ==========================================
   Animations & Transitions
   ========================================== */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

/* ==========================================
   Yearly Statistics Section
   ========================================== */

.yearly-date-range {
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
}

.yearly-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.yearly-stat-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    transition: var(--transition);
}

.yearly-stat-card:hover {
    border-color: var(--border-strong);
    background: var(--surface);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.yearly-stat-icon-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    flex-shrink: 0;
}

.yearly-stat-icon-wrap svg {
    width: 20px;
    height: 20px;
}

.worked-icon { color: var(--primary); background: var(--primary-soft); }
.rest-icon { color: var(--blue); background: var(--blue-soft); }
.overtime-icon { color: var(--amber); background: var(--amber-soft); }
.tiaoxiu-icon { color: hsl(290, 84%, 60%); background: rgba(232, 121, 249, 0.12); }

[data-theme="dark"] .tiaoxiu-icon { color: hsl(290, 84%, 70%); background: rgba(240, 171, 252, 0.18); }

.yearly-stat-info {
    flex: 1;
}

.yearly-stat-label {
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
}

.yearly-stat-value {
    margin-top: 6px;
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

/* ==========================================
   Responsive for Yearly Stats
   ========================================== */

@media (max-width: 960px) {
    .yearly-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 540px) {
    .yearly-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   Responsive Breakpoints
   ========================================== */

@media (max-width: 1120px) {
    .contribution-months {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 960px) {
    .modal-grid-layout {
        grid-template-columns: 1fr;
        max-height: calc(min(92vh, 800px) - 76px);
    }

    .settings-left-panel {
        border-right: none;
        border-bottom: 1px solid var(--border);
        padding-right: 0;
        padding-bottom: 20px;
    }

    .contribution-months {
        grid-template-columns: repeat(2, 1fr);
        margin-top: 10px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 24px 0 40px;
    }

    .header-section {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .theme-toggle {
        align-self: flex-end;
    }

    h1 {
        font-size: 1.85rem;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column-reverse;
    }
    
    .submit-btn, .cancel-btn {
        width: 100%;
    }
}

@media (max-width: 540px) {
    .contribution-months {
        grid-template-columns: 1fr;
    }
    
    .custom-days-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .year-end-form-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .year-end-submit-btn {
        margin-top: 10px;
        width: 100%;
    }
}

/* ==========================================
   Sidebar Heatmap Calendar (Current Month)
   ========================================== */
.sidebar-month-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    justify-items: center;
    background: var(--surface-muted);
    padding: 12px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.sidebar-month-grid .weekday-label {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 800;
}

.sidebar-month-grid .day-cell {
    width: 26px;
    height: 26px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text);
    transition: transform 0.15s ease, filter 0.15s ease, box-shadow 0.15s ease;
}

.sidebar-month-grid .day-cell.empty {
    background: transparent;
    cursor: default;
}

.sidebar-month-grid .day-cell:not(.empty):hover {
    transform: scale(1.2);
    z-index: 5;
    filter: brightness(1.15);
    box-shadow: var(--shadow-sm);
}

/* 单元格状态颜色与文字配色适配 */
.sidebar-month-grid .day-cell.work {
    background: var(--primary);
    color: #ffffff;
}

.sidebar-month-grid .day-cell.rest {
    background: rgba(148, 163, 184, 0.15);
    color: var(--text-muted);
}
[data-theme="dark"] .sidebar-month-grid .day-cell.rest {
    background: rgba(255, 255, 255, 0.06);
}

.sidebar-month-grid .day-cell.holiday {
    background: var(--blue);
    color: #ffffff;
}

.sidebar-month-grid .day-cell.overtime {
    background: var(--amber);
    color: #ffffff;
}

.sidebar-month-grid .day-cell.tiaoxiu {
    background: #e879f9;
    color: #ffffff;
}
[data-theme="dark"] .sidebar-month-grid .day-cell.tiaoxiu {
    background: #f0abfc;
}

/* 已过工作日的打卡小对勾 */
.sidebar-month-grid .day-cell .check-mark {
    position: absolute;
    bottom: -2px;
    right: -2px;
    font-size: 7px;
    font-weight: 900;
    color: #16a34a; /* 高对比度深绿勾 */
    background: #ffffff; /* 白色小圆圈底座 */
    border-radius: 50%;
    width: 11px;
    height: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    pointer-events: none;
    line-height: 1;
    z-index: 2;
}

/* 图例细化微调 */
.sidebar-heatmap-legend {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    padding: 0 4px;
}

.sidebar-heatmap-legend .legend-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 600;
}

.sidebar-heatmap-legend .legend-color {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

