* { box-sizing: border-box; margin: 0; padding: 0; }
.hidden { display: none!important; }

/* Тот же брендовый блок, что в apps/web/ui.css и apps/web/whats-new/whats-new.css —
   отдельная страница, поэтому свой собственный файл, а не общий с apps/web. */
:root {
    --brand: #6C5CE7;
    --brand-hover: #5B4BD6;
    --brand-active: #4939C4;
    --brand-disabled: #C7C3ED;
    --brand-on: #FFFFFF;

    --brand-light: #9B8CF0;
    --brand-lighter: #B9B0F5;

    --brand-tint-soft: #F5F3FE;
    --brand-tint: #EDEAFB;
    --brand-tint-strong: #E6E3FA;

    --brand-rgb: 108, 92, 231;    /* для rgba(var(--brand-rgb), α) */

    --text: #111;
    --text-muted: #666;
    --header-h: 39px;             /* высота шапки (как у прежнего блока бренда); от неё считается высота первого экрана */
    --body-pt: 10px;              /* верхний отступ body */
    --section-max-w: 1100px;
}

html { scroll-behavior: smooth; }

body {
    display: flex;
    flex-direction: column;
    padding: var(--body-pt) 0 0 0;
    min-height: 100vh;
    min-height: 100dvh; /* мобильные браузеры: без прыжков из-за адресной строки */
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', sans-serif;
    background-color: #ffffff;
}

