/* ============================================
   SET BASE — Минимализм, черно-белые цвета
   ============================================ */
:root {
    --color-primary: #000000;
    --color-bg: #f5f5f5;
    --color-bg-card: #ffffff;
    --color-text: #000000;
    --color-text-secondary: #333333;
    --color-border: #cccccc;
    --font-family: Arial, Helvetica, sans-serif;
    --radius: 4px;
}

* {
    margin: 0;
    padding: 0;
    outline: none;
    border: 0;
    box-sizing: border-box;
}

ol, ul { list-style: none; }
blockquote, q { quotes: none; }
table { border-collapse: collapse; border-spacing: 0; }
input, select, textarea { font-family: var(--font-family); }
article, aside, figure, footer, header, nav, section, main { display: block; }

html { scroll-behavior: smooth; }

body {
    font: 16px/1.5 var(--font-family);
    padding: 0;
    margin: 0;
    color: var(--color-text);
    background: var(--color-bg);
    min-height: 100vh;
    width: 100%;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.clr, .clearfix:after { clear: both; }
.clearfix:after { content: ""; display: table; }

/* Ссылки — строго без подчеркиваний при наведении */
a {
    color: #0055cc;
    text-decoration: none;
}
a:hover {
    color: #000000;
    text-decoration: none !important;
}

h1, h2, h3, h4, h5 {
    font-weight: bold;
    line-height: 1.3;
    color: #000000;
}

/* ============================================
   БАЗОВАЯ СЕТКА (Жёсткое центрирование)
   ============================================ */
.wrap {
    min-width: 320px;
    overflow-x: hidden;
    position: relative;
    width: 100% !important;
}

.center {
    width: 100% !important;
    max-width: 1200px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    position: relative;
    box-sizing: border-box !important;
}

.block {
    background: var(--color-bg-card);
    padding: 20px;
    margin: 15px 0;
    border: 1px solid var(--color-border);
}

.cols {
    display: flex;
    flex-wrap: nowrap;
    margin: 15px auto;
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    width: 100%;
}

/* ============================================
   HEADER
   ============================================ */
.header {
    margin-bottom: 15px;
    background: var(--color-bg-card);
    border-bottom: 1px solid var(--color-border);
}

.h-inf {
    padding: 15px 20px;
    min-height: 60px;
    display: block;
}

.logo {
    display: block;
    text-decoration: none;
}

.logo p {
    font-size: 20px;
    font-weight: bold;
    color: #000;
    text-transform: uppercase;
    margin: 0;
    line-height: 1.2;
}

.logo-tagline {
    display: block;
    font-size: 13px;
    color: #666666;
    margin-top: 6px;
}

.btn-menu { display: none !important; }

/* ============================================
   MAIN & SIDEBAR
   ============================================ */
.main {
    flex: 1 1 auto;
    min-width: 0;
    padding: 20px;
}

.side {
    width: 300px;
    flex-shrink: 0;
    padding: 20px;
    border-left: 1px solid var(--color-border);
    background: #fafafa;
}

.side-bt {
    padding-bottom: 10px;
    font-size: 16px;
    font-weight: bold;
    color: #000;
    border-bottom: 2px solid #000;
    margin-bottom: 10px;
}

ul.side-bc a {
    display: block;
    padding: 8px 0;
    border-bottom: 1px solid #eeeeee;
    font-size: 14px;
    color: #333;
    text-decoration: none !important;
}

ul.side-bc a:hover {
    color: #000;
    background: #f5f5f5;
    padding-left: 5px;
}

ul.side-bc li:last-child a { border-bottom: none; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
    padding: 20px;
    margin-top: 20px;
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-card);
    font-size: 13px;
    color: var(--color-text-secondary);
    display: flex;
    justify-content: space-between;
}

/* ============================================
   НОВОСТНЫЕ КАРТОЧКИ (Shortstory)
   ============================================ */
.news-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid var(--color-border);
}

.news-item:last-child { border-bottom: none; }

.news-item-img {
    flex-shrink: 0;
    width: 200px;
    height: 120px;
    background: #eeeeee;
    border: 1px solid var(--color-border);
}

.news-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-item-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.news-item-title {
    font-size: 18px;
    font-weight: bold;
}

