/* temp/web/css/style-mail.css */
/* ПОЧТА */
body { font-family: sans-serif; margin: 0; background: #f4f6f8; color: #333; }
.app-container { display: flex; flex-direction: column; height: 100vh; }
.top-bar { background: #333; color: #fff; padding: 10px 20px; display: flex; justify-content: space-between; align-items: center; }
.mail-layout { display: flex; flex: 1; overflow: hidden; }
.sidebar { width: 220px; background: #fff; border-right: 1px solid #ddd; padding: 20px; display: flex; flex-direction: column; }
.content-area { flex: 1; padding: 25px; overflow-y: auto; background: #fff; }
/* Кнопки и Навигация */
.btn-compose { width: 100%; padding: 12px; background: #007bff; color: white; border: none; border-radius: 4px; cursor: pointer; margin-bottom: 20px; font-weight: bold; }
.folder-list a { display: block; padding: 10px; text-decoration: none; color: #555; border-radius: 4px; margin-bottom: 5px; }
.folder-list a:hover { background: #f0f0f0; }
.folder-list a.active { background: #e7f1ff; color: #007bff; font-weight: bold; }
/* Список сообщений */
.list-controls { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
/* Удлинили поиск (было 200px) + адаптивность */
.search-input { padding: 8px 15px; border-radius: 20px; border: 1px solid #ddd; width: 100%; max-width: 500px; outline: none; }
.msg-list { list-style: none; padding: 0; }
/* Компактная строка (Flexbox) */
.msg-item { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    border-bottom: 1px solid #eee; /* Линия вместо рамки */
    padding: 10px 15px; 
    cursor: pointer; 
    background: #fff;}
.msg-item:hover { background: #f9f9f9; }
/* Левая часть: Тема и Автор/Адресат */
.msg-main-info { display: flex; align-items: baseline; gap: 15px; flex: 1; overflow: hidden; }
.msg-subject { font-weight: bold; color: #333; white-space: nowrap; }
.msg-correspondent { color: #666; font-size: 0.9em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Правая часть: Дата и Скрепка */
.msg-meta-info { display: flex; align-items: center; gap: 15px; font-size: 0.85em; color: #999; white-space: nowrap; }
/* Просмотр и Редактор */
.compose-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.msg-body { line-height: 1.6; min-height: 200px; margin-top: 20px; }
blockquote { border-left: 3px solid #ccc; margin-left: 0; padding-left: 15px; color: #777; font-style: italic; }
.hidden { display: none !important; }
.form-group { margin-bottom: 10px; }
.form-group input { width: 100%; padding: 10px; border: 1px solid #ddd; border-radius: 4px; box-sizing: border-box; }
.editor-toolbar { background: #f8f8f8; padding: 8px; border: 1px solid #ddd; border-bottom: none; border-radius: 4px 4px 0 0; display: flex; align-items: center; }
.editor-toolbar button, .btn-attach { background: #fff; border: 1px solid #bbb; padding: 4px 10px; cursor: pointer; margin-right: 5px; border-radius: 3px; font-size: 0.9em; }
.editor-content { border: 1px solid #ddd; min-height: 300px; padding: 15px; border-radius: 0 0 4px 4px; outline: none; }
.editor-content:focus { border-color: #007bff; }
/* Вложения */
.att-chip { display: inline-block; background: #e3f2fd; padding: 4px 12px; border-radius: 16px; margin: 10px 5px 0 0; font-size: 0.85em; border: 1px solid #bbdefb; }
.att-chip a { text-decoration: none; color: #0277bd; }
/* Общие кнопки */
.btn-primary { background: #28a745; color: #fff; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; }
.btn-secondary { background: #6c757d; color: #fff; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; }
/* Адаптивность */
@media (max-width: 768px) {
    .mail-layout { flex-direction: column; }
    .sidebar { width: 100%; border-right: none; border-bottom: 1px solid #ddd; padding: 10px; box-sizing: border-box; }
    .folder-list { display: flex; gap: 10px; overflow-x: auto; }
    .folder-list a { margin-bottom: 0; white-space: nowrap; }
    .msg-main-info { flex-direction: column; align-items: flex-start; gap: 2px; }
    .msg-correspondent { font-size: 0.8em; } }