/* =========================================================
   ВНУТРЕННИЕ СТРАНИЦЫ: ДВУХКОЛОНОЧНЫЙ LAYOUT
   ========================================================= */

/* Контейнер для двух колонок внутри #region3 */
#region3 {
    display: flex;
    gap: 30px;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 15px;
}

/* Левая колонка: сайдбар (новости + меню) */
#region3 .aside#region_2 {
    flex: 0 0 320px;
    width: 100%;
}

/* Правая колонка: основной контент */
#region3 .main#region_3 {
    flex: 1;
    min-width: 0; /* Важно для flex */
}

/* Хлебные крошки на всю ширину контента */
#breadcrumbs {
    background: var(--white);
    padding: 12px 20px;
    border-radius: var(--border-radius);
    border: 1px solid #eee;
    margin-bottom: 25px;
    font-size: 13px;
    color: var(--text-light);
}
#breadcrumbs a {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 500;
}
#breadcrumbs a:hover {
    color: var(--accent-orange);
    text-decoration: underline;
}

/* Белый блок контента */
.content_box {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    padding: 35px;
    margin-bottom: 30px;
}

/* Заголовок H1 */
.content_box > h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-blue);
    border-bottom: 3px solid var(--accent-orange);
    padding-bottom: 15px;
    margin-bottom: 25px;
    line-height: 1.3;
}

/* Типографика текста */
.html_block.post p {
    margin-bottom: 16px;
    line-height: 1.7;
    color: var(--text-dark);
    font-size: 15px;
}
.html_block.post a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: rgba(30, 90, 135, 0.3);
    font-weight: 600;
}
.html_block.post a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--accent-orange);
}
.html_block.post strong {
    color: var(--primary-blue);
    font-weight: 700;
}
.html_block.post img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    margin: 15px 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

/* Стили для сайдбара */
#region3 .aside#region_2 .site_search {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    padding: 20px;
    margin-bottom: 25px;
}
#region3 .aside#region_2 .site_search input[type="search"] {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
    font-size: 14px;
}
#region3 .aside#region_2 .site_search input[type="search"]:focus {
    outline: none;
    border-color: var(--primary-blue);
}
#region3 .aside#region_2 .site_search input[type="submit"] {
    width: 100%;
    padding: 10px;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
}
#region3 .aside#region_2 .site_search input[type="submit"]:hover {
    background: var(--accent-orange);
}

/* Блок новостей */
#region3 .aside#region_2 .aside_box {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    margin-bottom: 25px;
    overflow: hidden;
}
#region3 .aside#region_2 .aside_box h3 {
    background: var(--primary-blue);
    color: var(--white);
    padding: 15px 20px;
    font-size: 15px;
    font-weight: 700;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
#region3 .aside#region_2 .wrapper-news {
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}
#region3 .aside#region_2 .wrapper-news:last-child {
    border-bottom: none;
}
#region3 .aside#region_2 .wrapper-news:hover {
    background: var(--bg-light);
}
#region3 .aside#region_2 .wrapper-news h4 {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 6px 0;
    line-height: 1.4;
}
#region3 .aside#region_2 .wrapper-news h4 a {
    color: var(--text-dark);
    text-decoration: none;
}
#region3 .aside#region_2 .wrapper-news h4 a:hover {
    color: var(--primary-blue);
}
#region3 .aside#region_2 .wrapper-news .date {
    font-size: 12px;
    color: var(--text-light);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}
#region3 .aside#region_2 .wrapper-news .date::before {
    content: '\f073';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--accent-orange);
    font-size: 11px;
}

/* Меню разделов */
#region3 .aside#region_2 .section_menu > a {
    display: block;
    padding: 12px 20px;
    background: var(--primary-blue);
    color: white !important;
    font-weight: 600;
}
#region3 .aside#region_2 .section_menu ul.level_0 > li {
    border-bottom: 1px solid #f0f0f0;
}
#region3 .aside#region_2 .section_menu ul.level_0 > li > a,
#region3 .aside#region_2 .section_menu ul.level_0 > li > span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}
#region3 .aside#region_2 .section_menu ul.level_0 > li > a:hover {
    background: var(--bg-light);
    color: var(--primary-blue);
}
#region3 .aside#region_2 .section_menu ul.level_0 > li.parent > a::after,
#region3 .aside#region_2 .section_menu ul.level_0 > li.parent > span::after {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    color: var(--text-light);
    transition: transform 0.3s;
}
#region3 .aside#region_2 .section_menu ul.level_0 > li.active > a::after,
#region3 .aside#region_2 .section_menu ul.level_0 > li.active > span::after {
    transform: rotate(180deg);
}
#region3 .aside#region_2 .section_menu ul.level_1,
#region3 .aside#region_2 .section_menu ul.level_2 {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0;
}
#region3 .aside#region_2 .section_menu ul.level_0 > li.active > ul.level_1,
#region3 .aside#region_2 .section_menu ul.level_1 > li.active > ul.level_2 {
    display: block;
}
#region3 .aside#region_2 .section_menu ul.level_1 > li > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px 10px 35px;
    color: var(--text-light);
    text-decoration: none;
    font-size: 14px;
    border-left: 3px solid transparent;
    transition: all 0.2s;
}
#region3 .aside#region_2 .section_menu ul.level_1 > li > a:hover {
    background: var(--bg-light);
    color: var(--primary-blue);
    border-left-color: var(--primary-blue);
}
#region3 .aside#region_2 .section_menu ul.level_1 > li.parent > a::after {
    content: '\f105';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 11px;
    margin-left: auto;
    transition: transform 0.3s;
}
#region3 .aside#region_2 .section_menu ul.level_1 > li.active > a::after {
    transform: rotate(90deg);
}
#region3 .aside#region_2 .section_menu ul.level_2 > li > a {
    padding: 8px 20px 8px 50px;
    font-size: 13px;
    color: var(--text-light);
    border-left: 3px solid transparent;
}
#region3 .aside#region_2 .section_menu ul.level_2 > li > a:hover {
    background: #f8f9fa;
    border-left-color: var(--accent-orange);
}
#region3 .aside#region_2 .section_menu ul.level_0 > li.parent_active > a,
#region3 .aside#region_2 .section_menu ul.level_0 > li.active > a,
#region3 .aside#region_2 .section_menu ul.level_1 > li.parent_active > a,
#region3 .aside#region_2 .section_menu ul.level_1 > li.active > a,
#region3 .aside#region_2 .section_menu ul.level_2 > li.active > span {
    background: rgba(255, 153, 0, 0.1);
    color: var(--accent-orange) !important;
    border-left-color: var(--accent-orange);
    font-weight: 600;
}
#region3 .aside#region_2 .section_menu ul.level_2 > li.active > span {
    display: block;
    padding: 8px 20px 8px 50px;
}