img {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* ------------------------------
   Шапка: бренд слева, навигация справа.
   На мобилке навигация уходит под бургер (см. блок «Бургер» ниже и js/nav.js)
   ------------------------------ */
.site-header {
    position: relative;
    z-index: 50; /* выпадающее меню поверх листа, но ниже оверлея D&D (1000) и модалок */
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: var(--header-h);
    /* снизу 10px воздуха — содержимое центрируется в верхних 29px, как у прежнего .app-brand */
    padding: 0 20px 10px;
}

.app-brand {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
    color: var(--text-muted);
    text-decoration: none;
}

.app-brand img { flex-shrink: 0; }

.app-brand h2,
.app-brand__name {
    font-size: 24px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 32px;
}

.site-nav a {
    font-size: 16px;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    white-space: nowrap;
    transition: color .18s;
}

.site-nav a:hover { color: var(--brand); }

/* Между бургером (<800px) и десктопом бренд + 5 пунктов в одну строку не влезают с gap 32px — ужимаем */
@media (min-width: 800px) and (max-width: 959px) {
    .site-nav { gap: 18px; }
    .site-nav a { font-size: 15px; }
    .app-brand h2,
    .app-brand__name { font-size: 20px; }
}

.site-nav__cws {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    line-height: 0;
}

.site-nav__cws img {
    display: block;
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* Подпись к иконке CWS видна только в раскрытом мобильном меню */
.site-nav__cws-label { display: none; line-height: 1.4; }

.nav-toggle {
    display: none;
    flex-shrink: 0;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 32px;
    height: 32px;
    padding: 0 7px;
    border: none;
    border-radius: 10px;
    background: transparent;
    cursor: pointer;
}

.nav-toggle:hover { background: var(--brand-tint-soft); }

.nav-toggle span {
    display: block;
    height: 2px;
    border-radius: 2px;
    background: var(--text);
    transition: transform .25s ease, opacity .2s ease;
}

/* Белый «лист» со скруглёнными верхними углами: первый экран + блоки под ним */
.container {
    width: 100%;
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
    border: none;
    border-radius: 15px 15px 0 0;
    box-shadow: 0 -3px 15px rgba(0,0,0,0.10);
    position: relative;
    background-color: #ffffff;
}

/* Первый экран: на всю высоту окна под шапкой, hero по центру */
.hero-screen {
    min-height: calc(100vh - var(--header-h) - var(--body-pt));
    min-height: calc(100dvh - var(--header-h) - var(--body-pt));
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 20px;
}

/* ------------------------------
   Главный экран: картинка + заголовок + зона загрузки.
   Три раскладки по ширине (ориентир — remove.bg):
     ≥1024px  — две колонки: слева картинка над заголовком, справа зона загрузки;
     640–1023 — сверху картинка и заголовок рядом, зона загрузки под ними;
     <640     — всё в одну колонку по центру.
   ------------------------------ */
.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
        "media  upload"
        "text   upload";
    column-gap: 64px;
    row-gap: 24px;
    align-items: center;
    width: 100%;
    max-width: 1200px;
}

.hero-media {
    grid-area: media;
    align-self: end;
    display: flex;
    align-items: flex-end;
    width: 100%;
    max-width: 420px;
    aspect-ratio: 1 / 1;
}

.hero-img {
    display: block;
    width: 100%;
    max-width: 280px;
    height: auto;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 24px;
}

.page-header {
    grid-area: text;
    align-self: start;
}

.page-header h1 {
    font-size: 56px;
    font-weight: 700;
    line-height: 1.1;
    margin: 0 0 12px 0;
    color: #111;
    text-align: left;
}

.page-header p {
    font-size: 20px;
    color: #666;
    margin: 0;
    line-height: 1.5;
    text-align: left;
}

.upload-section {
    grid-area: upload;
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    max-width: 520px;
    justify-self: center;
}

.upload-area {
    position: relative;
    border: 1.3px dotted #c9c8c8;
    border-radius: 24px;
    /* Сверху больше — кнопка с подписью сидят чуть ниже центра */
    padding: 85px 45px 45px;
    min-height: 340px;
    max-height: 80vh;
    text-align: center;
    background: #f8f8f8;
    cursor: pointer;
    transition: border-color .3s, background-color .3s ease;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.legal-note {
    font-size: 12px;
    line-height: 1.5;
    color: #808080;
    text-align: left;
}

.legal-note a {
    color: inherit;
    text-decoration: underline;
}

.legal-note a:hover { color: var(--brand); }

/* Планшет: картинка и текст в одной строке, зона загрузки под ними */
@media (max-width: 1023px) {
    .hero {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        grid-template-areas:
            "media  text"
            "upload upload";
        column-gap: 32px;
        row-gap: 40px;
        max-width: 720px;
    }
    .hero-media { align-self: center; max-width: 320px; margin-left: auto; }
    .page-header { align-self: center; }
    .hero-img { max-width: 213px; }
    .page-header h1 { font-size: 40px; }
    .page-header p { font-size: 17px; }
    .upload-section { max-width: 460px; }
}

/* Мобилка: одна колонка по центру, зона загрузки компактнее */
@media (max-width: 639px) {
    .hero-screen { padding: 24px 16px; }
    .hero {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "media"
            "text"
            "upload";
        row-gap: 24px;
    }
    .hero-media { max-width: 260px; margin: 0 auto; }
    .hero-img { max-width: 173px; }
    .page-header h1 { font-size: 30px; text-align: center; }
    .page-header p { font-size: 16px; text-align: center; }
    .upload-section { justify-self: stretch; max-width: none; }
    .upload-area { min-height: 200px; padding: 24px; }
    /* Drag & drop на телефоне бессмыслен */
    .upload-hint { display: none; }
    .legal-note { text-align: center; }
}

.upload-area:hover {
    background: var(--brand-tint-soft);
    border-color: var(--brand-light);
}

/* Подпись под кнопкой */
.upload-hint {
    font-size: 19px;
    font-weight: 400;
    margin: 20px 0 0;
    color: #808080;
}

.upload-btn {
    background: var(--brand);
    padding: 14px 54px;
    border: none;
    border-radius: 13px;
    font-size: 20px;
    font-weight: 700;
    color: white;
    cursor: pointer;
    transition: background-color .2s ease, box-shadow .2s ease;
}

.upload-btn:hover { background: var(--brand-hover); }
.upload-btn:active { background: var(--brand-active); }

/* Оверлей D&D: показывается при перетаскивании файлов на любое место страницы */
.drop-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--brand-rgb), 0.88);
    pointer-events: none;
}
.drop-overlay p {
    color: #ffffff;
    font-size: 32px;
    font-weight: 700;
    text-align: center;
    padding: 0 20px;
}

