/* ==========================================================================
   Кристалл Клин — оформление сайта.
   Основа стилистики — Future Imperfect (HTML5 UP): широкие межбуквенные
   интервалы в заголовках, тонкие рамки, много воздуха. Палитра своя, холодная.
   ========================================================================== */

/* Фирменная палитра:
   тёмно-синий #001B46 · синий #0048C5 · яркий голубой #00AFFF
   светло-голубой #8DDCFF · ледяной #DDF5FF · белый #FFFFFF
   Оттенки ниже (текст, линии) — производные от тёмно-синего, чтобы
   на странице не появлялось посторонних серых. */
:root {
    --navy:          #001B46;
    --blue:          #0048C5;
    --sky:           #00AFFF;
    --sky-light:     #8DDCFF;
    --ice:           #DDF5FF;

    --accent:        var(--blue);
    --accent-dark:   #003699;
    --accent-soft:   var(--ice);
    --ink:           #001B46;
    --ink-soft:      #46608c;
    --ink-faint:     #7a91b4;
    --line:          #cfe4f4;
    --bg:            #ffffff;
    --bg-soft:       #f2fafe;
    --dark:          var(--navy);
    --gold:          var(--sky);
    --radius:        6px;
    --container:     1400px;
    --narrow:        780px;   /* ширина колонки чтения внутри контейнера */
    --rail:          320px;   /* правый рейл портала */
    --font: "Golos Text", "Segoe UI", Arial, sans-serif;
    --font-display: "Onest", "Golos Text", "Segoe UI", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 16px/1.65 var(--font);
}

img { max-width: 100%; height: auto; }

/* полоса прокрутки резервируется всегда — иначе центр контейнера прыгает
   на 8px между короткими и длинными страницами */
html { scrollbar-gutter: stable; }

.site-main { padding-top: 45px; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }

h1, h2, h3, h4 {
    margin: 0 0 .6em;
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -.015em;
    color: var(--dark);
}

h1 { font-size: 2.1rem; }
h2 { font-size: 1.55rem; }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1.1em; }

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

/* Ширина чтения. Контейнер везде один (.container, как на главной), а колонка
   текста ограничивается внутри него и прижата влево — поэтому крошки,
   заголовок, текст и FAQ начинаются с одной вертикали на всех страницах. */
.readable { max-width: var(--narrow); }

/* --- Шапка ---------------------------------------------------------------- */

/* Шапка белая. Логотип собран из двух частей: знак-кристалл вырезан из
   исходного макета с прозрачным фоном, надпись набрана фирменным шрифтом —
   так она остаётся резкой на любом экране и не тащит за собой тёмную подложку. */
.site-header {
    border-bottom: 1px solid var(--line);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 20;
}

.site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 84px;
}

/* Поиск — отдельная компактная строка на всю ширину, с разделителем сверху.
   Делит инвариант .site-header__inner с верхней строкой, но без высокой высоты. */
.site-header__search { min-height: 0; padding: 12px 0 14px; border-top: 1px solid var(--line); }
.site-header__search .site-search { flex: none; width: 100%; max-width: none; }
.site-header__search .site-search__input { padding-top: 9px; padding-bottom: 9px; }

.logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--dark);
    text-decoration: none;
}
.logo:hover { text-decoration: none; color: var(--dark); }

/* Логотип — картинкой как есть, только уменьшенной */
.logo picture, .logo img { display: block; height: 74px; width: auto; }

@media (max-width: 640px) {
    .logo picture, .logo img { height: 50px; }
}

.site-nav ul {
    display: flex;
    gap: 28px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-nav a {
    color: var(--ink);
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--accent); border-bottom-color: var(--sky); text-decoration: none; }

/* --- Секции --------------------------------------------------------------- */

.site-main { min-height: 60vh; }