.news-item-title a { color: #000; }
.news-item-title a:hover { color: #0055cc; }

.news-item-text {
    font-size: 14px;
    color: #333;
    line-height: 1.5;
}

/* ============================================
   FULLSTORY
   ============================================ */
.full .news-item {
    padding: 0 0 15px 0;
    border-bottom: none;
    display: flex;
    align-items: flex-start;
}

.full .news-item-title {
    font-size: 24px;
    margin-bottom: 15px;
}

.full .news-item-text {
    font-size: 15px;
    color: #000;
}

/* ============================================
   НАВИГАЦИЯ (Pagination)
   ============================================ */
.bottom-nav {
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid var(--color-border);
    margin-top: 20px;
}

.navigation {
    display: flex;
    justify-content: center;
    gap: 5px;
}

.navigation a,
.navigation span {
    display: inline-block;
    padding: 5px 12px;
    border: 1px solid #ccc;
    background: #fff;
    color: #000;
    font-size: 14px;
    text-decoration: none !important;
}

.navigation a:hover { background: #eee; }
.navigation span { background: #000; color: #fff; border-color: #000; }

/* ============================================
   АДАПТИВНОСТЬ (Мобильные)
   ============================================ */
@media screen and (max-width: 820px) {
    .cols { flex-direction: column; }
    .side {
        width: 100%;
        border-left: none;
        border-top: 1px solid var(--color-border);
    }
    .main { padding: 15px; }
    .news-item { flex-direction: column; }
    .news-item-img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }
    .footer {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}

/* ============================================
   ТЕХНИЧЕСКИЕ ИСПРАВЛЕНИЯ
   ============================================ */
html, body {
    max-width: 100vw;
    overflow-x: hidden;
}
.full-text, .comm-two, .news-item-text {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
}

/* ============================================
   АВТО-ОФОРМЛЕНИЕ ПЛЕЕРОВ И СПОЙЛЕРОВ
   ============================================ */
iframe[src*="ok.ru"], 
iframe[src*="vk.com"], 
iframe[src*="vkvideo.ru"], 
iframe[src*="youtube.com"] {
    width: 100% !important;
    aspect-ratio: 16 / 9 !important;
    height: auto !important;
    display: block !important;
    margin: 5px 0 20px 0 !important;
    background: #000 !important;
    border: 1px solid #000 !important;
}

p:has(iframe) b {
    font-size: 16px !important;
    font-weight: bold !important;
    color: #000000 !important;
    display: block !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
}

div:has(> .spoiler-content) {
    background-color: #ebebeb !important;
    border: 1px solid #cccccc !important;
    margin: -10px 0 25px 0 !important;
    padding: 0 !important;
}

div:has(> .spoiler-content) > div:first-child {
    color: #000000 !important;
    font-size: 14px !important;
    font-weight: bold !important;
    text-align: center !important;
    padding: 10px 15px !important;
}

.spoiler-content {
    padding: 0 10px 10px 10px !important;
    margin-top: 0 !important;
}

p:has(iframe) {
    margin: 15px 0 0 0 !important;
    padding: 0 !important;
}

p:has(iframe) br { display: none !important; }

/* ============================================
   ИНФОБЛОКИ И ОШИБКИ (.berrors)
   ============================================ */
.berrors {
    display: flex !important;
    align-items: flex-start !important;
    gap: 15px !important;
    background: #ffffff !important;
    border: 1px solid #000000 !important;
    padding: 15px !important;
    margin-bottom: 20px !important;
    border-radius: 4px !important;
}
.berrors-icon { font-size: 20px !important; }
.berrors-title {
    display: block !important;
    font-weight: bold !important;
    color: #000000 !important;
    margin-bottom: 5px !important;
}
.berrors-text {
    color: #333333 !important;
    font-size: 14px !important;
}

/* ============================================
   ОФОРМЛЕНИЕ КОММЕНТАРИЕВ И ФОРМЫ
   ============================================ */
.add-comm-form {
    background: #f9f9f9 !important;
    padding: 20px !important;
    border: 1px solid var(--color-border) !important;
    margin: 30px 0 20px 0 !important;
    border-radius: 4px !important;
}

.ac-title {
    font-weight: bold !important;
    font-size: 18px !important;
    margin-bottom: 20px !important;
    color: #000 !important;
    border-bottom: 2px solid #000 !important;
    padding-bottom: 10px !important;
    display: inline-block !important;
}

.ac-inputs {
    display: flex !important;
    gap: 15px !important;
    margin-bottom: 15px !important;
}

.ac-inputs input,
.form-secur input {
    flex: 1 !important;
    width: 100% !important;
    padding: 12px !important;
    border: 1px solid #cccccc !important;
    background: #ffffff !important;
    color: #000 !important;
    font-size: 14px !important;
    border-radius: 4px !important;
    box-shadow: none !important;
}

.ac-inputs input:focus,
.form-secur input:focus,
.ac-textarea textarea:focus {
    border-color: #000000 !important;
}

.ac-textarea { margin-bottom: 15px !important; }

.ac-textarea textarea {
    width: 100% !important;
    min-height: 120px !important;
    padding: 12px !important;
    border: 1px solid #cccccc !important;
    background: #ffffff !important;
    color: #000 !important;
    font-size: 14px !important;
    resize: vertical !important;
    border-radius: 4px !important;
    box-shadow: none !important;
    font-family: Arial, Helvetica, sans-serif !important;
}

.ac-protect {
    margin-bottom: 15px !important;
    padding: 15px !important;
    background: #ffffff !important;
    border: 1px dashed #cccccc !important;
}

.form-item label {
    display: block !important;
    font-weight: bold !important;
    margin-bottom: 8px !important;
    font-size: 14px !important;
    color: #000 !important;
}

.ac-submit button {
    background: #000000 !important;
    color: #ffffff !important;
    padding: 10px 30px !important;
    font-size: 14px !important;
    font-weight: bold !important;
    cursor: pointer !important;
    border: none !important;
    border-radius: 4px !important;
    transition: background 0.2s !important;
}

.ac-submit button:hover { background: #333333 !important; }

.ac-soc { margin-bottom: 15px !important; display: flex !important; gap: 8px !important; }
.ac-soc img { width: 32px !important; height: 32px !important; opacity: 0.8 !important; }
.ac-soc img:hover { opacity: 1 !important; }

.comm-item {
    padding: 20px 0 !important;
    border-bottom: 1px solid #eeeeee !important;
}
.comm-item:last-child { border-bottom: none !important; }

.comm-one {
    display: flex !important;
    align-items: baseline !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    margin-bottom: 8px !important;
}

.comm-author {
    font-weight: bold !important;
    font-size: 16px !important;
    color: #000000 !important;
}

.comm-one span:not(.comm-author) {
    font-size: 12px !important;
    color: #888888 !important;
}

.comm-two {
    font-size: 15px !important;
    color: #222222 !important;
    line-height: 1.6 !important;
    margin-bottom: 12px !important;
    word-wrap: break-word !important;
}

.comm-three {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 15px !important;
    font-size: 13px !important;
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.comm-three li { display: inline-flex !important; align-items: center !important; color: #666666 !important; }
.comm-three a { color: #0055cc !important; font-weight: bold !important; text-decoration: none !important; }
.comm-three a:hover { color: #000000 !important; }
.comm-three span.fa { margin-right: 6px !important; }
.comm-three b { color: #000 !important; margin-right: 4px !important; }

@media screen and (max-width: 600px) {
    .ac-inputs { flex-direction: column !important; gap: 10px !important; }
}

/* ============================================
   МОДАЛЬНОЕ ОКНО DLE (.ui-dialog) — Строгий черно-белый стиль
   ============================================ */

/* Само всплывающее окно */
.ui-dialog.dle-popup-alert {
    background: #ffffff !important;
    border: 1px solid #000000 !important;
    border-radius: 4px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
    font-family: Arial, Helvetica, sans-serif !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Шапка окна (Заголовок "Информация" + кнопка закрытия) */
.ui-dialog-titlebar {
    background: #000000 !important;
    color: #ffffff !important;
    border-bottom: 1px solid #000000 !important;
    border-radius: 0 !important;
    padding: 10px 15px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.ui-dialog-title {
    font-weight: bold !important;
    font-size: 14px !important;
    color: #ffffff !important;
    float: none !important;
}

/* Кнопка закрытия (крестик) */
.ui-dialog-titlebar-close {
    background: transparent !important;
    border: none !important;
    cursor: pointer !important;
    padding: 2px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    opacity: 0.8 !important;
    transition: opacity 0.2s !important;
}

.ui-dialog-titlebar-close:hover {
    opacity: 1 !important;
}

.ui-dialog-titlebar-close .ui-icon-closethick {
    background: none !important;
    text-indent: 0 !important;
    display: inline-block !important;
    font-size: 14px !important;
    font-weight: bold !important;
    color: #ffffff !important;
}

.ui-dialog-titlebar-close .ui-icon::after {
    content: "✕";
}

/* Текст сообщения внутри окна ("Заполните поле с сообщением") */
.dle-alert {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    padding: 20px 15px !important;
}

/* Нижняя панель с кнопкой "Ok" */
.ui-dialog-buttonpane {
    background: #f5f5f5 !important;
    border-top: 1px solid #cccccc !important;
    padding: 10px 15px !important;
    margin: 0 !important;
}

.ui-dialog-buttonset {
    float: right !important;
}

/* Кнопка "Ok" в модалке */
.ui-dialog-buttonpane button.ui-button {
    background: #000000 !important;
    color: #ffffff !important;
    border: none !important;
    padding: 8px 20px !important;
    font-size: 13px !important;
    font-weight: bold !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    transition: background 0.2s !important;
    box-shadow: none !important;
}

.ui-dialog-buttonpane button.ui-button:hover {
    background: #333333 !important;
}

.ui-button-text-only .ui-button-text {
    padding: 0 !important;
}