/* ============================================================
   ГОРНАЯ АВТОМАТИКА — вёрстка по макету Figma (Desktop A)
   ============================================================ */

:root {
  --red: #e22323;
  --red-deep: #de2521;
  --ink: #2d2e32;
  --grey: #626367;
  --muted: #9d9ea3;
  --bg: #f4f5fa;
  --line: #e7e8ed;
  --white: #ffffff;
  --orange: #ff8d31;
  --pink: #ffe3df;
  --radius: 16px;
  --shadow: 0 12px 30px rgba(45, 46, 50, .06);
  --font-main: "Inter", "Suisse Intl", "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Roboto Flex", "Inter", "Suisse Intl", "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-main);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, textarea { font: inherit; color: inherit; }

.container {
  width: min(1200px, 100% - 240px);
  margin-inline: auto;
}
@media (max-width: 1280px) {
  .container { width: min(1200px, 100% - 96px); }
}
@media (max-width: 760px) {
  .container { width: calc(100% - 40px); }
}

.icon { width: 24px; height: 24px; flex: none; }
.icon--sm { width: 16px; height: 16px; }
.icon--red { color: var(--red); }
.icon--grey { color: var(--grey); }

/* ---------- Утилиты ---------- */
.section-label {
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--red);
}
.section-title {
  margin-top: 10px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 32px;
  line-height: 1.2;
  color: var(--ink);
}
.section-title--center { text-align: center; }
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}
.section-head--with-nav { margin-bottom: 24px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  font-weight: 600;
  transition: background-color .2s, transform .15s, box-shadow .2s;
}
.btn--red { background: var(--red); color: #fff; }
.btn--red:hover { background: #c81d1d; }
.btn--lg { padding: 16px 32px; border-radius: 16px; font-size: 16px; }
.btn--block { width: 100%; padding: 15px 20px; font-size: 15px; border-radius: 8px; }

/* ============================================================
   TOP BAR
   ============================================================ */
.topbar {
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 43px;
}
.topbar__left, .topbar__right { display: flex; align-items: center; gap: 32px; }
.topbar__item { display: inline-flex; align-items: center; gap: 8px; color: var(--grey); white-space: nowrap; }
.topbar__item .icon { width: 16px; height: 16px; }
.topbar__item a { color: var(--grey); }
.topbar__item a:hover { color: var(--red); }
.topbar__item--phone { font-weight: 600; color: var(--ink); }
.topbar__item--phone a { color: var(--ink); }
.topbar__item--phone a:hover { color: var(--red); }
.topbar__item--grey .icon { color: var(--grey); }

/* ============================================================
   HEADER / NAVBAR
   ============================================================ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.header__inner {
  display: flex;
  align-items: center;
  gap: 40px;
  height: 85px;
}
.logo { flex: none; display: flex; align-items: center; }
.logo img { width: 191px; height: auto; }

.nav { margin-inline: auto; }
.nav__list { display: flex; align-items: center; gap: 32px; }
.nav__link {
  font-weight: 500;
  font-size: 15px;
  color: var(--ink);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color .2s, border-color .2s;
}
.nav__link:hover { color: var(--red); }
.nav__link.is-active { color: var(--red); border-bottom-color: var(--red); }

.header__actions { display: flex; align-items: center; gap: 12px; }
.header__cta { padding: 11px 20px; font-size: 14px; }
.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--red);
}
.icon-btn .icon { width: 22px; height: 22px; }
.header__burger { display: none; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: calc(100svh - 128px); /* первый экран за вычетом topbar (43) + header (85) */
  background: #1c1d22;
}
.hero__video,
.hero__overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.hero__video { object-fit: cover; }
.hero__overlay {
  background:
    linear-gradient(90deg, rgba(15, 16, 20, .82) 0%, rgba(15, 16, 20, .55) 42%, rgba(15, 16, 20, .28) 100%),
    linear-gradient(180deg, rgba(15, 16, 20, .28) 0%, rgba(15, 16, 20, 0) 20%, rgba(15, 16, 20, .18) 100%);
}
.hero > .container { position: relative; z-index: 1; }

/* Кнопка запуска видео, если автоплей заблокирован браузером */
.hero__play {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 160;
  display: none;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .55);
  background: rgba(226, 35, 35, .92);
  color: #fff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, .35);
  transition: background-color .2s, transform .15s;
}
.hero__play .icon { width: 26px; height: 26px; margin-left: 3px; }
.hero__play:hover { background: #c81d1d; transform: scale(1.06); }
.hero__play.is-shown { display: inline-flex; animation: heroPlayIn .25s ease; }
.hero__play[hidden] { display: none; }
@keyframes heroPlayIn {
  from { opacity: 0; transform: scale(.85); }
  to   { opacity: 1; transform: scale(1); }
}

.hero__top {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 0 32px;
}
.hero__content { max-width: 620px; }

.hero__badge {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  padding: 7px 15px;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 8px;
  background: rgba(255, 255, 255, .12);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #fff;
}

.hero__title {
  margin-top: 18px;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 44px;
  line-height: 1.14;
  letter-spacing: -.01em;
  color: #fff;
}

.hero__cta-row { margin-top: 28px; }

.hero__tags { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, .35);
  background: rgba(255, 255, 255, .14);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #fff;
  font-weight: 500;
  font-size: 15px;
}

