﻿.mailbox-container {
    background: var(--bs-component-bg);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.mailbox-container-body {
    border-top: 1px solid var(--bs-border-color);
    flex: 1;
    display: flex;
    overflow: hidden; /* Constrain overflow to children */
}

.folder-sidebar {
    width: 250px;
    background-color: #f8f9fa;
    border-right: 1px solid #dee2e6;
    padding: 15px;
    overflow-y: auto;
}

.mailbox {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.mailbox-content-area {
    flex: 1; /* Take remaining space */
    display: flex;
    flex-direction: column;
}

.mailbox-toolbar {
    padding: 10px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    flex-shrink: 0; /* Don’t shrink */
}

#mailbox-list {
    flex: 1; /* Grow to fill space */
    overflow-y: auto; /* Enable scrolling */
    background: #fff; /* Ensure visibility */
    min-height: 50px; /* Minimum visibility if empty */
}

#mailbox-content {
    flex-shrink: 0; /* For detail view, if present */
}
.mailbox-placeholder {
    opacity: 0.5; /* Faint to indicate it’s a placeholder */
    pointer-events: none; /* Prevent interaction */
    margin-top: 10px; /* Add some breathing room */
}
.folders-section,
.system-folders-section {
    margin-bottom: 20px;
}

.folder-item,
.system-folder-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px;
    cursor: pointer;
    transition: background-color 0.3s;
}

    .folder-item:hover,
    .system-folder-item:hover {
        background-color: #e9ecef;
    }

.draft-indicator {
    color: #ffc107;
    margin-left: 5px;
}

.folder-actions {
    display: flex;
    gap: 10px;
}
.folder-list-item-link {
    display: block;
    color: var(--bs-body-color);
    text-decoration: none;
    position: relative
}
.mailbox-attachments {
    margin-top: 15px;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.attachment-item {
    padding: 8px;
    margin-bottom: 5px;
    background-color: white;
    border-radius: 3px;
    display: flex;
    align-items: center;
    gap: 10px;
}

    .attachment-item:last-child {
        margin-bottom: 0;
    }

#file-upload {
    display: none;
}

.attachment-list {
    margin-top: 10px;
    padding: 10px;
}

.remove-attachment {
    color: #dc3545;
    cursor: pointer;
    margin-left: auto;
}
.mailbox-list-item.dragging {
    opacity: 0.5;
    background-color: #f0f0f0;
}

.system-folder-item.drag-over,
.folder-item.drag-over {
    background-color: #e0e0e0;
    border: 2px dashed #007bff;
}
action-icon .fa-trash:hover {
    color: #c82333; /* Darker red for trash */
}

.mailbox-empty-state {
    text-align: center;
    padding: 20px 0;
    color: #6c757d;
    font-style: italic;
}

    .mailbox-empty-state .mailbox-title {
        display: inline-flex;
        align-items: center;
    }