.footer {
  background-color: rgba(21, 22, 24, 1);
  padding: 28px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  overflow: hidden;
}

.footer-line {
  width: 100%;
  height: 1px;
  background-color: rgba(34, 35, 38, 1);
}

.footer-payments {
  position: relative;
  overflow: hidden;
}

.footer-payments-track {
  display: flex;
  justify-content: flex-start;
}

.footer-payments.is-running {
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 48px, #000 calc(100% - 48px), transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 48px, #000 calc(100% - 48px), transparent 100%);
}

.footer-payments.is-running .footer-payments-track {
  width: max-content;
  animation: footer-payments-run var(--footer-payments-duration, 40s) linear infinite;
}

.footer-payments.is-running:hover .footer-payments-track {
  animation-play-state: paused;
}

.footer-payments-set {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 40px;
  flex-shrink: 0;
}

.footer-payments.is-running .footer-payments-set {
  padding-right: 40px;
}

.footer-payments-set img {
  display: block;
  height: 28px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  opacity: .85;
  transition: opacity .2s;
  user-select: none;
}

.footer-payments-set img:hover {
  opacity: 1;
}

@keyframes footer-payments-run {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .footer-payments.is-running .footer-payments-track {
    animation: none;
    width: auto;
  }

  .footer-payments.is-running .footer-payments-set {
    flex-wrap: wrap;
    row-gap: 16px;
    padding-right: 0;
  }

  .footer-payments [data-footer-payments-clone] {
    display: none;
  }

  .footer-payments.is-running {
    -webkit-mask-image: none;
    mask-image: none;
  }
}

.footer-top,
.footer-legal,
.footer-bottom {
  display: grid;
  grid-template-columns: minmax(180px, 1.1fr) repeat(3, minmax(0, 1fr)) 220px;
  column-gap: 32px;
}

.footer-top {
  align-items: start;
}

.footer-brand {
  grid-column: 1;
}

.footer-logo {
  display: block;
  max-height: 44px;
  width: auto;
}

.footer-columns {
  display: contents;
}

.footer-column {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}

.footer-column-title {
  margin-bottom: 4px;
  font-family: Onest;
  font-weight: 700;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: white;
}

.footer-column-link {
  font-family: Onest;
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  color: rgba(150, 152, 158, 1);
  text-decoration: none;
  transition: color .2s;
}

.footer-column-link:hover {
  color: rgba(255, 141, 40, 1);
}

.footer-first-line-socials {
  grid-column: -2;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
  justify-content: flex-end;
  margin-top: -10px;
}

.footer-first-line-socials-item {
  padding: 10px;
  border-radius: 10px;
  border: 1px solid rgba(26, 27, 29, 1);
}

.footer-legal {
  row-gap: 16px;
}

.footer-legal-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-width: 560px;
}

.footer-legal-block:nth-child(1) {
  grid-column: 1;
}

.footer-legal-block:nth-child(2) {
  grid-column: 2;
}

.footer-legal-block:nth-child(3) {
  grid-column: 3 / -1;
}

.footer-legal-title {
  font-family: Onest;
  font-weight: 700;
  font-size: 13px;
  line-height: 17px;
  color: rgba(200, 202, 208, 1);
}

.footer-legal-text {
  font-family: Onest;
  font-weight: 500;
  font-size: 13px;
  line-height: 18px;
  color: rgba(130, 132, 138, 1);
}

.footer-bottom {
  row-gap: 6px;
  font-family: Onest;
  font-weight: 500;
  font-size: 12px;
  line-height: 17px;
  color: rgba(108, 109, 112, 1);
}

.footer-bottom-copy {
  grid-column: 1;
  color: rgba(150, 152, 158, 1);
  white-space: nowrap;
}

.footer-bottom-text {
  grid-column: 2 / -1;
  max-width: 900px;
}

.footer-bottom-geo {
  grid-column: 1 / -1;
  justify-self: end;
  font-size: 10px;
  line-height: 14px;
  color: rgba(108, 109, 112, 0.55);
  text-decoration: none;
}

.footer-bottom-geo:hover {
  color: rgba(150, 152, 158, 1);
}

@media (max-width: 1000px) {
  .footer-top {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 24px;
  }

  .footer-brand {
    grid-column: 1 / 3;
    grid-row: 1;
  }

  .footer-first-line-socials {
    grid-column: 3;
    grid-row: 1;
    margin-top: 0;
  }

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

  .footer-legal-block:nth-child(3) {
    grid-column: 1 / -1;
  }

  .footer-bottom-copy,
  .footer-bottom-text,
  .footer-bottom-geo {
    grid-column: 1 / -1;
  }
}

@media (max-width: 600px) {
  .footer {
    padding: 18px;
    gap: 18px;
  }

  .footer-top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 16px;
  }

  .footer-brand,
  .footer-first-line-socials {
    grid-column: 1 / -1;
    grid-row: auto;
    justify-content: flex-start;
  }

  .footer-first-line-socials {
    gap: 8px;
  }

  .footer-legal {
    grid-template-columns: 1fr;
    row-gap: 12px;
  }

  .footer-legal-block:nth-child(n) {
    grid-column: 1;
  }

  .footer-payments-set img {
    height: 22px;
  }

  .footer-payments-set {
    gap: 28px;
  }

  .footer-payments.is-running .footer-payments-set {
    padding-right: 28px;
  }
}

.footer-payments-set img[style*="--w"] {
  --s: 46px;
  width: calc(var(--w) * var(--s));
  height: calc(var(--h) * var(--s));
  max-width: none;
}

@media (max-width: 600px) {
  .footer-payments-set img[style*="--w"] {
    --s: 36px;
  }
}
