:root {
    --primary-color: #4e73df;
    --secondary-color: #858796;
    --success-color: #1cc88a;
    --info-color: #36b9cc;
    --warning-color: #f6c23e;
    --danger-color: #e74a3b;
    --light-color: #f8f9fc;
    --dark-color: #5a5c69;
    --bg-color: #f3f4f6;
    --card-bg: #ffffff;
    --text-color: #2c3e50;
    --border-radius: 10px;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    padding-bottom: 40px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    background-color: var(--primary-color);
    color: white;
    padding: 1rem 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

header h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Cards */
.card {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 20px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.card-header h2, .card-header h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin: 0;
}

/* Controls */
.controls-row {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

select, input[type="date"], input[type="month"], input[type="week"] {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 0.9rem;
    outline: none;
    transition: var(--transition);
}

select:focus, input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(78, 115, 223, 0.2);
}

button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

button:hover {
    background-color: #2e59d9;
}

button.secondary {
    background-color: var(--secondary-color);
}

button.secondary:hover {
    background-color: #717384;
}

/* Grid Layout */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

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

/* Chart Containers */
.chart-wrapper {
    position: relative;
    width: 100%;
    padding: 10px;
}

.canvas-container {
    position: relative;
    height: 300px;
    width: 100%;
}

.canvas-container.large {
    height: 400px;
}

/* Utility */
.mt-4 { margin-top: 1.5rem; }
.mb-4 { margin-bottom: 1.5rem; }
.text-center { text-align: center; }

label {
    font-weight: 600;
    font-size: 0.9rem;
    margin-right: 5px;
}

/* Footer */
.footer {
    background-color: var(--card-bg);
    padding: 1rem 0;
    margin-top: 2rem;
    border-top: 1px solid #e3e6f0;
    text-align: center;
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.status-success {
    color: var(--success-color);
    font-weight: bold;
}

.status-failure {
    color: var(--danger-color);
    font-weight: bold;
}
