/* Terms, privacy and cookies: typeset like the report, contents beside the text, hairlines instead of boxes */
@layer pages {
  .legal {
    display: grid;
    grid-template-columns: minmax(0, 15rem) minmax(0, 46rem);
    gap: var(--space-16);
    max-width: var(--page-width);
    margin: 0 auto;
    padding: var(--space-16) var(--space-6) var(--space-20);
  }

  .legal__aside {
    position: sticky;
    top: var(--space-8);
    align-self: start;
  }

  .legal__body {
    font-size: var(--text-lg);

    > p:first-child {
      margin-top: 0;
    }
  }

  .legal__section {
    margin-top: var(--space-12);
    scroll-margin-top: var(--space-8);
  }

  .legal__section-title {
    margin: 0 0 var(--space-4);
    padding-top: var(--space-4);
    border-top: 2px solid var(--color-text);
    font-size: var(--text-2xl);
    font-weight: var(--font-semibold);
    line-height: 1.25;
  }

  .legal__subsection-title {
    margin: var(--space-8) 0 var(--space-3);
    font-size: var(--text-lg);
    font-weight: var(--font-semibold);
  }

  .legal p {
    margin: 0 0 var(--space-4);
    line-height: 1.7;
    color: var(--color-text);
  }

  .legal__body ul,
  .legal__body ol {
    margin: 0 0 var(--space-4);
    padding-left: var(--space-6);
  }

  .legal__body li {
    margin-bottom: var(--space-2);
    line-height: 1.6;
  }

  .legal strong {
    font-weight: var(--font-semibold);
  }

  .legal__body a {
    color: var(--color-text);
    text-decoration: underline;
    text-underline-offset: 0.2em;
  }

  /* A notice the reader must not miss: a bold lead-in under a rule, no tinted box */
  .legal__disclaimer {
    margin: var(--space-6) 0;
    padding: var(--space-4) 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);

    p {
      margin: 0;
    }
  }

  .legal__contact p:last-child {
    margin-bottom: 0;
  }

  .legal .ledger-wrap {
    margin: var(--space-4) 0 var(--space-6);
  }

  @media (max-width: 960px) {
    .legal {
      grid-template-columns: minmax(0, 1fr);
      gap: var(--space-10);
      padding: var(--space-10) var(--space-4) var(--space-16);
    }

    .legal__aside {
      position: static;
    }

    .legal__body {
      font-size: var(--text-base);
    }
  }
}
