/* Rotating AJAX loader */

.uis_loader_wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.uis_page_loader {
    border: 6px solid var(--crb-loader-border);
    border-top: 6px solid var(--crb-loader-border-top);

    border-radius: 50%;
    width: 70px;
    height: 70px;

    will-change: transform;
    animation: crb-spinner 1.5s linear infinite;
}

@keyframes crb-spinner {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Inter-page loader */

#ui_page_overlay {
    background-color: rgba(255, 255, 255, 0.8);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

#ui_page_overlay::after {
    content: '';

    border: 6px solid var(--crb-loader-border);
    border-top: 6px solid var(--crb-loader-border-top);

    border-radius: 50%;
    width: 100px;
    height: 100px;

    will-change: transform;
    animation: spin 1.5s linear infinite;
}

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

/* Fancy skeleton AJAX loader */

.crb-skeleton-table {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 1em;
}

.crb-skeleton-row {
    display: flex;
    gap: 10px;
}

.crb-skeleton-cell {
    flex: 1;
    height: 15px;
    background: #dcdcdc;
    position: relative;
    overflow: hidden;
}

.crb-skeleton-cell::before {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 150%;
    height: 100%;

    background: linear-gradient(90deg,
    rgba(220, 220, 220, 1) 0%,
    rgba(190, 190, 190, 1) 50%,
    rgba(220, 220, 220, 1) 100%);

    will-change: transform;
    animation: crb-shimmer 1.5s infinite linear;
}

@keyframes crb-shimmer {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(150%);
    }
}
