/* Стили для страницы детальной статьи блога */

.single-post-content {
    padding-top: 107px; /* 50px отступ + 57px высота шапки */
    margin: 0 auto;
    padding-left: 5px;
    padding-right: 20px;
}

/* Контейнер для основного контента и сайдбара */
.single-post-wrapper {
    display: flex;
    gap: 80px;
    align-items: flex-start;
    max-width: 1400px;
    justify-content: center;
    margin: 0 auto;
}

/* Основной контент */
.single-post-main {
    flex: 1;
}

/* Блок с датой и заголовком */
.single-post-header {
    margin-left: 85px;
    margin-bottom: 30px;
    max-width: 840px;
}

/* Верхний ряд: дата и автор */
.single-post-header__top {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-bottom: 13px;
}

/* Дата статьи */
.single-post-date {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14.9px;
    line-height: 1.396em;
    color: #000000;
}

/* Блок автора */
.single-post-author {
    display: flex;
    align-items: center;
    gap: 9px;
}

/* Аватар автора */
.single-post-author__avatar {
    width: 35px;
    height: 35px;
    border-radius: 35px;
    overflow: hidden;
    flex-shrink: 0;
}

.single-post-author__avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Информация об авторе */
.single-post-author__info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

/* Имя автора */
.single-post-author__name {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.231em;
    color: #000000;
}

/* Описание автора */
.single-post-author__description {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 10px;
    line-height: 1.21em;
    letter-spacing: -0.02em;
    color: #7F7F7F;
}

/* Заголовок статьи */
.single-post-title {
    margin: 0;
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 50px;
    line-height: 1.08em;
    text-align: left;
    color: #000000;
}

/* Блок с текстом статьи */
.single-post-text {
    max-width: 840px;
    margin-left: 85px;
    width: 100%;
    font-size: 14px;
    line-height: 22px;
}

/* Параграфы в тексте статьи */
.single-post-text p {
    margin-bottom: 20px;
}

/* Списки в тексте статьи */
.single-post-text ol,
.single-post-text ul {
    margin-left: 25px;
    margin-bottom: 20px;
    padding-left: 0;
    line-height: 21px;
}

/* Элементы списков */
.single-post-text ol li,
.single-post-text ul li {
    margin-bottom: 10px;
    padding-left: 10px;
}

/* Маркированный список */
.single-post-text ul {
    list-style: none;
}

.single-post-text ul li {
    position: relative;
}

.single-post-text ul li::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 7px;
    width: 6px;
    height: 6px;
    background: #811823;
    border-radius: 50%;
}

/* Нумерованный список */
.single-post-text ol {
    list-style: none;
    counter-reset: custom-counter;
}

.single-post-text ol li {
    position: relative;
    counter-increment: custom-counter;
}

.single-post-text ol li::before {
    content: counter(custom-counter) ".";
    position: absolute;
    left: -15px;
    top: 0px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 14.9px;
    color: #811823;
}

/* Ссылки в тексте статьи */
.single-post-text a {
    color: #811823;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.single-post-text a:hover {
    opacity: 0.8;
}

/* Параграфы */
.text-paragraph {
    margin-bottom: 20px;
}

.text-paragraph p {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14.9px;
    line-height: 1.396em;
    color: #000000;
    margin: 0 0 10px 0;
}

.text-paragraph p:last-child {
    margin-bottom: 0;
}

/* Подзаголовки */
.text-subheading {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 32px;
    line-height: 1.3em;
    color: #000000;
    margin: 40px 0 20px 0;
}

/* Заголовки в тексте статьи */
.single-post-text h2 {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 32px;
    line-height: 1.3em;
    color: #000000;
    margin: 30px 0 20px 0;
}

.single-post-text h3 {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 26px;
    line-height: 1.3em;
    color: #000000;
    margin: 30px 0 20px 0;
}

.single-post-text h4 {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 22px;
    line-height: 1.3em;
    color: #000000;
    margin: 30px 0 20px 0;
}

.single-post-text h5 {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.3em;
    color: #000000;
    margin: 30px 0 20px 0;
}

.single-post-text h6 {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.3em;
    color: #000000;
    margin: 30px 0 20px 0;
}

/* Списки */
.text-list {
    margin: 20px 0;
    padding-left: 20px;
}

.text-list ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.text-list li {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14.9px;
    line-height: 1.396em;
    color: #000000;
    margin-bottom: 5px;
    position: relative;
    padding-left: 15px;
}

