/* ============================================
   Anders Reality — Cyborg Journal
   Three-column layout: robot | content | robot
   Dark terminal aesthetic. Raw. Digital notebook.
   ============================================ */

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

:root {
  --bg: #1e2330;
  --bg-surface: #252a3a;
  --text: #c8c8cc;
  --text-dim: #7a7a80;
  --text-muted: #4a4a50;
  --accent: #3ecf8e;
  --accent-dim: rgba(62, 207, 142, 0.15);
  --border: rgba(255, 255, 255, 0.05);
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
  --font-body: 'Inter', -apple-system, sans-serif;
  --max-width: 640px;
  --panel-width: 250px;
}

html { -webkit-font-smoothing: antialiased; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
}

/* ── Three-Column Layout ────────────── */
.layout-three-col {
  display: flex;
  justify-content: center;
  min-height: 100vh;
}

.robot-panel {
  width: var(--panel-width);
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  background-size: 200% 100%;
  background-repeat: no-repeat;
  background-image: url('../img/robots.webp');
  opacity: 0.7;
}

.robot-panel--left {
  background-position: left center;
}

.robot-panel--right {
  background-position: right center;
}

/* ── Layout ──────────────────────────── */
.page {
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 4rem 0;
  border-top: 1px solid var(--border);
}

.section:first-of-type {
  border-top: none;
  padding-top: 6rem;
}

/* ── Logo / Header ───────────────────── */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(30, 35, 48, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.logo {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--accent);
  text-decoration: none;
}

.logo-dim {
  color: var(--text-muted);
}

.header-status {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.pulse {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 6px;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ── Typography ──────────────────────── */
h1 {
  font-family: var(--font-body);
  font-size: 36px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
  letter-spacing: -0.01em;
}

h2 {
  font-family: var(--font-mono);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.prose {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--text-dim);
}

.prose p { margin-bottom: 1.25rem; }
.prose p:last-child { margin-bottom: 0; }

.prose em {
  font-style: italic;
  color: var(--text);
}

/* ── Concept Block ───────────────────── */
.concept {
  border-left: 2px solid var(--accent);
  padding: 1.25rem 1.5rem;
  background: var(--bg-surface);
  border-radius: 0 4px 4px 0;
  margin: 2rem 0;
}

.concept p {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.7;
  color: var(--text);
  margin: 0;
}

/* ── Journal Entries ─────────────────── */
.journal-list {
  list-style: none;
}

.journal-entry {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
}

.journal-entry:last-child { border-bottom: none; }

.journal-date {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.journal-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  display: block;
  margin-bottom: 1rem;
}

.journal-title:hover { color: var(--accent); }

.journal-excerpt {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.7;
}

.journal-excerpt p {
  margin-bottom: 1rem;
}

.journal-excerpt p:last-of-type {
  margin-bottom: 1.25rem;
}

.journal-read-more {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.journal-read-more:hover {
  text-decoration: underline;
}

/* ── Empty State ─────────────────────── */
.empty-state {
  border: 1px dashed var(--border);
  border-radius: 4px;
  padding: 3rem 2rem;
  text-align: center;
}

.empty-state p {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.8;
}

/* ── Footer ──────────────────────────── */
.site-footer {
  padding: 3rem 0;
  border-top: 1px solid var(--border);
  margin-top: 2rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.footer-links a {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

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

.footer-copy {
  font-size: 0.6rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ── Entry Page ─────────────────────── */
.entry-nav {
  margin-bottom: 1rem;
}

.entry-back {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.entry-back:hover { color: var(--accent); }

.entry-header {
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2.5rem;
}

.entry-title {
  font-family: var(--font-body);
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--text);
  margin: 0.75rem 0 1rem;
  line-height: 1.4;
}

.entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.entry-body {
  padding-bottom: 3rem;
}

.entry-body p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--text-dim);
  margin-bottom: 1.25rem;
}

.entry-body p:last-child { margin-bottom: 0; }

.entry-body code {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  background: var(--accent-dim);
  padding: 0.15em 0.4em;
  border-radius: 3px;
}

.entry-body em { color: var(--text); }

.entry-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

.entry-colophon {
  font-size: 0.85rem !important;
  color: var(--text-muted) !important;
  font-style: italic;
}

.entry-nav-footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
}

/* ── Scroll Reveal ───────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Responsive ──────────────────────── */
@media (max-width: 960px) {
  .robot-panel {
    display: none;
  }

  .layout-three-col {
    display: block;
  }

  .page {
    padding: 0 1.5rem;
  }
}

@media (max-width: 640px) {
  .section { padding: 3rem 0; }
  .section:first-of-type { padding-top: 5rem; }
  h1 { font-size: 1.6rem; }
  .journal-title { font-size: 1.2rem; }
  .site-header { padding: 1rem 1.25rem; }
}
