/**
 * Chat Embebido - Asistente de Valoracion
 */

/* Chat Embebido Container */
.ve-chat-embedded {
    max-width: 800px;
    margin: 0 auto 40px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    border: 1px solid #e2e8f0;
}

/* Chat Header Embebido */
.ve-chat-header-embedded {
    background: linear-gradient(135deg, #1e3a5f 0%, #2d5a8a 100%);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.ve-chat-avatar {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.ve-chat-avatar svg {
    width: 24px;
    height: 24px;
    color: white;
}

.ve-chat-header-info h4 {
    margin: 0;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
}

.ve-chat-header-info span {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
}

/* Chat Messages Embebido */
.ve-chat-messages-embedded {
    height: 250px;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #f8fafc;
}

.ve-chat-message {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 16px;
    font-size: 0.95rem;
    line-height: 1.5;
    animation: ve-message-appear 0.3s ease;
}

@keyframes ve-message-appear {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ve-chat-message.assistant {
    background: white;
    color: #1e293b;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.ve-chat-message.user {
    background: linear-gradient(135deg, #1e3a5f 0%, #2d5a8a 100%);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.ve-chat-message.typing {
    display: flex;
    gap: 5px;
    padding: 16px 20px;
    background: white;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.ve-chat-message.typing span {
    width: 8px;
    height: 8px;
    background: #94a3b8;
    border-radius: 50%;
    animation: ve-typing 1.4s infinite ease-in-out;
}

.ve-chat-message.typing span:nth-child(1) { animation-delay: 0s; }
.ve-chat-message.typing span:nth-child(2) { animation-delay: 0.2s; }
.ve-chat-message.typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes ve-typing {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-8px); }
}

/* Suggestions Embebido */
.ve-chat-suggestions-embedded {
    padding: 12px 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.ve-chat-suggestion {
    background: white;
    border: 1.5px solid #e2e8f0;
    padding: 10px 18px;
    border-radius: 24px;
    font-size: 0.85rem;
    color: #1e3a5f;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
}

.ve-chat-suggestion:hover {
    background: #1e3a5f;
    color: white;
    border-color: #1e3a5f;
    transform: translateY(-1px);
}

/* Chat Input Embebido */
.ve-chat-input-container-embedded {
    padding: 16px 20px;
    background: white;
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: 12px;
}

.ve-chat-input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 28px;
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ve-chat-input:focus {
    border-color: #1e3a5f;
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.1);
}

.ve-chat-input::placeholder {
    color: #94a3b8;
}

.ve-chat-send {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #c9a227 0%, #e6c65c 100%);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.ve-chat-send:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(201, 162, 39, 0.4);
}

.ve-chat-send:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.ve-chat-send svg {
    width: 22px;
    height: 22px;
    color: #1e3a5f;
}

/* Responsive */
@media (max-width: 640px) {
    .ve-chat-embedded {
        margin: 0 10px 30px;
    }
    
    .ve-chat-messages-embedded {
        height: 200px;
    }
    
    .ve-chat-suggestions-embedded {
        padding: 10px 15px;
    }
    
    .ve-chat-suggestion {
        padding: 8px 14px;
        font-size: 0.8rem;
    }
    
    .ve-chat-header-info h4 {
        font-size: 1rem;
    }
    
    .ve-chat-header-info span {
        font-size: 0.75rem;
    }
}

/* Ocultar chat flotante (ya no se usa) */
.ve-chat-button,
.ve-chat-window {
    display: none !important;
}
