/**
 * ToHo Water Usage Dashboard Styles
 */

.toho-dashboard-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.toho-dashboard-title {
    text-align: center;
    color: #2c5aa0;
    font-size: 32px;
    margin-bottom: 30px;
    font-weight: 600;
}

/* Controls */
.toho-dashboard-controls {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.toho-control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toho-control-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.toho-date-range-select {
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    min-width: 180px;
    background: white;
    cursor: pointer;
}

.toho-date-range-select:hover {
    border-color: #2c5aa0;
}

/* Property Cards */
.toho-dashboard-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.toho-property-card {
    background: white;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-top: 4px solid;
    transition: transform 0.2s, box-shadow 0.2s;
}

.toho-property-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.toho-property-card.card-1 {
    border-top-color: #4a90e2;
}

.toho-property-card.card-2 {
    border-top-color: #5cb85c;
}

.toho-property-card.card-3 {
    border-top-color: #e94b3c;
}

.toho-card-header {
    text-align: center;
    margin-bottom: 20px;
}

.toho-card-title {
    font-size: 20px;
    font-weight: 600;
    color: #2c5aa0;
    margin-bottom: 5px;
}

.toho-card-account {
    font-size: 12px;
    color: #666;
}

.toho-card-stat {
    margin-bottom: 16px;
}

.toho-card-stat-label {
    font-size: 11px;
    text-transform: uppercase;
    color: #666;
    font-weight: 600;
    margin-bottom: 4px;
}

.toho-card-stat-value {
    font-size: 28px;
    font-weight: 700;
    color: #e94b3c;
}

.toho-card-stat-value.usage {
    color: #4a90e2;
}

.toho-card-stat-unit {
    font-size: 14px;
    color: #999;
    font-weight: 400;
}

.toho-card-stat-secondary {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.toho-card-stat-tertiary {
    font-size: 14px;
    color: #666;
}

/* Charts */
.toho-dashboard-chart {
    background: white;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.toho-dashboard-chart h3 {
    font-size: 20px;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
    font-weight: 600;
}

.toho-dashboard-chart canvas {
    max-height: 400px;
}

.toho-dashboard-charts-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.toho-chart-container {
    background: white;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.toho-chart-container h3 {
    font-size: 18px;
    color: #333;
    margin-bottom: 16px;
    text-align: center;
    font-weight: 600;
}

.toho-chart-container canvas {
    max-height: 300px;
}

/* Loading State */
.toho-loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-size: 16px;
}

.toho-loading::after {
    content: '';
    animation: toho-dots 1.5s infinite;
}

@keyframes toho-dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Responsive */
@media (max-width: 768px) {
    .toho-dashboard-cards {
        grid-template-columns: 1fr;
    }
    
    .toho-dashboard-charts-row {
        grid-template-columns: 1fr;
    }
    
    .toho-dashboard-title {
        font-size: 24px;
    }
}
