/* ==========================================================================
   Creative Strategy Mastery — Neobrutalist Design System
   Bold borders, raw typography, hard shadows, high contrast
   ========================================================================== */

:root {
  /* Neobrutalist palette */
  --black: #1a1a1a;
  --white: #fafaf9;
  --cream: #f5f0e8;
  --paper: #fffef9;
  --ink: #0d0d0d;

  /* Accent colors — bold and unapologetic */
  --orange: #ff6b00;
  --orange-light: #ff8c38;
  --yellow: #ffe14d;
  --pink: #ff3e8a;
  --blue: #3366ff;
  --green: #00cc6a;
  --violet: #7c3aed;
  --red: #ff2e2e;
  --cyan: #00d4ff;

  /* Surfaces */
  --surface: var(--paper);
  --surface-2: var(--cream);
  --surface-dark: var(--ink);
  --surface-card: var(--white);

  /* Text */
  --text: var(--ink);
  --text-2: #444444;
  --text-3: #777777;
  --text-4: #aaaaaa;
  --text-on-dark: #f0ece4;

  /* Borders */
  --border: 2px solid var(--ink);
  --border-thick: 3px solid var(--ink);
  --border-light: 1.5px solid #d4d0c8;

  /* Shadows — hard, offset, no blur */
  --shadow: 4px 4px 0 var(--ink);
  --shadow-sm: 2px 2px 0 var(--ink);
  --shadow-lg: 6px 6px 0 var(--ink);
  --shadow-orange: 4px 4px 0 var(--orange);
  --shadow-pink: 4px 4px 0 var(--pink);
  --shadow-blue: 4px 4px 0 var(--blue);

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  --space-4xl: 96px;

  /* Radii — minimal, brutal */
  --radius-none: 0;
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-full: 9999px;

  /* Fonts */
  --font: 'Outfit', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Layout */
  --sidebar-width: 280px;
  --topbar-height: 52px;
  --content-max: 780px;
}

/* === RESET === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--yellow); color: var(--ink); }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb { background: var(--ink); border: 2px solid var(--cream); }

/* === PASSWORD GATE === */
.gate {
  position: fixed; inset: 0; z-index: 10000;
  background: var(--ink);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font);
}
.gate.hidden { display: none; }
.gate-box { width: 100%; max-width: 440px; padding: 0 24px; text-align: center; }
.gate-brand {
  font-family: var(--font-mono); font-size: 13px; font-weight: 700;
  color: #666; letter-spacing: .15em; text-transform: uppercase; margin-bottom: 36px;
}
.gate-lock {
  width: 72px; height: 72px; margin: 0 auto 28px;
  background: var(--orange); border: var(--border-thick); border-color: var(--orange);
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; box-shadow: var(--shadow-sm);
  animation: spin 8s linear infinite;
  border-radius: 50%;
}
.gate-lock-inner {
  width: 100%; height: 100%; border-radius: 50%;
  background: var(--ink);
  display: flex; align-items: center; justify-content: center;
}
@keyframes spin { to { transform: rotate(360deg); } }

.gate h1 {
  font-size: 32px; font-weight: 900; color: var(--text-on-dark);
  letter-spacing: -.03em; line-height: 1.15; margin-bottom: 10px;
}
.gate h1 span {
  color: var(--orange); text-decoration: underline;
  text-decoration-thickness: 3px; text-underline-offset: 4px;
}
.gate-sub { font-size: 14px; color: #999; line-height: 1.7; margin-bottom: 28px; }
.gate-status {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  color: var(--green); padding: 8px 16px;
  border: 2px solid var(--green); background: rgba(0,204,106,.06);
  margin-bottom: 24px;
}
.gate-status-dot {
  width: 7px; height: 7px; background: var(--green);
  animation: blink 1.5s ease infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:.3} }

