﻿/* Loader overlay to cover the entire background */
#loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent background for dull effect */
    z-index: 99999998; /* Slightly lower than loader z-index */
    display: none; /* Initially hidden */
}

/* Loader animation */
#loader {
    position: fixed;
    left: 50%;
    top: 50%;
    z-index: 99999999; /* High z-index to overlay everything */
    transform: translate(-50%, -50%);
    display: none;
    width: 60px;
    aspect-ratio: 4;
    --_g: no-repeat radial-gradient(circle closest-side, #d87ebd 90%, #0000);
    background: var(--_g) 0% 50%, var(--_g) 50% 50%, var(--_g) 100% 50%;
    background-size: calc(100%/3) 100%;
    animation: l7 1s infinite linear;
}

/* Keyframes for loader animation */
@keyframes l7 {
    33% {
        background-size: calc(100%/3) 0%, calc(100%/3) 100%, calc(100%/3) 100%;
    }

    50% {
        background-size: calc(100%/3) 100%, calc(100%/3) 0%, calc(100%/3) 100%;
    }

    66% {
        background-size: calc(100%/3) 100%, calc(100%/3) 100%, calc(100%/3) 0%;
    }
}

/* Prevent background interaction without dimming loader */
#loader-overlay, body.loader-active {
    pointer-events: none; /* Disable interactions on the background */
}
