/* Chatbot Container */
#startpt-chatbot {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99999;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

/* Launcher Button */
#chatbot-launcher {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #003a43;
    /* Primary Teal */
    color: #fff;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

#chatbot-launcher:hover {
    transform: scale(1.05);
    background-color: #fe0101;
    /* Accent Red on hover */
}

/* Main Window */
#chatbot-window {
    width: 350px;
    height: 600px;
    max-height: 80vh;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    margin-bottom: 15px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    animation: slideUp 0.3s ease-out forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
#chatbot-header {
    background-color: #003a43;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
}

#chatbot-logo {
    height: 35px;
    margin-right: 12px;
    object-fit: contain;
}

#chatbot-title {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #ffffff !important;
}

#chatbot-subtitle {
    margin: 0;
    font-size: 12px;
    opacity: 0.9;
    color: #ffffff !important;
}

#chatbot-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    opacity: 0.8;
}

#chatbot-close:hover {
    opacity: 1;
}

/* Messages Area */
#chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f4f4f6;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Bubble Styles */
.chat-msg {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 15px;
    font-size: 14px;
    line-height: 1.4;
    word-wrap: break-word;
}

.chat-msg.assistant {
    background-color: #fff;
    color: #231f20;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.chat-msg.user {
    background-color: #408dd4;
    /* Secondary Blue */
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

.chat-msg.urgent {
    background-color: #fee2e2;
    color: #991b1b;
    border-left: 4px solid #fe0101;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 5px;
    margin-bottom: 10px;
}

.btn-quick-action {
    background: white;
    border: 1px solid #408dd4;
    color: #408dd4;
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-quick-action:hover {
    background: #408dd4;
    color: white;
}

/* Input Area */
#chatbot-input-area {
    padding: 15px;
    background: white;
    display: flex;
    gap: 10px;
    border-top: 1px solid #eee;
}

#chatbot-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    outline: none;
    font-family: inherit;
    font-size: 14px;
}

#chatbot-input:focus {
    border-color: #408dd4;
}

#chatbot-send {
    background: #003a43;
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

#chatbot-send:hover {
    background: #fe0101;
}

/* Typing Indicator */
.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 8px 12px;
    background: #fff;
    border-radius: 15px;
    align-self: flex-start;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.typing-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ccc;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-dot:nth-child(1) {
    animation-delay: 0s;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}

/* Mobile Responsiveness */
@media screen and (max-width: 450px) {
    #chatbot-window {
        width: 100%;
        height: 100%;
        max-height: 100vh;
        bottom: 0;
        right: 0;
        border-radius: 0;
        margin-bottom: 0;
    }

    #chatbot-header {
        border-radius: 0;
    }

    #chatbot-launcher {
        bottom: 15px;
        right: 15px;
    }
}