/* Мой Архив Мира — стили сайта.
   Внешних ресурсов нет намеренно: страница, которая обещает «без облака»,
   не должна тянуть шрифты и счётчики с чужих серверов. Шрифты лежат
   здесь же, в /fonts/ (лицензия OFL), урезанные до латиницы и кириллицы
   с казахскими буквами. */

@font-face {
    font-family: "Golos Text";
    src: url("../fonts/golos-text-400.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Golos Text";
    src: url("../fonts/golos-text-600.woff2") format("woff2");
    font-weight: 500 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Lora";
    src: url("../fonts/lora-600.woff2") format("woff2");
    font-weight: 500 700;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Графит и оранжевый — цвета логотипа */
    --paper:       #f2f1ee;
    --paper-deep:  #e8e7e3;
    --card:        #ffffff;
    --ink:         #1a1c1f;
    --ink-soft:    #50555b;
    --solid:       #26292d;   /* кнопки и тёмные блоки */
    --solid-dark:  #1a1c1f;
    --seal:        #a94a14;   /* акцент текстом: ссылки, текущий раздел */
    --seal-dark:   #7a3410;
    --brass:       #d2601f;   /* фирменный оранжевый: только графика */
    --rule:        #d8d6d0;

    --font-text: "Golos Text", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", sans-serif;
    --font-head: Lora, Georgia, "Times New Roman", serif;
    --radius: 12px;

    --measure: 62ch;
    --gap: clamp(1rem, 2.5vw, 2rem);
}

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

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

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font-text);
    font-size: clamp(1rem, 0.97rem + 0.15vw, 1.075rem);
    line-height: 1.65;
    font-kerning: normal;
}

h1, h2, h3 {
    font-family: var(--font-head);
    line-height: 1.18;
    letter-spacing: -0.018em;
    font-weight: 600;
    margin: 0;
    text-wrap: balance;
}

p { margin: 0 0 1.1em; max-width: var(--measure); }
p:last-child { margin-bottom: 0; }

a { color: var(--seal); text-underline-offset: 0.18em; }
a:hover { color: var(--seal-dark); }

:focus-visible {
    outline: 2px solid var(--seal);
    outline-offset: 3px;
    border-radius: 2px;
}

.wrap {
    width: min(100% - 2.5rem, 68rem);
    margin-inline: auto;
}

/* ── Шапка ─────────────────────────────────────────────── */

.top { border-bottom: 1px solid var(--rule); }

/* Шапка остаётся на месте при прокрутке — на широком экране. На телефоне
   меню переносится в две-три строки и закрыло бы пол-экрана, поэтому там
   шапка уезжает вместе со страницей. */
@media (min-width: 46.01rem) {
    .top {
        position: sticky;
        top: 0;
        z-index: 50;
        background: rgba(242, 241, 238, 0.94);
        -webkit-backdrop-filter: blur(8px);
        backdrop-filter: blur(8px);
    }
    /* Якоря (#windows и т. п.) не прячутся под шапкой */
    html { scroll-padding-top: 6rem; }
}

.top-row {
    display: flex;
    align-items: center;
    gap: 1rem 1.6rem;
    padding: 1rem 0;
    flex-wrap: wrap;
}

/* Название и подпись — в две строки: так бренд занимает вдвое меньше
   ширины, и меню из четырёх пунктов помещается в ту же строку. */
.brand {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    column-gap: 0.7rem;
    text-decoration: none;
    color: inherit;
    margin-right: auto;
}
.brand .mark { grid-row: span 2; }
.brand-name { grid-column: 2; align-self: end; }
.brand-tag  { grid-column: 2; align-self: start; line-height: 1.3; }

/* Логотип: знак в рамке, встроенный SVG (partials/logo.html) */
.mark {
    width: 2.6rem;
    height: 2.6rem;
    flex: none;
    display: block;
}
.mark svg { display: block; width: 100%; height: 100%; }

.brand-name { font-family: var(--font-head); font-weight: 600; font-size: 1.12rem; line-height: 1.25; }
.brand-tag  { color: var(--ink-soft); font-size: 0.82rem; }

/* Название и подпись одной ширины — подобрано под шрифты Lora и Golos Text. */
@media (min-width: 46.01rem) {
    .brand { column-gap: 0.8rem; }
    .brand-name { font-size: 1.85rem; letter-spacing: 0.02em; line-height: 1.05; }
    .brand-tag  { font-size: 0.78rem; }
    .mark { width: 3.1rem; height: 3.1rem; }
}

/* Разделы сайта. «Скачать» — кнопкой: это главное действие,
   и оно должно отличаться от остальных ссылок. */
.menu {
    display: flex;
    align-items: center;
    gap: 1.4rem;
    font-size: 0.95rem;
}
.menu a { color: var(--ink); text-decoration: none; }
.menu a:hover { color: var(--seal); }
.menu a[aria-current="page"] {
    color: var(--seal);
    box-shadow: 0 1.5px 0 var(--seal);
}
.menu-cta {
    padding: 0.42rem 1rem;
    border: 1.5px solid var(--solid);
    border-radius: 10px;
    background: var(--solid);
    color: var(--paper) !important;
    font-weight: 600;
}
.menu-cta:hover { background: var(--solid-dark); border-color: var(--solid-dark); }
.menu-cta[aria-current="page"] { box-shadow: none; }

.langs { display: flex; gap: 0.7rem; font-size: 0.82rem; letter-spacing: 0.02em; }
.langs a { color: var(--ink-soft); text-decoration: none; }
.langs a:hover { color: var(--seal); text-decoration: underline; }
.langs .current { color: var(--ink); font-weight: 600; }

