:root {
  --bg: #ffffff;
  --fg: #1a1a1a;
  --muted: #666;
  --accent: #0b6e4f;
  --code-bg: #f4f4f2;
  --border: #e2e2e0;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131313;
    --fg: #e6e6e3;
    --muted: #9a9a96;
    --accent: #5fd3a5;
    --code-bg: #1e1e1c;
    --border: #2c2c2a;
  }
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  border-top: 3px solid var(--accent);
}
main {
  max-width: 42rem;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 5rem;
}
h1 { font-size: 1.9rem; line-height: 1.25; margin: 0.5rem 0 0.25rem; }
h2 { font-size: 1.25rem; margin-top: 2.2rem; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.meta { color: var(--muted); font-size: 0.9rem; margin-bottom: 2rem; }
.site-header { margin-bottom: 2.5rem; }
.site-header a { color: var(--fg); font-weight: 600; }
.site-header a.wordmark {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-weight: 700;
  font-size: 1.05rem;
}
.site-header .tld { color: var(--accent); }
.site-header .tag { color: var(--muted); font-size: 0.95rem; }
ul.post-list { list-style: none; padding: 0; }
ul.post-list li { margin: 1.2rem 0; }
ul.post-list .date { color: var(--muted); font-size: 0.85rem; display: block; }
blockquote {
  margin: 1.5rem 0; padding: 0.1rem 1.1rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}
pre {
  position: relative;
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.1rem;
  overflow-x: auto;
  font-size: 0.85rem;
  line-height: 1.5;
}
code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }
.copy-btn {
  position: absolute; top: 0.5rem; right: 0.5rem;
  font-size: 0.75rem; padding: 0.25rem 0.6rem;
  background: var(--bg); color: var(--fg);
  border: 1px solid var(--border); border-radius: 6px;
  cursor: pointer;
}
.copy-btn:hover { border-color: var(--accent); color: var(--accent); }
hr { border: none; border-top: 1px solid var(--border); margin: 2.5rem 0; }
table { border-collapse: collapse; width: 100%; margin: 1.2rem 0; font-size: 0.88rem; }
th, td { border: 1px solid var(--border); padding: 0.45rem 0.6rem; text-align: left; vertical-align: top; }
th { background: var(--code-bg); font-weight: 650; }
figure.diagram { margin: 1.8rem 0; cursor: zoom-in; }
figure.diagram svg { width: 100%; height: auto; }
figure.diagram figcaption { color: var(--muted); font-size: 0.8rem; text-align: center; margin-top: 0.4rem; }
dialog.lightbox {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem;
  background: var(--bg);
  width: min(96vw, 1400px);
  max-width: none;
  cursor: zoom-out;
}
dialog.lightbox::backdrop { background: rgba(0, 0, 0, 0.55); }
dialog.lightbox svg { width: 100%; height: auto; max-height: 92vh; }
footer.bio { color: var(--muted); font-size: 0.95rem; font-style: italic; }
.copyright {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.8rem;
  font-style: normal;
}
strong { font-weight: 650; }

.contact { color: var(--muted); font-size: 0.95rem; margin-top: 1.5rem; }
