/* Global Styles */
:root {
    --primary-dark-blue: rgb(85,85,199);
    --secondary-beige: #f5f2e6;
    --accent-orange: #f89c31;
    --text-dark: #333333;
    --text-light: #ffffff;
}

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

body {
    font-family: 'Segoe UI', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

a {
    text-decoration: none;
    color: var(--primary-dark-blue);
    transition: all 0.3s ease;
}

a:hover {
    color: var(--accent-orange);
}

ul {
    list-style: none;
}

header {
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 28px 0; 
}

.logo {
    display: flex;
    align-items: center;
    gap: 0px;
    position: relative; 
}

.logo .titles-wrapper {
    position: relative; 
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0; 
    margin-top: 8px; 
}

.logo img {
    max-height: 120px;
    margin-right: 0;
}

.logo a { 
    flex-shrink: 0; 
}

.logo h1 {
    display: block;
    font-size: 22px;
    margin: 0; 
    padding: 0; 
    line-height: 1; 
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    color: rgb(51,51,153);
    font-weight: 400;
    text-transform: uppercase;
}

/* Подзаголовок под логотипом */
.logo .site-subtitle {
    position: absolute; 
    top: calc(100% + 3px); 
    left: 0; 
    font-size: 11px; 
    line-height: 1;
    margin: 0;
    padding: 0;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    color: rgb(51,51,153);
    font-weight: 400;
    text-transform: uppercase;
}

.logo .site-subtitle .cap { font-size: 1.3em; }

.top-nav {
    display: flex;
    gap: 20px;
}

.top-nav-links {
    display: flex;
    gap: 20px;
    align-items: center;
}

.top-nav a {
    font-size: 13px; 
    font-weight: 400; 
    color: rgb(51,51,153);
    text-transform: uppercase;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}
.top-nav a:hover { color: var(--accent-orange); }

.nav-right {
    display: flex;
    gap: 20px;
}

.nav-right a {
    font-size: 13px;
    font-weight: 400;
    color: rgb(51,51,153);
    text-transform: uppercase;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

.nav-right a:hover { color: var(--accent-orange); }

.nav-right a.active {
    color: var(--accent-orange);
}

/* Активные состояния для заголовков в шапке на основе класса body */
body.page-news .nav-right a[href*="news"] {
    color: var(--accent-orange);
}

body.page-contacts .nav-right a[href*="contacts"] {
    color: var(--accent-orange);
}

.main-nav {
    margin: 10px 0;
}

.main-nav ul {
    display: flex;
    gap: 20px;
}

.main-nav li {
    position: relative;
    margin-right: 15px;
}

.main-nav a {
    display: block;
    padding: 10px 0;
    font-weight: 400;
    font-size: 15px;
    color: rgb(51,51,153);
    text-transform: uppercase;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}
.main-nav a:hover { color: var(--accent-orange); }

/* Увеличенная первая буква в пунктах шапки (селектируемая через текст) */
.main-nav a::first-letter,
.top-nav a::first-letter {
    font-size: 1.3em;
    color: inherit;
    font-weight: inherit;
}

/* Стили для домика и активных элементов */
.main-nav ul li.home {
    margin-right: 10px;
}
.main-nav ul li.home a {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 10px;
    border-radius: 4px;
    margin-top: 3px;
    font-weight: 700;
}
.main-nav ul li.home.active a svg {
    fill: var(--accent-orange) !important;
    stroke: var(--accent-orange) !important;
}
.main-nav ul li.active > a {
    color: var(--accent-orange);
}
.main-nav ul li.home a:hover {
    background-color: rgba(0, 0, 0, 0.05);
}
.main-nav ul li.home.active a {
    background-color: rgba(255, 152, 0, 0.1);
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #fff;
    min-width: 100%; 
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    z-index: 1;
    border-radius: 4px;
    padding: 10px 0;
}

.dropdown-content a {
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 400;
    color: rgb(51,51,153);
    text-transform: uppercase;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    display: block;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
    line-height: 1.3;
}
.dropdown-content a:hover { color: var(--accent-orange); }

.dropdown:hover .dropdown-content {
    display: block !important;
}

.color-strip {
    height: 5px;
    background-color: var(--accent-orange);
    margin-top: 10px;
}

main {
    min-height: 500px;
    padding: 40px 0;
}

.hero {
    background-color: var(--secondary-beige);
    padding: 40px;
    margin-bottom: 30px;
    border-radius: 4px;
}

.hero h2 {
    color: var(--primary-dark-blue);
    margin-bottom: 15px;
}

.site-search {
    display: flex;
    margin-top: 25px;
    max-width: 600px;
}

.site-search input[type="text"] {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    font-size: 16px;
    font-family: 'Segoe UI', sans-serif;
}

.search-button {
    background-color: var(--primary-dark-blue);
    color: white;
    border: none;
    padding: 0 20px;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.search-button:hover {
    background-color: var(--accent-orange);
}

.search-results {
    margin-top: 20px;
}

.search-result-item {
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

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

.search-result-item h3 {
    margin-bottom: 8px;
}

.search-result-item p {
    margin-bottom: 5px;
    color: #555;
}

.featured-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    margin-top: 30px;
}

.breadcrumbs {
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--text-dark);
}

.breadcrumbs a {
    color: var(--primary-dark-blue);
}

.breadcrumbs a:hover {
    color: var(--accent-orange);
}

/* Page Header */
.page-header {
    margin-bottom: 0;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
}

.page-header-image {
    margin-bottom: 0;
    width: 100%;
}

.page-header-image img {
    width: 100%;
    height: 325px;
    object-fit: cover;
    border-radius: 0;
}

/* Универсальное смещение баннеров (под шапкой фото) для всех страниц до 499px - сделано чтобы центрировать объекты фото */
@media (max-width: 499px) {
    .page-header-image {
        margin-left: calc(-50vw + 50% - 60px) !important;
        width: calc(100vw + 60px) !important;
    }
    
    /* Исключение для некоторых баннеров страниц */
    .no-banner-shift .page-header-image {
        margin-left: calc(-50vw + 50%) !important;
        width: 100vw !important;
    }
}

.page-title {
    color: var(--primary-dark-blue);
    font-size: 32px;
    margin-top: 6px; 
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-orange);
}

.content {
    margin-bottom: 40px;
}

.subcategories {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.subcategory-card {
    background-color: var(--secondary-beige);
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.subcategory-card h2 {
    color: var(--primary-dark-blue);
    margin-bottom: 15px;
    font-size: 20px;
}

.subcategory-card p {
    margin-bottom: 20px;
}

.button {
    display: inline-block;
    background-color: var(--primary-dark-blue);
    color: var(--text-light);
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: bold;
    transition: all 0.3s ease;
    outline: none;
    border: none;
}

.button:hover {
    background-color: var(--accent-orange);
    color: var(--text-light);
}

.direction-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-top: 30px;
    margin-bottom: 60px; 
}

.direction-item {
    display: flex;
    flex-direction: column;
    margin-bottom: 30px;
    background-color: var(--secondary-beige);
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.direction-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.direction-item-content {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    padding: 20px;
    position: relative;
}

.direction-item-image {
    flex: 0 0 200px;
    height: 150px;
    overflow: hidden;
    border-radius: 4px;
    position: relative;
}

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

.direction-item-separator {
    width: 4px;
    height: 150px;
    background-color: var(--accent-orange);
    position: relative;
    flex: 0 0 4px;
}

.direction-item-title {
    flex: 1;
}

.direction-item-title h2 {
    color: rgb(51,51,153); 
    margin-bottom: 15px;
    font-size: 24px; 
    font-weight: bold;
}

/* Первая буква заголовков статей: делаем больше через реальный элемент, чтобы буква была выделяема */
.cap-first {
    font-size: 0.90em; 
    color: inherit;
    font-weight: inherit;
    line-height: 1;
    display: inline;
}

/* Нейтральное оформление первой буквы: без увеличения и с наследованием цвета */
.initial-cap::first-letter {
    color: inherit;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    margin-right: 0;
}

/* Универсальный класс для заглавных букв в заголовках */
.cap {
    font-size: 1.3em;
    color: inherit;
}

.direction-item-title p {
    margin-bottom: 15px;
}

.direction-item-link {
    display: inline-block;
    padding: 8px 15px;
    background-color: var(--primary-dark-blue);
    color: #fff;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.direction-item-link:hover {
    background-color: var(--accent-orange);
}

@media (max-width: 767px) {
    .direction-item-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .direction-item-image {
        flex: 0 0 auto;
        width: 100%;
        margin-bottom: 15px;
    }
    
    .direction-item-separator {
        width: 100%;
        height: 4px;
        margin: 5px 0 15px;
        flex: 0 0 4px;
    }
}

.info-block {
    background-color: var(--secondary-beige);
    padding: 30px;
    border-radius: 4px;
    margin-bottom: 30px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.info-block h2 {
    color: var(--primary-dark-blue);
    margin-bottom: 20px;
    font-size: 24px;
    border-bottom: 2px solid var(--accent-orange);
    padding-bottom: 10px;
}

.coming-soon {
    background-color: #fff;
    padding: 25px;
    border-radius: 4px;
    border-left: 4px solid var(--accent-orange);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.coming-soon h3 {
    color: var(--primary-dark-blue);
    margin-bottom: 15px;
    font-size: 20px;
}

.coming-soon ul {
    list-style: disc;
    padding-left: 20px;
}

.coming-soon ul li {
    margin-bottom: 10px;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info h2,
.contact-form h2 {
    color: var(--primary-dark-blue);
    margin-bottom: 20px;
    font-size: 24px;
    border-bottom: 2px solid var(--accent-orange);
    padding-bottom: 10px;
}

.contact-details {
    margin-top: 30px;
}

.contact-item {
    margin-bottom: 20px;
}

.contact-item h3 {
    color: var(--primary-dark-blue);
    margin-bottom: 5px;
    font-size: 18px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Segoe UI', sans-serif;
    font-size: 16px;
}

.form-group textarea {
    resize: vertical;
}

.success-message {
    background-color: rgba(0, 58, 93, 0.1);
    padding: 20px;
    border-radius: 4px;
    border-left: 4px solid var(--accent-orange);
    margin-top: 20px;
}

.success-message ul {
    list-style: none;
    padding: 0;
    margin-top: 15px;
}

.success-message ul li {
    margin-bottom: 8px;
}

@media (max-width: 767px) {
    .contact-layout {
        grid-template-columns: 1fr;
    }
}

/* Footer Styles */
footer {
    margin-top: -75px; 
    background-color: var(--primary-dark-blue);
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

.slant-color-insert {
    position: relative;
    padding: 30px 0 10px;
    background-color: var(--primary-dark-blue);
    clip-path: polygon(0 15%, 100% 0, 100% 100%, 0 100%);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.site-map {
    margin-bottom: -5px;
}

.site-map h3 {
    margin-bottom: 15px;
    color: rgb(248,156,49);
    text-transform: none;
    font-size: 1.15rem;
    font-weight: 400;
    font-family: 'Segoe UI';
    position: relative; 
    z-index: 2;
    padding-top: 10px; 
}

.site-map ul li {
    margin-bottom: 8px;
    font-family: 'Segoe UI';
    font-size: 1rem;
    font-weight: 400;
}

.site-map a {
    color: var(--text-light);
}

.site-map a:hover {
    color: var(--accent-orange);
}

.copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    margin-top: 20px;
    text-align: center;
    font-size: 14px;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .header-top {
        flex-direction: column;
    }
    
    .logo {
        margin-bottom: 20px;
    }
    
    .main-nav ul {
        flex-direction: column;
    }
    
    .dropdown-content {
        position: static;
        box-shadow: none;
        padding-left: 20px;
    }
    
    .dropdown:hover .dropdown-content {
        display: none;
    }
    
    .dropdown.active .dropdown-content {
        display: block;
    }
}

/* Добавляем стили для ПК версии выпадающего меню */
@media (min-width: 992px) {
    .dropdown-content a {
        padding: 10px 20px; 
    }
}

@media (max-width: 767px) {
    .footer-content {
        flex-direction: column;
    }
    
    .hero {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .logo h1 { font-size: 18px; }
    .logo .site-subtitle { font-size: 9px; } /* 18px / 2 */
    
    .top-nav {
        flex-direction: column;
        gap: 10px;
    }
}

/* Стили для отдельных страниц статей */
.article-content {
    padding: 30px 0;
}

.article-description {
    background-color: var(--secondary-beige);
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 30px;
    border-left: 4px solid var(--accent-orange);
}

.article-text {
    line-height: 1.6;
}

.article-text h2 {
    color: rgb(51,51,153); 
    margin: 30px 0 20px;
    font-size: 24px;
    font-weight: bold;
    border-bottom: 2px solid var(--accent-orange);
    padding-bottom: 10px;
    display: inline-block;
}

.article-text p {
    margin-bottom: 15px;
}

.article-text em {
    color: var(--primary-dark-blue);
    font-style: italic;
}

/* Стили для кнопки перехода к следующему разделу */
.next-section-link {
    margin: 30px 0;
    text-align: left;
}

.next-section-link a {
    display: inline-flex;
    background-color: var(--secondary-beige);
    border: 1px solid #e0ddd0;
    border-radius: 6px;
    padding: 0;
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    max-width: 350px;
}

.next-section-link a:hover {
    background-color: #f0ece0;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.next-section-content {
    display: flex;
    align-items: center;
    padding: 12px 18px;
}

.next-section-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: var(--primary-dark-blue);
    border-radius: 50%;
    margin-right: 14px;
    flex-shrink: 0;
}

.next-section-icon svg {
    color: white;
    width: 18px;
    height: 18px;
}

.next-section-text {
    flex: 1;
    text-align: left;
}

.next-section-text span {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 2px;
}

.next-section-text h4 {
    font-size: 15px;
    font-weight: bold;
    color: rgb(51,51,153); 
    margin: 0;
}

@media (max-width: 600px) {
    .next-section-content {
        padding: 10px;
    }
    
    .next-section-icon {
        width: 28px;
        height: 28px;
        margin-right: 10px;
    }
    
    .next-section-icon svg {
        width: 16px;
        height: 16px;
    }
    
    .next-section-text h4 {
        font-size: 14px;
    }
    
    .next-section-link {
        text-align: center;
    }
}

.bibliography-block {
    margin-top: 32px;
    margin-bottom: 0;
    background: var(--accent-orange);
    border-radius: 6px;
    padding: 0;
    overflow: hidden;
} 

.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 30px 0 40px;
}

.article-authors-block {
    margin: 0;
    text-align: right;
}

.bibliography-block {
    margin-top: 32px;
    background: transparent; 
    border-radius: 6px;
    padding: 0;
    overflow: hidden;
    margin-bottom: 24px;
}
.bibliography-title {
    background: var(--accent-orange);
    color: #fff;
    font-family: Segoe UI;
    font-weight: 400;
    font-size: 1.2rem;
    padding: 4px 24px 4px 24px;
    letter-spacing: 1px;
}
.bibliography-list {
    background: #fff;
    color: #222;
    font-family: Segoe UI;
    font-size: 0.9rem;
    padding: 18px 24px 18px 24px;
    border-radius: 0 0 6px 6px;
}
.bibliography-list ol {
    margin: 0;
    padding-left: 22px;
}
.bibliography-list li {
    margin: 0px;
    line-height: 1.1;
}

.next-section-link {
    margin: 0;
    text-align: left;
}

/* Стили для кнопки перехода к следующему разделу */
.next-section-link a {
    display: inline-flex;
    background-color: var(--secondary-beige);
    border: 1px solid #e0ddd0;
    border-radius: 6px;
    padding: 0;
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    max-width: 320px;
}

@media (max-width: 768px) {
    .article-footer {
        flex-direction: column;
        align-items: flex-end;
    }
    
    .article-authors-block {
        margin-top: 20px;
        text-align: right;
        width: 100%;
    }
    
    .next-section-link {
        text-align: left;
        width: 100%;
    }
    
    .next-section-link a {
        width: 100%;
        max-width: none;
    }
} 

/* Стили для двухколоночной структуры с боковой навигацией */
.content-with-sidebar {
    display: flex;
    gap: 30px;
    margin-top: 20px;
    margin-bottom: 60px;
}

.sidebar {
    flex: 0 0 250px;
    background-color: var(--secondary-beige);
    border-radius: 6px;
    padding: 15px 0;
    align-self: flex-start;
    position: sticky;
    top: 20px;
}

.sidebar-title {
    display: none; 
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li {
    padding: 0;
    margin: 0;
}

.sidebar-nav a {
    display: block;
    padding: 10px 20px;
    color: var(--primary-dark-blue);
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    font-size: 15px; 
    line-height: 1.4;
}

.sidebar-nav a:hover {
    background-color: rgba(0, 58, 93, 0.05);
    border-left-color: var(--accent-orange);
}

.sidebar-nav a.active {
    background-color: rgba(0, 58, 93, 0.08);
    border-left-color: var(--accent-orange);
    font-weight: bold;
}

.main-content {
    flex: 1;
}

@media (max-width: 991px) {
    .content-with-sidebar {
        flex-direction: column;
    }
    
    .sidebar {
        flex: 0 0 auto;
        width: 100%;
        position: static;
        margin-bottom: 30px;
    }
}

/* Стили для списка направлений */
.direction-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-top: 30px;
    margin-bottom: 60px; 
}

.page-header {
    margin-bottom: 0;
}

.page-header-image {
    margin-bottom: 0;
}

.page-title {
    margin-top: 6px; 
} 

/* Стили для поисковой формы */
.search-container {
    display: flex;
    align-items: center;
    margin-left: 15px;
}

.search-container form {
    display: flex;
    align-items: center;
    position: relative;
}

.search-container input[type="text"] {
    padding: 6px 10px;
    padding-right: 30px;
    border: 1px solid rgb(166,22,118);
    border-radius: 4px;
    font-size: 14px;
    width: 150px;
    transition: all 0.3s;
}

.search-container input[type="text"]:focus {
    width: 180px;
    padding-right: 30px;
    border-color: rgb(166,22,118);
    outline: none;
}

.search-container input[type="text"]::placeholder {
    color: rgb(166,22,118); 
    opacity: 0.7; 
}

.search-container button {
    background: none;
    border: none;
    cursor: pointer;
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: rgb(166,22,118);
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
}

.search-container button:hover {
    color: rgb(166,22,118);
}

@media (max-width: 768px) {
    .search-container {
        margin-top: 10px;
        margin-left: 0;
        width: 100%;
    }
    
    .search-container form {
        width: 100%;
    }
    
    .search-container input[type="text"] {
        width: 100%;
    }
    
    .search-container input[type="text"]:focus {
        width: 100%;
    }
    
    .top-nav {
        flex-wrap: wrap;
    }
} 

/* Стили для раздела "СКОРО НА САЙТЕ" */
.coming-soon-section {
    margin-top: 40px;
    background-color: #fff;
    position: relative;
    z-index: 10;
    margin-bottom: 40px;
}

.coming-soon-title {
    font-size: 1.5rem;
    color: var(--accent-orange);
    margin-bottom: 20px;
    text-transform: uppercase;
    font-weight: normal;
} 

.sidebar-nav-item {
    margin-bottom: 5px;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    color: var(--primary-dark-blue);
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9rem; 
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    position: relative;
}

/* Стиль для текстовых элементов меню без ссылок и стрелок */
.sidebar-nav-text {
    display: block;
    padding: 10px 15px;
    color: var(--primary-dark-blue);
    font-weight: normal;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    cursor: default;
}

.sidebar-nav-text:hover {
    background-color: rgba(0, 58, 93, 0.05);
    border-left-color: var(--accent-orange);
}

.sidebar-nav-text.active {
    background-color: var(--accent-orange);
    color: white;
    border-left-color: var(--accent-orange);
}

.sidebar-nav-link::after {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-top: 2px solid var(--primary-dark-blue);
    border-right: 2px solid var(--primary-dark-blue);
    transform: rotate(45deg);
    position: absolute;
    right: 15px;
    top: 50%;
    margin-top: -3px;
    transition: all 0.2s ease;
}

.sidebar-nav-link:hover::after {
    border-color: var(--accent-orange);
}

.sidebar-nav-link:hover {
    background-color: rgba(0, 58, 93, 0.05);
    border-left-color: var(--accent-orange);
}

.sidebar-nav-link.active {
    background-color: var(--accent-orange);
    color: white;
    border-left-color: var(--accent-orange);
}

/* Стили для категорий в левой вставке содержания */
.sidebar-nav-category {
    margin-bottom: 5px;
}

.sidebar-nav-category-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 10px 15px;
    color: var(--primary-dark-blue);
    font-weight: bold;
    font-size: 0.9rem; 
    cursor: pointer;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
    position: relative;
}

.sidebar-nav-category-header:hover {
    background-color: rgba(0, 58, 93, 0.05);
    border-left-color: var(--accent-orange);
}

.sidebar-nav-category-header.active {
    background-color: var(--accent-orange);
    color: white;
    border-left-color: var(--accent-orange);
}

.sidebar-nav-category-header .arrow {
    width: 8px;
    height: 8px;
    border-right: 2px solid var(--primary-dark-blue);
    border-top: 2px solid var(--primary-dark-blue);
    transform: rotate(45deg);
    transition: transform 0.3s ease;
    position: absolute;
    right: 15px;
    top: 50%;
    margin-top: -4px;
    flex-shrink: 0;
}

.sidebar-nav-category-header.active .arrow {
    transform: rotate(135deg);
    border-right: 2px solid white;
    border-top: 2px solid white;
}

/* Специальный класс для длинных заголовков с переносом */
.sidebar-nav-category-header.multiline {
    flex-wrap: wrap;
    padding-right: 30px;
    position: relative;
}

.sidebar-nav-category-content {
    display: none;
    padding-left: 0;
}

.sidebar-nav-category-content.active {
    display: block;
}

.sidebar-nav-category-content a {
    display: block;
    padding: 8px 15px 8px 15px;
    color: var(--primary-dark-blue);
    text-decoration: none;
    font-size: 0.85rem; 
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    position: relative;
}

.sidebar-nav-category-content a:hover {
    background-color: rgba(0, 58, 93, 0.05);
    border-left-color: var(--accent-orange);
}

.sidebar-nav-category-content a::after {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-top: 2px solid var(--primary-dark-blue);
    border-right: 2px solid var(--primary-dark-blue);
    transform: rotate(45deg);
    position: absolute;
    right: 15px;
    top: 50%;
    margin-top: -3px;
    transition: all 0.2s ease;
}

.sidebar-nav-category-content a:hover::after {
    border-color: var(--accent-orange);
}

.sidebar-nav-category-content a.active {
    color: var(--accent-orange);
    background-color: transparent;
    border-left-color: transparent;
    font-weight: normal;
} 

/* Стили для левой вставки содержания */
.sidebar-nav-item.main-item {
    margin-bottom: 5px;
}

/* Специальный стиль для страницы "Всемирное сообщество лечащих эвритмистов" */
body.community .sidebar-nav-item.main-item {
    margin-bottom: 2px;
}

.sidebar-nav-item.main-item .sidebar-nav-link {
    font-size: 16px;
    font-weight: 500;
}

.sidebar-nav-item.sub-item,
.sidebar-nav-category.sub-item {
    margin-left: 15px;
    margin-bottom: 5px;
}

.sidebar-nav-item.sub-item .sidebar-nav-link,
.sidebar-nav-category.sub-item .sidebar-nav-category-header {
    font-size: 14px;
}

/* Активные состояния для левой вставки содержания в стиле Anthromedics */
.sidebar-nav-link.active {
    background-color: var(--accent-orange) !important;
    color: white !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: normal !important;
}

.sidebar-nav-category-header.active {
    background-color: var(--accent-orange) !important;
    color: white !important;
    border-left-color: var(--accent-orange) !important;
}

.sidebar-nav-category-header.active .arrow {
    border-right: 2px solid white !important;
    border-bottom: 2px solid white !important;
}

.sidebar-nav-category-content a.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: transparent !important;
    font-weight: normal !important;
}

.sidebar-nav-item.sub-item .sidebar-nav-link.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: transparent !important;
    font-weight: normal !important;
} 

/* Переопределение стилей для левого меню содержания */
.sidebar-nav-link.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: normal !important;
}

.sidebar-nav-category-header.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: var(--accent-orange) !important;
}

.sidebar-nav-category-content a.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: normal !important;
}

