/* =========================================
   PAGE-HOME — стили главной страницы
   Вынесено из основного style.css темы
   ========================================= */

/* =========================================
   1. ТОП-СЛАЙДЕР ГЛАВНОЙ
   ========================================= */

/* --- Базовая обёртка --- */
.co-topslider {
    position: relative;
}

.co-topslider-slide {
    border-radius: 8px 8px 0 0;
    background: linear-gradient(135deg, #EFF6FF 0%, #F8FAFC 100%);
}

/* =========================================
   ДЕСКТОП (min-width: 769px)
   ========================================= */
@media (min-width: 769px) {
    .co-topslider {
        height: 440px;
        border-radius: 8px;
        box-shadow: var(--shadow-soft);
    }
    .co-topslider-slides {
        height: 100%;
    }
    .co-topslider-slide {
        position: absolute;
        top: 0;
        height: 100%;
        border-radius: 8px;
        opacity: 0;
        pointer-events: none;
        overflow: hidden;
    }
    .co-topslider-slide.active {
        position: relative;
        opacity: 1;
        pointer-events: auto;
        transition: opacity 1s linear;
    }
}

/* =========================================
   МОБИЛКА (max-width: 768px) — базовая
   ========================================= */
@media (max-width: 768px) {
    .co-topslider-slide {
        position: relative;
        display: flex;
        flex-direction: column;
        margin-bottom: 16px;
        padding: 16px;
        min-height: 208px;
        border-radius: 8px;
        font-size: 16px;
        line-height: 24px;
        color: #212121;
        box-shadow: var(--shadow-soft);
        overflow: hidden;
    }
}

/* =========================================
   ФИГУРА И КАРТИНКА
   ========================================= */
@media (min-width: 769px) {
    .co-topslider-slide__figure {
        position: absolute;
        right: -236px;
        top: -94px;
        width: 750px;
        height: 750px;
        background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iODAzIiBoZWlnaHQ9IjgzNSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTc4NC44NTIgNDI2LjkzNWMxNC4yNTMtMzcuODc1IDIwLjkyOC03MS40NTcgMTYuNzY3LTk2LjE3MUM3ODEuNjA4IDIxMS44OTEgNDU3LjU0NC0xOC43ODkgMzM4LjY3MSAxLjIyMiAyNDUuNDkgMTYuOTA4IDgzLjYxMSAyMTkuNDE4IDI3LjYyNiAzNjMuNDc4IDkuODUyIDM5Ni40MzMtLjQ3MSA0MjYuNDExLjAxNiA0NDkuOTFjMi40NDQgMTE3Ljc4OCAyODIuOTgyIDM4Ni45MjggNDAwLjc3IDM4NC40ODUgMTE3Ljc4OC0yLjQ0MyAzODYuOTI4LTI4Mi45ODEgMzg0LjQ4NS00MDAuNzY5YTgzLjA5NCA4My4wOTQgMCAwIDAtLjQxOC02LjY5MXptLTc1OS40LTU3Ljc0OWMtMTMuOTQ3IDM3LjM5LTIwLjQ0IDcwLjUyOS0xNi4zMjQgOTQuOTg1QzI5LjE0IDU4My4wNDQgMzUzLjIwMyA4MTMuNzI0IDQ3Mi4wNzcgNzkzLjcxM2M5My44MTMtMTUuNzkyIDI1Ny4yNjItMjIwLjk1NCAzMTIuMTcxLTM2NS4xODIuMTQ2IDEuNzM0LjIzOCAzLjQzOC4yNzIgNS4xMTEuNjA2IDI5LjIxMy0xNS42NSA2OC42NzEtNDIuMzY4IDExMS41NTYtMjYuNjk1IDQyLjg0OS02My43NTUgODguOTk0LTEwNC41NzkgMTMxLjU0OC00MC44MjQgNDIuNTUzLTg1LjM5NCA4MS40OTQtMTI3LjA5OSAxMDkuOTQzLTQxLjc0IDI4LjQ3Mi04MC40OTEgNDYuMzUtMTA5LjcwNCA0Ni45NTYtMjkuMjE0LjYwNi02OC42NzItMTUuNjUtMTExLjU1Ni00Mi4zNjgtNDIuODQ5LTI2LjY5NS04OC45OTUtNjMuNzU1LTEzMS41NDgtMTA0LjU3OS00Mi41NTQtNDAuODI0LTgxLjQ5NS04NS4zOTQtMTA5Ljk0My0xMjcuMDk5QzE5LjI1IDUxNy44NTkgMS4zNzMgNDc5LjEwOC43NjYgNDQ5Ljg5NWMtLjQ1Ny0yMi4wNDYgOC42ODgtNDkuOTI1IDI0LjY4Ni04MC43MDl6IiBmaWxsPSIjMDM5QkU1Ii8+PC9zdmc+) no-repeat 50%;
        background-size: contain;
        transform: rotate(-67deg);
        overflow: hidden;
    }
    .co-topslider-slide__image {
        position: absolute;
        top: 0;
        right: 0;
        width: 440px;
        height: 440px;
        background: 50%/contain no-repeat transparent;
        overflow: hidden;
    }
}

