:root {
  --ink: #1f2328;
  --muted: #6b7280;
  --border: #e5e7eb;
  --accent: #2563eb;
  --bg: #ffffff;
  --paper: #ffffff;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e5e7eb;
    --muted: #9ca3af;
    --border: #374151;
    --accent: #60a5fa;
    --bg: #111827;
    --paper: #1f2937;
  }
}

* { box-sizing: border-box; }
html {
    height: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  color: var(--ink);
  line-height: 1.75;
  font-size: 18px;
  background-color: var(--bg);
  min-height: 100%;
  display: grid;
  grid-template-rows: auto 1fr auto;
}
.site-header, .site-footer {
    width: 90%;
    max-width: 1024px;
  margin: 0 auto;
  padding: 24px 20px;
  background-color: var(--paper);
}
.site-header {
  border-bottom: 1px solid var(--border);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.site-header h1 { font-size: 1.4em; margin: 0; }
.site-header a { color: var(--ink); text-decoration: none; }
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 60px;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  color: var(--muted);
}

.site-main { width: 90%; max-width: 1024px; margin: 40px auto; padding: 0 20px; }

.post-list { display: flex; flex-direction: column; gap: 28px; }
.post-summary h2 { margin: 0 0 4px; font-size: 1.5em; }
.post-summary a { color: var(--ink); text-decoration: none; }
.post-summary a:hover { text-decoration: underline; }
.post-date { font-family: system-ui, sans-serif; font-size: 13px; color: var(--muted); }
.empty { color: var(--muted); font-family: system-ui, sans-serif; }

.post-full h1 { font-family: system-ui, sans-serif; font-size: 2.1em; line-height: 1.2; margin-bottom: 0.2em; }
.post-full .post-date { margin-bottom: 1.5em; }
.post-content img { max-width: 100%; height: auto; border-radius: 6px; }
.post-content audio { display: block; width: 100%; max-width: 480px; margin: 1em 0; }
.post-content blockquote {
  margin: 1.5em 0;
  padding-left: 1em;
  border-left: 3px solid var(--border);
  color: var(--muted);
  font-style: italic;
}

.post-content pre { background: var(--paper); padding: 14px; border-radius: 8px; overflow-x: auto; font-size: 0.85em; color: var(--ink); }
.post-content code { background: var(--paper); padding: 0.15em 0.4em; border-radius: 4px; font-size: 0.9em; color: var(--ink); }
.post-content a { color: var(--accent); }
.post-content hr { border: none; border-top: 1px solid var(--border); margin: 2em 0; }

.preview-banner {
  background: #fef9c3;
  color: #713f12;
  font-family: system-ui, sans-serif;
  font-size: 13px;
  padding: 8px 14px;
  border-radius: 6px;
  margin-bottom: 24px;
}

@media (prefers-color-scheme: dark) {
  .preview-banner {
    background: #452608;
    color: #fef9c3;
  }
}
