/* Журнал — страница статьи /journal/<адрес> (pages/zhurnal-statya.htm, partials/journal/*), 08.10.2026.
   Подключается <link> в начале страницы, как pv-quiz.css; правка — поднять ?v= в шаблоне статьи.
   Цвета и шрифты — как у блоков карточки ЖК (pc-blocks.css): текст Inter, заголовки RFDewi, синий #137dff.
   Классы pj-card*, pj-grid, pj-chips*, pj-pager*, pj-feed* — у ленты (journal-list.css), здесь не трогаем. */

/* Отступ сверху — под закреплённую шапку сайта: её низ 148 px на ПК, до 184 px на 501–960 px, 48 px на телефоне
   (замер 08.10.2026 на /faq). */
.pj-article {
    padding: 176px 0 24px;
    color: #3f4757;
    font-family: "Inter", sans-serif;
}

.pj-narrow {
    width: 100%;
    max-width: 820px;
    margin-left: auto;
    margin-right: auto;
}

.pj-section-title {
    margin: 0 0 20px;
    color: #0d1321;
    font-family: "RFDewi", "MuseoSansCyrl", sans-serif;
    font-size: 30px;
    font-weight: 700;
    line-height: 1.2;
}

/* --- Шапка статьи --- */

.pj-crumbs { flex-wrap: wrap; margin-bottom: 20px; }

.pj-draft {
    margin: 0 0 16px;
    padding: 10px 14px;
    border-radius: 10px;
    background: #fff4e5;
    color: #8a4b00;
    font-size: 14px;
    line-height: 1.4;
}

.pj-head__rubric {
    display: inline-block;
    margin-bottom: 14px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #eef4ff;
    color: #137dff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
}

