/* Chat Widget Styles */
:root {
    --chat-primary: #0073aa;
    --chat-bg: #ffffff;
    --chat-text: #333333;
    --chat-border: #e0e0e0;
    --chat-user-bg: #f0f7fb;
    --chat-bot-bg: #ffffff;
}

/* Floating Chat Trigger (Unified Pill) */
#chat-container {
    position: fixed;
    bottom: 25px;
    right: 25px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 1000;
    background-color: white;
    border: 2px solid var(--chat-primary);
    padding: 8px 18px;
    border-radius: 40px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

#chat-container:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

#chat-bubble {
    display: flex;
    align-items: center;
    justify-content: center;
}

#chat-bubble svg {
    width: 24px;
    height: 24px;
    fill: var(--chat-primary);
}

#chat-label {
    color: var(--chat-primary);
    font-size: 14px;
    font-weight: 800;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Pulse animation on the container border */
#chat-container::after {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 40px;
    border: 2px solid var(--chat-primary);
    opacity: 0.4;
    z-index: -1;
    animation: pulsePill 2s infinite;
}

@keyframes pulsePill {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }

    70% {
        transform: scale(1.08, 1.25);
        opacity: 0;
    }

    100% {
        transform: scale(1.08, 1.25);
        opacity: 0;
    }
}

/* Chat Window */
#chat-window {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 380px;
    height: 600px;
    max-height: calc(100vh - 110px);
    background-color: var(--chat-bg);
    border-radius: 16px;
    display: none;
    flex-direction: column;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    overflow: hidden;
    border: 1px solid var(--chat-border);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

#chat-window.active {
    display: flex;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
.chat-header {
    background-color: var(--chat-primary);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.chat-close {
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.chat-close:hover {
    opacity: 1;
}

/* Messages Area */
#chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background-color: #f9f9f9;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.4;
    position: relative;
    word-wrap: break-word;
}

.message.user {
    align-self: flex-end;
    background-color: var(--chat-primary);
    color: white;
    border-bottom-right-radius: 2px;
}

.message.bot {
    align-self: flex-start;
    background-color: white;
    color: var(--chat-text);
    border: 1px solid var(--chat-border);
    border-bottom-left-radius: 2px;
}

/* Input Area */
.chat-input-container {
    padding: 15px;
    background-color: white;
    border-top: 1px solid var(--chat-border);
    display: flex;
    gap: 10px;
}

#chat-input {
    flex: 1;
    border: 1px solid var(--chat-border);
    border-radius: 20px;
    padding: 8px 15px;
    outline: none;
    font-size: 14px;
}

#chat-input:focus {
    border-color: var(--chat-primary);
}

#chat-send {
    background: none;
    border: none;
    color: var(--chat-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
}

#chat-send:disabled {
    opacity: 0.3;
}

/* Suggestions */
#chat-suggestions {
    padding: 0 15px 10px;
    background-color: white;
    text-align: center;
}

.suggestion-tip {
    font-size: 11px;
    color: #888;
    font-style: italic;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Mobile Adjustments */
@media (max-width: 480px) {
    #chat-window {
        bottom: 0;
        right: 0;
        width: 100%;
        height: 100%;
        max-height: 100%;
        border-radius: 0;
    }
}

塑造