/* Contenedor principal */
.mapa-gris-osm-wrapper {
    margin: 20px 0;
    position: relative;
}

/* Contenedor del mapa */
.mapa-gris-osm-container {
    width: 100%;
    background: #f0f0f0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.mapa-gris-osm-container:hover {
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.15);
}

/* Información de dirección */
.mapa-gris-info {
    margin-top: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #666;
}

.mapa-gris-direccion {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
}

.mapa-gris-direccion strong {
    color: #000;
    font-size: 16px;
    display: block;
    margin-bottom: 5px;
}

.mapa-gris-attribution {
    margin-top: 8px;
    font-size: 11px;
    color: #999;
}

/* Estilos del marcador personalizado */
.mapa-gris-marker {
    background: transparent;
}

.marker-pin {
    width: 30px;
    height: 30px;
    border-radius: 50% 50% 50% 0;
    background: #666;
    position: absolute;
    transform: rotate(-45deg);
    left: 0;
    top: 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.marker-icon {
    position: absolute;
    left: 8px;
    top: 5px;
    font-size: 16px;
    z-index: 1;
}

/* Popup personalizado */
.mapa-gris-popup-container .leaflet-popup-content-wrapper {
    border-radius: 10px;
    padding: 0;
    background: white;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.2);
}

.mapa-gris-popup-container .leaflet-popup-content {
    margin: 0;
    min-width: 250px;
}

.mapa-gris-popup {
    padding: 15px;
}

.mapa-gris-popup h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 16px;
    border-bottom: 2px solid #666;
    padding-bottom: 5px;
}

.mapa-gris-popup p {
    margin: 10px 0;
    font-size: 13px;
    line-height: 1.5;
    color: #555;
}

.mapa-gris-link {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 12px;
    background: #666;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 12px;
    transition: background 0.3s ease;
}

.mapa-gris-link:hover {
    background: #444;
    color: white;
    text-decoration: none;
}

/* Controles personalizados */
.leaflet-control-custom {
    transition: all 0.2s ease;
}

.leaflet-control-custom:hover {
    background-color: #f0f0f0 !important;
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .mapa-gris-osm-container {
        height: 300px !important;
    }
    
    .mapa-gris-popup {
        padding: 10px;
    }
    
    .mapa-gris-popup h4 {
        font-size: 14px;
    }
    
    .mapa-gris-popup p {
        font-size: 12px;
    }
    
    .mapa-gris-link {
        padding: 6px 10px;
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .mapa-gris-osm-container {
        border-radius: 8px;
    }
    
    .mapa-gris-info {
        padding: 10px;
    }
    
    .mapa-gris-direccion {
        font-size: 12px;
    }
    
    .mapa-gris-direccion strong {
        font-size: 14px;
    }
}

/* Animaciones */
@keyframes markerDrop {
    0% {
        transform: translateY(-100px) rotate(-45deg);
        opacity: 0;
    }
    100% {
        transform: translateY(0) rotate(-45deg);
        opacity: 1;
    }
}

.mapa-gris-marker {
    animation: markerDrop 0.5s ease-out;
}

/* Estilos para la capa del mapa en gris */
.leaflet-tile-pane {
    filter: grayscale(30%);
}

/* Control de geocodificación personalizado */
.leaflet-control-geocoder {
    border-radius: 4px !important;
    border: 1px solid #ddd !important;
}

.leaflet-control-geocoder input {
    font-size: 14px !important;
    padding: 6px 8px !important;
}

.leaflet-control-geocoder .leaflet-control-geocoder-alternatives {
    border-radius: 4px !important;
    border: 1px solid #ddd !important;
}