/* Hotkey feedback notifications */
.hotkey-feedback {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(2, 123, 255, 0.9);
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10000;
    transform: translateX(100px);
    opacity: 0;
    transition: all 0.3s ease-out;
    pointer-events: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.hotkey-feedback.show {
    transform: translateX(0);
    opacity: 1;
}

/* Modal */
.modal {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none;
}
.error-icon
{
    display: inline-block;
    background-color: #ffffff;
    color: #ffc341;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    font-weight: bold;
    margin-right: 8px;
    font-size: 20px;
    position: absolute;
    left: 15px;
    top: 15px;
}
.modal-content {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #ffc341;
    padding: 20px 60px;
    border-radius: 6px;
    max-width: 400px;
    color: white;
    font-weight: 600;
    font-size: 16px;
    pointer-events: auto;
    z-index: 1001;
}
.modal-close {
    position: absolute;
    top: 14px;
    right: 12px;
    cursor: pointer;
    font-size: 1.4rem;
    width: 30px;
    line-height: 1.4rem;
    height: 30px;
    display: flex;
    border-radius: 50px;
    border: 2px solid white;
    justify-content: center;
}

/* Info modal стили */
.info-modal .modal-content {
    background: #2196f3;
}

.info-icon {
    display: inline-block;
    background-color: #ffffff;
    color: #2196f3;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    font-weight: bold;
    margin-right: 8px;
    font-size: 20px;
    position: absolute;
    left: 15px;
    top: 15px;
}

@media (max-height: 600px) {
    .upload-area {
        min-height: 200px;
        padding: 20px;
    }
    .hero-screen {
        padding: 10px;
    }
}

/* ══════════════════════════════════════════════════════════════
   Блоки под первым экраном (перенесены из archive/unblur_image_web,
   раскладка оттуда же, цвета и шрифт — как у остальной страницы)
   ══════════════════════════════════════════════════════════════ */
.section-inner {
    width: 100%;
    max-width: var(--section-max-w);
    margin-inline: auto;
    padding-inline: 20px;
}

#how, #features, #use-cases, #faq, #extension { scroll-margin-top: 16px; }

.section-title {
    font-size: 40px;
    font-weight: 700;
    line-height: 1.15;
    text-align: center;
    color: var(--text);
    margin-bottom: 56px;
}

/* ---------- Цифры ---------- */
.stats {
    background: var(--brand-tint);
    padding: 96px 0;
}

.stats__grid {
    display: flex;
    align-items: center;
    justify-content: center;
}

.stats__item {
    flex: 1;
    text-align: center;
    padding: 0 24px;
}

.stats__number {
    font-size: 44px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--brand);
    margin-bottom: 10px;
}

.stats__label {
    font-size: 15px;
    line-height: 1.5;
    color: var(--text-muted);
    max-width: 200px;
    margin-inline: auto;
}

.stats__divider {
    flex-shrink: 0;
    width: 1px;
    height: 60px;
    background: rgba(var(--brand-rgb), .25);
}

/* ---------- How It Works ---------- */
.how {
    padding: 112px 0;
}

.steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 8px;
}

.steps__col {
    display: flex;
    flex-direction: column;
    gap: 24px;
    flex: 1 1 200px;
    min-width: 0;
    max-width: 320px;
}

.step__card {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 16px;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(var(--brand-rgb), .10);
    transition: transform .25s ease, box-shadow .25s ease;
}

.step__card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(var(--brand-rgb), .16);
}

/* Квадратные скриншоты 1000×1000 */
.how-step__img-wrap {
    width: 100%;
    max-width: 280px;
    aspect-ratio: 1 / 1;
    border-radius: 14px;
    overflow: hidden;
    background: var(--brand-tint-soft);
}

