body.fleetbase-console .chat-tray-panel-container,
body.fleetbase-console .chat-tray-panel-container.ember-basic-dropdown-content {
    box-shadow:
        0 4px 6px -1px rgb(0 0 0 / 0.1),
        0 2px 4px -2px rgb(0 0 0 / 0.1);
    margin-top: 0.75rem;
    background-color: #f9fafb;
    border: 1px #e5e7eb solid;
    border-radius: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: 400px;
    @apply space-y-2;
}

body[data-theme='dark'] .chat-tray-panel-container,
body[data-theme='dark'] .chat-tray-panel-container.ember-basic-dropdown-content {
    background-color: #111827;
    border-color: #374151;
}

.chat-container {
    position: fixed;
    bottom: 0;
    right: 0;
    z-index: 800;
    margin-right: 1rem;
}

.chat-container.is-mobile {
    bottom: 55px;
}

.chat-window-container {
    position: absolute;
    bottom: 0;
    right: 0;
    margin-left: calc(360px + 2rem);
    margin-bottom: 1rem;
    z-index: 800;
    display: flex;
    flex-direction: column;
    width: 360px;
    height: 483px;
    min-height: 483px;
    max-height: 553px;
    box-shadow:
        0 4px 6px -1px rgb(0 0 0 / 0.1),
        0 2px 4px -2px rgb(0 0 0 / 0.1);
    border: 1px #d1d5db solid;
    border-radius: 1rem;
    background-color: #f9fafb;
    transition: transform 0.5s ease;
}

.chat-window-container.has-attachments {
    min-height: 513px;
}

body[data-theme='dark'] .chat-window-container {
    background-color: #1f2937;
    border-color: #374151;
}

.chat-window-container a,
.chat-window-container button {
    cursor: default !important;
}

.chat-window-input-container {
    display: flex;
    flex-direction: column;
    background-color: #f9fafb;
    border-bottom-left-radius: 1rem;
    border-bottom-right-radius: 1rem;
}

body[data-theme='dark'] .chat-window-input-container {
    background-color: #1f2937;
}

.chat-window-input-box {
    flex: 1;
    width: 100%;
    background-color: #f9fafb;
}

body[data-theme='dark'] .chat-window-input-box {
    background-color: #1f2937;
}

.chat-window-input {
    height: 80px;
    max-height: 80px;
    min-height: 80px;
    flex: 1;
    padding: 0.6rem;
    font-size: 0.75rem;
    background-color: #f9fafb;
    width: 100%;
    border: 0;
    outline: none;
    box-shadow: none;
}

body[data-theme='dark'] .chat-window-input {
    background-color: #1f2937;
    color: #f9fafb;
}

.chat-window-input:focus {
    border: 0;
    outline: none;
    box-shadow: none;
}

.chat-window-submit-container {
    flex: 1;
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
    padding: 0.5rem;
}

.chat-window-submit-container .btn-wrapper {
    border: 0;
    outline: none;
    box-shadow: none;
}

.chat-window-attachment-input a.btn.btn-xs,
.chat-window-attachment-input a,
.chat-window-submit-container button.btn.btn-xs,
.chat-window-submit-container button {
    background-color: #64748b;
    border: 1px solid #64748b;
    color: #f9fafb;
}

body[data-theme='dark'] .chat-window-attachment-input a.btn.btn-xs,
body[data-theme='dark'] .chat-window-attachment-input a,
body[data-theme='dark'] .chat-window-submit-container button.btn.btn-xs,
body[data-theme='dark'] .chat-window-submit-container button {
    background-color: #374151;
    color: #f3f4f6;
    border-color: #111827;
}

.chat-window-attachment-input a.btn.btn-xs:hover,
.chat-window-attachment-input a:hover,
.chat-window-submit-container button.btn.btn-xs:hover,
.chat-window-submit-container button:hover {
    background-color: #64748b;
    border: 1px solid #64748b;
    color: #f9fafb;
    opacity: 0.5;
}

body[data-theme='dark'] .chat-window-attachment-input a.btn.btn-xs:hover,
body[data-theme='dark'] .chat-window-attachment-input a:hover,
body[data-theme='dark'] .chat-window-submit-container button.btn.btn-xs:hover,
body[data-theme='dark'] .chat-window-submit-container button:hover {
    background-color: #374151;
    color: #f3f4f6;
    border-color: #111827;
    opacity: 0.5;
}

