/* Toast Notification Styles */

.wholesuite-toast-container {
    position: fixed;
    z-index: 999999;
    pointer-events: none;
}

.wholesuite-toast-container.bottom-right {
    bottom: 24px;
    right: 24px;
}

.wholesuite-toast-container.bottom-left {
    bottom: 24px;
    left: 24px;
}

.wholesuite-toast-container.top-right {
    top: 24px;
    right: 24px;
}

.wholesuite-toast-container.top-left {
    top: 24px;
    left: 24px;
}

.wholesuite-toast-container.top-center {
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
}

.wholesuite-toast-container.bottom-center {
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
}

.wholesuite-toast {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 320px;
    max-width: 420px;
    background: white;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15), 0 4px 10px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    animation: toast-slide-in 0.3s ease;
    border-left: 4px solid;
    position: relative;
    overflow: hidden;
}

@keyframes toast-slide-in {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.wholesuite-toast.removing {
    animation: toast-slide-out 0.3s ease forwards;
}

@keyframes toast-slide-out {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* Toast Types */
.wholesuite-toast.success {
    border-left-color: #10b981;
}

.wholesuite-toast.error {
    border-left-color: #ef4444;
}

.wholesuite-toast.info {
    border-left-color: #3b82f6;
}

.wholesuite-toast.warning {
    border-left-color: #f59e0b;
}

/* Toast Icon */
.wholesuite-toast-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
}

.wholesuite-toast.success .wholesuite-toast-icon {
    color: #10b981;
}

.wholesuite-toast.error .wholesuite-toast-icon {
    color: #ef4444;
}

.wholesuite-toast.info .wholesuite-toast-icon {
    color: #3b82f6;
}

.wholesuite-toast.warning .wholesuite-toast-icon {
    color: #f59e0b;
}

/* Toast Image (for product thumbnails) */
.wholesuite-toast-image {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    overflow: hidden;
    background: #f3f4f6;
}

.wholesuite-toast-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Toast Content */
.wholesuite-toast-content {
    flex: 1;
    min-width: 0;
}

.wholesuite-toast-title {
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    margin: 0 0 4px 0;
}

.wholesuite-toast-message {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
}

/* Toast Actions */
.wholesuite-toast-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.wholesuite-toast-action {
    display: inline-block;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    border: 1px solid #e5e7eb;
    color: #374151;
    background: white;
}

.wholesuite-toast-action:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    color: #1f2937;
}

.wholesuite-toast-action.primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

.wholesuite-toast-action.primary:hover {
    opacity: 0.9;
    color: white;
}

/* Toast Close Button */
.wholesuite-toast-close {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #9ca3af;
    font-size: 18px;
    line-height: 1;
    transition: color 0.2s ease;
    padding: 0;
    background: none;
    border: none;
}

.wholesuite-toast-close:hover {
    color: #4b5563;
}

/* Progress Bar */
.wholesuite-toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: currentColor;
    opacity: 0.3;
    animation: toast-progress 5s linear forwards;
}

@keyframes toast-progress {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}

.wholesuite-toast.success .wholesuite-toast-progress {
    color: #10b981;
}

.wholesuite-toast.error .wholesuite-toast-progress {
    color: #ef4444;
}

.wholesuite-toast.info .wholesuite-toast-progress {
    color: #3b82f6;
}

.wholesuite-toast.warning .wholesuite-toast-progress {
    color: #f59e0b;
}

/* Mobile Responsive */
@media (max-width: 640px) {
    .wholesuite-toast-container {
        left: 12px !important;
        right: 12px !important;
        bottom: 12px;
        transform: none !important;
    }
    
    .wholesuite-toast {
        min-width: 0;
        max-width: none;
        width: 100%;
    }
    
    @keyframes toast-slide-in {
        from {
            transform: translateY(100px);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }
    
    @keyframes toast-slide-out {
        from {
            transform: translateY(0);
            opacity: 1;
        }
        to {
            transform: translateY(100px);
            opacity: 0;
        }
    }
}

/* Accessibility */
.wholesuite-toast:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    .wholesuite-toast {
        animation: none;
    }
}