/* Спойлеры (аккордеоны) */
.entry_spoiler.excerpt {
    background: var(--white);
    border: 1px solid #eee;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: all 0.3s ease;
}
.entry_spoiler.excerpt:hover {
    box-shadow: 0 5px 15px rgba(30, 90, 135, 0.1);
    border-color: var(--primary-blue);
}
.entry_spoiler .excerpt_preview {
    width: 80px;
    flex-shrink: 0;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 3px solid var(--accent-orange);
}
.entry_spoiler .excerpt_preview img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    margin: 0 !important;
    box-shadow: none !important;
}
.entry_spoiler .excerpt_content {
    flex: 1;
    padding: 15px 20px;
    position: relative;
}
.entry_spoiler .excerpt_content > span {
    display: none;
}
.entry_spoiler .excerpt_content h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 10px 0;
    line-height: 1.4;
}
.entry_spoiler .show-hide {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--primary-blue);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
}
.entry_spoiler .show-hide:hover {
    color: var(--accent-orange);
}
.entry_spoiler .show-hide::before {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 11px;
}
.entry_spoiler .post.spoiler {
    padding: 25px;
    border-top: 1px solid #eee;
    background: #fdfdfd;
    width: 100%;
    box-sizing: border-box;
}
.entry_spoiler .post.spoiler iframe {
    max-width: 100%;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}

/* Таблицы */
.content_box table, 
.post.spoiler table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 14px;
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.content_box table th, 
.post.spoiler table th {
    background: var(--primary-blue);
    color: var(--white);
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
}
.content_box table td, 
.post.spoiler table td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    color: var(--text-dark);
}
.content_box table tr:nth-child(even), 
.post.spoiler table tr:nth-child(even) {
    background-color: var(--bg-light);
}
.content_box table tr:hover td, 
.post.spoiler table tr:hover td {
    background-color: rgba(255, 153, 0, 0.05);
}

/* Адаптивность */
@media (max-width: 992px) {
    #region3 {
        flex-direction: column;
    }
    
    #region3 .aside#region_2 {
        flex: 0 0 100%;
        order: 2;
    }
    
    #region3 .main#region_3 {
        order: 1;
    }
    
    .content_box {
        padding: 20px;
    }
    
    .entry_spoiler.excerpt {
        flex-direction: column;
    }
    .entry_spoiler .excerpt_preview {
        width: 100%;
        height: 60px;
        border-right: none;
        border-bottom: 3px solid var(--accent-orange);
    }
    
    .content_box table, 
    .post.spoiler table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* Скрываем все подменю по умолчанию */
#region_2 .section_menu ul.level_1,
#region_2 .section_menu ul.level_2 {
    display: none;
}

/* Показываем подменю если у родителя есть класс active ИЛИ parent_active */
#region_2 .section_menu li.active > ul,
#region_2 .section_menu li.parent_active > ul,
#region_2 .section_menu ul.parent_active {
    display: block;
}

/* Стрелочка для элементов с подменю */
#region_2 .section_menu .parent > a::after {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    margin-left: 8px;
    transition: transform 0.3s;
    float: right;
    color: var(--text-light);
}

/* Поворот стрелочки при открытии */
#region_2 .section_menu .parent.active > a::after {
    transform: rotate(180deg);
}

/* Подсветка активного пункта */
#region_2 .section_menu li.active > a,
#region_2 .section_menu li.parent_active > a {
    color: var(--accent-orange);
    font-weight: 600;
}

/* Стили для спойлеров (аккордеон) */
.entry_spoiler.excerpt {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    margin-bottom: 15px;
    overflow: hidden;
}

.entry_spoiler .excerpt_preview {
    width: 60px;
    float: left;
    padding: 15px;
    background: var(--bg-light);
    border-right: 3px solid var(--accent-orange);
}

.entry_spoiler .excerpt_preview img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.entry_spoiler .excerpt_content {
    padding: 15px 20px;
    margin-left: 60px;
}

.entry_spoiler .excerpt_content h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 10px 0;
    line-height: 1.4;
}

.entry_spoiler .show-hide {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--primary-blue);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
}

.entry_spoiler .show-hide:hover {
    color: var(--accent-orange);
}

