.bubble-btn {
    cursor: pointer;
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    display: flex;
    align-items: flex-end;
    height: 3rem;
    z-index:9999;
    text-decoration:none;
}

.bubble-btn .btn-txt {
    width: 18rem;
    font-size: 1.2rem;
    color: #333;
    text-align: right;
    background-color: #FFF;
    border-radius: 1rem 1rem 0 1rem;
    padding: 1rem;
    margin: 0 1rem 0 0;
    box-shadow: rgba(0, 0, 8, 0.2) 0px 2px 4px 0px;
    animation: 0.5s cubic-bezier(0.39, 0.575, 0.565, 1) both fade-in-right;
}
.bubble-btn .btn-txt > * {
    margin-bottom: 0;
}

.bubble-btn .btn-img {
    width: 4.8rem;
    height: 4.8rem;
    border-radius: 100%;
    box-shadow: none;
    animation: 1.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) 3s both shake;
    transform: translate3d(0px, 0px, 0px);
    backface-visibility: hidden;
    perspective: 1000px;
    will-change: transform;
}

#chatbot-box {
    display: none;
    overflow: hidden;
    position: fixed;
    width: 24rem;
    right: 2rem;
    bottom: 2rem;
    border: none;
    border-radius: 1rem;
    z-index: 9999;
}

#chatbot-box {
    background-color: #F3F3F3;
}
#chatbot-box .card-header {
    background-color: #004B87;
}
#chatbot-box .card-header > div {
    display: inline-flex;
    align-items: center;
}
#chatbot-box .card-header > div img {
    width: 24px;
    object-fit: contain;
    margin-right: 0.6rem;
}
#chatbot-box .card-header > div span {
    font-size: 20px;
}
#chatbot-box .card-header #chatbot-close {
    font-size: 16px;
    padding: 0;
}
#chatbot-box #chatbot-messages {
    height: 24rem;
    overflow-y: auto;
}
#chatbot-box #chatbot-messages .alert {
    position: sticky;
    top: 0;
    font-size: 12px;
    color: #004B87;
    border: none;
    border-radius: 0.6rem;
    padding: 0.6rem 1.8rem 0.9rem 0.9rem;
    margin-bottom: 1rem;
}
#chatbot-box #chatbot-messages .alert .btn-close {
    font-size: 0.6rem;
    padding: 0.9rem;
}
#chatbot-box #chatbot-messages .message {
    max-width: 80%;
    font-size: 16px;
    border-radius: 1rem;
    padding: 0.6rem 0.9rem;
    margin-bottom: 0.6rem;
}
#chatbot-box #chatbot-messages .message:last-child {
    margin-bottom: 0;
}
#chatbot-box #chatbot-messages .message > *:last-child {
    margin-bottom: 0.45rem;
}
#chatbot-box #chatbot-messages .message.user {
    background: #F3E9E0;
    border: 1px solid #004B87;
    border-bottom-right-radius: 0;
    padding-bottom: 0.9rem;
    margin-left: auto;
}
#chatbot-box #chatbot-messages .message.bot {
    background: #FFF;
    border-bottom-left-radius: 0;
    margin-right: auto;
}

/* Puntitos */
#chatbot-box #chatbot-messages .message.typing {
    display: flex;
    gap: 0.2em;
    align-items: flex-end;
    height: 2em;
    width: 3em;
}
#chatbot-box #chatbot-messages .message.typing span {
    display: block;
    width: 0.3em;
    height: 0.3em;
    background: #555; 
    border-radius: 50%;
    margin-bottom: 0;
    animation: bounce 1s infinite ease-in-out;
}

#chatbot-box #chatbot-messages .message.typing span:nth-child(1) { animation-delay: 0s; }
#chatbot-box #chatbot-messages .message.typing span:nth-child(2) { animation-delay: 0.2s; }
#chatbot-box #chatbot-messages .message.typing span:nth-child(3) { animation-delay: 0.4s; }

#chatbot-box .card-footer {
    background-color: #FFF;
    border-top: none;
    padding: 0 1rem;
}
#chatbot-box .card-footer #chatbot-input {
    font-size: 16px;
    background-color: transparent;
    border: none;
    box-shadow: none;
    padding: 0.75rem 1rem 0.75rem 0;
}
#chatbot-box .card-footer #chatbot-input:focus {
    box-shadow: none;
}
#chatbot-box .card-footer #chatbot-send {
    background-color: transparent;
    border: none;
    padding: 0;
}   
#chatbot-box .card-footer #chatbot-send img {
    width: 16px;
}

@keyframes bounce {
    0%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-0.2em); }
}

@media only screen and (max-width: 1024px) {
    #chatbot-box {
        width: 32rem;
    }
}

@media only screen and (max-width: 600px) {
    #chatbot-box {
        width: 100vw;
        height: 100vh;
        right: 0;
        bottom: 0;
    }
}