/* Shared by terms.html, privacy.html and refunds.html.

   These three are plain static files rather than routes in the app, on purpose.
   They are documents: no state, no motion, nothing that needs React. Serving
   them as flat HTML means they work on any host with no rewrite rules, they
   cannot be broken by a change to the site's JavaScript, and a crawler or a
   payment provider's compliance check gets the text without running anything.

   Tokens are copied from the app's theme.css so the two read as one product. */

:root {
  --ground: #f7faf9;
  --surface: #ffffff;
  --ink: #14210f;
  --muted: #5a6656;
  --line: #dce4dc;
  --leaf: #718705;
  --paper: #f7efdc;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  /* Inter is already served from this origin for the app; reusing it here
     means these pages cost no extra font download for anyone arriving from
     the site, which is nearly everyone who reads them. */
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-latin.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

.wrap {
  max-width: 44rem;
  margin: 0 auto;
  padding: 2.5rem max(1.5rem, env(safe-area-inset-left)) 6rem;
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  /* 44px of vertical room around a link people tap on a phone. */
  padding: 0.75rem 0;
  color: var(--muted);
  font-size: 0.9rem;
  text-decoration: none;
}

.back:hover {
  color: var(--ink);
}

h1 {
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.2rem, 6vw, 3.2rem);
  line-height: 1.06;
  letter-spacing: -0.025em;
  text-wrap: balance;
  margin: 1.5rem 0 0.75rem;
}

.updated {
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0 0 2.5rem;
}

h2 {
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 3.4vw, 1.75rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin: 2.75rem 0 0.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  scroll-margin-top: 1.5rem;
}

h2:first-of-type {
  border-top: none;
  padding-top: 0;
}

p,
li {
  margin: 0 0 1rem;
  max-width: 68ch;
}

ul,
ol {
  padding-left: 1.25rem;
}

strong {
  font-weight: 600;
}

a {
  color: var(--leaf);
  text-underline-offset: 0.18em;
}

a:focus-visible,
.back:focus-visible {
  outline: 2px solid var(--leaf);
  outline-offset: 3px;
  border-radius: 2px;
}

/* An unfilled business detail. Deliberately loud: shipping one of these live
   is worse than shipping no page at all, because it reads as abandoned. */
.todo {
  background: #fdecdf;
  color: #8f3f10;
  font-weight: 600;
  padding: 0.1em 0.4em;
  border-radius: 0.25rem;
  font-size: 0.92em;
}

.note {
  background: var(--paper);
  border-radius: 0.6rem;
  padding: 1.25rem 1.4rem;
  margin: 1.75rem 0;
}

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

.note-label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
}

footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-bottom: 1rem;
}
