/* Loader wrapper: fixed fullscreen overlay, dark background */
#loader {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* Smaller loader circle size */
.loader-circle-8 {
    position: relative;
    width: 40px;   /* smaller size */
    height: 40px;
}
.loader-circle-8:before {
    content: "";
    display: block;
    padding-top: 100%;
}

/* SVG fills the loader container */
.circular {
    animation: rotate 2s linear infinite;
    width: 20%;
    height: 20%;
    transform-origin: center center;
    position: absolute;
    top: 0; bottom: 0; left: 0; right: 0;
    margin: auto;
}

.path {
    stroke-dasharray: 1, 200;
    stroke-dashoffset: 0;
    animation: dash 1.5s ease-in-out infinite, color 6s ease-in-out infinite;
    stroke-linecap: round;
    stroke-width: 3;  /* thinner stroke for smaller size */
}

/* keyframes remain unchanged */
@keyframes rotate {
    100% { transform: rotate(360deg); }
}
@keyframes dash {
    0% {
        stroke-dasharray: 1, 200;
        stroke-dashoffset: 0;
    }
    50% {
        stroke-dasharray: 89, 200;
        stroke-dashoffset: -35px;
    }
    100% {
        stroke-dasharray: 89, 200;
        stroke-dashoffset: -124px;
    }
}
@keyframes color {
    0%, 100% { stroke: #d82929; }
    40% { stroke: #0057e7; }
    66% { stroke: #cad829; }
    80%, 90% { stroke: #2844d3; }
}