.entry_spoiler .show-hide::before {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 11px;
    transition: transform 0.3s;
}

.entry_spoiler .post.spoiler {
    padding: 20px;
    border-top: 1px solid #eee;
    background: #fdfdfd;
    display: none;
}

.entry_spoiler .post.spoiler iframe,
.entry_spoiler .post.spoiler table {
    max-width: 100%;
    margin: 10px 0;
}

.entry_spoiler .post.spoiler table {
    border-collapse: collapse;
    width: 100%;
}

.entry_spoiler .post.spoiler table td {
    padding: 8px 12px;
    border: 1px solid #ddd;
    font-size: 14px;
}

.entry_spoiler .post.spoiler table tr:nth-child(even) {
    background: var(--bg-light);
}

/* Адаптивность */
@media (max-width: 768px) {
    .entry_spoiler .excerpt_preview {
        float: none;
        width: 100%;
        border-right: none;
        border-bottom: 3px solid var(--accent-orange);
    }
    
    .entry_spoiler .excerpt_content {
        margin-left: 0;
        padding: 15px;
    }
    
    .entry_spoiler .post.spoiler {
        padding: 15px;
    }
}

/* ============================================
   ИСПРАВЛЕНИЕ СПОЙЛЕРОВ - КОНТЕНТ НА ВСЮ ШИРИНУ
   ============================================ */

.entry_spoiler.excerpt {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    margin-bottom: 20px;
    overflow: hidden;
}

/* Заголовок спойлера (всегда с иконкой и полосой) */
.entry_spoiler .excerpt_preview {
    width: 60px;
    float: left;
    padding: 20px 15px;
    background: linear-gradient(135deg, var(--bg-light) 0%, #fff 100%);
    border-right: 3px solid var(--accent-orange);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80px;
}

.entry_spoiler .excerpt_preview img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    opacity: 0.7;
}

.entry_spoiler .excerpt_content {
    padding: 20px;
    margin-left: 60px; /* Отступ для иконки в заголовке */
}

.entry_spoiler .excerpt_content h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 15px 0;
    line-height: 1.4;
}

/* Кнопка раскрыть/свернуть */
.entry_spoiler .show-hide {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, #2a7aa8 100%);
    color: white !important;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none !important;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(30, 90, 135, 0.3);
    margin: 10px 0;
    border: none;
}

.entry_spoiler .show-hide:hover {
    background: linear-gradient(135deg, var(--accent-orange) 0%, #ffaa33 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 153, 0, 0.4);
}

.entry_spoiler .show-hide::before {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    transition: transform 0.3s;
}

.entry_spoiler .show-hide.expanded::before {
    transform: rotate(180deg);
}

/* ============================================
   ИСПРАВЛЕНИЕ СПОЙЛЕРОВ - КОНТЕНТ НА ВСЮ ШИРИНУ
   ============================================ */

.entry_spoiler.excerpt {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    margin-bottom: 20px;
    overflow: hidden;
}

/* Иконка слева (всегда фиксированной ширины) */
.entry_spoiler .excerpt_preview {
    width: 60px;
    float: left;
    padding: 20px 15px;
    background: linear-gradient(135deg, var(--bg-light) 0%, #fff 100%);
    border-right: 3px solid var(--accent-orange);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80px;
    flex-shrink: 0; /* Не сжимается */
}

.entry_spoiler .excerpt_preview img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    opacity: 0.7;
}

/* Заголовок справа от иконки */
.entry_spoiler .excerpt_content {
    padding: 20px;
    margin-left: 60px; /* Отступ для иконки */
}

.entry_spoiler .excerpt_content h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 15px 0;
    line-height: 1.4;
}

/* Кнопка раскрыть/свернуть */
.entry_spoiler .show-hide {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, #2a7aa8 100%);
    color: white !important;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none !important;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(30, 90, 135, 0.3);
    margin: 10px 0;
    border: none;
}

.entry_spoiler .show-hide:hover {
    background: linear-gradient(135deg, var(--accent-orange) 0%, #ffaa33 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 153, 0, 0.4);
}

.entry_spoiler .show-hide::before {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    transition: transform 0.3s;
}

.entry_spoiler .show-hide.expanded::before {
    transform: rotate(180deg);
}

/* КОНТЕНТ СПОЙЛЕРА - НА ВСЮ ШИРИНУ! */
.entry_spoiler .post.spoiler {
    padding: 25px;
    border-top: 2px solid var(--accent-orange);
    background: #fafafa;
    display: none;
    margin: 15px -20px -25px -20px; /* Растягиваем на всю ширину */

    box-sizing: border-box;
    overflow-x: auto;
}

/* Ссылки внутри спойлеров */
.entry_spoiler .post.spoiler a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: var(--accent-orange);
    text-decoration-thickness: 2px;
    font-weight: 600;
    transition: all 0.2s;
}

.entry_spoiler .post.spoiler a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--primary-blue);
}

/* Таблицы внутри спойлеров */
.entry_spoiler .post.spoiler table {
    width: 100%;
    max-width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    font-size: 14px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: table;
}