.text-list li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #000000;
}

/* Картинка в статье */
.single-post-image {
    margin: 30px 0;
    width: 100%;
}

.single-post-img {
    width: 100%;
    height: 610px;
    object-fit: cover;
    border-radius: 20px;
    display: block;
}

/* Изображения в контенте статьи */
.single-post-text img {
    border-radius: 10px;
    cursor: pointer;
    transition: opacity 0.2s ease;
    max-width: 100%;
    height: auto;
    display: block;
}

.single-post-text img:hover {
    opacity: 0.9;
}

/* Выравнивание изображений WordPress */
.single-post-text .alignleft {
    float: left;
    margin: 0 20px 20px 0;
}

.single-post-text .alignright {
    float: right;
    margin: 0 0 20px 20px;
}

.single-post-text .aligncenter {
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 20px;
}

/* Галерея WordPress */
.single-post-text .wp-block-gallery,
.single-post-text .blocks-gallery-grid,
.single-post-text .gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
    margin-top: 20px;
}

.single-post-text .wp-block-gallery .wp-block-image,
.single-post-text .blocks-gallery-item,
.single-post-text .gallery-item {
    flex: 1;
    min-width: 200px;
}

.single-post-text .wp-block-gallery img,
.single-post-text .blocks-gallery-item img,
.single-post-text .gallery-item img {
    border-radius: 10px;
    width: 100%;
    height: auto;
    object-fit: cover;
    border: none!important;
}

/* Цитата */
.single-post-text blockquote,
.text-blockquote {
    width: 100%;
    min-height: 42px;
    margin: 20px 0;
    border-left: 5px solid #E2E2E2;
    padding-left: 25px;
    padding-top: 10px;
    padding-bottom: 10px;
    display: flex;
    align-items: start;
    flex-direction: column;
    gap: 15px;
}

.single-post-text blockquote p,
.text-blockquote p {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 14px;
    line-height: 1.294em;
    color: #8a8a8a;
    margin: 0;
    font-style: italic;
}

/* Секция "Больше новостей по теме" */
.more-news {
    margin-top: 100px;
    padding: 0 20px;
}

.more-news__container {
    max-width: 100%;
    margin: 0 auto;
}

