.chat-container .chat-list .avatar span {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    line-height: 14px;
}

body.admin\.chat\.page header {
    margin-top: 20px;
}

body.admin\.chat\.page footer.footer {
    display: none;
}

.error-message {
    width: 100%;
    padding: 20px 20px 50px;
}

.chat-app button.toggle-open {
    display: inline-flex;
    width: 120px;
    background: #000;
    color: #fff;
    justify-content: center;
    align-items: center;
    font-size: 13px;
    font-weight: 400;
    column-gap: 10px;
    padding: 7px 25px;
    height: auto;
    cursor: pointer;
    border-radius: 5px 0 0 0;
}

#start-form button {
    width: 100%;
    text-align: center;
    padding: 10px 20px;
    height: auto;
    background: #000;
    color: #fff;
    font-weight: 400;
    border-radius: 0;
}

.chat-app {
    position: fixed;
    bottom: 32px;
    right: 0;
    z-index: 999999999;
    width: 90vw;
    max-width: 360px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}



.chat-app .chat-popup {
    background: #fff;
    padding-bottom: 50px;
    box-shadow: 0px 5px 10px 6px #d9d9d9;
    border-radius: 12px 0 0 0;
}

#start-form {
    padding: 0px 30px 0;

}

#start-form h2 {
    font-size: 23px;
    line-height: 1.2;
    margin: 25px 0 5px 0;
}

#start-form p {
    font-size: 14px;
    line-height: 1.2;
}

.fields .field {
    width: 100%;
    margin-bottom: 12px;
}

.field input,
.field textarea {
    width: 100%;
    padding: 20px;
    font-size: 14px;
    font-weight: 400;
    border-radius: 0;
    border: 1px solid #D9D9D9;
}

.fields textarea {
    min-height: 120px;
}

.messages-screen {
    display: flex;
    flex-direction: column;
}

.messages-screen .message-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 20px;
}

.messages-screen .avatar {
    width: 42px;
    height: 42px;
    background-color: #D9D9D9;
    border-radius: 50%;
    position: relative;
}

.messages-screen .avatar img {
    position: absolute;
    width: 20px;
    height: 20px;
    left: 50%;
    object-fit: contain;
    top: 50%;
    transform: translate(-50%, -50%);
}

.messages-screen .admin-information {
    width: calc(100% - 52px);
}

.messages-screen .admin-information h4 {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.2;
    margin-top: 0;
    margin-bottom: 5px;
}

.messages-screen .admin-information p {
    font-size: 14px;
    margin-bottom: 0;
}

.messages-box li {
    display: flex;
    gap: 10px;
    font-size: 13px;
    line-height: 1.2;
    color: #1E1E1E;
    align-items: center;
}

.messages-box li .msg {
    width: calc(100% - 55px);
}

.messages-box {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-height: 350px;
    border: 1px solid #d9d9d9;
    padding: 10px;
    max-height: 400px;
    overflow: auto;
    position: relative;
}

.messages-box li.admin {
    flex-direction: row-reverse;
    text-align: right;
}

.messages-screen {
    padding: 0 10px;
}

.messages-box li .msg .timestamp {
    font-size: 10px;
    color: #C1B9B9;
    margin-top: 2px;
}

.send-msg {
    display: flex;
    justify-content: space-between;
}

.send-msg button {
    border-radius: 0;
    padding: 8px 20px;
    height: 42px;
    background: #1E1E1E;
    color: #fff;
    width: 100px;
    text-align: center;
    font-size: 16px;
    font-weight: 400;
}

.send-msg input {
    width: calc(100% - 100px);
    border-radius: 0;
    height: 42px;
    padding: 10px 20px;
}

.messages-box li .msg img {
    max-width: 150px;
}

.send-msg input#file-upload {
    width: 0;
    height: 0;
    visibility: hidden;
    padding: 0;
    overflow: hidden;
    opacity: 0;
}

.messages-screen .file-name {
    font-size: 10px;
    text-align: center;
    margin-top: 5px;
}