.chat-window-controls-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    border-top-left-radius: 1rem;
    border-top-right-radius: 1rem;
    background-color: #f9fafb;
    padding: 0.5rem 0.5rem;
}

body[data-theme='dark'] .chat-window-controls-container {
    background-color: #1f2937;
}

.chat-window-controls-container .chat-window-name {
    display: flex;
    align-items: center;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 500;
    color: #000;
    flex: 1;
}

body[data-theme='dark'] .chat-window-controls-container,
body[data-theme='dark'] .chat-window-controls-container .chat-window-name {
    color: #fff;
}

.chat-window-controls-container .chat-window-controls {
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
    flex: 1;
}

.chat-window-controls-container .chat-window-controls .chat-window-button {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #e5e7eb;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    height: 24px;
    width: 24px;
    text-align: center;
    font-size: 0.75rem;
    margin-left: 0.25rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    cursor: default;
}

.chat-window-controls-container .chat-window-controls .chat-window-button svg {
    font-size: 0.5rem;
}

.chat-window-controls-container .chat-window-controls .chat-window-button:hover {
    opacity: 0.5;
}

.chat-window-controls-container .chat-window-controls .chat-window-close-button {
    background-color: #b91c1c;
    border-color: #dc2626;
    color: #fee2e2;
}

.chat-window-participants-container {
    padding: 0rem 0.5rem 0.5rem 0.5rem;
    background-color: #f9fafb;
    display: flex;
}

body[data-theme='dark'] .chat-window-participants-container {
    background-color: #1f2937;
}

.chat-window-participants-container > .chat-window-participant-name {
    border: 1px #2563eb solid;
    color: #e5e7eb;
    font-size: 0.65rem;
    width: 70px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border-radius: 0.5rem;
    padding: 0.25rem;
    background-color: #3b82f6;
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}

.chat-window-participants-container .chat-window-participant-bubble-container {
    width: 35px;
    display: flex;
    position: relative;
}

.chat-window-participants-container .chat-window-participant-bubble-container > .chat-window-participant-online-status,
.chat-window-participants-container .chat-window-participant-bubble-container > .chat-window-remove-participant {
    opacity: 0;
    position: absolute;
    top: 0;
    right: 0;
    margin-right: 5px;
    margin-top: -2px;
    border-radius: 100%;
    background-color: #ef4444;
    color: #fff;
    height: 14px;
    width: 14px;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 1px #dc2626 solid;
    box-shadow:
        0 10px 15px -3px rgb(0 0 0 / 0.1),
        0 4px 6px -4px rgb(0 0 0 / 0.1);
}

.chat-window-participants-container .chat-window-participant-bubble-container > .chat-window-remove-participant:hover {
    opacity: 0.5;
}

.chat-window-participants-container .chat-window-participant-bubble-container:hover > .chat-window-remove-participant {
    opacity: 1;
}

.chat-window-participants-container .chat-window-participant-bubble-container > .chat-window-participant-online-status {
    opacity: 0.8;
    height: 10px;
    width: 10px;
    left: 0;
    right: unset;
    margin-right: unset;
    margin-left: -2px;
    margin-top: -1px;
    background-color: #eab308;
    border: 1px #facc15 solid;
}

.chat-window-participants-container .chat-window-participant-bubble-container > .chat-window-participant-online-status.is-online {
    background-color: #16a34a;
    border: 1px #22c55e solid;
}

.chat-window-participants-container .chat-window-participant-bubble {
    width: 24px;
    height: 24px;
    border-radius: 100%;
    border: 1px #000 solid;
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}

.chat-window-messages-container {
    height: 230px;
    max-height: 230px;
    min-height: 230px;
    width: 100%;
    background-color: #fff;
    border-bottom: 1px #e5e7eb solid;
    border-top: 1px #e5e7eb solid;
    overflow-y: scroll;
}

body[data-theme='dark'] .chat-window-messages-container {
    border-color: #374151;
    background-color: #323b49;
    box-shadow: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);
}

