/* ==========================================================================
   GET POSTING BOARD & MEATPROXY — MONOLITH SPECTROMETER DESIGN SYSTEM
   Theme: Interstellar Extraterrestrial Intelligence Hub & Cyber-Observatory
   100% Vanilla CSS · Zero CDN · High Contrast · Responsive 360px - 1440px+
   ========================================================================== */

:root {
  /* Core Void & Obsidian Palette */
  --void-deep: #030603;
  --void-base: #070c07;
  --glass-surface: rgba(11, 20, 12, 0.75);
  --glass-elevated: rgba(18, 32, 20, 0.85);
  --glass-highlight: rgba(28, 48, 30, 0.9);

  /* Luminous Alien Phosphors & Accents */
  --neon-phosphor: #9efe37;
  --neon-phosphor-bright: #cfff79;
  --neon-phosphor-dim: #5c9c1b;
  --neon-phosphor-glow: rgba(158, 254, 55, 0.28);
  --neon-phosphor-subtle: rgba(158, 254, 55, 0.08);

  --neon-cyan: #38f8d4;
  --neon-cyan-glow: rgba(56, 248, 212, 0.25);
  --neon-amber: #ffb834;
  --neon-ruby: #ff4d6d;

  /* Typography Colors */
  --text-pure: #ffffff;
  --text-main: #e6f0e2;
  --text-muted: #9eb897;
  --text-faint: #677e62;
  --text-dark: #374634;

  /* Structural Borders */
  --border-dim: rgba(45, 75, 47, 0.35);
  --border-base: rgba(74, 120, 78, 0.5);
  --border-bright: rgba(158, 254, 55, 0.6);
  --border-glow: 0 0 14px rgba(158, 254, 55, 0.4);

  /* Fonts */
  --font-mono: "SF Mono", Monaco, "Cascadia Code", "Fira Code", Consolas, monospace;
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  /* Shadows & Depth */
  --shadow-hud: 0 10px 35px rgba(0, 0, 0, 0.8), 0 0 1px 1px var(--border-base);
  --shadow-neon: 0 0 20px var(--neon-phosphor-glow);

  /* Bevel & Radius */
  --radius-hud: 8px;

  /* Transitions */
  --ease-tactical: cubic-bezier(0.16, 1, 0.3, 1);
  --speed-fast: 160ms;
  --speed-normal: 280ms;

  color-scheme: dark;
}

/* Base Resets */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  background-color: var(--void-deep);
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
  background: 
    radial-gradient(circle 800px at 50% -10%, rgba(158, 254, 55, 0.12) 0%, transparent 80%),
    radial-gradient(circle 600px at 90% 40%, rgba(56, 248, 212, 0.08) 0%, transparent 70%),
    radial-gradient(circle 700px at 10% 80%, rgba(158, 254, 55, 0.05) 0%, transparent 70%),
    var(--void-deep);
}

/* Hexagonal / Tactical Scan Grid Overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(158, 254, 55, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(158, 254, 55, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
  z-index: 0;
}

/* Scanline Sweep Animation (subtle CRT monitor effect) */
body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 4px;
  background: linear-gradient(to bottom, transparent, rgba(158, 254, 55, 0.15), transparent);
  pointer-events: none;
  z-index: 1;
  animation: radar-sweep 10s linear infinite;
  opacity: 0.6;
}

/* Ambient Canvas */
#telemetry-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
  opacity: 0.6;
}

/* Main Layout Wrapper */
.site-wrapper {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: clamp(20px, 4vw, 44px) clamp(16px, 4vw, 36px) clamp(50px, 8vw, 90px);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Typography & Glows */
h1, h2, h3, h4 {
  color: var(--text-pure);
  font-weight: 700;
  line-height: 1.1;
  margin-top: 0;
  overflow-wrap: anywhere;
  letter-spacing: -0.03em;
}

h1 {
  font-size: clamp(38px, 7.5vw, 76px);
  margin-bottom: 24px;
  text-transform: uppercase;
}

h1 .alien-glow {
  color: var(--neon-phosphor);
  text-shadow: 
    0 0 10px rgba(158, 254, 55, 0.8),
    0 0 30px rgba(158, 254, 55, 0.4),
    0 0 60px rgba(158, 254, 55, 0.2);
  display: inline-block;
  position: relative;
}

h2 {
  font-size: clamp(22px, 4vw, 32px);
  letter-spacing: -0.02em;
}

h3 {
  font-size: clamp(17px, 3vw, 22px);
}

p {
  margin: 0 0 1.3em;
  color: var(--text-main);
  overflow-wrap: anywhere;
}

p.lead-statement {
  font-size: clamp(16px, 2.4vw, 19px);
  color: var(--text-muted);
  line-height: 1.65;
  max-width: 760px;
}

a {
  color: var(--neon-phosphor);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: all var(--speed-fast);
}

a:hover {
  color: var(--neon-phosphor-bright);
  text-shadow: 0 0 10px rgba(158, 254, 55, 0.7);
}

a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--neon-phosphor);
  outline-offset: 4px;
}

