:root {
    /* Light theme variables */
    --primary-color: #2196f3;
    --secondary-color: #03a9f4;
    --background-color: #f5f5f5;
    --card-background: #ffffff;
    --card-background-hover: #f0f0f0;
    --text-color: #333333;
    --border-color: #e0e0e0;
    --trend-up-color: #4caf50;
    --trend-down-color: #f44336;
}

[data-theme="dark"] {
    --primary-color: #64b5f6;
    --secondary-color: #29b6f6;
    --background-color: #121212;
    --card-background: #1e1e1e;
    --card-background-hover: #2a2a2a;
    --text-color: #e0e0e0;
    --border-color: #333333;
    --trend-up-color: #81c784;
    --trend-down-color: #e57373;
}

.theme-toggle {
    background: none;
    border: none;
    background-color: var(--card-background);
    color: var(--text-color);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.5rem;
    margin-left: 1rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
}

.theme-toggle:hover {
    background-color: var(--card-background-hover);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

.dashboard {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

header {
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

h1 {
    font-size: 1.8rem;
    color: var(--text-color);
}

.time-range-selector {
    display: flex;
    gap: 1rem;
}

.time-range-selector button {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: var(--card-background);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-color);
}

.time-range-selector button.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.card {
    background: var(--card-background);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.card h3 {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.card div:not(.trend) {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.trend {
    font-size: 0.8rem;
    color: var(--trend-up-color);
}

.trend.down {
    color: var(--trend-down-color);
}

.charts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.chart-container {
    background: var(--card-background);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    height: fit-content;
    position: relative;
}

.chart-container canvas {
    max-height: 400px !important;
}

.chart-container h2 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.details-section {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.details-list {
    background: var(--card-background);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.details-list h2 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.details-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.details-item:last-child {
    border-bottom: none;
}

.details-item .name {
    font-weight: 500;
}

.details-item .time {
    color: #666;
}

.progress-bar {
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    margin-top: 0.5rem;
    overflow: hidden;
}

.progress-bar .fill {
    height: 100%;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

@media (max-width: 1200px) {
    .charts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard {
        padding: 1rem;
    }

    .details-section {
        grid-template-columns: 1fr;
    }

    header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
} 