.chat-container {
    display: flex;
    flex-wrap: wrap;
}

.chat-container .chat-list {
    width: 450px;
    max-width: 450px;
    border-right: 1px solid #908C8C;
    padding-right: 10px;
}

.chat-container .chat-detail {
    width: calc(100% - 450px);
}

.chat-container img {
    max-width: 200px;
}


.chat-container .chat-list ul {
    list-style-type: none;
}

.chat-container .chat-list .session-info {
    display: flex;
    gap: 10px;
    font-size: 13px;
    line-height: 1.2;
    color: #1E1E1E;
    align-items: center;
    cursor: pointer;
    position: relative;
}

.chat-container .chat-list .session-info:before {
    content: "";
    width: 3px;
    height: 100%;
    position: absolute;
    left: -10px;
    top: 0;
    background: transparent;
}



.chat-container .chat-list .avatar {
    width: 42px;
    height: 42px;
    background-color: #D9D9D9;
    border-radius: 50%;
    position: relative;
}

.chat-container .chat-list .session-info .row {
    display: flex;
    flex-direction: row;
    margin-bottom: 3px;
}

.chat-container .chat-list .session-info .row:before,
.chat-container .chat-list .session-info .row:after {
    display: none;
}

.chat-container .chat-list .session-info .row .c-left {
    width: calc(100% - 50px);
}


.chat-container .chat-list .session-info .row .c-right {
    width: 50px;
    text-align: right;
}

.chat-container .chat-list .session-info .msg {
    width: calc(100% - 55px);
}

.chat-container .chat-list li {
    margin-bottom: 10px;
    padding: 5px;
}

.chat-container .chat-list li.active,
.chat-container .chat-list li:hover {
    background: #c3c8f7;
}

.chat-container .chat-list .unread-count {
    width: 15px;
    height: 15px;
    background: #E8500F;
    text-align: center;
    line-height: 15px;
    color: #fff;
    border-radius: 50%;
    display: block;
    font-size: 10px;
    margin-left: auto;
}


.filter-container {
    display: flex;
    position: relative;
    justify-content: space-between;
    margin-bottom: 30px;
}

.filter-container #status-filter {
    position: absolute;
    width: 250px;
    z-index: 2;
    background: #fff;
    right: 0;
    top: 33px;
    box-shadow: 0 4px 10px 4px #DFDFDF;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    padding: 10px;
}

.filter-container #status-filter label {
    display: flex;
    align-items: center;
    margin: 0;
    font-size: 12px;
    line-height: 31px;
    gap: 10px;
    cursor: pointer;
    
}

.filter-container #status-filter label input {
    margin: 0;
}

.filter-container input#contact-filter {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 4px;
    height: auto;
    padding: 10px 15px;
}

.filter-container .filter-icon {
    width: 50px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.chat-container .chat-list ul {
    max-height: calc(100vh - 280px);
    overflow: auto;
    padding-left: 10px;
}

.chat-container .chat-list ul::-webkit-scrollbar {
    width: 2px;
}

/* Track */
.chat-container .chat-list ul::-webkit-scrollbar-track {
    background: #f1f1f1;
}

/* Handle */
.chat-container .chat-list ul::-webkit-scrollbar-thumb {
    background: #888;
}

/* Handle on hover */
.chat-container .chat-list ul::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.messages-box::-webkit-scrollbar {
    width: 2px;
}

/* Track */
.messages-box::-webkit-scrollbar-track {
    background: #f1f1f1;
}

/* Handle */
.messages-box::-webkit-scrollbar-thumb {
    background: #888;
}

/* Handle on hover */
.messages-box::-webkit-scrollbar-thumb:hover {
    background: #555;
}


.chat-container .chat-detail .messages-screen .messages-box {
    min-height: calc(100vh - 320px);
    background: #F5F5F5;
}

.customer-detail .chat-list {
    
    border-right: 0;
    padding: 10px;
}

.messages-screen .customer-detail {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.error-message.active {
    display: block !important;
}

.customer-detail .actions span{
    cursor: pointer;
    display: block;
    padding-right: 5px;
}

.customer-detail .actions {
    display: flex;
    align-items: center;
    position: relative;
}

.customer-detail .actions div#status-popup {
    position: absolute;
    top: 0;
    width: 300px;
    right: 0;
    z-index: 2;
    background: #fff;
    display: flex;
    flex-direction: column;
    top: 100%;
    border: 1px solid #ddd;
    padding: 20px;
    font-size: 12px;
    text-align: right;
}

.customer-detail .actions div#status-popup label {
    cursor: pointer;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
    flex-direction: row-reverse;
}