.sidebar-nav-item.sub-item .sidebar-nav-link.active {
    color: var(--accent-orange) !important;
    background-color: transparent !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: normal !important;
}

/* Стили для активных статей в разделе "Образование в России" */
body[class*="education"] .sidebar-nav-category-content a.active,
body[class*="community"] .sidebar-nav-link.active {
    color: var(--primary-dark-blue) !important;
    background-color: transparent !important;
    border-left-color: transparent !important;
    font-weight: normal !important;
}


/* Стиль для кнопки "Перейти" на плашках */
.read-more-btn, .direction-item-link {
    display: inline-block;
    padding: 8px 15px;
    background-color: var(--primary-dark-blue);
    color: #fff;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    transition: background-color 0.3s ease;
    margin-left: 24px;
}

.read-more-btn:hover, .direction-item-link:hover {
    background-color: var(--accent-orange);
    color: #fff;
}

/* Стиль для метки "В разработке" */
.in-development {
    display: inline-block;
    padding: 8px 16px;
    background-color: #e0e0e0;
    color: #666;
    border-radius: 4px;
    font-weight: bold;
    font-size: 14px;
    margin-left: 24px;
} 
/* Стили для раздела "О терапевтической эвритмии" с домиком */
.main-nav ul li.dropdown a svg {
    vertical-align: middle;
    margin-right: 8px;
    margin-top: 0 !important;
    flex-shrink: 0;
    position: relative;
    top: -5px !important;
    display: inline-block; 
}
.main-nav ul li.active > a {
    color: var(--accent-orange);
}
.main-nav ul li.active > a svg {
    fill: var(--accent-orange) !important;
    stroke: var(--accent-orange) !important;
}
.main-nav ul li.dropdown a:hover {
    color: var(--accent-orange);
    transition: color 0.3s ease;
}
.main-nav ul li.dropdown a:hover svg {
    fill: var(--accent-orange) !important;
    stroke: var(--accent-orange) !important;
    transition: fill 0.3s ease, stroke 0.3s ease;
}