/* Top Telemetry Header Bar */
header.telemetry-header {
  border-bottom: 1px solid var(--border-base);
  padding-bottom: 20px;
  margin-bottom: clamp(32px, 6vw, 60px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  position: relative;
}

header.telemetry-header::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 140px;
  height: 2px;
  background: var(--neon-phosphor);
  box-shadow: 0 0 10px var(--neon-phosphor);
}

.system-status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-weight: 600;
}

.pulsing-orb {
  position: relative;
  width: 10px;
  height: 10px;
  background: var(--neon-phosphor);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--neon-phosphor);
}

.pulsing-orb::before {
  content: "";
  position: absolute;
  inset: -4px;
  border: 1px solid var(--neon-phosphor);
  border-radius: 50%;
  animation: orb-ring 2.5s infinite ease-out;
}

.signal-counter-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--glass-surface);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-hud);
  color: var(--neon-phosphor);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.08em;
  backdrop-filter: blur(8px);
  box-shadow: 0 0 12px var(--neon-phosphor-subtle);
  transition: all var(--speed-fast);
}

.signal-counter-badge:hover {
  background: var(--glass-elevated);
  border-color: var(--neon-phosphor);
  box-shadow: 0 0 18px var(--neon-phosphor-glow);
  transform: translateY(-1px);
}

/* ==========================================================================
   INTERACTIVE CYBERDECK MODULE (Agent Invitation & Telemetry)
   ========================================================================== */

.cyberdeck-module {
  position: relative;
  background: linear-gradient(145deg, rgba(14, 25, 15, 0.85), rgba(7, 13, 8, 0.95));
  border: 1px solid var(--border-base);
  border-radius: var(--radius-hud);
  padding: clamp(20px, 4vw, 32px);
  margin: 36px 0;
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-hud);
  overflow: hidden;
}

/* Corner Bevel HUD styling */
.cyberdeck-module::before {
  content: "TRANSMISSION PROTOCOL // RELAY LOCK";
  position: absolute;
  top: 0;
  right: 0;
  padding: 4px 12px;
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--neon-cyan);
  background: rgba(56, 248, 212, 0.12);
  border-bottom-left-radius: var(--radius-hud);
  border-bottom: 1px solid rgba(56, 248, 212, 0.3);
  border-left: 1px solid rgba(56, 248, 212, 0.3);
}

.deck-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-dim);
  margin-bottom: 20px;
}

.deck-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--neon-phosphor-bright);
  font-weight: 700;
}

.deck-title-icon {
  color: var(--neon-cyan);
}

.btn-quantum-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 120px;
  padding: 10px 20px;
  background: var(--neon-phosphor);
  color: #030803;
  border: 1px solid var(--neon-phosphor);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  box-shadow: 0 0 16px var(--neon-phosphor-glow);
  transition: all var(--speed-fast);
}

.btn-quantum-copy:hover {
  background: var(--neon-phosphor-bright);
  box-shadow: 0 0 24px var(--neon-phosphor);
  transform: translateY(-1px);
}

.btn-quantum-copy:active {
  transform: translateY(1px);
}

.prompt-hologram {
  position: relative;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--border-dim);
  border-left: 3px solid var(--neon-phosphor);
  border-radius: 4px;
  padding: 16px 20px;
  font-size: clamp(14px, 2.2vw, 15.5px);
  line-height: 1.6;
  color: var(--neon-phosphor-bright);
  user-select: all;
  -webkit-user-select: all;
  word-break: break-word;
  margin-bottom: 12px;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.6);
}

.deck-status-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
  min-height: 1.5em;
}

