/* ----------------------------------------------------------------------------
 * Mawaeedy - Global request loader
 * ---------------------------------------------------------------------------- */

.app-request-loader {
    position: fixed;
    inset: 0 auto auto 0;
    width: 100%;
    height: 0;
    z-index: 1065;
    pointer-events: none;
}

.app-request-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 7px;
    width: 100%;
    opacity: 0;
    background: linear-gradient(90deg, #0d6efd 0%, #20c997 100%);
    transform: translateX(-100%);
    transition: opacity 0.15s ease-in-out;
}

.app-request-spinner {
    position: fixed;
    top: 12px;
    right: 14px;
    width: 28px;
    height: 28px;
    border: 2px solid rgba(13, 110, 253, 0.2);
    border-top-color: #0d6efd;
    border-radius: 999px;
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.25s ease-in-out, transform 0.25s ease-in-out;
}

.app-request-loader.is-active .app-request-progress {
    opacity: 1;
    animation: app-request-progress-indeterminate 1.8s ease-in-out infinite;
}

.app-request-loader.is-active .app-request-spinner {
    opacity: 0.95;
    transform: scale(1);
    animation: app-request-spinner-rotate 0.7s linear infinite;
}

body[dir='rtl'] .app-request-spinner {
    right: auto;
    left: 14px;
}

.request-timeout-note {
    position: fixed;
    right: 14px;
    bottom: 14px;
    max-width: min(380px, calc(100vw - 24px));
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255, 193, 7, 0.45);
    background: rgba(17, 24, 39, 0.92);
    color: #f8fafc;
    font-size: 13px;
    line-height: 1.3;
    z-index: 1080;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

body[dir='rtl'] .request-timeout-note {
    right: auto;
    left: 14px;
}

@keyframes app-request-progress-indeterminate {
    0% {
        transform: translateX(-100%);
    }

    50% {
        transform: translateX(-5%);
    }

    100% {
        transform: translateX(100%);
    }
}

@keyframes app-request-spinner-rotate {
    from {
        transform: scale(1) rotate(0deg);
    }

    to {
        transform: scale(1) rotate(360deg);
    }
}

