/* Иду на контракт — анимации и мобильные правки (Claude, 2026-10-21)
   Принципы анимации (Emil Kowalski): только transform и opacity, ease-out,
   короткие длительности, без «пружин» и ease-in, уважение prefers-reduced-motion. */

:root {
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
    --transition: 0.2s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Читаемость текстов статей и разделов */
.editor {
    max-width: 760px;
    font-size: 17px;
    line-height: 1.65;
}
.editor p {
    margin: 0 0 1em;
}
.editor > h2 {
    font-size: clamp(24px, 2.2vw, 32px);
    line-height: 1.25;
    margin: 1.6em 0 0.6em;
}
.editor > h3 {
    font-size: clamp(20px, 1.7vw, 24px);
    line-height: 1.3;
    margin: 1.4em 0 0.5em;
}
.editor > :first-child {
    margin-top: 0;
}
.editor ul,
.editor ol {
    margin: 0 0 1em;
    padding-left: 1.3em;
}
.editor li {
    margin: 0.35em 0;
    line-height: 1.6;
}
.editor a:not(.btn) {
    color: #3b4ef6;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: text-decoration-thickness 0.15s var(--ease-out), color 0.15s var(--ease-out);
}
.editor a:not(.btn):hover {
    color: #142bf4;
    text-decoration-thickness: 2px;
}

/* Видимый фокус для навигации с клавиатуры */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
    outline: 2px solid #3b4ef6;
    outline-offset: 2px;
}

/* Появление блоков при прокрутке (заменяет WOW.js + animate.css) */
.m-pending {
    opacity: 0;
    transform: translate3d(0, 14px, 0);
}
.m-in {
    opacity: 1;
    transform: none;
    transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
    transition-delay: var(--m-delay, 0ms);
}

/* Отклик кнопок на нажатие */
.btn,
.side__btn {
    transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out),
        border-color 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out), transform 0.16s var(--ease-out);
}
.btn:active,
.side__btn:active {
    transform: scale(0.97);
}

/* Без «пружинящих» и ease-in кривых */
.dropdown .drop-content,
.dropup .drop-content,
.dropstart .drop-content,
.dropend .drop-content,
.modal {
    transition-timing-function: var(--ease-out);
    transition-duration: 0.2s;
}

/* Хлебные крошки: один разделитель вместо «/ »» */
.speedbar a::after {
    content: none;
}

/* Мобильная типографика */
/* Прокрутка на мобильных: в теме у html и body одновременно стоит overflow-x:hidden (до 540px) —
   в мобильных WebKit/Яндекс Браузере это делает body отдельной областью прокрутки и страница «залипает».
   Оставляем обрезку только на body и через clip (не создаёт область прокрутки). */
@media (max-width: 540px) {
    html {
        overflow-x: visible;
    }
    body {
        overflow-x: hidden;
        overflow-x: clip;
    }
}

@media (max-width: 480px) {
    /* суммы в карточках первого экрана помещаются в строку, ₽ не отрывается */
    .hero__item-text {
        font-size: clamp(14px, 4.1vw, 18px);
    }
}