.how-step__img-wrap img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Стрелка по центру карточки (квадратная картинка + паддинги) */
.step__arrow {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    height: 320px;
    font-size: 26px;
    color: var(--brand-lighter);
}

.step__title {
    font-size: 19px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
}

.step__desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* ---------- Features ---------- */
.features {
    background: var(--brand-tint-soft);
    padding: 112px 0;
}

/* Bento: слева интро + Background (почти квадрат 692×720, высота по контенту),
   справа Cutout и Shadow (широкие ~1.8:1) друг над другом */
.features__grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 24px;
}

.features__col {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0;
}

/* Интро забирает лишнюю высоту левой колонки, текст прижат к верху */
.features__intro {
    flex: 1;
    padding: 8px 4px 0;
}

.features__intro .section-title {
    text-align: left;
    margin-bottom: 16px;
}

.features__lead {
    max-width: 420px;
    font-size: 17px;
    line-height: 1.6;
    color: var(--text-muted);
}

.feature-tile {
    display: flex;
    flex-direction: column;
    gap: 22px;
    padding: 24px;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(var(--brand-rgb), .08);
    transition: transform .25s ease, box-shadow .25s ease;
}

.feature-tile:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(var(--brand-rgb), .16);
}

/* Подложка под скрин: забирает лишнюю высоту, чтобы колонки сходились по низу */
.feature-tile__media {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
    padding: 16px;
    border-radius: 16px;
    background: var(--brand-tint-soft);
}

.feature-tile__media img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 100%;
    object-fit: contain;
    border-radius: 12px;
}

.feature-tile__text { padding-inline: 4px; }

.feature-tile__title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--text);
    margin-bottom: 8px;
}

.feature-tile__desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* Акцентная плитка, как фиолетовая на референсе */
.feature-tile--background {
    flex: none;
    padding: 28px;
    background: var(--brand);
    box-shadow: 0 8px 32px rgba(var(--brand-rgb), .28);
}

.feature-tile--background:hover { box-shadow: 0 16px 48px rgba(var(--brand-rgb), .36); }

/* Подложка по размеру картинки — не растягивается, пустоты нет */
.feature-tile--background .feature-tile__media {
    flex: none;
    padding: 24px;
    background: rgba(255, 255, 255, .14);
}

.feature-tile--background .feature-tile__title {
    font-size: 26px;
    color: var(--brand-on);
}

.feature-tile--background .feature-tile__desc { color: rgba(255, 255, 255, .85); }

/* ---------- Компактные преимущества (под bento) ---------- */
.perks {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.perk {
    padding: 24px;
    background: #ffffff;
    border: 1px solid var(--brand-tint-strong);
    border-radius: 20px;
}

/* Галочка в фиолетовом кружке — чистый CSS, без ассетов */
.perk__icon {
    position: relative;
    display: block;
    width: 36px;
    height: 36px;
    margin-bottom: 16px;
    border-radius: 50%;
    background: var(--brand);
}

.perk__icon::after {
    content: '';
    position: absolute;
    left: 13px;
    top: 9px;
    width: 8px;
    height: 14px;
    border: solid var(--brand-on);
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
}

.perk__title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--text);
    margin-bottom: 8px;
}

.perk__desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* ---------- Use cases ---------- */
.use-cases { padding: 112px 0; }

/* Десктоп: 3 + 2 по центру; планшет: по 2; мобилка: одна колонка */
.use-cases__list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px 24px;
}

.use-case {
    flex: 0 0 calc((100% - 48px) / 3);
    min-width: 0;
}

/* Шахматка «прозрачного фона» — плейсхолдер, пока нет картинок 1:1 */
.use-case__media {
    position: relative;
    aspect-ratio: 1 / 1;
    margin-bottom: 20px;
    overflow: hidden;
    border-radius: 24px;
    background-color: #ffffff;
    background-image: conic-gradient(var(--brand-tint) 25%, transparent 0 50%, var(--brand-tint) 0 75%, transparent 0);
    background-size: 28px 28px;
    box-shadow: inset 0 0 0 1px var(--brand-tint-strong);
}

