@import url('https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,100..900&family=Pacifico&display=swap');

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter",sans-serif;
}
body{
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(#EEEEFF,#C8C7FF);
}
.chatbot-popup{
    position: relative;
    width: 420px;
    background: #fff;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 0 128px 0 rgba(0,0,0,0.1),0 32px 65px -48px rgba(0,0,0,0.5);
}
.chat-header{
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #140ed2;
    padding: 15px 22px;
}
.chat-header .header-info{
    display: flex;
    align-items: center;
    gap: 10px;
}
.header-info .chatbot-logo{
    width: 35px;
    height: 35px;
    background: #fff;
    border-radius: 40%;
    padding: 6px;
    fill: #3c36e7;
}
.header-info .logo-text{
    color: #fff;
    font-size: 1.25rem;
    font-weight: bold;
}
.chat-header #close-chatbot{
    width: 35px;
    height: 30px;
    border: none;
    background: #140ed2;
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    transition: 0.s ease;
}
.chat-header #close-chatbot:hover{
    background: #4640fd;
}
.chat-body{
    scrollbar-width:thin;
    scrollbar-color: #ccccf5 transparent;
    padding: 25px 22px;
    gap: 20px;
    display: flex;
    flex-direction: column;
    overflow-y:auto;
    height: 480px;
    margin-bottom: 82px;
}
.chat-body .message{
    display: flex;
    align-items: center;
    gap: 11px;
}
.chat-body .bot-message .bot-avatar{
    width: 40px;
    height: 40px;
    background: #3c36e7;
    border-radius: 50%;
    padding: 6px;
    fill: #fff;
    flex-shrink: 0;
    align-self: flex-end;
}
.chat-body .message .message-text{
    padding: 12px 16px;
    max-width: 100%;
    font-size: 0.8rem;
    background: #F2F2FF;
}
.chat-body .user-message{
    flex-direction: column;
    align-self:flex-end;
}
.chat-body .bot-message .message-text{
 background: #F2F2FF;
 border-radius: 13px 13px 3px 13px;
}
.chat-body .bot-message.thinking .message-text{
    padding:2px 16px;
}
.chat-body .user-message .message-text{
    color: #fff;
    background: #3c36e7;
    border-radius: 13px 13px 3px 13px;
    margin-left: 196px;
}
.chat-body .bot-message .thinking-indicator{
    display: flex;
    gap: 3px;
    padding-block: 15px;
}
.chat-body .bot-message .thinking-indicator .dot{
    height: 7px;
    width: 7px;
    opacity: 0.7;
    background: #4640fd;
    border-radius: 32px;
    animation:  dotPulse 1.8s ease-in-out infinite;
}
.chat-body .bot-message .thinking-indicator .dot:nth-child(1){
    animation-delay: 0.2s;
}
.chat-body .bot-message .thinking-indicator .dot:nth-child(2){
    animation-delay:0.3s;
}
.chat-body .bot-message .thinking-indicator .dot:nth-child(3){
    animation-delay: 0.4s;
}
@keyframes dotPulse{
    0%,44%{
        transform: translateY(0);
    }
    28%{
        opacity: 0.4;
        transform: translateY(-4px);
    }
    44%{
        opacity: 0.2;
    }
}
.chat-footer{
    position: absolute;
    bottom: 0;
    width: 100%;
    background:#fff;
    padding: 15px 22px 20px;
}
.chat-footer .chat-form{
    position: relative;
    display: flex;
    align-items: center;
    background: #fff;
    outline: 1px solid #CCCCE5;
    border-radius: 32px;
}
.chat-footer .chat-form:focus-within{
    outline: 3px solid rgba(0,0,0,0.5);
}
.chat-form .message-input{
    border: none;
    outline: none;
    resize:none;
    font-size: 0.95rem;
    height: 47px;
    width: 100%;
    padding: 13px;
}
.chat-form .chat-controls{
    display: flex;
    height: 47px;
    align-items: center;
    align-self: flex-end;
    padding: 6px;
}
.chat-form .chat-controls #send-message{
 background: #4540ca;
 color: white;
 display: none;
}
.chat-form .message-input:valid~.chat-controls #send-message{
    display: block;
}
.chat-form .chat-controls #send-message:hover{
    background: #6864db;
}
.chat-form .chat-controls button{
    height: 35px;
    width: 35px;
    border: none;
    border-radius: 50%;
    color: #4540ca;
    background: none;
    transition: 0.3s ease;
    cursor: pointer;
}
.chat-form .chat-controls button:hover{
    background: #f1f1ff;
}
.chat-body .user-message .attach{
    width: 47%;
    margin-left: 200px;
    border-radius: 13px 3px 13px 13px;
    margin-top: -10px;

}
em-emoji-picker{
    position: absolute;
    left: 50%;
    top:-337px ;
    width: 100%;
    max-width: 350px;
    max-height: 330px;
    visibility: hidden;
    transform: translateX(-50%);

}
body.show-emoji-picker    em-emoji-picker{
    visibility: visible;
}