@media (max-width: 768px) {
    .co-topslider-slide__image {
        position: absolute;
        bottom: -6px;
        right: -6px;
        width: 165px;
        height: 165px;
        background: 50%/contain no-repeat transparent;
        overflow: hidden;
    }
}

/* =========================================
   КОНТЕНТ И ЗАГОЛОВОК
   ========================================= */
.co-topslider-slide__content {
    position: relative;
    z-index: 1;
}

@media (min-width: 769px) {
    .co-topslider-slide__content {
        padding-top: 64px;
        padding-left: 48px;
        height: 332px;
    }
    .co-topslider-slide__title {
        margin-bottom: 32px;
        font-size: 28px;
        font-weight: bold;
        line-height: 40px;
        color: var(--primary-color);
    }
}

@media (max-width: 768px) {
    .co-topslider-slide__content {
        display: flex;
        flex-direction: column;
        min-height: 176px;
    }
    .co-topslider-slide__title {
        margin-bottom: 12px;
        font-size: 20px;
        line-height: 28px;
        font-weight: bold;
        color: var(--primary-color);
    }
}

/* =========================================
   КНОПКА
   ========================================= */
.co-topslider-slide__btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0 30px;
    width: auto;
    height: 56px;
    border-radius: var(--border-radius-btn);
    font-size: 15px;
    line-height: 1.2;
    font-weight: 700;
    text-decoration: none;
    text-align: center;
    background-color: var(--secondary-color);
    color: #fff;
    cursor: pointer;
    transition: background 0.3s;
}
.co-topslider-slide__btn:hover {
    background-color: var(--secondary-hover);
}

@media (max-width: 768px) {
    .co-topslider-slide__btn-wrapper {
        margin-top: auto;
    }
    .co-topslider-slide__btn {
        padding: 0 15px;
        height: 40px;
    }
}

/* =========================================
   НИЖНЯЯ ПАНЕЛЬ ВКЛАДОК (actions)
   ========================================= */
.co-topslider-actions {
    position: absolute;
    bottom: -8px;
    display: flex;
    width: 100%;
}
@media (max-width: 768px) {
    .co-topslider-actions {
        display: none;
    }
}

.co-topslider-action {
    flex: 1;
    min-height: 116px;
    overflow: hidden;
}
.co-topslider-action:first-child {
    border-bottom-left-radius: 8px;
}
.co-topslider-action:last-child {
    border-bottom-right-radius: 8px;
}
.co-topslider-action.active {
    display: flex;
    flex-direction: column;
    margin: 0;
    border-right: none;
    border-radius: 15px;
    background: #fff;
    transition: all .33s ease-out;
    box-shadow: 0 8px 16px rgba(22,33,54,.08), 0 -8px 16px rgba(22,33,54,.04), 0 16px 24px rgba(22,33,54,.16);
    z-index: 9;
}

.co-topslider-action__inner {
    position: relative;
    display: flex;
    flex-direction: column;
    margin: 8px 0;
    padding: 16px;
    flex: 1;
    height: calc(100% - 16px);
    background: rgba(255,255,255,.72);
    backdrop-filter: blur(24px);
    transition: all easeInOutBack .33s;
    outline: none;
    cursor: pointer;
    z-index: 1;
}