/* Стиль заголовков в боковом меню без градиентных полосок */
.sidebar-nav-category-header {
    border-left: none;
    padding-bottom: 4px;
}

/* Заголовки результатов поиска: стиль как у главных заголовков навигации */
.search-result-item h3,
.search-result-item h3 a {
	text-transform: uppercase;
	font-weight: 400;
	color: rgb(51,51,153);
	font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

.search-result-item h3::first-letter,
.search-result-item h3 a::first-letter {
	font-size: 1.3em;
	color: inherit;
	font-weight: inherit;
	line-height: 1;
}

/* Результаты поиска: ссылки как в шапке */
.search-modal .search-results a {
	text-transform: uppercase !important;
	font-weight: 400 !important;
	color: rgb(51,51,153) !important;
	font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif !important;
}

.search-modal .search-results a:hover {
	color: var(--accent-orange) !important;
	text-decoration: underline !important;
}

.search-modal .search-results a .cap {
	font-size: 1.3em !important;
	font-weight: inherit !important;
	color: inherit !important;
	line-height: 1 !important;
	display: inline-block !important;
}
/* отключаем предыдущее увеличение первой буквы для модалки, чтобы не было двойного эффекта */
.search-modal .search-results a::first-letter { font-size: inherit !important; }

/* Стили для видео секции */
.video-section {
    margin: 40px 0;
}

.video-title {
    text-align: center;
    margin-bottom: 30px;
    color: var(--primary-dark-blue);
    font-size: 24px;
    font-weight: bold;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.video-item {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.video-preview {
    position: relative;
    width: 100%;
    height: 150px;
    overflow: hidden;
}

.video-preview iframe {
    width: 100%;
    height: 100%;
    border: none;
    object-fit: cover;
    pointer-events: none; 
}



.video-number {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--accent-orange);
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
}

.video-caption {
    padding: 15px;
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
    color: var(--text-dark);
    text-align: center;
}

/* Модальное окно для видео */
.video-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.video-modal-content {
    position: relative;
    width: 90%;
    max-width: 800px;
    margin: 5% auto;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

.video-close {
    position: absolute;
    top: 10px;
    right: 15px;
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
    background: rgba(0, 0, 0, 0.5);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.video-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

.video-modal iframe {
    width: 100%;
    height: 450px;
    border: none;
}

@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    .video-modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .video-modal iframe {
        height: 250px;
    }
}

/* Специальные стили для бокового меню раздела "Образование по терапевтической эвритмии" */
body.education .sidebar-nav-link {
    font-weight: bold !important;
    padding: 10px 15px !important;
    font-size: 14px !important; 
}

body.education .sidebar-nav-category-header {
    font-weight: bold !important;
    padding: 10px 15px !important;
    border-left: 3px solid transparent !important;
    font-size: 14px !important; 
}

body.education .sidebar-nav-category-content a {
    padding: 10px 15px 8px 15px !important;
    font-weight: normal !important;
    font-size: 14px !important; 
}

body.education .sidebar-nav-category.sub-item {
    margin-left: 0 !important;
}

body.education .sidebar-nav-link.active {
    background-color: var(--accent-orange) !important;
    color: white !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: bold !important;
}

body.education .sidebar-nav-category-content a.active {
    background-color: var(--accent-orange) !important;
    color: white !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: normal !important;
}

/* Стили для многострочных заголовков в боковом меню раздела "Образование" */
body.education .sidebar-nav-category-header.multiline {
    flex-wrap: wrap;
    padding-right: 30px;
    position: relative;
}

body.education .sidebar-nav-category-header.multiline .arrow {
    position: absolute;
    right: 15px;
    top: 10px;
}

.nowrap { white-space: nowrap; }

/* Убираем стрелочки у заголовков в боковом меню */
.sidebar-nav-item.sub-item .sidebar-nav-link::after {
    display: none;
}

/* Стили для стрелки в футере */
.footer-link-arrow {
    color: var(--accent-orange);
    font-weight: bold;
    margin-left: 4px;
    transition: all 0.3s ease;
    position: relative;
    display: inline-block;
    font-size: 0; 
}

.footer-link-arrow::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    border-left: 8px solid var(--accent-orange) !important;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    margin-left: 4px; 
    margin-top: -5px; 
}

body.page-education .sidebar-nav-link {
    font-weight: bold !important;
    padding: 10px 15px !important;
    font-size: 14px !important; 
}

body.page-education .sidebar-nav-category-header {
    font-weight: bold !important;
    padding: 10px 15px !important;
    border-left: 3px solid transparent !important;
    font-size: 14px !important;
}

body.page-education .sidebar-nav-category-content a {
    padding: 10px 15px 8px 15px !important;
    font-weight: normal !important;
    font-size: 14px !important; 
}

body.page-education .sidebar-nav-category.sub-item {
    margin-left: 0 !important;
}

/* Стили для активного состояния заголовков в боковом меню раздела "Образование" */
body.page-education .sidebar-nav-link.active {
    background-color: var(--accent-orange) !important;
    color: white !important;
    border-left-color: var(--accent-orange) !important;
    font-weight: bold !important;
}

body.page-education .sidebar-nav-category-content a.active {
    background-color: transparent !important;
    color: var(--accent-orange) !important;
    border-left-color: transparent !important;
    font-weight: normal !important;
}

/* Стили для многострочных заголовков в боковом меню раздела "Образование" */
body.page-education .sidebar-nav-category-header.multiline {
    flex-wrap: wrap;
    padding-right: 30px;
    position: relative;
}

body.page-education .sidebar-nav-category-header.multiline .arrow {
    position: absolute;
    right: 15px;
    top: 10px; 
}