.use-case__media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.use-case__title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--text);
    margin-bottom: 8px;
}

.use-case__desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* ---------- FAQ ---------- */
.faq {
    background: var(--brand-tint-soft);
    padding: 112px 0;
}

/* Слева заголовок (липнет при скролле), справа аккордеон */
.faq__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr);
    gap: 64px;
    align-items: start;
}

.faq__head {
    position: sticky;
    top: 32px;
}

.faq__head .section-title {
    text-align: left;
    margin-bottom: 0;
}

.faq__list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq__item {
    background: #ffffff;
    border-radius: 18px;
    transition: box-shadow .2s ease;
}

.faq__item[open] { box-shadow: 0 8px 28px rgba(var(--brand-rgb), .10); }

.faq__item summary {
    position: relative;
    display: block;
    list-style: none;
    padding: 20px 64px 20px 24px;
    cursor: pointer;
    border-radius: 18px;
}

.faq__item summary::-webkit-details-marker { display: none; }

.faq__item summary:focus-visible {
    outline: 2px solid var(--brand);
    outline-offset: 2px;
}

/* Плюс в кружке → крестик при раскрытии */
.faq__item summary::before,
.faq__item summary::after {
    content: '';
    position: absolute;
    right: 30px;
    top: 50%;
    width: 14px;
    height: 2px;
    margin-top: -1px;
    border-radius: 2px;
    background: var(--brand);
    transition: transform .25s ease;
}

.faq__item summary::after { transform: rotate(90deg); }
.faq__item[open] summary::before { transform: rotate(45deg); }
.faq__item[open] summary::after { transform: rotate(135deg); }

.faq__q {
    font-size: 17px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text);
}

.faq__a {
    padding: 0 24px 22px;
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-muted);
}

/* ---------- Финальный CTA ---------- */
.final-cta { padding: 112px 0 56px; }

.final-cta__panel {
    padding: 72px 48px;
    border-radius: 32px;
    background: linear-gradient(135deg, var(--brand) 0%, var(--brand-active) 100%);
    box-shadow: 0 20px 60px rgba(var(--brand-rgb), .30);
    text-align: center;
    color: var(--brand-on);
}

.final-cta__title {
    font-size: 40px;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 14px;
}

.final-cta__text {
    max-width: 560px;
    margin: 0 auto 36px;
    font-size: 18px;
    line-height: 1.55;
    color: rgba(255, 255, 255, .85);
}

/* Зона загрузки на фиолетовом фоне */
.upload-area.upload-area--on-brand {
    max-width: 640px;
    min-height: 0;
    margin-inline: auto;
    padding: 48px 32px;
    background: rgba(255, 255, 255, .10);
    border: 1.5px dashed rgba(255, 255, 255, .55);
}

.upload-area.upload-area--on-brand:hover {
    background: rgba(255, 255, 255, .16);
    border-color: #ffffff;
}

.upload-area--on-brand .upload-btn {
    background: #ffffff;
    color: var(--brand);
}

.upload-area--on-brand .upload-btn:hover { background: var(--brand-tint-soft); }
.upload-area--on-brand .upload-btn:active { background: var(--brand-tint); }

.upload-area--on-brand .upload-hint { color: rgba(255, 255, 255, .8); }

.final-cta__note {
    margin-top: 18px;
    font-size: 14px;
    color: rgba(255, 255, 255, .75);
}

/* ---------- Chrome-расширение ---------- */
.ext { padding: 56px 0 112px; }

.ext__card {
    max-width: 820px;
    margin-inline: auto;
    padding: 40px 44px;
    border: 1px solid var(--brand-tint-strong);
    border-radius: 28px;
    background: #ffffff;
}

.ext__head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

.ext__icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
}

.ext__title {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text);
}

.ext__text {
    font-size: 16px;
    line-height: 1.65;
    color: var(--text-muted);
    margin-bottom: 28px;
}

.ext__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
}