/* ---------- Категории внизу hero ---------- */
.cats {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 22px;
  padding-bottom: 80px;
}
.cat-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 20px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 28px rgba(10, 11, 14, .22);
  transition: border-color .2s, transform .2s, box-shadow .2s;
}
.cat-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.cat-card--hot { border-color: var(--orange); border-width: 1.5px; }
.cat-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--red);
  color: #fff;
}
.cat-card__icon .icon { width: 18px; height: 18px; }
.cat-card--hot .cat-card__icon { background: var(--orange); }
.cat-card__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 20px;
  line-height: 1.2;
  color: var(--ink);
}

/* ============================================================
   BRANDS / SERVICES
   ============================================================ */
.brands { padding: 88px 0 80px; }
.brands .section-label { display: block; text-align: center; }
.brands .section-title { text-align: center; margin-top: 10px; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 208px);
  justify-content: center;
  gap: 32px;
  margin: 56px 0;
}
.stats__item { text-align: center; }
.stats__value {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 32px;
  line-height: 1.2;
  color: var(--red);
}
.stats__caption {
  display: block;
  margin-top: 4px;
  font-size: 16px;
  color: var(--grey);
}

.brands__row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 60px;
  align-items: center;
}
.brand-logo {
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
}
.brand-logo img {
  max-height: 74%;
  max-width: 78%;
  object-fit: contain;
  filter: grayscale(1);
  opacity: .85;
  transition: filter .2s, opacity .2s;
}
.brand-logo:hover img { filter: none; opacity: 1; }

/* ============================================================
   ENGINEERING / DISTRIBUTORS
   ============================================================ */
.engineering {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 80px 0 88px;
}
.eng-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 48px;
}
.eng-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px 40px 44px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.eng-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--red);
  color: #fff;
}
.eng-card__icon .icon { width: 28px; height: 28px; }
.eng-card__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 22px;
  color: var(--ink);
}
.eng-card__text {
  font-size: 14px;
  color: var(--grey);
  line-height: 1.55;
}

/* ============================================================
   PRODUCTS CAROUSEL
   ============================================================ */