@media (max-width: 720px) {
    .title__text {
        font-size: clamp(22px, 7vw, 28px);
        line-height: 1.15;
        overflow-wrap: break-word;
    }
    .editor h2 {
        font-size: clamp(22px, 6.2vw, 30px);
        line-height: 1.25;
        margin: 28px 0 12px;
        overflow-wrap: break-word;
    }
    .editor h3 {
        font-size: clamp(19px, 5.2vw, 24px);
        line-height: 1.3;
        margin: 22px 0 10px;
        overflow-wrap: break-word;
    }
    .editor h4 {
        font-size: 18px;
        line-height: 1.35;
    }
    .static__title {
        overflow-wrap: break-word;
    }
    .fullstory__head {
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 8px 12px;
    }
    .fullstory__head-category {
        height: auto;
        min-height: 30px;
        padding-block: 4px;
        max-width: 100%;
        white-space: normal;
        font-size: 14px;
    }
    /* Ссылки в подвале — удобная зона нажатия */
    .footer__info-link {
        display: inline-block;
        padding: 6px 0;
    }
    /* Плавающая кнопка «Связаться» не перекрывает конец страницы */
    footer {
        padding-bottom: 72px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .m-pending {
        opacity: 1;
        transform: none;
    }
    .m-in,
    .btn,
    .side__btn {
        transition: none;
    }
    .btn:active,
    .side__btn:active {
        transform: none;
    }
}

/* Мобильные: длинные кнопки в тексте и FAQ не выходят за экран (2026-10-21) */
@media (max-width: 540px) {
    .faq__inner { grid-template-columns: minmax(0, 1fr); }
    .faq__body { min-width: 0; }
    .editor .btn, .static__text .btn, .faq .btn-full {
        white-space: normal; max-width: 100%; height: auto; min-height: 44px;
        padding-top: 10px; padding-bottom: 10px; line-height: 1.3; text-align: center;
    }
}

/* Подзаголовки карточек: h3 вместо h5/h6 (порядок заголовков), вид прежний */
h3.h6 { font-size: 20px; font-weight: 500; line-height: 1.5; font-family: var(--font-title); color: var(--color-title); }
.contacts__social h3.h6 { color: var(--color-white); margin-bottom: 15px; }

/* ===== UX-fixes 2026-10-22 (аудит адаптива) ===== */
/* 1. Кнопки с длинным текстом вылезают за экран (FAQ, Профессии, Документы) */
@media (max-width: 540px) {
  .btn {
    white-space: normal;
    height: auto;
    min-height: 56px;
    padding-block: 12px;
    text-align: center;
    line-height: 1.25;
  }
}
@media (max-width: 960px) {
  .faq__inner { grid-template-columns: minmax(0, 1fr); }
}

/* 2. Кнопки .btn без модификатора в SEO-блоках выглядят как обычный текст */
.editor a.btn:not(.btn-primary):not(.btn-secondary),
.seo-gap-block a.btn:not(.btn-primary):not(.btn-secondary) {
  background: var(--color-primary, #3b4ef6);
  color: #fff;
  min-height: 52px;
  padding-inline: 24px;
  text-decoration: none;
}

/* 3. Шапка: полупрозрачный фон, сквозь «щель» между логотипом и телефоном виден текст */
@media (max-width: 1140px) {
  .header__inner { background: rgba(255, 255, 255, .97); }
  /* шапка 80px вместо 132px — убираем лишний отступ над hero */
  .hero { padding-top: 95px; }
}

/* 4. Плашки с цифрами в hero: «до» отрывается от суммы */
.hero__item:not(:last-child) .hero__item-text { white-space: nowrap; } /* 4-я плашка — текст, ей перенос нужен */
@media (max-width: 540px) {
  .hero__item-text { font-size: clamp(18px, 5.4vw, 24px); }
  .hero__item-text span { font-size: .6em; }
}

/* 5. Висячие предлоги и «СВО» одной строкой в заголовках */
h1, h2, .title__text, .hero__promo-title { text-wrap: balance; }
/* переносы по слогам в подзаголовках смотрятся плохо */
.editor h2, .editor h3 { hyphens: manual; }

/* 6. Плавающая кнопка «Связаться» перекрывает меню, модалки и футер */
.side { z-index: 1015; }               /* ниже шапки (1020), меню (1030) и модалок (1040) */
body.backdrop .side,
body:has(.modal.active) .side { opacity: 0; pointer-events: none; }  /* прячем, пока открыто меню или модалка */
@media (min-width: 721px) { footer { padding-bottom: 90px; } }

/* 7. Пункты мобильного меню — маленькие тап-зоны */
.menu__links a { padding-block: 10px; font-size: 18px; }
.panestart-content { background: rgba(255, 255, 255, .97); }

/* 8. Блок «Что важно знать» на десктопе занимает половину ширины */
#seo-info .conditions__inner { grid-template-columns: 1fr; }
@media (min-width: 960px) {
  #seo-info .conditions__list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
}

/* 9. «Этапы подготовки» на планшете: 3 колонки → дыра в последнем ряду */
@media (min-width: 541px) and (max-width: 1140px) {
  .steps__inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 10. Статья: обложка, заголовок и текст разной ширины и не по центру */
.fullstory__head, .fullstory__cover, .fullstory__body {
  max-width: 860px;
  margin-inline: auto;
}
.fullstory__body { padding-inline: 0; }
.fullstory__cover img { display: block; width: 100%; height: auto; }
.fullstory__body .editor { max-width: none; }

/* 11. Список статей: обложки обрезаются слева («окументы», «ыплаты») */
.shortstory__cover img, .promo__cover img { object-position: left center; }

/* 12. Перевёрнутая иерархия заголовков на статических страницах (h4 крупнее h3) */
.static__text.editor h2 { font-size: clamp(24px, 2.6vw, 32px); }
.static__text.editor h3,
.static__text.editor .seo-cta h3,
.static__text.editor .seo-gap-block h3 { font-size: clamp(20px, 2vw, 24px); }
.static__text.editor h4 { font-size: clamp(17px, 1.5vw, 19px); }

/* 13. «Задайте вопрос, мы онлайн:» и «Вопросы и ответы» переносятся на 2 строки */
/* на 1141–1199 px в одну строку не помещается (телефон в шапке уезжает за край) */
@media (min-width: 1200px) { .header__menu a, .header__contacts-label { white-space: nowrap; } }

/* 14. Окно «Выберите город»: 22 города одной узкой колонкой → сетка (4 кол. десктоп / 2 кол. телефон) */
.city { grid-template-columns: 1fr; }
.city__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 4px 16px;
}
.city__list-item a { display: block; padding: 8px 0; }

/* 15. «Льготы и гарантии семьям»: номер [1]…[4] стоит под текстом на разной высоте → наверх, как в остальных блоках */
.garant__item-content { display: flex; flex-direction: column; }
.garant__item-count { order: -1; margin: 0 0 10px; }

/* 16. Регион в H1 городских страниц */
.hero__region { display: block; font-size: .55em; line-height: 1.2; margin-top: 6px; }

/* 17. Названия городов не рвать по дефису («Ростов-на- / Дону», «Санкт- / Петербург») */
.nowrap { white-space: nowrap; }

/* Таблицы в тексте разделов и статей (2026-10-22): отступы, линии, прокрутка на телефоне */
.editor .table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 1.2em; }
.editor table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.45; margin: 0 0 1.2em; }
.editor .table-scroll table { margin: 0; }
.editor th, .editor td { padding: 10px 12px; border-bottom: 1px solid #e6e7eb; text-align: left; vertical-align: top; }
.editor thead th { background: #f4f4f5; font-weight: 600; }
.editor td a { font-weight: 600; }
.editor .table-scroll td:nth-child(3) { font-weight: 600; }
@media (max-width: 720px) {
  .editor .table-scroll table { min-width: 560px; font-size: 14px; }
  .editor th, .editor td { padding: 8px 10px; }
}

/* Документы: категории свёрнуты в <details> (2026-10-22) */
.doc-group { border-top: 1px solid #e5e7eb; }
.doc-group > summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 0; font-weight: 600; font-size: clamp(18px, 2vw, 22px); }
.doc-group > summary::-webkit-details-marker { display: none; }
.doc-group > summary::after { content: "+"; color: var(--color-primary, #3b4ef6); font-size: 1.4em; line-height: 1; }
.doc-group[open] > summary::after { content: "−"; }
.doc-group > summary .doc-group__title { margin: 0; font: inherit; color: inherit; }
.doc-group__count { margin-left: auto; color: #8a8f98; font-weight: 400; font-size: .8em; }

/* «из Ростова-на-Дону» в плашке первого экрана: город тем же кеглем, длинные названия помещаются на телефоне */
.hero__item-text span.nowrap { font-size: inherit; margin: 0; }
@media (max-width: 540px) {
  .hero.hero--v2 .hero__main--compact .hero__item:last-child .hero__item-text { font-size: clamp(14px, 4vw, 18px); }
}
/* Плашки первого экрана на узких телефонах: колонки не распирают сетку, суммы и «из Санкт-Петербурга» помещаются */
@media (max-width: 400px) {
  .hero.hero--v2 .hero__main--compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero.hero--v2 .hero__main--compact .hero__item-text { font-size: clamp(14px, 4.4vw, 18px); }
  .hero.hero--v2 .hero__main--compact .hero__item:last-child .hero__item-text { font-size: clamp(13px, 3.8vw, 18px); }
}

/* Окно «Выберите город» на телефоне: 2 колонки, «Санкт-Петербург» и «Ростов-на-Дону» без разрыва по дефису */
@media (max-width: 420px) {
  .city__list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 12px; }
  .city__list-item a { font-size: 15px; }
}
@media (max-width: 380px) { .city__list-item a { font-size: 14px; } }
@media (max-width: 340px) { .city__list { grid-template-columns: 1fr; } }

/* 2026-10-22: длинный текст кнопки не вылезает за её край (FAQ: «Оставить заявку на бесплатную консультацию») */
.faq__link { max-width: 460px; }
.btn-full.btn-lg { height: auto; min-height: 80px; white-space: normal; text-align: center; line-height: 1.3; padding-top: 12px; padding-bottom: 12px; }

/* 2026-10-22: призыв к действию в конце статьи */
.fullstory__cta { margin: 36px 0 8px; }

/* 2026-10-22: 404 и служебные сообщения — ссылки «куда дальше» */
.info__links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; margin-top: 20px; }
.info__links a:not(.btn) { color: var(--color-primary); text-decoration: underline; text-underline-offset: 3px; }
.info__links .btn { margin-left: auto; }
@media (max-width: 540px) { .info__links .btn { margin-left: 0; width: 100%; } }

/* 2026-10-22: ссылки в подвале с отступами, а не сплошной строкой */
.footer__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; }

/* 2026-10-22: заголовок карточки статьи — до 3 строк, а не обрывается на середине */
.shortstory__content-title { -webkit-line-clamp: 3; line-clamp: 3; }

/* 2026-10-22: форма поиска в стиле сайта вместо стандартной браузерной */
.searchtable td.search > div { margin: 0 0 20px !important; }
.searchtable td.search br { display: none; }
.searchtable #searchinput { display: block; width: 100%; max-width: 560px; height: 52px; margin-bottom: 12px; padding: 0 16px; border: 1px solid #d6dae3; background: #fff; font: inherit; font-size: 16px; color: var(--color-title); }
.searchtable #searchinput:focus { border-color: var(--color-primary); }
.searchtable input.bbcodes { height: 46px; margin: 0 8px 8px 0; padding: 0 22px; border: 0; background: var(--color-primary); color: #fff; font: inherit; font-size: 15px; font-weight: 500; cursor: pointer; }
.searchtable #dofullsearch { background: #eef0f6; color: var(--color-title); }

/* 2026-10-22: таблица в статье без обёртки .table-scroll не растягивает страницу на телефоне */
@media (max-width: 720px) { .editor table:not(.table-scroll > table) { min-width: 0; width: 100%; } .editor table:not(.table-scroll > table) { display: block; max-width: 100%; overflow-x: auto; } .editor table:not(.table-scroll > table) th, .editor table:not(.table-scroll > table) td { padding: 8px; font-size: 14px; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; } .editor table:not(.table-scroll > table) th { -webkit-hyphens: manual; hyphens: manual; } }

/* 2026-10-22: статья — обложка целиком (16:9, без обрезки), на широких экранах две колонки: текст и боковая панель */
.fullstory__cover img { aspect-ratio: 16 / 9; height: auto; }
.fullstory__aside { display: none; }
.fullstory .editor h2 { scroll-margin-top: 110px; }
@media (min-width: 1200px) {
    .fullstory__top { max-width: 1290px; padding-left: 40px; padding-right: 40px; box-sizing: border-box; }
    .fullstory__top .fullstory__head { max-width: none; margin: 0 0 30px; }
    .fullstory__top .fullstory__title { max-width: 1000px; }
    .fullstory__layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; align-items: start; max-width: 1290px; margin: 0 auto; padding: 0 40px 40px; box-sizing: border-box; }
    .fullstory__layout .fullstory__cover,
    .fullstory__layout .fullstory__body { max-width: none; margin-left: 0; margin-right: 0; }
    .fullstory__aside { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 104px; }
}
.fullstory__toc { padding: 22px 24px; background: #f4f6fa; }
.fullstory__toc-title { display: block; margin-bottom: 10px; font-family: var(--font-title); font-size: 18px; font-weight: 600; color: var(--color-title); }
.fullstory__toc ol { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.fullstory__toc li { counter-increment: toc; }
.fullstory__toc a { display: grid; grid-template-columns: 24px 1fr; padding: 7px 0; font-size: 15px; line-height: 1.35; color: #4b5160; text-decoration: none; transition: color .15s ease; }
.fullstory__toc a::before { content: counter(toc) "."; color: #9aa1b1; font-variant-numeric: tabular-nums; }
.fullstory__toc a:hover,
.fullstory__toc a.is-active,
.fullstory__toc a.is-active::before { color: var(--color-primary); }
.fullstory__side-cta { display: flex; flex-direction: column; gap: 10px; padding: 24px; color: #fff; background: linear-gradient(135deg, #3b4ef6, #142bf4); }
.fullstory__side-cta strong { font-family: var(--font-title); font-size: 20px; line-height: 1.2; }
.fullstory__side-cta span { font-size: 15px; line-height: 1.45; opacity: .88; }
.fullstory__side-btn { width: 100%; height: 56px; margin-top: 6px; background: #fff; color: var(--color-primary); }
.fullstory__side-link { display: flex; align-items: center; justify-content: center; height: 48px; border: 1px solid rgba(255, 255, 255, .45); color: #fff; font-weight: 500; text-decoration: none; transition: background-color .15s ease; }
.fullstory__side-link:hover { background: rgba(255, 255, 255, .12); color: #fff; }

/* боковая панель статьи компактнее, чтобы не уходить под кнопку чата на ноутбуках */
.fullstory__toc a { padding: 5px 0; font-size: 14px; }
@media (min-width: 1200px) and (max-height: 860px) { .fullstory__side-cta span { display: none; } .fullstory__toc { padding: 18px 22px; } }

/* 2026-10-22: статичные страницы — шире текст, боковая панель на широких экранах, плашки и кнопки в одном стиле с сайтом (прямые углы, чёрный уголок) */
.static__aside { display: none; }
.static__text h2, .static__text h3 { scroll-margin-top: 110px; }
@media (min-width: 1200px) {
    .static__content { max-width: 1290px; padding-left: 40px; padding-right: 40px; box-sizing: border-box; margin-left: auto; margin-right: auto; }
    .static__layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; align-items: start; }
    .static__layout .static__text { max-width: none; }
    .static__aside { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 104px; margin-top: 20px; }
}

/* синяя плашка «Уточнить условия» и плашка в конце статьи */
.static__cta { position: relative; border-radius: 0; padding: 32px 36px; gap: 32px; }
.static__cta::after { content: ""; position: absolute; right: 0; bottom: 0; width: 14px; height: 14px; background: #04070e; clip-path: polygon(100% 0, 100% 100%, 0 100%); }
.static__cta-content strong { font-size: 24px; }
.static__cta-content span { max-width: 520px; font-size: 16px; line-height: 1.45; }
.static__cta-actions { flex-wrap: nowrap; gap: 12px; }
.static__cta-actions .btn,
.static__cta-link { height: 56px; min-width: 190px; padding: 0 26px; border-radius: 0; font-size: 16px; font-weight: 600; white-space: nowrap; }
.static__cta-link { background: transparent; border: 1px solid rgba(255, 255, 255, .6); color: #fff; transition: background-color .15s ease; }
.static__cta-link:hover { background: rgba(255, 255, 255, .14); color: #fff; }
@media (max-width: 900px) {
    .static__cta { flex-direction: column; align-items: stretch; padding: 24px 22px; gap: 20px; }
    .static__cta-actions { flex-direction: column; align-items: stretch; }
    .static__cta-actions .btn, .static__cta-link { width: 100%; min-width: 0; }
    .static__cta-content strong { font-size: 21px; }
}

/* карточки «Что получите / Что нужно / Сколько занимает» */
.static__cards > div { position: relative; border-radius: 0; background: #f4f6fa; padding: 22px 22px 20px; }
.static__cards > div::before { content: ""; position: absolute; top: 0; left: 0; width: 12px; height: 12px; background: #04070e; clip-path: polygon(0 0, 100% 0, 0 100%); }

/* плашки внутри текста и карточки документов: без скруглений, как остальной сайт */
.editor .seo-cta { position: relative; border-radius: 0 !important; border: 0 !important; background: #f4f6fa !important; padding: 26px 28px !important; }
.editor .seo-cta::before { content: ""; position: absolute; top: 0; left: 0; width: 12px; height: 12px; background: #04070e; clip-path: polygon(0 0, 100% 0, 0 100%); }
.editor .seo-cta .btn { height: 52px; padding: 0 26px; border-radius: 0; }
.document-download-item { border-radius: 0 !important; }
.document-download-item a { border-radius: 0 !important; }

/* 2026-10-22: новый подвал */
.site-footer { margin-top: 24px; padding-bottom: 110px; } /* запас снизу под плавающую кнопку «Связаться» */
.site-footer__card { position: relative; padding: 56px 56px 0; background: #070b14; color: rgba(255, 255, 255, .72); }
.site-footer__card::before { content: ""; position: absolute; top: 0; left: 0; width: 18px; height: 18px; background: var(--color-primary); clip-path: polygon(0 0, 100% 0, 0 100%); }
.site-footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 48px; }
.site-footer__logo { display: inline-block; }
.site-footer__logo svg { display: block; width: 150px; height: 40px; }
.site-footer__logo svg path { fill: #fff !important; }
.site-footer__logo svg text { fill: #fff !important; }
.site-footer__about { max-width: 300px; margin: 20px 0 24px; font-size: 15px; line-height: 1.55; color: rgba(255, 255, 255, .72); }
.site-footer__title { display: block; margin-bottom: 16px; font-family: var(--font-title); font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: #fff; }
.site-footer__col a { display: block; padding: 6px 0; font-size: 15px; line-height: 1.35; color: rgba(255, 255, 255, .72); text-decoration: none; transition: color .15s ease; }
.site-footer__col a:hover { color: #fff; }
.site-footer__phone { display: block; font-family: var(--font-title); font-size: 24px; font-weight: 700; line-height: 1.2; color: #fff; text-decoration: none; white-space: nowrap; }
.site-footer__phone:hover { color: #fff; opacity: .85; }
.site-footer__phone-note { display: block; margin: 6px 0 20px; font-size: 14px; line-height: 1.4; color: rgba(255, 255, 255, .55); }
.site-footer__cta { width: 100%; height: 56px; }
.site-footer .social { display: flex; gap: 10px; }
.site-footer .social-btn:not(.social-btn--max) { background: rgba(255, 255, 255, .08); color: #fff; transition: background-color .15s ease; }
.site-footer .social-btn:not(.social-btn--max):hover { background: rgba(255, 255, 255, .18); }
.site-footer__bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 32px; padding: 22px 0 26px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: 13px; line-height: 1.5; color: rgba(255, 255, 255, .5); }
.site-footer__disclaimer { flex: 1 1 420px; text-align: center; }
.site-footer__bottom a { color: rgba(255, 255, 255, .72); text-decoration: underline; text-underline-offset: 3px; }
.site-footer__bottom a:hover { color: #fff; }
@media (max-width: 1199px) {
    .site-footer__top { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px 32px; }
    .site-footer__brand { grid-column: span 2; }
}
@media (max-width: 767px) {
    .site-footer { padding-bottom: 96px; }
    .site-footer__card { padding: 40px 22px 0; }
    .site-footer__top { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 20px; padding-bottom: 36px; }
    .site-footer__brand, .site-footer__contact { grid-column: 1 / -1; }
    .site-footer__about { max-width: none; }
    .site-footer__bottom { flex-direction: column; align-items: flex-start; }
    .site-footer__disclaimer { flex: none; text-align: left; }
}

/* 2026-10-22: навигация — выпадающие списки «Выплаты» и «Профессии», подсветка текущего раздела, мобильное меню с подразделами */
.nav-dd-btn { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 22px; height: 22px; margin: 0; padding: 0; border: 0; background: none; color: inherit; cursor: pointer; transition: transform .18s ease-out; }
.nav-item--dd.is-open > .nav-dd-btn { transform: rotate(180deg); }

@media (min-width: 1141px) {
    .header__menu { gap: 26px; }
    .header__menu .nav-item { position: relative; display: flex; align-items: center; gap: 2px; height: 80px; }
    .header__menu .nav-dd-btn { color: var(--color-dark); }
    .header__menu a.is-active,
    .header__menu .nav-item--dd.is-current > .nav-link { color: var(--color-primary); border-color: var(--color-primary); }
    .header__menu .nav-dd { position: absolute; top: 100%; left: -16px; z-index: 30; min-width: 250px; padding: 10px; background: #fff; box-shadow: 0 18px 40px rgba(4, 7, 14, .14); opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .16s ease-out, transform .16s ease-out, visibility 0s linear .16s; }
    .header__menu .nav-dd::before { content: ""; position: absolute; top: 0; left: 0; width: 12px; height: 12px; background: #04070e; clip-path: polygon(0 0, 100% 0, 0 100%); }
    .header__menu .nav-item--dd.is-open .nav-dd { opacity: 1; visibility: visible; transform: none; transition: opacity .16s ease-out, transform .16s ease-out, visibility 0s; }
    .header__menu .nav-dd a { display: block; height: auto; padding: 10px 14px; border: 0; font-size: 15px; line-height: 1.3; color: var(--color-dark); white-space: nowrap; transition: background-color .12s ease, color .12s ease; }
    .header__menu .nav-dd a:hover,
    .header__menu .nav-dd a.is-active { background: #f4f6fa; color: var(--color-primary); }
}
@media (min-width: 1141px) and (hover: hover) and (pointer: fine) {
    .header__menu .nav-item--dd:hover .nav-dd { opacity: 1; visibility: visible; transform: none; transition: opacity .16s ease-out, transform .16s ease-out, visibility 0s; }
    .header__menu .nav-item--dd:hover > .nav-dd-btn { transform: rotate(180deg); }
}
.nav-dd-btn svg path { fill: none !important; stroke: currentColor; }
@media (min-width: 1141px) { .header__menu a { white-space: nowrap; } }
@media (min-width: 1141px) and (max-width: 1365px) { .header__menu { gap: 18px; } }
@media (min-width: 1141px) and (max-width: 1279px) { .header__menu { gap: 13px; } .header__menu a { font-size: 13.5px; } .header__contacts-label { display: none; } }

/* мобильное меню */
.menu__links { gap: 0; }
.menu__links > a,
.menu__links .nav-item > .nav-link { min-height: 50px; font-size: 17px; }
.menu__links > a { border-bottom: 1px solid #eceef3; }
.menu__links .nav-item { display: grid; grid-template-columns: minmax(0, 1fr) 48px; align-items: center; border-bottom: 1px solid #eceef3; }
.menu__links .nav-dd-btn { width: 48px; height: 48px; color: var(--color-dark); }
.menu__links .nav-dd { display: none; grid-column: 1 / -1; padding: 0 0 12px 20px; }
.menu__links .nav-item--dd.is-open .nav-dd { display: block; }
.menu__links .nav-dd a { min-height: 42px; font-size: 15px; color: #4b5160; }
.menu__links .nav-dd a::before { opacity: .45; }
.menu__links a.is-active,
.menu__links .nav-item--dd.is-current > .nav-link { color: var(--color-primary); font-weight: 600; }
.menu__cta { display: flex; align-items: center; justify-content: center; height: 56px; margin: 10px 15px 0; border: 1px solid var(--color-primary); background: #fff; color: var(--color-primary); font-weight: 600; }

/* 2026-10-22: главная, блок выплат на узких телефонах (320 px) не вылезает за экран */
@media (max-width: 767px) { .payments__inner { grid-template-columns: minmax(0, 1fr); } .payments__tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .payments__tabs-btn { min-width: 0; white-space: normal; } }

/* 2026-10-22: страница «Города» (static-goroda.tpl) */
.cities { display: flex; flex-direction: column; gap: 24px; padding-bottom: 8px; }
.cities [hidden] { display: none !important; }
.cities__hero, .cities__featured, .cities__all { position: relative; background: #fff; }
.cities__hero::before, .cities__featured::before, .cities__all::before { content: ""; position: absolute; top: 0; left: 0; width: 14px; height: 14px; background: #04070e; clip-path: polygon(0 0, 100% 0, 0 100%); }
.cities__hero { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; align-items: stretch; padding: 48px; }
.cities__eyebrow { display: inline-block; align-self: flex-start; padding: 6px 12px; background: #eef0fe; color: var(--color-primary); font-size: 13px; font-weight: 600; letter-spacing: .02em; }
.cities__hero-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.cities__title { margin: 0; font-family: var(--font-title); font-size: clamp(28px, 3.6vw, 46px); line-height: 1.08; text-transform: uppercase; color: var(--color-title); }
.cities__lead { max-width: 640px; margin: 0; font-size: 17px; line-height: 1.55; color: #4b5160; }
.cities__search { display: flex; align-items: center; gap: 12px; height: 60px; margin-top: 8px; padding: 0 18px; border: 2px solid #e3e6ee; background: #fff; color: #9aa1b1; cursor: text; transition: border-color .15s ease; }
.cities__search:focus-within { border-color: var(--color-primary); color: var(--color-primary); }
.cities__search svg { flex: none; }
.cities__search svg circle, .cities__search svg path { fill: none !important; stroke: currentColor; }
.cities__search-input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; font: inherit; font-size: 17px; color: var(--color-title); }
.cities__search-input::placeholder { color: #9aa1b1; }
.cities__status { min-height: 20px; margin: -6px 0 0; font-size: 14px; color: #6b7280; }
.cities__hero-card { position: relative; display: flex; flex-direction: column; justify-content: center; gap: 10px; padding: 32px 28px; color: #fff; background: linear-gradient(135deg, #3b4ef6, #142bf4); }
.cities__hero-card::after { content: ""; position: absolute; right: 0; bottom: 0; width: 14px; height: 14px; background: #04070e; clip-path: polygon(100% 0, 100% 100%, 0 100%); }
.cities__hero-card strong { font-family: var(--font-title); font-size: 24px; line-height: 1.2; }
.cities__hero-card span { font-size: 15px; line-height: 1.5; opacity: .9; }
.cities__hero-btn { width: 100%; height: 56px; margin-top: 8px; background: #fff; color: var(--color-primary); }
.cities__hero-phone { align-self: center; margin-top: 4px; font-family: var(--font-title); font-size: 20px; font-weight: 700; color: #fff; text-decoration: none; }
.cities__hero-phone:hover { color: #fff; opacity: .85; }
.cities__featured, .cities__all { padding: 40px 48px; }
.cities__section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.cities__h2 { margin: 0; font-family: var(--font-title); font-size: 28px; line-height: 1.2; color: var(--color-title); }
.cities__more { font-weight: 600; color: var(--color-primary); text-decoration: none; }
.cities__more::after { content: " →"; }
.cities__more:hover { text-decoration: underline; text-underline-offset: 3px; }
.cities__note { margin: 10px 0 22px; font-size: 15px; color: #6b7280; }
.cities__cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.city-card { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 18px 44px 18px 18px; border: 1px solid transparent; background: #f4f6fa; text-decoration: none; transition: background-color .15s ease-out, border-color .15s ease-out, transform .15s ease-out; }
.city-card::after { content: "→"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: #9aa1b1; transition: color .15s ease-out, transform .15s ease-out; }
.city-card__name { font-size: 17px; font-weight: 600; line-height: 1.25; color: var(--color-title); }
.city-card__region { font-size: 13px; line-height: 1.35; color: #6b7280; }
@media (hover: hover) and (pointer: fine) {
    .city-card:hover { background: #fff; border-color: var(--color-primary); transform: translateY(-2px); }
    .city-card:hover::after { color: var(--color-primary); transform: translate(3px, -50%); }
}
.city-card:active { transform: scale(.98); }
.cities__abc { position: sticky; top: 80px; z-index: 5; display: flex; flex-wrap: wrap; gap: 4px; margin: 20px -8px 0; padding: 10px 8px; background: #fff; border-bottom: 1px solid #eceef3; }
.cities__abc a { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; font-size: 15px; font-weight: 600; color: var(--color-title); text-decoration: none; transition: background-color .12s ease, color .12s ease; }
.cities__abc a:hover { background: var(--color-primary); color: #fff; }
.cities__abc a.is-empty { opacity: .25; pointer-events: none; }
.cities__list h2 { margin: 28px 0 10px; padding-bottom: 8px; border-bottom: 1px solid #eceef3; font-family: var(--font-title); font-size: 26px; line-height: 1.1; color: var(--color-primary); scroll-margin-top: 150px; }
.cities__list ul { margin: 0; padding: 0; list-style: none; columns: 4 190px; column-gap: 24px; }
.cities__list li { break-inside: avoid; margin: 0; padding: 0; }
.cities__list li::before, .cities__list li::marker { content: none; }
.cities__list a { display: block; padding: 6px 0; font-size: 15px; line-height: 1.35; color: var(--color-dark, #04070e); text-decoration: none; }
.cities__list a:hover { color: var(--color-primary); }
.cities__empty { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin-top: 24px; padding: 28px; background: #f4f6fa; }
.cities__empty strong { font-family: var(--font-title); font-size: 20px; color: var(--color-title); }
.cities__empty span { font-size: 15px; color: #4b5160; }
.cities.is-searching .cities__featured { display: none; }
.cities__cta { margin: 0; }
@media (max-width: 1100px) { .cities__hero { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 767px) {
    .cities { gap: 16px; }
    .cities__hero { padding: 28px 20px; gap: 24px; }
    .cities__featured, .cities__all { padding: 28px 20px; }
    .cities__lead { font-size: 16px; }
    .cities__h2 { font-size: 23px; }
    .cities__cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
    .city-card { padding: 14px 30px 14px 14px; }
    .city-card::after { right: 12px; }
    .city-card__name { font-size: 15px; }
    .cities__abc { top: 64px; gap: 2px; margin: 16px -4px 0; padding: 8px 4px; }
    .cities__abc a { width: 30px; height: 30px; font-size: 14px; }
    .cities__list ul { columns: 2; column-gap: 16px; }
    .cities__list h2 { font-size: 22px; }
}
@media (max-width: 374px) { .cities__cards { grid-template-columns: minmax(0, 1fr); } .cities__list ul { columns: 1; } .cities__abc a { width: 28px; } }
@media (max-width: 767px) { .cities__abc { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; } .cities__abc::-webkit-scrollbar { display: none; } .cities__abc a { flex: none; } .cities__list h2 { scroll-margin-top: 130px; } }

/* Claude 2026-10-22: футер без светлой полосы снизу; место под плавающую кнопку внутри тёмной карточки */
.site-footer{padding-bottom:0!important}
@media (max-width:1439px){.site-footer__bottom{padding-bottom:84px}}
@media (max-width:767px){.site-footer__bottom{padding-bottom:92px}}
