/* KituDreamCake AI Chat Widget Styles */
.kitu-chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: Arial, sans-serif;
}

.chat-toggle {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 15px 20px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-weight: bold;
    font-size: 14px;
}

.chat-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0,0,0,0.3);
}

.chat-icon {
    font-size: 18px;
}

.chat-container {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #e0e0e0;
}

.chat-header {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h4 {
    margin: 0;
    font-size: 16px;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.chat-close:hover {
    background: rgba(255,255,255,0.2);
}

.chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f8f9fa;
}

.chat-message {
    margin-bottom: 15px;
    display: flex;
}

.chat-message.user {
    justify-content: flex-end;
}

.chat-message.bot {
    justify-content: flex-start;
}

.message-content {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.4;
    white-space: pre-line;
}

.chat-message.user .message-content {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    border-bottom-right-radius: 5px;
}

.chat-message.bot .message-content {
    background: white;
    color: #333;
    border: 1px solid #e0e0e0;
    border-bottom-left-radius: 5px;
}

.chat-input-container {
    padding: 15px;
    background: white;
    border-top: 1px solid #e0e0e0;
    display: flex;
    gap: 10px;
}

#chat-input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 25px;
    outline: none;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

#chat-input:focus {
    border-color: #ff6b6b;
}

.chat-send {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 12px 20px;
    cursor: pointer;
    font-weight: bold;
    font-size: 14px;
    transition: all 0.3s ease;
}

.chat-send:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

.typing-indicator .message-content {
    padding: 15px 20px;
}

.typing-dots {
    display: flex;
    gap: 4px;
    align-items: center;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #999;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(1) { animation-delay: -0.32s; }
.typing-dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes typing {
    0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

/* Dark theme support */
[data-theme="dark"] .chat-container {
    background: #333;
    border-color: #555;
}

[data-theme="dark"] .chat-messages {
    background: #2a2a2a;
}

[data-theme="dark"] .chat-message.bot .message-content {
    background: #444;
    color: #fff;
    border-color: #555;
}

[data-theme="dark"] .chat-input-container {
    background: #333;
    border-color: #555;
}

[data-theme="dark"] #chat-input {
    background: #444;
    color: #fff;
    border-color: #555;
}

/* Mobile responsive */
@media (max-width: 480px) {
    .kitu-chat-widget {
        bottom: 15px;
        right: 15px;
    }
    
    .chat-container {
        width: calc(100vw - 30px);
        height: 400px;
        right: -15px;
    }
    
    .chat-toggle {
        padding: 12px 16px;
        font-size: 13px;
    }
    
    .chat-text {
        display: none;
    }
}
