.legal-section h2 {
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1.15;
}

.legal-section h3 {
  align-self: end;
  margin: 0;
  font-size: 0.98rem;
  font-weight: 800;
  line-height: 1.18;
}

.legal-section h3 + p,
.legal-section h3 + ul,
.legal-section h3 + pre {
  margin-top: -0.35rem;
}

.legal-section p,
.legal-section li {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.3;
}

.legal-section p {
  margin: 0;
}

.legal-section ul {
  margin: 0;
  padding-left: 1.2rem;
}

.legal-section li + li {
  margin-top: 0.2rem;
}

.legal-section strong {
  color: var(--text);
}

.legal-section pre {
  overflow-x: auto;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  white-space: pre-wrap;
}

.legal-section code {
  font: 0.92rem/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

@media (max-width: 1100px) {
  .donation-button {
    width: 1.85rem;
    padding-inline: 0;
  }

  .donation-button__label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }
}

@media (max-width: 810px) {
  .site-header__inner {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    row-gap: 0.35rem;
  }

  .header-actions {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
  }

  .site-nav {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .install-section {
    scroll-margin-top: 160px;
  }
}

@media (max-width: 350px) {
  .site-header__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    justify-self: center;
  }

  .header-actions {
    grid-column: 1;
    grid-row: 2;
    justify-self: center;
  }

  .site-nav {
    grid-column: 1;
    grid-row: 3;
  }
}

@media (max-width: 480px) {
  .language-switcher__menu {
    position: fixed;
    top: 4.75rem;
    right: 0.75rem;
    left: 0.75rem;
    width: auto;
  }
}

@media (max-width: 390px) {
  .site-nav__links {
    gap: 0.75rem;
  }

  .site-nav .site-nav__button {
    padding-inline: 0.55rem;
  }
}

@media (max-width: 480px) {
  .site-nav__links {
    display: grid;
    grid-template-columns: repeat(4, max-content);
    justify-content: center;
    width: 100%;
    gap: 0.25rem 0.75rem;
  }

  .site-nav .site-nav__button {
    grid-column: 1 / -1;
    justify-self: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
