html.legal,
body.legal {
  min-width: 0;
  height: auto;
  max-height: none;
  overflow: auto;
  overflow-x: hidden;
  background: #472c7c;
}

.legal-page {
  position: relative;
  min-height: 100dvh;
  padding:
    max(24px, env(safe-area-inset-top))
    max(24px, env(safe-area-inset-right))
    max(32px, env(safe-area-inset-bottom))
    max(24px, env(safe-area-inset-left));
  background:
    radial-gradient(120% 80% at 50% -10%, #7d69ac 0%, #472c7c 58%, #3a2468 100%);
  color: #fff;
}

.legal-top {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin: 0 auto 36px;
  max-width: 840px;
}

.legal-back {
  position: absolute;
  left: 0;
  top: 50%;
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateY(-50%);
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-family: "Congenial Cyrillic BETA", sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: normal;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}

.legal-back:focus-visible,
.legal-back:active {
  outline: none;
  background: transparent;
}

.legal-back:hover .glass-icon__gold,
.legal-back:focus-visible .glass-icon__gold {
  opacity: 1;
}

.legal-back__icon {
  position: relative;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  color: #fff;
  background: url("../images/buttons/glass.webp") center / 100% 100% no-repeat;
}

.legal-back__icon svg {
  display: block;
  width: 100%;
  height: 100%;
}

.legal-logo {
  display: block;
  width: min(170px, 42vw);
}

.legal-logo img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 22px rgba(255, 242, 203, 0.22));
}

.legal-content {
  max-width: 840px;
  margin: 0 auto;
  font-family: "Congenial Cyrillic BETA", sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.92);
}

.legal-content h1,
.legal-content h2 {
  margin: 0 0 20px;
  font-family: "Lorrach BETA", sans-serif;
  font-weight: 800;
  line-height: 1.15;
  text-transform: uppercase;
  background-image: linear-gradient(200.16deg, #cead7c 16.75%, #fff2cb 54.06%, #e6cc9b 68.88%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.legal-content h1 {
  font-size: clamp(28px, 4vw, 40px);
}

.legal-content h2 {
  margin-top: 36px;
  font-size: clamp(20px, 2.6vw, 26px);
}

.legal-content p,
.legal-content ul {
  margin: 0 0 16px;
}

.legal-content ul {
  padding-left: 1.2em;
}

.legal-content li + li {
  margin-top: 10px;
}

.legal-content li::marker {
  color: #cead7c;
}

.legal-content .btn {
  margin-top: 8px;
  height: auto;
  min-height: 40px;
  max-width: 100%;
  padding: 10px 24px;
  white-space: normal;
}

#ot-sdk-cookie-policy:not(:empty) {
  margin: 20px 0 28px;
  overflow-x: auto;
  color: rgba(255, 255, 255, 0.92);
}

#ot-sdk-cookie-policy table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

#ot-sdk-cookie-policy th,
#ot-sdk-cookie-policy td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(206, 173, 124, 0.28);
  text-align: left;
  vertical-align: top;
}

#ot-sdk-cookie-policy a {
  color: #fff2cb;
}

.legal-footer {
  max-width: 840px;
  margin: 48px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  font-family: "Congenial Cyrillic BETA", sans-serif;
  font-size: 14px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.72);
}

@media (max-width: 768px), (max-width: 1024px) and (orientation: portrait) {
  .legal-page {
    padding:
      max(16px, env(safe-area-inset-top))
      max(16px, env(safe-area-inset-right))
      max(24px, env(safe-area-inset-bottom))
      max(16px, env(safe-area-inset-left));
  }

  .legal-top {
    min-height: 72px;
    margin-bottom: 24px;
    align-items: flex-start;
    padding-top: 4px;
  }

  .legal-back {
    top: 0;
    transform: none;
  }

  .legal-back span:last-child {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  .legal-logo {
    margin-top: 38px;
    width: clamp(132px, 47vw, 170px);
  }

  .legal-content {
    font-size: 15px;
  }

  .legal-content h1 {
    font-size: clamp(24px, 7.4vw, 32px);
    margin-bottom: 16px;
  }

  .legal-content h2 {
    margin-top: 28px;
    font-size: clamp(18px, 5.4vw, 22px);
  }

  .legal-footer {
    margin-top: 36px;
    font-size: 13px;
  }
}