.co-topslider-action:not(.active) + .co-topslider-action:not(.active) .co-topslider-action__inner:before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    display: block;
    width: 1px;
    height: 76px;
    background-color: var(--border-color);
    transform: translateY(-50%);
}
.co-topslider-action:first-child .co-topslider-action__inner {
    border-bottom-left-radius: 8px;
}
.co-topslider-action:last-child .co-topslider-action__inner {
    border-bottom-right-radius: 8px;
}
.co-topslider-action.active .co-topslider-action__inner {
    margin: 8px 0;
    background: #fff;
}

.co-topslider-action__title {
    margin-bottom: 8px;
    font-size: 16px;
    font-weight: 700;
    line-height: 24px;
    color: var(--text-main);
}
.co-topslider-action__desc {
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: var(--text-light);
}

.co-topslider-action__progress {
    height: 4px;
    background: #fff;
    transition-delay: .4s;
}
.co-topslider-action.active .co-topslider-action__progress-fill {
    display: block;
    height: 4px;
    border-radius: 8px;
    background: var(--secondary-color);
    transform: translateX(-100%);
    animation: topslider_animate 5s linear infinite forwards;
    animation-play-state: running;
}
.co-topslider-action.no-animate .co-topslider-action__progress-fill {
    display: none !important;
}

@keyframes topslider_animate {
    to {
        transform: none;
    }
}

/* =========================================
   МОБИЛЬНЫЙ ПРЕМИУМ-ДИЗАЙН С SVG-ИКОНКАМИ
   (max-width: 768px) — перекрывает базовые правила
   ========================================= */
