/* Boton para abrir el mapa */
#iconMapa {
    z-index: 400;
    position: fixed;
    top: 160px;
    right: 15px;
    width: 45px;
    height: 45px;
    background-image: var(--bg-linear);
    color: var(--color);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.3s;
    overflow: hidden;
}

#iconMapa img {
    width: 35px;
    height: 35px;
    transition: transform 0.3s;
}
  
#iconMapa.active {
    transform: scale(1.3);
}

#iconMapa:hover {
    transform: scale(1.3);
}


/* Estilo del panel */
.mapaPanel {
    z-index: 300; /* z-index para los panels laterales derechos */
    position: fixed;
    top: 197px;
    right: 15px;
    width: 350px;
    height: 300px;
    display: none;
    border-radius: 5px;
    background-image: var(--bg-linear);
    color: var(--color);
    transform-origin: top center;
}

/* Imagen dentro del panel */
#mapaImagen {
    width: 350px;
    height: 290px;
    object-fit: cover;
    cursor: pointer;
    border-radius: 5px;
    padding-left: 5px;
    padding-top: 15px;
    padding-right: 5px;
}

.mapaPanel.show {
    display: block;
    animation: unfoldFoldedSheet 0.5s forwards;
}

.mapaPanel.fold {
    animation: foldSheet 0.5s forwards;
}


/* Estilo del nombre del mapa */
#hoverMapaPanel {
    z-index: 301;
    position: fixed;
    top: 160px;
    right: 50px;
    width: 315px;
    height: 45px;
    text-align: center;
    background-image: var(--bg-linear);
    color: var(--color);
    padding: 5px;
    border-radius: 5px;
    font-size: 20px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(50px);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

/* Adaptacion a dispositivos moviles */
@media (max-width: 767px) {
    #iconMapa img {
        width: 30px;
        height: 30px;
        transition: transform 0.3s;
    }

    .mapaPanel {
        top: 150px;
        right: 20px;
        width: 260px;
        height: 260px;
    }

    #mapaImagen {
        padding: 5px;
        padding-top: 10px;
        width: 260px;
        height: 260px;
    }

    #hoverMapaPanel {
        top: 150px;
        right: 40px;
        width: 240px;
        height: 32px;
        font-size: 14px;
    }

    #iconMapa {
        top: 150px;
        right: 15px;
        width: 40px;
        height: 40px;
    }
}

/* Estilos adicionales para pantallas muy pequeñas */
@media (max-width: 480px) {

    #iconMapa img {
        width: 30px;
        height: 30px;
        transition: transform 0.3s;
    }

    .mapaPanel {
        top: 170px;
        right: 20px;
        width: 260px;
        height: 260px;
    }

    #mapaImagen {
        padding: 5px;
        padding-top: 10px;
        width: 260px;
        height: 260px;
    }

    #hoverMapaPanel {
        top: 150px;
        right: 40px;
        width: 240px;
        height: 32px;
        font-size: 14px;
    }

    #iconMapa {
        top: 150px;
        right: 15px;
        width: 40px;
        height: 40px;
    }
}