html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #111;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
}

body {
  overflow-x: hidden;
}

/* страховка от микро-overflow */

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: clamp(14px, 3vw, 24px);
  padding-right: clamp(14px, 3vw, 24px);
}


.site-header {
  background: #fff;
  border-bottom: 1px solid #eaeaea;
}

.site-header__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  height: 72px;
  gap: 18px;
}

.site-header__logo img {
  height: 42px;
  width: auto;
  display: block;
}

.site-header__nav {
  justify-self: center;
  display: flex;
  gap: 22px;
  align-items: center;
  flex-wrap: wrap;
}

.site-header__link {
  font-size: 14px;
  font-weight: 500;
  color: #111;
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 999px;
}

.site-header__link:hover {
  color: #E53935;
  background: rgba(229, 57, 53, 0.08);
}

.site-footer {
  margin-top: 64px;
  background: #fff7f7;
  border-top: 1px solid rgba(229, 57, 53, .12);
  padding: 28px 0 16px;
  overflow: hidden;
}

.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;

  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 44px;
}

.site-footer__brand {
  min-width: 240px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.site-footer__logo {
  max-width: 240px;
}

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

.site-footer__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
  color: #111;
  font-weight: 650;
}

.site-footer__meta {
  margin: 0;
  font-size: 12px;
  color: #6f6f6f;
  line-height: 1.35;
}

.site-footer__nav {
  flex: 1;
  display: flex;
  gap: 56px;
}

.site-footer__nav-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer__link {
  font-size: 13px;
  color: #111;
  text-decoration: none;
  line-height: 1.35;
  white-space: nowrap;
  transition: color .18s ease, transform .18s ease;
}

.site-footer__link:hover {
  color: #E53935;
  transform: translateX(2px);
}

.site-footer__contacts {
  margin-top: 14px;
}

.site-footer__contacts {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.site-footer__contacts-title {
  margin: 0;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #111;
  opacity: .9;
}

.site-footer__chips {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  max-width: 360px;
}

.footer-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid #e7e7e7;
  background: #fff;
  text-decoration: none;
  color: #111;
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.footer-chip:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, .10);
  border-color: rgba(0, 0, 0, .18);
}

.footer-chip__icon {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex: 0 0 28px;
}

.footer-chip--tg .footer-chip__icon {
  background: #229ED9;
}

.footer-chip--vk .footer-chip__icon {
  background: #0077FF;
}

.footer-chip--yandex .footer-chip__icon {
  background: #E53935;
}

.footer-chip__text {
  white-space: nowrap;
}

.site-footer__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 14px;
  border-radius: 999px;
  background: #E53935;
  color: #fff;
  font-size: 12.5px;
  font-weight: 800;
  text-decoration: none;
  border: 1px solid #E53935;
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.site-footer__cta:hover {
  transform: translateY(-1px);
  filter: brightness(.98);
  box-shadow: 0 12px 22px rgba(229, 57, 53, .22);
}

.site-footer__bottom {
  max-width: 1200px;
  margin: 18px auto 0;
  padding: 12px 20px 0;
  border-top: 1px solid rgba(0, 0, 0, .06);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.site-footer__copy {
  margin: 0;
  font-size: 12px;
  color: #6f6f6f;
  line-height: 1.35;
}

.site-footer__top {
  text-decoration: none;
  color: #111;
  font-size: 12px;
  font-weight: 700;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid #e7e7e7;
  background: #fff;
  transition: transform .18s ease, box-shadow .18s ease, color .18s ease;
}

.site-footer__top:hover {
  color: #E53935;
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(0, 0, 0, .10);
}

.site-footer img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* adaptive */
@media (max-width: 980px) {
  .site-footer__inner {
    flex-direction: column;
    gap: 18px;
  }

  .site-footer__brand {
    min-width: 0;
  }

  .site-footer__nav {
    width: 100%;
    gap: 26px;
    flex-wrap: wrap;
  }

  .site-footer__contacts {
    align-items: flex-start;
  }

  .site-footer__chips {
    justify-content: flex-start;
    max-width: 100%;
  }
}

@media (max-width: 560px) {
  .site-footer {
    padding: 22px 0 14px;
  }

  .site-footer__nav {
    flex-direction: column;
    gap: 12px;
  }

  .site-footer__nav-group {
    gap: 8px;
  }

  .footer-chip {
    width: 100%;
    justify-content: center;
  }

  .site-footer__cta {
    width: 100%;
  }

  .site-footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
}


.site-header__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 10px 18px;
  border-radius: 999px;

  background: #E53935;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;

  border: 1px solid #E53935;
  white-space: nowrap;

  transition:
    transform .18s ease,
    box-shadow .18s ease,
    filter .18s ease;
}

.site-header__cta:hover {
  transform: translateY(-2px);
  filter: brightness(.98);
  box-shadow: 0 14px 26px rgba(229, 57, 53, .28);
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg,
      #ffffff 0%,
      rgba(229, 57, 53, .08) 45%,
      rgba(229, 57, 53, .16) 100%);
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;

  background-image:
    repeating-radial-gradient(circle at 0 0,
      rgba(0, 0, 0, .035) 0,
      rgba(0, 0, 0, .035) 1px,
      transparent 1px,
      transparent 3px);

  opacity: .35;
  mix-blend-mode: soft-light;
}