.carousel-sec { padding: 88px 0; border-top: 1px solid var(--line); }
.carousel { position: relative; margin-top: 48px; }
.carousel__viewport { overflow: hidden; }
.carousel__track {
  display: flex;
  transition: transform .45s ease;
}
.carousel__slide { flex: 0 0 100%; }
.carousel__card {
  display: grid;
  grid-template-columns: 1fr 1.7fr;
  align-items: center;
  gap: 48px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 32px;
  padding: 48px 72px;
}
.carousel__media img {
  width: 100%;
  height: auto;
  border-radius: 16px;
}
.carousel__dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}
.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line);
  padding: 0;
  transition: background .2s;
}
.dot.is-active { background: var(--red); }
.carousel__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 32px;
  color: var(--ink);
}
.carousel__desc { margin-top: 12px; font-size: 16px; color: var(--grey); }
.carousel__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, .9);
  transition: background .2s, transform .15s;
}
.carousel__arrow:hover { background: #c81d1d; }
.carousel__arrow--prev { left: 0; }
.carousel__arrow--next { right: 0; }
.carousel__arrow .icon { width: 22px; height: 22px; }


/* ============================================================
   INFO LINKS (О заводе / Дополнительно)
   ============================================================ */
.links-sec {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 88px 0;
}
.links-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 48px;
}
.link-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 32px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: box-shadow .2s, transform .2s;
}
.link-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.link-card__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 20px;
  color: var(--ink);
}
.link-card__text { font-size: 13px; line-height: 1.55; color: var(--grey); }
.link-card__more {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 14px;
  color: var(--red);
}
.link-card__more .icon { width: 15px; height: 15px; }

/* ============================================================
   PROMOTIONS
   ============================================================ */
.promo { padding: 88px 0; border-top: 1px solid var(--line); }
.promo__nav { display: flex; gap: 12px; padding-bottom: 14px; }
.nav-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  transition: background .2s, color .2s, border-color .2s;
}
.nav-arrow:hover { background: var(--red); border-color: var(--red); color: #fff; }
.nav-arrow .icon { width: 20px; height: 20px; }

.promo__grid {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}
.promo__grid::-webkit-scrollbar { display: none; }
.promo-card {
  flex: 0 0 calc((100% - 48px) / 3);
  scroll-snap-align: start;
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: box-shadow .2s, transform .2s;
}
.promo-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.promo-card__media { position: relative; }
.promo-card__media img { width: 100%; height: 240px; object-fit: cover; }
.promo-card__badge {
  position: absolute;
  top: 16px;
  left: 16px;
  padding: 4px 10px;
  border-radius: 4px;
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.promo-card__body { padding: 24px; }
.promo-card__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.25;
  color: var(--ink);
}
.promo-card__text {
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--grey);
}
.promo-card__price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 20px;
}
.price { font-family: var(--font-head); line-height: 1.2; }
.price--old { font-weight: 400; font-size: 14px; color: var(--muted); text-decoration: line-through; }
.price--new { font-weight: 700; font-size: 20px; color: var(--red); }

/* ============================================================
   ABOUT
   ============================================================ */
.about {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 88px 0;
}
.about__grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 80px;
  align-items: center;
}
.about__title {
  margin-top: 14px;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 36px;
  line-height: 1.2;
  color: var(--ink);
}
.about__text {
  margin-top: 24px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--grey);
}
.about__stats {
  display: flex;
  gap: 32px;
  margin-top: 44px;
}
.about-stat__value {
  display: block;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 40px;
  line-height: 1.1;
  color: var(--red);
}
.about-stat__label {
  display: block;
  margin-top: 8px;
  font-weight: 600;
  font-size: 14px;
  color: var(--ink);
}
.about__media img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* ============================================================
   CTA / INQUIRY
   ============================================================ */
.inquiry { padding: 88px 0; border-top: 1px solid var(--line); }
.inquiry__grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 80px;
  align-items: start;
}
.inquiry__title {
  margin-top: 14px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 32px;
  line-height: 1.25;
  color: var(--ink);
}
.inquiry__text {
  margin-top: 22px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--grey);
}