.entry_spoiler .post.spoiler table th,
.entry_spoiler .post.spoiler table td {
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    text-align: left;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.entry_spoiler .post.spoiler table th {
    background: var(--primary-blue);
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

.entry_spoiler .post.spoiler table tr:nth-child(even) {
    background: var(--bg-light);
}

.entry_spoiler .post.spoiler table tr:hover {
    background: rgba(255, 153, 0, 0.05);
}

/* Iframes */
.entry_spoiler .post.spoiler iframe {
    max-width: 100%;
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin: 10px 0;
}

/* Адаптивность */
@media (max-width: 768px) {
    .entry_spoiler .excerpt_preview {
        float: none;
        width: 100%;
        border-right: none;
        border-bottom: 3px solid var(--accent-orange);
        padding: 15px;
        min-height: auto;
    }
    
    .entry_spoiler .excerpt_content {
        margin-left: 0;
        padding: 15px;
    }
    
    .entry_spoiler .post.spoiler {
        margin: 15px -15px -15px -15px;
        padding-left: 15px;
        width: calc(100% + 30px);
    }
    
    .entry_spoiler .post.spoiler table {
        font-size: 12px;
    }
    
    .entry_spoiler .post.spoiler table th,
    .entry_spoiler .post.spoiler table td {
        padding: 8px 10px;
    }
}

/* ============================================
   АДАПТИВНЫЕ ТАБЛИЦЫ
   ============================================ */

/* Контейнер для таблиц с прокруткой */
.content_box .html_block.post {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Все таблицы внутри контента */
.content_box table,
.html_block.post table {
    max-width: 100% !important;
    width: 100% !important;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 14px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Ячейки таблиц */
.content_box table th,
.content_box table td,
.html_block.post table th,
.html_block.post table td {
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    text-align: left;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    min-width: 100px;
}

/* Заголовки таблиц */
.content_box table th,
.html_block.post table th {
    background: var(--primary-blue);
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* Чередование строк */
.content_box table tr:nth-child(even),
.html_block.post table tr:nth-child(even) {
    background: var(--bg-light);
}

/* Hover эффект */
.content_box table tr:hover,
.html_block.post table tr:hover {
    background: rgba(255, 153, 0, 0.05);
}

/* Центрирование текста в ячейках */
.content_box table td[style*="text-align: center"],
.html_block.post table td[style*="text-align: center"] {
    text-align: center !important;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .content_box table,
    .html_block.post table {
        font-size: 12px;
    }
    
    .content_box table th,
    .content_box table td,
    .html_block.post table th,
    .html_block.post table td {
        padding: 8px 10px;
        min-width: 80px;
    }
}

/* Специально для таблиц с расписанием */
.content_box table[width="1000"],
.html_block.post table[width="1000"] {
    width: 100% !important;
    max-width: 100% !important;
}

/* ============================================
   ССЫЛКИ ВНУТРИ КОНТЕНТА
   ============================================ */

/* Ссылки внутри текстового блока */
.content_box a,
.html_block.post a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: var(--accent-orange);
    text-decoration-thickness: 2px;
    text-underline-offset: 2px;
    font-weight: 600;
    transition: all 0.2s ease;
}

/* Hover эффект для ссылок */
.content_box a:hover,
.html_block.post a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--primary-blue);
    text-decoration-thickness: 3px;
}

/* Ссылки внутри списков */
.content_box ul li a,
.content_box ol li a,
.html_block.post ul li a,
.html_block.post ol li a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: var(--accent-orange);
    font-weight: 600;
}

.content_box ul li a:hover,
.content_box ol li a:hover,
.html_block.post ul li a:hover,
.html_block.post ol li a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--primary-blue);
}

/* Ссылки с target="_blank" (внешние) */
.content_box a[target="_blank"],
.html_block.post a[target="_blank"] {
    position: relative;
    padding-right: 18px;
}

.content_box a[target="_blank"]::after,
.html_block.post a[target="_blank"]::after {
    content: '\f08e';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: 0;
    top: 0;
    font-size: 11px;
    color: var(--accent-orange);
}

/* Ссылки внутри спойлеров */
.entry_spoiler .post.spoiler a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: var(--accent-orange);
    text-decoration-thickness: 2px;
    font-weight: 600;
    transition: all 0.2s;
}

.entry_spoiler .post.spoiler a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--primary-blue);
}

/* ============================================
   ИСПРАВЛЕНИЕ ТАБЛИЦ С РУКОВОДСТВОМ
   ============================================ */

/* Контейнер для широких таблиц с прокруткой */
.content_box .html_block.post,
.html_block.post {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -35px; /* Компенсируем padding родителя */
    padding: 0 35px;
}

/* Таблицы внутри контента */
.content_box table,
.html_block.post table {
    width: 100% !important;
    max-width: 100% !important;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 14px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: table !important; /* Важно для таблиц */
    table-layout: auto !important;
    min-width: 600px; /* Минимальная ширина для читаемости */
}

/* Ячейки таблиц */
.content_box table th,
.content_box table td,
.html_block.post table th,
.html_block.post table td {
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    text-align: left;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    vertical-align: middle;
}

