/* AI Chat Widget Styling */
.chat-widget-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 10000;
    font-family: 'Inter', sans-serif;
}

/* Floating Button */
.chat-trigger {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-pink), var(--accent-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 32px rgba(255, 46, 99, 0.3);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: none;
    color: white;
    font-size: 1.5rem;
}

.chat-trigger:hover {
    transform: scale(1.1) rotate(5deg);
}

.chat-trigger.active {
    transform: rotate(90deg) scale(0.8);
    opacity: 0;
    pointer-events: none;
}

/* Chat Window */
.chat-window {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 380px;
    max-height: 600px;
    height: 70vh;
    background: rgba(18, 16, 20, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.9) translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.chat-window.active {
    transform: scale(1) translateY(0);
    opacity: 1;
    pointer-events: all;
}

/* Header */
.chat-header {
    padding: 20px;
    background: linear-gradient(90deg, rgba(255, 46, 99, 0.1), rgba(0, 122, 255, 0.1));
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-header-info i {
    color: var(--accent-pink);
    font-size: 1.2rem;
}

.chat-header-info h4 {
    margin: 0;
    font-size: 1rem;
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
}

.chat-header-info span {
    font-size: 0.75rem;
    color: #4cd137;
    display: flex;
    align-items: center;
    gap: 4px;
}

.chat-header-info span::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #4cd137;
    border-radius: 50%;
}

.close-chat {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
}

.close-chat:hover {
    color: var(--text-primary);
}

/* Messages Area */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 15px;
    font-size: 0.9rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
}

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

.bot-message {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    align-self: flex-start;
    border-bottom-left-radius: 2px;
}

.user-message {
    background: var(--accent-pink);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

/* Typing Indicator */
.typing {
    font-style: italic;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

/* Input Area */
.chat-input-area {
    padding: 20px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    gap: 10px;
}

.chat-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 10px 15px;
    color: var(--text-primary);
    font-size: 0.9rem;
    outline: none;
}

.chat-input:focus {
    border-color: var(--accent-pink);
}

.send-btn {
    background: var(--accent-pink);
    color: white;
    border: none;
    border-radius: 10px;
    width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.send-btn:hover {
    background: #ff1e56;
}

/* Custom Scrollbar */
.chat-messages::-webkit-scrollbar {
    width: 4px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

/* Mobile Adjustments */
@media (max-width: 480px) {
    .chat-window {
        width: 100vw;
        height: 100vh;
        max-height: none;
        bottom: -30px;
        right: -30px;
        border-radius: 0;
    }
    
    .chat-widget-container {
        bottom: 20px;
        right: 20px;
    }
}
