.footer {
  background-color: var(--graphite-deep);
  color: var(--ink-light-muted);
  padding-top: 24px;
  border-top: 1px solid var(--graphite-line);
}

.footer__main {
  display: grid;
  grid-template-columns: 1.15fr auto minmax(260px, 1.2fr) auto;
  gap: 28px clamp(28px, 4vw, 56px);
  padding-bottom: 20px;
  align-items: start;
}

.footer__logo {
  display: inline-block;
  margin-bottom: 10px;
}

.footer__logo-img {
  height: 34px;
  width: auto;
  display: block;
}

.footer__desc {
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--ink-light-muted);
  max-width: 290px;
}

.footer__desc strong {
  color: var(--paper);
}

.footer__title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--paper);
  margin-bottom: 10px;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--graphite-line);
}

.footer__nav-grid {
  display: grid;
  grid-template-columns: repeat(2, auto);
  justify-content: start;
  gap: 7px 22px;
}

.footer__nav-link {
  font-size: 12.5px;
  color: var(--ink-light-muted);
  line-height: 1.4;
  white-space: nowrap;
  transition: color var(--transition);
}

.footer__nav-link:hover {
  color: var(--brand);
}

.footer__offices-list {
  display: flex;
  flex-direction: column;
}

.footer__office-row {
  padding: 5px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.footer__office-row:first-child { padding-top: 0; }
.footer__office-row:last-child { border-bottom: 0; padding-bottom: 0; }

.footer__office-title {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--paper);
  line-height: 1.3;
}

.footer__office-address {
  display: block;
  font-size: 12px;
  color: var(--ink-light-muted);
  line-height: 1.35;
}

.footer__contacts-quick {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  margin-bottom: 7px;
}

.footer__social-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 100%;
}

.footer__tg-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--graphite-line);
  background-color: var(--graphite-soft);
  color: var(--paper);
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  transition: background-color var(--transition), border-color var(--transition), color var(--transition);
}

.footer__tg-link svg {
  color: var(--brand);
  display: block;
  transition: color var(--transition);
}

.footer__tg-link:hover {
  background-color: var(--brand-deep);
  border-color: var(--brand);
  color: var(--paper);
}

.footer__tg-link:hover svg {
  color: var(--paper);
}

.footer__phone {
  font-family: var(--font-display);
  font-size: 16.5px;
  font-weight: 600;
  color: var(--paper);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  white-space: nowrap;
}

.footer__phone:hover {
  color: var(--brand);
}

.footer__email {
  font-size: 13px;
  color: var(--brand);
  width: fit-content;
}

.footer__email:hover {
  color: var(--paper);
}

.footer__messengers {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
  width: 100%;
}

.footer__social-link {
  width: 100%;
  height: 28px;
  border: 1px solid var(--graphite-line);
  background-color: var(--graphite-soft);
  color: var(--paper);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color var(--transition), border-color var(--transition), color var(--transition);
}

.footer__social-link svg {
  display: block;
}

.footer__social-link:hover {
  background-color: var(--brand-deep);
  border-color: var(--brand);
  color: var(--paper);
}

.footer__bottom {
  border-top: 1px solid var(--graphite-line);
  padding: 13px 0;
}

.footer__bottom-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer__copyright {
  font-size: 12px;
  color: var(--ink-light-muted);
}

.footer__bottom-right {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.footer__cookie-link {
  background: none;
  border: 0;
  padding: 0;
  font-size: 12px;
  color: var(--ink-light-muted);
  cursor: pointer;
  transition: color var(--transition);
}

.footer__cookie-link:hover {
  color: var(--paper);
}

.footer__dev-link {
  display: inline-flex;
  align-items: center;
  opacity: 0.88;
  transition: opacity var(--transition);
}

.footer__dev-link:hover {
  opacity: 1;
}

.footer__dev-logo {
  height: 26px;
  width: auto;
  display: block;
}

@media (max-width: 1040px) {
  .footer__main {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 24px 32px;
  }

  .footer__social-row {
    width: 176px;
  }

  .footer__tg-link,
  .footer__social-link {
    height: 34px;
  }
}

@media (max-width: 720px) {
  .footer__bottom-container {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .footer { padding-top: 20px; }
  .footer__col--nav { display: none; }
  .footer__main { grid-template-columns: 1fr; gap: 14px; padding-bottom: 16px; }
  .footer__logo { margin-bottom: 6px; }
  .footer__logo-img { height: 28px; }
  .footer__desc { font-size: 12px; line-height: 1.45; max-width: none; }
  .footer__title { margin-bottom: 7px; padding-bottom: 5px; font-size: 12.5px; }
  .footer__office-row { padding: 4px 0; }
  .footer__office-title { font-size: 11.5px; }
  .footer__office-address { font-size: 11.5px; }
  .footer__contacts-quick {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 4px 14px;
    margin-bottom: 10px;
  }
  .footer__phone { font-size: 16.5px; }
  .footer__email { font-size: 12.5px; }
  .footer__social-row {
    flex-direction: row;
    align-items: stretch;
    gap: 6px;
    width: 100%;
  }
  .footer__tg-link {
    flex: 1;
    min-width: 0;
    height: 36px;
  }
  .footer__messengers {
    display: flex;
    gap: 6px;
    width: auto;
    flex-shrink: 0;
  }
  .footer__social-link {
    width: 36px;
    height: 36px;
  }
  .footer__bottom { padding: 10px 0; }
  .footer__bottom-container { gap: 8px; }
  .footer__copyright { font-size: 11px; line-height: 1.45; }
  .footer__bottom-right { justify-content: center; gap: 14px; }
  .footer__dev-logo { height: 22px; }
}