.form {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.form__field { display: flex; flex-direction: column; gap: 8px; }
.form__label {
  font-size: 12px;
  font-weight: 600;
  color: var(--grey);
}
.form__input {
  width: 100%;
  padding: 13px 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  color: var(--ink);
  outline: none;
  transition: border-color .2s, background .2s;
}
.form__input:focus { border-color: var(--red); background: #fff; }
.form__textarea { resize: vertical; min-height: 96px; }
.form__input.is-invalid { border-color: var(--red); }
.form__note { font-size: 11px; color: var(--grey); }
.form.error .form__input { border-color: var(--red); }


/* ============================================================
   FOOTER
   ============================================================ */
.footer { background: var(--white); border-top: 1px solid var(--line); }
.footer__main {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 60px;
  padding: 64px 0 48px;
}
.footer__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 20px;
}
.footer__list { display: flex; flex-direction: column; gap: 14px; }
.footer__list a { font-size: 14px; color: var(--grey); transition: color .2s; }
.footer__list a:hover { color: var(--red); }
.footer__list--contacts li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--grey);
}
.footer__list--contacts a { font-size: 14px; color: var(--ink); font-weight: 600; }
.footer__list--contacts a:hover { color: var(--red); }
.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}
.footer__copy { font-size: 13px; color: var(--muted); }
.footer__socials { display: flex; gap: 12px; }
.footer__socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  color: var(--grey);
  transition: color .2s, background .2s;
}
.footer__socials .icon { width: 20px; height: 20px; }
.footer__socials a:hover { color: var(--red); }

/* ============================================================
   MOBILE NAV (бургер-меню)
   ============================================================ */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--white);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transform: translateX(100%);
  transition: transform .3s ease;
  overflow-y: auto;
}
.mobile-nav.is-open { transform: none; }
.mobile-nav__head { display: flex; align-items: center; justify-content: space-between; }
.mobile-nav__list { display: flex; flex-direction: column; gap: 8px; }
.mobile-nav__list a {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 24px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.mobile-nav__cta { margin-top: auto; }
body.no-scroll { overflow: hidden; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1200px) {
  .cats { grid-template-columns: repeat(3, 1fr); }
  .cat-card:nth-child(4), .cat-card:nth-child(5) { display: none; }
  .brands__row { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .eng-grid, .links-grid { grid-template-columns: repeat(2, 1fr); }
  .promo-card { flex-basis: calc((100% - 24px) / 2); }
  .footer__main { grid-template-columns: 1fr 1fr; }
  .footer__col:last-child { grid-column: 1 / -1; }
}

@media (max-width: 992px) {
  .nav { display: none; }
  .header__burger { display: flex; }
  .header__cta { display: none; }
  .hero__top { padding-top: 48px; }
  .hero__title { font-size: 36px; }
  .inquiry__grid, .about__grid { grid-template-columns: 1fr; gap: 48px; }
  .carousel__card { grid-template-columns: 1fr; padding: 32px; }
}

@media (max-width: 720px) {
  .topbar__item span, .topbar__item a { display: none; }
  .topbar__inner { justify-content: flex-start; }
  .topbar__right { margin-left: auto; }
  .topbar__left .topbar__item:nth-child(2) { display: none; }
  .stats { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .stats__value { font-size: 26px; }
  .stats__caption { font-size: 13px; }
  .brands__row { grid-template-columns: repeat(2, 1fr); }
  .cats { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .eng-grid, .links-grid { grid-template-columns: 1fr; }
  .promo-card { flex-basis: 100%; }
  .carousel__arrow { width: 44px; height: 44px; }
  .carousel__card { gap: 24px; }
  .footer__main { grid-template-columns: 1fr; gap: 36px; }
  .footer__bottom { flex-direction: column; align-items: flex-start; }
  .hero__title { font-size: 30px; }
  .section-title { font-size: 26px; }
  .about__title { font-size: 28px; }
  .about__stats { flex-wrap: wrap; gap: 24px; }
  .about-stat__value { font-size: 32px; }
}