@media (max-width: 46rem) {
    /* Подпись под названием на узком экране только мешает:
       её место занимает меню, а суть уже сказана на главной. */
    .brand-tag { display: none; }
    .top-row { gap: 0.7rem 1.1rem; }

    /* Четыре пункта в строку не помещаются - переносим, а не прячем
       за кнопкой: гамбургер ради четырёх ссылок прячет навигацию,
       ничего не выигрывая. */
    .menu {
        flex-wrap: wrap;
        gap: 0.6rem 1.1rem;
        font-size: 0.92rem;
        width: 100%;
        order: 3;
    }
    .langs { order: 2; }
    .menu-cta { padding: 0.38rem 0.9rem; }
}

/* ── Первый экран ──────────────────────────────────────── */

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4.5rem);
    align-items: center;
    padding: clamp(3rem, 7vw, 6rem) 0 clamp(2.5rem, 5vw, 4rem);
}

.hero h1 {
    font-size: clamp(1.9rem, 1.4rem + 1.7vw, 2.65rem);
    margin-bottom: 1.05rem;
    max-width: 17ch;
}

.hero .lead {
    font-size: 1.08em;
    color: var(--ink-soft);
    max-width: 34rem;
}

.actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 1.8rem 0 0.9rem;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.45rem;
    background: var(--solid);
    color: var(--paper);
    text-decoration: none;
    font-weight: 600;
    border: 1.5px solid var(--solid);
    border-radius: var(--radius);
}
.btn:hover { background: var(--solid-dark); border-color: var(--solid-dark); color: var(--paper); }

.btn-quiet {
    background: var(--card);
    color: var(--ink);
    border-color: var(--solid);
}
.btn-quiet:hover { background: var(--card); color: var(--ink); border-color: var(--solid-dark); }

.note { font-size: 0.9rem; color: var(--ink-soft); margin: 0; }

/* Живой макет карточки контакта — то, что человек увидит в приложении */

.card {
    background: #fff;
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    box-shadow: 0 1px 0 var(--rule);
    padding: 1.4rem 1.5rem 1.5rem;
}

.card-name { font-size: 1.22rem; font-weight: 600; }
.card-role { color: var(--ink-soft); font-size: 0.9rem; margin-top: 0.15rem; }

.card-rows { margin-top: 1.2rem; display: grid; gap: 0.95rem; }

.row {
    display: grid;
    grid-template-columns: 1.45rem 1fr;
    gap: 0.75rem;
    align-items: start;
    padding-top: 0.95rem;
    border-top: 1px solid var(--rule);
}
.row:first-child { border-top: 0; padding-top: 0; }

.row-icon { color: var(--seal); margin-top: 0.12rem; }
.row-icon svg { display: block; width: 1.15rem; height: 1.15rem; }

.row-label {
    display: block;
    font-size: 0.74rem;
    color: var(--ink-soft);
    margin-bottom: 0.12rem;
}
.row-text { display: block; font-size: 0.95rem; }

/* ── Секции ────────────────────────────────────────────── */

section { padding: clamp(2.6rem, 5vw, 4.5rem) 0; }

.why {
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    background: var(--paper-deep);
}
.why h2 { font-size: clamp(1.45rem, 1.15rem + 1.1vw, 2.05rem); margin-bottom: 1.2rem; }
.why .last { font-size: 1.06em; }
.why .last strong { font-weight: 600; }

.scenario {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(1.6rem, 4vw, 3.5rem);
    align-items: center;
    padding: clamp(2.2rem, 4vw, 3.4rem) 0;
    border-bottom: 1px solid var(--rule);
}
.scenario:last-of-type { border-bottom: 0; }
.scenario:nth-child(even) .scenario-text { order: 2; }

.scenario h3 {
    font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.7rem);
    margin-bottom: 0.9rem;
}

/* Заглушки скриншотов: форма рамки говорит, какая это платформа */

.shot {
    background: #fff;
    border: 1px solid var(--rule);
    display: grid;
    place-items: center;
    padding: 1.5rem;
    text-align: center;
    color: var(--ink-soft);
    font-size: 0.88rem;
    line-height: 1.45;
}
.shot-phone {
    border-radius: 18px;
    width: min(13rem, 100%);
    aspect-ratio: 9 / 16;
    margin-inline: auto;
    border-width: 6px;
    border-color: var(--ink);
}
.shot-desktop {
    border-radius: 5px;
    width: 100%;
    aspect-ratio: 16 / 10;
    border-width: 1px;
    border-top-width: 1.5rem;
    border-top-color: var(--ink);
}

/* ── Платформа и расширения ────────────────────────────── */

.platform { background: var(--paper-deep); border-top: 1px solid var(--rule); }
.platform h2 { font-size: clamp(1.45rem, 1.15rem + 1.1vw, 2.05rem); margin-bottom: 1.1rem; }
.platform .lead { max-width: var(--measure); color: var(--ink-soft); }

.exts {
    list-style: none;
    margin: 2rem 0 1.8rem;
    padding: 0;
    display: grid;
    gap: 1.15rem;
    grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr));
}
.exts li {
    border-left: 2px solid var(--brass);
    padding-left: 0.95rem;
}
.exts b { font-weight: 600; display: block; margin-bottom: 0.2rem; }
.exts span { color: var(--ink-soft); font-size: 0.95rem; }

.platform-footer { display: flex; gap: 1.2rem; align-items: baseline; flex-wrap: wrap; }
.platform-footer p { margin: 0; }

/* ── Приватность: единственный инверсный блок ──────────── */

