:root {
  --bg: #0c1222;
  --surface: #141e33;
  --text: #e8edf7;
  --muted: #8b9ab8;
  --accent: #f97316;
  --accent-dim: #c2410c;
  --border: #243049;
  --broken: #f87171;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(12, 18, 34, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 1.25rem;
}
.brand {
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}
.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
}
.nav-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.85rem;
}
.nav-link:hover, .nav-link.active {
  color: var(--accent);
}
.content {
  max-width: 920px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
}
.page-title {
  font-size: 1.75rem;
  margin: 0 0 1.25rem;
  color: var(--text);
}
h2, h3 { color: var(--text); margin-top: 1.75rem; }
h2 { font-size: 1.25rem; border-bottom: 1px solid var(--border); padding-bottom: 0.35rem; }
h3 { font-size: 1.05rem; color: var(--accent); }
p, li { color: #d5ddea; }
ul, ol { padding-left: 1.25rem; }
li { margin: 0.35rem 0; }
a { color: var(--accent); }
a:hover { color: #fdba74; }
code, pre {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
}
code { padding: 0.1rem 0.35rem; font-size: 0.9em; }
pre {
  padding: 1rem;
  overflow-x: auto;
  white-space: pre-wrap;
}
.note-link, .img-link {
  font-weight: 600;
}
.broken-link {
  color: var(--broken);
  font-family: monospace;
  font-size: 0.9em;
}
.screenshot {
  margin: 1.25rem 0;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.screenshot img {
  display: block;
  width: 100%;
  max-width: 420px;
  height: auto;
  cursor: zoom-in;
}
.screenshot figcaption {
  padding: 0.5rem 0.75rem;
  font-size: 0.8rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
}
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}
.lightbox[hidden] { display: none; }
.lightbox-img {
  max-width: min(96vw, 520px);
  max-height: 92vh;
  border-radius: 8px;
}
.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: transparent;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
}
@media (min-width: 900px) {
  .site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .brand { margin-bottom: 0; }
}
