body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header h1 {
    margin: 0;
    color: #2c3e50;
    font-size: 2.5em;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.header p {
    margin: 10px 0 0 0;
    color: #7f8c8d;
    font-size: 1.2em;
}

.map-container {
    height: 70vh;
    margin: 20px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 3px solid rgba(255, 255, 255, 0.2);
}

#map {
    height: 100%;
    width: 100%;
}

.stats-panel {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    margin: 20px;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 10px;
}

.detailed-stats {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    margin: 10px 20px 20px 20px;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.detailed-stats h2 {
    color: #2c3e50;
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
    font-size: 1.8em;
    font-weight: 700;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.stat-section {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.stat-section h3 {
    color: #495057;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.3em;
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 2px solid #dee2e6;
}

.municipality-stats {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.municipality-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.municipality-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.municipality-name {
    font-weight: 600;
    color: #2c3e50;
    flex: 1;
}

.municipality-count {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9em;
    min-width: 40px;
    text-align: center;
}

.depth-stats, .year-stats, .sponsor-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: white;
    border-radius: 6px;
    font-size: 0.95em;
}

.stat-label {
    color: #495057;
}

.stat-value {
    font-weight: 600;
    color: #2c3e50;
}

.stat-item {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
    transform: translateY(0);
    transition: all 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(52, 152, 219, 0.4);
}

.stat-number {
    font-size: 2.5em;
    font-weight: bold;
    margin-bottom: 5px;
}

.custom-popup {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.popup-header {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 15px;
    margin: -10px -10px 15px -10px;
    border-radius: 8px 8px 0 0;
    text-align: center;
}

.popup-title {
    font-size: 1.3em;
    font-weight: bold;
    margin-bottom: 5px;
}

.popup-subtitle {
    font-size: 0.9em;
    opacity: 0.9;
}

.popup-content {
    padding: 0 5px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #ecf0f1;
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: #2c3e50;
}

.info-value {
    color: #7f8c8d;
}

.status-installed {
    color: #27ae60;
    font-weight: bold;
}

.status-not-installed {
    color: #e74c3c;
    font-weight: bold;
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 768px) {
    .header h1 {
        font-size: 2em;
    }
    
    .map-container {
        height: 60vh;
        margin: 10px;
    }
    
    .stats-panel {
        margin: 10px;
        padding: 15px;
        grid-template-columns: repeat(2, 1fr);
    }
    
    .detailed-stats {
        margin: 10px;
        padding: 15px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .stat-section {
        padding: 15px;
    }
    
    .stat-item {
        padding: 15px;
    }
    
    .stat-number {
        font-size: 2em;
    }
}