/* ===== СТИЛИ ДЛЯ СТРАНИЦЫ ГЛАВЫ (article-canon.css) ===== */

/* Базовые сбросы и настройки */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

@media (max-width: 768px) {
    html {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }
}

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    line-height: 1.7;
    color: #333;
    background-color: #f8f9fa;
    font-size: 1rem;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
        width: 100%;
    }
}

/* Типография для мобильных */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: #2c3e50;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

h1 {
    font-size: 2.8rem;
    text-align: center;
}

h2 {
    font-size: 2.2rem;
    color: #597d89;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
}

h3 {
    font-size: 1.8rem;
    color: #495057;
}

h4 {
    font-size: 1.4rem;
    color: #6c757d;
}

@media (max-width: 992px) {
    h1 {
        font-size: 2.4rem;
    }
    
    h2 {
        font-size: 1.9rem;
    }
    
    h3 {
        font-size: 1.5rem;
    }
    
    h4 {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    h2 {
        font-size: 1.7rem;
        line-height: 1.3;
    }
    
    h3 {
        font-size: 1.3rem;
    }
    
    h4 {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }
    
    h2 {
        font-size: 1.5rem;
        padding-bottom: 0.4rem;
        margin-bottom: 0.8rem;
    }
    
    h3 {
        font-size: 1.2rem;
    }
    
    h4 {
        font-size: 1rem;
    }
}

/* Основной текст */
p {
    margin-bottom: 1.5rem;
    text-align: justify;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

@media (max-width: 768px) {
    p {
        text-align: left;
        margin-bottom: 1.2rem;
        line-height: 1.6;
    }
}

a {
    text-decoration: none;
    color: #597d89;
    transition: all 0.3s ease;
    word-wrap: break-word;
}

a:hover {
    color: #4a6a75;
}

/* Кнопки */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 12px 30px;
    background-color: #597d89;
    color: white;
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    white-space: nowrap;
    min-height: 48px;
}

.btn:hover {
    background-color: #4a6a75;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    color: white;
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid #597d89;
    color: #597d89;
}

.btn-secondary:hover {
    background-color: #597d89;
    color: white;
}

.btn-small {
    padding: 8px 20px;
    font-size: 0.9rem;
    min-height: 40px;
}

@media (max-width: 768px) {
    .btn {
        padding: 10px 20px;
        font-size: 0.95rem;
        min-height: 44px;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .btn-small {
        padding: 8px 16px;
        font-size: 0.85rem;
        min-height: 38px;
    }
    
    .cta-buttons .btn {
        width: 100%;
        max-width: 250px;
    }
}

@media (max-width: 480px) {
    .btn {
        padding: 12px 16px;
        font-size: 0.9rem;
        min-height: 42px;
    }
}

/* ===== ОСНОВНОЙ КОНТЕНТ ГЛАВЫ ===== */

/* Контейнер для основного текста */
.chapter-text-container {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

/* Основные стили для текста главы */
.chapter-body {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
    width: 100%;
    padding: 0 10px;
}

/* Обычные параграфы (не в блоках) */
.chapter-body > p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
    text-align: justify;
}

/* Заголовки внутри основного текста */
.chapter-body > h2 {
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid #e9ecef;
    color: #597d89;
}

.chapter-body > h3 {
    margin-top: 2.5rem;
    margin-bottom: 1.2rem;
    color: #495057;
    font-size: 1.6rem;
}

.chapter-body > h4 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #6c757d;
    font-size: 1.3rem;
}

/* Мобильная адаптация основного текста */
@media (max-width: 768px) {
    .chapter-body > p {
        font-size: 1.05rem;
        line-height: 1.7;
        text-align: left;
    }
    
    .chapter-body > h2 {
        margin-top: 2.5rem;
        margin-bottom: 1.2rem;
        font-size: 1.7rem;
    }
    
    .chapter-body > h3 {
        margin-top: 2rem;
        margin-bottom: 1rem;
        font-size: 1.4rem;
    }
    
    .chapter-body > h4 {
        margin-top: 1.5rem;
        margin-bottom: 0.8rem;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .chapter-body > p {
        font-size: 1rem;
        line-height: 1.6;
    }
    
    .chapter-body > h2 {
        margin-top: 2rem;
        margin-bottom: 1rem;
        font-size: 1.5rem;
    }
    
    .chapter-body > h3 {
        margin-top: 1.5rem;
        margin-bottom: 0.8rem;
        font-size: 1.2rem;
    }
    
    .chapter-body > h4 {
        margin-top: 1.2rem;
        margin-bottom: 0.6rem;
        font-size: 1rem;
    }
}

/* ===== БЛОКИ ТОЛЬКО ДЛЯ ПЕРЕЧИСЛЕНИЙ ===== */

/* Общие стили для блоков перечисления */
.content-block {
    margin: 2.5rem 0;
    padding: 2rem;
    border-radius: 12px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-left: 4px solid #597d89;
}

.content-block h3 {
    color: #2c3e50;
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid #dee2e6;
    font-size: 1.6rem;
}

.content-block h4 {
    color: #2c3e50;
    margin-bottom: 0.8rem;
    font-size: 1.3rem;
}

.content-block p {
    margin-bottom: 0.8rem;
    color: #495057;
    font-size: 1.05rem;
    line-height: 1.6;
}

/* ТИП 1: Блок с цифровым перечислением */
.numbered-list {
    border-left-color: #597d89;
}

.numbered-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.8rem;
    padding: 1.2rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.numbered-item:hover {
    border-color: #597d89;
    box-shadow: 0 5px 15px rgba(89, 125, 137, 0.1);
}

.item-number {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #597d89 0%, #4a6a75 100%);
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
    border-radius: 50%;
    flex-shrink: 0;
}

.item-content {
    flex: 1;
}

/* ТИП 2: Блок с символьным перечислением */
.symbol-list {
    border-left-color: #597d89;
}

.symbol-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.2rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.symbol-item:hover {
    border-color: #597d89;
    box-shadow: 0 5px 15px rgba(89, 125, 137, 0.1);
}

.item-symbol {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    color: #597d89;
    font-weight: 700;
    font-size: 1.5rem;
    flex-shrink: 0;
}

/* ТИП 3: Блок с маркерами */
.marker-list {
    border-left-color: #597d89;
}

.marker-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.2rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.marker-item:hover {
    border-color: #597d89;
    box-shadow: 0 5px 15px rgba(89, 125, 137, 0.1);
}

.item-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    color: #597d89;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* ТИП 4: Смешанный блок */
.mixed-list {
    border-left-color: #597d89;
}

.mixed-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.2rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.mixed-item:hover {
    border-color: #597d89;
    box-shadow: 0 5px 15px rgba(89, 125, 137, 0.1);
}

.mixed-item.nested {
    margin-left: 2rem;
    background: #f8f9fa;
}

.item-prefix {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    color: #597d89;
    font-weight: 700;
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* ТИП 5: Блок с индикаторами */
.indicator-list {
    border-left-color: #597d89;
}

.indicator-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.2rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.indicator-item:hover {
    border-color: #597d89;
    box-shadow: 0 5px 15px rgba(89, 125, 137, 0.1);
}

.indicator-item.special {
    border-left: 3px solid #4a6a75;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.item-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    color: #597d89;
    font-weight: 700;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.indicator-item.special .item-indicator {
    color: #4a6a75;
}

/* Адаптивность для блоков */
@media (max-width: 768px) {
    .content-block {
        padding: 1.5rem;
        margin: 2rem 0;
    }
    
    .content-block h3 {
        font-size: 1.3rem;
        margin-bottom: 1.2rem;
        padding-bottom: 0.6rem;
    }
    
    .numbered-item,
    .symbol-item,
    .indicator-item {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    .marker-item,
    .mixed-item {
        flex-direction: column;
        gap: 0.8rem;
        padding: 0.8rem;
    }
    
    .item-number,
    .item-symbol,
    .item-indicator {
        width: 35px;
        height: 35px;
        font-size: 1.1rem;
    }
    
    .item-marker,
    .item-prefix {
        width: 25px;
        height: 25px;
        font-size: 1rem;
    }
    
    .mixed-item.nested {
        margin-left: 1rem;
    }
    
    .item-content h4 {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .content-block {
        padding: 1.2rem;
        margin: 1.5rem 0;
        border-left-width: 3px;
    }
    
    .content-block h3 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
        padding-bottom: 0.5rem;
    }
    
    .numbered-item,
    .symbol-item,
    .indicator-item {
        padding: 0.8rem;
        gap: 0.8rem;
    }
    
    .marker-item,
    .mixed-item {
        padding: 0.7rem;
        gap: 0.6rem;
    }
    
    .item-number,
    .item-symbol,
    .item-indicator {
        width: 30px;
        height: 30px;
        font-size: 1rem;
    }
    
    .item-marker,
    .item-prefix {
        width: 20px;
        height: 20px;
        font-size: 0.9rem;
    }
    
    .mixed-item.nested {
        margin-left: 0.8rem;
    }
    
    .item-content h4 {
        font-size: 1rem;
    }
    
    .item-content p {
        font-size: 0.95rem;
        line-height: 1.5;
    }
}

/* ===== СПЕЦИАЛЬНЫЕ ЭЛЕМЕНТЫ ===== */

/* Цитаты */
.article-quote {
    border-left: 5px solid #597d89;
    padding: 2rem;
    margin: 2.5rem 0;
    font-style: italic;
    color: #555;
    background: #f8f9fa;
    border-radius: 0 8px 8px 0;
}

.article-quote p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

.article-quote cite {
    display: block;
    margin-top: 1rem;
    font-style: normal;
    color: #999;
    font-weight: 500;
}

.article-quote cite::before {
    content: "— ";
}

/* Важные примечания */
.content-note {
    background: linear-gradient(135deg, #f0f7ff 0%, #e3f2fd 100%);
    padding: 1.5rem 2rem;
    border-left: 5px solid #597d89;
    border-radius: 8px;
    margin: 2rem 0;
}

.content-note.important {
    background: linear-gradient(135deg, #fff0f0 0%, #ffebee 100%);
    border-left-color: #8b0000;
}

.content-note p {
    margin-bottom: 0;
    font-style: italic;
    font-weight: 500;
    font-size: 1.1rem;
}

/* ===== ШАПКА САЙТА ===== */
.header {
    background-color: #fff;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0;
    width: 100%;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 15px;
    flex-wrap: wrap;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #597d89;
    white-space: nowrap;
}

.nav {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.nav a {
    font-weight: 600;
    position: relative;
    white-space: nowrap;
    font-size: 0.95rem;
}

.nav a:hover,
.nav a.active {
    color: #4a6a75;
}

.nav a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #597d89;
}

/* Мобильное меню */
@media (max-width: 992px) {
    .nav {
        gap: 1rem;
    }
    
    .nav a {
        font-size: 0.9rem;
    }
}

@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        padding: 0.8rem 15px;
        gap: 0.8rem;
    }
    
    .logo {
        font-size: 1.5rem;
        text-align: center;
        width: 100%;
    }
    
    .nav {
        width: 100%;
        justify-content: center;
        gap: 0.8rem;
        padding: 0.5rem 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }
    
    .nav::-webkit-scrollbar {
        display: none;
    }
    
    .nav a {
        font-size: 0.85rem;
        padding: 0.3rem 0.5rem;
    }
}

@media (max-width: 480px) {
    .header .container {
        padding: 0.6rem 10px;
    }
    
    .logo {
        font-size: 1.3rem;
    }
    
    .nav {
        gap: 0.5rem;
    }
    
    .nav a {
        font-size: 0.8rem;
        padding: 0.2rem 0.4rem;
    }
}

/* ===== ПОДВАЛ САЙТА ===== */
.footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: #ecf0f1;
    padding: 3rem 0 2rem;
    margin-top: 4rem;
    width: 100%;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer-nav {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-nav a {
    color: #bdc3c7;
    font-size: 0.9rem;
    white-space: nowrap;
}

.footer-nav a:hover {
    color: #ecf0f1;
}

@media (max-width: 768px) {
    .footer {
        padding: 2rem 0 1.5rem;
        margin-top: 3rem;
    }
    
    .footer .container {
        flex-direction: column;
        text-align: center;
        gap: 1.2rem;
    }
    
    .footer p {
        margin-bottom: 0;
        line-height: 1.5;
    }
    
    .footer-nav {
        justify-content: center;
        gap: 1rem;
    }
    
    .footer-nav a {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 1.5rem 0 1rem;
        margin-top: 2rem;
    }
    
    .footer-nav {
        gap: 0.8rem;
    }
    
    .footer-nav a {
        font-size: 0.8rem;
    }
}

/* ===== ХЛЕБНЫЕ КРОШКИ ===== */
.breadcrumbs {
    background: linear-gradient(135deg, #e9ecef 0%, #f8f9fa 100%);
    padding: 1.2rem 0;
    font-size: 0.9rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #dee2e6;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
}

.breadcrumbs .container {
    white-space: nowrap;
    padding: 0 15px;
}

.breadcrumbs a {
    color: #597d89;
    display: inline-block;
}

.breadcrumbs a:hover {
    color: #4a6a75;
}

.breadcrumbs span {
    color: #6c757d;
    font-weight: 500;
}

@media (max-width: 768px) {
    .breadcrumbs {
        padding: 1rem 0;
        margin-bottom: 1.5rem;
        font-size: 0.85rem;
    }
    
    .breadcrumbs .container {
        padding: 0 10px;
    }
}

@media (max-width: 480px) {
    .breadcrumbs {
        padding: 0.8rem 0;
        font-size: 0.8rem;
    }
}

/* ===== СТИЛИ СТРАНИЦЫ ГЛАВЫ ===== */
.chapter-page {
    padding-top: 2rem;
    background: white;
    min-height: 100vh;
    width: 100%;
}

/* Заголовок главы */
.chapter-header {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e9ecef;
}

.chapter-category {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #597d89 0%, #4a6a75 100%);
    color: white;
    padding: 0.6rem 1.8rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.chapter-header h1 {
    font-size: 2.5rem;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    color: #2c3e50;
    text-align: center;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.chapter-excerpt {
    font-size: 1.2rem;
    line-height: 1.6;
    color: #666;
    max-width: 800px;
    margin: 0 auto 2rem;
    font-style: italic;
    word-wrap: break-word;
}

.chapter-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
    background: #f8f9fa;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    white-space: nowrap;
}

.meta-item i {
    color: #597d89;
    font-size: 1rem;
}

@media (max-width: 992px) {
    .chapter-header h1 {
        font-size: 2.2rem;
    }
    
    .chapter-excerpt {
        font-size: 1.1rem;
        padding: 0 20px;
    }
    
    .chapter-meta {
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .chapter-page {
        padding-top: 1.5rem;
    }
    
    .chapter-header {
        margin-bottom: 2rem;
        padding-bottom: 1.5rem;
    }
    
    .chapter-header h1 {
        font-size: 1.8rem;
        line-height: 1.2;
        margin-bottom: 1rem;
        padding: 0 10px;
    }
    
    .chapter-category {
        font-size: 0.8rem;
        padding: 0.5rem 1.5rem;
        margin-bottom: 1rem;
    }
    
    .chapter-excerpt {
        font-size: 1rem;
        line-height: 1.5;
        margin-bottom: 1.5rem;
        padding: 0 15px;
    }
    
    .chapter-meta {
        flex-direction: column;
        gap: 0.8rem;
        align-items: center;
        margin-bottom: 1.5rem;
    }
    
    .meta-item {
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
        width: auto;
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .chapter-page {
        padding-top: 1rem;
    }
    
    .chapter-header {
        margin-bottom: 1.5rem;
        padding-bottom: 1rem;
    }
    
    .chapter-header h1 {
        font-size: 1.6rem;
        padding: 0 5px;
    }
    
    .chapter-category {
        font-size: 0.75rem;
        padding: 0.4rem 1.2rem;
    }
    
    .chapter-excerpt {
        font-size: 0.95rem;
        padding: 0 10px;
        margin-bottom: 1rem;
    }
    
    .meta-item {
        font-size: 0.8rem;
        padding: 0.3rem 0.7rem;
    }
}

/* ===== БЛОК РЕСУРСОВ ===== */
.chapter-resources {
    margin: 4rem 0;
    padding: 3rem 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
}

.chapter-resources h3 {
    text-align: center;
    margin-bottom: 2.5rem;
    color: #2c3e50;
    font-size: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.resource-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-decoration: none;
    color: inherit;
    min-height: 200px;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border-color: #597d89;
}

.resource-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #597d89 0%, #4a6a75 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.resource-icon i {
    color: white;
    font-size: 1.5rem;
}

.resource-content {
    flex: 1;
    min-width: 0;
}

.resource-content h4 {
    margin-bottom: 0.5rem;
    color: #2c3e50;
    font-size: 1.3rem;
    word-wrap: break-word;
}

.resource-content p {
    margin-bottom: 1rem;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.resource-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #597d89;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
}

/* Призыв к действию */
.chapter-cta {
    background: linear-gradient(135deg, #597d89 0%, #4a6a75 100%);
    color: white;
    padding: 4rem 2rem;
    border-radius: 15px;
    margin: 4rem 0;
    text-align: center;
}

.cta-content h3 {
    color: white;
    margin-bottom: 1rem;
    font-size: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
}

.cta-content p {
    margin-bottom: 2rem;
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-buttons .btn {
    background: white;
    color: #597d89;
    font-weight: 600;
    min-width: 200px;
}

.cta-buttons .btn:hover {
    background: #f8f9fa;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
}

.cta-buttons .btn-secondary {
    background: transparent;
    border: 2px solid white;
    color: white;
}

.cta-buttons .btn-secondary:hover {
    background: white;
    color: #597d89;
}

/* Анимации */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.8s ease-out;
}

/* Дополнительные улучшения для мобильных устройств */
@media (max-width: 768px) {
    .chapter-body {
        font-size: 1rem;
        line-height: 1.6;
        padding: 0 10px;
    }
    
    .chapter-resources {
        margin: 2.5rem 0;
        padding: 2rem 0;
        border-radius: 10px;
    }
    
    .chapter-resources h3 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .resources-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        max-width: 100%;
        padding: 0 10px;
    }
    
    .resource-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        padding: 1.2rem;
        min-height: auto;
    }
    
    .resource-icon {
        width: 50px;
        height: 50px;
    }
    
    .resource-content h4 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }
    
    .resource-content p {
        font-size: 0.9rem;
        line-height: 1.4;
        margin-bottom: 0.8rem;
    }
    
    .chapter-cta {
        padding: 2.5rem 1rem;
        margin: 2.5rem 0;
        border-radius: 10px;
    }
    
    .cta-content h3 {
        font-size: 1.5rem;
        flex-direction: column;
        gap: 0.5rem;
        margin-bottom: 0.8rem;
    }
    
    .cta-content p {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
        line-height: 1.5;
        padding: 0;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        width: 100%;
    }
    
    .cta-buttons .btn {
        width: 100%;
        max-width: 250px;
        min-width: unset;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .chapter-body {
        font-size: 0.95rem;
        line-height: 1.5;
        padding: 0 5px;
    }
    
    .chapter-resources {
        margin: 2rem 0;
        padding: 1.5rem 0;
    }
    
    .chapter-resources h3 {
        font-size: 1.3rem;
    }
    
    .resources-grid {
        gap: 1.2rem;
        padding: 0 5px;
    }
    
    .resource-card {
        padding: 1rem;
        gap: 0.8rem;
    }
    
    .resource-icon {
        width: 45px;
        height: 45px;
    }
    
    .resource-icon i {
        font-size: 1.2rem;
    }
    
    .resource-content h4 {
        font-size: 1rem;
    }
    
    .resource-content p {
        font-size: 0.85rem;
    }
    
    .resource-link {
        font-size: 0.85rem;
    }
    
    .chapter-cta {
        padding: 2rem 0.8rem;
        margin: 2rem 0;
    }
    
    .cta-content h3 {
        font-size: 1.3rem;
    }
    
    .cta-content p {
        font-size: 0.9rem;
        margin-bottom: 1.2rem;
    }
    
    .cta-buttons {
        gap: 0.8rem;
    }
    
    .cta-buttons .btn {
        max-width: 220px;
        padding: 10px 15px;
    }
}

/* Оптимизация для очень маленьких экранов */
@media (max-width: 320px) {
    html {
        font-size: 13px;
    }
    
    .container {
        padding: 0 8px;
    }
    
    .btn {
        padding: 10px 12px;
        font-size: 0.85rem;
    }
    
    .content-block {
        padding: 1rem;
    }
    
    .item-number,
    .item-symbol,
    .item-indicator {
        width: 25px;
        height: 25px;
        font-size: 0.9rem;
    }
}

/* Предотвращение горизонтального скролла */
body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
}

/* Улучшение для сенсорных устройств */
@media (hover: none) and (pointer: coarse) {
    .btn:hover,
    .resource-card:hover,
    .numbered-item:hover,
    .symbol-item:hover,
    .marker-item:hover,
    .mixed-item:hover,
    .indicator-item:hover {
        transform: none;
    }
    
    .btn:active,
    .resource-card:active,
    .numbered-item:active,
    .symbol-item:active,
    .marker-item:active,
    .mixed-item:active,
    .indicator-item:active {
        transform: scale(0.98);
    }
    
    .nav a.active::after {
        height: 3px;
    }
}