/* ===== OVERLAY MESSAGES (Django messages) ===== */
.ui-msg {
  position: fixed !important;
  inset: 0 !important;
  z-index: 99999 !important;
}

.ui-msg__backdrop {
  position: absolute !important;
  inset: 0 !important;
  background: rgba(0, 0, 0, .55) !important;
}

.ui-msg__dialog {
  position: relative !important;
  z-index: 1 !important;
  width: 100% !important;
  height: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 18px !important;
}

.ui-msg__content {
  width: min(560px, 92vw) !important;
  background: #fff !important;
  border: 1px solid rgba(0, 0, 0, .12) !important;
  border-radius: 16px !important;
  box-shadow: 0 18px 55px rgba(0, 0, 0, .22) !important;
  padding: 18px 18px 14px !important;
}

.ui-msg__title {
  margin: 0 0 8px !important;
  font-size: 18px !important;
  font-weight: 900 !important;
}

.ui-msg__text {
  margin: 0 0 14px !important;
  font-size: 14px !important;
  line-height: 1.45 !important;
  color: #111 !important;
}

.ui-msg__actions {
  display: flex !important;
  justify-content: flex-end !important;
  gap: 10px !important;
}

.ui-msg__btn {
  border: 1px solid rgba(0, 0, 0, .18) !important;
  background: #fff !important;
  border-radius: 999px !important;
  padding: 9px 14px !important;
  font-weight: 800 !important;
  cursor: pointer !important;
}

.ui-msg__close {
  position: absolute !important;
  top: 16px !important;
  right: 16px !important;
  width: 38px !important;
  height: 38px !important;
  border-radius: 999px !important;
  border: 1px solid rgba(0, 0, 0, .16) !important;
  background: #fff !important;
  cursor: pointer !important;
  font-size: 22px !important;
  line-height: 1 !important;
}

.ui-msg__content--success {
  border-left: 6px solid #2e7d32 !important;
}

.ui-msg__content--error {
  border-left: 6px solid #c62828 !important;
}

.ui-msg__content--warning {
  border-left: 6px solid #ef6c00 !important;
}

.ui-msg__content--info {
  border-left: 6px solid #1565c0 !important;
}

html.ui-msg--lock,
html.ui-msg--lock body {
  overflow: hidden !important;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
}

img,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

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

/* ===== Header mobile nav ===== */
.burger {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid #e7e7e7;
  background: #fff;
  border-radius: 12px;
  padding: 10px;
  cursor: pointer;
}

.burger span {
  display: block;
  height: 2px;
  background: #111;
  border-radius: 2px;
}

.burger span+span {
  margin-top: 6px;
}

.mnav[hidden] {
  display: none;
}

.mnav {
  position: fixed;
  inset: 0;
  z-index: 9999;
}

.mnav__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .35);
}

.mnav__panel {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: min(360px, 92vw);
  background: #fff;
  box-shadow: -18px 0 50px rgba(0, 0, 0, .18);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mnav__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mnav__title {
  font-weight: 800;
}

.mnav__close {
  width: 44px;
  height: 44px;
  border: 1px solid #e7e7e7;
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
}

.mnav__links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 6px;
}

.mnav__links a {
  text-decoration: none;
  color: inherit;
  padding: 10px 12px;
  border-radius: 12px;
}

.mnav__links a:hover {
  background: #f5f5f5;
}

.mnav__cta {
  margin-top: auto;
  display: block;
  text-align: center;
  padding: 12px 14px;
  border-radius: 14px;
  background: #111;
  color: #fff;
  text-decoration: none;
}


@media (max-width: 980px) {

  .header__nav {
    display: none;
  }

  .burger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

body.is-menu-open {
  overflow: hidden;
}

/* ===== Footer docs list (glow red style) ===== */
.site-footer__docs {
  margin-top: 14px;
}

.site-footer__docs-title {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #111;
  opacity: .9;
}

.site-footer__docs-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.site-footer__docs-item {
  position: relative;
  padding-left: 14px;
}

.site-footer__docs-item::before {
  content: "•";
  position: absolute;
  left: 0;
  top: 0;
  color: #E53935;
  font-size: 18px;
  line-height: 1;
  text-shadow: 0 0 8px rgba(229, 57, 53, .45);
}

.site-footer__docs-item a {
  font-size: 13px;
  font-weight: 700;
  color: #E53935;
  text-decoration: none;
  text-shadow:
    0 0 6px rgba(229, 57, 53, .35),
    0 0 12px rgba(229, 57, 53, .18);
  transition:
    color .15s ease,
    text-shadow .15s ease,
    transform .15s ease;
}

.site-footer__docs-item a:hover {
  color: #ff3b3b;
  text-shadow:
    0 0 10px rgba(255, 59, 59, .55),
    0 0 18px rgba(255, 59, 59, .35);
  transform: translateX(3px);
}

/* FIX footer overflow on mobile */
@media (max-width: 560px) {
  .site-footer__link {
    white-space: normal;
  }

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

  .footer-chip__text {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}