.filter-container #status-filter label:before,
.customer-detail .actions div#status-popup label:before{
    content: "";
    width: 15px;
    height: 10px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: yellow;
    left: -5px;
}

.filter-container #status-filter label,
.customer-detail .actions div#status-popup label{
    position: relative;
    padding-left: 15px;
}

.chat-container .chat-list .session-info.purchased-deposited:before,
.customer-detail .actions div#status-popup label.purchased-deposited:before ,
.filter-container #status-filter label.purchased-deposited:before{
    background: #7AA1ED;
}
.chat-container .chat-list .session-info.consulted:before,
.customer-detail .actions div#status-popup label.consulted:before ,
.filter-container #status-filter label.consulted:before{
    background: #1E9B2A;
}
.chat-container .chat-list .session-info.shipped:before,
.customer-detail .actions div#status-popup label.shipped:before ,
.filter-container #status-filter label.shipped:before{
    background: #ACE74D;
}
.chat-container .chat-list .session-info.not-purchased:before,
.customer-detail .actions div#status-popup label.not-purchased:before ,
.filter-container #status-filter label.not-purchased:before{
    background: #4DAFE7;
}
.chat-container .chat-list .session-info.unread:before,
.customer-detail .actions div#status-popup label.unread:before ,
.filter-container #status-filter label.unread:before{
    background: #B0EAE6;
}

.chat-container .chat-list .session-info.purchased-not-deposited:before,
.customer-detail .actions div#status-popup label.purchased-not-deposited:before ,
.filter-container #status-filter label.purchased-not-deposited:before {
    background: #CD6FEE;
}

.chat-container .chat-list .session-info.unknown-status:before,
.chat-container .chat-list .session-info.new-ticket:before {
    background: yellow;
}


body.admin-chat .chat-app button.toggle-open {
    display: none;
}

.chat-popup .messages-box li.admin {
    flex-direction: row;
    text-align: left;
}

.chat-popup li.user {
    flex-direction: row-reverse;
    text-align: right;
}

.send-msg label[for=file-upload] {
    width: 40px;
}

span.fast-chat, span.fast-chat svg {
    width: 35px;
    height: auto;
}

span.fast-chat {
    display: flex;
    align-items: center;
    margin: 0 5px;
    cursor: pointer;
}

.fast-chat-list,
.fast-chat-modal{
    position: absolute;
    bottom: 50px;
    width: 300px;
    height: 250px;
    background: #fff;
    /* border: 1px solid; */
    border-radius: 12px;
    box-shadow: 0 0 8px 0 #3a3a3a69;
    padding: 10px;
}

.send-msg {
    position: relative;
}

.fast-chat-list .col-head {
    display: flex;
    justify-content: space-between;
    padding: 5px;
}

.fast-chat-list .col-head .txt {
    font-weight: bold;
    font-size: 16px;
    line-height: 22px;
}

.fast-chat-list .col-head .add-msg {
    font-size: 14px;
    line-height: 22px;
    cursor: pointer;
}

.fast-chat-list .col-body {
    height: 210px;
    overflow: auto;
    padding-right: 5px;
}

.fast-chat-list .col-body .guide-box {
    margin-top: 10px;
}

.fast-chat-list .col-body .guide-icon span {
    display: inline-block;
    padding: 2px 5px;
    background: #ddd;
    border-radius: 8px;
    font-size: 12px;
}