.pj-head__rubric:hover { background: #dce9ff; }

.pj-head__title {
    margin: 0;
    color: #0d1321;
    font-family: "RFDewi", "MuseoSansCyrl", sans-serif;
    font-size: 40px;
    font-weight: 700;
    line-height: 1.15;
}

/* Точка-разделитель стоит слева от каждого пункта и срезается у первого пункта строки:
   при переносе строка не начинается с точки. */
.pj-head__byline {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 0 0;
}

.pj-head__avatar {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    background: #eef4ff;
}

.pj-head__avatar--letter {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #137dff;
    font-family: "RFDewi", sans-serif;
    font-size: 19px;
    font-weight: 700;
}

.pj-head__meta {
    margin: 0;
    overflow: hidden;
    color: #74809a;
    font-size: 14px;
    line-height: 1.5;
}

.pj-head__meta-in {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 0;
    margin-left: -18px;
}

.pj-head__meta-in > * { position: relative; padding-left: 18px; }

.pj-head__meta-in > *::before {
    content: "·";
    position: absolute;
    left: 6px;
    color: #b6bfcf;
}

.pj-head__author { color: #1f2633; font-weight: 600; }

.pj-head__review {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 14px 0 0;
    padding: 7px 14px 7px 8px;
    border: 1px solid #cfe9d8;
    border-radius: 999px;
    background: #f1f9f4;
    color: #2f6b44;
    font-size: 13.5px;
    line-height: 1.35;
}

.pj-head__review b { color: #235436; font-weight: 600; }

.pj-head__check {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #2f9e55;
}

.pj-head__check svg {
    width: 12px;
    height: 12px;
    fill: none;
    stroke: #fff;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.pj-cover { margin: 28px 0 0; }

.pj-cover img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1200 / 630;
    object-fit: cover;
    border-radius: 16px;
    background: #eef1f5;
}

.pj-cover figcaption {
    margin-top: 8px;
    color: #74809a;
    font-size: 13px;
    line-height: 1.45;
}

.pj-lead {
    margin: 28px 0 0;
    color: #1f2633;
    font-size: 19px;
    line-height: 1.6;
}

/* --- Оглавление --- */

.pj-toc {
    margin: 28px 0 0;
    padding: 18px 22px;
    border: 1px solid #eaedf4;
    border-radius: 14px;
    background: #f5f7fb;
}

.pj-toc__title {
    display: block;
    color: #0d1321;
    font-size: 16px;
    font-weight: 600;
    list-style: none;
    cursor: pointer;
}

.pj-toc__title::-webkit-details-marker { display: none; }

.pj-toc__title::after {
    content: "";
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-left: 10px;
    border-right: 2px solid #74809a;
    border-bottom: 2px solid #74809a;
    transform: translateY(-3px) rotate(45deg);
    transition: transform .2s ease;
}

.pj-toc[open] .pj-toc__title::after { transform: translateY(0) rotate(225deg); }

.pj-toc__list { margin: 12px 0 0; padding: 0; list-style: none; }

.pj-toc__item { margin: 0; line-height: 1.45; }
.pj-toc__item + .pj-toc__item { margin-top: 8px; }
.pj-toc__item--h3 { padding-left: 18px; font-size: 14px; }

.pj-toc__item a { color: #137dff; text-decoration: none; }
.pj-toc__item a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* --- Текст статьи (поле content после ContentProcessor) --- */

.pj-text {
    margin-top: 28px;
    color: #3f4757;
    font-size: 17px;
    font-weight: 400;
    line-height: 1.7;
    overflow-wrap: break-word;
}

.pj-text > * { margin-top: 0; margin-bottom: 0; }
.pj-text > * + * { margin-top: 1em; }

.pj-text h2,
.pj-text h3,
.pj-text h4 {
    color: #0d1321;
    font-family: "RFDewi", "MuseoSansCyrl", sans-serif;
    font-weight: 700;
    line-height: 1.25;
    scroll-margin-top: 170px;
}

.pj-text h2 { font-size: 28px; }
.pj-text > h2 { margin-top: 1.8em; }
.pj-text h3 { font-size: 21px; }
.pj-text > h3 { margin-top: 1.5em; }
.pj-text h4 { font-family: "Inter", sans-serif; font-size: 17px; font-weight: 600; }
.pj-text > h2:first-child,
.pj-text > h3:first-child { margin-top: 0; }

.pj-text b,
.pj-text strong { color: #1f2633; font-weight: 600; }

.pj-text a { color: #137dff; text-decoration: underline; text-underline-offset: 3px; }
.pj-text a:hover { color: #0a63d6; text-decoration: none; }

.pj-text ul,
.pj-text ol { padding-left: 1.4em; }
.pj-text ul { list-style: disc; }
.pj-text ol { list-style: decimal; }
.pj-text li + li { margin-top: .4em; }
.pj-text li::marker { color: #137dff; }

.pj-text blockquote {
    padding: 4px 0 4px 20px;
    border-left: 3px solid #137dff;
    color: #1f2633;
}

/* «Мнение Михаила» внутри текста (md_to_post.py): шапка — как у блока эксперта карточки ЖК (.pv-expert*, pc-blocks.css). */
.pj-text .pj-quote {
    margin-top: 1.6em;
    margin-bottom: 1.6em;
    padding: 22px 26px 24px;
    background: #eef5ff;
    border-left: 4px solid #137dff;
    border-radius: 4px 16px 16px 4px;
}
.pj-quote .pv-expert { gap: 14px; margin-bottom: 14px; }
.pj-quote .pv-expert__photo { width: 56px; height: 56px; background: #fff; }
.pj-text .pj-quote .pv-expert__photo img { max-width: none; border-radius: 0; }
.pj-quote .pv-expert__name { font-size: 17px; }
.pj-quote .pv-expert__position { font-size: 13px; }
.pj-text .pj-quote__text { margin: 0; padding: 0; border: 0; }
.pj-quote__text > * { margin: 0; }
.pj-quote__text > * + * { margin-top: .75em; }
@media (max-width: 500px) {
    .pj-text .pj-quote { padding: 18px 16px 20px; }
}

.pj-text img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

.pj-text figure figcaption { margin-top: 8px; color: #74809a; font-size: 13px; line-height: 1.45; }

.pj-text iframe { display: block; width: 100%; max-width: 100%; border: 0; border-radius: 12px; }

/* Таблицы — в обёртке .pj-table (ContentProcessor). На телефоне строка — карточка, подпись столбца
   из data-label (ставит ContentProcessor): прокрутку вбок на телефоне не замечали, правка 09.10.2026. */
.pj-table {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #d5dbe7;
    border-radius: 12px;
}

.pj-table table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 15px; line-height: 1.45; }

.pj-table th,
.pj-table td { padding: 10px 14px; border-bottom: 1px solid #dfe4ee; text-align: left; vertical-align: top; }

.pj-table th + th,
.pj-table td + td { border-left: 1px solid #dfe4ee; }
.pj-table th { background: #eef2f9; color: #1f2633; font-weight: 600; }
.pj-table tr:last-child td { border-bottom: 0; }

@media (max-width: 600px) {
    .pj-table--cards { overflow: visible; border: 0; border-radius: 0; }
    .pj-table--cards table,
    .pj-table--cards tbody,
    .pj-table--cards tr,
    .pj-table--cards td { display: block; width: auto; min-width: 0; }
    .pj-table--cards thead { display: none; }
    .pj-table--cards tr {
        margin-bottom: 10px;
        padding: 14px 16px;
        border: 1px solid #d5dbe7;
        border-radius: 12px;
        background: #fff;
    }
    .pj-table--cards td { padding: 0; border: 0; }
    .pj-table--cards td + td { margin-top: 10px; border: 0; }
    .pj-table--cards td:first-child { color: #0d1321; font-size: 16px; font-weight: 600; }
    .pj-table--cards td + td::before {
        content: attr(data-label);
        display: block;
        margin-bottom: 2px;
        color: #74809a;
        font-size: 13px;
    }
}

/* Картинка или схема в тексте: <figure class="pj-figure"><picture> — телефонная версия через <source>. */
.pj-text .pj-figure { margin: 1.6em 0; }
.pj-text .pj-figure img { width: 100%; border: 1px solid #eaedf4; border-radius: 16px; background: #fff; }
.pj-text .pj-figure figcaption { margin-top: 10px; }

/* Раздел-предложение агентства внутри текста: <section class="pj-offer"> (md статьи), правка 09.10.2026. */
.pj-text .pj-offer {
    margin-top: 2.2em;
    padding: 30px 32px 28px;
    border: 1px solid #d6e6ff;
    border-top: 4px solid #137dff;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 32px rgba(13, 19, 33, .06);
}
.pj-offer > * { margin-top: 0; margin-bottom: 0; }
.pj-offer > * + * { margin-top: 14px; }
.pj-offer__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #eef5ff;
    color: #137dff;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: .03em;
    text-transform: uppercase;
}
.pj-offer__badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #137dff; }
.pj-text .pj-offer h2 { margin-top: 12px; font-size: 26px; }
.pj-offer__lead { color: #0d1321; font-weight: 600; }

.pj-text .pj-offer__steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 0;
    list-style: none;
    counter-reset: pj-step;
}
.pj-text .pj-offer__steps li {
    position: relative;
    margin: 0;
    padding: 52px 16px 16px;
    border-radius: 14px;
    background: #f5f7fb;
    font-size: 15px;
    line-height: 1.5;
    counter-increment: pj-step;
}
.pj-offer__steps li::before {
    content: counter(pj-step);
    position: absolute;
    top: 14px;
    left: 16px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #137dff;
    color: #fff;
    font: 600 14px/28px "Inter", sans-serif;
    text-align: center;
}
.pj-text .pj-offer__steps b { display: block; color: #0d1321; }

.pj-offer__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pj-offer > .pj-offer__actions { margin-top: 20px; }
.pj-text .pj-offer .pj-btn,
.pj-text .pj-offer .pj-btn:hover { color: #fff; text-decoration: none; }
.pj-text .pj-offer .pj-btn--outline { background: transparent; color: #137dff; }
.pj-text .pj-offer .pj-btn--outline:hover,
.pj-text .pj-offer .pj-btn--outline:focus-visible { border-color: #137dff; background: #137dff; color: #fff; }
.pj-offer__more { font-size: 15px; }

@media (max-width: 760px) {
    .pj-text .pj-offer__steps { grid-template-columns: 1fr; gap: 8px; }
    .pj-text .pj-offer__steps li { padding: 14px 16px 14px 58px; }
    .pj-offer__steps li::before { top: 14px; }
}
@media (max-width: 600px) {
    .pj-text .pj-offer { padding: 22px 16px 20px; border-radius: 16px; }
    .pj-text .pj-offer h2 { font-size: 22px; }
    .pj-offer__actions { flex-direction: column; }
    .pj-text .pj-figure { margin-left: -8px; margin-right: -8px; }
}

/* --- Призывы --- */

.pj-cta {
    margin: 36px auto;
    padding: 26px 28px;
    border-radius: 18px;
    background: #0d1321;
    color: #fff;
}

.pj-cta__title {
    margin: 0;
    font-family: "RFDewi", "MuseoSansCyrl", sans-serif;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.25;
}

.pj-cta__text { margin: 8px 0 0; color: #c9d1e1; font-size: 16px; line-height: 1.55; }

.pj-cta__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }

.pj-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 12px 20px;
    border: 1px solid #137dff;
    border-radius: 10px;
    background: #137dff;
    color: #fff;
    font-family: "Inter", sans-serif;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease;
}

.pj-btn:hover,
.pj-btn:focus-visible { background: #0a63d6; border-color: #0a63d6; color: #fff; }

.pj-btn .icon { width: 16px; height: 16px; fill: currentColor; }

.pj-btn--ghost { border-color: rgba(255, 255, 255, .35); background: transparent; }
.pj-btn--ghost:hover,
.pj-btn--ghost:focus-visible { border-color: #fff; background: rgba(255, 255, 255, .08); }

.pj-cta--end { margin-top: 8px; margin-bottom: 40px; }

/* Квиз, калькулятор и осмотр в середине статьи — свои секции сайта, только отступы. */
.pj-cta-block { margin: 24px 0; }

/* У калькулятора и осмотра на сайте 7.5em сверху и снизу и линия сверху — разделитель блоков главной.
   В тексте это дыра в полэкрана: отступ сверху как у раздела, снизу до следующего H2 столько же. */
.pj-cta-block.section { margin: 48px 0 20px; }
.pj-cta-block .big_form__container,
.pj-cta-block .inspection__container { padding: 0; border-top: 0; }
@media (max-width: 500px) {
    .pj-cta-block.section { margin-top: 36px; margin-bottom: 8px; }
    .pj-cta-block .big_form__container,
    .pj-cta-block .inspection__container { padding: 0 1em; }
}

/* Осмотр: на ПК справа картинка с машиной — свой заголовок или текст редактора не должен под неё заходить. */
@media (min-width: 901px) {
    .pj-cta-block .inspection__form .section_block { max-width: 560px; }
}

/* --- Мнение эксперта --- */

.pj-expert {
    margin-top: 44px;
    padding: 26px 28px;
    border: 1px solid #eaedf4;
    border-radius: 18px;
    background: #fff;
}

.pj-expert__label {
    margin: 0 0 16px;
    color: #137dff;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .06em;
    line-height: 1.2;
    text-transform: uppercase;
}

.pj-expert .pv-expert { margin-bottom: 18px; }

.pj-expert__text {
    position: relative;
    padding-left: 20px;
    color: #1f2633;
    font-size: 16px;
    line-height: 1.7;
}

.pj-expert__text::before {
    content: "";
    position: absolute;
    top: 4px;
    bottom: 4px;
    left: 0;
    width: 3px;
    border-radius: 3px;
    background: #137dff;
}

.pj-expert__text > * { margin: 0; }
.pj-expert__text > * + * { margin-top: .9em; }

.pj-expert__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 20px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #eef1f5;
}

.pj-expert a.pv-desc__call,
.pj-expert a.pv-desc__call:hover { color: #fff; text-decoration: none; }
.pj-expert__foot .expert-review__alt { margin-top: 0; }

/* --- Подборка ЖК --- */

.pj-zk { margin-top: 48px; }

.pj-zk__note { margin: -10px 0 0; color: #74809a; font-size: 14px; line-height: 1.45; }

.pj-zk .pj-zk__grid { margin-top: 18px; }

.pj-zk__links { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 0; padding: 0; list-style: none; }

.pj-zk__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border: 1px solid #d8e3f5;
    border-radius: 10px;
    color: #137dff;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
}

.pj-zk__link:hover { border-color: #137dff; background: #eef4ff; }

/* --- Вопросы и ответы (стили pc-faq — main.css) --- */

.pj-faq { padding-bottom: 32px; }
.pj-faq .pc-faq__answer p + p { margin-top: .8em; }

/* --- Автор --- */

.pj-author {
    margin-top: 8px;
    padding: 24px 0 8px;
    border-top: 1px solid #eef1f5;
}

.pj-author__label {
    margin: 0 0 14px;
    color: #74809a;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .06em;
    line-height: 1.2;
    text-transform: uppercase;
}

.pj-author__card { display: flex; align-items: flex-start; gap: 16px; }

.pj-author__photo {
    flex: none;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    background: #eef4ff;
}

.pj-author__photo--letter {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #137dff;
    font-family: "RFDewi", sans-serif;
    font-size: 32px;
    font-weight: 700;
}

.pj-author__name { margin: 4px 0 0; color: #0d1321; font-family: "RFDewi", sans-serif; font-size: 20px; font-weight: 700; line-height: 1.25; }
.pj-author__name a { color: inherit; text-decoration: none; }
.pj-author__name a:hover { color: #137dff; }
.pj-author__job { margin: 4px 0 0; color: #74809a; font-size: 14px; line-height: 1.45; }
.pj-author__bio { margin: 10px 0 0; color: #3f4757; font-size: 15px; line-height: 1.6; }
.pj-author__links { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 10px 0 0; font-size: 14px; }
.pj-author__links a { color: #137dff; text-decoration: none; }
.pj-author__links a:hover { text-decoration: underline; }

.pj-author__review {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 16px 0 0;
    padding: 12px 16px;
    border: 1px solid #dfeee5;
    border-radius: 12px;
    background: #f4faf6;
    color: #2f5e3b;
    font-size: 14px;
    line-height: 1.5;
}

.pj-author__review-photo {
    flex: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    background: #eef4ff;
}

.pj-author__review-check {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #2f9e55;
}

.pj-author__review-check svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: #fff;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.pj-author__review-text { margin: 0; }
.pj-author__review b { font-weight: 600; }

/* --- Читайте также (карточки — journal-list.css) --- */

.pj-related { margin-top: 40px; padding: 40px 0 56px; background: #f5f7fb; }

/* --- Планшет и телефон --- */

@media (max-width: 960px) {
    .pj-article { padding-top: 200px; }
}

@media (max-width: 900px) {
    .pj-head__title { font-size: 32px; }
    .pj-section-title { font-size: 26px; }
    .pj-text h2 { font-size: 24px; }
    .pj-text h3 { font-size: 19px; }
}

@media (max-width: 600px) {
    .pj-article { padding-top: 210px; }
    .pj-head__title { font-size: 27px; line-height: 1.2; }
    .pj-head__meta { font-size: 13px; }
    .pj-head__byline { gap: 10px; }
    .pj-head__avatar { width: 38px; height: 38px; }
    .pj-head__avatar--letter { font-size: 17px; }
    .pj-head__review { align-items: flex-start; padding: 8px 14px 8px 10px; border-radius: 14px; }
    .pj-head__check { margin-top: 1px; }
    .pj-author__review { align-items: flex-start; gap: 12px; }
    .pj-cover { margin-top: 20px; margin-left: -8px; margin-right: -8px; }
    .pj-cover img { border-radius: 12px; }
    .pj-lead { margin-top: 22px; font-size: 17px; }
    .pj-toc { padding: 14px 16px; }
    .pj-text { font-size: 16px; }
    .pj-text h2 { font-size: 22px; }
    .pj-text h3 { font-size: 18px; }
    .pj-section-title { font-size: 23px; }
    .pj-cta { margin: 28px auto; padding: 22px 18px; border-radius: 16px; }
    .pj-cta__title { font-size: 21px; }
    .pj-cta__actions { flex-direction: column; }
    .pj-btn { width: 100%; }
    .pj-expert { margin-top: 32px; padding: 20px 16px; border-radius: 16px; }
    .pj-expert__text { padding-left: 14px; font-size: 15px; }
    .pj-expert__foot .pv-desc__call { width: 100%; justify-content: center; }
    .pj-author__photo { width: 64px; height: 64px; }
    .pj-related { padding: 32px 0 40px; }
}

@media (max-width: 500px) {
    .pj-article { padding-top: 84px; }
    .pj-text h2, .pj-text h3, .pj-text h4 { scroll-margin-top: 68px; }
    /* на телефоне крошки — одна ссылка «‹ рубрика», плашка повторила бы её */
    .pj-head__rubric { display: none; }
}
