:root {
  --red: #e1212a;
  --red-dark: #c81922;
  --text: #1f2430;
  --muted: #6e7580;
  --line: #e7e9ee;
  --soft: #f5f6f8;
  --dark: #262b33;
  --footer: #2b313a;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  background: #fff;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
}

.container {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  background: var(--red);
  color: #fff;
  font-size: 14px;
}

.topbar__inner,
.header-main,
.quick-menu,
.breadcrumbs,
.page-head,
.catalog-toolbar,
.hero__actions,
.hero__facts {
  display: flex;
  align-items: center;
}

.topbar__inner {
  min-height: 42px;
  gap: 28px;
}

.topbar__nav {
  display: flex;
  gap: 22px;
  flex: 1;
}

.topbar__contact,
.header-main__contact,
.footer__contact,
.lead__contact {
  font-weight: 700;
}

.link-button {
  border: 0;
  padding: 0 0 0 18px;
  color: #fff;
  background: transparent;
  cursor: pointer;
  position: relative;
}

.link-button::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
  transform: translateY(-50%);
}

.header-main {
  min-height: 92px;
  gap: 24px;
}

.logo {
  width: 176px;
  flex: 0 0 auto;
}

.header-main__contact {
  display: none;
  color: var(--red);
}

.search {
  display: flex;
  flex: 1;
  min-width: 260px;
}

.catalog-button,
.button {
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 700;
}

.catalog-button {
  min-width: 128px;
  min-height: 48px;
  color: #fff;
  background: var(--red);
}

.search__form {
  display: flex;
  flex: 1;
  border: 1px solid var(--line);
  border-left: 0;
  border-radius: 0 6px 6px 0;
  overflow: hidden;
}

.search__form input {
  width: 100%;
  border: 0;
  padding: 0 16px;
  outline: 0;
}

.search__form button {
  border: 0;
  padding: 0 18px;
  color: var(--red);
  background: #fff;
  cursor: pointer;
}

