/* Совместимость темы с компонентами DataLife Engine.
   Здесь только то, что не входит в дизайн v28: таблицы, редактор,
   служебные формы, вложения и разметка стандартных шаблонов DLE. */

body { font-size: 14px; }
p { margin: 0 0 12px; }
h1, h2, h3, h4 { line-height: 1.2; }
hr { border: 0; border-top: 1px solid var(--border); margin: 18px 0; }

/* Таблицы служебных страниц (ЛС, профиль, статистика, админ-формы) */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; font-size: 12px; vertical-align: top; }
.table th { color: var(--muted); font-weight: 800; }
.table tr:last-child td { border-bottom: 0; }
.table-striped tbody tr:nth-child(odd) { background: var(--soft); }

.heading, .h4 { font-size: 18px; letter-spacing: -.4px; margin: 0 0 14px; }
.hnum { font-size: 12px; font-weight: 700; }

/* Стандартные кнопки и поля DLE */
.btn-border { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); padding: 9px 12px; font-size: 12px; font-weight: 700; }
.btn-border:hover { border-color: var(--accent); color: var(--accent); }
.plus_icon { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; font-size: 14px; }
.plus_icon.circle { border-radius: 50%; }
.form-sep { border-top: 1px solid var(--border); padding-top: 12px; margin-top: 12px; }
.field.wide, .wide { width: 100%; }
.checkbox, .form-check-input { accent-color: var(--accent); }

/* Редактор DLE */
.bb-editor, .wysiwygeditor { width: 100%; min-height: 160px; border-radius: 8px; }
.bb-panel, .bb-editor-panel, .editor-toolbar { display: flex; flex-wrap: wrap; gap: 2px; padding: 4px; border: 1px solid var(--border); border-bottom: 0; border-radius: 8px 8px 0 0; background: var(--soft); }
.bb-panel + textarea, .bb-panel + .bb-editor { border-radius: 0 0 8px 8px; }
.bbcodes { border: 0; background: transparent; color: var(--muted); border-radius: 5px; padding: 5px 6px; font-size: 12px; }
.bbcodes:hover { background: var(--surface); color: var(--accent); }
.editor, .editor textarea { width: 100%; }

/* Комментарии: обёртки движка */
#dle-comments-list, #dle-ajax-comments { display: block; }
#dle-comments-list > .comment:first-child { border-top: 0; }
.com_list .comment:first-child { border-top: 0; padding-top: 0; }
.mass-action { display: inline-flex; }
.complaint, .edit_btn, .del { color: var(--muted); font-size: 10px; }
.complaint:hover, .edit_btn:hover, .del:hover { color: var(--accent); }

/* Вложения и файлы */
.attachment, .attachments { margin-top: 12px; }
.attachment a, .attachments a { color: var(--accent); font-weight: 700; }

/* Просмотр ЛС / профиля */
.userinfo_top, .dark_top { background: var(--soft); }
.avatar .cover { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: color-mix(in srgb, var(--accent) 18%, var(--surface)); background-size: cover; color: var(--accent); font-weight: 800; }
.addform, .addpm { display: grid; gap: 10px; }

/* Информеры, голосования, статистика */
.poll, .vote, .informer, .stats { font-size: 12px; }
.vote .vote-item { padding: 6px 0; }

/* Спидбар и служебные сообщения */
.speedbar { font-size: 11px; color: var(--muted); }
.berrors { background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.info-message { padding: 12px 14px; border-radius: 8px; background: var(--soft); color: var(--text); margin-bottom: 14px; font-size: 12px; }

/* Отзывчивость таблиц служебных страниц */
@media (max-width: 760px) {
	.table { display: block; overflow-x: auto; white-space: nowrap; }
	.box { padding: 16px; }
}

/* Регистрация, восстановление пароля, обратная связь */
.page-shell > form { display: block; }
.page_form__inner { max-width: 780px; margin: 0 auto; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 26px; }
.page_form__form { display: grid; gap: 12px; }
.page_form__inner .title, .h1 { font-size: 26px; letter-spacing: -.8px; margin: 0 0 14px; }
.regtext { color: var(--muted); line-height: 1.7; margin-bottom: 16px; font-size: 12px; }
.login_check { display: flex; gap: 8px; align-items: stretch; }
.login_check input { flex: 1; min-width: 0; }
.login_check .btn { flex: none; }

/* Статистика */
.stats_head { background: var(--soft); border-radius: 10px; padding: 16px; margin-bottom: 16px; }
.stats_head ul { list-style: none; margin: 0; padding: 0; }
.stats_head li { padding: 6px 0; font-size: 12px; }
.statistics { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.stat_group h5 { margin: 0 0 8px; font-size: 13px; color: var(--accent); }
.stat_group ul { list-style: none; margin: 0; padding: 0; }
.stat_group li { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--border); padding: 8px 0; font-size: 12px; }
@media (max-width: 760px) { .page_form__inner { padding: 18px; } .statistics { grid-template-columns: 1fr; } }