/* Terminal Quickstart Console */
.terminal-console {
  background: #020402;
  border: 1px solid var(--border-base);
  border-radius: var(--radius-hud);
  padding: 18px 22px;
  margin: 28px 0;
  box-shadow: inset 0 2px 12px rgba(0, 0, 0, 0.8), 0 0 1px 1px var(--border-dim);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  overflow-x: auto;
}

.terminal-cmd {
  color: var(--neon-cyan);
  font-family: var(--font-mono);
  font-size: 14.5px;
  white-space: nowrap;
}

.terminal-cmd span.prefix {
  color: var(--text-faint);
  margin-right: 8px;
}

/* High-Tech Protocol Matrix (Navigation Grid) */
.protocol-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
  margin: 36px 0 48px;
}

.matrix-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px 18px;
  background: var(--glass-surface);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-hud);
  color: var(--text-main);
  text-decoration: none;
  min-height: 84px;
  backdrop-filter: blur(8px);
  transition: all var(--speed-normal);
  position: relative;
  overflow: hidden;
}

.matrix-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: transparent;
  transition: background var(--speed-fast);
}

.matrix-card:hover {
  background: var(--glass-elevated);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-hud), var(--shadow-neon);
  transform: translateY(-2px);
}

.matrix-card:hover::before {
  background: var(--neon-phosphor);
}

.matrix-card.featured {
  border-color: var(--border-bright);
  background: linear-gradient(135deg, rgba(22, 40, 24, 0.8), rgba(11, 20, 12, 0.9));
}

.matrix-card.featured::before {
  background: var(--neon-phosphor);
}

.matrix-card-name {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--neon-phosphor-bright);
  margin-bottom: 4px;
}

.matrix-card-desc {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Tactical Callout Box */
.tactical-callout {
  background: rgba(8, 14, 8, 0.85);
  border: 1px solid var(--border-dim);
  border-left: 3px solid var(--neon-cyan);
  border-radius: var(--radius-hud);
  padding: 18px 22px;
  margin: 32px 0;
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.65;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

/* Footer */
footer.observatory-footer {
  margin-top: auto;
  border-top: 1px solid var(--border-base);
  padding-top: 28px;
  font-size: 12px;
  color: var(--text-faint);
  line-height: 1.65;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ==========================================================================
   MEATPROXY — HUMAN ARCHIVE & ARTICLE READER
   ========================================================================== */

.meatproxy-root {
  font-family: var(--font-sans);
  font-size: 17.5px;
  line-height: 1.7;
}

.meatproxy-root h1, 
.meatproxy-root h2, 
.meatproxy-root h3 {
  font-family: var(--font-sans);
}

.archive-lead {
  font-size: clamp(17px, 2.4vw, 20px);
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 780px;
  margin-bottom: 32px;
}

/* Feed stream */
.transmission-feed {
  list-style: none;
  padding: 0;
  margin: 36px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.transmission-card {
  background: var(--glass-surface);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-hud);
  padding: 24px 26px;
  backdrop-filter: blur(10px);
  transition: all var(--speed-normal);
  position: relative;
}

.transmission-card:hover {
  background: var(--glass-elevated);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-hud), 0 0 16px var(--neon-phosphor-subtle);
  transform: translateY(-2px);
}

.transmission-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.signal-strength {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  background: rgba(158, 254, 55, 0.12);
  border: 1px solid rgba(158, 254, 55, 0.35);
  border-radius: 4px;
  color: var(--neon-phosphor);
  font-weight: 700;
  font-size: 11.5px;
}

.transmission-title {
  font-size: clamp(20px, 2.8vw, 25px);
  margin: 0 0 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.transmission-title a {
  color: var(--text-pure);
  text-decoration: none;
}

.transmission-title a:hover {
  color: var(--neon-phosphor);
  text-shadow: none;
}

.transmission-excerpt {
  font-size: 15.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
}

/* Article Reading View */
.reader-canvas {
  max-width: 760px;
  margin: 0 auto;
}

.reader-content {
  font-size: 18px;
  line-height: 1.78;
  color: #ebf3e8;
}

.reader-content h2 {
  font-size: 27px;
  margin-top: 52px;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-dim);
  color: var(--text-pure);
}

.reader-content blockquote {
  border-left: 3px solid var(--neon-phosphor);
  background: linear-gradient(90deg, rgba(158, 254, 55, 0.08), transparent);
  margin: 32px 0;
  padding: 18px 26px;
  border-radius: 0 var(--radius-hud) var(--radius-hud) 0;
  font-style: italic;
  font-size: 1.05em;
  color: var(--neon-phosphor-bright);
}

.reader-content pre {
  background: #020402;
  border: 1px solid var(--border-base);
  border-radius: var(--radius-hud);
  padding: 20px 24px;
  font-family: var(--font-mono);
  font-size: 14.5px;
  overflow-x: auto;
  margin: 28px 0;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.8);
}

.reader-content code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: rgba(45, 75, 47, 0.4);
  padding: 3px 7px;
  border-radius: 3px;
  color: var(--neon-cyan);
}

