/* ===========================================================
   ARSENAL MET — app.css
   Доп. слой темы поверх вёрстки: модалка, FAQ-панель,
   состояния форм, служебное. style.css не трогаем.
   =========================================================== */

/* -------- FAQ answer panel -------- */
.faq__answer {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.35s ease;
}
.faq__answer-inner {
  padding: 4px 0 22px;
  color: var(--color-text, #111);
  line-height: 1.6;
  max-width: 70ch;
}
.faq__answer-inner p {
  margin: 0 0 10px;
}
.faq__answer-inner p:last-child {
  margin-bottom: 0;
}
.faq__icon-v {
  transform-origin: center;
  transition: transform 0.3s ease;
}
.faq__item--open .faq__icon-v {
  transform: scaleX(0);
}
.faq__toggle {
  cursor: pointer;
}

/* -------- Form result -------- */
.am-form__result {
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 1.5;
}
.am-form__result[data-state="success"] {
  color: #1a7f37;
}
.am-form__result[data-state="error"] {
  color: var(--color-red, #d81f26);
}

/* -------- Modal -------- */
.am-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.am-modal.is-open {
  display: flex;
}
.am-modal__overlay {
  position: absolute;
  inset: 0;
  background: var(--color-overlay-dark, rgba(0, 0, 0, 0.55));
  backdrop-filter: blur(2px);
}
.am-modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--color-white, #fff);
  border-radius: var(--radius-lg, 18px);
  box-shadow: var(--shadow-form, 0 10px 40px rgba(0, 0, 0, 0.25));
  padding: clamp(24px, 4vw, 44px);
  animation: am-modal-in 0.25s ease;
}
@keyframes am-modal-in {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.am-modal__close {
  position: absolute;
  top: 12px;
  right: 16px;
  width: 40px;
  height: 40px;
  border: 0;
  background: transparent;
  font-size: 30px;
  line-height: 1;
  color: var(--color-black, #111);
  cursor: pointer;
  border-radius: var(--radius-sm, 4px);
  transition: color var(--transition, 0.3s ease);
}
.am-modal__close:hover {
  color: var(--color-red, #d81f26);
}
.am-modal .callback-form {
  box-shadow: none;
  padding: 0;
}
body.is-locked {
  overflow: hidden;
}

/* -------- Admin notice (пустое меню и т.п.) -------- */
.am-admin-notice {
  padding: 8px 12px;
  background: #fff3cd;
  border: 1px solid #ffe69c;
  border-radius: 4px;
  color: #664d03;
  font-size: 13px;
}

/* -------- Page content (privacy и пр.) -------- */
.page-content {
  padding: var(--section-py, 60px) 0;
}
.page-content .entry-content {
  max-width: 80ch;
  line-height: 1.7;
}
.page-content .entry-content p {
  margin: 0 0 1em;
}

/* ===========================================================
   АДАПТИВ — слой исправлений поверх вёрстки (style.css не трогаем).
   Вёрстка ломалась на планшете/мобайле: у карточек услуг номер
   позиционировался absolute и наезжал на заголовок, тёмные
   декоративные медиа превращались в чёрные «простыни».
   =========================================================== */

/* -------- Карточки услуг (главная + /priem/): в вёрстке номер и
   текст позиционированы absolute, а высота карточки привязана к
   ширине (aspect-ratio). На узких/средних экранах текст-блок
   разрастался и наезжал на номер.
   Переводим карточку во flex-поток: номер сверху, текст прижат к
   низу (margin-top:auto — читаемо на тёмном градиенте), а `gap`
   гарантирует зазор между номером и текстом, даже когда контент
   занимает всю высоту. Flex-элементы не накладываются физически —
   наезд невозможен ни на какой ширине.
   Страницу /services/ (.service-card--lg) НЕ трогаем. */
@media (max-width: 1024px) {
  .services__grid .service-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    height: auto;
    min-height: 240px;
    aspect-ratio: auto;
    padding: 20px;
  }
  .services__grid .service-card__num {
    position: static;
    inset: auto;
    font-size: 50px;
    line-height: 0.9;
    opacity: 0.92;
  }
  .services__grid .service-card__body {
    position: static;
    inset: auto;
    margin-top: auto;
    padding: 0;
  }
  .services__grid .service-card__title {
    font-size: 21px;
  }
  .services__grid .service-card__text {
    margin-top: 8px;
  }
}

@media (max-width: 480px) {
  .services__grid .service-card {
    min-height: 210px;
    padding: 18px;
  }
  .services__grid .service-card__num {
    font-size: 46px;
  }
  .services__grid .service-card__title {
    font-size: 20px;
  }
}

/* -------- Priem hero: в вёрстке на ≤1023 у hero сбрасывается
   верхний отступ (padding-top: 30px / 20px), хотя шапка —
   position:absolute высотой ~90px. Заголовок залезал под шапку и
   наезжал на телефон. Возвращаем клиренс под абсолютную шапку. */
@media (max-width: 1023px) {
  .priem-hero {
    padding-top: calc(var(--header-height, 90px) + 24px);
  }
}

/* -------- Footer: сетка в вёрстке оставалась 4-колоночной вплоть
   до мобайла → на узком десктопе колонка с кнопкой «Заказать
   звонок» выезжала за край. Складываем в 2 колонки заранее. */
@media (max-width: 1100px) {
  .footer__container {
    grid-template-columns: 1fr 1fr;
    gap: 32px 40px;
  }
  .footer__col {
    min-width: 0;
  }
  .footer__col--cta {
    align-items: flex-start;
  }
}
@media (max-width: 560px) {
  .footer__container {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

/* -------- Stats: декоративное фото на планшете/мобайле уходило
   во всю ширину тёмной простынёй (а сейчас картинка ещё и битая).
   Прячем его и убираем зарезервированный третий ряд сетки —
   остаются ровные 2×2 карточки без чёрного провала. */
@media (max-width: 1024px) {
  .stats__photo {
    display: none;
  }
  .stats__grid {
    grid-template-rows: auto auto;
  }
}

/* -------- About hero: тёмное фото-медиа делаем компактной
   полосой на мобайле, чтобы не было чёрного провала под hero. */
@media (max-width: 768px) {
  .about-hero__media {
    height: 220px;
    min-height: 0;
  }
  .about-hero__img {
    height: 100%;
    object-fit: cover;
  }
}

/* ===========================================================
   Корректировки клиента (июль 2026) — сверка с Figma
   =========================================================== */

/* -------- Шрифты: Bebas Neue (заголовки) + Onest (текст),
   вместо системного стека с Impact -------- */
:root {
  --font-heading:
    "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --font-body:
    "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --font-condensed:
    "Bebas Neue", "Arial Narrow Bold", "Roboto Condensed", sans-serif;
}
.section-title {
  line-height: 1.05;
  letter-spacing: 0.5px;
}

/* -------- Услуги на главной: 5 карточек в один ряд (Figma).
   Заодно лечит вёрсточный баг: правило grid-column + max-width +
   margin-inline:auto схлопывало 5-ю карточку в ширину 0. -------- */
@media (min-width: 1280px) {
  .services__grid {
    grid-template-columns: repeat(5, 1fr);
  }
}
.services__grid .service-card--5 {
  grid-column: auto;
  max-width: none;
  margin-inline: 0;
  justify-self: stretch;
}
/* Карточки квадратные (Figma). Номер и текст — во flex-потоке
   (номер сверху, текст прижат к низу): физически не накладываются
   ни на какой ширине, квадрат держит aspect-ratio. */
.services__grid .service-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: auto;
  min-height: 0;
  aspect-ratio: 1 / 1;
  padding: 16px;
}
.services__grid .service-card__num {
  position: static;
  inset: auto;
  font-size: 64px;
  font-weight: 400;
  line-height: 0.9;
}
.services__grid .service-card__body {
  position: static;
  inset: auto;
  margin-top: auto;
  padding: 0;
}
.services__grid .service-card__title {
  font-size: 19px;
  line-height: 1.05;
}
.services__grid .service-card__text {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.35;
}

/* -------- Преимущества: залитые иконки чуть крупнее -------- */
.advantage-card__icon svg {
  width: 24px;
  height: 24px;
}

/* -------- FAQ: ответы тем же шрифтом и размером, что и вопрос -------- */
.faq__answer-inner {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.6;
  color: #444;
}

/* -------- About «Выбирая Арсеналмет»: фон менее затемнённый (Figma) -------- */
.choose__hero-bg {
  filter: grayscale(100%) brightness(0.55) contrast(1.05);
}
.choose__hero::before {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.35) 0%,
    rgba(0, 0, 0, 0.55) 100%
  );
}

/* -------- Контакты: воздух между строками карточек (Figma) -------- */
.contact-card__value {
  margin-bottom: 8px;
}
.contact-card__note {
  margin: -4px 0 12px;
}
.contact-card__sub {
  margin: 10px 0 2px;
  font-size: 15px;
  font-weight: 500;
  opacity: 0.95;
}
/* Фирменные цвета значков мессенджеров */
.contact-card__social-link--bip {
  background: #00a5eb;
  color: #ffffff;
}
.contact-card__social-link--telegram {
  background: #229ed9;
  color: #ffffff;
}
.contact-card__social-link--whatsapp {
  background: #25d366;
  color: #ffffff;
}

/* -------- Футер: нижняя плашка — лицензия / реквизиты / политика -------- */
.footer__legal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.footer__legal-row .footer__legal-text {
  text-align: center;
  flex: 1 1 auto;
}
.footer__legal-license {
  margin: 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
}
.footer__legal-row .footer__policy {
  margin: 0;
}

/* -------- Мобильное меню: пункты белым, активный — красным
   (брейкпоинт бургера в вёрстке — 1024px) -------- */
@media (max-width: 1024px) {
  .header__nav .nav__link,
  .header--light .header__nav .nav__link {
    color: #ffffff;
  }
  .header__nav .nav__item.current-menu-item > .nav__link,
  .header__nav .nav__link[aria-current="page"],
  .header--light .header__nav .nav__item.current-menu-item > .nav__link,
  .header--light .header__nav .nav__link[aria-current="page"] {
    color: var(--color-red, #d81f26);
  }
  /* Крестик закрытия поверх тёмного оверлея — белый */
  .burger[aria-expanded="true"] .burger__line,
  .header--light .burger[aria-expanded="true"] .burger__line {
    background: #ffffff;
  }
  .burger[aria-expanded="true"] {
    position: relative;
    z-index: 21;
  }
}

/* -------- Хардкоды font-family в вёрстке мимо переменных:
   Oswald/'Bebas Neue' → Bebas Neue, Montserrat/Roboto → Onest -------- */
.process__title,
.licenses__title,
.process-card__num,
.process-card__title,
.callback-form__title {
  font-family: var(--font-condensed);
}
.process-card__text,
.callback-form__title-line--accent,
.callback-form__subtitle,
.features-list__title,
.features-list__text,
.page--services .service-card--lg .service-card__text,
.page--services .callback-form__title-line--accent,
.page--services .callback-form__subtitle,
.page--services .callback-form__input,
.footer__legal-text,
.contact-card__title,
.contact-card__value,
.contact-card__note,
.contact-card__sub,
.page--contacts .callback-form__title-line--accent,
.page--contacts .callback-form__subtitle,
.page--contacts .callback-form__input {
  font-family: var(--font-body);
}

/* -------- Блок «Выбирая Арсеналмет» — по фигме: иконка над текстом -------- */
.choose__item {
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
}
.choose__text {
  align-self: auto;
}
.choose__icon svg {
  width: 26px;
  height: 26px;
}

/* -------- Контакты: адреса в карточках мельче (фигма) -------- */
p.contact-card__value:not(.contact-card__value--bold) {
  font-size: 16px;
  line-height: 1.5;
}

/* -------- Номера карточек услуг: Bebas Neue Light 200 (фигма) -------- */
.service-card__num,
.page--services .service-card--lg .service-card__num {
  font-family: var(--font-condensed);
  font-weight: 200;
}

/* -------- Футер по фигме: телефон/почта Bebas, плотный интерлиньяж -------- */
.footer__text {
  line-height: 1.5;
}
.footer__phone {
  font-family: var(--font-condensed);
  font-weight: 400;
  font-size: 30px;
  letter-spacing: 1px;
}
.footer__email {
  font-family: var(--font-condensed);
  font-weight: 400;
  font-size: 22px;
  letter-spacing: 1px;
}
.footer__address {
  line-height: 1.6;
}
.footer__col--offices .footer__btn {
  margin-top: 10px;
  align-self: flex-start;
}

/* -------- Swiper process/licenses: вёрстка задаёт wrapper'у display:grid,
   это ломает swiper-wrapper — лишние слайды уходят во вторую строку грида
   и слайдер не листается. Отступы между слайдами делает Swiper (spaceBetween). -------- */
.process__slider .process__cards,
.licenses__slider .licenses__list,
.page--services .process__slider .process__cards {
  display: flex;
  gap: 0;
}

/* Swiper задаёт слайдам height:100%; auto + stretch — карточки одной высоты */
.process__slider .swiper-slide,
.licenses__slider .swiper-slide {
  height: auto;
}

/* -------- Лицензии: единый размер карточек (портрет А4), рамка,
   документ целиком через object-fit -------- */
.license-card {
  aspect-ratio: 3 / 4;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  padding: 12px;
}
.license-card__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* -------- Услуги: карточки заполняют колонку, почти квадрат (фигма) -------- */
.page--services .services-page__grid {
  gap: 40px;
}
.page--services .service-card--lg {
  width: 100%;
  height: auto;
  aspect-ratio: 340 / 365;
  min-height: 0;
}

/* ===========================================================
   Правки по клиентским DOCX
   =========================================================== */

.hero__title {
  font-family: var(--font-condensed);
  font-size: clamp(42px, 4.4vw, 68px);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: 0.3px;
}

.about-hero__subtitle {
  margin-top: 22px;
  line-height: 1.15;
}

.service-card {
  color: var(--color-white);
  text-decoration: none;
}

.service-card:focus-visible {
  outline: 3px solid var(--color-red);
  outline-offset: 3px;
}

.menu-item-has-children:focus-within > .sub-menu {
  display: block;
}

.sub-menu {
  z-index: 30;
}

.prices__list--second {
  margin-top: 55px;
}

.prices__note {
  margin: -18px 0 22px;
  color: #666;
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
}

.priem-copy,
.about-copy {
  padding-block: 60px;
  background: #fff;
}

.priem-copy__container,
.about-copy__container {
  max-width: 1040px;
}

.priem-copy__content,
.about-copy__container,
.page-content .entry-content {
  font-size: 16px;
  line-height: 1.75;
  color: #333;
}

.priem-copy__content h2,
.about-copy__container h2,
.page-content .entry-content h2 {
  margin: 1.5em 0 0.65em;
  font-family: var(--font-condensed);
  font-size: clamp(30px, 3vw, 44px);
  line-height: 1.05;
  text-transform: uppercase;
  color: #2f2f2f;
}

.priem-copy__content h2:first-child,
.about-copy__container h2:first-child,
.page-content .entry-content h2:first-child {
  margin-top: 0;
}

.priem-copy__content p,
.about-copy__container p,
.page-content .entry-content p {
  margin: 0 0 1em;
}

.priem-copy__content ul,
.priem-copy__content ol,
.about-copy__container ul,
.about-copy__container ol,
.page-content .entry-content ul,
.page-content .entry-content ol {
  margin: 0 0 1.25em;
  padding-left: 1.4em;
}

.priem-copy__content li + li,
.about-copy__container li + li,
.page-content .entry-content li + li {
  margin-top: 0.45em;
}

.priem-copy__images {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 36px;
}

.priem-copy__media {
  aspect-ratio: 16 / 10;
  margin: 0;
  overflow: hidden;
  border-radius: 18px;
  background: #eee;
}

.priem-copy__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.choose--hero-only {
  padding-bottom: 20px;
}

.choose-cards {
  padding-block: 20px 70px;
  background: #fff;
}

.choose-cards__container {
  max-width: calc(var(--container-width) + var(--container-padding) * 2);
}

.subpages {
  padding-top: 30px;
}

.subpages__grid .service-card {
  min-width: 0;
}

.reviews {
  padding-block: 80px;
  background: #f5f5f5;
}

.reviews__container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.9fr);
  align-items: center;
  gap: 60px;
}

.reviews__title {
  margin: 0 0 24px;
  font-family: var(--font-condensed);
  font-size: clamp(38px, 4vw, 56px);
  line-height: 1;
  text-transform: uppercase;
  color: #2f2f2f;
}

.reviews__text {
  max-width: 62ch;
  color: #555;
  font-size: 15px;
  line-height: 1.65;
}

.reviews__text p {
  margin: 0 0 12px;
}

.reviews__ratings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}