.header-actions {
  display: flex;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.quick-menu {
  min-height: 48px;
  gap: 24px;
  border-top: 1px solid var(--line);
  color: #414751;
  font-size: 15px;
  overflow-x: auto;
}

.breadcrumbs {
  gap: 10px;
  padding: 24px 0 12px;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
  overflow-x: auto;
}

.breadcrumbs span::after {
  content: "/";
  margin-left: 10px;
  color: #b9bec7;
}

.page-head {
  justify-content: space-between;
  gap: 24px;
  padding: 8px 0 30px;
}

h1 {
  margin: 0;
  font-size: 40px;
  line-height: 1.1;
}

.page-head p,
.hero__copy p,
.landing-info p,
.seo p,
.lead p,
.footer p,
.legal p,
.addresses p {
  line-height: 1.55;
}

.page-head p {
  margin: 12px 0 0;
  color: var(--muted);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  white-space: nowrap;
}

.button_red {
  color: #fff;
  background: var(--red);
}

.button_red:hover {
  background: var(--red-dark);
}

.button_light {
  color: var(--text);
  background: #fff;
}

.button_border {
  border: 1px solid var(--line);
  color: var(--text);
  background: #fff;
}

.hero {
  background: linear-gradient(180deg, #f8f9fb 0%, #eef1f5 100%);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 40px;
  align-items: center;
  min-height: 430px;
  padding: 34px 0;
}

.hero__eyebrow {
  color: var(--red);
  font-weight: 700;
  margin-bottom: 14px;
}

.hero h2,
.lead h2,
.seo h2,
.related h2,
.landing-info h2,
.footer h2,
.legal h2,
.addresses h2 {
  margin: 0;
  line-height: 1.15;
}

.hero h2 {
  max-width: 640px;
  font-size: 42px;
}

.hero__copy p {
  max-width: 620px;
  color: #4b535f;
  font-size: 18px;
}

.hero__actions {
  gap: 12px;
  margin-top: 24px;
}

.hero__facts {
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.hero__facts span {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 14px;
  background: #fff;
  font-weight: 700;
}

.hero__image {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 18px 40px rgba(31, 36, 48, 0.08);
}

.hero__image img {
  width: 100%;
  max-height: 340px;
  object-fit: contain;
}

.catalog-section {
  background: var(--soft);
  padding: 34px 0 46px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
}

.filter {
  align-self: start;
  position: sticky;
  top: 16px;
}

.filter__title {
  display: none;
}

.filter__block {
  margin-bottom: 16px;
  border-radius: 8px;
  padding: 22px;
  background: #fff;
  border: 1px solid var(--line);
}

.filter h2 {
  margin: 0 0 16px;
  font-size: 18px;
}

.filter a,
.filter label,
.footer a {
  display: block;
}

.filter a {
  padding: 8px 0;
  color: #4b535f;
}

.filter .is-current {
  color: var(--red);
  font-weight: 700;
}

.filter label {
  margin: 12px 0;
  color: #4b535f;
}

.catalog-toolbar {
  justify-content: space-between;
  margin-bottom: 20px;
}

.catalog-toolbar select {
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 14px;
  background: #fff;
}

.view-icons {
  display: flex;
  gap: 8px;
}

.view-icons span {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 420px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}

.product-card__image {
  display: grid;
  place-items: center;
  height: 180px;
  margin-bottom: 18px;
}

.product-card__image img {
  max-height: 170px;
  object-fit: contain;
}

.product-card h3 {
  min-height: 56px;
  margin: 0 0 12px;
  font-size: 16px;
  line-height: 1.35;
}

.fav {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--muted);
  cursor: pointer;
}

.price {
  margin-top: auto;
  font-size: 21px;
  font-weight: 700;
}

.availability {
  margin: 12px 0 16px;
  color: #168744;
  font-size: 14px;
}

.availability button {
  border: 0;
  padding: 0;
  color: var(--red);
  background: transparent;
  cursor: pointer;
}

.availability_disabled {
  color: var(--muted);
}

.product-card__note {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 6px;
  background: #f0f1f4;
  color: var(--muted);
  font-weight: 700;
}

.product-card_muted img {
  opacity: 0.62;
}

.related {
  padding: 48px 0;
}

.related h2 {
  margin-bottom: 20px;
}

.related__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.related__grid a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 70px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  font-weight: 700;
}

.related__grid img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.related__grid span {
  margin-left: auto;
  color: var(--muted);
}

.landing-info {
  padding: 48px 0;
  background: var(--soft);
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.info-grid > div,
.lead-form {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.info-grid > div {
  padding: 24px;
}

.info-grid p {
  color: #4b535f;
}

.seo {
  padding: 48px 0;
}

.seo h2 {
  margin-bottom: 18px;
}

.seo p,
.seo li {
  color: #4b535f;
}

.seo li {
  margin: 10px 0;
  line-height: 1.55;
}

.lead {
  padding: 52px 0;
  color: #fff;
  background: var(--red);
}

.lead__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.7fr);
  gap: 44px;
  align-items: center;
}

.lead h2 {
  max-width: 560px;
  font-size: 36px;
}

.lead__contact {
  display: inline-block;
  margin: 20px 0 4px;
  font-size: 28px;
}

.lead__hours {
  max-width: 420px;
}

.lead-form {
  padding: 24px;
  color: var(--text);
}

.lead-form label {
  display: block;
  margin-bottom: 14px;
  color: #4b535f;
  font-weight: 700;
}

.lead-form input,
.lead-form textarea {
  display: block;
  width: 100%;
  margin-top: 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px 14px;
  resize: vertical;
}

.form-note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.footer {
  padding: 44px 0 92px;
  color: #d7dce4;
  background: var(--footer);
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 26px;
}

.footer h2,
.addresses h2,
.legal h2 {
  margin-bottom: 16px;
  color: #fff;
  font-size: 20px;
}

.footer a,
.footer p {
  margin: 10px 0;
  color: #d7dce4;
}

.addresses,
.legal {
  margin-top: 36px;
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.addresses__grid,
.legal__cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.addresses article,
.legal article {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.04);
}

.addresses h3,
.legal h3 {
  margin: 0 0 10px;
  color: #fff;
}

.legal__links,
.copyright {
  color: #b5bdc9;
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 24px;
  z-index: 4;
  max-width: 320px;
  border-radius: 8px;
  padding: 14px 18px;
  color: #fff;
  background: var(--dark);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.mobile-bar {
  display: none;
}

@media (max-width: 1020px) {
  .topbar__nav,
  .header-actions {
    display: none;
  }

  .header-main {
    flex-wrap: wrap;
  }

  .header-main__contact {
    display: block;
    margin-left: auto;
  }

  .search {
    order: 3;
    flex-basis: 100%;
  }

  .hero__grid,
  .catalog-layout,
  .lead__grid {
    grid-template-columns: 1fr;
  }

  .filter {
    position: static;
  }

  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .container {
    width: min(100% - 24px, 1220px);
  }

  .topbar__inner {
    justify-content: space-between;
  }

  .quick-menu {
    gap: 18px;
  }

  h1 {
    font-size: 30px;
  }

  .page-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero h2,
  .lead h2 {
    font-size: 30px;
  }

  .hero__grid {
    gap: 22px;
    min-height: auto;
  }

  .product-grid,
  .related__grid,
  .info-grid,
  .footer__grid,
  .addresses__grid,
  .legal__cards {
    grid-template-columns: 1fr;
  }

  .product-card {
    min-height: 390px;
  }

  .search {
    min-width: 0;
  }

  .catalog-button {
    min-width: 104px;
  }

  .footer {
    padding-bottom: 86px;
  }

  .mobile-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 5;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid var(--line);
    background: #fff;
    box-shadow: 0 -8px 24px rgba(31, 36, 48, 0.1);
  }

  .mobile-bar a {
    padding: 11px 4px 10px;
    color: #4b535f;
    text-align: center;
    font-size: 13px;
  }
}

@media (max-width: 440px) {
  .logo {
    width: 132px;
  }

  .header-main__contact {
    font-size: 14px;
  }

  .search__form button {
    padding: 0 10px;
  }

  .hero__actions,
  .hero__facts {
    align-items: stretch;
    flex-direction: column;
  }

  .button {
    width: 100%;
  }
}
