/**
 * VDO Blocks Styles
 *
 * @package VDO_Theme
 */

/* Notification Styles */
.vdo-notification {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 16px 32px;
    border-radius: 8px;
    font-weight: 500;
    z-index: 10000;
    opacity: 0;
    transition: all 0.3s ease;
}

.vdo-notification.is-visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.vdo-notification--success {
    background: var(--wp--preset--color--success, #28a745);
    color: #fff;
}

.vdo-notification--error {
    background: #dc3545;
    color: #fff;
}

/* AI Chat Widget Styles */
.vdo-ai-chat-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    font-family: var(--wp--preset--font-family--inter, sans-serif);
}

.vdo-ai-chat-trigger {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--wp--preset--color--accent, #ff6600), var(--wp--preset--color--accent-yellow, #ffc107));
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(255, 102, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: #fff;
}

.vdo-ai-chat-trigger:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(255, 102, 0, 0.5);
}

.vdo-ai-chat-panel {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    height: 520px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.vdo-ai-chat-panel.is-open {
    display: flex;
    animation: slideUp 0.3s ease;
}

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

.vdo-ai-chat-header {
    background: linear-gradient(135deg, var(--wp--preset--color--primary, #1a2b4a), var(--wp--preset--color--primary-light, #2d4a7c));
    color: #fff;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.vdo-ai-chat-avatar {
    width: 48px;
    height: 48px;
    background: var(--wp--preset--color--accent, #ff6600);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vdo-ai-chat-header-info {
    flex: 1;
}

.vdo-ai-chat-title {
    display: block;
    font-weight: 600;
    font-size: 1.1rem;
}

.vdo-ai-chat-status {
    display: block;
    font-size: 0.85rem;
    opacity: 0.8;
}

.vdo-ai-chat-close {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 8px;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.vdo-ai-chat-close:hover {
    opacity: 1;
}

.vdo-ai-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.vdo-ai-message {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 16px;
    line-height: 1.5;
    font-size: 0.95rem;
}

.vdo-ai-message.bot {
    background: var(--wp--preset--color--bg-light, #f8f9fa);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.vdo-ai-message.user {
    background: var(--wp--preset--color--secondary, #0066cc);
    color: #fff;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.vdo-ai-chat-suggestions {
    display: flex;
    gap: 8px;
    padding: 0 16px 16px;
    flex-wrap: wrap;
}

.vdo-ai-suggestion {
    padding: 8px 16px;
    background: var(--wp--preset--color--bg-light, #f8f9fa);
    border: 1px solid var(--wp--preset--color--border, #e0e0e0);
    border-radius: 20px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.vdo-ai-suggestion:hover {
    background: var(--wp--preset--color--secondary, #0066cc);
    color: #fff;
    border-color: var(--wp--preset--color--secondary, #0066cc);
}

.vdo-ai-chat-input {
    padding: 16px;
    border-top: 1px solid var(--wp--preset--color--border, #e0e0e0);
    display: flex;
    gap: 12px;
}

.vdo-ai-chat-input input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--wp--preset--color--border, #e0e0e0);
    border-radius: 24px;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.3s ease;
}

.vdo-ai-chat-input input:focus {
    border-color: var(--wp--preset--color--secondary, #0066cc);
}

.vdo-ai-chat-input button {
    padding: 12px 20px;
    background: var(--wp--preset--color--accent, #ff6600);
    color: #fff;
    border: none;
    border-radius: 24px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.vdo-ai-chat-input button:hover {
    background: #e55a00;
}

/* Loading Animation */
.vdo-loading {
    display: flex;
    align-items: center;
    gap: 6px;
}

.vdo-loading-dot {
    width: 8px;
    height: 8px;
    background: var(--wp--preset--color--secondary, #0066cc);
    border-radius: 50%;
    animation: loadingDot 1.4s ease-in-out infinite;
}

.vdo-loading-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.vdo-loading-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes loadingDot {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .vdo-ai-chat-panel {
        width: 100%;
        height: 100vh;
        bottom: 0;
        right: 0;
        border-radius: 0;
        position: fixed;
    }
    
    .vdo-ai-chat-trigger {
        width: 56px;
        height: 56px;
    }
}
