/* CSS (converted from SCSS) */
@import url('https://fonts.googleapis.com/css?family=Noto+Sans');

.floating-chat {
    font: 12px/16px 'Noto Sans', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: black;
    position: fixed;
    bottom: 40px;
    right: 40px;
    width: 60px;
    height: 60px;
    transform: translateY(70px);
    transition: all 250ms ease-out;
    border-radius: 50%;
    background: -moz-linear-gradient(-45deg, #d7e9fc 0, #d7e9fc 25%, #c9e2fb 50%, #bcdcfd 75%, #bcdcfd 100%);
    background: -webkit-linear-gradient(-45deg, #d7e9fc 0, #d7e9fc 25%, #c9e2fb 50%, #bcdcfd 75%, #bcdcfd 100%);
    opacity: 0;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.floating-chat.enter:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.19), 0 6px 6px rgba(0, 0, 0, 0.23);
    opacity: 1;
}

.floating-chat.enter {
    transform: translateY(0);
    opacity: 0.6;
    box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.12), 0px 1px 2px rgba(0, 0, 0, 0.14);
}

.floating-chat.expand {
    margin-top: 62px; /* Adjust the padding to match the height of the fixed navbar */
    background: -moz-linear-gradient(-45deg, #F4F4F4 0, #F4F4F4 25%, #fdfaf4 50%, #e7ebef 75%, #e7ebef 100%);
    background: -webkit-linear-gradient(-45deg, #F4F4F4 0, #F4F4F4 25%, #fdfaf4 50%, #e7ebef 75%, #e7ebef 100%);
    width: 300px; /* Adjusted width for sidebar */
    height: calc(100% - 60px); /* Full height for sidebar */
    max-height: none; /* Remove the max height */
    right: 0; /* Align to the right */
    bottom: 0; /* Align to the bottom */
    top: 0; /* Align to the top */
    border-radius: 0; /* Remove border radius */
    cursor: auto;
    opacity: 1;
}

.floating-chat button {
    background: transparent;
    border: 0;
    color: black;
    text-transform: uppercase;
    border-radius: 3px;
    cursor: pointer;
}

.chat {
    display: flex;
    flex-direction: column;
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    border-radius: 50%;
    transition: all 250ms ease-out;
    margin: auto;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.chat.enter {
    opacity: 1;
    border-radius: 0;
    margin: 10px;
    width: auto;
    height: auto;
}

.header {
    flex-shrink: 0;
    padding-bottom: 10px;
    display: flex;
    background: transparent;
}

.header .title {
    font-size: 14px;
    flex-grow: 1;
    flex-shrink: 1;
    padding: 0 5px;
}

.messages {
    padding: 10px;
    margin: 0;
    list-style: none;
    overflow-y: scroll;
    overflow-x: hidden;
    flex-grow: 1;
    border-radius: 4px;
}

.messages::-webkit-scrollbar {
    width: 5px;
}

.messages::-webkit-scrollbar-track {
    border-radius: 5px;
    background-color: rgba(25, 147, 147, 0.1);
}

.messages::-webkit-scrollbar-thumb {
    border-radius: 5px;
    background-color: rgba(25, 147, 147, 0.2);
}

.messages li {
    position: relative;
    clear: both;
    display: flex;
    max-width: 81%;
}

.messages li p {
    align-items: center;
    padding: 14px;
    margin: 0 0 20px 0;
    font: 12px/16px 'Noto Sans', sans-serif;
    border-radius: 10px;
    word-wrap: break-word;
    background-color: #d8dee6;
}

.messages li.other {
    animation: show-chat-odd 0.15s 1 ease-in;
    float: left;
}

.messages li.self {
    animation: show-chat-even 0.15s 1 ease-in;
    float: right;
}

.messages li.self p {
    background-color: #ace2ec;
}

.messages li img {
    width: 35px;
    height: 35px;
    margin-right: 10px;
}

.footer {
    flex-shrink: 0;
    display: flex;
    padding-top: 10px;
    max-height: 90px;
    background: transparent;
}

.footer .text-box {
    border-radius: 3px;
    background: white;
    min-height: 100%;
    width: 100%;
    margin-right: 5px;
    overflow-y: auto;
    padding: 2px 5px;
    font-size: 12px;
}

.footer .text-box::-webkit-scrollbar {
    width: 5px;
}

.footer .text-box::-webkit-scrollbar-track {
    border-radius: 5px;
    background-color: rgba(25, 147, 147, 0.1);
}

.footer .text-box::-webkit-scrollbar-thumb {
    border-radius: 5px;
    background-color: rgba(25, 147, 147, 0.2);
}

@keyframes show-chat-even {
    0% {
        margin-left: -480px;
    }
    100% {
        margin-left: 0;
    }
}

@keyframes show-chat-odd {
    0% {
        margin-right: -480px;
    }
    100% {
        margin-right: 0;
    }
}
