        body {
            font-family: 'Prompt', sans-serif;
            background-color: #fbfbfb;
            height: 100vh;
            width: 100vw;
            /* overflow: hidden; */
            position: relative;
        }

        ul li {
                font-weight: normal !important;
                margin-bottom: 0px !important;
            }
        :root {
            --theme-color: #183668;
            --theme-dark: #7d1a18;
            --theme-light: #fce8e8;
            --bg-warm: #fbfbfb;
        }
        .flex-center-col {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            height: 100%;
        }
        .rounded-circle { border-radius: 50%; }
        .rounded-lg { border-radius: 15px; }
        .no-margin { margin: 0; }
        .text-white { color: #fff; }
        
        #chat-widget {
            position: fixed;
            bottom: 90px;
            right: 20px;
            width: 380px;
            height: 750px;
            max-width: 90vw;
            max-height: 75vh;
            background-color: #fff;
            border-radius: 16px;
            box-shadow: 0 10px 25px rgba(0,0,0,0.15);
            border: 1px solid #e0e0e0;
            z-index: 9999;
            display: flex;
            flex-direction: column;
            overflow: hidden;
            transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
            transform-origin: bottom right;
        }

        .chat-widget-enter {
            opacity: 0;
            transform: translateY(20px) scale(0.95);
            pointer-events: none;
        }
        .chat-widget-active {
            opacity: 1;
            transform: translateY(0) scale(1);
            pointer-events: auto;
        }

        .chat-header {
            padding: 15px;
            border-bottom: 1px solid #eee;
            display: flex;
            align-items: center;
            background: #fff;
        }
        .header-icon {
            width: 40px;
            height: 40px;
            border-radius: 50%;
            background: linear-gradient(45deg, var(--theme-color), #183668);
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-right: 12px;
            box-shadow: 0 2px 5px rgba(27, 106, 146, 0.505);
        }
        .status-dot {
            width: 8px;
            height: 8px;
            background-color: #5cb85c; /* Bootstrap success color */
            border-radius: 50%;
            display: inline-block;
            margin-right: 4px;
            animation: pulse 2s infinite;
        }

        #chat-box {
            flex: 1;
            overflow-y: auto;
            padding: 15px;
            background-color: var(--bg-warm);
        }

        .chat-scroll {
            scrollbar-width: thin;
            scrollbar-color: #a0aec0 transparent;
        }
        .chat-scroll::-webkit-scrollbar {
            width: 6px;
        }
        .chat-scroll::-webkit-scrollbar-track {
            background: rgba(0,0,0,0.05);
        }
        .chat-scroll::-webkit-scrollbar-thumb {
            background-color: #a0aec0;
            border-radius: 20px;
            border: 1px solid transparent;
            background-clip: content-box;
        }
        .chat-scroll::-webkit-scrollbar-thumb:hover {
            background-color: #718096;
        }

        .msg-container {
            display: flex;
            margin-bottom: 15px;
            animation: messagePop 0.3s ease-out;
        }
        .msg-container.user { justify-content: flex-end; }
        
        .avatar-ai {
            width: 45px;
            height: 45px;
            border-radius: 50%;
            background-color: #ffffff;
            border: 1px solid #eee;
            color: #183668;
            font-size: 10px;
            font-weight: bold;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-right: 8px;
            flex-shrink: 0;
        }

        .bubble {
            max-width: 85%;
            padding: 10px 14px;
            border-radius: 16px;
            font-size: 14px;
            line-height: 1.5;
            position: relative;
            word-wrap: break-word;
        }
        .bubble-ai {
            background-color: #fff;
            border: 1px solid #eee;
            color: #333;
            border-top-left-radius: 4px;
        }
        .bubble-user {
            background: #f5f5f5;
            color: #000000;
            border-top-right-radius: 4px;
            border: 1px solid #eee;
        }
        .time-stamp {
            font-size: 10px;
            margin-top: 4px;
            text-align: right;
            opacity: 0.7;
        }

        /* --- Quick Chips --- */
        .quick-chips-container {
            padding: 10px 15px;
            background: #fff;
            border-top: 1px solid #f5f5f5;
            white-space: nowrap;
            overflow-x: auto;
            -webkit-overflow-scrolling: touch;
        }
        
        .btn-chip {
            border-radius: 20px;
            font-size: 12px;
            padding: 5px 12px;
            margin-right: 5px;
            border: 1px solid #eee;
            color: #333;
            background-color: #eee;
            transition: all 0.2s;
        }
        .btn-chip:hover {
            background-color: #eee;
            text-decoration: none;
            color: #333;
            transform: translateY(-1px);
        }

        /* --- Footer / Input --- */
        .chat-footer {
            padding: 10px 15px;
            background: #fff;
            border-top: 1px solid #eee;
        }
        .chat-input-wrapper {
            display: flex;
            align-items: center;
            gap: 8px;
        }        
        .btn-send {
            background-color: var(--theme-color);
            color: white;
            border-radius: 50%;
            width: 36px;
            height: 36px;
            padding: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            border: none;
            box-shadow: 0 2px 4px rgba(0,0,0,0.2);
            transition: transform 0.1s;
            flex-shrink: 0;
        }
        .btn-send:hover { background-color: var(--theme-color); color: white; }
        .btn-send:active {  color: white;transform: scale(0.95); }
        
        .btn-upload {
            color: #999;
            background: transparent;
            border: none;
            font-size: 20px;
            padding: 0 5px;
            cursor: pointer;
            transition: color 0.2s;
            flex-shrink: 0;
            margin: 0;
        }
        .btn-upload:hover { color: var(--theme-color); }
        
        .form-control-chat {
            border-radius: 20px;
            border: 1px solid #ddd;
            box-shadow: none;
            padding-left: 15px;
            width: 100%;
        }
        .form-control-chat:focus {
            border-radius: 20px;
            border-color: var(--theme-color);
            box-shadow: 0 0 0 2px rgba(31, 118, 152, 0.1);
        }

        #chat-toggle-btn {
            position: fixed;
            bottom: 20px;
            right: 20px;
            width: 60px;
            height: 60px;
            border-radius: 50%;
            background:#183668;
            color: white;
            border: none;
            z-index: 10000;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        #chat-toggle-btn:hover {
            transform: scale(1);
            box-shadow: 0 4px 12px rgba(31, 118, 152, 0.1);
        }
        .icon-toggle {
            width: 28px;
            height: 28px;
        }
        .rotate-icon { transform: rotate(90deg); }

        #welcome-bubble {
            position: fixed;
            bottom: 35px;
            right: 90px;
            background: white;
            padding: 8px 12px;
            border-radius: 8px;
            box-shadow: 0 2px 8px  rgba(31, 118, 152, 0.1);
            border: 1px solid #eee;
            font-size: 12px;
            color: #555;
            white-space: nowrap;
            z-index: 9998;
            animation: float-msg 3s ease-in-out infinite;
        }
        #welcome-bubble::after {
            content: '';
            position: absolute;
            right: -6px;
            top: 50%;
            transform: translateY(-50%) rotate(45deg);
            width: 10px;
            height: 10px;
            background: white;
            border-top: 1px solid #eee;
            border-right: 1px solid #eee;
        }

        #loading-overlay {
            position: absolute;
            top: 0; left: 0; right: 0; bottom: 0;
            background: rgba(255,255,255,0.9);
            z-index: 100;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
        }

        @keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.5; } 100% { opacity: 1; } }
        @keyframes messagePop { 0% { opacity: 0; transform: translateY(10px); } 100% { opacity: 1; transform: translateY(0); } }
        @keyframes float-msg { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
        @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
        
        .typing-dot {
            width: 6px; height: 6px; background: #aaa; border-radius: 50%;
            display: inline-block; margin: 0 2px;
            animation: typing 1.0s infinite ease-in-out both;
        }
        .typing-dot:nth-child(1) { animation-delay: -0.23s; }
        .typing-dot:nth-child(2) { animation-delay: -0.11s; }
        @keyframes typing { 0%, 80%, 100% { transform: scale(0); } 40% { transform: scale(1); } }
        
        .hidden { display: none !important; }
    .chat-tooltip-message {
    position: fixed;
    /* ปรับตำแหน่งความสูง (Bottom) ให้ตรงกับกึ่งกลางปุ่มไอคอนของคุณ */
    bottom: 35px; 
    
    /* ปรับระยะห่างจากขวา (Right) ให้ข้อความอยู่ทางซ้ายของไอคอน 
       (ค่านี้ = ความกว้างไอคอน + ระยะห่างที่ต้องการ) */
    right: 100px; 

    background-color: #ffffff; /* สีพื้นหลัง */
    color: #333333;            /* สีตัวอักษร */
    padding: 8px 16px;
    border-radius: 20px;       /* ความมนของกล่อง */
    box-shadow: 0 4px 15px  rgba(31, 118, 152, 0.1); /* เงา */
    font-size: 14px;
    font-weight: 500;
    z-index: 9999;             /* ให้ลอยอยู่บนสุด */
    white-space: nowrap;       /* ไม่ให้ข้อความขึ้นบรรทัดใหม่ */
    
    /* เพิ่ม Animation เล็กน้อยให้ดูน่าสนใจ */
    animation: floatMessage 2s infinite ease-in-out;
}

/* สร้างสามเหลี่ยมชี้ไปทางขวา (หาไอคอน) */
.chat-tooltip-message::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -6px; /* ขยับสามเหลี่ยมออกไปทางขวา */
    margin-top: -6px;
    border-width: 6px 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent transparent #ffffff;
}

/* Animation ลอยขึ้นลงเบาๆ (Optional) */
@keyframes floatMessage {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}