
#tg-chatbot {
    font-family: Arial, sans-serif;
    position: relative;
    z-index: 999999;
}

#tg-chat-toggle {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 62px;
    height: 62px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #092c55, #1675e8);
    color: white;
    font-size: 29px;
    cursor: pointer;
    box-shadow: 0 5px 20px #0004;
}

#tg-chat-window {
    position: fixed;
    bottom: 100px;
    right: 25px;
    width: 350px;
    height: 480px;
    max-height: 75vh;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 35px #0003;
    display: flex;
    flex-direction: column;
}

.tg-chat-hidden {
    display: none !important;
}

.tg-chat-header {
    background: linear-gradient(135deg, #092c55, #1675e8);
    color: white;
    padding: 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tg-chat-header strong {
    display: block;
    font-size: 17px;
}

.tg-chat-header small {
    display: block;
    margin-top: 5px;
    font-size: 11px;
}

#tg-chat-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 27px;
    cursor: pointer;
}

#tg-chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f3f6fb;
}

.tg-message {
    padding: 11px 13px;
    border-radius: 12px;
    margin-bottom: 12px;
    max-width: 85%;
    font-size: 14px;
    line-height: 1.6;
}

.tg-bot {
    background: white;
    color: #222;
    border: 1px solid #e5eaf2;
}

.tg-user {
    background: #1268cf;
    color: white;
    margin-left: auto;
}

.tg-chat-input {
    display: flex;
    padding: 12px;
    gap: 8px;
    border-top: 1px solid #eee;
}

#tg-chat-text {
    flex: 1;
    min-width: 0;
    border: 1px solid #ddd;
    border-radius: 25px;
    padding: 12px;
    outline: none;
}

#tg-chat-send {
    width: 43px;
    border: none;
    border-radius: 50%;
    background: #1268cf;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

@media(max-width: 480px) {
    #tg-chat-window {
        width: calc(100% - 24px);
        right: 12px;
        bottom: 90px;
        height: 70vh;
    }

    #tg-chat-toggle {
        right: 18px;
        bottom: 18px;
    }
}

/* Chatbot floating icon position */
#tg-chat-toggle {
    bottom: 55px;
    overflow: visible;
}


/* Chatbot Help Label */
#tg-chat-label {
    position: fixed;
    bottom: 8px;
    right: 10px;
    z-index: 1000000;
    background: #ffffff;
    color: #092c55;
    padding: 7px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    box-shadow: 0 3px 12px rgba(0,0,0,0.20);
    white-space: nowrap;
    pointer-events: none;
}

/* Remove old pseudo text */
#tg-chat-toggle::after {
    content: none;
}


/* Interactive Chatbot Menu Buttons */

.tg-chat-option {
    display: block;
    width: 92%;
    margin: 8px auto;
    padding: 12px 15px;
    background: #ffffff;
    color: #0b4c91;
    border: 1px solid #c9def8;
    border-radius: 10px;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.tg-chat-option:hover {
    background: #eaf3ff;
    border-color: #1675e8;
}

.tg-chat-back {
    background: #eaf1fa;
    color: #092c55;
    text-align: center;
}

.tg-chat-link {
    display: inline-block;
    margin: 5px 15px 12px;
    color: #1268cf;
    font-weight: bold;
    text-decoration: underline;
}

/* Tagore Assistant - Premium Menu Buttons */

#tg-chat-messages button.tg-chat-option {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box !important;
    margin: 9px 0 !important;
    padding: 13px 15px !important;
    background: #ffffff !important;
    color: #0b4c91 !important;
    border: 1px solid #d5e5f8 !important;
    border-radius: 12px !important;
    text-align: left !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    white-space: normal !important;
    transition: 0.2s ease !important;
}

#tg-chat-messages button.tg-chat-option:hover {
    background: #eaf3ff !important;
    border-color: #1675e8 !important;
}

#tg-chat-messages button.tg-chat-back {
    background: #eaf1fa !important;
    color: #092c55 !important;
    text-align: center !important;
}

/* LANGUAGE SELECTION SCREEN */
#tg-chat-language-screen {
    display: block;
    padding: 25px 15px;
    text-align: center;
    background: #ffffff;
    color: #222;
}

#tg-chat-language-screen h3 {
    font-size: 19px;
    margin: 5px 0;
    color: #123c70;
}

#tg-chat-language-screen p {
    font-size: 13px;
    color: #777;
    margin: 5px 0 22px;
}

#tg-chat-language-screen .tg-language-option {
    display: block;
    width: 100%;
    padding: 13px 10px;
    margin: 12px 0;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #123c70, #1675df);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

#tg-chat-language-screen .tg-language-option:hover {
    background: #0b2d55;
}

.tg-chat-header-actions {
    display: flex;
    align-items: center;
    gap: 7px;
}

#tg-chat-language {
    padding: 5px 7px;
    border-radius: 5px;
    border: 1px solid #ddd;
    font-size: 12px;
    max-width: 90px;
    background: #fff;
    color: #222;
}

#tg-chat-language-screen .tg-language-option:focus {
    outline: 2px solid #ff9d00;
    outline-offset: 2px;
}

/* FINAL TAGORE CHATBOT POSITION AND CLICK FIX */

#tg-chatbot {
    position: fixed !important;
    right: 18px !important;
    bottom: 18px !important;
    width: 62px;
    height: 62px;
    z-index: 2147483000 !important;
    pointer-events: none !important;
}

#tg-chat-toggle {
    position: absolute !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 62px !important;
    height: 62px !important;
    z-index: 2147483000 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
}

#tg-chat-toggle span {
    pointer-events: none !important;
}

#tg-chat-window {
    position: fixed !important;
    right: 25px !important;
    bottom: 100px !important;
    z-index: 2147483000 !important;
    pointer-events: auto !important;
}

#tg-chat-label {
    pointer-events: none !important;
    z-index: 2147482999 !important;
}

#tg-chatbot .tg-chat-header-actions,
#tg-chatbot .tg-language-option {
    pointer-events: auto !important;
}