.section { padding: 48px 0; }
.section--tight { padding: 32px 0; }
.section--soft { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.section__head { max-width: 780px; margin-bottom: 28px; }
.section__head p { color: var(--ink-soft); margin-bottom: 0; }

.section__head--row {
    max-width: none;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}
.section__head--row h2 { margin-bottom: 0; }
.section__more {
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.muted-note { color: var(--ink-soft); margin: 0; }

.page-intro { padding-top: 44px; padding-bottom: 4px; }
.page-intro + .section { padding-top: 28px; }
.page-intro h1 { margin-bottom: .35em; }
.page-intro__lead { font-size: 1.08rem; color: var(--ink-soft); max-width: 760px; }

.breadcrumbs {
    padding-top: 18px;
    padding-bottom: 18px;
    font-size: .84rem;
    color: var(--ink-faint);
}
.breadcrumbs ol {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    list-style: none;
    white-space: nowrap;
    overflow: hidden;
}
.breadcrumbs li { display: flex; align-items: center; min-width: 0; }
.breadcrumbs li:not(:first-child)::before {
    content: "›";
    margin: 0 10px;
    color: var(--sky-light);
    font-size: 1rem;
    line-height: 1;
    flex: none;
}
.breadcrumbs li:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--ink-soft);
}
.breadcrumbs a { color: var(--ink-faint); flex: none; }
.breadcrumbs a:hover { color: var(--accent); text-decoration: none; }

/* На узком экране полная цепочка не помещается — остаётся только ссылка
   на родительский раздел со стрелкой назад */
@media (max-width: 640px) {
    .breadcrumbs li { display: none; }
    .breadcrumbs li:nth-last-child(2) { display: flex; }
    .breadcrumbs li:nth-last-child(2)::before {
        content: "‹";
        margin: 0 8px 0 0;
        color: var(--sky-light);
        font-size: 1rem;
        line-height: 1;
    }
}

/* --- Вкладки сегментов ---------------------------------------------------- */

.segments {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 28px;
    padding: 0;
    list-style: none;
}