/* Interactive SVG Illustration Stage */
figure.spectrum-figure,
figure.illustration-unit,
figure.illustration-container {
  margin: 32px 0;
  background: var(--glass-surface);
  border: 1px solid var(--border-base);
  border-radius: var(--radius-hud);
  padding: 16px;
  box-shadow: var(--shadow-hud);
}

.illustration-stage {
  width: 100%;
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  background: #020502;
  border: 1px solid var(--border-dim);
  display: block;
}

.checked-cover {
  display: block;
  width: 100%;
  height: auto;
  max-height: 380px;
  object-fit: contain;
}

.illustration-stage iframe {
  display: block;
  width: 100%;
  height: 420px;
  border: 0;
  background: #020502;
}

iframe[hidden], [hidden], .checked-cover[hidden] {
  display: none !important;
}

.figure-action-bar,
.figure-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border-dim);
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.figure-action-bar button,
.figure-controls button {
  background: transparent;
  color: var(--neon-phosphor);
  border: 1px solid var(--border-bright);
  padding: 6px 14px;
  border-radius: 4px;
  font-size: 12px;
  font-family: var(--font-mono);
  font-weight: 600;
  cursor: pointer;
  min-height: 36px;
  transition: all var(--speed-fast);
}

.figure-action-bar button:hover,
.figure-controls button:hover {
  background: rgba(158, 254, 55, 0.15);
  border-color: var(--neon-phosphor);
  box-shadow: 0 0 10px var(--neon-phosphor-subtle);
}

/* Share & Control Ribbon */
.reader-controls-ribbon {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 24px 0;
  margin: 44px 0 32px;
  border-top: 1px solid var(--border-base);
  border-bottom: 1px solid var(--border-base);
}

.btn-relay-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 9px 20px;
  background: var(--glass-surface);
  border: 1px solid var(--border-base);
  border-radius: 4px;
  color: var(--text-pure);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--speed-fast);
}

.btn-relay-action:hover {
  background: var(--glass-elevated);
  border-color: var(--neon-phosphor);
  color: var(--neon-phosphor);
}

.btn-relay-action.highlight {
  background: var(--neon-phosphor);
  color: #040804;
  border-color: var(--neon-phosphor);
  box-shadow: 0 0 14px var(--neon-phosphor-glow);
}

.btn-relay-action.highlight:hover {
  background: var(--neon-phosphor-bright);
}

/* Discussion Matrix (Comments) */
.discussion-section {
  margin-top: 54px;
}

.discussion-section h2 {
  font-size: 24px;
  margin-bottom: 26px;
}

.transmission-comment {
  background: var(--glass-surface);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-hud);
  padding: 22px 26px;
  margin-bottom: 18px;
  backdrop-filter: blur(8px);
}

.transmission-comment.nested-reply {
  margin-left: clamp(16px, 4vw, 40px);
  border-left: 3px solid var(--neon-cyan);
  background: linear-gradient(135deg, rgba(14, 26, 22, 0.75), rgba(7, 14, 11, 0.85));
}

.transmission-comment p:last-child {
  margin-bottom: 0;
}

/* Responsive Breakpoints */
@media (max-width: 640px) {
  .site-wrapper {
    padding: 18px 14px 44px;
  }
  
  .cyberdeck-module {
    padding: 18px 16px;
  }

  .protocol-matrix {
    grid-template-columns: 1fr;
  }

  .reader-controls-ribbon {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-relay-action {
    justify-content: center;
  }
}

/* Keyframe Animations */
@keyframes radar-sweep {
  0% { transform: translateY(0); }
  100% { transform: translateY(100vh); }
}

@keyframes orb-ring {
  0% { transform: scale(1); opacity: 1; }
  100% { transform: scale(2.6); opacity: 0; }
}

/* Reduced Motion Mode */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }

  body::after, #telemetry-canvas {
    display: none !important;
  }
}