@media (max-width: 768px) {

    /* 1. Скрываем старые фото и фигуру */
    .co-topslider-slide__image,
    .co-topslider-slide__figure {
        display: none !important;
        height: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    /* 2. Карточка слайда */
    .co-topslider-slide {
        background: linear-gradient(135deg, #F8FAFC 0%, #EFF6FF 100%) !important;
        border-radius: 16px !important;
        box-shadow: var(--shadow-soft) !important;
        border: 1px solid var(--border-color) !important;
        margin: 10px 6px !important;
        height: auto !important;
        min-height: 0 !important;
        overflow: hidden;
        position: relative;
    }

    /* 3. Контент */
    .co-topslider-slide__content {
        padding: 14px 14px 16px 14px !important;
        position: static !important;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        z-index: 2;
    }

    /* 4. Заголовок с иконкой */
    .co-topslider-slide__title {
        font-size: 16px !important;
        font-weight: 700 !important;
        color: var(--primary-color) !important;
        line-height: 1.3 !important;
        margin: 0 !important;
        text-align: center;

        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;

        padding-top: 34px;
        background-position: top center;
        background-repeat: no-repeat;
        background-size: 32px 32px;
    }

    /* Индивидуальные иконки по data-index */
    .co-topslider-slide[data-index="1"] .co-topslider-slide__title {
        background-image: url('https://kartarasrochki.ru/wp-content/themes/aigiz/img/block-chapter/zaem.svg');
    }
    .co-topslider-slide[data-index="2"] .co-topslider-slide__title {
        background-image: url('https://kartarasrochki.ru/wp-content/themes/aigiz/img/block-chapter/credit.svg');
    }
    .co-topslider-slide[data-index="3"] .co-topslider-slide__title {
        background-image: url('https://kartarasrochki.ru/wp-content/themes/aigiz/img/block-chapter/creditcard.svg');
    }
    .co-topslider-slide[data-index="4"] .co-topslider-slide__title {
        background-image: url('https://kartarasrochki.ru/wp-content/themes/aigiz/img/block-chapter/debitcard.svg');
    }

    /* 5. Кнопка */
    .co-topslider-slide__btn-wrapper {
        width: 100%;
        margin-top: 4px !important;
    }

    .co-topslider-slide__btn {
        display: block;
        width: 100%;
        box-sizing: border-box;

        background: var(--secondary-color) !important;
        color: #fff !important;
        border: none !important;

        border-radius: var(--border-radius-btn) !important;
        padding: 12px 10px !important;

        font-size: 14px !important;
        font-weight: 700 !important;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        text-align: center;
        text-decoration: none !important;

        box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2) !important;
        transition: all 0.2s ease;
    }

    .co-topslider-slide__btn:active {
        transform: scale(0.97);
        background: var(--secondary-hover) !important;
    }
}

/* =========================================
   2. КАТЕГОРИИ на главной под слайдером
   ========================================= */
.section-categories--premium {
    background: #F8FAFC;
    padding: 20px 0 30px 0;
    overflow: hidden;
    width: 100%;
}

.categories-scroll-wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    padding: 10px 0 20px 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.categories-scroll-wrapper::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.categories-track {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 16px;
    padding: 0 20px;
    width: max-content;
    min-width: 100%;
    justify-content: flex-start;
}

.category-card {
    flex: 0 0 auto;
    width: 150px;
    max-width: 150px;
    transition: transform 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.category-card__link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px 12px 16px 12px;
    height: 100%;
    min-height: 130px;
    background: #FFFFFF;
    border-radius: 16px;
    border: 1px solid rgba(15, 23, 42, 0.04);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
    text-decoration: none;
    color: #1E293B;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.category-card__link:hover {
    transform: translateY(-4px);
    background: #FFFFFF;
    border-color: #FFFFFF;
    box-shadow: 0 12px 30px -8px rgba(15, 23, 42, 0.12), 0 4px 10px -4px rgba(15, 23, 42, 0.02);
}

.category-card__accent-line {
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0%;
    height: 3px;
    background: #2563EB;
    border-radius: 20px 20px 0 0;
    transform: translateX(-50%);
    transition: width 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.category-card__link:hover .category-card__accent-line {
    width: 40%;
}

.category-card__icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    background: #F8FAFC;
    border-radius: 14px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.category-card__link:hover .category-card__icon-wrap {
    background: #0F172A;
    transform: scale(0.95);
}

.category-card__icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
    transition: filter 0.3s ease;
}

.category-card__link:hover .category-card__icon {
    filter: brightness(0) invert(1);
}

.category-card__title {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    color: #1E293B;
    letter-spacing: -0.01em;
    transition: color 0.2s;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.category-card__link:hover .category-card__title {
    color: #0F172A;
}

/* --- Адаптив категорий --- */
@media (min-width: 768px) and (max-width: 991px) {
    .category-card {
        width: 160px;
        max-width: 160px;
    }
}

@media (min-width: 992px) {
    .category-card {
        width: 170px;
        max-width: 170px;
    }
}

@media (max-width: 576px) {
    .category-card {
        width: 130px;
        max-width: 130px;
    }
    .category-card__link {
        padding: 14px 8px 12px 8px;
        min-height: 110px;
        border-radius: 14px;
    }
    .category-card__title {
        font-size: 11px;
        -webkit-line-clamp: 2;
    }
    .category-card__icon-wrap {
        width: 36px;
        height: 36px;
        margin-bottom: 8px;
        border-radius: 12px;
    }
    .category-card__icon {
        width: 18px;
        height: 18px;
    }
    .categories-track {
        gap: 12px;
        padding: 0 16px;
    }
}

@media (max-width: 400px) {
    .category-card {
        width: 110px;
        max-width: 110px;
    }
    .category-card__link {
        padding: 12px 6px 10px 6px;
        min-height: 100px;
        border-radius: 12px;
    }
    .category-card__title {
        font-size: 10px;
        -webkit-line-clamp: 2;
    }
    .category-card__icon-wrap {
        width: 32px;
        height: 32px;
        margin-bottom: 6px;
        border-radius: 10px;
    }
    .category-card__icon {
        width: 16px;
        height: 16px;
    }
    .categories-track {
        gap: 10px;
        padding: 0 12px;
    }
}

@media (max-width: 340px) {
    .category-card {
        width: 95px;
        max-width: 95px;
    }
    .category-card__link {
        padding: 10px 4px 8px 4px;
        min-height: 90px;
        border-radius: 10px;
    }
    .category-card__title {
        font-size: 9px;
        -webkit-line-clamp: 2;
    }
    .category-card__icon-wrap {
        width: 28px;
        height: 28px;
        margin-bottom: 5px;
        border-radius: 8px;
    }
    .category-card__icon {
        width: 14px;
        height: 14px;
    }
    .categories-track {
        gap: 8px;
        padding: 0 10px;
    }
}

/* =========================================
   2.5. КУРСЫ ВАЛЮТ + СТАВКА ЦБ
   ========================================= */
.cbr-rate {
    display: flex;
    align-items: center;
    margin-left: 20px;
    font-size: 15px;
    font-weight: normal;
    color: #000;
}

@media (min-width: 901px) {
    .cbr-rate {
        white-space: nowrap;
    }
}

@media (max-width: 800px) {
    .cbr-rate {
        margin-top: 10px;
        margin-left: 0;
    }
}

/* =========================================
   3. ЛУЧШИЕ ПРЕДЛОЖЕНИЯ
   ========================================= */
.section-best-offers {
    padding: 60px 20px;
    background: transparent;
}
.section-best-offers__header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
}
.section-best-offers__title {
    font-size: clamp(28px, 4vw, 38px);
    font-weight: 800;
    color: #0F172A;
    margin: 0;
}
.section-best-offers__content {
    max-width: 1400px;
    margin: 0 auto;
}
.section-best-offers__content > * {
    width: 100%;
}
@media (max-width: 768px) {
    .section-best-offers {
        padding: 40px 16px;
    }
    .section-best-offers__header {
        margin-bottom: 30px;
    }
}

/* =========================================
   4. НОВОСТИ
   ========================================= */
.news-section {
    width: 100%;
    padding: 0;
    background: #f8fafc;
    box-sizing: border-box;
}
.news-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
    max-width: 100%;
    padding: 20px 0 0 0;
}
.news-head__title {
    font-size: 26px;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
}
.news-head__all {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    padding: 6px 14px;
    border-radius: 8px;
    transition: background 0.2s;
}
.news-head__all:hover {
    background: rgba(37, 99, 235, 0.08);
}
.news-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    width: 100%;
}
.news-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    border: 1px solid #eef2f6;
    transition: transform 0.3s, box-shadow 0.3s;
    width: 100%;
}
.news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}
.news-card__link {
    display: block;
    text-decoration: none;
    color: inherit;
    width: 100%;
}
.news-card__image-wrap {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #eef2f6;
}
.news-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s;
}
.news-card:hover .news-card__image {
    transform: scale(1.04);
}
.news-card__title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: #0f172a;
    padding: 14px 16px 8px;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.news-card:hover .news-card__title {
    color: #2563eb;
}
.news-card__meta {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0 16px 16px;
    font-size: 13px;
    color: #64748b;
}
.news-card__date {
    padding-right: 14px;
    border-right: 1px solid #e2e8f0;
}
.news-card__views {
    display: flex;
    align-items: center;
    gap: 5px;
}
.news-card__views svg {
    stroke: #94a3b8;
}
@media (max-width: 1024px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 18px;
    }
}
@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}
@media (max-width: 480px) {
    .news-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .news-head__title {
        font-size: 22px;
    }
    .news-card__title {
        font-size: 14px;
        padding: 12px 14px 6px;
    }
    .news-card__meta {
        font-size: 12px;
        padding: 0 14px 14px;
    }
}
@media (max-width: 380px) {
    .news-head {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* =========================================
   4.1. БЛОК "ЖУРНАЛ" (Табы с рубриками)
   ========================================= */
.section-journal {
    background: #fff;
    padding: 2em 0;
}
.journal-box {
    padding: 20px 0;
}

/* --- НАВИГАЦИЯ ТАБОВ --- */
.journal-tabs-nav {
    display: flex;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    padding-left: 20px;
    padding-right: 20px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.journal-tabs-nav::-webkit-scrollbar {
    display: none;
}
.journal-tab-btn {
    background: none;
    border: none;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-light);
    padding: 10px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}
.journal-tab-btn:hover {
    color: var(--secondary-color);
    background: var(--bg-light);
}
.journal-tab-btn.active {
    color: #fff;
    background: var(--secondary-color);
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}
.journal-tab-pane {
    display: none;
    animation: fadeIn 0.4s ease-in-out;
}
.journal-tab-pane.active {
    display: block;
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
.journal-grid {
    display: grid;
    gap: 20px;
    grid-template-columns: 1fr;
}
@media (min-width: 600px) {
    .journal-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 992px) {
    .journal-grid { grid-template-columns: repeat(4, 1fr); }
}
.journal-card {
    background: #fff;
    border-radius: var(--border-radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: transform 0.2s, box-shadow 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.journal-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-soft);
}
.journal-card__link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.journal-card__image {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
}
@media (min-width: 1200px) {
    .journal-card__image {
        height: 210px;
    }
}
.journal-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
    display: block;
}
.journal-card:hover .journal-card__img {
    transform: scale(1.05);
}
.journal-card__content {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.journal-card__title {
    font-size: 15px;
    line-height: 1.4;
    margin: 0;
    color: var(--text-main);
    font-weight: 700;
}
@media (max-width: 1024px) {
    .journal-tabs-nav {
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 5px;
        white-space: nowrap;
    }
    .journal-tab-btn {
        flex-shrink: 0;
        margin-right: 10px;
    }
}

/* =========================================
   6. ПОЧЕМУ ВЫБИРАЮТ
   ========================================= */
.section-why-us {
    padding: 60px 20px;
    background: #F8FAFC;
}
.section-why-us__title {
    text-align: center;
    font-size: clamp(28px, 4vw, 38px);
    font-weight: 800;
    color: #0F172A;
    margin-bottom: 8px;
}
.section-why-us__subtitle {
    text-align: center;
    font-size: clamp(16px, 1.2vw, 20px);
    color: #64748B;
    margin-bottom: 40px;
}
.section-why-us__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1400px;
    margin: 0 auto;
}
.advantage-card {
    background: white;
    padding: 80px 24px 24px;
    border-radius: 16px;
    border: 1px solid #E2E8F0;
    text-align: center;
    position: relative;
    transition: 0.2s;
}
.advantage-card:hover {
    border-color: #2563EB;
    box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}
.advantage-card__icon {
    position: absolute;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 56px;
    height: 56px;
    background: #EFF6FF;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.advantage-card__icon img {
    width: 28px;
    height: 28px;
}
.advantage-card__title {
    font-size: clamp(18px, 1.3vw, 22px);
    font-weight: 700;
    color: #0F172A;
    margin: 0 0 8px;
}
.advantage-card__text {
    font-size: clamp(14px, 1vw, 16px);
    line-height: 1.6;
    color: #475569;
    margin: 0;
}
@media (max-width: 900px) {
    .section-why-us__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 600px) {
    .section-why-us {
        padding: 40px 16px;
    }
    .section-why-us__grid {
        grid-template-columns: 1fr;
    }
    .advantage-card {
        padding: 72px 20px 20px;
    }
    .advantage-card__icon {
        width: 48px;
        height: 48px;
        top: 20px;
    }
    .advantage-card__icon img {
        width: 24px;
        height: 24px;
    }
}

/* =========================================
   8. ЧАСТО ИЩУТ
   ========================================= */
.popular-searches {
    padding: 60px 15px;
    background: #f8fafc;
}
.popular-searches__title {
    font-size: 32px;
    font-weight: 700;
    color: #0f172a;
    text-align: center;
    margin-bottom: 40px;
    letter-spacing: -0.5px;
}
.popular-searches__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}
.search-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px 20px 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transition: transform 0.25s ease, box-shadow 0.3s ease;
    border: 1px solid #e9edf2;
    display: flex;
    flex-direction: column;
}
.search-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
}
.search-card__title {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid #eef2f6;
    position: relative;
    flex-shrink: 0;
}
.search-card__title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 40px;
    height: 2px;
    background: #3b82f6;
    border-radius: 4px;
}
.search-card__list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}
.search-card__link {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    font-size: 15px;
    color: #334155;
    text-decoration: none;
    border-radius: 8px;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
    background: transparent;
    width: 100%;
    position: relative;
    gap: 8px;
}
.search-card__link::before {
    content: '›';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 700;
    color: #94a3b8;
    transition: color 0.2s ease, transform 0.2s ease;
    width: 24px;
    flex-shrink: 0;
}
.search-card__link:hover {
    background: #f1f5f9;
    color: #3b82f6;
    transform: translateX(4px);
}
.search-card__link:hover::before {
    color: #3b82f6;
    transform: translateX(2px);
}
.search-card__link:active {
    background: #e2e8f0;
    transform: scale(0.98);
}
@media (max-width: 768px) {
    .popular-searches {
        padding: 40px 10px;
    }
    .popular-searches__title {
        font-size: 26px;
        margin-bottom: 30px;
    }
    .popular-searches__grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 18px;
    }
    .search-card {
        padding: 18px 14px 16px;
    }
    .search-card__title {
        font-size: 16px;
        margin-bottom: 12px;
        padding-bottom: 10px;
    }
    .search-card__link {
        padding: 10px 12px;
        font-size: 14px;
    }
    .search-card__link::before {
        font-size: 18px;
        width: 20px;
    }
}
@media (max-width: 480px) {
    .popular-searches {
        padding: 30px 8px;
    }
    .popular-searches__title {
        font-size: 22px;
        margin-bottom: 24px;
    }
    .popular-searches__grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .search-card {
        padding: 16px 12px 14px;
        border-radius: 12px;
    }
    .search-card__title {
        font-size: 15px;
        margin-bottom: 10px;
        padding-bottom: 8px;
    }
    .search-card__list {
        gap: 2px;
    }
    .search-card__link {
        padding: 12px 10px;
        font-size: 14px;
        border-radius: 6px;
        min-height: 44px;
    }
    .search-card__link::before {
        font-size: 18px;
        width: 20px;
    }
    .search-card__link:hover {
        transform: none;
    }
}
@media (max-width: 360px) {
    .search-card__link {
        font-size: 13px;
        padding: 10px 8px;
        min-height: 40px;
    }
}

