@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400&display=swap');

:root {
  --bg: #080808;
  --bg2: #0f0f0f;
  --bg3: #141414;
  --amber: #D4920A;
  --amber-bright: #F0AA15;
  --amber-dim: #7A5408;
  --amber-faint: #2A1C04;
  --white: #E8E0D0;
  --grey: #6A6058;
  --grey-light: #9A9088;
  --border: #221A08;
  --font: 'JetBrains Mono', 'Courier New', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* CRT scanline overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,0.08) 2px, rgba(0,0,0,0.08) 4px);
  pointer-events: none;
  z-index: 1000;
}

/* Vignette */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 60%, rgba(0,0,0,0.5) 100%);
  pointer-events: none;
  z-index: 999;
}

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--amber-dim); }
::selection { background: var(--amber); color: var(--bg); }

.amber { color: var(--amber); }
.amber-bright { color: var(--amber-bright); }
.dim { color: var(--grey); }
.comment { color: var(--amber-dim); font-style: italic; }

@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: 0; } }
.cursor {
  display: inline-block;
  width: 9px; height: 16px;
  background: var(--amber);
  vertical-align: text-bottom;
  animation: blink 1.1s step-end infinite;
  margin-left: 2px;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in { opacity: 0; animation: fadeUp 0.6s ease forwards; }
.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.35s; }
.delay-3 { animation-delay: 0.55s; }
.delay-4 { animation-delay: 0.75s; }
.delay-5 { animation-delay: 0.95s; }

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

/* STATUS BAR */
.statusbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 10px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: 0.06em;
}
.statusbar-left { display: flex; align-items: center; gap: 20px; }
.statusbar-logo {
  color: var(--amber-bright);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.05em;
  text-decoration: none;
}
.statusbar-logo:hover { color: var(--white); }
.status-dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--amber);
  animation: blink 2s ease-in-out infinite;
  margin-right: 6px;
  vertical-align: middle;
}
.statusbar-nav { display: flex; gap: 24px; }
.statusbar-nav a {
  color: var(--grey);
  text-decoration: none;
  transition: color 0.2s;
  font-size: 11px;
}
.statusbar-nav a:hover { color: var(--amber-bright); }
.statusbar-nav a.active { color: var(--amber); }
.statusbar-nav a::before { content: './'; color: var(--amber-dim); }

/* SECTIONS */
section { padding: 88px 0; border-bottom: 1px solid var(--border); }
section:last-of-type { border-bottom: none; }

.section-header { margin-bottom: 52px; }
.section-label {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--amber-dim);
  margin-bottom: 10px;
}
.section-label::before { content: '// '; }
.section-title {
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.02em;
}

/* PROGRESS BAR */
#progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  background: var(--amber);
  width: 0%;
  z-index: 600;
  transition: width 0.05s linear;
}

/* FOOTER */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 24px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--grey);
  max-width: 860px;
  margin: 0 auto;
}
.site-footer a { color: var(--grey); text-decoration: none; }
.site-footer a:hover { color: var(--amber); }

/* TERMINAL BLOCK */
.terminal-block {
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 20px 22px;
  font-size: 12px;
  line-height: 1.8;
  margin-top: 28px;
}
.terminal-block .tl { color: var(--amber-dim); }

/* PROSE (for essay pages) */
.prose {
  font-size: 15px;
  color: var(--grey-light);
  line-height: 1.9;
  max-width: 680px;
}
.prose p { margin-bottom: 1.4em; }
.prose h2 {
  font-size: 18px;
  color: var(--white);
  font-weight: 700;
  margin: 2em 0 0.7em;
  letter-spacing: -0.01em;
}
.prose h3 {
  font-size: 15px;
  color: var(--amber);
  font-weight: 500;
  margin: 1.6em 0 0.5em;
}
.prose strong { color: var(--white); font-weight: 500; }
.prose em { color: var(--amber-dim); font-style: italic; }
.prose a { color: var(--amber); text-decoration: none; border-bottom: 1px solid var(--amber-dim); }
.prose a:hover { color: var(--amber-bright); border-color: var(--amber-bright); }
.prose blockquote {
  border-left: 2px solid var(--amber-dim);
  padding-left: 18px;
  color: var(--grey);
  margin: 1.5em 0;
  font-style: italic;
}
.prose ul, .prose ol { padding-left: 22px; margin-bottom: 1.2em; }
.prose li { margin-bottom: 0.4em; }
.prose code {
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 1px 6px;
  font-size: 12px;
  color: var(--amber);
}
.prose pre {
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 18px;
  overflow-x: auto;
  margin: 1.5em 0;
}
.prose hr { border: none; border-top: 1px solid var(--border); margin: 2em 0; }

/* BACK LINK */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--grey);
  text-decoration: none;
  margin-bottom: 40px;
  margin-top: 100px;
  transition: color 0.2s;
}
.back-link:hover { color: var(--amber); }

/* RESPONSIVE */
@media (max-width: 520px) {
  .statusbar-nav { display: none; }
}
