/* Mini Chart Component */
.mini-chart-container {
    background: var(--card-bg, #fff);
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
    border: 1px solid var(--border-color, #e2e8f0);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.mini-chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.mini-chart-header h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary, #0f172a);
    margin: 0;
}

.chart-period-btns {
    display: flex;
    gap: 4px;
}

.chart-period-btns button {
    padding: 4px 10px;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 6px;
    background: transparent;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary, #64748b);
    cursor: pointer;
    transition: all 0.2s;
}

.chart-period-btns button.active,
.chart-period-btns button:hover {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.mini-chart-canvas {
    width: 100%;
    height: 180px;
    position: relative;
}

.mini-chart-canvas canvas {
    width: 100% !important;
    height: 100% !important;
}

.mini-chart-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color, #e2e8f0);
}

.chart-stat {
    text-align: center;
}

.chart-stat-label {
    font-size: 0.7rem;
    color: var(--text-secondary, #64748b);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.chart-stat-value {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-primary, #0f172a);
    margin-top: 4px;
    letter-spacing: -0.3px;
}

.chart-stat-value.up { color: #10b981; }
.chart-stat-value.down { color: #ef4444; }

/* Dark mode */
body.dark-mode .mini-chart-container {
    background: #1e293b;
    border-color: #334155;
}
body.dark-mode .mini-chart-header h3 { color: #f1f5f9; }
body.dark-mode .chart-period-btns button { border-color: #475569; color: #94a3b8; }
body.dark-mode .chart-stat-label { color: #94a3b8; }
body.dark-mode .chart-stat-value { color: #f1f5f9; }
body.dark-mode .mini-chart-footer { border-top-color: #334155; }

@media (max-width: 768px) {
    .mini-chart-canvas { height: 140px; }
    .mini-chart-footer { flex-wrap: wrap; gap: 8px; }
    .chart-stat { flex: 1; min-width: 60px; }
}
