body {
    min-height: 100vh;
}

.action-buttons {
    white-space: nowrap;
}

.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
    height: 100vh;
}

.sidebar-sticky {
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar .nav-link {
    font-weight: 500;
    color: var(--bs-body-color);
    padding: .5rem 1rem;
    margin-bottom: .2rem;
    border-radius: .375rem;
}

.sidebar .nav-link:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--bs-primary);
}

.sidebar .nav-link.active {
    background-color: var(--bs-primary);
    color: #fff;
}

.sidebar .nav-link .bi {
    width: 16px;
    height: 16px;
}

@media (min-width: 768px) {
    main.col-md-9 {
        margin-left: 25%;
        min-height: 100vh;
        padding-bottom: 2rem;
    }
    
    main.col-lg-10 {
        margin-left: 16.666667%;
    }
}

@media (max-width: 767.98px) {
    .sidebar {
        position: static;
        height: auto;
        padding-top: 0;
    }
    
    .sidebar-sticky {
        height: auto;
        overflow: visible;
    }
}

.chat-window .message-bubble {
    max-width: 75%;
}

.chat-window .message-bubble p {
    white-space: pre-wrap;
    word-break: break-word;
    margin-bottom: 0;
}

.message-content-wrapper {
    display: flex;
    align-items: flex-end;
}

.message-text-content {
    flex-grow: 1;
}

.message-timestamp {
    font-size: 0.75rem;
    opacity: 0.75;
    margin-left: 0.5rem;
    flex-shrink: 0;
    white-space: nowrap;
}

.media-container img,
.media-container video {
    max-width: 100%;
    max-height: 300px;
    width: auto;
    height: auto;
    display: block;
    border-radius: 0.25rem;
}

.chat-list-actions {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.message-form .input-group {
    position: relative;
}

.message-form textarea {
    border-radius: 0.375rem !important;
    padding-right: 80px;
}

.message-form .btn-send {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    background: transparent;
    border: none;
    color: var(--bs-primary);
    padding: .375rem .75rem;
}

.message-form .btn-attach {
    position: absolute;
    right: 45px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    background: transparent;
    border: none;
    color: var(--bs-secondary-color);
    padding: .375rem .75rem;
}

.message-form .btn-send:hover,
.message-form .btn-attach:hover {
    color: var(--bs-primary-text-emphasis);
}

.attachment-preview-item {
    cursor: default;
}

.attachment-preview-item .btn-close {
    cursor: pointer;
}