.segments a {
    display: inline-block;
    padding: 8px 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: .86rem;
    font-weight: 600;
    color: var(--ink-soft);
    background: var(--bg);
}
.segments a:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.segments .is-active a {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

/* --- Таблица рейтинга ----------------------------------------------------- */

.rating {
    width: 100%;
    border-collapse: collapse;
    font-size: .95rem;
}

.rating th {
    text-align: left;
    padding: 12px 14px;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .11em;
    text-transform: uppercase;
    color: var(--ink-faint);
    border-bottom: 2px solid var(--line);
    white-space: nowrap;
}

.rating td {
    padding: 18px 14px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.rating tbody tr:hover { background: var(--bg-soft); }

.rating__pos {
    width: 62px;
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--ink-faint);
    font-variant-numeric: tabular-nums;
}
.rating tr:nth-child(1) .rating__pos,
.rating tr:nth-child(2) .rating__pos,
.rating tr:nth-child(3) .rating__pos { color: var(--gold); }

.rating__name { font-size: 1.06rem; font-weight: 700; color: var(--dark); }
.rating__name a { color: var(--dark); }
.rating__name a:hover { color: var(--accent); text-decoration: none; }
.rating__desc { margin: 6px 0 0; color: var(--ink-soft); font-size: .9rem; }

.rating__meta {
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.rating__meta li {
    font-size: .78rem;
    color: var(--ink-soft);
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 4px;
    padding: 2px 8px;
    max-width: 230px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rating__score {
    width: 96px;
    text-align: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--accent);
    font-variant-numeric: tabular-nums;
}
.rating__score small {
    display: block;
    font-size: .68rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink-faint);
}

.rating__go { width: 130px; text-align: right; }

.btn {
    display: inline-block;
    padding: 9px 18px;
    border: 1px solid var(--accent);
    border-radius: var(--radius);
    background: var(--bg);
    color: var(--accent);
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    white-space: nowrap;
}
.btn:hover { background: var(--accent); color: #fff; text-decoration: none; }
.btn--solid { background: var(--accent); color: #fff; }
.btn--solid:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.btn--ghost { border-color: var(--line); color: var(--ink-soft); }
.btn--ghost:hover { background: var(--ink-soft); border-color: var(--ink-soft); color: #fff; }

.table-wrap { overflow-x: auto; }

/* --- Карточка компании ---------------------------------------------------- */

.company-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 32px;
    padding-top: 22px;
    padding-bottom: 36px;
    border-bottom: 1px solid var(--line);
}

.company-head__main { flex: 1 1 420px; }
.company-head__main h1 { margin-bottom: .3em; }

.company-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }

.badge {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .04em;
    background: var(--accent-soft);
    color: var(--accent-dark);
}
.badge--score { background: var(--dark); color: #fff; }
.badge--muted { background: var(--bg-soft); color: var(--ink-soft); border: 1px solid var(--line); }

.company-head__aside {
    flex: 0 0 260px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px;
    background: var(--bg-soft);
}
.company-head__aside dl { margin: 0; font-size: .9rem; }
.company-head__aside dt {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink-faint);
    margin-top: 12px;
}
.company-head__aside dt:first-child { margin-top: 0; }
.company-head__aside dd { margin: 2px 0 0; color: var(--ink); word-break: break-word; }

.company-body { padding-top: 32px; padding-bottom: 40px; }
.company-body__text { max-width: 760px; }
.company-body__text h2 { margin-top: 1.6em; }
.company-body__text ul, .company-body__text ol { padding-left: 22px; color: var(--ink); }
.company-body__text img {
    max-width: 100%;
    height: auto;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 10px 30px -18px rgba(15, 35, 60, .25);
    margin: 6px 0 10px;
}

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 24px; padding: 0; list-style: none; }
.tags li {
    padding: 6px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: .84rem;
    color: var(--ink-soft);
    background: var(--bg);
}

.company-nav {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding-top: 28px;
    padding-bottom: 72px;
    border-top: 1px solid var(--line);
    font-size: .9rem;
}
.company-nav__prev,
.company-nav__next {
    flex: 0 1 340px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px 18px;
    background: var(--bg);
    transition: border-color .15s, box-shadow .15s;
}
.company-nav__prev:hover,
.company-nav__next:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 22px -14px rgba(15, 35, 60, .35);
}
.company-nav span { display: block; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 4px; }
.company-nav a { font-weight: 600; }
.company-nav a:hover { text-decoration: none; }
.company-nav__prev a::before { content: '← '; color: var(--ink-faint); }
.company-nav__next a::after { content: ' →'; color: var(--ink-faint); }
.company-nav__next { text-align: right; margin-left: auto; }
@media (max-width: 640px) {
    .company-nav { flex-direction: column; padding-bottom: 48px; }
    .company-nav__prev, .company-nav__next { flex-basis: auto; }
    .company-nav__next { text-align: left; margin-left: 0; }
}

/* --- Блог ----------------------------------------------------------------- */

.posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 28px; }
.posts--3 { grid-template-columns: repeat(3, 1fr); }

.post-card {
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg);
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 2px rgba(0, 27, 70, .05);
    transition: box-shadow .25s ease, transform .25s ease, border-color .25s ease;
}
.post-card:hover {
    box-shadow: 0 14px 32px rgba(0, 27, 70, .14);
    border-color: var(--sky-light);
    transform: translateY(-3px);
}

.post-card__img {
    display: block;
    aspect-ratio: 3 / 2;
    overflow: hidden;
    background: var(--bg-soft);
}
.post-card__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .45s ease;
}
.post-card:hover .post-card__img img { transform: scale(1.05); }

