/* A floating container for the chat button and window */
#ita-chatbot-floating-wrapper {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

/* The toggle button to open the chatbot */
#ita-chatbot-toggle {
    position:fixed;
    background-color: #011f2c;
    color: white;
    border: none;
    border-radius: 50px;
    padding: 15px 18px;
    font-size: 6px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: background-color 0.3s ease, transform 0.3s ease;
    bottom:20px;
    right:20px;
}

#ita-chatbot-toggle:hover {
    opacity: 0.7;
    transform: scale(1.05);
}

/* The main chat window container */
#ita-chatbot-window {
    width: 350px;
    height: 510px;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-family: Arial, sans-serif;
}

/* The header of the chat window */
#chatbot-header {
    background-color: #4571bb;
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
    font-size: 18px;
}

#chatbot-close-button {
    background: none;
    border: none;
    color: white;
    font-size: 36px;
    cursor: pointer;
    line-height: 1;
}

/* The main chat content area */
#chat-window-content {
    flex-grow: 1;
    padding: 15px;
    overflow-y: auto;
    background-color: #f4f4f4;
}

/* Styles for chat messages */
.message {
    padding: 10px 15px;
    border-radius: 20px;
    margin-bottom: 10px;
    max-width: 80%;
    word-wrap: break-word;
}

.message.user {
    background-color: #007bff;
    color: white;
    margin-left: auto;
    border-top-right-radius: 5px;
}

.message.bot {
    background-color: #e0e0e0;
    color: #333;
    border-top-left-radius: 5px;
}

.message.bot.welcome {
    background-color: #c8e6c9;
    color: #333;
    font-style: italic;
    text-align: center;
}

.message.bot.loading {
    background-color: #f0f0f0;
    font-style: italic;
    animation: pulse 1.5s infinite ease-in-out;
}

.message.bot.error {
    background-color: #ffcdd2;
    color: #d32f2f;
    font-weight: bold;
}

@keyframes pulse {
    0% { opacity: 0.5; }
    50% { opacity: 1; }
    100% { opacity: 0.5; }
}

/* The input area at the bottom of the chat window */
#chat-input-area {
    display: flex;
    padding: 10px;
    background-color: #ffffff;
    border-top: 1px solid #ddd;
}

#chat-input {
    flex-grow: 1;
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 10px 15px;
    font-size: 14px;
    outline: none;
}

#send-button {
    background-color: #4571bb;
    color: white;
    border: none;
    border-radius: 20px;
    padding: 10px 15px;
    margin-left: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#send-button:hover {
    opacity: 0.7;
}

#ita-chatbot-floating-wrapper.open #ita-chatbot-toggle {
    display: none;
}
.message.bot a {
    color: #0055ff; /* A different color for links */
    text-decoration: underline;
}

.message.bot a:hover {
    color: #007bff; /* A slightly different color on hover */
}
/* Responsive adjustments */
@media (max-width:500px) {
    #ita-chatbot-floating-wrapper.open #ita-chatbot-window {
        width: 100% !important;
        height: 100% !important;
        border-radius: 0;
        bottom: 0;
        right: 0;
    }

    #ita-chatbot-floating-wrapper.open {
        bottom: 0;
        right: 0;
        width: 100%;
        height: 100%;
        background-color: white;
        transition: all 0.3s ease-in-out;
    }

    #ita-chatbot-floating-wrapper.open {
        transform: translateY(0);
    }
}

/* New styles for the contact form */
#contact-form-container {
    padding: 0 20px 20px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    margin-top:-21px;
}
#contact-form-container h3 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
}
#contact-form-container input {
    width: 90%;
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 5px;
    border: 1px solid #ddd;
    font-size: 14px;
}
#contact-form-container button {
    width: 90%;
    padding: 12px;
    background-color: #4571bb;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
#contact-form-container button:hover {
    background-color: #d35502;
}
#contact-form-container .required-label::after {
    content: "*";
    color: red;
    margin-left: 4px;
}
#form-error-message {
    color: red;
    font-size: 12px;
    margin-bottom: 10px;
    text-align: center;
    display: none;
}