/* =========================================
   7. SEO-ТЕКСТ / СПОЙЛЕР (аккордеон)
   ========================================= */
.spoiler-wrap {
    margin-bottom: 12px;
    border: 1px solid var(--border-color, #E2E8F0);
    border-radius: var(--radius-md, 8px);
    background: #FFFFFF;
    box-shadow: var(--shadow-sm, 0 1px 2px 0 rgba(0, 0, 0, 0.03));
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
.spoiler-wrap:hover {
    border-color: #CBD5E1;
    box-shadow: var(--shadow-md, 0 4px 6px -2px rgba(0, 0, 0, 0.03));
}
.spoiler-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 16px 20px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--primary-color, #0F172A);
    background: #FFFFFF;
    border: none;
    border-radius: var(--radius-md, 8px);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
    text-align: left;
    position: relative;
    gap: 15px;
    margin: 0;
}
.spoiler-head.unfolded:after,
.spoiler-head.folded:after {
    content: none;
    display: none;
}
.spoiler-head:hover {
    background: #F8FAFC;
    color: var(--secondary-color, #2563EB);
}
.spoiler-head.active {
    color: var(--secondary-color, #2563EB);
    border-bottom: 1px solid var(--border-color, #E2E8F0);
    border-radius: var(--radius-md, 8px) var(--radius-md, 8px) 0 0;
}
.spoiler-head svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    transform: rotate(0deg);
    fill: none;
    stroke: var(--text-light, #64748B);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.spoiler-head.active svg {
    transform: rotate(180deg);
    stroke: var(--secondary-color, #2563EB);
}
.spoiler-body {
    padding: 20px 20px 24px;
    background: #FFFFFF;
    border: none;
    border-radius: 0 0 var(--radius-md, 8px) var(--radius-md, 8px);
    color: var(--text-main, #1E293B);
    font-size: 14px;
    line-height: 1.7;
}
.spoiler-body p {
    margin-bottom: 15px;
}
.spoiler-body p:last-child {
    margin-bottom: 0;
}
.spoiler-body ul,
.spoiler-body ol {
    margin-bottom: 15px;
}
@media (max-width: 767px) {
    .spoiler-head {
        padding: 14px 16px;
        font-size: 15px;
    }
    .spoiler-body {
        padding: 16px;
        font-size: 14px;
    }
    .spoiler-head svg {
        width: 18px;
        height: 18px;
    }
}
@media (max-width: 480px) {
    .spoiler-head {
        padding: 12px 14px;
        font-size: 14px;
    }
    .spoiler-body {
        padding: 14px;
        font-size: 13px;
        line-height: 1.6;
    }
}