/* Заголовки таблиц */
.content_box table th,
.html_block.post table th {
    background: var(--primary-blue);
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* Чередование строк */
.content_box table tr:nth-child(even),
.html_block.post table tr:nth-child(even) {
    background: var(--bg-light);
}

/* Hover эффект */
.content_box table tr:hover,
.html_block.post table tr:hover {
    background: rgba(255, 153, 0, 0.05);
}

/* Изображения в таблицах */
.content_box table img,
.html_block.post table img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Ссылки в таблицах */
.content_box table a,
.html_block.post table a {
    color: var(--primary-blue);
    text-decoration: underline;
    text-decoration-color: var(--accent-orange);
    font-weight: 600;
    white-space: nowrap;
}

.content_box table a:hover,
.html_block.post table a:hover {
    color: var(--accent-orange);
    text-decoration-color: var(--primary-blue);
}

/* Адаптивность для мобильных */
@media (max-width: 992px) {
    .content_box .html_block.post,
    .html_block.post {
        margin: 0 -20px;
        padding: 0 20px;
    }
    
    .content_box table,
    .html_block.post table {
        font-size: 12px;
        min-width: 500px;
    }
    
    .content_box table th,
    .content_box table td,
    .html_block.post table th,
    .html_block.post table td {
        padding: 8px 10px;
    }
}

@media (max-width: 768px) {
    .content_box table,
    .html_block.post table {
        min-width: 400px;
        font-size: 11px;
    }
}


/* ============================================
   ИСПРАВЛЕНИЕ IFRAME'ОВ - СОХРАНЯЕМ ВЫСОТУ
   ============================================ */

/* Основной контейнер контента */
.content_box,
.html_block.post {
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
}

/* Все iframes по умолчанию - адаптивные по ширине */
.content_box iframe,
.html_block.post iframe,
.entry_spoiler .post.spoiler iframe {
    max-width: 100% !important;
    width: 100% !important;
    border: 1px solid #ddd;
    border-radius: 8px;
    display: block;
    margin: 15px 0;
    /* УБРАЛ height: auto !important */
}

/* Google Drive preview (документы для просмотра) */
.content_box iframe[src*="drive.google.com/file"],
.html_block.post iframe[src*="drive.google.com/file"],
.entry_spoiler .post.spoiler iframe[src*="drive.google.com/file"] {
    aspect-ratio: 5/6;
    height: auto;
    min-height: 400px;
}

/* Google Docs (встроенные документы) - СОХРАНЯЕМ ВЫСОТУ! */
.content_box iframe[src*="docs.google.com/document"],
.html_block.post iframe[src*="docs.google.com/document"],
.entry_spoiler .post.spoiler iframe[src*="docs.google.com/document"] {
    min-height: 800px;
    height: 1200px !important; /* Сохраняем оригинальную высоту */
    border: none;
    border-radius: 0;
}

/* Google Презентации */
.content_box iframe[src*="docs.google.com/presentation"],
.html_block.post iframe[src*="docs.google.com/presentation"],
.entry_spoiler .post.spoiler iframe[src*="docs.google.com/presentation"] {
    aspect-ratio: 16/9;
    min-height: 350px;
    height: auto;
}

/* Google Таблицы */
.content_box iframe[src*="docs.google.com/spreadsheets"],
.html_block.post iframe[src*="docs.google.com/spreadsheets"],
.entry_spoiler .post.spoiler iframe[src*="docs.google.com/spreadsheets"] {
    min-height: 600px;
    height: 800px;
}

/* Все изображения */
.content_box img,
.html_block.post img,
.entry_spoiler .post.spoiler img {
    max-width: 100% !important;
    height: auto !important;
    width: auto !important;
    display: block;
    margin: 15px auto;
}

/* Таблицы - горизонтальная прокрутка если нужно */
.content_box table,
.html_block.post table,
.entry_spoiler .post.spoiler table {
    max-width: 100% !important;
    width: 100% !important;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
}

/* Обертка для контента с прокруткой */
.html_block.post {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Адаптивность для планшетов */
@media (max-width: 992px) {
    .content_box iframe[src*="docs.google.com/document"],
    .html_block.post iframe[src*="docs.google.com/document"],
    .entry_spoiler .post.spoiler iframe[src*="docs.google.com/document"] {
        height: 1000px !important;
        min-height: 600px;
    }
    
    .content_box iframe[src*="drive.google.com/file"],
    .html_block.post iframe[src*="drive.google.com/file"] {
        min-height: 350px;
    }
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .content_box,
    .html_block.post {
        padding: 15px !important;
    }
    
    /* Google Docs на мобильных - уменьшаем высоту но оставляем читаемой */
    .content_box iframe[src*="docs.google.com/document"],
    .html_block.post iframe[src*="docs.google.com/document"],
    .entry_spoiler .post.spoiler iframe[src*="docs.google.com/document"] {
        height: 800px !important;
        min-height: 500px;
    }
    
    .content_box iframe[src*="drive.google.com/file"],
    .html_block.post iframe[src*="drive.google.com/file"] {
        min-height: 300px;
    }
    
    .content_box iframe[src*="docs.google.com/presentation"],
    .html_block.post iframe[src*="docs.google.com/presentation"] {
        min-height: 220px;
    }
    
    .content_box iframe[src*="docs.google.com/spreadsheets"],
    .html_block.post iframe[src*="docs.google.com/spreadsheets"] {
        height: 600px;
        min-height: 400px;
    }
    
    /* Таблицы на мобильных */
    .content_box table,
    .html_block.post table {
        font-size: 12px;
    }
    
    .content_box table th,
    .content_box table td,
    .html_block.post table th,
    .html_block.post table td {
        padding: 6px 8px;
    }
}

/* Очень маленькие экраны */
@media (max-width: 480px) {
    .content_box iframe[src*="docs.google.com/document"],
    .html_block.post iframe[src*="docs.google.com/document"],
    .entry_spoiler .post.spoiler iframe[src*="docs.google.com/document"] {
        height: 600px !important;
        min-height: 400px;
    }
}

/* Убираем фиксированную ширину у всех элементов */
.content_box *,
.html_block.post * {
    box-sizing: border-box;
}

/* Контейнер для region3 - ограничиваем ширину */
#region3 {
    max-width: 100%;
    overflow-x: hidden;
}

#region_3 {
    max-width: 100%;
    overflow-x: hidden;
    min-width: 0;
}

