/**
 * PREQOLIMS Website Loader Animation
 * MS Research Journey Visualization
 */

.loader-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    flex-direction: column;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

.loader-container.hidden {
    opacity: 0;
    visibility: hidden;
}

.journey-loader {
    width: 80%;
    max-width: 700px;
    height: 6px;
    background-color: #e0e0e0;
    border-radius: 3px;
    position: relative;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.journey-progress {
    position: absolute;
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--primary-light), var(--primary-color));
    border-radius: 3px;
    transition: width 0.3s ease-out;
}

.journey-steps {
    display: flex;
    justify-content: space-between;
    width: 80%;
    max-width: 700px;
    position: relative;
    margin-top: 5px;
}

.journey-step {
    width: 16px;
    height: 16px;
    background-color: #e0e0e0;
    border-radius: 50%;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.journey-step.active {
    background-color: var(--primary-color);
    transform: scale(1.2);
}

.journey-step.completed {
    background-color: var(--primary-color);
}

.journey-detail {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    width: 100%;
    max-width: 500px;
    bottom: 30px;
    font-size: 0.9rem;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.journey-title {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.journey-description {
    color: var(--neutral-medium);
    margin-bottom: 0.5rem;
}

.journey-logo {
    margin-bottom: 2rem;
}

.journey-logo img {
    height: 60px;
}

.journey-step-label {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: var(--neutral-medium);
    text-align: center;
    width: 100px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.journey-step.active .journey-step-label {
    opacity: 1;
    font-weight: 600;
    color: var(--primary-color);
}

.journey-step.completed .journey-step-label {
    opacity: 1;
}

.journey-status {
    position: absolute;
    top: -40px;
    left: 0;
    width: 100%;
    text-align: center;
    color: var(--neutral-medium);
    font-size: 0.85rem;
}

/* Loading spinner */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(74, 137, 220, 0.2);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* For smaller screens */
@media (max-width: 768px) {
    .journey-loader, .journey-steps {
        width: 90%;
    }
    
    .journey-step-label {
        width: 80px;
        font-size: 0.7rem;
    }
}