/* ── Design tokens ─────────────────────────────────────────────────────────── */
:root {
  --bg-primary:    #0D1117;
  --bg-devcredit:  #161B22;
  --text-primary:  #F8F9FA;
  --text-secondary: rgba(248, 249, 250, 0.70);
  --text-muted:    rgba(248, 249, 250, 0.45);
  --text-faint:    rgba(248, 249, 250, 0.30);
  --amber:         #E8A045;
  --amber-dim:     rgba(232, 160, 69, 0.30);
  --blue:          #3B82F6;
  --max-w:         1200px;
  --text-max:      680px;
  --hero-text-max: 540px;
  --section-py:    120px;
}

/* ── Reset ──────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.65;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
input, button { font-family: inherit; }

/* ── Brand accent ───────────────────────────────────────────────────────────── */
.accent-blue { color: #46aee8; }

/* ── Utility ────────────────────────────────────────────────────────────────── */
.section-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--section-py) 48px;
}
.mono { font-family: 'JetBrains Mono', monospace; }

/* ── Scroll entrance animation ──────────────────────────────────────────────── */
.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 300ms ease-out, transform 300ms ease-out;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── CTA button ─────────────────────────────────────────────────────────────── */
.cta-button {
  display: inline-block;
  background: var(--amber);
  color: var(--bg-primary);
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  font-weight: 500;
  padding: 14px 28px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background 150ms ease;
  white-space: nowrap;
}
.cta-button:hover { background: #F0AF55; }

/* ── Navigation ─────────────────────────────────────────────────────────────── */
#navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(13, 17, 23, 0.90);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
}
#navbar.visible {
  opacity: 1;
  pointer-events: auto;
}
.nav-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 48px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.nav-wordmark {
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-primary);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}
.nav-links a {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 150ms;
}
.nav-links a:hover { color: var(--text-primary); }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text-primary);
  transition: all 200ms;
}

/* ── Mobile drawer ──────────────────────────────────────────────────────────── */
#nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 280px;
  background: #111820;
  z-index: 200;
  padding: 80px 40px 40px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  transform: translateX(100%);
  transition: transform 250ms ease;
}
#nav-drawer.open { transform: translateX(0); }
.drawer-close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
}
.drawer-link {
  font-family: 'Outfit', sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: var(--text-primary);
}
#drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 150;
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms;
}
#drawer-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

/* ── Section 1: Hero ────────────────────────────────────────────────────────── */
#hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
#particle-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(13, 17, 23, 0.97) 0%,
    rgba(13, 17, 23, 0.85) 30%,
    rgba(13, 17, 23, 0.40) 60%,
    rgba(13, 17, 23, 0.10) 100%
  );
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--hero-text-max);
  padding: 0 48px;
  margin-left: calc((100vw - var(--max-w)) / 2);
  margin-left: max(48px, calc((100vw - var(--max-w)) / 2));
}
.hero-logo-mark {
  margin-bottom: 32px;
}
.hero-logo-mark img {
  max-width: 420px;
  width: 100%;
  height: auto;
}
.hero-wordmark {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(48px, 6vw, 72px);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  line-height: 1.05;
  margin-bottom: 20px;
}
.hero-tagline {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 400;
  color: var(--amber);
  margin-bottom: 16px;
  line-height: 1.4;
}
.hero-descriptor {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(15px, 1.5vw, 18px);
  font-weight: 400;
  color: var(--text-secondary);
  margin-bottom: 36px;
}
.hero-secondary-link {
  display: block;
  margin-top: 20px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--text-faint);
  transition: color 150ms;
}
.hero-secondary-link:hover { color: var(--text-muted); }

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: opacity 300ms;
  z-index: 1;
}
.scroll-indicator.hidden { opacity: 0; pointer-events: none; }
.scroll-line {
  width: 1px;
  height: 40px;
  background: var(--amber);
  opacity: 0.6;
  animation: scroll-pulse 2s ease-in-out infinite;
}
@keyframes scroll-pulse {
  0%, 100% { opacity: 0.3; }
  50%       { opacity: 0.7; }
}

/* ── Section 2: About ───────────────────────────────────────────────────────── */
#about .section-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--section-py) 48px 80px;
}
.murmuration-mark {
  margin-bottom: 48px;
}
#about h2 {
  font-size: clamp(28px, 3.2vw, 36px);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 36px;
  max-width: var(--text-max);
}
.about-body {
  max-width: var(--text-max);
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 48px;
}
.about-body p {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.75;
}
.positioning-statement {
  max-width: var(--text-max);
  border-left: 2px solid var(--amber-dim);
  padding-left: 24px;
}
.positioning-statement p {
  font-size: clamp(16px, 1.8vw, 20px);
  color: var(--amber);
  font-weight: 400;
  line-height: 1.5;
}
.positioning-statement p + p { margin-top: 6px; }
.about-divider {
  width: 100%;
  height: 24px;
  overflow: hidden;
}