.privacy { background: var(--ink); color: var(--paper); }
.privacy h2 { font-size: clamp(1.4rem, 1.1rem + 1vw, 1.9rem); margin-bottom: 1.1rem; }
.privacy p { color: #cfcdc8; }

/* ── Скачивание ────────────────────────────────────────── */

.download h2 { font-size: clamp(1.45rem, 1.15rem + 1.1vw, 2.05rem); margin-bottom: 1.6rem; }

.dl-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
    gap: 2rem;
}
.dl-label { font-weight: 600; margin-bottom: 0.8rem; }
.dl-line { display: flex; gap: 0.6rem; align-items: baseline; margin-bottom: 0.5rem; }
.dl-os { font-size: 1.05rem; }
.dl-state { color: var(--ink-soft); font-size: 0.9rem; }
.dl-hint { font-size: 0.88rem; margin-top: 0.6rem; }

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

footer {
    border-top: 1px solid var(--rule);
    padding: 2rem 0 2.6rem;
    font-size: 0.9rem;
    color: var(--ink-soft);
}
.foot-row { display: flex; justify-content: space-between; gap: 1rem 1.6rem; flex-wrap: wrap; }
.foot-langs { display: flex; gap: 1.1rem; }
.foot-langs span { color: var(--ink); }
.foot-links { display: flex; gap: 1.1rem; flex-wrap: wrap; }
footer a { color: var(--ink-soft); }

/* ── Узкие экраны ──────────────────────────────────────── */

@media (max-width: 54rem) {
    .hero { grid-template-columns: 1fr; }
    .hero .card { max-width: 26rem; }
    .scenario { grid-template-columns: 1fr; }
    .scenario:nth-child(even) .scenario-text { order: 0; }
    .shot-desktop { aspect-ratio: 16 / 11; }
}

@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; animation: none !important; }
}

/* ── Галерея кадров ────────────────────────────────────── */

.shot-wrap { display: grid; gap: 0.85rem; justify-items: center; width: 100%; }

.shot { position: relative; overflow: hidden; }
.shot:focus-visible { outline-offset: 4px; }

.frame {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 1rem;
    text-align: center;
    font-size: 0.85rem;
    line-height: 1.4;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.45s ease;
}
.frame.is-on { opacity: 1; visibility: visible; }
/* Кадр со снимком: картинка во всю рамку, верх экрана всегда виден. */
.frame.has-img { padding: 0; }
.frame.has-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }

@media (prefers-reduced-motion: reduce) {
    .frame { transition: none; }
}

.dots { display: flex; gap: 0.45rem; }
.dots button {
    width: 0.55rem;
    height: 0.55rem;
    padding: 0;
    border: 1px solid var(--ink-soft);
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
}
.dots button[aria-selected="true"] { background: var(--seal); border-color: var(--seal); }
.dots button:hover { border-color: var(--seal); }

.visually-hidden {
    position: absolute;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

/* ── Внутренние страницы ───────────────────────────────── */

.page { padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(3rem, 7vw, 5rem); max-width: 44rem; }
.page h1 { font-size: clamp(1.8rem, 1.35rem + 1.7vw, 2.5rem); margin-bottom: 1rem; }
.page .lead { font-size: 1.08em; color: var(--ink-soft); }
.release-line { font-size: 0.88rem; color: var(--ink-soft); margin-top: -0.4rem; }

.dl-block {
    padding: 2rem 0 0;
    margin-top: 2rem;
    border-top: 1px solid var(--rule);
}
.dl-block h2 { font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.6rem); margin-bottom: 1.1rem; }
.dl-block h3 { font-size: 1.05rem; margin: 1.8rem 0 0.7rem; }

.dl-main { display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; }
.dl-meta { color: var(--ink-soft); font-size: 0.9rem; }
.dl-note { margin: 0.7rem 0 0; color: var(--ink-soft); }
.dl-fallback { margin-top: 1.1rem; font-size: 0.92rem; color: var(--ink-soft); }
.dl-others { margin-top: 1.4rem; color: var(--ink-soft); }

.steps { margin: 0; padding-left: 1.3rem; max-width: var(--measure); }
.steps li { margin-bottom: 0.5rem; }

.asks { margin: 0; max-width: var(--measure); }
.asks dt {
    font-weight: 600;
    margin-top: 1.1rem;
    border-left: 2px solid var(--brass);
    padding-left: 0.8rem;
}
.asks dd { margin: 0.4rem 0 0 0.8rem; color: var(--ink-soft); }

.sums { margin-top: 1rem; }
.sums summary { cursor: pointer; color: var(--seal); width: fit-content; }
.sums-body { margin-top: 1rem; }
.sum-line { display: grid; gap: 0.15rem; margin-bottom: 0.9rem; font-size: 0.88rem; }
.sum-line code {
    font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
    font-size: 0.78rem;
    color: var(--ink-soft);
    word-break: break-all;
}
.sum-how { font-size: 0.85rem; color: var(--ink-soft); }
.sum-how code { font-family: ui-monospace, Consolas, monospace; font-size: 0.8rem; }
.dl-all { margin-top: 1.8rem; }

/* ── Обещания на первом экране ─────────────────────────── */

.promises {
    list-style: none;
    margin: 1.6rem 0 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.4rem;
    font-size: 0.95rem;
}
.promises li {
    position: relative;
    padding-left: 1.05rem;
    color: var(--ink);
}
/* Галочка вместо маркера: это перечень обещаний, а не список пунктов */
.promises li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.52em;
    width: 0.42rem;
    height: 0.22rem;
    border-left: 1.6px solid var(--seal);
    border-bottom: 1.6px solid var(--seal);
    transform: rotate(-45deg);
}

/* ── Выбор платформы на странице «Скачать» ─────────────── */