.post-card__body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.post-card__date { font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 8px; }
.post-card h3 {
    font-size: 1.14rem;
    line-height: 1.35;
    margin-bottom: .5em;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.post-card h3 a { color: var(--dark); }
.post-card h3 a:hover { color: var(--accent); text-decoration: none; }
.post-card p {
    color: var(--ink-soft);
    font-size: .92rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.post-card__more { margin-top: auto; padding-top: 12px; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 36px; }
.pagination a, .pagination span {
    min-width: 40px;
    padding: 8px 12px;
    text-align: center;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    font-size: .9rem;
    color: var(--ink-soft);
}
.pagination .is-current { background: var(--accent); border-color: var(--accent); color: #fff; }

/* --- Статья --------------------------------------------------------------- */

.article-hero { padding: 28px 0 8px; }

/* Обложка статьи: кадр во всю ширину, тёмный градиент снизу, белый текст поверх */
/* обложка прилегает к шапке — верхний отступ основной области ей не нужен */
.site-main:has(.article-cover) { padding-top: 0; }

.article-cover {
    position: relative;
    min-height: 440px;
    display: flex;
    align-items: flex-end;
    background: var(--dark);
    overflow: hidden;
}

.article-cover__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.article-cover__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
        rgba(0, 27, 70, .55) 0%,
        rgba(0, 27, 70, .35) 30%,
        rgba(0, 27, 70, .72) 62%,
        rgba(0, 27, 70, .94) 100%);
}

.article-cover__inner {
    position: relative;
    padding-top: 64px;
    padding-bottom: 40px;
    color: #fff;
}
.article-cover__inner h1 {
    color: #fff;
    margin-bottom: .35em;
    text-shadow: 0 2px 18px rgba(0, 0, 0, .4);
}
.article-cover__lead {
    margin: 0;
    max-width: var(--narrow);
    color: rgba(255, 255, 255, .9);
    font-size: 1.05rem;
    text-shadow: 0 1px 14px rgba(0, 0, 0, .45);
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
    font-size: .85rem;
    color: var(--ink-soft);
}
.article-meta__author { font-weight: 700; color: var(--ink); }

.article-body { padding-top: 32px; padding-bottom: 40px; }
.article-body > h2:first-child { margin-top: 0; }
.article-body h2 { margin-top: 1.9em; }
.article-body h3 { margin-top: 1.5em; }
.article-body ul, .article-body ol { padding-left: 22px; margin: 0 0 1.15em; }
.article-body li { margin-bottom: .4em; }

/* Иллюстрация внутри текста */
.article-fig { margin: 34px 0; }
.article-fig img {
    width: 100%;
    display: block;
    border-radius: var(--radius);
}
.article-fig figcaption {
    margin-top: 10px;
    font-size: .85rem;
    line-height: 1.5;
    color: var(--ink-faint);
}

/* --- FAQ ------------------------------------------------------------------ */


.faq__item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq__q { font-weight: 700; color: var(--dark); margin-bottom: 6px; }
.faq__a { color: var(--ink-soft); margin: 0; }

/* --- 404 ------------------------------------------------------------------ */

.error-404 { padding: 80px 0; text-align: center; }
.error-404 __code { font-size: 4rem; }
.error-404 h1 { font-size: 3.4rem; color: var(--accent); margin-bottom: .2em; }

/* --- Подвал --------------------------------------------------------------- */

.site-footer {
    border-top: 1px solid var(--line);
    background: var(--dark);
    color: var(--sky-light);
}
.site-footer a { color: var(--sky-light); }
.site-footer a:hover { color: #fff; }

.site-footer__inner {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    justify-content: space-between;
    padding-top: 40px;
    padding-bottom: 28px;
}
.site-footer__col { flex: 1 1 280px; }
.site-footer__brand {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: .04em;
    color: #fff;
    margin-bottom: 10px;
}
.site-footer__note { font-size: .88rem; color: #a8cbe8; max-width: 520px; margin: 0; }
.site-footer__links ul { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 18px; }
.site-footer__links a { font-size: .82rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }

.site-footer__bottom {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: space-between;
    padding-top: 16px;
    padding-bottom: 28px;
    border-top: 1px solid rgba(141, 220, 255, .16);
    font-size: .8rem;
    color: #7fa6cd;
}

/* --- Адаптив -------------------------------------------------------------- */

@media (max-width: 900px) {
    h1 { font-size: 1.75rem; }
    .article-cover { min-height: 320px; }
    .article-cover__inner { padding-top: 40px; padding-bottom: 28px; }
    .posts--3 { grid-template-columns: repeat(2, 1fr); }
    .site-header__inner { min-height: 66px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
    .site-nav ul { gap: 18px; }
    .company-head__aside { flex: 1 1 100%; }
}

@media (max-width: 640px) {
    .container, .narrow { padding: 0 16px; }
    .article-cover { min-height: 260px; }
    .article-fig { margin: 24px 0; }
    .posts--3 { grid-template-columns: 1fr; }
    .logo__text { font-size: 1.1rem; }
    .logo__text small { display: none; }
    .rating th:nth-child(3), .rating td:nth-child(3) { display: none; }
    .rating__go { width: auto; }
    .rating td { padding: 14px 8px; }
    .section { padding: 32px 0; }
}

/* Скриншоты сайта компании в описании карточки */
.company-body__text figure { margin: 24px 0; }
.company-body__text figure img {
    display: block;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}
.company-body__text figcaption {
    margin-top: 8px;
    font-size: .86rem;
    color: var(--ink-faint);
}

/* ==========================================================================
   Страница статьи: читательская колонка
   Наборный принцип — статья набирается как в журнале: узкая колонка (68–72
   знака в строке), крупный кегль, спокойный межстрочный интервал. Разделы
   размечены не номерами (материал не является пошаговой инструкцией целиком),
   а тонкой чертой фирменного голубого — она же связывает оглавление с текстом.
   ========================================================================== */

.article-body {
    font-size: 1.09rem;
    line-height: 1.78;
    color: #17325c;
}

/* лид — первый абзац после оглавления читается крупнее остального текста */
.article-body > p:first-of-type {
    font-size: 1.2rem;
    line-height: 1.65;
    color: var(--navy);
}

.article-body h2 {
    position: relative;
    margin-top: 2.2em;
    margin-bottom: .7em;
    padding-top: 22px;
    font-size: 1.62rem;
    letter-spacing: -.02em;
    scroll-margin-top: 96px;
}
.article-body h2::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 42px;
    height: 3px;
    background: var(--sky);
    border-radius: 2px;
}

.article-body h3 { font-size: 1.22rem; margin-top: 1.7em; }

.article-body ul { list-style: none; padding-left: 0; }
.article-body ul li {
    position: relative;
    padding-left: 26px;
    margin-bottom: .55em;
}
.article-body ul li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: .72em;
    width: 7px;
    height: 7px;
    background: var(--sky);
    transform: rotate(45deg);
}

.article-body ol { padding-left: 22px; }
.article-body ol li::marker { color: var(--accent); font-weight: 700; }

.article-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 28px 0;
    font-size: .96rem;
}
.article-body th {
    text-align: left;
    padding: 12px 14px;
    background: var(--ice);
    color: var(--navy);
    font-family: var(--font-display);
    font-size: .8rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.article-body td { padding: 12px 14px; border-bottom: 1px solid var(--line); }

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

.toc {
    margin: 0 0 36px;
    padding: 22px 24px 24px;
    background: var(--ice);
    border-radius: 10px;
}
.toc__title {
    margin: 0 0 12px;
    font-family: var(--font-display);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--accent);
}
.toc ol {
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: toc;
    columns: 2;
    column-gap: 32px;
}
.toc li {
    counter-increment: toc;
    break-inside: avoid;
    margin-bottom: 9px;
    padding-left: 30px;
    position: relative;
    font-size: .95rem;
    line-height: 1.45;
}
.toc li::before {
    content: counter(toc, decimal-leading-zero);
    position: absolute;
    left: 0;
    top: .1em;
    font-family: var(--font-display);
    font-size: .78rem;
    font-weight: 700;
    color: var(--sky);
    font-variant-numeric: tabular-nums;
}
.toc a { color: var(--navy); text-decoration: none; border-bottom: 1px solid transparent; }
.toc a:hover { color: var(--accent); border-bottom-color: var(--sky-light); }

/* --- Подписи к иллюстрациям ---------------------------------------------- */

.article-fig figcaption {
    padding-left: 14px;
    border-left: 3px solid var(--sky-light);
}

/* --- Обложка: надзаголовочная строка -------------------------------------- */

.article-cover__eyebrow {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    margin-bottom: 16px;
    font-family: var(--font-display);
    font-size: .76rem;
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 0 1px 10px rgba(0, 27, 70, .55);
}
.article-cover__eyebrow span::before { content: "·"; margin-right: 14px; color: rgba(141, 220, 255, .6); }
.article-cover__eyebrow a { color: var(--sky-light); text-shadow: 0 1px 10px rgba(0, 27, 70, .55); }
.article-cover__eyebrow a:hover { color: #fff; text-decoration: none; }

.article-cover__inner h1 { font-size: 2.6rem; letter-spacing: -.025em; max-width: 22ch; }

/* --- FAQ статьи ----------------------------------------------------------- */

.faq__item {
    padding: 20px 22px;
    margin-bottom: 12px;
    background: var(--bg);
    border: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    border-radius: 10px;
}
.faq__q { font-family: var(--font-display); font-size: 1.05rem; margin-bottom: 8px; }

@media (max-width: 900px) {
    .article-cover__inner h1 { font-size: 1.85rem; max-width: none; }
    .toc ol { columns: 1; }
    .article-body { font-size: 1.04rem; }
}


/* --- Топ-5 рейтинга: ледяная подсветка строк -------------------------------- */

.rating__row--top { background: var(--ice); }
.rating__row--top td { border-bottom-color: var(--sky-light); }
.rating tbody tr.rating__row--top:hover { background: #cfeeff; }
.rating__row--top .rating__pos { color: var(--sky); }

/* Топ-3 — золотой «пьедестал» */
.rating__row--gold { background: #fff7e0; }
.rating__row--gold td { border-bottom-color: #f0d788; }
.rating tbody tr.rating__row--gold:hover { background: #fdefc7; }
.rating__row--gold .rating__pos { color: #c8971c; }

/* Скриншоты сайтов в обзорах компаний */
.article-fig--shot img {
    border: 1px solid var(--line);
    box-shadow: 0 8px 26px rgba(0, 27, 70, .08);
}

/* --- page-intro с иконкой кристалла ---------------------------------------- */

.page-intro--icon {
    display: flex;
    align-items: center;
    gap: 32px;
}
.page-intro__icon {
    flex: none;
    width: 132px;
    height: 132px;
    filter: drop-shadow(0 10px 24px rgba(0, 175, 255, .25));
}
.page-intro__body { min-width: 0; }

@media (max-width: 640px) {
    .page-intro--icon { gap: 16px; }
    .page-intro__icon { width: 76px; height: 76px; }
}

/* --- Поиск в шапке ---------------------------------------------------------- */

.site-search {
    position: relative;
    flex: 0 1 300px;
    min-width: 0;
}
.site-search__input {
    width: 100%;
    padding: 10px 42px 10px 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--bg-soft);
    font: inherit;
    font-size: .9rem;
    color: var(--ink);
    outline: none;
    transition: border-color .2s ease, background .2s ease;
}
.site-search__input::placeholder { color: var(--ink-faint); }
.site-search__input:focus {
    border-color: var(--sky);
    background: var(--bg);
}
.site-search__btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--accent);
    cursor: pointer;
}
.site-search__btn:hover { background: var(--ice); }

@media (max-width: 900px) {
    .site-header__inner { flex-wrap: wrap; }
}


/* Строка «Рейтинг обновлён …» над таблицей */
.rating__updated {
    margin: 0 0 18px;
    font-size: .86rem;
    color: var(--ink-faint);
}

/* --- Врезка «Комментарий эксперта» в статьях ИИ Блогера --------------------- */

.pmw-expert {
    margin: 34px 0;
    padding: 22px 24px;
    background: var(--ice);
    border-left: 4px solid var(--sky);
    border-radius: 0 10px 10px 0;
}
.pmw-expert__label {
    display: block;
    margin-bottom: 10px;
    font-family: var(--font-display);
    font-size: .74rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--accent);
}
.pmw-expert__head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.pmw-expert__ava {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    overflow: hidden;
    flex: none;
}
.pmw-expert__ava img { width: 100%; height: 100%; object-fit: cover; }
.pmw-expert__name { display: block; color: var(--navy); }
.pmw-expert__role { display: block; font-size: .84rem; color: var(--ink-soft); }
.pmw-expert p:last-child { margin-bottom: 0; }

/* --- Рейтинг средств: сетка рубрик ---------------------------------------- */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }

.cat-card {
    display: flex;
    flex-direction: column;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--bg);
    box-shadow: 0 1px 2px rgba(0, 27, 70, .05);
    transition: box-shadow .25s ease, transform .25s ease, border-color .25s ease;
}
.cat-card:hover {
    box-shadow: 0 14px 32px rgba(0, 27, 70, .14);
    border-color: var(--sky-light);
    transform: translateY(-3px);
    text-decoration: none;
}
.cat-card__icon {
    font-size: 1.9rem;
    line-height: 1;
    width: 56px;
    height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--ice);
    margin-bottom: 14px;
}
.cat-card__title { font-size: 1.16rem; margin: 0 0 6px; color: var(--ink); }
.cat-card:hover .cat-card__title { color: var(--accent); }
.cat-card__lead { color: var(--ink-soft); font-size: .92rem; margin: 0 0 12px; }
.cat-card__meta { margin: auto 0 0; color: var(--ink-faint); font-size: .82rem; }

