/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

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

/* Header */
.header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563EB;
}

.logo i {
    font-size: 1.8rem;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
}

.nav-link:hover,
.nav-link.active {
    color: #2563EB;
    background-color: #f0f7ff;
}

/* Hero Section with Map */
.hero {
    position: relative;
    margin-top: 80px;
}

.map-container {
    width: 100%;
    height: 77.76vh;
    position: relative;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.1));
    z-index: 2;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.hero-content {
    color: white;
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: 1.2rem;
    font-weight: 400;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* Footer */
.footer {
    background-color: #f8f9fa;
    padding: 3rem 0 1rem;
    margin-top: 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-info h3 {
    color: #2563EB;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.footer-info p {
    color: #666;
}

.footer-contact h4,
.footer-social h4 {
    color: #333;
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.footer-contact p {
    color: #666;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-contact i {
    color: #2563EB;
    width: 16px;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #2563EB;
    color: white;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.social-link:hover {
    background-color: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
    color: #666;
}

/* Leaflet Map Customization */
.leaflet-popup-content-wrapper {
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.leaflet-popup-content {
    margin: 12px 16px;
    font-size: 14px;
    font-weight: 500;
}

.leaflet-popup-tip-container {
    margin-top: -1px;
}

/* Custom marker hitbox and visual pin for better hover targeting */
.marker-hitbox {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
}

.marker-pin {
    width: 32px;
    height: 32px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    border: 3px solid #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    position: relative;
    transition: transform 120ms ease, box-shadow 120ms ease;
}

.marker-pin::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    width: 8px;
    height: 8px;
    background-color: #fff;
    border-radius: 50%;
}

.marker-pin:hover {
    transform: rotate(-45deg) scale(1.06);
    box-shadow: 0 3px 8px rgba(0,0,0,0.35);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-list {
        gap: 1rem;
    }
    
    .map-container {
        height: 51.84vh;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .map-container {
        height: 64.8vh;
    }

/* Legend section */
.legend {
    padding: 1rem 0 2rem;
    background-color: #fff;
}

.legend .container {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.legend-title {
    font-weight: 600;
    color: #333;
}

.legend-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.75rem 1.5rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #444;
}

.legend-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 28px;
}

.legend-marker {
    width: 18px;
    height: 18px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    position: relative;
}

.legend-marker::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    width: 5px;
    height: 5px;
    background-color: #fff;
    border-radius: 50%;
}

.legend-marker.yellow { background-color: #F59E0B; }
.legend-marker.green { background-color: #22C55E; }
.legend-marker.red { background-color: #EF4444; }
    
    .hero-title {
        font-size: 2.5rem;
    }
}

/* Tablet adjustments */
@media (min-width: 769px) and (max-width: 1024px) {
    .container {
        padding: 0 30px;
    }
}

/* Large desktop adjustments */
@media (min-width: 1400px) {
    .container {
        max-width: 1400px;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading state for map */
.map-container.loading {
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-container.loading::before {
    content: "Chargement de la carte...";
    color: #666;
    font-size: 1.1rem;
}
