:root { --ink:var(--ui-ink, #222923); --mute:var(--kp-mute-2, #566058); --line:var(--ui-line, rgba(34, 41, 35,.1)); --pink:var(--ui-accent, #233d31); --pink-deep:var(--ui-accent-hover, #1b3026); --bg:#f7f7f2; --legal-display:'DM Sans',-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; }
* { box-sizing:border-box; }
/* Body copy now uses the design system font (these pages did not load the DS until
   2026-07-30, so all seven rendered in the OS system font). System stack kept as fallback. */
body { margin:0; font-family:var(--font-body,-apple-system),BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif; color:var(--ink); background:var(--bg); line-height:1.7; -webkit-font-smoothing:antialiased; }
main.legal { max-width:820px; margin:0 auto; padding:44px 22px 80px; }
main.legal h1 { font-family:var(--legal-display); font-weight:550; font-size:clamp(30px,5vw,42px); letter-spacing:-.045em; margin:0 0 6px; }
.legal__meta { color:var(--mute); font-size:14px; margin:0 0 12px; }
main.legal h2 { font-family:var(--legal-display); font-weight:600; font-size:21px; margin:34px 0 10px; letter-spacing:-.03em; }
/* h3 previously had NO rule: it inherited the UA default (18.72px, system font, 700) and sat
   directly beneath a 20px Bricolage h2 — same apparent rank, different typeface. Used by
   refund.html and creator-agreement.html. */
main.legal h3 { font-family:var(--legal-display); font-weight:700; font-size:16.5px; margin:22px 0 8px; letter-spacing:-.2px; }
main.legal p, main.legal li { color:var(--ink); font-size:15.5px; }
main.legal ul { padding-left:20px; margin:8px 0; }
main.legal li { margin:6px 0; }
main.legal a { color:var(--pink-deep); }
main.legal strong { font-weight:700; }
/* ── 3-column docs layout (GitBook-style): left menu · content · "On this page" ── */
.legal-layout { max-width:1180px; margin:0 auto; padding:0 22px; display:grid; gap:48px; grid-template-columns:230px minmax(0,1fr) 210px; align-items:start; }
.legal-layout main.legal { max-width:none; margin:0; padding:44px 0 80px; }
.legal-side { position:sticky; top:73px; align-self:start; padding-top:48px; max-height:calc(100vh - 73px); overflow:auto; }
.legal-side__title { font-size:11px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; color:var(--mute); margin:0 0 10px; }
.legal-nav nav, .legal-toc nav { display:flex; flex-direction:column; gap:1px; }
.legal-nav a { font-size:14px; color:var(--mute); text-decoration:none; padding:7px 12px; border-radius:8px; border-left:2px solid transparent; line-height:1.35; }
.legal-nav a:hover { background:rgba(34, 41, 35,.04); color:var(--ink); }
.legal-nav a.active { color:var(--pink-deep); font-weight:700; background:rgba(35, 61, 49,.07); border-left-color:var(--pink); }
/* impeccable-disable-next-line side-tab -- continuous scroll-spy rail across 14 stacked links, not a card accent */
.legal-toc a { font-size:13px; color:var(--mute); text-decoration:none; padding:5px 12px; border-left:2px solid var(--line); line-height:1.4; }
.legal-toc a:hover { color:var(--ink); }
.legal-toc a.on { color:var(--pink-deep); border-left-color:var(--pink); font-weight:600; }
@media (max-width:1040px){ .legal-toc { display:none; } .legal-layout { grid-template-columns:220px minmax(0,1fr); gap:40px; } }
@media (max-width:720px){ .legal-nav { min-width:0; position:static; padding-top:14px; max-height:none; overflow:visible; }
  .legal-nav .legal-side__title { display:none; }
  .legal-nav nav { position:relative; flex-direction:row; gap:6px; overflow-x:auto; scrollbar-width:none; margin:0 -18px; padding:0 18px; }
  .legal-nav nav::-webkit-scrollbar { display:none; }
  .legal-nav a, .legal-nav a.active { flex:none; white-space:nowrap; padding:0 14px; border:1px solid var(--line); border-radius:999px; }
  .legal-nav a.active { border-color:rgba(35, 61, 49,.35); }
  .legal-layout { grid-template-columns:1fr; padding:0 18px; } .legal-layout main.legal { padding:32px 0 64px; } }

/* ── Touch targets, 2026-08-01 ──
   Audited at 375px across all seven legal pages: the footer nav links ("Terms", "Privacy",
   "EULA", "Acceptable Use") rendered 18px tall inside a <nav>. That is real navigation, not
   a link inside a sentence, so WCAG 2.5.8's inline exemption does not apply and 18px fails
   the 24px AA minimum outright. The brand lockup was 31px and the back link 24px — over the
   AA floor but under the 44px platform target the rest of the site holds.
   Height only: type, colour and horizontal rhythm are untouched. The footer and the sidebar
   rails get taller, which is the correct trade for links a thumb has to hit. */
.legal-nav a,
.legal-toc a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
/* The two sidebar rails are vertical lists, so they keep their own compact vertical padding
   and simply grow to the 44px floor rather than gaining 44px of extra box. */
.legal-nav a, .legal-toc a { box-sizing: border-box; }

/* ── Contents on narrower screens, 2026-10-21 ──
   The "On this page" rail is hidden below 1040px, which left phones and tablets no way to jump
   to a section of the long agreements. legal.js puts a collapsed copy of the list under the
   title; it shows only where the rail does not. */
.legal-toc-m { display:none; border:1px solid var(--line); border-radius:12px; padding:0 14px; margin:0 0 20px; }
.legal-toc-m summary { padding:12px 0; line-height:22px; font-weight:700; font-size:14.5px; cursor:pointer; }
.legal-toc-m nav { display:flex; flex-direction:column; padding-bottom:6px; }
main.legal .legal-toc-m a { display:flex; align-items:center; min-height:44px; border-top:1px solid var(--line); color:var(--ink); text-decoration:none; font-size:14.5px; line-height:1.35; }
@media (max-width:1040px){ .legal-toc-m { display:block; } }
/* The sticky header (77px) covered the top of whatever a contents link or the skip link
   jumped to. */
html { scroll-padding-top:90px; }
/* Shown in a frame (legal.js sets .is-framed): the document alone. */
.is-framed .sh, .is-framed .skip-link, .is-framed .legal-side, .is-framed .legal-toc-m { display:none; }
.is-framed .legal-layout { display:block; }

.legal-nav a:focus-visible, .legal-toc a:focus-visible, main.legal a:focus-visible, .legal-toc-m summary:focus-visible {
  outline: 2px solid var(--pink-deep); outline-offset: 2px; border-radius: 4px;
}
html[data-theme="dark"] {
  --ink: #f2f6f3;
  --mute: #b8c8be;
  --line: rgba(184, 200, 190, .22);
  --pink: #9ce6ba;
  --pink-deep: #9ce6ba;
  --bg: #0f1612;
  color-scheme: dark;
}
html[data-theme="dark"] .legal-nav a:hover { background: rgba(156, 230, 186, .08); color: #f2f6f3; }
html[data-theme="dark"] .legal-nav a.active { background: rgba(29, 77, 53, .55); color: #e6f7ec; border-left-color: #9ce6ba; }
html[data-theme="dark"] .legal-toc-m { background: #141c18; border-color: rgba(184, 200, 190, .25); }
html[data-theme="dark"] main.legal .legal-toc-m a { color: #f2f6f3; }
html[data-theme="dark"] :focus-visible { outline-color: #d8f68b; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
