/* Modal Loading Overlay */
.modal-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-loading-content {
    text-align: center;
    color: white;
}

/* Modern Spinner Animation */
.loading-spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    position: relative;
}

.loading-spinner-ring {
    box-sizing: border-box;
    display: block;
    position: absolute;
    width: 100%;
    height: 100%;
    border: 4px solid transparent;
    border-top-color: #fff;
    border-radius: 50%;
    animation: spinner-rotate 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.loading-spinner-ring:nth-child(1) {
    animation-delay: -0.45s;
}

.loading-spinner-ring:nth-child(2) {
    animation-delay: -0.3s;
    border-top-color: #4f9ef8;
}

.loading-spinner-ring:nth-child(3) {
    animation-delay: -0.15s;
    border-top-color: #0cbc87;
}

@keyframes spinner-rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Pulse Animation for Text */
.loading-text {
    font-size: 16px;
    font-weight: 500;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Alternative: Dots Loading Animation */
.loading-dots {
    display: inline-flex;
    gap: 6px;
    margin-left: 8px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: white;
    animation: dots-bounce 1.4s infinite ease-in-out both;
}

.loading-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.loading-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes dots-bounce {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* Small Inline Loader */
.inline-loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spinner-rotate 0.8s linear infinite;
}

.inline-loader.loader-primary {
    border-color: rgba(79, 158, 248, 0.3);
    border-top-color: #4f9ef8;
}

.inline-loader.loader-success {
    border-color: rgba(12, 188, 135, 0.3);
    border-top-color: #0cbc87;
}