.chat-window-messages {
    height: 100%;
    width: 100%;
    background-color: #fff;
    padding: 0.25rem 0;
}

body[data-theme='dark'] .chat-window-messages {
    background-color: #323b49;
    box-shadow: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);
}

.chat-window-pending-attachments-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    align-self: start;
    padding-top: 0.5rem;
    width: 100%;
    height: 30px;
}

.chat-window-pending-attachment {
    display: flex;
    flex-direction: row;
    align-items: center;
    align-self: start;
    border-radius: 0.25rem;
    font-size: 0.7rem;
    background-color: #f9fafb;
    border: 1px #fff solid;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: #0f172a;
    position: relative;
    padding: 0.1rem 0.25rem;
    opacity: 0.9;
    margin-right: 0.15rem;
    max-height: 26px;
}

body[data-theme='dark'] .chat-window-pending-attachment {
    background-color: #374151;
    border-color: #1f2937;
    color: #f3f4f6;
}

.chat-window-pending-attachment > .chat-window-pending-attachment-preview {
    display: flex;
    align-items: center;
}

.chat-window-pending-attachment > .chat-window-pending-attachment-preview > .x-fleetbase-file-preview > .file-icon svg {
    font-size: 0.75rem;
}

.chat-window-pending-attachment > .chat-window-pending-attachment-preview > .flb--img.x-fleetbase-file-preview {
    height: 20px;
    border-radius: 0.05rem;
}

.chat-window-pending-attachment > .chat-window-pending-attachment-name {
    font-size: 0.55rem;
    display: flex;
    align-items: center;
    margin-left: 0.25rem;
    height: 20px;
    max-height: 20px;
    width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-window-pending-attachment > .chat-window-pending-attachment-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    font-size: 0.65rem;
}

.chat-log-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    padding-top: 0.7rem;
    padding-bottom: 0.15rem;
}

.chat-log-container .chat-log-content-bubble-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    width: 100%;
    padding: 0 0.35rem;
}

.chat-log-container .chat-log-content-bubble {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    border-radius: 0.25rem;
    padding: 0.25rem 0.5rem;
    font-size: 0.7rem;
    background-color: #f9fafb;
    width: 100%;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: #0f172a;
    text-align: center;
}

body[data-theme='dark'] .chat-log-container .chat-log-content-bubble {
    background-color: #374151;
    color: #f9fafb;
    border: 1px solid rgb(31 41 55 / 70%);
}

.chat-log-container .chat-log-created-at {
    font-size: 0.5rem;
    margin-top: 0.2rem;
    color: #475569;
}

body[data-theme='dark'] .chat-log-container .chat-log-created-at {
    color: #f9fafb;
}

.chat-message-container {
    display: flex;
    flex-direction: row;
    padding: 0.7rem 0;
}

.chat-message-container .chat-message-content-bubble-container {
    flex: 1;
    width: 100%;
    padding: 0 0.35rem;
}

