:root {
  color-scheme: light dark;
  --text: #1f2328;
  --muted: #59636e;
  --background: #ffffff;
  --surface: #f6f8fa;
  --border: #d1d9e0;
  --accent: #9a4a12;
  --code: #eff2f5;
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #e6edf3;
    --muted: #9198a1;
    --background: #0d1117;
    --surface: #151b23;
    --border: #3d444d;
    --accent: #f0a060;
    --code: #1f2630;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", sans-serif;
}

a {
  color: var(--accent);
}

header {
  display: flex;
  gap: 1.5rem;
  align-items: baseline;
  padding: 0.75rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

header a {
  text-decoration: none;
}

header .brand {
  margin-right: auto;
  color: var(--text);
  font-weight: 700;
  font-size: 1.2rem;
}

main {
  max-width: 60rem;
  margin: 0 auto;
  padding: 1.5rem;
}

h1 {
  margin-top: 0;
  line-height: 1.25;
}

code {
  padding: 0.1em 0.35em;
  border-radius: 4px;
  background: var(--code);
  font: 0.9em/1.5 ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

.projects {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.projects article {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
}

.projects h2 {
  margin: 0 0 0.25rem;
  font-size: 1.2rem;
}

.projects p {
  margin: 0.5rem 0 0;
}

.projects .links {
  display: flex;
  gap: 1rem;
  margin-top: auto;
  padding-top: 0.75rem;
}

.projects .links a {
  text-decoration: none;
  font-weight: 600;
}

@media (max-width: 48rem) {
  header,
  main {
    padding: 0.75rem 1rem;
  }
}