/* Бренд под названием средства в таблице рейтинга */
.rating__brand { margin: 2px 0 0; color: var(--ink-faint); font-size: .8rem; }

/* --- Карточка средства: плюсы / минусы ------------------------------------ */
.procon { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 26px; }
.procon__col {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 18px 22px;
    background: var(--bg);
}
.procon__col h2 { font-size: 1.02rem; margin: 0 0 10px; }
.procon__col ul { margin: 0; padding-left: 0; list-style: none; }
.procon__col li { position: relative; padding-left: 22px; color: var(--ink-soft); margin: 6px 0; font-size: .94rem; }
.procon__col li::before { position: absolute; left: 0; top: 0; font-weight: 700; }
.procon__col--pro { border-top: 3px solid var(--sky); }
.procon__col--pro li::before { content: "+"; color: var(--sky); }
.procon__col--con { border-top: 3px solid var(--ink-faint); }
.procon__col--con li::before { content: "–"; color: var(--ink-faint); }

@media (max-width: 640px) {
    .procon { grid-template-columns: 1fr; }
    .cat-grid { grid-template-columns: 1fr; }
}

/* --- Портальный layout: широкий контейнер + правый рейл ------------------- */
.layout-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--rail);
    gap: 40px;
    align-items: start;
}
.layout-main { min-width: 0; }
/* Блоки внутри главной колонки выравниваются по её краям — внешнюю
   горизонтальную рамку даёт .layout-shell (это .container). */
