:root {
  --legal-navy: #07162f;
  --legal-blue: #0758f8;
  --legal-blue-soft: #edf4ff;
  --legal-muted: #5b6880;
  --legal-line: #dce5f2;
}

.legal-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% 4%, rgba(7, 88, 248, 0.09), transparent 26rem),
    radial-gradient(circle at 92% 16%, rgba(34, 195, 255, 0.07), transparent 30rem),
    #f6f9fd;
}

.legal-shell {
  width: min(calc(100% - 40px), 1240px);
  margin: 0 auto;
}

.legal-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(215, 225, 240, 0.82);
  background: rgba(250, 252, 255, 0.88);
  box-shadow: 0 8px 28px rgba(7, 22, 47, 0.045);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.legal-header__inner {
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.legal-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.legal-brand__mark {
  width: 38px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}

.legal-brand__copy {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.legal-brand__copy strong {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.025em;
}

.legal-brand__copy small {
  margin-top: 6px;
  color: #68758c;
  font-size: 9px;
  font-weight: 600;
}

.legal-back {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid #cdd9eb;
  border-radius: 12px;
  color: var(--legal-navy);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 22px rgba(20, 49, 95, 0.06);
  font-size: 13px;
  font-weight: 800;
  transition: border-color 180ms ease, color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.legal-back::before {
  content: "\2190";
  color: var(--legal-blue);
  font-size: 18px;
  line-height: 1;
}

.legal-back:hover {
  border-color: #aac1e7;
  color: var(--legal-blue);
  box-shadow: 0 12px 26px rgba(20, 49, 95, 0.1);
  transform: translateY(-1px);
}

.legal-page {
  padding: clamp(52px, 7vw, 92px) 0 72px;
}

.legal-hero {
  max-width: 980px;
}

.legal-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 20px;
  color: var(--legal-blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.legal-eyebrow::before {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--legal-blue);
  box-shadow: 0 0 0 6px rgba(7, 88, 248, 0.1);
  content: "";
}

.legal-page h1 {
  max-width: 940px;
  margin: 0;
  color: var(--legal-navy);
  font-family: "Golos Text", "Manrope", Arial, sans-serif;
  font-size: clamp(40px, 5.8vw, 72px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.02;
}

.legal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.legal-meta span,
.legal-meta a {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  padding: 0 13px;
  border: 1px solid #d8e3f3;
  border-radius: 999px;
  color: #53627a;
  background: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  font-weight: 700;
}

.legal-meta a {
  color: var(--legal-blue);
}

.legal-operator {
  display: grid;
  grid-template-columns: minmax(180px, 0.75fr) minmax(0, 2.25fr);
  gap: 24px;
  margin-top: 38px;
  padding: clamp(22px, 3vw, 34px);
  overflow: hidden;
  border: 1px solid #d7e3f4;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(7, 88, 248, 0.05), transparent 55%), rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 50px rgba(23, 55, 104, 0.08);
}

.legal-operator__title {
  color: var(--legal-blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.legal-operator__details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 28px;
  margin: 0;
}

.legal-operator__details div {
  min-width: 0;
}

.legal-operator__details dt {
  margin: 0 0 5px;
  color: #7b889e;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.legal-operator__details dd {
  margin: 0;
  color: #1d2e49;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
}

.legal-operator__details a,
.legal-copy a {
  color: var(--legal-blue);
  text-decoration: underline;
  text-decoration-color: rgba(7, 88, 248, 0.3);
  text-underline-offset: 3px;
}

.legal-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  align-items: start;
  gap: clamp(36px, 5vw, 72px);
  margin-top: clamp(52px, 7vw, 82px);
}

.legal-toc {
  position: sticky;
  top: 104px;
  padding: 22px;
  border: 1px solid var(--legal-line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 14px 38px rgba(29, 56, 98, 0.06);
}

.legal-toc__title {
  display: block;
  margin-bottom: 13px;
  color: #8190a7;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.legal-toc ol {
  display: grid;
  gap: 3px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.legal-toc button {
  display: block;
  width: 100%;
  padding: 7px 9px;
  border: 0;
  border-radius: 8px;
  color: #53627a;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease;
}

.legal-toc button:hover,
.legal-toc button:focus-visible {
  color: var(--legal-blue);
  background: var(--legal-blue-soft);
  outline: none;
}

.legal-copy {
  min-width: 0;
  padding: clamp(26px, 4vw, 52px);
  border: 1px solid var(--legal-line);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 24px 70px rgba(22, 51, 96, 0.07);
}

.legal-section {
  scroll-margin-top: 104px;
}

.legal-section + .legal-section {
  margin-top: 48px;
  padding-top: 48px;
  border-top: 1px solid #e4ebf5;
}

.legal-section h2 {
  margin: 0 0 22px;
  color: var(--legal-navy);
  font-family: "Golos Text", "Manrope", Arial, sans-serif;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.18;
}

.legal-section h3 {
  margin: 28px 0 10px;
  color: #152946;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.45;
}

.legal-section p,
.legal-section li {
  color: var(--legal-muted);
  font-size: 15px;
  font-weight: 550;
  line-height: 1.78;
}

.legal-section p {
  margin: 0;
}

.legal-section p + p {
  margin-top: 14px;
}

.legal-section ul,
.legal-section ol {
  display: grid;
  gap: 9px;
  margin: 16px 0 0;
  padding-left: 23px;
}

.legal-section ul {
  list-style: none;
  padding-left: 0;
}

.legal-section ul li {
  position: relative;
  padding-left: 22px;
}

.legal-section ul li::before {
  position: absolute;
  top: 0.72em;
  left: 2px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--legal-blue);
  box-shadow: 0 0 0 4px rgba(7, 88, 248, 0.08);
  content: "";
}

.legal-section ol li {
  padding-left: 5px;
}

.legal-note {
  margin-top: 20px !important;
  padding: 18px 20px;
  border-left: 3px solid var(--legal-blue);
  border-radius: 0 12px 12px 0;
  background: var(--legal-blue-soft);
  color: #344864 !important;
}

.legal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 32px;
  padding: 26px 0 0;
  border-top: 1px solid #dce5f2;
  color: #738199;
  font-size: 12px;
  font-weight: 650;
}

.legal-footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 16px;
}

.legal-footer a {
  color: var(--legal-blue);
}

@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .legal-toc {
    position: static;
  }

  .legal-toc ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .legal-shell {
    width: min(calc(100% - 24px), 1240px);
  }

  .legal-header__inner {
    min-height: 68px;
  }

  .legal-brand__copy small {
    display: none;
  }

  .legal-back {
    min-height: 40px;
    padding: 0 12px;
    font-size: 12px;
  }

  .legal-page {
    padding-top: 40px;
  }

  .legal-page h1 {
    font-size: clamp(34px, 10vw, 48px);
    letter-spacing: -0.04em;
  }

  .legal-operator {
    grid-template-columns: 1fr;
  }

  .legal-operator__details {
    grid-template-columns: 1fr;
  }

  .legal-layout {
    gap: 24px;
    margin-top: 40px;
  }

  .legal-toc {
    padding: 17px;
  }

  .legal-toc ol {
    grid-template-columns: 1fr;
  }

  .legal-copy {
    padding: 24px 19px;
    border-radius: 20px;
  }

  .legal-section + .legal-section {
    margin-top: 36px;
    padding-top: 36px;
  }

  .legal-section h2 {
    font-size: 25px;
  }

  .legal-section p,
  .legal-section li {
    font-size: 14px;
    line-height: 1.72;
  }

  .legal-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .legal-footer__links {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .legal-back,
  .legal-toc button {
    transition: none;
  }
}
