/* Chatbot Widget Styles */
:root {
    --chat-primary: #2c5f7c;
    --chat-secondary: #4a9b8e;
    --chat-bg: #ffffff;
    --chat-text: #333333;
    --chat-user-msg: #e3f2fd;
    --chat-bot-msg: #f1f1f1;
}

/* Floating Button */
.chatbot-toggler {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--chat-secondary);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    z-index: 9999;
    border: none;
}

.chatbot-toggler:hover {
    transform: scale(1.1);
    background: var(--chat-primary);
}

.chatbot-toggler i {
    color: white;
    font-size: 28px;
    transition: transform 0.3s ease;
}

.chatbot-toggler.active i:first-child {
    display: none;
}

.chatbot-toggler i:last-child {
    display: none;
}

.chatbot-toggler.active i:last-child {
    display: block;
}

/* Chat Window */
.chatbot-window {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 350px;
    height: 500px;
    background: var(--chat-bg);
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.15);
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 9998;
    display: flex;
    flex-direction: column;
}

.chatbot-window.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

/* Header */
.chatbot-header {
    background: linear-gradient(135deg, var(--chat-primary), var(--chat-secondary));
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: white;
}

.chatbot-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}

.chatbot-header p {
    font-size: 0.8rem;
    opacity: 0.9;
    margin: 0;
}

.chatbot-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
}

/* Chat Body */
.chatbot-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.chat-msg {
    display: flex;
    align-items: flex-end;
    margin-bottom: 10px;
}

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

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

.msg-content {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 15px;
    font-size: 0.95rem;
    line-height: 1.4;
    position: relative;
}

.chat-msg.bot .msg-content {
    background: var(--chat-bot-msg);
    color: var(--chat-text);
    border-bottom-left-radius: 2px;
}

.chat-msg.user .msg-content {
    background: var(--chat-primary);
    color: white;
    border-bottom-right-radius: 2px;
}

/* Options / Buttons */
.chat-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.chat-option-btn {
    background: white;
    border: 1px solid var(--chat-primary);
    color: var(--chat-primary);
    padding: 8px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s;
    text-align: left;
}

.chat-option-btn:hover {
    background: var(--chat-primary);
    color: white;
}

/* Input Area */
.chatbot-input {
    padding: 15px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
}

.chatbot-input textarea {
    flex: 1;
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 10px 15px;
    resize: none;
    height: 45px;
    font-family: inherit;
    outline: none;
}

.chatbot-input button {
    background: var(--chat-secondary);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.chatbot-input button:hover {
    background: var(--chat-primary);
}

@media (max-width: 480px) {
    .chatbot-window {
        width: 90%;
        right: 5%;
        bottom: 90px;
        height: 70vh;
    }
}