.pick {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    gap: 1rem;
    margin: 2rem 0 0.5rem;
}
.pick-item {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    column-gap: 0.85rem;
    align-items: center;
    padding: 1rem 1.2rem;
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    background: #fff;
    text-decoration: none;
    color: inherit;
}
.pick-item:hover { border-color: var(--seal); }
.pick-icon { grid-row: span 2; color: var(--seal); }
.pick-icon svg { display: block; width: 1.8rem; height: 1.8rem; }
.pick-name { font-weight: 600; }
.pick-os { color: var(--ink-soft); font-size: 0.9rem; }

/* ── Страница «Возможности» ────────────────────────────── */

.page-wide { max-width: 62rem; }

.feature {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(1.6rem, 4vw, 3.2rem);
    align-items: center;
    padding: clamp(2rem, 4vw, 3rem) 0;
    border-top: 1px solid var(--rule);
    margin-top: clamp(1.5rem, 3vw, 2.5rem);
}
.feature:nth-of-type(even) .feature-text { order: 2; }

.feature h2 { font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.65rem); margin-bottom: 0.9rem; }
.feature h3 {
    font-size: 1rem;
    color: var(--ink-soft);
    font-weight: 600;
    margin: 0 0 0.8rem;
}
.feature p { max-width: 34rem; }
.feature p strong { font-weight: 600; }

.perm, .feature-ext {
    border-top: 1px solid var(--rule);
    margin-top: clamp(1.5rem, 3vw, 2.5rem);
    padding-top: clamp(2rem, 4vw, 3rem);
    max-width: 44rem;
}
.perm h2, .feature-ext h2 { font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.65rem); margin-bottom: 1rem; }

.perm-key {
    border-left: 2px solid var(--seal);
    padding-left: 1rem;
    font-size: 1.04em;
}
.perm-key strong { font-weight: 600; }

.perm-list { margin: 1.4rem 0; }
.perm-list dt {
    font-weight: 600;
    margin-top: 1rem;
    font-size: 0.95rem;
}
.perm-list dd {
    margin: 0.2rem 0 0;
    color: var(--ink-soft);
    font-size: 0.95rem;
    max-width: var(--measure);
}
.perm-list dd strong { color: var(--ink); font-weight: 600; }

.feature-ext p { max-width: var(--measure); }

@media (max-width: 54rem) {
    .feature { grid-template-columns: 1fr; }
    .feature:nth-of-type(even) .feature-text { order: 0; }
}

/* ── Конспект страницы ─────────────────────────────────── */

.digest-intro { color: var(--ink-soft); margin: 2rem 0 0.9rem; }

.digest {
    list-style: none;
    counter-reset: d;
    margin: 0 0 1rem;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
    gap: 0.85rem;
}
.digest li { counter-increment: d; }
.digest a {
    display: grid;
    gap: 0.3rem;
    height: 100%;
    padding: 0.95rem 1.1rem;
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    background: #fff;
    text-decoration: none;
    color: inherit;
}
.digest a:hover { border-color: var(--seal); }

.digest-label {
    font-size: 0.78rem;
    color: var(--seal);
    font-weight: 600;
}
.digest-label::before {
    content: counter(d) " · ";
    color: var(--brass);
}
.digest-text { font-size: 0.95rem; line-height: 1.45; }

/* На узком экране конспект листается пальцем: короткие карточки,
   горизонтальная лента с прилипанием — привычный жест для телефона.
   Для длинного текста ниже такой приём не годится, там нужна
   обычная прокрутка. */
@media (max-width: 54rem) {
    .digest {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: 78%;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: 0.6rem;
        margin-inline: -1.25rem;
        padding-inline: 1.25rem;
        scrollbar-width: thin;
    }
    .digest li { scroll-snap-align: start; }
}

.perm-link, .perm-back { margin-top: 2rem; }
.perm-link {
    border-top: 1px solid var(--rule);
    padding-top: clamp(2rem, 4vw, 3rem);
    max-width: 44rem;
}
.perm-link h2 { font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.65rem); margin-bottom: 1rem; }

/* ── Главная: первый экран ─────────────────────────────── */

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.home-hero { padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2.5rem, 5vw, 3.5rem); }
.home-hero h1 {
    font-size: clamp(2rem, 1.3rem + 2.6vw, 3.6rem);
    max-width: 30ch;
    margin-bottom: 1.1rem;
}
.home-hero .lead { font-size: 1.15em; color: var(--ink-soft); max-width: 44rem; }

.paid-note {
    display: flex;
    gap: 0.55rem;
    align-items: flex-start;
    margin-top: 0.4rem;
    max-width: 44rem;
    font-size: 0.92rem;
    color: var(--ink-soft);
}
.paid-note svg { flex: none; width: 1.1rem; height: 1.1rem; margin-top: 0.2rem; }

/* ── Главная: схема ────────────────────────────────────── */

.scheme { padding-bottom: clamp(3rem, 6vw, 5rem); }
/* Схеме нужно больше ширины, чем тексту: четыре блока в ряд. */
.scheme .wrap { width: min(100% - 2.5rem, 80rem); }

/* Широкий экран: блоки в ряд (колонки 1, 3, 5, 7), между ними стрелки
   и граница сети, панели — ниже во всю ширину. */
.sb-grid {
    display: grid;
    grid-template-columns: 1fr 2.4rem 1fr 4.5rem 1fr 2.4rem 1fr;
    column-gap: 0;
    row-gap: 1.4rem;
    align-items: stretch;
}
.sb-c1 { grid-column: 1; grid-row: 1; }
.sb-c2 { grid-column: 2; grid-row: 1; }
.sb-c3 { grid-column: 3; grid-row: 1; }
.sb-c4 { grid-column: 4; grid-row: 1; }
.sb-c5 { grid-column: 5; grid-row: 1; }
.sb-c6 { grid-column: 6; grid-row: 1; }
.sb-c7 { grid-column: 7; grid-row: 1; }

