/* Downsize — site styles. Light palette on :root, dark via prefers-color-scheme. */

:root {
  color-scheme: light dark;
  --bg: #fbfaf8;
  --surface: #ffffff;
  --border: #e6e2dc;
  --text: #1c1a17;
  --muted: #6b655d;
  --accent: #1f6f4a;
  --accent-text: #ffffff;
  --radius: 12px;
  --measure: 68ch;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #16151a;
    --surface: #1e1d23;
    --border: #302e37;
    --text: #eceaf0;
    --muted: #a29daa;
    --accent: #4fbb8a;
    --accent-text: #10241b;
  }
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

code {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.1em 0.35em;
  font-size: 0.9em;
}

/* ---------------------------------------------------------------- chrome */

/* One container, applied to the three top-level regions. Anything that wants a
   narrower measure caps its own width as a CHILD of these — putting max-width on
   the container itself would centre the block instead of aligning it left. */
.site-header,
.site-footer,
main {
  max-width: 1040px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 2.5rem);
}

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

.brand {
  font-weight: 650;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
}

.site-header nav {
  display: flex;
  gap: 1.5rem;
  font-size: 0.95rem;
}

.site-footer {
  margin-top: 5rem;
  padding-block: 2.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.875rem;
}

.site-footer p {
  margin: 0.35rem 0;
}

/* ---------------------------------------------------------------- landing */

.hero {
  padding-block: clamp(2.5rem, 8vw, 5.5rem) 2rem;
  max-width: 800px;
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 6vw, 3.25rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.lede {
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  color: var(--muted);
  max-width: 58ch;
}

.cta {
  margin-top: 2rem;
}

.button {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-text);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
}

.button:hover {
  filter: brightness(1.08);
}

.fine {
  color: var(--muted);
  font-size: 0.9rem;
}

.features h2,
.privacy-note h2 {
  font-size: 1.5rem;
  letter-spacing: -0.015em;
  margin-bottom: 1.5rem;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.925rem;
}

.privacy-note {
  margin-top: 4rem;
  max-width: var(--measure);
}

/* ---------------------------------------------------------------- prose */

.prose {
  max-width: var(--measure);
  padding-block: 1rem 2rem;
}

.prose.narrow {
  max-width: 62ch;
}

.prose h1 {
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.prose h2 {
  margin-top: 2.5rem;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

.prose h3 {
  margin-top: 1.75rem;
  font-size: 1.05rem;
}

.prose ul {
  padding-left: 1.25rem;
}

.prose li {
  margin-block: 0.4rem;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.925rem;
}

.prose th,
.prose td {
  border: 1px solid var(--border);
  padding: 0.5rem 0.65rem;
  text-align: left;
}

.callout {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
}

/* Language switcher on the policy pages. */
.locales {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  padding-block: 0.5rem 1.5rem;
  font-size: 0.9rem;
}

.locales [aria-current="page"] {
  color: var(--muted);
  font-weight: 600;
}

/* Support-page question headings sit tighter to their answers than prose h3. */
.prose h3 + p {
  margin-top: 0.35rem;
}