.ext__btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border: 1.5px solid var(--brand-tint-strong);
    border-radius: 13px;
    background: #ffffff;
    color: var(--text);
    font: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease;
}

.ext__btn:hover {
    border-color: var(--brand-light);
    background: var(--brand-tint-soft);
}

.ext__btn img { display: block; width: 22px; height: 22px; }

.ext__badge {
    padding: 5px 12px;
    border-radius: 999px;
    background: var(--brand-tint);
    color: var(--brand);
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
}

.ext__note {
    margin-top: 14px;
    font-size: 13px;
    color: #808080;
}

/* Попап «Coming soon» (нативный <dialog>) */
.cws-dialog {
    width: calc(100% - 32px);
    max-width: 420px;
    margin: auto;
    padding: 32px 28px 28px;
    border: none;
    border-radius: 24px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, .20);
    color: var(--text);
    text-align: center;
}

.cws-dialog::backdrop { background: rgba(31, 27, 58, .55); }

.cws-dialog__title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
}

.cws-dialog__text {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.cws-dialog__btn {
    padding: 12px 40px;
    border: none;
    border-radius: 13px;
    background: var(--brand);
    color: var(--brand-on);
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .2s ease;
}

.cws-dialog__btn:hover { background: var(--brand-hover); }

/* ---------- Юридические страницы (privacy-policy.html) ---------- */
.legal-page {
    max-width: 760px;
    padding-block: 48px 80px;
    color: var(--text);
}

.legal-page h1 {
    font-size: 40px;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 24px;
}

.legal-page h2 {
    font-size: 26px;
    font-weight: 700;
    line-height: 1.25;
    margin: 40px 0 14px;
}

.legal-page h3 {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.35;
    margin: 28px 0 10px;
}

.legal-page h4 {
    font-size: 16px;
    font-weight: 500;
    font-style: italic;
    margin: 22px 0 8px;
}

.legal-page p,
.legal-page li {
    font-size: 16px;
    line-height: 1.6;
}

.legal-page p { margin-bottom: 14px; }

.legal-page ul {
    padding-left: 24px;
    margin-bottom: 14px;
}

.legal-page li + li { margin-top: 6px; }

.legal-page a {
    color: var(--brand);
    overflow-wrap: anywhere; /* длинный email не должен распирать страницу на мобилке */
}

.legal-page a:hover { color: var(--brand-hover); }

@media (max-width: 639px) {
    .legal-page { padding-block: 32px 56px; }
    .legal-page h1 { font-size: 30px; }
    .legal-page h2 { font-size: 22px; margin-top: 32px; }
    .legal-page h3 { font-size: 17px; }
    .legal-page p,
    .legal-page li { font-size: 15px; }
}

/* ---------- Подвал ---------- */
.footer {
    flex-shrink: 0;
    background: #1f1b3a;
    padding: 52px 0 44px;
}

.footer__inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
}

.footer__brand {
    font-size: 19px;
    font-weight: 700;
    color: #ffffff;
}

.footer__cols {
    display: flex;
    gap: 60px;
}

.footer__col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer__col-title {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    color: rgba(255,255,255,.5);
    margin-bottom: 4px;
}

.footer__link {
    font-size: 14px;
    color: rgba(255,255,255,.75);
    text-decoration: none;
    transition: color .18s;
}

