/* Async Search Styles */

/* Loading animation */
@keyframes loading-shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

#eeva-loading .loading-bar {
    position: relative;
    background: #f0f0f0;
    overflow: hidden;
}

#eeva-loading .loading-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(217, 2, 61, 0.3) 50%, transparent 100%);
    background-size: 200% 100%;
    animation: loading-shimmer 1.5s infinite;
}

#eeva-loading .loading-progress {
    background: #d9023d;
    transition: width 0.3s ease;
}

/* Async loaded product rows */
.eeva-product-row {
    animation: fadeInUp 0.5s ease-out;
    transform: translateY(20px);
    position: relative;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Subtle indicator for EEVA products */
.eeva-product-row:first-of-type::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -10px;
    height: 1px;
    background: linear-gradient(to right, transparent, #e0e0e0 20%, #e0e0e0 80%, transparent);
    opacity: 0.5;
}

/* Optional: Slightly different background for EEVA products */
.eeva-product-row:hover {
    background-color: rgba(217, 1, 61, 0.02);
}

/* Notification styles */
.eeva-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #005a99;
    color: white;
    padding: 16px 24px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 9999;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid #004a7f;
    display: flex;
    align-items: center;
    gap: 12px;
    opacity: 0;
}

.eeva-notification::before {
    content: '\2713';
    display: inline-block;
    width: 24px;
    height: 24px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    text-align: center;
    line-height: 24px;
    font-size: 16px;
    flex-shrink: 0;
}

.eeva-notification.error {
    background: #f44336;
}

/* Cart confirmation overlay */
.cart-confirmation-overlay {
    animation: fadeIn 0.3s ease;
}

.cart-confirmation-modal {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Loading state for buttons */
.buy-button.loading {
    position: relative;
    color: transparent !important;
    min-width: 100px;
}

.buy-button.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top: 2px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
    .eeva-notification {
        right: 10px;
        left: 10px;
        top: 10px;
    }
    
    .cart-confirmation-modal {
        margin: 10px;
        max-width: calc(100% - 20px);
    }
}