#banner2 {
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: row;
    background-image: url('../recursos/banner2Fondo.png');
    background-size: cover;
}

#banner2Contenedor2item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;   
    justify-content: center;
    margin-left: 300px;         
    max-width: 520px;          
    gap: 12px;                
    text-align: left;
}


.banner2Contenedor {
    position: relative;
    width: 35%;
    height: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.banner2Elemento {
    position: absolute;
    width: 200px;
    height: 200px;


    animation: desplazarDiagonal1 2s ease forwards;

    bottom: 0;
    left: 10%;
}

.banner2Elemento.mostrar1 {
    left: calc(90% - 200px);

}

#T2_B2 {
    color: white;
    text-align: center;
    font-size: 40px;
}

#RPB2 {
    max-width: 100%;
}

@keyframes desplazarDiagonal1 {
    0% {
        bottom: -300px;
        left: -300px;
    }

    100% {
        bottom: 0;
        left: 10%;
    }
}

#Img_Bn2 {
    height: 80%;
    width: auto;
}

.banner2Contenedor2 {
    /*position: relative;*/
    width: 85%;
    height: 100%;
    /* Altura de ejemplo */
    overflow: hidden;
    /* Evita que el contenido desborde el 2Contenedor */
    display: flex;
    align-items: center;

}

.banner2Elemento2 {
    position: absolute;

    /* Posición inicial, fuera del área visible */
    width: 200px;
    height: 200px;

    animation: desplazarDiagonal2 2s ease forwards;

    bottom: 0;
    right: 0;
}


@keyframes desplazarDiagonal2 {
    0% {
        bottom: -300px;
        right: -300px;
    }

    100% {
        bottom: 0;
        right: 0;
    }
}

@media screen and (max-width: 900px) {
    #banner2 {
        min-height: 100dvh;
        /* mejor en móviles */
        height: auto;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        /* centrado vertical real */
        padding-top: 6vh;
        /* súbelo un poco */
        padding-bottom: 10vh;

    }

    .banner2Elemento2 {
        display: none;
    }

    .banner2Contenedor2 {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        /* antes 12vh; ya lo compensa el padding del #banner2 */
        padding-top: 0;
        height: auto;
    }

    .banner2Contenedor,
    .banner2Contenedor2 {
        overflow: visible;
        /* antes estaba hidden */
    }

    .banner2Contenedor {
        width: 100%;
        display: flex;
        justify-content: center;
        /* Centrado horizontal */
        align-items: center;
        /* Centrado vertical */
    }

    #banner2Contenedor2item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        padding-left: 0;
        gap: 12px;
        transform: none;
        margin: 0;
    }

    #Img_Bn2 {
        height: 85%;
        width: auto;
    }

    #T2_B2 {
        font-size: 28px;
        /* Tamaño de fuente más pequeño para móviles */
    }
}


@media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (-webkit-min-device-pixel-ratio: 2) {
    #banner2 {
        flex-direction: column-reverse;
        align-items: center;
        justify-content: center;
        min-height: 100dvh;
        /* reemplaza 100vh */
        height: auto;
        padding-top: 6vh;
        padding-bottom: 10vh;
        /* evita recorte inferior */
    }

    .banner2Elemento2 {
        display: none;
    }

    .banner2Contenedor2 {
        width: 100%;
        height: auto;
        /* Asegurar que el contenedor ocupe toda la altura */
        display: flex;
        justify-content: center;
        /* Centrado horizontal */
        align-items: center;
        /* Centrado vertical */
    }

    .banner2Contenedor {
        width: 100%;
        display: flex;
        justify-content: center;
        /* Centrado horizontal */
        align-items: center;
        /* Centrado vertical */
    }

    #banner2Contenedor2item {
        display: flex;
        flex-direction: column;
        align-items: center;
        /* Centrado horizontal */
        justify-content: center;
        /* Centrado vertical */
        padding-left: 0px;
        margin-top: 0;
        margin-bottom: 20px;
        /* Eliminar el margen superior para evitar desplazamientos */
    }

    #T2_B2 {
        font-size: 24px;
        /* Reducir tamaño de fuente en móviles */
    }

    #RPB2 {
        text-align: center;
        /* Asegurarse de que el texto esté centrado */
    }
}

/* Orientación vertical para tabletas */
@media (min-width: 600px) and (max-width: 1024px) and (orientation: portrait) {
    .banner2Contenedor {
        position: relative;
        width: 74%;
        height: 100%;
        overflow: hidden;
        display: flex;
        align-items: center;
    }

    #Img_Bn2 {
        height: 55%;
        width: auto;
    }

    .banner2Contenedor2 {
        position: relative;
        width: 76%;
        height: 82%;
        overflow: hidden;
        display: flex;
        align-items: center;
        margin-top: 24%;
        justify-content: center;
    }

    #banner2Contenedor2item {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        justify-content: center;
        margin-top: -86%;
        margin-right: 5%;
    }

    #RPB2 {
        max-width: 100%;
        color: white;
        font-size: 40px;
        font-weight: 900;
        line-height: 44px;
        padding-bottom: 18px;
    }

    .banner2Elemento2 {
        position: absolute;
        width: 200px;
        height: 200px;
        animation: desplazarDiagonal2 2s ease forwards;
        bottom: 0;
        right: 0;
        height: 45%;
        width: auto;
        margin-right: 0%;
    }
}

.logooo2 {
    width: 85%;
    height: auto;
    margin-top: 20px;
    align-self: flex-start; /* 🔥 asegura que siga la alineación a la izquierda */
}