.footer__link:hover { color: #ffffff; }

/* ---------- Адаптив блоков ---------- */
@media (max-width: 979px) {
    .stats { padding-block: 72px; }
    .how, .features, .use-cases, .faq { padding-block: 88px; }
    .final-cta { padding-block: 88px 44px; }
    .ext { padding-block: 44px 88px; }
    .perks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    .features__grid {
        grid-template-columns: 1fr;
        max-width: 560px;
        margin-inline: auto;
    }
    .features__intro { padding: 0; text-align: center; }
    .features__intro .section-title { text-align: center; }
    .features__lead { margin-inline: auto; }

    .steps {
        flex-direction: column;
        align-items: center;
        gap: 36px;
    }
    .step__arrow { display: none; }
    .steps__col { width: 100%; }

    .use-case { flex-basis: calc((100% - 24px) / 2); }

    .faq__grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
    .faq__head { position: static; }
    .faq__head .section-title { text-align: center; }
    .faq__list { max-width: 720px; width: 100%; margin-inline: auto; }

    .final-cta__panel { padding: 56px 32px; }
    .final-cta__title { font-size: 34px; }
}

/* ══════════════════════════════
   Бургер-меню: до 800px бренд + 5 пунктов в одну строку не влезают
   (порог синхронизирован с matchMedia в js/nav.js)
   ══════════════════════════════ */
@media (max-width: 799px) {
    .nav-toggle { display: flex; }

    .site-nav {
        display: none;
        position: absolute;
        top: calc(100% + 4px);
        left: 12px;
        right: 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 8px;
        background: #ffffff;
        border-radius: 16px;
        box-shadow: 0 12px 32px rgba(var(--brand-rgb), .18);
    }

    .site-header.is-open .site-nav { display: flex; }

    .site-nav a {
        padding: 14px 16px;
        border-radius: 10px;
        color: var(--text);
        line-height: 1.4;
    }

    .site-nav a:hover { background: var(--brand-tint-soft); }

    .site-nav__cws {
        margin-top: 4px;
        border-top: 1px solid var(--brand-tint);
        border-radius: 0 0 10px 10px !important;
    }

    .site-nav__cws-label { display: inline; }

    /* Полоски бургера → крестик */
    .site-header.is-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .site-header.is-open .nav-toggle span:nth-child(2) { opacity: 0; }
    .site-header.is-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ══════════════════════════════
   Мобилка: компактные блоки
   (брейкпоинт тот же, что у одноколоночного hero)
   ══════════════════════════════ */
@media (max-width: 639px) {
    .site-header { padding: 0 12px 10px 16px; }
    .app-brand h2,
    .app-brand__name { font-size: 18px; }

    .section-inner { padding-inline: 16px; }
    .section-title { font-size: 30px; margin-bottom: 36px; }

    .stats { padding-block: 56px; }
    .how, .features, .use-cases, .faq { padding-block: 64px; }

    .perks { grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 16px; }
    .perk { padding: 20px; }

    /* Use cases: одна колонка, карточки на всю ширину */
    .use-cases__list { gap: 32px; }
    .use-case { flex-basis: 100%; }
    .use-case__media { border-radius: 20px; margin-bottom: 16px; }
    .use-case__title { font-size: 18px; }

    .faq__item summary { padding: 18px 56px 18px 18px; }
    .faq__item summary::before,
    .faq__item summary::after { right: 22px; }
    .faq__q { font-size: 16px; }
    .faq__a { padding: 0 18px 18px; }

    .final-cta { padding-block: 64px 32px; }
    .final-cta .section-inner { padding-inline: 12px; }
    .final-cta__panel { padding: 40px 20px; border-radius: 24px; }
    .final-cta__title { font-size: 28px; }
    .final-cta__text { font-size: 16px; margin-bottom: 28px; }
    .upload-area.upload-area--on-brand { padding: 32px 16px; }

    .ext { padding-block: 32px 64px; }
    .ext__card { padding: 28px 20px; border-radius: 24px; }
    .ext__head { align-items: flex-start; }
    .ext__icon { margin-top: 2px; }
    .ext__title { font-size: 22px; }
    .ext__text { font-size: 15px; }

    .stats__grid { flex-direction: column; gap: 32px; }
    .stats__divider { width: 60px; height: 1px; }
    .stats__number { font-size: 36px; }

    .feature-tile,
    .feature-tile--background { padding: 18px; gap: 18px; }
    .feature-tile__media,
    .feature-tile--background .feature-tile__media { padding: 12px; }
    .feature-tile--background .feature-tile__title { font-size: 22px; }

    .footer__inner { flex-direction: column; }
    .footer__cols { flex-direction: column; gap: 28px; }
}
