:root {
  --bg: #fbf7f0;
  --bg-raised: #fffdf9;
  --text: #1c1917;
  --text-muted: #57534e;
  --accent: #a63d17;
  --border: #e5ddd0;
  --tongue: #e8859b;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #16130f;
    --bg-raised: #211d18;
    --text: #f5f0e8;
    --text-muted: #b9afa3;
    --accent: #f0a868;
    --border: #332d26;
    --tongue: #e8859b;
  }
}

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

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

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

main { flex: 1; }

main, .site-header, .site-footer {
  width: 100%;
  max-width: 46rem;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.5rem;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  white-space: nowrap;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
}

.lang-toggle {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-inline: 0.25rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}

.lang-toggle:hover,
.lang-toggle:focus-visible {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
  min-height: 44px;
}

.wordmark span { color: var(--text); }

.mark { flex: none; }

.hero { padding-block: 2rem 3rem; }

h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 8vw, 2.75rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

p { margin: 0 0 1rem; }

.lede {
  max-width: 34rem;
  color: var(--text-muted);
  font-size: 1.125rem;
}

.fineprint {
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-block: 1.5rem 1.25rem;
}

.action { margin-bottom: 0.5rem; }

.action a {
  color: var(--accent);
  text-underline-offset: 0.2em;
  padding-block: 0.5rem;
}

.pill {
  display: inline-block;
  padding: 0.5rem 0.875rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-raised);
  color: var(--text-muted);
  font-size: 0.9375rem;
  font-weight: 500;
}

.site-footer {
  padding-block: 2rem 2.5rem;
  margin-top: 2rem;
  border-top: 1px solid var(--border);
}

.footer-social,
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  margin-bottom: 0.75rem;
}

.social-link,
.footer-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  color: var(--text-muted);
  font-size: 0.9375rem;
  text-decoration: none;
}

.social-link:hover,
.social-link:focus-visible,
.footer-nav a:hover,
.footer-nav a:focus-visible {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.social-icon { flex: none; }

.site-footer .fineprint { margin-bottom: 0; }

/* Legal pages (privacy, terms) */

.legal { padding-block: 1rem 2rem; }

.legal h1 { margin-bottom: 0.5rem; }

.legal .updated {
  color: var(--text-muted);
  font-size: 0.9375rem;
  margin-bottom: 2rem;
}

.legal h2 {
  margin: 2.25rem 0 0.75rem;
  font-size: 1.375rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.legal h3 {
  margin: 1.5rem 0 0.5rem;
  font-size: 1.0625rem;
}

.legal ul { margin: 0 0 1rem; padding-left: 1.25rem; }

.legal li { margin-bottom: 0.375rem; }

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

.table-wrap {
  overflow-x: auto;
  margin: 0 0 1.5rem;
}

.legal table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.legal caption {
  text-align: left;
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
}

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

.legal thead th {
  color: var(--text);
  font-weight: 600;
  border-bottom: 2px solid var(--border);
}

.legal tbody th {
  color: var(--text);
  font-weight: 600;
}

.legal td { color: var(--text-muted); }