/* ── Section 3: Channel ─────────────────────────────────────────────────────── */
#channel {
  background: var(--bg-primary);
}
#channel .section-container {
  padding-top: 80px;
  padding-bottom: var(--section-py);
}
.section-eyebrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  color: var(--amber);
  margin-bottom: 20px;
}
#channel h2 {
  font-size: clamp(24px, 2.8vw, 32px);
  font-weight: 700;
  color: var(--text-primary);
  max-width: var(--text-max);
  margin-bottom: 48px;
}
.channel-preview-card {
  max-width: 720px;
  border: 1px solid var(--amber-dim);
  border-radius: 6px;
  overflow: hidden;
}
.channel-banner-placeholder {
  background: #161B22;
  padding: 40px 36px;
}
.channel-banner-content {
  display: flex;
  align-items: flex-start;
  gap: 28px;
}
.channel-avatar {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.channel-name {
  font-family: 'Outfit', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.channel-name img {
  display: block;
  height: 66px;
  width: auto;
}
.channel-desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.65;
  max-width: 480px;
}
.channel-cta-row {
  padding: 24px 36px;
  background: var(--bg-primary);
  border-top: 1px solid var(--amber-dim);
}

/* ── Section 4: DevCredit ───────────────────────────────────────────────────── */
#devcredit {
  background: var(--bg-devcredit);
}
#devcredit .section-container {
  padding-top: 0;
}
.section-amber-rule {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  height: 1px;
  background: var(--amber-dim);
}
#devcredit .section-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--section-py) 48px;
}
.section-byline {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--amber);
  margin-bottom: 16px;
}
#devcredit h2 {
  font-size: clamp(24px, 2.8vw, 32px);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 36px;
}
.value-prop {
  max-width: var(--text-max);
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 56px;
}
.value-prop p {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.75;
}
.feature-callouts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  max-width: 860px;
  margin-bottom: 48px;
}
.feature-item {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.feature-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(232, 160, 69, 0.08);
  border-radius: 6px;
  flex-shrink: 0;
}
.feature-label {
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}
.feature-desc {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}
.legal {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-faint);
  max-width: var(--text-max);
  margin-top: 24px;
  line-height: 1.6;
}

/* ── Section 5: Book ────────────────────────────────────────────────────────── */
#book {
  background: var(--bg-primary);
}
.book-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 80px;
  align-items: center;
}
#book .section-eyebrow { margin-bottom: 16px; }
#book h2 {
  font-size: clamp(28px, 3.2vw, 36px);
  font-weight: 700;
  font-style: italic;
  color: var(--text-primary);
  margin-bottom: 16px;
}
.book-subtitle {
  font-size: clamp(16px, 1.8vw, 20px);
  color: var(--text-secondary);
  margin-bottom: 32px;
  max-width: 520px;
}
.book-body {
  max-width: 540px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}
.book-body p {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.75;
}
.audience-line {
  font-size: clamp(16px, 1.6vw, 18px);
  font-style: italic;
  color: var(--amber);
  margin-bottom: 36px;
}
.email-capture { margin-bottom: 12px; }
.email-row {
  display: flex;
  gap: 0;
  max-width: 480px;
  margin-bottom: 10px;
}
.email-row input[type="email"] {
  flex: 1;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12);
  border-right: none;
  border-radius: 4px 0 0 4px;
  color: var(--text-primary);
  font-size: 16px;
  padding: 14px 18px;
  outline: none;
  transition: border-color 150ms;
}
.email-row input[type="email"]::placeholder { color: var(--text-muted); }
.email-row input[type="email"]:focus { border-color: rgba(232, 160, 69, 0.5); }
.email-row .cta-button {
  border-radius: 0 4px 4px 0;
  flex-shrink: 0;
}
.sub-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--text-faint);
}
.form-success {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--amber);
  min-height: 1em;
  margin-top: 8px;
}
.author-line {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 36px;
}
.book-image-placeholder {
  width: 100%;
  aspect-ratio: 3/4;
  background: #161B22;
  border: 1px solid var(--amber-dim);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.book-image-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding: 40px;
  text-align: center;
}
.book-image-label {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-style: italic;
  color: var(--text-muted);
}

/* ── Footer ─────────────────────────────────────────────────────────────────── */
#footer {
  background: var(--bg-primary);
}
.footer-rule {
  height: 1px;
  background: var(--amber-dim);
  max-width: var(--max-w);
  margin: 0 auto;
}
.footer-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 80px 48px 48px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 48px;
}
.footer-brand-content {
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
}
.footer-logo {
  margin-bottom: 16px;
}
.footer-logo img {
  display: block;
  width: 100%;
  height: auto;
}
.footer-brand-content .footer-legal {
  white-space: nowrap;
}
.footer-wordmark {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-primary);
}
.footer-tagline {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.footer-legal {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--text-faint);
}
.footer-col-heading {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 20px;
}
.footer-links, .footer-contact {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.footer-links a, .footer-contact a {
  font-size: 15px;
  color: var(--text-muted);
  transition: color 150ms;
}
.footer-links a:hover, .footer-contact a:hover { color: var(--text-primary); }
.footer-bottom {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 48px 40px;
  border-top: 1px solid rgba(255,255,255,0.04);
  padding-top: 24px;
}
.footer-bottom-text {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-faint);
  opacity: 0.7;
}

/* ── Responsive ─────────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  :root { --section-py: 80px; }

  .nav-links { display: none; }
  .hamburger { display: flex; }

  .nav-container { padding: 0 24px; }
  .section-container { padding-left: 24px; padding-right: 24px; }

  .hero-content {
    padding: 0 24px;
    margin-left: 0;
    max-width: 100%;
  }

  .feature-callouts {
    grid-template-columns: 1fr;
    gap: 24px;
    max-width: 100%;
  }

  .book-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .book-image { order: -1; }
  .book-image-placeholder { aspect-ratio: 16/9; }
  .book-image-inner { flex-direction: row; justify-content: center; }

  .footer-container {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 60px 24px 40px;
  }
  .footer-bottom { padding: 0 24px 32px; padding-top: 20px; }

  .email-row { flex-direction: column; max-width: 100%; }
  .email-row input[type="email"] {
    border-right: 1px solid rgba(255,255,255,0.12);
    border-bottom: none;
    border-radius: 4px 4px 0 0;
  }
  .email-row .cta-button { border-radius: 0 0 4px 4px; }
}

@media (max-width: 540px) {
  .hero-wordmark { font-size: 40px; }
  .channel-banner-content { flex-direction: column; }
}
