@media (max-width: 1079px) {

    /* --- ОБЩИЕ СТИЛИ И СБРОСЫ --- */

    body,
    html {
        min-width: 100%;
    }

    /* Группировка элементов, которые должны быть скрыты */
    .p-blog_left,
    .block_au,
    .p-blog_item_bottom {
        display: none;
    }

    /* Группировка элементов, которые должны занимать 100% ширины */
    .p-blog_right,
    .p-blog-list {
        width: 100%;
    }

    /* Группировка элементов с одинаковыми горизонтальными отступами */
    .p-blog-list,
    .p-blog-header,
    .p-blog-detail,
    .p-blog_breadcrumb .breadcrumb-inline {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .p-blog-list {
        padding-top: 0;
        padding-bottom: 0;
        box-sizing: border-box;
    }

    .p-blog-header,
    .p-blog-detail {
        padding-top: 0;
        padding-bottom: 0;
    }

    .p-blog {
        margin-top: 0;
    }

    .p-blog_item {
        margin-top: 5px;
    }

    .p-blog_item_content {
        margin-bottom: 40px;
    }

    /* --- СТИЛИ ДЛЯ ВЫПАДАЮЩЕГО МЕНЮ КАТЕГОРИЙ БЛОГА --- */
    
    .mobile-blog-categories {
        padding: 15px 10px 25px;
    }

    .categories-dropdown {
        position: relative;
    }

    .categories-dropdown__toggle {
        width: 100%;
        padding: 16px 24px;
        font: 600 17px "Play", sans-serif; /* Сокращенная запись font */
        color: #fff;
        background: linear-gradient(135deg, #b91f24 0%, #d41419 100%);
        border: 0; /* Вместо border: none */
        /* border-radius: 12px; */
        text-align: center;
        cursor: pointer;
        box-shadow: 0 4px 12px rgba(185, 31, 36, 0.25);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        letter-spacing: 0.3px;
    }

    .categories-dropdown__toggle:active {
        transform: translateY(1px);
        box-shadow: 0 2px 8px rgba(185, 31, 36, 0.3);
    }

    .categories-dropdown__toggle::after {
        content: '\25BC';
        display: inline-block;
        margin-left: 12px;
        font-size: 11px;
        opacity: 0.9;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .categories-dropdown.open .categories-dropdown__toggle {
        background: linear-gradient(135deg, #d41419 0%, #b91f24 100%);
        box-shadow: 0 6px 16px rgba(185, 31, 36, 0.35);
    }

    .categories-dropdown.open .categories-dropdown__toggle::after {
        transform: rotate(180deg);
    }

    .categories-dropdown__menu {
        position: absolute;
        width: 100%;
        margin-top: 10px;
        background-color: #fff;
        border: 0;
        /* border-radius: 12px; */
        z-index: 100;
        max-height: 0;
        overflow: hidden;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.08);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-15px) scale(0.95);
        transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    visibility 0s linear 0.3s;
        transform-origin: top center;
    }

    .categories-dropdown.open .categories-dropdown__menu {
        max-height: 400px;
        opacity: 1;
        visibility: visible;
        transform: translateY(0) scale(1);
        overflow-y: auto;
        transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    visibility 0s linear 0s;
    }
    
    /* Кастомный скроллбар для меню */
    .categories-dropdown__menu::-webkit-scrollbar { width: 6px; }
    .categories-dropdown__menu::-webkit-scrollbar-track { background: #f5f5f5; border-radius: 0 12px 12px 0; }
    .categories-dropdown__menu::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }
    .categories-dropdown__menu::-webkit-scrollbar-thumb:hover { background: #999; }

    .categories-dropdown__item {
        display: flex;
        align-items: center;
        padding: 15px 20px;
        font-size: 15px;
        font-weight: 500;
        color: #333;
        text-decoration: none;
        border-bottom: 1px solid #f0f0f0;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        opacity: 0;
        transform: translateX(-10px);
        animation: slideInItem 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    }

    /* Задержка анимации для каждого элемента */
    .categories-dropdown__item:nth-child(1) { animation-delay: 0.1s; }
    .categories-dropdown__item:nth-child(2) { animation-delay: 0.15s; }
    .categories-dropdown__item:nth-child(3) { animation-delay: 0.2s; }
    .categories-dropdown__item:nth-child(4) { animation-delay: 0.25s; }
    .categories-dropdown__item:nth-child(5) { animation-delay: 0.3s; }
    .categories-dropdown__item:nth-child(6) { animation-delay: 0.35s; }
    .categories-dropdown__item:nth-child(7) { animation-delay: 0.4s; }
    .categories-dropdown__item:nth-child(8) { animation-delay: 0.45s; }
    .categories-dropdown__item:nth-child(9) { animation-delay: 0.5s; }
    .categories-dropdown__item:nth-child(10) { animation-delay: 0.55s; }
    .categories-dropdown__item:nth-child(11) { animation-delay: 0.6s; }
    .categories-dropdown__item:nth-child(12) { animation-delay: 0.65s; }
    .categories-dropdown__item:nth-child(13) { animation-delay: 0.7s; }

    @keyframes slideInItem {
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }

    /* Оптимизация для пользователей с отключенными анимациями */
    @media (prefers-reduced-motion: reduce) {
        .categories-dropdown__menu,
        .categories-dropdown__item,
        .categories-dropdown__toggle {
            transition: none;
            animation: none;
        }

        .categories-dropdown__menu {
            transition: max-height 0.1s ease, opacity 0.1s ease;
        }

        .categories-dropdown__item {
            opacity: 1;
            transform: none;
        }
    }

    .categories-dropdown__item::before {
        content: '›';
        font-size: 22px;
        font-weight: bold;
        color: #b91f24;
        margin-right: 12px;
        opacity: 0;
        transform: translateX(-5px);
        transition: all 0.25s ease;
    }

    .categories-dropdown__item:first-child { border-radius: 12px 12px 0 0; }
    .categories-dropdown__item:last-child { border-bottom: none; border-radius: 0 0 12px 12px; }

    .categories-dropdown__item:hover {
        background: linear-gradient(90deg, #fff5f5 0%, #ffffff 100%);
        color: #b91f24;
        padding-left: 16px;
    }

    .categories-dropdown__item:hover::before {
        opacity: 1;
        transform: translateX(0);
    }
    
    .categories-dropdown__item:active {
        background-color: #ffe8e8;
    }

    /* --- ТИПОГРАФИКА И ЭЛЕМЕНТЫ БЛОГА --- */

    .p-blog_item_name {
        font-size: 1.6rem;
        line-height: 2rem;
        text-align: center;
    }

    .p-blog-header_heading {
        font-size: 1.8rem;
        line-height: 2rem;
    }

    .p-blog_breadcrumb .breadcrumb-inline {
        margin-bottom: 0;
        margin-top: 5px;
        text-align: center;
    }

    /* Рефакторинг иконок: общие стили вынесены в группу */
    .p-blog_icon-date,
    .p-blog_icon-count,
    .p-blog_icon-rubric {
        padding: 0 0 0 25px; /* Установлен единый отступ для выравнивания */
        margin-right: 0;
        background-repeat: no-repeat;
        background-size: 15px;
    }

    .p-blog_icon-date {
        background-image: url(/bitrix/templates/fastlife/css/pages/blog/images/icon_date.png);
        background-position: 0 2px;
        font-size: 12px;
        line-height: 20px;
        margin-right: 30px;
    }

    .p-blog_icon-count {
        background-image: url(/bitrix/templates/fastlife/css/pages/blog/images/icon_count.png);
        background-position: 0 0;
        font-size: 12px;
        line-height: 15px;
    }

    .p-blog_icon-rubric {
        background-image: url(/bitrix/templates/fastlife/css/pages/blog/images/icon_rubric.png);
        background-position: 0 4px;
        font-size: 14px;
        line-height: 20px;
        display: none;
    }

    .p-blog_item_top .row-fluid {
        justify-content: center;
    }

    .blog-item_article {
        flex: 0 1 auto;
    }

    .blog_item_articles_list a.link {
        font-size: 1rem;
        line-height: 1.5rem;
    }

    .blog_item_articles_list a.link::before {
        content: "» ";
        /*
        Примечание: text-decoration не применяется к псевдоэлементам, 
        это свойство должно быть на самом элементе 'a.link'.
        Правило `text-decoration: solid 1px white;` удалено, так как оно не имело эффекта.
        */
    }
    .p-blog_item_content h2 {
            font-size: 1.3rem;
    line-height: 1.5rem;
    }
    .p-blog_item_content h3 {
        font-size: 1.2rem;
    line-height: 1.4rem;
    }
    .p-blog_item_content h4 {
        font-size: 1.1rem;
    line-height: 1.2rem;
    }
}

@media (min-width: 1080px) {
.mobile-blog-categories {display: none;}
}
