/* The legal pages (privacy, terms): one plain reading column on the page colour, using site.css's fonts and tokens. */

.legal {
  max-width: 44rem;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
  line-height: 1.65;

  /* the wordmark back to the home page, and the theme switch */
  & .legal__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 3.5rem;
  }
  & .legal__home img { display: block; height: 1.75rem; width: auto; }
  /* a plain "← Back" opposite the wordmark, since the logo alone doesn't read as a way home */
  & .legal__top .legal__back {
    color: var(--muted);
    font-size: 0.9375rem;
    text-decoration: none;
    &:hover, &:focus-visible { color: var(--ink); }
  }

  & h1 { margin: 0; font-size: clamp(2rem, 4vw, 2.75rem); font-weight: 500; letter-spacing: -0.02em; line-height: 1.1; }
  & .legal__date { margin: 0.75rem 0 2.5rem; color: var(--muted); font-size: 0.9375rem; }
  & h2 { margin: 2.75rem 0 0.75rem; font-size: 1.25rem; font-weight: 500; letter-spacing: -0.01em; }
  & h3 { margin: 1.75rem 0 0.5rem; font-size: 1rem; font-weight: 600; }
  & p, & li { color: color-mix(in srgb, var(--ink) 85%, var(--muted)); }
  & ul { padding-left: 1.25rem; }
  & li + li { margin-top: 0.375rem; }
  & a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 0.2em; }

  /* the cookie table: scrolls sideways on a phone rather than squashing */
  & .legal__table { overflow-x: auto; margin: 1rem 0; }
  & table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
  & th, & td { padding: 0.625rem 0.75rem 0.625rem 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
  & th { font-weight: 600; color: var(--ink); }

  & .legal__foot { margin-top: 4rem; padding-top: 1.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.875rem; }
}