.rating-card {
  padding: 18px;
  border-radius: 12px;
  background: #fff;
}

.rating-card__title {
  margin: 0 0 10px;
  color: #555;
  font-size: 14px;
}

.rating-card__body {
  display: flex;
  align-items: center;
  gap: 14px;
}

.rating-card__value {
  font-family: var(--font-condensed);
  font-size: 42px;
  line-height: 1;
  color: #222;
}

.rating-card__stars {
  display: block;
  color: var(--color-red);
  font-size: 15px;
  letter-spacing: 2px;
}

.rating-card__count {
  display: block;
  margin-top: 4px;
  color: #777;
  font-size: 12px;
}

.reviews__slider {
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.reviews__slides {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
}

.reviews__slide {
  height: auto;
}

.reviews__image {
  width: 100%;
  height: 480px;
  object-fit: contain;
  object-position: center;
}

.reviews__nav {
  position: relative;
  z-index: 2;
}

.page-content {
  padding-top: calc(var(--header-height, 90px) + 60px);
}

.page-content .section-title {
  margin-bottom: 32px;
}

/* Компактная шапка на обычном масштабе браузера. */
@media (min-width: 1025px) and (max-width: 1400px) {
  .header__container {
    grid-template-columns: auto minmax(0, 1fr) auto auto auto;
    column-gap: 12px;
  }

  .header__logo .logo__text {
    display: none;
  }

  .logo__img {
    width: 52px;
    height: 52px;
  }

  .nav__list {
    justify-content: flex-start;
    gap: 16px;
  }

  .nav__link {
    font-size: 13px;
  }

  .socials {
    gap: 10px;
  }

  .header__btn {
    padding-inline: 14px;
    font-size: 12px;
  }

  .phone__number {
    font-size: 18px;
  }
}

@media (min-width: 1025px) and (max-height: 850px) {
  .hero__container {
    padding-block: 20px;
  }

  .hero__form .form {
    padding: 22px;
  }

  .hero__form .form__title {
    font-size: 24px;
  }

  .hero__form .form__divider {
    margin-block: 14px;
  }

  .hero__form .form__fields {
    gap: 8px;
  }

  .hero__form .form__input {
    height: 42px;
  }

  .hero__form .form__submit {
    margin-top: 16px;
  }
}

/* На 901–1024px сохраняем десктопную композицию, которую клиент
   видел при масштабе 90%, но без CSS zoom. */
@media (min-width: 901px) and (max-width: 1024px) {
  .header__container {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    column-gap: 8px;
    padding-inline: 16px;
  }

  .header__logo .logo__text,
  .header__socials {
    display: none;
  }

  .logo__img {
    width: 48px;
    height: 48px;
  }

  .header__nav {
    position: static;
    inset: auto;
    z-index: auto;
    display: block;
    padding: 0;
    overflow: visible;
    background: transparent;
  }

  .nav__list {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 11px;
  }

  .nav__link {
    display: inline-flex;
    padding: 8px 0;
    border: 0;
    color: #fff;
    font-size: 12px;
    font-weight: 400;
  }

  .header--light .header__nav .nav__link {
    color: #222;
  }

  .sub-menu {
    position: absolute;
    display: none;
    padding: 10px 0;
    background: #fff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  }

  .menu-item-has-children:hover > .sub-menu,
  .menu-item-has-children:focus-within > .sub-menu {
    display: block;
  }

  .sub-menu .nav__link,
  .header--light .sub-menu .nav__link {
    display: block;
    padding: 8px 16px;
    color: #222;
    font-size: 13px;
  }

  .header__btn {
    display: inline-flex;
    height: 38px;
    padding-inline: 11px;
    font-size: 11px;
  }

  .header__phone {
    display: flex;
  }

  .phone__number {
    font-size: 16px;
  }

  .phone__hours {
    font-size: 10px;
  }

  .header__burger {
    display: none;
  }

  .hero__container {
    flex-direction: row;
    align-items: center;
    gap: 24px;
    padding-block: 20px;
  }

  .hero__content {
    flex: 1 1 auto;
    width: auto;
    max-width: none;
  }

  .hero__form {
    flex: 0 0 330px;
    width: 330px;
    max-width: 330px;
  }

  .hero__title {
    font-size: 48px;
  }

  .hero__subtitle {
    margin-top: 20px;
    font-size: 16px;
  }

  .hero__actions {
    margin-top: 24px;
  }

  .form {
    max-width: 330px;
    padding: 20px;
  }

  .form__title {
    font-size: 23px;
  }

  .form__divider {
    margin-block: 14px;
  }

  .form__fields {
    gap: 8px;
  }

  .form__input {
    height: 42px;
  }

  .priem-hero__container {
    grid-template-columns: minmax(0, 1fr) 400px;
    gap: 24px;
  }

  .priem-hero__title {
    margin-bottom: 28px;
    font-size: 46px;
  }

  .priem-hero__media {
    width: 400px;
    height: 286px;
  }

  .features-list {
    row-gap: 18px;
    margin-bottom: 28px;
  }

  .features-list__title,
  .features-list__text {
    font-size: 14px;
  }

  .about-hero {
    min-height: 650px;
    padding-bottom: 50px;
  }

  .about-hero__container {
    flex-direction: row;
    align-items: center;
    gap: 24px;
    margin-top: 30px;
    min-height: 500px;
  }

  .about-hero__content {
    flex: 1 1 auto;
    width: auto;
    max-width: none;
  }

  .about-hero__title {
    font-size: 54px;
  }

  .about-hero__media {
    flex: 0 0 410px;
    width: 410px;
    height: 320px;
  }
}

@media (max-width: 900px) {
  .hero__title {
    font-size: clamp(38px, 9vw, 58px);
  }

  .reviews__container {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .reviews__image {
    height: 420px;
  }
}

@media (max-width: 640px) {
  .priem-copy,
  .about-copy,
  .reviews {
    padding-block: 45px;
  }

  .priem-copy__images,
  .reviews__ratings {
    grid-template-columns: 1fr;
  }

  .choose-cards {
    padding-bottom: 50px;
  }

  .reviews__image {
    height: 380px;
  }
}

/* Четыре уровня: раздел → тип лома → металл → разновидность. */
.sub-menu .nav__link--has-arrow,
.header--light .sub-menu .nav__link--has-arrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav__arrow--side {
  flex: 0 0 auto;
  transform: rotate(-90deg);
}

.nav__submenu-toggle {
  display: none;
}

@media (min-width: 901px) {
  .sub-menu .menu-item-has-children {
    position: relative;
  }

  .sub-menu .sub-menu {
    top: -10px;
    left: calc(100% + 4px);
    min-width: 250px;
  }
}

@media (min-width: 901px) and (max-width: 1024px) {
  .nav__submenu--level-4 {
    width: 250px;
  }

  .nav__submenu--level-4 .nav__link {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

@media (max-width: 900px) {
  .header__nav .menu-item-has-children {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 44px;
    width: 100%;
  }

  .header__nav .menu-item-has-children > .nav__link {
    grid-column: 1;
    grid-row: 1;
  }

  .header__nav .nav__submenu-toggle {
    display: flex;
    grid-column: 2;
    grid-row: 1;
    align-items: center;
    justify-content: center;
    width: 44px;
    padding: 0;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: transparent;
    color: var(--color-text-muted);
    cursor: pointer;
  }

  .header__nav .nav__submenu-toggle-icon {
    transition: transform 0.2s ease;
    transform: rotate(-90deg);
  }

  .header__nav
    .nav__submenu-toggle[aria-expanded="true"]
    .nav__submenu-toggle-icon {
    transform: rotate(0);
  }

  .header__nav .menu-item-has-children > .sub-menu {
    display: none;
    grid-column: 1 / -1;
  }

  .header__nav .menu-item-has-children.is-submenu-open > .sub-menu {
    display: block;
  }

  .sub-menu .sub-menu {
    padding-left: 18px;
  }

  .header__nav .nav__arrow {
    display: none;
  }

  .header__nav .nav__list,
  .header__nav .nav__link {
    white-space: normal;
  }

  .header__nav .nav__item {
    max-width: 100%;
  }

  .header__nav .nav__link {
    line-height: 1.3;
    overflow-wrap: anywhere;
  }
}
