﻿/* Estilos para el spinner de carga inicial */
.converge-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #2A294B;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.converge-logo-container {
    margin-bottom: 30px;
    text-align: center;
}

.converge-logo {
    width: 200px;
    height: 200px;
    background: url('/Images/logotreliadatawhite.png') no-repeat center center;
    background-size: contain;
    display: inline-block;
    animation: logoFloat 3s ease-in-out infinite;
    margin-bottom: 20px;
}

.converge-logo-fallback {
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: white;
    margin-bottom: 20px;
    animation: logoFloat 3s ease-in-out infinite;
}

.converge-loading-title {
    color: white;
    font-size: 28px;
    font-weight: 300;
    margin-bottom: 10px;
    animation: fadeInOut 2s ease-in-out infinite;
}

.converge-loading-subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 16px;
    margin-bottom: 40px;
}

.converge-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 30px;
}

.converge-loading-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    text-align: center;
    min-height: 20px;
}

.converge-progress-container {
    width: 250px;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 20px;
}

.converge-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #ffffff, #e0e0e0);
    width: 0%;
    transition: width 0.3s ease;
    animation: shimmer 2s infinite;
}

/* Animaciones */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes fadeInOut {
    0%, 100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

@keyframes shimmer {
    0% {
        background-position: -200px 0;
    }

    100% {
        background-position: 200px 0;
    }
}

/* Transición de salida */
.converge-loading-overlay.fade-out {
    opacity: 0;
    transition: opacity 0.8s ease-out;
}

/* Ocultar cuando esté listo */
.blazor-ready .converge-loading-overlay {
    display: none;
}
