/* Styling for the two static legal pages.
 *
 * These sit in web/public rather than in the React app on purpose, so they render with no
 * JavaScript, no sign-in and no app boot — a legal page has to work for someone who has
 * never had an account, and for Stripe's reviewer following a link. That puts them outside
 * the Tailwind pipeline, so the type scale and the stone/charcoal palette are restated here
 * by hand. Keep them in step with the app's look; they are not a different product. */

:root {
  color-scheme: light dark;
  --bg: #fafaf9;
  --fg: #1c1917;
  --muted: #57534e;
  --rule: #e7e5e4;
  --panel: #ffffff;
  --link: #171e26;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0a09;
    --fg: #f5f5f4;
    --muted: #a8a29e;
    --rule: #292524;
    --panel: #1c1917;
    --link: #e7e5e4;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
}

header {
  border-bottom: 1px solid var(--rule);
}

header .bar,
main,
footer .bar {
  margin: 0 auto;
  max-width: 44rem;
  padding: 0 1.25rem;
}

header .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

header .wordmark {
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--fg);
}

header nav a {
  font-size: 0.875rem;
  margin-left: 1rem;
}

main {
  padding-top: 2.5rem;
  padding-bottom: 4rem;
}

h1 {
  font-size: 1.9rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem;
}

h2 {
  font-size: 1.2rem;
  letter-spacing: -0.01em;
  margin: 2.5rem 0 0.6rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
}

h3 {
  font-size: 1rem;
  margin: 1.6rem 0 0.4rem;
}

p,
ul,
ol {
  margin: 0 0 1rem;
}

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

li {
  margin-bottom: 0.4rem;
}

a {
  color: var(--link);
  text-underline-offset: 2px;
}

.dates {
  color: var(--muted);
  font-size: 0.875rem;
  margin-bottom: 2rem;
}

.summary {
  background: var(--panel);
  border: 1px solid var(--rule);
  border-radius: 0.75rem;
  padding: 1.25rem 1.25rem 0.5rem;
  margin-bottom: 2rem;
}

.summary h2 {
  margin: 0 0 0.6rem;
  padding: 0;
  border: 0;
  font-size: 1rem;
}

/* Warranty and liability sections need to stand out from the surrounding prose rather than
 * read as one more paragraph. Contrasting type, not shouting capitals. */
.conspicuous {
  background: var(--panel);
  border: 1px solid var(--rule);
  border-left: 3px solid #c8102e;
  border-radius: 0.5rem;
  padding: 1rem 1.25rem 0.25rem;
  margin-bottom: 1rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 0.6rem 0.75rem 0.6rem 0;
  border-bottom: 1px solid var(--rule);
}

th {
  font-weight: 600;
  white-space: nowrap;
}

.table-scroll {
  overflow-x: auto;
}

address {
  font-style: normal;
  color: var(--muted);
}

footer {
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.875rem;
}

footer .bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  padding-top: 1.25rem;
  padding-bottom: 2.5rem;
}

@media (max-width: 30rem) {
  h1 {
    font-size: 1.6rem;
  }
}