.fast-chat-list .col-body  .guide-text {
    font-size: 12px;
    margin-top: 4px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* number of lines to show */
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.fast-chat-modal .inner-box {
    display: flex;
    flex-wrap: wrap;
}

.fast-chat-modal .inner-box input {
    width: 100%;
    border: 1px solid #ddd;
    margin-bottom: 10px;
    padding: 5px 10px;
    font-size: 12px;
    line-height: 12px;
    height: auto;
}

.fast-chat-modal .inner-box span {
    font-size: 12px;
    display: block;
}

.fast-chat-modal .inner-box label {
    width: 100%;
}

.fast-chat-modal .inner-box label textarea {
    min-height: 70px;
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 0
}

.fast-chat-modal .inner-box .actions {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    gap: 10px;
}

.fast-chat-modal .inner-box .actions button {
    width: 50%;
    height: auto;
    border: 0;
    font-size: 14px;
}

.fast-chat-list .col-body ul {
    list-style-type: none;
    padding: 0;
    margin-top: 10px;
}

.fast-chat-list .col-body ul .fast-chat-item {
    display: flex;
    padding: 5px;
    border-radius: 5px
}

.fast-chat-list .col-body ul .fast-chat-item:hover {
    background: #e3eef9;
}

.msg-actions {
    width: 60px;
    text-align: right;
}

.msg-actions button {
    width: auto;
    height: auto;
    background: transparent;
    border: 0;
    padding: 0;
}

.fast-chat-item .msg-short {
    width: calc(100% - 60px);
    cursor: pointer;
}

.fast-chat-item .msg-short span {
    display: inline-block;
    padding: 2px 5px;
    background: #ddd;
    border-radius: 8px;
    font-size: 12px;
}

.fast-chat-item .msg-short p {
    font-size: 12px;
    margin-top: 4px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* number of lines to show */
    line-clamp: 2;
    -webkit-box-orient: vertical;
}
/* width */
.fast-chat-list .col-body::-webkit-scrollbar {
  width: 2px;
}

/* Track */
.fast-chat-list .col-body::-webkit-scrollbar-track {
  background: #f1f1f1;
}

/* Handle */
.fast-chat-list .col-body::-webkit-scrollbar-thumb {
  background: #888;
}

/* Handle on hover */
.fast-chat-list .col-body::-webkit-scrollbar-thumb:hover {
  background: #555;
}
@media screen and (max-width: 1025px) {
    .chat-container .chat-list {
        width: 300px;
    }
    
    .chat-container .chat-detail {
        width: calc(100% - 300px);
    }
}
@media screen and (max-width: 767px) {
    .chat-container .chat-list ul {
        max-height: calc(100vh - 180px);
    }
    
    .send-msg label[for=file-upload], .send-msg label[for=file-upload] svg {
        width: 25px;
        height: auto;
    }
    
    span.fast-chat, span.fast-chat svg {
        width: 25px;
    }
    
    .send-msg label[for=file-upload] {
        display: inline-flex;
        align-items: center;
    }
    
    .send-msg button {
        border: 0;
        font-size: 14px;
        padding: 8px 10px;
    }
    
    .fast-chat-list, .fast-chat-modal {
        max-width: 100%;
    }
    .chat-container .chat-list ul {
        max-height: calc(100vh - 180px);
    }
    .chat-container .chat-list {
        width: 100%;
        height: 90vh;
    }
    
    .chat-container .chat-detail {
        width: 100%;
    }
    .back-to-list {
        display: block !important;
    }
    
    .messages-screen .customer-detail .chat-list {
        height: auto;
    }
    .chat-container .chat-detail {
        position: absolute;
        z-index: 2;
        left: 0;
        top: 0;
        background: #fff;
        min-height: 90vh;
        transform: translateX(150%);
        transition: transform .5s;
    }
    .chat-container .chat-detail.active {
        transform: translateX(0%);
    }
    .chat-container {
        position: relative;
    }
    .chat-container .chat-detail .messages-screen .messages-box {
        min-height: calc(100vh - 250px);
    }
}