.footer {
  margin-top: auto;
  flex-shrink: 0;
  background: var(--c-paper);
  border-top: 1px solid var(--c-line);
  padding-block: var(--sp-6);
  padding-bottom: calc(var(--sp-6) + var(--safe-bottom));
}

.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
}

.footer__title {
  font-size: var(--fs-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--c-head);
  margin-bottom: var(--sp-3);
}

.footer__list {
  display: grid;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

.footer__list a:hover {
  color: var(--c-accent);
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-3);
}

.footer__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
  background: #ffffff;
}

.footer__logo img,
.footer__brand img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  display: block;
}

.footer__socials {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: var(--sp-3);
}

.footer__social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  box-shadow: none;
  transition: opacity var(--transition), transform var(--transition);
  -webkit-tap-highlight-color: transparent;
}

.footer__social:hover {
  opacity: 0.85;
  transform: translateY(-1px);
  background: transparent;
  border: 0;
  box-shadow: none;
}

.footer__social:active {
  opacity: 0.7;
  transform: translateY(0);
}

.footer__social-icon {
  display: block;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  overflow: visible;
}

.footer__bottom {
  margin-top: var(--sp-6);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--c-line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2) var(--sp-4);
  justify-content: space-between;
  font-size: var(--fs-xs);
  color: var(--c-muted);
}

.footer__credit {
  margin: 0;
  flex: 1 1 auto;
  text-align: center;
  color: #e65100;
  font-size: calc(var(--fs-xs) * 1.2);
  font-weight: 500;
  line-height: 1.4;
  -webkit-text-size-adjust: 100%;
}

.footer__credit-link,
.footer__credit-name {
  font-weight: 700;
}

.footer__credit-prometey {
  color: #1a1a1a;
}

.footer__credit-labs {
  color: #7b2cbf;
}

.footer__credit-link {
  text-decoration: none;
  transition: opacity var(--transition);
}

.footer__credit-link:hover,
.footer__credit-link:focus-visible {
  opacity: 0.82;
}

.footer__credit-link .footer__credit-prometey,
.footer__credit-link .footer__credit-labs {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

@media (max-width: 599px) {
  .footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--sp-2);
  }

  .footer__credit {
    flex: 0 0 auto;
    text-align: left;
  }
}

@media (min-width: 600px) {
  .footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .footer__grid {
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: var(--sp-6);
  }
}
