:root {
    --loading-overlay-bg: rgba(255, 255, 255, 0.6);
    --loading-track-bg: #f3f3f3;
    --loading-bar-bg: #007bff;
}

/* Overlay that sits over the table while loading */
.sample-requests-section { /* can be plain */ }

.table-scroll{
    position: relative;          /* anchor for overlay */
    overflow-x: auto;            /* the horizontal scroll lives here */
}

.table-loading-overlay{
    position: absolute;
    inset: 0;                    /* cover the visible viewport of .table-scroll */
    display: none;
    align-items: center;
    justify-content: center;
    background-color: var(--loading-overlay-bg);
    z-index: 5;
    width: 267.5%;
}

.table-loading-overlay[wire\:loading]{
    display: flex;
}

/* The thin track holding the animated bar */
.loading-bar-container {
    position: relative;
    /*width: auto;*/
    height: 4px;
    background-color: var(--loading-track-bg);
    overflow: hidden;
    border-radius: 2px;
}

/* The animated bar (indeterminate) */
.loading-bar {
    position: absolute;
    top: 0;
    left: -30%;
    height: 100%;
    width: 30%; /* ensure visible even at start */
    background-color: var(--loading-bar-bg);
    animation: loading-bar-slide 1.2s ease-in-out infinite;
}

@keyframes loading-bar-slide {
    0% {
        left: -30%;
        width: 30%;
    }
    50% {
        left: 50%;
        width: 50%;
    }
    100% {
        left: 100%;
        width: 30%;
    }
}