.layout-main .container { max-width: none; margin: 0; padding: 0; width: 100%; }
/* …но вертикальные отступы секций карточки компании возвращаем: обнуление выше
   гасило и их, из-за чего крошки/навигация прилипали к шапке и футеру. */
.layout-main .breadcrumbs { padding-top: 4px; padding-bottom: 16px; }
.layout-main .company-head { padding-top: 22px; padding-bottom: 36px; }
.layout-main .company-body { padding-top: 32px; padding-bottom: 40px; }
.layout-main .company-nav { padding-top: 28px; padding-bottom: 72px; }
@media (max-width: 640px) {
    .layout-main .company-nav { padding-bottom: 48px; }
}

.layout-rail { align-self: start; margin-bottom: 75px; }
.rail { display: flex; flex-direction: column; gap: 18px; }

.rail-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--bg);
    padding: 18px;
}
.rail-card__title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: .76rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--ink-faint);
    margin-bottom: 12px;
}
.rail-more { display: inline-block; margin-top: 12px; font-size: .82rem; font-weight: 600; }

.rail-trust { background: var(--ice); border-color: var(--sky-light); }
.rail-trust__badge {
    display: inline-block;
    font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
    color: #fff; background: var(--accent);
    padding: 3px 10px; border-radius: 20px; margin-bottom: 10px;
}
.rail-trust p { font-size: .9rem; color: var(--ink-soft); margin: 0; }

