:root {
  --bg: #0a0a0a;
  --bg-elev: #141414;
  --bg-card: #1a1a1a;
  --neon: #ff6b00;
  --neon-bright: #ff8533;
  --neon-glow: rgba(255, 107, 0, 0.25);
  --neon-line: rgba(255, 107, 0, 0.4);
  --text: #f5f5f5;
  --text-soft: #d0d0d0;
  --muted: #888;
  --muted-dark: #555;
  --border: #2a2a2a;
  --border-strong: #3a3a3a;
  --code-bg: #0f0f0f;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  background-image:
    radial-gradient(circle at 15% 10%, var(--neon-glow) 0%, transparent 30%),
    radial-gradient(circle at 85% 80%, rgba(255, 107, 0, 0.08) 0%, transparent 40%);
  background-attachment: fixed;
}

.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Header ── */
header.site-header {
  border-bottom: 1px solid var(--border);
  padding: 48px 0 32px;
  margin-bottom: 48px;
  position: relative;
}

header.site-header::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--neon), transparent);
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.brand-mark {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 13px;
  color: var(--neon);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.brand-mark::before {
  content: '▸ ';
  opacity: 0.7;
}

.brand-title {
  font-size: 32px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.5px;
}

.brand-title .accent {
  color: var(--neon);
  text-shadow: 0 0 16px var(--neon-glow);
}

.brand-tagline {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  max-width: 600px;
}

/* ── Posts listing (home) ── */
.posts-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 80px;
}

.post-card {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-left: 3px solid var(--neon);
  padding: 24px 28px;
  border-radius: 4px;
  transition: all 0.2s ease;
  text-decoration: none;
  color: inherit;
  display: block;
}

.post-card:hover {
  border-color: var(--neon);
  background: var(--bg-card);
  transform: translateX(2px);
  box-shadow: -3px 0 12px var(--neon-glow);
}

.post-card-date {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--neon);
  letter-spacing: 1.5px;
  margin-bottom: 8px;
}

.post-card-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  line-height: 1.3;
}

.post-card-hook {
  color: var(--text-soft);
  font-size: 15px;
  line-height: 1.55;
}

.post-card-tags {
  margin-top: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tag {
  background: rgba(255, 107, 0, 0.1);
  color: var(--neon-bright);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 3px;
  font-family: 'JetBrains Mono', monospace;
  border: 1px solid rgba(255, 107, 0, 0.2);
}

/* ── Post detail ── */
article.post {
  padding-bottom: 80px;
}

.post-meta {
  font-family: 'JetBrains Mono', monospace;
  color: var(--neon);
  font-size: 13px;
  letter-spacing: 1.5px;
  margin-bottom: 16px;
}

.post-title {
  font-size: 38px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 24px;
  letter-spacing: -0.5px;
}

.post-hook {
  font-size: 19px;
  color: var(--text-soft);
  line-height: 1.5;
  padding: 20px 24px;
  background: var(--bg-elev);
  border-left: 3px solid var(--neon);
  border-radius: 0 4px 4px 0;
  margin-bottom: 40px;
  font-weight: 400;
}

.post section {
  margin-bottom: 40px;
}

.post h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--neon);
  margin-bottom: 16px;
  text-shadow: 0 0 12px var(--neon-glow);
  display: flex;
  align-items: center;
  gap: 12px;
}

.post h2::before {
  content: '#';
  font-family: 'JetBrains Mono', monospace;
  color: var(--muted-dark);
  font-weight: 400;
}

.post section .content {
  color: var(--text-soft);
  font-size: 16px;
  line-height: 1.75;
}

.post section .content p {
  margin-bottom: 14px;
}

.post section .content ul,
.post section .content ol {
  margin-bottom: 16px;
  padding-left: 22px;
}

.post section .content li {
  margin-bottom: 6px;
}

.post section .content strong {
  color: var(--text);
  font-weight: 700;
}

.post section .content em {
  color: var(--neon-bright);
  font-style: normal;
  border-bottom: 1px dashed var(--neon-line);
  padding-bottom: 1px;
}

.post section .content code {
  background: var(--code-bg);
  color: var(--neon-bright);
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.92em;
  border: 1px solid var(--border);
}

.post section .content a {
  color: var(--neon);
  text-decoration: none;
  border-bottom: 1px dotted var(--neon-line);
}

.post section .content a:hover {
  color: var(--neon-bright);
  border-bottom-color: var(--neon-bright);
}

.post-tags {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.post-nav {
  margin-top: 40px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.post-nav a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
  font-family: 'JetBrains Mono', monospace;
}

.post-nav a:hover {
  color: var(--neon);
}

/* ── Footer ── */
footer.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  margin-top: 80px;
  text-align: center;
  color: var(--muted-dark);
  font-size: 13px;
  font-family: 'JetBrains Mono', monospace;
}

footer.site-footer .accent {
  color: var(--neon);
}

footer .links {
  margin-top: 8px;
  display: flex;
  justify-content: center;
  gap: 16px;
}

footer .links a {
  color: var(--muted);
  text-decoration: none;
}

footer .links a:hover {
  color: var(--neon);
}

/* ── Mobile ── */
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .brand-title { font-size: 24px; }
  .post-title { font-size: 28px; }
  .post-hook { font-size: 16px; padding: 16px 18px; }
  .post h2 { font-size: 19px; }
  header.site-header { padding: 32px 0 24px; margin-bottom: 32px; }
}

/* ── Reduce motion ── */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  html { scroll-behavior: auto; }
}
