/* ==========================================
   EV CLINIC SLOVENIA - MAP STYLES
   ========================================== */

/* Map Section */
.map-section {
    padding: 80px 20px;
    background-color: var(--white);
}

/* Interactive Map Container */
.interactive-map {
    width: 100%;
    height: 600px;
    border-radius: 15px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    border: 3px solid #e0e0e0;
}

/* Custom Map Popup Styles */
.leaflet-popup-content-wrapper {
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    padding: 0;
    overflow: hidden;
}

.leaflet-popup-content {
    margin: 0;
    padding: 0;
    min-width: 250px;
}

.map-popup {
    padding: 20px;
    text-align: center;
}

.map-popup h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 10px;
}

.map-popup p {
    font-size: 0.95rem;
    color: var(--text-gray);
    margin-bottom: 15px;
}

.popup-link {
    display: inline-block;
    padding: 10px 25px;
    background: linear-gradient(135deg, var(--primary-blue), var(--light-blue));
    color: var(--white);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.popup-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.4);
}

/* Custom Marker Styling */
.leaflet-marker-icon,
.leaflet-marker-icon img {
    background: transparent !important;
    border: none !important;
}
.leaflet-marker-icon {
filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.7));
}

/* Remove any default Leaflet marker backgrounds */
.leaflet-div-icon {
    background: transparent !important;
    border: none !important;
}

/* Leaflet Controls Customization */
.leaflet-control-zoom a {
    background-color: var(--white) !important;
    color: var(--primary-blue) !important;
    border: 2px solid var(--primary-blue) !important;
}

.leaflet-control-zoom a:hover {
    background-color: var(--primary-blue) !important;
    color: var(--white) !important;
}

.leaflet-control-attribution {
    background-color: rgba(255, 255, 255, 0.9) !important;
    font-size: 0.75rem !important;
}

/* Popup Close Button */
.leaflet-popup-close-button {
    color: var(--text-gray) !important;
    font-size: 1.5rem !important;
    padding: 4px 8px !important;
}

.leaflet-popup-close-button:hover {
    color: var(--primary-blue) !important;
}

/* Tooltip Styling (za hover tooltips) */
.leaflet-tooltip {
    background-color: var(--primary-blue);
    color: var(--white);
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    padding: 8px 12px;
    font-weight: 600;
    font-size: 0.9rem;
}

.leaflet-tooltip::before {
    border-top-color: var(--primary-blue) !important;
}

/* Map Loading State */
.interactive-map.loading {
    background: linear-gradient(135deg, var(--background-light) 0%, var(--white) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.interactive-map.loading::before {
    content: 'Učitavanje mape...';
    font-size: 1.2rem;
    color: var(--text-gray);
    font-weight: 600;
}

/* ==========================================
   RESPONSIVE MAP STYLES
   ========================================== */

@media (max-width: 768px) {
    .interactive-map {
        height: 450px;
        border-radius: 10px;
    }
    
    .map-popup {
        padding: 15px;
    }
    
    .map-popup h3 {
        font-size: 1.1rem;
    }
    
    .leaflet-popup-content {
        min-width: 200px;
    }
}

@media (max-width: 480px) {
    .interactive-map {
        height: 350px;
        border-width: 2px;
    }
    
    .map-section {
        padding: 60px 10px;
    }
    
    .popup-link {
        padding: 8px 20px;
        font-size: 0.85rem;
    }
}

/* ==========================================
   ANIMATION FOR MAP MARKERS
   ========================================== */

@keyframes markerBounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.leaflet-marker-icon.bounce {
    animation: markerBounce 0.6s ease-in-out;
}

/* Custom styling for multiple markers (budući centri) */
.marker-cluster {
    background-color: rgba(0, 102, 204, 0.8);
    color: var(--white);
    border-radius: 50%;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.marker-cluster-small {
    width: 40px;
    height: 40px;
}

.marker-cluster-medium {
    width: 50px;
    height: 50px;
}

.marker-cluster-large {
    width: 60px;
    height: 60px;
}

interactive-map {
    width: 100%;
    height: 450px;
    border-radius: 15px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    border: none;
    position: relative;
}

/* Soft fade na rubovima */
.interactive-map::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    box-shadow: 
        inset 0 0 50px 15px rgba(240, 244, 248, 0.9),
        inset 0 0 30px 10px rgba(0, 180, 216, 0.05);
    border-radius: 15px;
}