.gate-row { display: flex; gap: 0; max-width: 340px; margin: 0 auto; }
.gate-input {
  flex: 1; padding: 12px 14px;
  background: #222; border: 2px solid #444; border-right: none;
  font-family: var(--font-mono); font-size: 14px; color: var(--text-on-dark);
  outline: none;
}
.gate-input:focus { border-color: var(--orange); }
.gate-input.error { border-color: var(--red); }
.gate-btn {
  padding: 12px 22px;
  background: var(--orange); border: 2px solid var(--orange);
  color: var(--ink); font-family: var(--font); font-size: 14px; font-weight: 800;
  cursor: pointer; text-transform: uppercase; letter-spacing: .05em;
}
.gate-btn:hover { background: var(--yellow); border-color: var(--yellow); }
.gate-err { font-size: 12px; color: var(--red); margin-top: 8px; min-height: 18px; font-family: var(--font-mono); }
.gate-footer { margin-top: 28px; font-size: 11px; color: #555; font-family: var(--font-mono); }

/* === APP LAYOUT === */
.app { display: flex; min-height: 100vh; }

/* === SIDEBAR — Enterprise / Linear-style === */
.sidebar {
  position: fixed; top: 0; left: 0; width: var(--sidebar-width); height: 100vh;
  background: linear-gradient(180deg, #0c0c10 0%, #0a0a0e 100%);
  color: var(--text-on-dark);
  display: flex; flex-direction: column; z-index: 100;
  border-right: 1px solid rgba(255,255,255,.06);
  transition: transform .3s;
}
.sidebar-header {
  padding: 24px 18px 18px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.02);
}
.sidebar-brand {
  font-family: var(--font-mono); font-size: 13px; font-weight: 800;
  color: #999; letter-spacing: .15em; text-transform: uppercase; margin-bottom: 8px;
}
.sidebar-title { font-size: 17px; font-weight: 900; color: #f0f0f4; letter-spacing: -.02em; line-height: 1.3; }
.sidebar-title span {
  background: linear-gradient(135deg, #ff6b00, #ff3e8a);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

.toc { flex: 1; overflow-y: auto; padding: 0; }

/* Search */
.toc-search {
  padding: 10px 14px; border-bottom: 1px solid rgba(255,255,255,.04);
}
.toc-search input {
  width: 100%; padding: 8px 12px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
  border-radius: 6px;
  font-family: var(--font-mono); font-size: 11px; color: #bbb;
  outline: none; transition: .2s;
}
.toc-search input:focus { border-color: rgba(255,107,0,.4); background: rgba(255,255,255,.06); box-shadow: 0 0 0 2px rgba(255,107,0,.08); }
.toc-search input::placeholder { color: #444; }

/* Hub link */
.toc-hub-link {
  display: flex; align-items: center; gap: 6px; padding: 10px 16px;
  font-family: var(--font); font-size: 12px; font-weight: 600;
  color: #777; text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: .15s;
}
.toc-hub-link:hover { color: var(--orange); background: rgba(255,255,255,.02); }

/* Check mark */
.toc-check { color: var(--green); font-size: 12px; margin-left: auto; opacity: 1; }

/* Part headers */
.toc-group { border-bottom: 1px solid rgba(255,255,255,.05); padding: 4px 0; }
.toc-part {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .05em;
  color: #888; padding: 10px 16px 8px;
  text-decoration: none; transition: .15s;
}
.toc-part:hover { color: #ccc; background: rgba(255,255,255,.02); }
.toc-part-active {
  color: #fff !important;
  background: rgba(255,107,0,.06);
  border-left: 3px solid var(--orange);
}
.toc-part-active::before {
  content: ''; display: inline-block; width: 6px; height: 6px;
  background: var(--orange); border-radius: 50%; flex-shrink: 0;
  box-shadow: 0 0 8px rgba(255,107,0,.5);
}

/* Section items */
.toc-item {
  display: flex; align-items: center; padding: 7px 16px 7px 32px;
  font-size: 13px; font-weight: 500; color: #999; text-decoration: none;
  border-left: 2px solid rgba(255,255,255,.06);
  margin-left: 10px;
  transition: .12s;
}
.toc-item:hover { color: #eee; background: rgba(255,255,255,.03); border-left-color: #555; }
.toc-item.active {
  color: var(--orange);
  border-left-color: var(--orange);
  background: rgba(255,107,0,.06);
  font-weight: 700;
}

/* Author */
.sidebar-author {
  padding: 14px 16px; border-top: 1px solid rgba(255,255,255,.06);
  background: rgba(0,0,0,.2);
}
.sidebar-author a {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--text-on-dark); padding: 6px;
  border-radius: 6px; transition: .15s;
}
.sidebar-author a:hover { background: rgba(255,255,255,.03); }
.sidebar-author-name { font-size: 13px; font-weight: 700; color: #ccc; }
.sidebar-author-handle { font-size: 11px; color: var(--orange); margin-top: 1px; opacity: .8; }

/* === MAIN === */
.main { flex: 1; margin-left: var(--sidebar-width); min-height: 100vh; background: var(--cream); }

.topbar {
  position: sticky; top: 0; z-index: 50; height: var(--topbar-height);
  background: var(--cream); border-bottom: 2px solid var(--ink);
  display: flex; align-items: center; padding: 0 var(--space-xl); gap: 14px;
}
.menu-toggle {
  display: none; background: none; border: 2px solid var(--ink);
  font-size: 18px; color: var(--ink); cursor: pointer; padding: 4px 8px; font-weight: 900;
}
.current-section {
  font-family: var(--font-mono); font-size: 12px; font-weight: 600;
  color: var(--text-3); flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.progress-bar {
  width: 120px; height: 6px; background: var(--ink); flex-shrink: 0;
}
.progress-fill {
  height: 100%; background: var(--orange); width: 0%; transition: width .15s;
}

.content { max-width: var(--content-max); margin: 0 auto; padding: 36px 36px 100px; }

/* === HERO === */
.hero {
  background: var(--ink); padding: var(--space-4xl) var(--space-xl);
  text-align: center; color: var(--text-on-dark);
  border-bottom: 4px solid var(--orange); position: relative;
}
.hero::after {
  content: ''; position: absolute; top: 0; right: 0;
  width: 200px; height: 200px; background: var(--orange); opacity: .04;
  clip-path: polygon(100% 0, 0 0, 100% 100%);
}
.hero-badge {
  display: inline-block; font-family: var(--font-mono); font-size: 11px;
  font-weight: 800; text-transform: uppercase; letter-spacing: .12em;
  color: var(--orange); border: 2px solid var(--orange); padding: 6px 16px;
  margin-bottom: var(--space-lg);
}
.hero h1 {
  font-size: 2.6rem; font-weight: 900; line-height: 1.1;
  margin-bottom: var(--space-md); letter-spacing: -.03em;
}
.hero h1 span {
  color: var(--orange); text-decoration: underline;
  text-decoration-thickness: 4px; text-underline-offset: 6px;
  text-decoration-color: var(--orange);
}
.hero-rule { width: 60px; height: 4px; background: var(--orange); margin: 0 auto var(--space-md); }
.hero-lead {
  font-size: 16px; color: #aaa; line-height: 1.7;
  max-width: 560px; margin: 0 auto var(--space-lg);
}
.hero-meta {
  display: flex; justify-content: center; gap: 20px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600; color: #777;
}

/* === TYPOGRAPHY === */
.section { padding: var(--space-3xl) 0 var(--space-2xl); }
.section + .section { border-top: 2px solid var(--ink); }

.sh { margin-bottom: var(--space-xl); }
.sh-label {
  font-family: var(--font-mono); font-size: 11px; font-weight: 800;
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: 6px;
  display: inline-block; padding: 2px 8px; border: 2px solid;
}
.sh-label.blue { color: var(--blue); border-color: var(--blue); background: rgba(51,102,255,.05); }
.sh-label.green { color: var(--green); border-color: var(--green); background: rgba(0,204,106,.05); }
.sh-label.violet { color: var(--violet); border-color: var(--violet); background: rgba(124,58,237,.05); }
.sh-label.amber { color: var(--orange); border-color: var(--orange); background: rgba(255,107,0,.05); }
.sh-label.rose { color: var(--pink); border-color: var(--pink); background: rgba(255,62,138,.05); }
.sh-label.cyan { color: var(--cyan); border-color: var(--cyan); background: rgba(0,212,255,.05); }

.sh h2 {
  font-size: 28px; font-weight: 900; color: var(--ink);
  line-height: 1.15; letter-spacing: -.03em; margin-bottom: 6px;
}
.sh p { font-size: 15px; color: var(--text-3); line-height: 1.7; }

h3 { font-size: 20px; font-weight: 900; color: var(--ink); margin: 32px 0 12px; letter-spacing: -.02em; }
h4 { font-size: 16px; font-weight: 800; color: var(--ink); margin: 24px 0 8px; }
p { margin-bottom: 14px; }
ul, ol { margin: 0 0 16px 20px; }
li { margin-bottom: 6px; }
strong { color: var(--ink); font-weight: 800; }
a { color: var(--blue); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 2px; }
a:hover { color: var(--orange); }
code {
  font-family: var(--font-mono); font-size: .88em;
  background: var(--yellow); color: var(--ink);
  padding: 2px 6px; border: 1px solid var(--ink);
}

/* Code blocks */
pre {
  background: var(--ink); color: #ddd; padding: 20px;
  overflow-x: auto; margin: 14px 0 18px;
  font-family: var(--font-mono); font-size: 13px; line-height: 1.6;
  border: 3px solid var(--ink); box-shadow: var(--shadow);
}
pre code { background: none; padding: 0; color: inherit; border: none; }
.code-label {
  font-family: var(--font-mono); font-size: 10px; font-weight: 800;
  color: var(--text-3); letter-spacing: .05em; text-transform: uppercase; margin-bottom: 4px;
}

/* === CALLOUT BOXES === */
.callout {
  padding: 18px 20px; margin: 18px 0;
  border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
  background: var(--paper); position: relative;
}
.callout-title {
  font-family: var(--font-mono); font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .08em; margin-bottom: 6px;
}
.callout p { margin-bottom: 6px; font-size: 14px; }
.callout p:last-child { margin-bottom: 0; }

.callout.tip { border-left: 6px solid var(--blue); }
.callout.tip .callout-title { color: var(--blue); }
.callout.success { border-left: 6px solid var(--green); }
.callout.success .callout-title { color: var(--green); }
.callout.warning { border-left: 6px solid var(--orange); }
.callout.warning .callout-title { color: var(--orange); }
.callout.danger { border-left: 6px solid var(--red); background: #fff5f5; }
.callout.danger .callout-title { color: var(--red); }
.callout.insight { border-left: 6px solid var(--violet); }
.callout.insight .callout-title { color: var(--violet); }
.callout.real-talk { border-left: 6px solid var(--orange); background: #fffbf0; }
.callout.real-talk .callout-title { color: var(--orange); }

/* === STEP CARDS === */
.step-card {
  background: var(--paper); border: 2px solid var(--ink);
  padding: 18px 20px; margin: 12px 0; box-shadow: var(--shadow-sm);
  transition: transform .15s, box-shadow .15s;
}
.step-card:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.step-num { font-family: var(--font-mono); font-size: 11px; font-weight: 800; color: var(--orange); margin-bottom: 4px; }
.step-title { font-size: 15px; font-weight: 800; color: var(--ink); margin-bottom: 6px; }
.step-desc { font-size: 14px; color: var(--text-2); line-height: 1.6; }

/* === SANDBOX (dark terminal style) === */
.sandbox {
  background: var(--ink); border: 3px solid var(--ink);
  box-shadow: var(--shadow-lg); margin: 24px 0; overflow: hidden;
}
.sandbox-header {
  padding: 12px 20px; border-bottom: 2px solid #333;
  display: flex; align-items: center; gap: 10px;
}
.sandbox-dot { width: 10px; height: 10px; border-radius: 50%; border: 2px solid; }
.sandbox-dot.red { background: var(--red); border-color: var(--red); }
.sandbox-dot.yellow { background: var(--yellow); border-color: var(--yellow); }
.sandbox-dot.green { background: var(--green); border-color: var(--green); }
.sandbox-title {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  color: #777; flex: 1; text-transform: uppercase; letter-spacing: .05em;
}
.sandbox-badge {
  font-family: var(--font-mono); font-size: 9px; font-weight: 800;
  padding: 3px 10px; text-transform: uppercase; letter-spacing: .08em;
  border: 2px solid;
}
.sandbox-badge.before { color: var(--red); border-color: var(--red); }
.sandbox-badge.after { color: var(--green); border-color: var(--green); }
.sandbox-badge.live { color: var(--cyan); border-color: var(--cyan); }
.sandbox-body { padding: 20px; min-height: 120px; color: #ddd; }
.sandbox-body div, .sandbox-body span, .sandbox-body p { color: inherit; }

.sandbox-split { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.sandbox-half { padding: 20px; color: #ddd; }
.sandbox-half + .sandbox-half { border-left: 2px solid #333; }
.sandbox-half-label {
  font-family: var(--font-mono); font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px;
}
.sandbox-half-label.old { color: var(--red); }
.sandbox-half-label.new { color: var(--green); }

/* Sandbox content */
.sb-line {
  display: flex; align-items: center; gap: 8px; padding: 3px 0;
  font-family: var(--font-mono); font-size: 12px; color: #bbb;
}
.sb-line .prompt { color: var(--orange); font-weight: 700; }
.sb-line .cmd { color: #eee; }
.sb-line .out { color: var(--green); }
.sb-line .err { color: var(--red); }
.sb-comment {
  font-family: var(--font-mono); font-size: 11px; color: #555;
  font-style: italic; padding: 3px 0;
}
.sb-highlight { color: var(--yellow); font-weight: 800; }
.sb-block {
  background: rgba(255,255,255,.03); border: 1px solid #333;
  padding: 14px; margin: 8px 0;
}
.sb-result {
  text-align: center; padding: 14px; margin-top: 12px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 800;
}
.sb-result.win {
  border: 2px solid var(--green); color: #6ee7b7;
  background: rgba(0,204,106,.06);
}
.sb-result.lose {
  border: 2px solid var(--red); color: #fca5a5;
  background: rgba(255,46,46,.06);
}
.sb-metric { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; font-family: var(--font-mono); font-size: 12px; font-weight: 700; margin: 4px; border: 2px solid; }
.sb-metric.good { color: var(--green); border-color: var(--green); }
.sb-metric.bad { color: var(--red); border-color: var(--red); }

/* Animated sandbox elements */
.sandbox-animated .sandbox-replay {
  background: none; border: 2px solid #555; color: #777;
  font-size: 14px; cursor: pointer; padding: 2px 8px; margin-left: auto;
  font-family: var(--font-mono);
}
.sandbox-animated .sandbox-replay:hover { color: var(--orange); border-color: var(--orange); }
.sb-typed .cursor { display: inline-block; width: 2px; height: 1em; background: var(--orange); animation: cursor-blink .6s infinite; vertical-align: text-bottom; margin-left: 1px; }
@keyframes cursor-blink { 0%,100%{opacity:1} 50%{opacity:0} }

/* === FEATURE GRID === */
.feat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 18px 0; }
.feat-card {
  background: var(--paper); border: 2px solid var(--ink); padding: 18px;
  box-shadow: var(--shadow-sm); transition: transform .15s, box-shadow .15s;
}
.feat-card:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.feat-card.c-blue { border-top: 5px solid var(--blue); }
.feat-card.c-violet { border-top: 5px solid var(--violet); }
.feat-card.c-green { border-top: 5px solid var(--green); }
.feat-card.c-amber { border-top: 5px solid var(--orange); }
.feat-card.c-rose { border-top: 5px solid var(--pink); }
.feat-card.c-cyan { border-top: 5px solid var(--cyan); }
.feat-icon { font-size: 24px; margin-bottom: 8px; }
.feat-name { font-size: 14px; font-weight: 900; color: var(--ink); margin-bottom: 4px; }
.feat-desc { font-size: 12px; color: var(--text-3); line-height: 1.5; }

/* === CHECKLIST === */
.checklist { list-style: none; margin: 14px 0; padding: 0; }
.checklist li {
  display: flex; gap: 10px; padding: 10px 0; font-size: 14px;
  color: var(--text-2); border-bottom: 2px solid var(--surface-2);
}
.checklist li:last-child { border-bottom: none; }
.check-icon { font-size: 14px; flex-shrink: 0; margin-top: 2px; }

/* === TIMELINE === */
.timeline { position: relative; padding-left: 28px; margin: 18px 0; }
.timeline::before {
  content: ''; position: absolute; left: 8px; top: 0; bottom: 0;
  width: 3px; background: var(--ink);
}
.timeline-item { position: relative; margin-bottom: 18px; }
.timeline-dot {
  position: absolute; left: -24px; top: 4px; width: 14px; height: 14px;
  border: 3px solid var(--ink); background: var(--cream);
}
.timeline-item.done .timeline-dot { background: var(--orange); }
.timeline-title { font-size: 14px; font-weight: 800; color: var(--ink); }
.timeline-desc { font-size: 13px; color: var(--text-3); margin-top: 2px; }

/* === COMPARISON TABLE === */
.compare-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 13px; }
.compare-table th {
  background: var(--ink); color: var(--text-on-dark);
  padding: 12px 14px; font-weight: 800; text-align: left;
  border: 2px solid var(--ink); font-family: var(--font-mono); font-size: 11px;
  text-transform: uppercase; letter-spacing: .05em;
}
.compare-table td {
  padding: 10px 14px; border: 2px solid var(--ink);
  color: var(--text-2); background: var(--paper);
}
.compare-table tr:hover td { background: var(--yellow); color: var(--ink); }

/* === VISUAL DIAGRAMS === */

/* Flow diagram — horizontal process */
.flow-diagram { display: flex; align-items: center; gap: 0; margin: 24px 0; flex-wrap: wrap; }
.flow-node {
  flex: 1; min-width: 120px; padding: 16px 14px; text-align: center;
  background: var(--paper); border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
}
.flow-node.active { border-color: var(--orange); box-shadow: 3px 3px 0 var(--orange); }
.flow-node.green { border-color: var(--green); box-shadow: 3px 3px 0 var(--green); }
.flow-node.red { border-color: var(--red); box-shadow: 3px 3px 0 var(--red); }
.flow-node.blue { border-color: var(--blue); box-shadow: 3px 3px 0 var(--blue); }
.flow-node.violet { border-color: var(--violet); box-shadow: 3px 3px 0 var(--violet); }
.flow-node-num { font-family: var(--font-mono); font-size: 10px; font-weight: 800; color: var(--orange); margin-bottom: 4px; }
.flow-node-title { font-size: 13px; font-weight: 800; color: var(--ink); margin-bottom: 2px; }
.flow-node-desc { font-size: 10px; color: var(--text-3); line-height: 1.4; }
.flow-arrow { width: 32px; flex-shrink: 0; text-align: center; font-size: 18px; color: var(--ink); font-weight: 900; }

/* Vertical flow */
.vflow { display: flex; flex-direction: column; align-items: center; gap: 0; margin: 24px 0; }
.vflow-node {
  width: 100%; max-width: 500px; padding: 16px 20px;
  background: var(--paper); border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
  display: flex; align-items: center; gap: 14px;
}
.vflow-node.highlight { border-color: var(--orange); background: #fffbf0; }
.vflow-node.green { border-color: var(--green); background: #f0fff8; }
.vflow-node.red { border-color: var(--red); background: #fff5f5; }
.vflow-icon { font-size: 22px; flex-shrink: 0; }
.vflow-content { flex: 1; }
.vflow-title { font-size: 14px; font-weight: 800; color: var(--ink); }
.vflow-desc { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.vflow-arrow { font-size: 18px; color: var(--ink); padding: 4px 0; font-weight: 900; }

/* Architecture diagram — boxes with connections */
.arch-diagram { background: var(--ink); border: 3px solid var(--ink); box-shadow: var(--shadow-lg); padding: 28px; margin: 24px 0; color: #ddd; }
.arch-title { font-family: var(--font-mono); font-size: 10px; font-weight: 700; color: #666; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 16px; text-align: center; }
.arch-row { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 8px; }
.arch-box {
  padding: 12px 16px; border: 2px solid; text-align: center; min-width: 140px;
  font-size: 12px; font-weight: 700; font-family: var(--font-mono);
}
.arch-box.orange { border-color: var(--orange); color: var(--orange); background: rgba(255,107,0,.06); }
.arch-box.blue { border-color: var(--blue); color: #93c5fd; background: rgba(51,102,255,.06); }
.arch-box.green { border-color: var(--green); color: #6ee7b7; background: rgba(0,204,106,.06); }
.arch-box.violet { border-color: var(--violet); color: #c4b5fd; background: rgba(124,58,237,.06); }
.arch-box.pink { border-color: var(--pink); color: #f9a8d4; background: rgba(255,62,138,.06); }
.arch-box.white { border-color: #444; color: #ccc; background: rgba(255,255,255,.03); }
.arch-connector { font-size: 14px; color: #555; }
.arch-vconnector { text-align: center; font-size: 14px; color: #555; padding: 4px 0; }
.arch-label { font-family: var(--font-mono); font-size: 9px; color: #555; text-align: center; margin-top: 4px; }

/* Cycle/Loop diagram */
.cycle-diagram { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin: 24px 0; }
.cycle-step {
  width: 140px; padding: 14px 12px; text-align: center;
  background: var(--paper); border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
  position: relative;
}
.cycle-step::after {
  content: '→'; position: absolute; right: -20px; top: 50%; transform: translateY(-50%);
  font-size: 16px; font-weight: 900; color: var(--ink);
}
.cycle-step:last-child::after { content: '↩'; color: var(--orange); }
.cycle-num { font-family: var(--font-mono); font-size: 18px; font-weight: 900; color: var(--orange); }
.cycle-label { font-size: 11px; font-weight: 700; color: var(--ink); margin-top: 4px; }

/* Comparison visual — side by side with verdict */
.vs-visual { display: grid; grid-template-columns: 1fr auto 1fr; gap: 0; margin: 24px 0; align-items: stretch; }
.vs-side {
  padding: 20px; background: var(--paper); border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
}
.vs-side.bad { border-color: var(--red); }
.vs-side.good { border-color: var(--green); }
.vs-tag { font-family: var(--font-mono); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 10px; }
.vs-tag.bad { color: var(--red); }
.vs-tag.good { color: var(--green); }
.vs-divider {
  display: flex; align-items: center; justify-content: center;
  background: var(--ink); padding: 0 12px; color: #666;
  font-family: var(--font-mono); font-size: 12px; font-weight: 800;
}
.vs-item { font-size: 13px; color: var(--text-2); padding: 4px 0; display: flex; align-items: center; gap: 6px; }
.vs-item .icon { font-size: 14px; }

/* Metric highlight strip */
.metric-strip { display: flex; gap: 12px; margin: 20px 0; flex-wrap: wrap; }
.metric-box {
  flex: 1; min-width: 120px; padding: 16px; text-align: center;
  background: var(--paper); border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
}
.metric-box.green { border-top: 4px solid var(--green); }
.metric-box.red { border-top: 4px solid var(--red); }
.metric-box.orange { border-top: 4px solid var(--orange); }
.metric-box.blue { border-top: 4px solid var(--blue); }
.metric-value { font-family: var(--font-mono); font-size: 26px; font-weight: 900; color: var(--ink); }
.metric-label { font-size: 11px; color: var(--text-3); margin-top: 4px; font-weight: 600; }

/* Process pills — inline tag list */
.pill-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.pill {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  padding: 5px 12px; border: 2px solid var(--ink);
  text-transform: uppercase; letter-spacing: .04em;
}
.pill.orange { border-color: var(--orange); color: var(--orange); background: rgba(255,107,0,.04); }
.pill.green { border-color: var(--green); color: var(--green); background: rgba(0,204,106,.04); }
.pill.blue { border-color: var(--blue); color: var(--blue); background: rgba(51,102,255,.04); }
.pill.pink { border-color: var(--pink); color: var(--pink); background: rgba(255,62,138,.04); }
.pill.violet { border-color: var(--violet); color: var(--violet); background: rgba(124,58,237,.04); }

/* Funnel diagram */
.funnel { margin: 24px auto; max-width: 500px; }
.funnel-step {
  padding: 14px 20px; margin: 0 auto; text-align: center;
  border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
  background: var(--paper); position: relative;
  font-size: 13px; font-weight: 700; color: var(--ink);
}
.funnel-step + .funnel-step { margin-top: -2px; }
.funnel-step:nth-child(1) { width: 100%; }
.funnel-step:nth-child(2) { width: 85%; }
.funnel-step:nth-child(3) { width: 70%; }
.funnel-step:nth-child(4) { width: 55%; }
.funnel-step:nth-child(5) { width: 40%; border-color: var(--green); box-shadow: 3px 3px 0 var(--green); color: var(--green); }
.funnel-pct { font-family: var(--font-mono); font-size: 11px; color: var(--text-3); font-weight: 600; }

/* === CTA BANNER === */
.cta-banner {
  background: var(--ink); border: 3px solid var(--ink);
  box-shadow: var(--shadow-orange); padding: 40px 28px; text-align: center;
  margin: 40px 0;
}
.cta-banner h3 {
  font-size: 24px; font-weight: 900; color: var(--text-on-dark);
  letter-spacing: -.02em; margin-bottom: 8px;
}
.cta-banner h3 span { color: var(--orange); text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 4px; }
.cta-banner p { font-size: 14px; color: #999; margin-bottom: 0; }

/* === PART NAVIGATION === */
.part-nav-inner {
  display: flex; justify-content: space-between; align-items: stretch;
  border-top: 3px solid var(--ink); margin-top: var(--space-2xl); padding-top: var(--space-lg);
}
.part-nav-link {
  text-decoration: none; padding: 12px 16px;
  border: 2px solid var(--ink); box-shadow: var(--shadow-sm);
  background: var(--paper); transition: .15s;
}
.part-nav-link:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.part-nav-link.next { text-align: right; }
.part-nav-dir { display: block; font-family: var(--font-mono); font-size: 10px; font-weight: 800; color: var(--orange); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 2px; }
.part-nav-title { display: block; font-size: 14px; font-weight: 700; color: var(--ink); }

/* === BREADCRUMB === */
#breadcrumb, .breadcrumb {
  font-family: var(--font-mono); font-size: 12px; color: var(--text-3);
  margin-bottom: var(--space-lg); padding: 8px 0;
  border-bottom: 2px dashed #d4d0c8;
}
.breadcrumb-link { color: var(--orange); text-decoration: none; font-weight: 700; }
.breadcrumb-link:hover { text-decoration: underline; }
.breadcrumb-sep { margin: 0 6px; color: #bbb; }
.breadcrumb-current { font-weight: 700; color: var(--ink); }

/* === HUB CARDS === */
.hub-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 18px 0; }
.hub-card {
  display: block; text-decoration: none; color: inherit;
  background: var(--paper); border: 3px solid var(--ink);
  padding: 24px; box-shadow: var(--shadow);
  transition: transform .15s, box-shadow .15s;
  position: relative; overflow: hidden;
}
.hub-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0;
  height: 5px; background: var(--accent, var(--orange));
}
.hub-card:hover {
  transform: translate(-4px, -4px); box-shadow: var(--shadow-lg);
}
.hub-num {
  font-family: var(--font-mono); font-size: 48px; font-weight: 900;
  color: #e8e4dc; line-height: 1; margin-bottom: 8px;
}
.hub-title { font-size: 18px; font-weight: 900; color: var(--ink); margin-bottom: 6px; }
.hub-desc { font-size: 13px; color: var(--text-3); line-height: 1.5; margin-bottom: 12px; }
.hub-meta {
  display: flex; gap: 12px; font-family: var(--font-mono); font-size: 11px;
  color: var(--text-3); font-weight: 600;
}
.hub-level {
  padding: 2px 8px; border: 2px solid; font-weight: 800; text-transform: uppercase;
  font-size: 9px; letter-spacing: .05em;
}
.hub-level.beginner { color: var(--green); border-color: var(--green); }
.hub-level.intermediate { color: var(--blue); border-color: var(--blue); }
.hub-level.advanced { color: var(--pink); border-color: var(--pink); }

/* === SCROLL REVEAL === */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* === RESPONSIVE === */
@media (max-width: 860px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0; }
  .menu-toggle { display: block; }
  .content { padding: 24px 20px 80px; }
  .hero { padding: 48px 24px 36px; }
  .hero h1 { font-size: 2rem; }
  .feat-grid { grid-template-columns: 1fr; }
  .hub-grid { grid-template-columns: 1fr; }
  .sandbox-split { grid-template-columns: 1fr; }
  .sandbox-half + .sandbox-half { border-left: none; border-top: 2px solid #333; }
}
@media (max-width: 480px) {
  .hero h1 { font-size: 1.6rem; }
  .sh h2 { font-size: 22px; }
  .gate h1 { font-size: 24px; }
}