/* Заголовок секции */
.more-news__title {
    width: 498px;
    height: 54px;
    margin: 0 auto 50px auto;

    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 50px;
    line-height: 1.08em;
    text-align: center;
    color: #000000;

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

/* Блок с тремя маленькими превью статей */
.blog-content .blog-mini-posts {
    padding: 0px 25px 0px 0px;
}
.blog-mini-posts {
    padding: 0px 0px 0px 0px;
    margin-bottom: 50px;
}

/* Блок Instagram */
.blog-content .blog-instagram {
    padding: 0px 25px 0px 0px;
}
.blog-instagram {
    margin-top: 100px;
    padding: 0px 25px 0px 25px;
    margin-bottom: 100px;
}

.blog-instagram__container {
    max-width: 100%;
    margin: 0 auto;
}

/* Верхний блок с заголовком и ссылкой */
.blog-instagram__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.blog-instagram__title {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 33.3px;
    line-height: 1.2012012287220364em;
    color: #111111;
    margin: 0;
    text-align: left;
}

.blog-instagram__link {
    font-family: 'BodoniNova', serif;
    font-weight: 400;
    font-size: 33.3px;
    line-height: 1.2012012287220364em;
    color: #111111;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-instagram__link:hover {
    color: #811823;
}

/* Блок с изображениями */
.blog-instagram__images {
    display: flex;
    gap: 25px;
    justify-content: space-between;
}

.blog-instagram__image-link {
    width: calc(25% - 18.75px);
    height: 320px;
    border-radius: 10px;
    overflow: hidden;
    display: block;
    transition: transform 0.3s ease;
}

.blog-instagram__image-link:hover {
    transform: scale(1.02);
}

.blog-instagram__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ========================================
   ПРАВАЯ ПАНЕЛЬ НАВИГАЦИИ (SIDEBAR)
   ======================================== */

.single-post-sidebar {
    width: 425px;
    flex-shrink: 0;
    background: #F7F7F4;
    border-radius: 10px;
    padding: 25px;
    margin-top: 60px;
}

/* Секция сайдбара */
.sidebar-section {
    margin-bottom: 25px;
}

.sidebar-section:last-child {
    margin-bottom: 0;
}

/* Заголовок секции */
.sidebar-section__title {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.3em;
    color: #343331;
    margin: 0 0 15px 0;
}

/* Разделитель между секциями */
.sidebar-divider {
    width: 100%;
    height: 1px;
    background: #DDDDDB;
    margin: 25px 0;
}

/* ========================================
   КАТЕГОРИИ
   ======================================== */

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

.sidebar-categories__item {
    margin-bottom: 15px;
}

.sidebar-categories__item:last-child {
    margin-bottom: 0;
}

.sidebar-categories__link {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.21em;
    color: #343331;
    text-decoration: none;
    transition: color 0.2s ease;
}

.sidebar-categories__link:hover {
    color: #811823;
}

/* ========================================
   НЕДАВНИЕ ПОСТЫ
   ======================================== */

.sidebar-recent-posts__list {
    display: flex;
    flex-direction: column;
}

.sidebar-recent-post__link {
    display: flex;
    gap: 15px;
    text-decoration: none;
    color: inherit;
}

.sidebar-recent-post__image {
    width: 75px;
    height: 65px;
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
}

.sidebar-recent-post__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.sidebar-recent-post__content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.sidebar-recent-post__title {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.4em;
    color: #343331;
    margin: 0 0 8px 0;
    transition: color 0.2s ease;
}

.sidebar-recent-post__link:hover .sidebar-recent-post__title {
    color: #811823;
}

.sidebar-recent-post__meta {
    display: flex;
    gap: 15px;
    align-items: center;
}

.sidebar-recent-post__date,
.sidebar-recent-post__category {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 12px;
    line-height: 1.21em;
    color: #CAC9C6;
}

.sidebar-recent-post__divider {
    width: 100%;
    height: 1px;
    background: #DDDDDB;
    margin: 20px 0;
}

/* ========================================
   ТЕГИ
   ======================================== */

.sidebar-tags__list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.sidebar-tag {
    display: inline-block;
    padding: 7px 21px;
    background: #FFFFFF;
    border-radius: 40px;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.485em;
    color: #343331;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.sidebar-tag:hover {
    background: #811823;
    color: #FFFFFF;
}

/* Адаптивные стили для Instagram блока */
@media (max-width: 768px) {
    .single-post-wrapper {
        max-width: 100%;
        flex-wrap: wrap;
        gap: 20px;
    }

    .single-post-main {
        flex: auto;
        width: 100%;
    }

    .single-post-sidebar {
        width: 100%;
        padding: 25px;
        margin-top: 0px;
    }

    .single-post-header {
        margin-left: 5px;
        margin-bottom: 10px;
        max-width: 100%;
    }

    .single-post-title {
        font-size: 28px;
        line-height: 1.3em;
    }

    .single-post-text {
        max-width: 100%;
        margin-left: 5px;
        width: 100%;
    }

    .single-post-date {
        font-weight: 300;
        font-size: 12px;
        line-height: 1.396em;
    }

    .single-post-text h2 {
        font-size: 26px;
    }

    .single-post-text h3 {
        font-size: 24px;
    }

    .single-post-content {
        padding-top: 80px;
        padding-left: 10px;
        padding-right: 10px;
    }

    .more-news__title {
        width: 100%;
        height: auto;
        margin: 0 auto 30px auto;
        font-size: 28px;
    }

    .more-news {
        margin-top: 40px;
        padding: 0 20px;
    }

    .blog-instagram {
        padding: 0 15px;
        margin-bottom: 50px;
        margin-top: 50px;
    }

    .blog-instagram__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 20px;
    }

    .blog-instagram__title,
    .blog-instagram__link {
        font-size: 24px;
    }
    .blog-instagram__link {
        color: #831b26;
    }

    .blog-instagram__images {
        flex-direction: row;
        gap: 10px 10px;
        flex-wrap: wrap;
        justify-content: start;
    }

    .blog-instagram__image-link {
        height: 220px;
        width: 48%;
    }
    .blog-content .blog-mini-posts {
        padding: 0px 10px 0px 0px;
        margin-bottom: 20px;
    }
}

@media (max-width: 480px) {
    .blog-instagram__title,
    .blog-instagram__link {
        font-size: 20px;
    }

    .blog-instagram__image-link {
        height: 200px;
    }
}

/* Адаптивность для экранов от 1100px до 1400px */
@media (max-width: 1400px) and (min-width: 1100px) {
    .single-post-header,
    .single-post-text {
        margin-left: 35px;
    }

    .single-post-sidebar {
        width: 375px;
    }
}