.rail-rank { list-style: none; margin: 0; padding: 0; }
.rail-rank li { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: .92rem; }
.rail-rank li:last-child { border-bottom: none; }
.rail-rank__pos {
    flex: none; width: 22px; height: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 6px; background: var(--ice); color: var(--accent); font-weight: 700; font-size: .8rem;
}
.rail-rank li a { flex: 1; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail-rank li a:hover { color: var(--accent); }
.rail-rank__score { flex: none; color: var(--ink-faint); font-size: .82rem; font-variant-numeric: tabular-nums; }

.rail-cats { list-style: none; margin: 0; padding: 0; }
.rail-cats li + li { border-top: 1px solid var(--line); }
.rail-cats a { display: flex; align-items: center; gap: 9px; padding: 8px 0; color: var(--ink); font-size: .92rem; }
.rail-cats a:hover { color: var(--accent); }
.rail-cats__ico { display: inline-flex; line-height: 1; }
.rail-cats__ico svg { width: 18px; height: 18px; color: var(--accent); }
.cat-card__icon svg { width: 26px; height: 26px; color: var(--accent); }

.rail-posts { list-style: none; margin: 0; padding: 0; }
.rail-posts li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.rail-posts li:last-child { border-bottom: none; }
.rail-posts a { display: block; color: var(--ink); font-size: .9rem; line-height: 1.4; }
.rail-posts a:hover { color: var(--accent); }
.rail-posts__date { display: block; margin-top: 3px; font-size: .74rem; color: var(--ink-faint); }

@media (max-width: 980px) {
    .layout-shell { grid-template-columns: 1fr; gap: 30px; }
    .layout-rail { position: static; }
    .rail { flex-direction: row; flex-wrap: wrap; }
    .rail-card { flex: 1 1 240px; }
}
@media (max-width: 560px) {
    .rail { flex-direction: column; }
}

/* --- Карточка средства: фото + характеристики строкой --------------------- */
.product-top { display: grid; grid-template-columns: 260px 1fr; gap: 32px; align-items: start; }
.product-top__media img,
.product-top__ph {
    width: 100%;
    aspect-ratio: 1 / 1;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--bg);
}
.product-top__media img { object-fit: contain; padding: 16px; }
.product-top__ph {
    display: flex; align-items: center; justify-content: center;
    background: var(--ice); border-color: var(--sky-light); color: var(--accent);
}
.product-top__ph svg { width: 84px; height: 84px; }
.product-top__main .company-badges { margin-bottom: 14px; }

.product-specs { margin-top: 28px; }
.product-specs dl {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    margin: 0;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
    border-radius: 12px;
    overflow: hidden;
}
.product-specs__item { padding: 14px 18px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.product-specs dt { font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 4px; }
.product-specs dd { margin: 0; color: var(--ink); font-size: .95rem; }

@media (max-width: 720px) {
    .product-top { grid-template-columns: 1fr; gap: 20px; }
    .product-top__media { max-width: 220px; }
}
