:root {
  color-scheme: light dark;
  --background: #f7f7fb;
  --surface: #ffffff;
  --text: #20212a;
  --muted: #626575;
  --brand: #7568e8;
  --border: #dedfea;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #15151d;
    --surface: #1e1f29;
    --text: #f2f2f7;
    --muted: #b7b8c6;
    --brand: #a39af8;
    --border: #353644;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-size: 16px;
  line-height: 1.7;
}

main {
  width: min(920px, calc(100% - 32px));
  margin: 48px auto;
  padding: clamp(24px, 5vw, 56px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 12px 36px rgb(20 20 40 / 8%);
}

h1,
h2,
h3 {
  line-height: 1.25;
}

h1 {
  margin-top: 0;
  font-size: clamp(2rem, 5vw, 3rem);
}

h2 {
  margin-top: 2.25rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

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

table {
  display: block;
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
}

th,
td {
  padding: 12px 14px;
  border: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

blockquote {
  margin-left: 0;
  padding: 12px 18px;
  color: var(--muted);
  border-left: 4px solid var(--brand);
  background: color-mix(in srgb, var(--brand) 8%, transparent);
}

hr {
  margin: 2rem 0;
  border: 0;
  border-top: 1px solid var(--border);
}

@media (max-width: 640px) {
  main {
    width: 100%;
    margin: 0;
    border: 0;
    border-radius: 0;
  }
}
