/* --- Loader Animation --- */
.btn-loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    vertical-align: middle;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* --- Reusable Modal/Popup --- */
.custom-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: none;
    /* Hidden by default */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.custom-modal-overlay.active {
    display: flex;
    opacity: 1;
}

.custom-modal-box {
    background: #fff;
    padding: 40px;
    width: 90%;
    max-width: 450px;
    border-radius: 8px;
    text-align: center;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.custom-modal-overlay.active .custom-modal-box {
    transform: translateY(0);
}

.custom-modal-icon {
    font-size: 50px;
    color: #2ecc71;
    /* Success Green */
    margin-bottom: 20px;
}

.custom-modal-title {
    font-size: 24px;
    color: #333;
    margin-bottom: 10px;
    font-weight: 600;
}

.custom-modal-text {
    font-size: 16px;
    color: #666;
    margin-bottom: 30px;
    line-height: 1.5;
}

.custom-modal-close {
    background: #333;
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background 0.2s;
}

.custom-modal-close:hover {
    background: #555;
}

/* Close 'X' button in top right */
.custom-modal-x {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
}