/* Estilos específicos para marcadores de inmuebles */

/* Marcadores con etiquetas de precio */
.inmuebles-markers .labels {
    color: #fff;
    background-color: transparent;
    border: 0;
    font-family: Arial, sans-serif;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
    width: 60px;
    white-space: nowrap;
}

.inmuebles-markers .labels .inner {
    background-color: #007bff;
    border-radius: 4px;
    padding: 4px 8px;
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.inmuebles-markers .labels .arrow {
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #007bff;
}

/* Diferentes colores según el tipo de inmueble */

/* Viviendas - Azul (por defecto) */
.inmuebles-markers .labels .inner.vivienda {
    background-color: #007bff;
}

.inmuebles-markers .labels .arrow.vivienda {
    border-top-color: #007bff;
}

/* Locales - Amarillo */
.inmuebles-markers .labels .inner.local {
    background-color: #ffc107;
    color: #212529;
}

.inmuebles-markers .labels .arrow.local {
    border-top-color: #ffc107;
}

/* Oficinas - Verde */
.inmuebles-markers .labels .inner.oficina {
    background-color: #28a745;
}

.inmuebles-markers .labels .arrow.oficina {
    border-top-color: #28a745;
}

/* Garajes - Gris */
.inmuebles-markers .labels .inner.garaje {
    background-color: #6c757d;
}

.inmuebles-markers .labels .arrow.garaje {
    border-top-color: #6c757d;
}

/* Terrenos - Marrón */
.inmuebles-markers .labels .inner.terreno {
    background-color: #8b4513;
}

.inmuebles-markers .labels .arrow.terreno {
    border-top-color: #8b4513;
}

/* Info window de inmuebles */
.info-window-inmueble {
    padding: 10px;
    max-width: 250px;
}

.info-window-inmueble h3 {
    margin: 0 0 10px 0;
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

.info-window-inmueble .precio {
    font-size: 18px;
    font-weight: bold;
    color: #007bff;
    margin: 10px 0;
}

.info-window-inmueble p {
    margin: 5px 0;
    font-size: 14px;
    color: #666;
}

.info-window-inmueble .btn-ver-inmueble {
    display: inline-block;
    background-color: #007bff;
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    margin-top: 10px;
}

.info-window-inmueble .btn-ver-inmueble:hover {
    background-color: #0056b3;
    color: white;
    text-decoration: none;
}

/* Estilos del listing-box para info-window (igual que inversión) */
.listing-box-image {
    position: relative;
    overflow: hidden;
    border-radius: 0;
}

.listing-box-image img {
    width: 100%;
    height: auto;
    max-height: 120px;
    object-fit: cover;
}

.listing-box-image a {
    display: block;
    text-decoration: none;
}

.listing-box-image a:hover {
    text-decoration: none;
}

/* Overlay de carga para info-window */
.inmuebles-info-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    font-size: 14px;
    color: #666;
}

.inmuebles-info-loading img {
    width: 20px;
    height: 20px;
    margin-right: 10px;
}

/* Overlay de carga para info-window (igual que inversión) */
.inversion-info-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    font-size: 14px;
    color: #666;
}

.inversion-info-loading img {
    width: 20px;
    height: 20px;
    margin-right: 10px;
}

/* Responsive */
@media (max-width: 768px) {
    .inmuebles-markers .labels {
        font-size: 10px;
        width: 50px;
    }
    
    .inmuebles-markers .labels .inner {
        padding: 3px 6px;
    }
    
    .info-window-inmueble {
        max-width: 200px;
        padding: 8px;
    }
    
    .info-window-inmueble h3 {
        font-size: 14px;
    }
    
    .info-window-inmueble .precio {
        font-size: 16px;
    }
}

/* Asegurar que el contenedor del mapa tenga altura */
#map {
    height: 500px !important;
    width: 100% !important;
    min-height: 400px !important;
}

.resultados-viviendas-mapa {
    height: 500px !important;
    min-height: 400px !important;
}

/* Loading overlay */
#map-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255,255,255,0.9);
    padding: 20px;
    border-radius: 5px;
    z-index: 1000;
    display: none;
} 