.footer {
  color: rgb(var(--color-text));
  background-color: rgb(var(--color-background));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  column-gap: 56px;
  row-gap: 40px;
  align-items: start;
}

.footer-col {
  min-width: 0;
}

/* ---- brand column ---- */
.footer-logo {
  display: inline-flex;
  align-items: center;
  color: inherit;
  text-decoration: none;
}
.footer-logo__image {
  width: auto;
  max-width: var(--footer-logo-width, 160px);
  height: auto;
}
.footer-logo__text {
  font-family: Jost, sans-serif;
  font-size: 30px;
  font-weight: 500;
  color: rgb(var(--color-text));
}
.footer-brand__text {
  max-width: 380px;
  margin-block-start: 20px;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(var(--color-text), 0.85);
}
.footer-brand__text p {
  margin: 0;
}

/* ---- menu columns ---- */
.footer-col__title {
  margin: 0 0 18px;
  font-family: var(--sort-body-font);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgb(var(--color-text));
}
.footer-col__links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer-col__links a {
  color: rgba(var(--color-text), 0.9);
  font-size: 16px;
  line-height: 1.4;
  text-decoration: none;
}
.footer-col__links a:hover {
  color: rgb(var(--color-text));
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---- sign up column ---- */
.footer-signup__form {
  display: flex;
  align-items: stretch;
  gap: 10px;
  max-width: 330px;
}
.footer-signup__form .field,
.footer-signup__form label {
  flex: 1 1 auto;
  margin: 0;
}
.footer-signup__form input {
  width: 100%;
  height: 100%;
  min-height: 48px;
  padding: 12px 14px;
  color: rgb(var(--color-text));
  background: transparent;
  border: 1px solid #636363;
  border-radius: 0;
}
.footer-signup__form input::placeholder {
  color: #bbbbbb;
  opacity: 1;
}
/* the field renders a floating label duplicating the placeholder — keep only the placeholder.
   theme shows it again on :focus / :not(:placeholder-shown), so this needs !important */
.footer-signup__form .field__label,
.footer-signup__form .field__input:focus ~ .field__label,
.footer-signup__form .field__input:not(:placeholder-shown) ~ .field__label,
.footer-signup__form .field__input:-webkit-autofill ~ .field__label {
  display: none !important;
}
.footer-signup__submit {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  color: rgb(var(--color-background));
  background: rgb(var(--color-text));
  border: 0;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.footer-signup__submit:hover {
  color: rgb(var(--color-text));
  background: rgb(var(--color-background));
}
.footer-signup__tips {
  max-width: 330px;
  margin: 22px 0 26px;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(var(--color-text), 0.85);
}

.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: rgb(var(--color-text));
  border: 1px solid rgba(var(--color-text), 0.5);
  transition: color 0.2s ease, background-color 0.2s ease;
}
.footer-social a:hover {
  color: rgb(var(--color-text));
  background-color: rgba(var(--color-text), 0.06);
  border-color: rgba(var(--color-text), 0.2);
}
.footer-social svg {
  width: 20px;
  height: 20px;
}

/* ---- bottom row ---- */
.footer-bottom {
  margin-block-start: 40px;
  padding-block-start: 32px;
  text-align: center;
  border-block-start: 1px solid rgba(var(--color-text), 0.15);
}
.footer-payment {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-block-end: 20px;
}
.footer-payment svg {
  width: auto;
  height: 28px;
}
.footer-copyright {
  margin: 0;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(var(--color-text), 0.8);
}

@media (max-width: 959px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    column-gap: 32px;
    row-gap: 32px;
  }
  .footer-col--brand,
  .footer-col--signup {
    grid-column: 1 / -1;
  }
}
@media (max-width: 599px) {
  /* Main menu + Support stay side by side; brand/sign-up span the full width */
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    column-gap: 20px;
    row-gap: 28px;
  }
}
