/**
 * WooCommerce Fabric Swapper
 * Optional CSS for loading states and animations
 */

/* Loading state */
#fabric.wfs-loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

#fabric.wfs-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ccc;
    border-top-color: #333;
    border-radius: 50%;
    animation: wfs-spin 0.6s linear infinite;
}

/* Update animation */
#fabric.wfs-updated {
    animation: wfs-fade-in 0.6s ease-in-out;
}

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

@keyframes wfs-fade-in {
    from {
        opacity: 0.5;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
