/* Fondo general del preloader */
.contenedor-carga {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

/* Spinner */
.rueda-carga {
    border: 6px solid #c2c2c2;
    border-top: 6px solid #3560aa;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: girar 1.2s linear infinite;
    margin-bottom: 20px;
}

/* Animaci¨®n del spinner */
@keyframes girar {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Texto animado */
.texto-carga {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-bottom: 15px;
}

.letra-carga {
    font-size: 28px;
    font-weight: bold;
    color: #3560aa;
    opacity: 0;
    animation: aparecerLetra 1s forwards;
}

.letra-carga:nth-child(1) { animation-delay: 0.1s; }
.letra-carga:nth-child(2) { animation-delay: 0.2s; }
.letra-carga:nth-child(3) { animation-delay: 0.3s; }
.letra-carga:nth-child(4) { animation-delay: 0.4s; }
.letra-carga:nth-child(5) { animation-delay: 0.5s; }
.letra-carga:nth-child(6) { animation-delay: 0.6s; }
.letra-carga:nth-child(7) { animation-delay: 0.7s; }
.letra-carga:nth-child(8) { animation-delay: 0.8s; }
.letra-carga:nth-child(9) { animation-delay: 0.9s; }
.letra-carga:nth-child(10) { animation-delay: 1.0s; }

@keyframes aparecerLetra {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Texto inferior */
.mensaje-carga {
    color: #c2c2c2;
    font-size: 16px;
    margin-top: 10px;
    animation: parpadeo 1.5s infinite;
}

@keyframes parpadeo {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* Animaci¨®n tipo cortina */
.pantalla-carga {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.fila {
    display: flex;
    height: 100%;
}

.seccion {
    flex: 1;
    overflow: hidden;
}

.fondo {
    background-color: #4585a2;
    height: 100%;
    animation: deslizar 2s ease-in-out forwards;
}

.seccion-izquierda .fondo {
    animation-name: deslizarIzquierda;
}

.seccion-derecha .fondo {
    animation-name: deslizarDerecha;
}

@keyframes deslizarIzquierda {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

@keyframes deslizarDerecha {
    0% { transform: translateX(0); }
    100% { transform: translateX(100%); }
}