.chat-message-container .chat-message-content-bubble-container.has-attachments .chat-message-content-bubble {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container {
    display: flex;
    flex-direction: row;
    border-top-left-radius: 0.25rem;
    border-top-right-radius: 0.25rem;
    padding: 0.5rem 0.5rem 0rem 0.5rem;
    background-color: rgb(229 231 235 / 65%);
    width: 100%;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

body[data-theme='dark'] .chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container {
    background-color: #1f2937;
    color: #f9fafb;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-container {
    margin-right: 0.15rem;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-image-preview {
    height: 45px;
    width: 50px;
    border-radius: 0.25rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    border: 1px #fff solid;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-file-preview {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    align-self: start;
    background-color: #fff;
    height: 45px;
    width: 50px;
    padding: 0.15rem;
    border-radius: 0.25rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    border: 1px #fff solid;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-file-preview:hover,
.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-file-preview:focus {
    border-color: #3b82f6;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-attachments-container .chat-attachment-file-preview .chat-attachment-file-preview-filename {
    font-size: 0.45rem;
    color: #000;
    width: 50px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-message-container .chat-message-content-bubble-container .chat-message-content-bubble {
    border-radius: 0.25rem;
    padding: 0.5rem 0.5rem 1rem 0.5rem;
    font-size: 0.7rem;
    background-color: rgb(229 231 235 / 65%);
    width: 100%;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: #0f172a;
}

body[data-theme='dark'] .chat-message-container .chat-message-content-bubble-container .chat-message-content-bubble {
    background-color: #1f2937;
    color: #f9fafb;
}

.chat-message-container .chat-message-created-at {
    font-size: 0.5rem;
    color: #475569;
}

body[data-theme='dark'] .chat-message-container .chat-message-created-at {
    color: #f9fafb;
}

.chat-message-container .chat-message-receipts {
    display: flex;
    flex: 1;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
}

.chat-message-container .chat-message-receipts > div:not(:last-child)::after {
    content: ',';
    margin-right: 5px;
    font-size: 0.5rem;
    color: #475569;
}

.chat-message-container .chat-message-receipts .chat-message-receipt-container {
    display: inline-flex;
    align-self: start;
    font-size: 0.5rem;
    color: #475569;
}

.chat-message-container .chat-message-receipts .chat-message-receipt {
    font-size: 0.5rem;
    color: #475569;
}

.chat-message-container .chat-message-receipts .chat-message-receipt svg {
    font-size: 0.5rem;
}

body[data-theme='dark'] .chat-message-container .chat-message-receipts > div:not(:last-child)::after,
body[data-theme='dark'] .chat-message-container .chat-message-receipts .chat-message-receipt-container,
body[data-theme='dark'] .chat-message-container .chat-message-receipts .chat-message-receipt {
    color: #f9fafb;
}

.chat-message-container .chat-message-sender-bubble {
    width: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.chat-message-container .chat-message-sender-bubble > img {
    width: 27px;
    height: 27px;
    border-radius: 100%;
    border: 1px #f3f4f6 solid;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

body[data-theme='dark'] .chat-message-container .chat-message-sender-bubble > img {
    border-color: #1f2937;
}

.chat-message-container .chat-message-sender-bubble > .chat-message-sender-name {
    margin-top: 0.15rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 50px;
    max-width: 50px;
    max-width: 60px;
    font-size: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #475569;
}

body[data-theme='dark'] .chat-message-container .chat-message-sender-bubble > .chat-message-sender-name {
    color: #fff;
}

.chat-window-attachments-container {
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100%;
    padding: 0.5rem;
}

.chat-window-attachment-input {
    display: flex;
    flex-direction: row;
}

.chat-tray-channel-preview:hover {
    opacity: 0.5;
}

.chat-tray-channel-preview .chat-tray-channel-preview-last-message {
    display: flex;
    flex-direction: column;
    width: 285px;
    max-width: 285px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: left;
}

.chat-tray-channel-preview .chat-tray-channel-preview-last-message .chat-tray-channel-preview-last-message-attachments {
    display: flex;
    align-items: center;
    align-self: start;
    margin-top: 0.15rem;
}

.chat-tray-icon .chat-tray-unread-notifications-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 16px;
    height: 16px;
    background: #dc2626;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    font-size: 10px;
    font-weight: bold;
}

.chat-tray-icon .chat-tray-unread-notifications-badge:hover {
    background-color: #b91c1c;
    cursor: pointer;
}

.chat-tray {
    position: relative;
    display: flex;
    align-items: center;
}

.chat-tray-panel-trigger {
    border: 0;
    background: transparent;
    padding: 0;
}

.chat-inbox-overlay,
.chat-compose-overlay {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    min-height: 100vh;
    max-height: 100vh;
    pointer-events: none;
}

.chat-inbox-overlay {
    z-index: 860;
}

.chat-compose-overlay {
    z-index: 850;
}

.chat-inbox-overlay > .next-content-overlay-panel-container,
.chat-compose-overlay > .next-content-overlay-panel-container {
    position: fixed;
    top: 0;
    bottom: 0;
    height: 100vh;
    min-height: 100vh;
    max-height: 100vh;
    pointer-events: auto;
}

.chat-inbox-overlay.next-content-overlay-pos-right > .next-content-overlay-panel-container,
.chat-compose-overlay.next-content-overlay-pos-right > .next-content-overlay-panel-container {
    right: 0;
    transform: translateX(100%);
}

.chat-inbox-overlay.is-open > .next-content-overlay-panel-container,
.chat-compose-overlay.is-open > .next-content-overlay-panel-container {
    transform: translateX(0);
}

.chat-inbox-overlay > .next-content-overlay-panel-container > .next-content-overlay-panel,
.chat-compose-overlay > .next-content-overlay-panel-container > .next-content-overlay-panel {
    height: 100vh;
    min-height: 100vh;
    max-height: 100vh;
    overflow: hidden;
}

.chat-inbox-overlay .next-content-overlay-panel,
.chat-compose-overlay .next-content-overlay-panel {
    border-left: 1px solid #e5e7eb;
}

.chat-compose-overlay.has-inbox.next-content-overlay-pos-right > .next-content-overlay-panel-container {
    right: 420px;
    transform: translateX(420px);
}

.chat-compose-overlay.has-inbox.is-open > .next-content-overlay-panel-container {
    transform: translateX(0);
}

.chat-inbox-panel,
.chat-compose-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 100%;
    max-height: 100%;
    background-color: #f9fafb;
    color: #111827;
}

.chat-inbox-panel-header,
.chat-compose-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 64px;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #e5e7eb;
    background-color: #fff;
}

.chat-inbox-panel-title,
.chat-compose-panel-title {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.chat-inbox-panel-title h2,
.chat-compose-panel-title h2 {
    font-size: 1rem;
    line-height: 1.35;
    font-weight: 700;
    margin: 0;
    color: #111827;
}

.chat-inbox-panel-title span,
.chat-compose-panel-title span {
    margin-top: 0.1rem;
    font-size: 0.75rem;
    color: #6b7280;
}

.chat-inbox-panel-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.chat-inbox-panel-actions .btn {
    min-height: 2rem;
    height: 2rem;
}

.chat-inbox-panel-actions .btn-icon-wrapper {
    display: inline-flex;
    align-items: center;
}

.chat-inbox-icon-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
    color: #4b5563;
    background-color: #f9fafb;
}

.chat-inbox-icon-button:hover,
.chat-inbox-row-action:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.chat-inbox-search {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.85rem 0.65rem;
    padding: 0.5rem 0.65rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    background-color: #fff;
    color: #6b7280;
}

.chat-inbox-search input {
    width: 100%;
    border: 0;
    padding: 0;
    font-size: 0.875rem;
    color: #111827;
    background-color: transparent;
    box-shadow: none;
}

.chat-inbox-search input:focus {
    outline: 0;
    box-shadow: none;
}

.chat-inbox-list,
.chat-compose-contact-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 0 0.65rem 0.85rem;
}

.chat-inbox-conversation-row {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid #e5e7eb;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(249, 250, 251, 0.98)),
        #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    transition:
        border-color 0.15s ease,
        background-color 0.15s ease,
        box-shadow 0.15s ease;
}

.chat-inbox-conversation-row:hover,
.chat-inbox-conversation-row.is-open {
    border-color: #bad5f5;
    background:
        linear-gradient(135deg, #fff, #eef6ff),
        #f6fbff;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.chat-inbox-conversation-row.has-unread {
    border-color: #9cc4f1;
    background:
        linear-gradient(135deg, #f8fbff, #eaf4ff),
        #f0f7ff;
}

.chat-inbox-conversation-row.has-unread::before {
    content: '';
    position: absolute;
    top: 0.6rem;
    bottom: 0.6rem;
    left: 0;
    width: 3px;
    border-radius: 0 9999px 9999px 0;
    background-color: #3485e2;
}

.chat-inbox-conversation-main {
    display: grid;
    grid-template-columns: 3.15rem minmax(0, 1fr) auto;
    align-items: flex-start;
    gap: 0.85rem;
    width: 100%;
    min-width: 0;
    border: 0;
    border-radius: 0.5rem;
    padding: 0.8rem 0.7rem 0.8rem 0.85rem;
    background-color: transparent;
    text-align: left;
}

.chat-inbox-conversation-avatars {
    position: relative;
    width: 3.15rem;
    height: 2.55rem;
    flex-shrink: 0;
    margin-top: 0.05rem;
}

.chat-inbox-conversation-avatar {
    position: absolute;
    width: 2.15rem;
    height: 2.15rem;
    border: 2px solid #fff;
    border-radius: 9999px;
    object-fit: cover;
    background-color: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
}

.chat-inbox-conversation-avatar:nth-child(1) {
    left: 0;
    z-index: 3;
}

.chat-inbox-conversation-avatar:nth-child(2) {
    left: 0.78rem;
    z-index: 2;
}

.chat-inbox-conversation-avatar:nth-child(3) {
    left: 1.56rem;
    z-index: 1;
}

.chat-inbox-conversation-avatar-count,
.chat-inbox-conversation-avatar-empty {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: #16539a;
    background-color: #e6f0fb;
}

.chat-inbox-conversation-avatar-count {
    left: 1.56rem;
    z-index: 4;
}

.chat-inbox-conversation-avatar-empty {
    left: 0.45rem;
    font-size: 0.8rem;
}

.chat-inbox-conversation-body {
    min-width: 0;
    padding-right: 0.15rem;
}

.chat-inbox-conversation-heading,
.chat-inbox-conversation-preview,
.chat-inbox-conversation-meta {
    display: flex;
    align-items: center;
    min-width: 0;
}

.chat-inbox-conversation-heading {
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
}

.chat-inbox-conversation-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.875rem;
    font-weight: 700;
    color: #111827;
}

.chat-inbox-conversation-row.has-unread .chat-inbox-conversation-title {
    color: #0f4f94;
}

.chat-inbox-conversation-time {
    flex-shrink: 0;
    margin-top: 0.05rem;
    font-size: 0.68rem;
    color: #6b7280;
}

.chat-inbox-conversation-preview {
    gap: 0.3rem;
    margin-top: 0.45rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.45rem;
    padding: 0.35rem 0.45rem;
    font-size: 0.78rem;
    color: #374151;
    background-color: rgba(249, 250, 251, 0.92);
    line-height: 1.35;
}

.chat-inbox-conversation-preview-icon {
    flex-shrink: 0;
    margin-top: 0.1rem;
    font-size: 0.68rem;
    color: #9ca3af;
}

.chat-inbox-conversation-preview-text,
.chat-inbox-conversation-sender {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-inbox-conversation-sender {
    flex-shrink: 0;
    font-weight: 600;
    color: #111827;
}

.chat-inbox-conversation-row.has-unread .chat-inbox-conversation-preview,
.chat-inbox-conversation-row.has-unread .chat-inbox-conversation-sender {
    font-weight: 600;
    color: #1f2937;
}

.chat-inbox-conversation-meta {
    gap: 0.35rem;
    margin-top: 0.5rem;
    font-size: 0.68rem;
    color: #6b7280;
}

.chat-inbox-conversation-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    max-width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 9999px;
    padding: 0.12rem 0.4rem;
    color: #4b5563;
    background-color: #f9fafb;
    line-height: 1.2;
}

.chat-inbox-conversation-side,
.chat-inbox-conversation-actions {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.chat-inbox-conversation-side {
    padding-top: 0.05rem;
}

.chat-inbox-unread-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.3rem;
    height: 1.3rem;
    padding: 0 0.35rem;
    border-radius: 9999px;
    font-size: 0.68rem;
    font-weight: 700;
    color: #fff;
    background-color: #3485e2;
    box-shadow: 0 0 0 2px #fff;
}

.chat-inbox-row-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    margin-top: 0.8rem;
    margin-right: 0.35rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    color: #9ca3af;
    background-color: #fff;
    opacity: 0;
    transition:
        opacity 0.15s ease,
        color 0.15s ease,
        background-color 0.15s ease;
}

.chat-inbox-conversation-row:hover .chat-inbox-row-action,
.chat-inbox-conversation-row:focus-within .chat-inbox-row-action {
    opacity: 1;
}

.chat-inbox-row-action:hover,
.chat-inbox-row-action:focus {
    border-color: #fecaca;
    color: #b91c1c;
    background-color: #fef2f2;
}

.chat-inbox-empty-state {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 15rem;
    padding: 2rem 1.25rem;
    text-align: center;
    color: #6b7280;
}

.chat-inbox-empty-state h3 {
    margin: 0.75rem 0 0.25rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: #111827;
}

.chat-inbox-empty-state p {
    margin: 0 0 1rem;
    font-size: 0.8rem;
}

.chat-inbox-empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.5rem;
    color: #3485e2;
    background-color: #e6f0fb;
}

.chat-compose-form {
    padding: 0.85rem 0.65rem;
    border-bottom: 1px solid #e5e7eb;
    background-color: #fff;
}

.chat-compose-form .chat-inbox-search {
    margin: 0;
}

.chat-compose-label {
    display: block;
    margin: 0 0 0.35rem;
    font-size: 0.72rem;
    font-weight: 700;
    color: #374151;
}

.chat-compose-label:not(:first-child) {
    margin-top: 0.85rem;
}

.chat-compose-form > input {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    padding: 0.55rem 0.65rem;
    font-size: 0.875rem;
    color: #111827;
    background-color: #fff;
}

.chat-compose-form > input:focus {
    border-color: #3485e2;
    outline: 0;
    box-shadow: 0 0 0 1px #3485e2;
}

.chat-compose-selected-users {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.65rem;
}

.chat-compose-selected-user {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    gap: 0.35rem;
    border: 1px solid #bad5f5;
    border-radius: 9999px;
    padding: 0.2rem 0.35rem 0.2rem 0.2rem;
    font-size: 0.75rem;
    color: #16539a;
    background-color: #e6f0fb;
}

.chat-compose-selected-user img {
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 9999px;
}

.chat-compose-selected-user span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-compose-selected-user button {
    display: inline-flex;
    color: #16539a;
}

.chat-compose-contact-row {
    display: grid;
    grid-template-columns: 2.35rem minmax(0, 1fr) 1.75rem;
    align-items: center;
    gap: 0.7rem;
    width: 100%;
    border: 0;
    border-radius: 0.5rem;
    padding: 0.65rem;
    background-color: transparent;
    text-align: left;
}

.chat-compose-contact-row:hover,
.chat-compose-contact-row.is-selected {
    background-color: #eef6ff;
}

.chat-compose-contact-avatar-wrap {
    position: relative;
}

.chat-compose-contact-avatar {
    width: 2.15rem;
    height: 2.15rem;
    border-radius: 9999px;
    object-fit: cover;
}

.chat-compose-contact-presence {
    position: absolute;
    right: -1px;
    bottom: -1px;
    width: 0.7rem;
    height: 0.7rem;
    border: 2px solid #f9fafb;
    border-radius: 9999px;
    background-color: #f59e0b;
}

.chat-compose-contact-presence.is-online {
    background-color: #16a34a;
}

.chat-compose-contact-body {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.chat-compose-contact-name,
.chat-compose-contact-subtitle {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-compose-contact-name {
    font-size: 0.86rem;
    font-weight: 700;
    color: #111827;
}

.chat-compose-contact-subtitle {
    margin-top: 0.1rem;
    font-size: 0.75rem;
    color: #6b7280;
}

.chat-compose-contact-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.65rem;
    height: 1.65rem;
    border-radius: 0.5rem;
    color: #3485e2;
    background-color: #e6f0fb;
}

.chat-compose-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 0.85rem 1rem;
    border-top: 1px solid #e5e7eb;
    background-color: #fff;
}

body[data-theme='dark'] .chat-inbox-overlay .next-content-overlay-panel,
body[data-theme='dark'] .chat-compose-overlay .next-content-overlay-panel {
    border-left-color: #374151;
}

body[data-theme='dark'] .chat-inbox-panel,
body[data-theme='dark'] .chat-compose-panel {
    background-color: #111827;
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-panel-header,
body[data-theme='dark'] .chat-compose-panel-header,
body[data-theme='dark'] .chat-compose-form,
body[data-theme='dark'] .chat-compose-footer {
    border-color: #374151;
    background-color: #1f2937;
}

body[data-theme='dark'] .chat-inbox-panel-title h2,
body[data-theme='dark'] .chat-compose-panel-title h2,
body[data-theme='dark'] .chat-inbox-conversation-title,
body[data-theme='dark'] .chat-inbox-empty-state h3,
body[data-theme='dark'] .chat-compose-contact-name,
body[data-theme='dark'] .chat-compose-label {
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-panel-title span,
body[data-theme='dark'] .chat-compose-panel-title span,
body[data-theme='dark'] .chat-inbox-conversation-time,
body[data-theme='dark'] .chat-inbox-conversation-preview,
body[data-theme='dark'] .chat-inbox-conversation-meta,
body[data-theme='dark'] .chat-inbox-empty-state,
body[data-theme='dark'] .chat-compose-contact-subtitle {
    color: #d1d5db;
}

body[data-theme='dark'] .chat-inbox-icon-button,
body[data-theme='dark'] .chat-inbox-search,
body[data-theme='dark'] .chat-compose-form > input {
    border-color: #374151;
    background-color: #111827;
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-search input {
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-icon-button:hover,
body[data-theme='dark'] .chat-inbox-conversation-row:hover,
body[data-theme='dark'] .chat-inbox-conversation-row.is-open,
body[data-theme='dark'] .chat-compose-contact-row:hover,
body[data-theme='dark'] .chat-compose-contact-row.is-selected {
    background-color: #1f2937;
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-conversation-row {
    border-color: #374151;
    background:
        linear-gradient(135deg, rgba(17, 24, 39, 0.98), rgba(31, 41, 55, 0.82)),
        #111827;
    box-shadow: none;
}

body[data-theme='dark'] .chat-inbox-conversation-row:hover,
body[data-theme='dark'] .chat-inbox-conversation-row.is-open {
    border-color: #2563eb;
    background:
        linear-gradient(135deg, #111827, #172235),
        #1f2937;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.24);
}

body[data-theme='dark'] .chat-inbox-conversation-row.has-unread {
    border-color: #2563eb;
    background:
        linear-gradient(135deg, #102033, #0f2740),
        #102033;
}

body[data-theme='dark'] .chat-inbox-conversation-row.has-unread .chat-inbox-conversation-title,
body[data-theme='dark'] .chat-inbox-conversation-row.has-unread .chat-inbox-conversation-preview,
body[data-theme='dark'] .chat-inbox-conversation-row.has-unread .chat-inbox-conversation-sender {
    color: #f9fafb;
}

body[data-theme='dark'] .chat-inbox-conversation-sender {
    color: #f3f4f6;
}

body[data-theme='dark'] .chat-inbox-conversation-pill,
body[data-theme='dark'] .chat-inbox-conversation-preview,
body[data-theme='dark'] .chat-inbox-row-action {
    border-color: #374151;
    color: #d1d5db;
    background-color: #1f2937;
}

body[data-theme='dark'] .chat-inbox-conversation-preview-icon {
    color: #9ca3af;
}

body[data-theme='dark'] .chat-inbox-row-action:hover,
body[data-theme='dark'] .chat-inbox-row-action:focus {
    border-color: #7f1d1d;
    color: #fecaca;
    background-color: #3f1d20;
}

body[data-theme='dark'] .chat-inbox-conversation-avatar,
body[data-theme='dark'] .chat-compose-contact-presence {
    border-color: #111827;
}

body[data-theme='dark'] .chat-inbox-empty-icon,
body[data-theme='dark'] .chat-compose-contact-check,
body[data-theme='dark'] .chat-compose-selected-user,
body[data-theme='dark'] .chat-inbox-conversation-avatar-count,
body[data-theme='dark'] .chat-inbox-conversation-avatar-empty {
    border-color: #16539a;
    color: #bad5f5;
    background-color: #0d2f57;
}

@media (max-width: 767px) {
    .chat-compose-overlay {
        z-index: 870;
    }

    .chat-compose-overlay.has-inbox.next-content-overlay-pos-right > .next-content-overlay-panel-container {
        right: 0;
        transform: translateX(100%);
    }

    .chat-compose-overlay.has-inbox.is-open > .next-content-overlay-panel-container {
        transform: translateX(0);
    }

    .chat-inbox-overlay .next-content-overlay-panel,
    .chat-compose-overlay .next-content-overlay-panel {
        width: 100% !important;
    }

    .chat-inbox-conversation-main {
        grid-template-columns: 3.15rem minmax(0, 1fr) auto;
        padding-right: 0.55rem;
    }

    .chat-inbox-row-action {
        opacity: 1;
    }
}