/* ============================================
   ИСПРАВЛЕНИЕ НАЛОЖЕНИЯ ФОНОВЫХ КАРТИНОК
   ============================================ */

/* Сброс всех позиционирований на мобильных */
@media (max-width: 768px) {
    /* Основной контейнер спойлера */
    .entry_spoiler.excerpt {
        position: relative !important;
        overflow: visible !important;
        clear: both !important;
    }
    
    /* Иконка слева - на всю ширину сверху */
    .entry_spoiler .excerpt_preview {
        float: none !important;
        width: 100% !important;
        position: relative !important;
        border-right: none !important;
        border-bottom: 3px solid var(--accent-orange) !important;
        padding: 15px !important;
        min-height: auto !important;
        margin: 0 !important;
        z-index: 1 !important;
        display: block !important;
    }
    
    .entry_spoiler .excerpt_preview img {
        width: 40px !important;
        height: 40px !important;
        margin: 0 auto !important;
        display: block !important;
        position: relative !important;
        float: none !important;
    }
    
    /* Контент под иконкой */
    .entry_spoiler .excerpt_content {
        margin-left: 0 !important;
        padding: 15px 20px !important;
        position: relative !important;
        z-index: 2 !important;
        clear: both !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Заголовок в контенте */
    .entry_spoiler .excerpt_content h2 {
        margin: 0 0 15px 0 !important;
        padding: 0 !important;
        position: relative !important;
        z-index: 2 !important;
    }
    
    /* Кнопка */
    .entry_spoiler .show-hide {
        position: relative !important;
        z-index: 2 !important;
        display: inline-flex !important;
    }
    
    /* Скрытый контент спойлера */
    .entry_spoiler .post.spoiler {
        position: relative !important;
        z-index: 2 !important;
        clear: both !important;
        margin: 15px -15px -15px -15px !important;
        padding: 15px !important;
        width: calc(100% + 30px) !important;
        overflow: visible !important;
    }
    
    /* Все картинки внутри контента */
    .entry_spoiler .post.spoiler img,
    .content_box img,
    .html_block.post img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
        margin: 15px auto !important;
        position: relative !important;
        float: none !important;
        clear: both !important;
        z-index: 1 !important;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
    }
    
    /* Картинки с inline стилями */
    .entry_spoiler .post.spoiler img[style],
    .content_box img[style],
    .html_block.post img[style] {
        position: relative !important;
        float: none !important;
        margin: 15px auto !important;
    }
    
    /* Iframe'ы */
    .entry_spoiler .post.spoiler iframe,
    .content_box iframe,
    .html_block.post iframe {
        max-width: 100% !important;
        width: 100% !important;
        display: block !important;
        margin: 15px auto !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    /* Таблицы */
    .entry_spoiler .post.spoiler table,
    .content_box table,
    .html_block.post table {
        display: block !important;
        overflow-x: auto !important;
        width: 100% !important;
        max-width: 100% !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    /* Параграфы и текст */
    .entry_spoiler .post.spoiler p,
    .content_box p,
    .html_block.post p {
        position: relative !important;
        z-index: 2 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
    }
}

/* Очень маленькие экраны */
@media (max-width: 480px) {
    .entry_spoiler .excerpt_preview {
        padding: 10px !important;
    }
    
    .entry_spoiler .excerpt_preview img {
        width: 32px !important;
        height: 32px !important;
    }
    
    .entry_spoiler .excerpt_content {
        padding: 10px 15px !important;
    }
    
    .entry_spoiler .post.spoiler {
        margin: 10px -10px -10px -10px !important;
        padding: 10px !important;
    }
}

/* Убираем все background-image которые могут мешать */
.entry_spoiler.excerpt,
.entry_spoiler .excerpt_preview,
.entry_spoiler .excerpt_content {
    background-image: none !important;
}

/* Если есть псевдоэлементы с фонами */
.entry_spoiler.excerpt::before,
.entry_spoiler.excerpt::after,
.entry_spoiler .excerpt_preview::before,
.entry_spoiler .excerpt_preview::after,
.entry_spoiler .excerpt_content::before,
.entry_spoiler .excerpt_content::after {
    display: none !important;
}

/* =========================================================
   УЧЕБНО-МЕТОДИЧЕСКИЕ ОБЪЕДИНЕНИЯ
   КАРТОЧКИ ПРЕПОДАВАТЕЛЕЙ + ФИЛЬТР
   ========================================================= */


/* =========================================================
   1. ФИЛЬТР ПО КАФЕДРАМ
   ========================================================= */

.content_box .filter {
    width: 100%;
    margin: 0 0 32px;
}

.content_box .filter-button-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;

    width: 100%;
}


/* Кнопка фильтра */
.content_box .filter-button-group button {
    appearance: none;
    -webkit-appearance: none;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 42px;
    padding: 10px 17px;

    margin: 0;

    background: #fff;

    border: 1px solid #d8e2e9;
    border-radius: 7px;

    color: var(--primary-blue);

    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;

    text-align: center;
    text-decoration: none;

    cursor: pointer;

    box-shadow: none;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


/* Наведение */
.content_box .filter-button-group button:hover {
    background: #fffaf4;

    border-color: var(--accent-orange);

    color: var(--accent-orange);

    transform: translateY(-1px);

    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.06);
}


/* Активная кафедра */
.content_box .filter-button-group button.active {
    background: var(--primary-blue);

    border-color: var(--primary-blue);

    color: #fff;

    box-shadow: 0 3px 8px rgba(30, 90, 135, 0.18);
}


.content_box .filter-button-group button.active:hover {
    background: var(--accent-orange);

    border-color: var(--accent-orange);

    color: #fff;
}


/* Фокус с клавиатуры */
.content_box .filter-button-group button:focus-visible {
    outline: 2px solid var(--accent-orange);
    outline-offset: 2px;
}



/* =========================================================
   2. СЕТКА ПРЕПОДАВАТЕЛЕЙ
   ========================================================= */

/*
 * Здесь !important специально.
 *
 * Старый Isotope может прописывать:
 * position:absolute;
 * transform:translate(...);
 * height;
 *
 * Поэтому забираем расположение карточек под CSS Grid.
 */

.content_box .team-listing {
    display: grid !important;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 28px;

    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    min-height: 0 !important;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    overflow: visible !important;

    box-sizing: border-box;
}



/* =========================================================
   3. КАРТОЧКА ПРЕПОДАВАТЕЛЯ
   ========================================================= */

.content_box .team-listing .team-item {
    display: block !important;

    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    min-height: 0 !important;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;

    transform: none !important;

    opacity: 1 !important;
    visibility: visible !important;

    background: #fff;

    border: 1px solid #e9edf0;
    border-radius: 9px;

    overflow: hidden;

    box-shadow:
        0 3px 12px rgba(0, 0, 0, 0.06);

    box-sizing: border-box;

    transition:
        box-shadow 0.25s ease,
        transform 0.25s ease,
        border-color 0.25s ease;
}


/* Наведение на карточку */
.content_box .team-listing .team-item:hover {
    transform: translateY(-4px) !important;

    border-color: rgba(30, 90, 135, 0.18);

    box-shadow:
        0 9px 25px rgba(30, 90, 135, 0.13);
}



/* =========================================================
   4. СКРЫТИЕ ПРИ ФИЛЬТРАЦИИ
   ========================================================= */

/*
 * Этот класс добавляет наш JS.
 */
.content_box .team-listing .team-item.filter-hidden {
    display: none !important;
}



/* =========================================================
   5. ОБЁРТКА ФОТО + ТЕКСТА
   ========================================================= */

/*
 * ВАЖНО:
 *
 * В Web Perspective внутри team-listing_wr-photo лежат:
 *
 * - сама фотография;
 * - контейнер с ФИО;
 * - должность;
 * - декоративный overlay.
 *
 * Поэтому НЕЛЬЗЯ ставить сюда aspect-ratio
 * и НЕЛЬЗЯ ставить overflow:hidden.
 */

.content_box .team-listing_wr-photo {
    display: block !important;

    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    min-height: 0 !important;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;

    overflow: visible !important;

    opacity: 1 !important;
    visibility: visible !important;

    background: #fff;

    box-sizing: border-box;
}



/* =========================================================
   6. ОБЛАСТЬ ФОТОГРАФИИ
   ========================================================= */

/*
 * Пропорции фиксируем ТОЛЬКО здесь.
 *
 * Все фотографии будут одинакового размера,
 * независимо от размера исходника.
 */

.content_box .team-listing_photo {
    display: block !important;

    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;

    aspect-ratio: 4 / 5;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;

    overflow: hidden !important;

    background: #f3f6f8;

    border-radius: 0;

    box-sizing: border-box;
}



/* =========================================================
   7. САМА ФОТОГРАФИЯ
   ========================================================= */

.content_box .team-listing_photo img {
    display: block !important;

    width: 100% !important;
    max-width: none !important;

    height: 100% !important;
    max-height: none !important;

    margin: 0 !important;
    padding: 0 !important;

    position: absolute !important;

    top: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    left: 0 !important;

    float: none !important;

    object-fit: cover;

    /*
     * Лица обычно находятся ближе к верхней части
     * фотографии, поэтому не центрируем строго.
     */
    object-position: center top;

    border: none !important;
    border-radius: 0 !important;

    box-shadow: none !important;

    transform: none !important;

    opacity: 1 !important;
    visibility: visible !important;
}



/* =========================================================
   8. ТЕКСТ ПОД ФОТОГРАФИЕЙ
   ========================================================= */

.content_box .team-listing_container {
    display: block !important;

    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    min-height: 0 !important;

    margin: 0 !important;

    padding: 18px 20px 21px !important;

    position: relative !important;

    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;

    float: none !important;

    transform: none !important;

    opacity: 1 !important;
    visibility: visible !important;

    background: #fff;

    box-sizing: border-box;

    z-index: 2;
}



/* =========================================================
   9. ФИО ПРЕПОДАВАТЕЛЯ
   ========================================================= */

.content_box .team-listing_name {
    display: block !important;

    width: 100% !important;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    color: var(--primary-blue) !important;

    font-family: inherit;

    font-size: 17px !important;
    font-weight: 700 !important;

    line-height: 1.35 !important;

    opacity: 1 !important;
    visibility: visible !important;

    text-align: left;

    box-sizing: border-box;
}


.content_box .team-listing_name a {
    display: inline !important;

    margin: 0 !important;
    padding: 0 !important;

    color: var(--primary-blue) !important;

    font-family: inherit;

    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;

    text-decoration: none !important;

    opacity: 1 !important;
    visibility: visible !important;

    transition: color 0.2s ease;
}


.content_box .team-listing_name a:hover {
    color: var(--accent-orange) !important;

    text-decoration: none !important;
}



/* =========================================================
   10. ОРАНЖЕВАЯ ПОЛОСКА
   ========================================================= */

.content_box .team-divider {
    display: block !important;

    width: 42px !important;
    height: 3px !important;

    min-height: 3px !important;

    margin: 12px 0 !important;
    padding: 0 !important;

    position: relative !important;

    background: var(--accent-orange) !important;

    border: none !important;
    border-radius: 2px;

    opacity: 1 !important;
    visibility: visible !important;
}



/* =========================================================
   11. ДОЛЖНОСТЬ
   ========================================================= */

.content_box .team-listing_position {
    display: block !important;

    width: 100% !important;

    margin: 0 !important;
    padding: 0 !important;

    position: relative !important;

    color: var(--text-light) !important;

    font-family: inherit;

    font-size: 14px !important;
    font-weight: 400 !important;

    line-height: 1.5 !important;

    text-align: left;

    opacity: 1 !important;
    visibility: visible !important;

    box-sizing: border-box;
}



/* =========================================================
   12. СТАРЫЙ OVERLAY WEB PERSPECTIVE
   ========================================================= */

/*
 * Старому шаблону он нужен был для эффектов поверх фото.
 * Сейчас только мешает.
 */

.content_box .team-listing_photo-overflow {
    display: none !important;

    width: 0 !important;
    height: 0 !important;

    opacity: 0 !important;
    visibility: hidden !important;

    pointer-events: none !important;
}



/* =========================================================
   13. ЗАЩИТА ОТ ОБЩИХ СТИЛЕЙ КАРТИНОК CMS
   ========================================================= */

/*
 * В основном CSS сайта есть общие правила вроде:
 *
 * .content_box img {
 *     width: 100%;
 *     height: auto;
 * }
 *
 * Поэтому специально перебиваем их.
 */

.content_box .team-listing .team-listing_photo img,
.content_box .team-listing_wr-photo .team-listing_photo img {
    width: 100% !important;
    height: 100% !important;

    min-width: 100% !important;
    min-height: 100% !important;

    object-fit: cover !important;
    object-position: center top !important;

    margin: 0 !important;
}



/* =========================================================
   14. ПЛАНШЕТ
   ========================================================= */

@media (max-width: 1000px) {

    .content_box .team-listing {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        gap: 22px;
    }


    .content_box .filter {
        margin-bottom: 28px;
    }


    .content_box .filter-button-group {
        gap: 8px;
    }


    .content_box .filter-button-group button {
        min-height: 40px;

        padding: 9px 14px;

        font-size: 13px;
    }
}



/* =========================================================
   15. МОБИЛЬНЫЕ
   ========================================================= */

@media (max-width: 650px) {

    /* Одна карточка в строке */

    .content_box .team-listing {
        grid-template-columns: 1fr;

        gap: 20px;
    }


    /* Фильтры */

    .content_box .filter {
        margin-bottom: 24px;
    }


    .content_box .filter-button-group {
        gap: 7px;
    }


    .content_box .filter-button-group button {
        min-height: 38px;

        padding: 8px 11px;

        border-radius: 6px;

        font-size: 12px;
    }


    /* Карточка */

    .content_box .team-listing .team-item {
        width: 100% !important;
    }


    /*
     * Всё ещё сохраняем одинаковые пропорции фотографий.
     */
    .content_box .team-listing_photo {
        aspect-ratio: 4 / 5;
    }


    /* Подпись */

    .content_box .team-listing_container {
        padding: 16px 17px 18px !important;
    }


    .content_box .team-listing_name {
        font-size: 16px !important;
    }


    .content_box .team-listing_position {
        font-size: 13px !important;
    }


    .content_box .team-divider {
        margin: 10px 0 !important;
    }
}



/* =========================================================
   16. ОЧЕНЬ МАЛЕНЬКИЕ ЭКРАНЫ
   ========================================================= */

@media (max-width: 420px) {

    .content_box .filter-button-group button {
        padding: 8px 10px;

        font-size: 11px;
    }


    .content_box .team-listing_container {
        padding: 14px 15px 17px !important;
    }


    .content_box .team-listing_name {
        font-size: 15px !important;
    }
}

/* =========================================================
   FIX: СПОЙЛЕРЫ НА МОБИЛЬНЫХ НЕ ОБРЕЗАЮТСЯ
   ========================================================= */

@media (max-width: 768px) {

    /* Сам спойлер не имеет права ограничивать высоту */
    .entry.entry_spoiler.excerpt {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }

    .entry.entry_spoiler.excerpt .excerpt_content {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }

    /* Раскрытый контент */
    .entry.entry_spoiler.excerpt .post.spoiler {
        height: auto !important;
        max-height: none !important;

        width: 100% !important;
        margin: 15px 0 0 0 !important;
        padding: 15px !important;

        box-sizing: border-box !important;

        overflow: visible !important;
    }

    /* ВАЖНО: таблица должна оставаться таблицей */
    .entry.entry_spoiler.excerpt .post.spoiler table {
        display: table !important;

        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;

        height: auto !important;
        max-height: none !important;

        table-layout: auto !important;

        overflow: visible !important;
    }

    .entry.entry_spoiler.excerpt .post.spoiler tbody {
        display: table-row-group !important;
    }

    .entry.entry_spoiler.excerpt .post.spoiler tr {
        display: table-row !important;
    }

    .entry.entry_spoiler.excerpt .post.spoiler td,
    .entry.entry_spoiler.excerpt .post.spoiler th {
        display: table-cell !important;

        min-width: 0 !important;

        white-space: normal !important;
        word-wrap: break-word !important;
        overflow-wrap: anywhere !important;
    }
}