/* Prevent body scroll during loading */
body.loading {
    overflow: hidden;
}

/* Page Loader */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-color);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

.page-loader.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Progress Bar Container */
.loader-progress-container {
    width: 300px;
    max-width: 80%;
    height: 4px;
    background-color: rgba(99, 102, 241, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 20px;
}

/* Progress Bar */
.loader-progress-bar {
    height: 100%;
    width: 0%;
    background-color: var(--accent);
    border-radius: 2px;
    transition: width 0.3s ease;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
}

/* Optional: Logo or spinner */
.loader-logo {
    max-width: 120px;
    height: auto;
    opacity: 0.8;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
    }
}

/* Loading text (optional) */
.loader-text {
    color: var(--anti-light);
    font-size: 14px;
    margin-top: 15px;
    font-family: "Gabarito", sans-serif;
}