.sb {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 17rem;
    padding: 1.6rem;
    border-radius: 20px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.sb h3 { font-size: clamp(1.4rem, 1.1rem + 0.7vw, 1.75rem); }
.sb p { margin: 0; color: var(--ink-soft); }
.sb-dark { background: var(--solid); border-color: var(--solid); color: #fff; }
.sb-dark p { color: #d9d8d4; }
.sb-tint { background: var(--paper-deep); border-color: #c9c7c1; }

.sb-num {
    width: 2.2rem; height: 2.2rem;
    flex: none;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #b9561c;
    color: #fff;
    font-weight: 600;
}
.sb-dark .sb-num { background: #f59a4f; color: var(--ink); }

.sb-badge {
    align-self: flex-start;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    background: #fff;
    color: var(--ink);
    font-size: 0.85rem;
    font-weight: 600;
}

.sb-toggle {
    margin-top: auto;
    align-self: flex-start;
    min-height: 2.75rem;
    padding: 0 1.1rem;
    border-radius: 10px;
    border: 1.5px solid currentColor;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}
.sb-less { display: none; }
.sb.is-open .sb-more { display: none; }
.sb.is-open .sb-less { display: inline; }

/* Без скрипта кнопка ничего не делает — прячем её, панели и так открыты. */
.sb-grid:not(.is-live) .sb-toggle { display: none; }
.sb-grid.is-live .sb { cursor: pointer; }
.sb.is-open { box-shadow: 0 0 0 3px var(--brass); }

.sb-arrow { display: grid; place-items: center; color: #8a8f8c; }
.sb-arrow svg { width: 1.8rem; height: 1.5rem; }

/* Граница сети: надпись по вертикали между двумя линиями. */
.sb-boundary {
    display: flex;
    justify-content: center;
    gap: 0.6rem;
}
.sb-boundary::before, .sb-boundary::after {
    content: "";
    width: 2px;
    border-radius: 1px;
    background: var(--brass);
}
.sb-boundary a, .sb-boundary span {
    align-self: center;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    white-space: nowrap;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--seal);
}

.sb-panel {
    grid-column: 1 / -1;
    position: relative;
    padding: clamp(1.1rem, 2vw, 1.75rem);
    background: var(--card);
    border: 3px solid var(--brass);
    border-radius: 20px;
}
.sb-panel[hidden] { display: none; }
/* Уголок, указывающий на свой блок; положение задаёт скрипт. */
.sb-grid.is-live .sb-panel::before {
    content: "";
    position: absolute;
    top: -12px;
    left: var(--x, 3rem);
    width: 20px; height: 20px;
    background: var(--card);
    border-left: 3px solid var(--brass);
    border-top: 3px solid var(--brass);
    transform: translateX(-50%) rotate(45deg);
    border-top-left-radius: 3px;
}
.sb-panel-head { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.1rem; }
.sb-panel-head .sb-num { background: var(--brass); }
.sb-panel-head h3 { font-size: clamp(1.25rem, 1.05rem + 0.6vw, 1.55rem); }

.tiles {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
}
.tile {
    display: flex;
    gap: 0.9rem;
    align-items: flex-start;
    height: 100%;
    min-height: 2.75rem;
    padding: 1rem 1.1rem;
    border-radius: var(--radius);
    background: var(--paper);
    color: var(--ink);
    text-decoration: none;
}
a.tile:hover { background: var(--paper-deep); color: var(--ink); }
.tile-icon {
    width: 2.75rem; height: 2.75rem;
    flex: none;
    display: grid;
    place-items: center;
    border-radius: var(--radius);
    background: var(--card);
    border: 1px solid #e2e0db;
    color: var(--solid);
}
.tile-icon svg { width: 1.6rem; height: 1.6rem; }
.tile-body { display: flex; flex-direction: column; gap: 0.2rem; }
.tile-title { font-weight: 600; }
.tile-go { color: var(--seal); }
.tile-text { font-size: 0.92rem; color: var(--ink-soft); line-height: 1.45; }

/* Узкий экран: блоки друг под другом, панель — сразу под своим блоком
   (так стоит разметка), граница сети — строкой между блоками 2 и 3. */
@media (max-width: 60rem) {
    .sb-grid { grid-template-columns: 1fr; row-gap: 0.75rem; }
    .sb-grid > * { grid-column: 1 !important; grid-row: auto !important; }
    .sb { min-height: 0; }
    .sb-arrow svg { transform: rotate(90deg); }
    .sb-boundary { flex-direction: row; align-items: center; padding: 0.4rem 0; }
    .sb-boundary::before, .sb-boundary::after { width: auto; height: 2px; flex: 1; }
    .sb-boundary a, .sb-boundary span { writing-mode: horizontal-tb; transform: none; white-space: normal; text-align: center; }
    .tiles { grid-template-columns: 1fr; }
}
@media (min-width: 60.01rem) and (max-width: 74rem) {
    .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ── Главная: сценарии ─────────────────────────────────── */

.home-scenarios { padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(3rem, 6vw, 5rem); border-top: 1px solid var(--rule); }
.home-scenarios h2 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); margin-bottom: 0.5rem; }
.home-scenarios .lead { color: var(--ink-soft); }
.scen-groups {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.75rem;
    margin-top: 1.75rem;
}
.scen-group { display: flex; flex-direction: column; gap: 0.9rem; }
.scen-group-name {
    font-family: var(--font-text);
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--seal);
}
.scen-card {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 1.3rem;
    border-radius: 16px;
    background: var(--card);
    border: 1px solid var(--rule);
    color: var(--ink);
    text-decoration: none;
}
a.scen-card:hover { border-color: var(--solid); color: var(--ink); }
.scen-title { font-family: var(--font-head); font-weight: 600; font-size: 1.3rem; line-height: 1.2; }
.scen-text { color: var(--ink-soft); font-size: 0.97rem; }
.scen-go { margin-top: 0.2rem; font-weight: 600; color: var(--seal); }
.scen-all { margin-top: 1.5rem; font-weight: 600; }

@media (max-width: 54rem) {
    .scen-groups { grid-template-columns: 1fr; }
}

/* ── Сценарии и страницы подробностей ──────────────────── */

.scen-page, .detail-page { max-width: none; }
.scen-page .wrap, .detail-page .wrap { width: min(100% - 2.5rem, 76rem); }
.scen-page h1, .detail-page h1 { font-size: clamp(2rem, 1.3rem + 2.4vw, 3.3rem); max-width: 22ch; margin-bottom: 1rem; }
.scen-page > .wrap > .lead, .detail-page > .wrap > .lead { font-size: 1.15em; max-width: 46rem; }

.crumbs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.4rem; font-size: 0.92rem; color: var(--ink-soft); }
.kicker {
    margin: 0 0 0.7rem;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--seal);
}
.muted { color: var(--ink-soft); }

.block { margin-top: clamp(3rem, 6vw, 4.5rem); }
.block > h2, .price-box h2, .cta-dark h2 { font-size: clamp(1.5rem, 1.15rem + 1.2vw, 2.15rem); margin-bottom: 1.1rem; }

/* Уменьшенная схема */
.mini-scheme { margin-top: 2.2rem; }
.mini-caption { font-size: 0.95rem; color: var(--ink-soft); max-width: none; }
.mini-caption strong { color: var(--ink); }
.mini-blocks { list-style: none; margin: 0.6rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.6rem; }
.mini-blocks a {
    display: flex; align-items: center; gap: 0.6rem;
    height: 100%;
    padding: 0.7rem 0.9rem;
    border-radius: 14px;
    border: 1px solid var(--rule);
    background: var(--card);
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
    opacity: 0.6;
}
.mini-blocks .is-on a { opacity: 1; border: 3px solid var(--brass); }
.mini-num {
    width: 1.8rem; height: 1.8rem; flex: none;
    display: grid; place-items: center;
    border-radius: 50%;
    background: var(--paper-deep);
    font-size: 0.85rem;
}
.mini-blocks .is-on .mini-num { background: #b9561c; color: #fff; }

/* Карточки */
.cards { display: grid; gap: 1rem; }
.cards-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cards-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cards-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.plain-card {
    display: flex; flex-direction: column; gap: 0.35rem;
    padding: 1.3rem 1.4rem;
    border-radius: 16px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.plain-card b { font-size: 1.05rem; }
.plain-card span { color: var(--ink-soft); }
.plain-card .card-title { font-family: var(--font-head); font-weight: 600; font-size: 1.35rem; line-height: 1.2; }

/* «Как это устроено»: источники → пространства */
.how {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    gap: 2.5rem;
    align-items: center;
    padding: clamp(1.2rem, 3vw, 2rem);
    border-radius: 20px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.how-map { display: grid; grid-template-columns: 14rem 8.75rem minmax(0, 1fr); align-items: center; }
.how-sources, .how-ws { display: grid; gap: 1rem; }
.how-src {
    height: 4rem;
    display: flex; flex-direction: column; justify-content: center;
    padding: 0 1rem;
    border-radius: var(--radius);
    background: var(--paper-deep);
}
.how-src span { font-size: 0.88rem; color: var(--ink-soft); line-height: 1.3; }
.how-arrows { width: 8.75rem; height: 14rem; color: var(--brass); }
.how-legend { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.6rem; margin: 1.2rem 0 0; font-size: 0.88rem; color: var(--ink-soft); }
.how-legend span { display: inline-block; width: 2rem; height: 0; border-top: 3px solid var(--brass); }
.how-legend .lg-free { border-top: 2px dashed var(--brass); margin-left: 0.8rem; }
.how-arrows-v { display: none; }
.ws-card {
    height: 6.5rem;
    display: flex; flex-direction: column; justify-content: center; gap: 0.5rem;
    padding: 0 1.1rem;
    border-radius: 14px;
    background: var(--solid);
    color: #fff;
}
.ws-top { display: flex; justify-content: space-between; align-items: baseline; gap: 0.6rem; }
.ws-name { font-family: var(--font-head); font-weight: 600; font-size: 1.35rem; }
.ws-note { font-size: 0.85rem; color: #cfcdc8; }
.ws-tags { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.ws-tags span { padding: 0.15rem 0.6rem; border-radius: 999px; background: #3a3e43; font-size: 0.8rem; font-weight: 600; }
.ws-tags span:first-child { background: #f59a4f; color: var(--ink); }
.how-notes p { color: var(--ink-soft); }
.how-notes b { color: var(--ink); }

/* Подсценарии */
.sub-card {
    display: flex; flex-direction: column; gap: 0.9rem;
    padding: clamp(1.2rem, 2.5vw, 1.8rem);
    border-radius: 20px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.sub-head { display: flex; align-items: center; gap: 0.7rem; }
.sub-head h3 { font-size: 1.55rem; }
.sub-lead { color: var(--ink-soft); }
.sub-card ul { margin: 0; padding-left: 1.2rem; }
.sub-card li { margin-bottom: 0.4rem; }
.tag-orange { padding: 0.2rem 0.7rem; border-radius: 999px; background: #f59a4f; color: var(--ink); font-size: 0.82rem; font-weight: 600; white-space: nowrap; }

/* Шаги */
.steps-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 15rem; gap: 3rem; align-items: start; }
.steps-list { list-style: none; margin: 0; padding: 0; counter-reset: st; border-bottom: 1px solid var(--rule); }
.steps-list li {
    counter-increment: st;
    position: relative;
    padding: 1.1rem 0 1.1rem 3.4rem;
    border-top: 1px solid var(--rule);
}
.steps-list li::before {
    content: counter(st);
    position: absolute; left: 0; top: 1.05rem;
    width: 2.3rem; height: 2.3rem;
    display: grid; place-items: center;
    border-radius: 50%;
    background: var(--solid);
    color: #fff;
    font-weight: 600;
}
.step-head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-bottom: 0.25rem; }
.step-head b { font-size: 1.1rem; }
.steps-list p { color: var(--ink-soft); margin: 0; }

.mark-chip { display: inline-block; padding: 0.15rem 0.65rem; border-radius: 999px; background: var(--paper-deep); color: var(--ink); font-size: 0.8rem; font-weight: 600; }
.mark-paid, .mark-solution { background: #f8e4d6; color: #7a3410; }

/* Что бесплатно */
.price-box {
    margin-top: clamp(3rem, 6vw, 4.5rem);
    display: grid; grid-template-columns: 1fr 1fr; gap: 2rem;
    padding: clamp(1.3rem, 3vw, 2rem);
    border-radius: 20px;
    background: #f8e4d6;
    color: #5a2a0e;
}
.price-box h2 { color: #7a3410; }
.price-box.is-single { grid-template-columns: 1fr; }
.price-box strong { color: #5a2a0e; }

/* Тёмный призыв в конце страницы */
.cta-dark {
    margin-top: clamp(3rem, 6vw, 4.5rem);
    display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
    padding: clamp(1.4rem, 3vw, 2.2rem);
    border-radius: 20px;
    background: var(--solid);
    color: #fff;
}
.cta-dark h2 { margin-bottom: 0.4rem; }
.cta-dark p { color: #cfcdc8; margin: 0; }
.btn-light { background: #f59a4f; border-color: #f59a4f; color: var(--ink); white-space: nowrap; }
.btn-light:hover { background: #f8b07a; border-color: #f8b07a; color: var(--ink); }

/* Список сценариев */
.scen-filter { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.8rem; }
.scen-filter a {
    display: inline-flex; align-items: center;
    min-height: 2.75rem; padding: 0 1.1rem;
    border-radius: 999px;
    border: 1px solid var(--rule);
    background: var(--card);
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
}
.scen-filter a.is-on { background: var(--solid); border-color: var(--solid); color: #fff; }
.scen-section { margin-top: 2.6rem; scroll-margin-top: 1rem; }
.scen-section .scen-group-name { margin-bottom: 1rem; }
.scen-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; }
.scen-card-big { gap: 0.6rem; }
.scen-card-big .scen-title { font-size: 1.45rem; }
.scen-pic {
    display: block;
    aspect-ratio: 16 / 10;
    margin-bottom: 0.5rem;
    border-radius: var(--radius);
    background: repeating-linear-gradient(135deg, #ecebe7 0 12px, #f2f1ee 12px 24px);
    border: 2px dashed #b9b6ae;
}
.marks { display: flex; flex-wrap: wrap; gap: 0.35rem; }

/* Схеме нужно около 44rem; если рядом с ней не остаётся места для
   пояснений, они уходят под схему. */
@media (max-width: 78rem) {
    .how { grid-template-columns: 1fr; }
    /* Схема не растягивается шире текста пояснений под ней. */
    .how-map, .how-notes { max-width: 46rem; }
}
@media (max-width: 60rem) {
    .how { grid-template-columns: 1fr; }
    /* Схема поворачивается на 90°: источники — ряд сверху, пространства —
       ряд снизу, связи идут сверху вниз. */
    .how-map { grid-template-columns: 1fr; gap: 0; }
    .how-arrows { display: none; }
    .how-arrows-v { display: block; width: 100%; height: auto; color: var(--brass); }
    .how-sources { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.5rem; }
    .how-ws { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
    .how-src { height: auto; min-height: 4rem; padding: 0.55rem 0.6rem; }
    .how-src b { font-size: 0.92rem; line-height: 1.25; }
    .how-src span { font-size: 0.78rem; }
    .ws-card { height: auto; padding: 0.75rem 0.8rem; }
    .ws-top { flex-direction: column; gap: 0.1rem; }
    .ws-name { font-size: 1.15rem; }
    .ws-note { font-size: 0.78rem; }
    .ws-tags span { font-size: 0.72rem; }
    .steps-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 54rem) {
    .cards-2, .cards-3, .cards-4, .scen-grid, .mini-blocks, .price-box { grid-template-columns: 1fr; }
    .cta-dark { flex-direction: column; align-items: flex-start; }
}

/* ── Страницы подробностей ─────────────────────────────── */

.block-note { margin-top: 1rem; }
.dark-card {
    display: flex; flex-direction: column; gap: 0.6rem;
    padding: 1.4rem;
    border-radius: 18px;
    background: var(--solid);
    color: #d9d8d4;
}
.dark-card-head { display: flex; justify-content: space-between; align-items: center; gap: 0.6rem; color: #fff; }
.tint-note { margin-top: 1rem; padding: 1rem 1.3rem; border-radius: 14px; background: var(--paper-deep); max-width: none; }
.split-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.2rem;
    align-items: center;
    padding: clamp(1.3rem, 3vw, 2rem);
    border-radius: 20px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.split-card h2 { font-size: clamp(1.5rem, 1.15rem + 1.2vw, 2.15rem); margin-bottom: 1rem; }
.ws-example { display: grid; gap: 0.6rem; }
.ws-example .ws-card { height: auto; padding: 0.9rem 1.1rem; flex-direction: row; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.ws-card-light { background: var(--paper-deep); color: var(--ink); }
.ws-card-light .ws-note { color: var(--ink-soft); }
.next-label { font-size: 0.88rem; font-weight: 600; color: var(--seal); }
.pill-row { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.pill {
    display: inline-flex; align-items: center;
    min-height: 2.75rem; padding: 0 1rem;
    border-radius: 999px;
    border: 1px solid var(--rule);
    background: var(--card);
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
}
a.pill:hover { border-color: var(--solid); color: var(--ink); }
.tile-card { background: var(--card); border: 1px solid var(--rule); }

@media (max-width: 54rem) {
    .split-card { grid-template-columns: 1fr; }
}
@media (min-width: 54.01rem) and (max-width: 66rem) {
    .cards-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ── Главная: скачать ──────────────────────────────────── */

.home-download { border-top: 1px solid var(--rule); }
.dl-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 1.2rem 0 1.4rem; }
.dl-card {
    padding: 1.3rem 1.4rem;
    border-radius: 18px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.dl-card .dl-label { margin-bottom: 0.6rem; }
.dl-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.8rem;
    padding: 0.75rem 0;
    border-top: 1px solid var(--rule);
}
.dl-row .dl-os { font-weight: 600; min-width: 7rem; }
.dl-chip { padding: 0.15rem 0.65rem; border-radius: 999px; background: var(--paper-deep); font-size: 0.85rem; color: var(--ink-soft); white-space: nowrap; }
.dl-chip.is-ready { background: #f8e4d6; color: #7a3410; font-weight: 600; }
.dl-btn { margin-left: auto; padding: 0.55rem 1.1rem; }
@media (min-width: 54.01rem) { .dl-row { flex-wrap: nowrap; } .dl-btn { white-space: nowrap; } }
.home-download .promises { margin-top: 0; }
@media (max-width: 54rem) {
    .dl-cards { grid-template-columns: 1fr; }
    .dl-btn { margin-left: 0; }
}

/* Граница сети — ссылка на «Разрешения» */
.sb-boundary a { text-decoration: none; }
.sb-boundary a:hover { text-decoration: underline; text-underline-offset: 0.2em; }

/* ── Компактная полоска на телефоне ────────────────────── */

.topbar-mini {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 60;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.45rem 1.25rem;
    background: rgba(242, 241, 238, 0.96);
    border-bottom: 1px solid var(--rule);
    transform: translateY(-100%);
    transition: transform 0.2s ease;
}
.topbar-mini.is-shown { transform: translateY(0); }
.topbar-mini[hidden] { display: none; }
.brand-mini { display: flex; align-items: center; gap: 0.55rem; color: var(--ink); text-decoration: none; font-family: var(--font-head); font-weight: 600; }
.brand-mini .mark { width: 2rem; height: 2rem; }
.topbar-mini .menu-cta { padding: 0.3rem 0.85rem; text-decoration: none; }
@media (min-width: 46.01rem) { .topbar-mini { display: none !important; } }
@media (prefers-reduced-motion: reduce) { .topbar-mini { transition: none; } }

/* ── Страницы продуктов: МАМ4.Загрузчик, МАМ4.Клиппер ──── */

.status-chip {
    display: inline-block;
    margin: 0.4rem 0 0;
    padding: 0.25rem 0.85rem;
    border-radius: 999px;
    background: var(--paper-deep);
    font-size: 0.92rem;
    font-weight: 600;
}
.block-lead { max-width: 52rem; margin-bottom: 1.2rem; }
.block-lead strong { color: var(--ink); }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 0.6rem; }
.dark-card .card-title { color: #fff; font-family: var(--font-head); font-weight: 600; font-size: 1.35rem; line-height: 1.2; }
.dark-card .mark-chip { background: #f59a4f; color: var(--ink); }
.card-fields { font-size: 0.88rem; font-weight: 600; color: var(--seal); }
.dark-card .card-fields { color: #f59a4f; }
.card-link { font-weight: 600; }
/* Снимок компьютера широкий — он встаёт под карточками или шагами, а не сбоку. */
.with-shots, .steps-wrap.is-wide { display: grid; grid-template-columns: 1fr; gap: 1.6rem; }
.with-shots .shot-wrap, .steps-wrap.is-wide .shot-wrap { max-width: 40rem; justify-self: start; }

/* Цепочка шагов: карточки в ряд со стрелками между ними */
.flow {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 2.2rem;
}
.flow-step {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 1rem 1.1rem;
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--rule);
}
.flow-step span { font-size: 0.92rem; color: var(--ink-soft); line-height: 1.45; }
.flow-step.is-dark { background: var(--solid); border-color: var(--solid); color: #fff; }
.flow-step.is-dark span { color: #d9d8d4; }
/* Шаг-ссылка: вся карточка нажимается */
.flow-step.has-link { padding: 0; }
.flow-step.has-link a { display: flex; flex-direction: column; gap: 0.35rem; height: 100%; padding: 1rem 1.1rem; border-radius: 14px; color: inherit; text-decoration: none; }
.flow-step.has-link:hover { border-color: var(--solid); }
.flow-step.has-link b { color: var(--ink); }
.flow-step:not(:last-child)::after {
    content: "→";
    position: absolute;
    right: -1.65rem;
    top: 50%;
    transform: translateY(-50%);
    color: #8a8f8c;
    font-size: 1.3rem;
}

@media (max-width: 60rem) {
    .flow { grid-auto-flow: row; gap: 1.6rem; }
    .flow-step:not(:last-child)::after { content: "↓"; right: auto; left: 50%; top: auto; bottom: -1.55rem; transform: translateX(-50%); }
}

