﻿/* Patriola.com — v22: site-wide dark hacker aesthetic; HUD chrome on all pages */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Outfit:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

@font-face {
  font-family: 'Very Simple Chalk';
  src: url('/fonts/very-simple-chalk.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --coral:       #d4694a;
  --coral-dark:  #b0502f;
  --coral-light: #e8875e;
  --coral-pale:  #fdf0ea;
  --gold:        #d4901a;
  --gold-light:  #e8a930;
  --gold-pale:   #fdf5e0;
  --ink:         #1e1510;
  --ink-soft:    #5a4538;
  --ink-mute:    #8a7a70;
  --rule:        #ddd0c8;
  --bg:          #fefcf8;
  --bg-soft:     #f5efe9;
  --hero-bg:     #0c0b07;
  --hero-mid:    #141210;
  --ok:          #166534;
  --err:         #991b1b;
  --maxw:        880px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
}

/* Film grain — fixed overlay, entire page */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.68' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23g)'/%3E%3C/svg%3E");
  background-size: 300px;
  opacity: 0.055;
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: overlay;
}

a { color: var(--coral); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--coral-dark); }

h1, h2 {
  font-family: "video", 'Bebas Neue', Georgia, sans-serif;
  font-weight: 400;
  line-height: 1.05;
  color: var(--ink);
  letter-spacing: 0.04em;
}
h1 { font-size: clamp(3rem, 8vw, 5.8rem); margin-bottom: 0.3em; }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-top: 1.8em; margin-bottom: 0.5em; }
h3 { font-size: 1.15rem; margin-top: 1.4em; margin-bottom: 0.35em; font-family: 'Outfit', sans-serif; font-weight: 700; letter-spacing: -0.01em; }

p { margin-bottom: 1em; }
ul, ol { margin-bottom: 1em; padding-left: 1.3em; }
li { margin-bottom: 0.4em; }

code, .mono {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.84em;
  background: var(--coral-pale);
  padding: 2px 7px;
  border-radius: 4px;
  color: var(--coral-dark);
}

/* ── Animations ── */
@keyframes orb-drift {
  0%,100% { transform: translateX(-50%) translateY(-50%) scale(1);    opacity: 0.5; }
  35%      { transform: translateX(-47%) translateY(-53%) scale(1.08); opacity: 0.62; }
  70%      { transform: translateX(-53%) translateY(-47%) scale(0.93); opacity: 0.38; }
}
@keyframes badge-pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(212,105,74,0); }
  50%      { box-shadow: 0 0 0 5px rgba(212,105,74,0.12); }
}
@keyframes shimmer {
  from { background-position: -400% center; }
  to   { background-position:  400% center; }
}
@keyframes fade-up {
  from { opacity:0; transform:translateY(24px); }
  to   { opacity:1; transform:translateY(0); }
}

/* ── Layout ── */
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

/* ── Header ── */
.site-header {
  background: rgba(12,11,7,0.88);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: 200;
}
.site-header .container { display:flex; align-items:center; justify-content:space-between; }
.brand {
  font-family: "video", 'Bebas Neue', serif;
  font-size: 1.15rem;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.06em;
  transition: color 0.2s;
  display: flex;
  align-items: center;
}
.brand:hover { color: var(--gold-light); }
.nav a {
  margin-left: 28px;
  color: rgba(255,255,255,0.42);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: color 0.2s;
}
.nav a:hover { color: #fff; }

/* ── Hero ── */
.hero {
  background: var(--hero-bg);
  padding: 120px 0 110px;
  position: relative;
  overflow: hidden;
  text-align: center;
}

/* Giant animated coral orb — center must be INSIDE the viewport */
.hero::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1200px;
  height: 1000px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center,
    rgba(212,105,74,0.5)  0%,
    rgba(212,105,74,0.28) 20%,
    rgba(212,105,74,0.1)  45%,
    transparent 68%);
  pointer-events: none;
  transform: translateX(-50%) translateY(-50%);
  animation: orb-drift 14s ease-in-out infinite;
  will-change: transform, opacity;
}

/* Gold accent orbs + vignette */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 45% at 6%  90%, rgba(212,144,26,0.2)  0%, transparent 60%),
    radial-gradient(ellipse 40% 50% at 94% 75%, rgba(100,60,40,0.12)  0%, transparent 60%),
    radial-gradient(ellipse 25% 30% at 70% 8%,  rgba(212,105,74,0.1)  0%, transparent 65%),
    linear-gradient(to bottom, transparent 60%, rgba(12,11,7,0.5) 100%);
  pointer-events: none;
}

.hero .container {
  position: relative;
  z-index: 1;
  text-align: center;
}

/* Dot grid behind hero content */
.hero .container::before {
  content: '';
  position: absolute;
  inset: -60px;
  background-image: radial-gradient(circle, rgba(255,255,255,0.055) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse 75% 70% at 50% 50%, black 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 75% 70% at 50% 50%, black 30%, transparent 100%);
}

.hero h1 {
  background: linear-gradient(140deg, #fff 0%, rgba(232,135,94,0.88) 38%, rgba(255,255,255,0.95) 62%, rgba(212,144,26,0.7) 85%, #fff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 80px rgba(212,105,74,0.45)) drop-shadow(0 4px 8px rgba(0,0,0,0.5));
  position: relative;
}
.hero .lede {
  font-size: clamp(1.05rem, 2.5vw, 1.3rem);
  color: rgba(255,255,255,0.58);
  font-weight: 300;
  letter-spacing: 0.015em;
  max-width: 500px;
  margin: 0 auto 1.3em;
}
.hero p { color: rgba(255,255,255,0.44); max-width: 560px; margin-left: auto; margin-right: auto; }
.hero a { color: var(--coral-light); }
.hero a:hover { color: #fff; }

.hero-rule {
  width: 100px;
  height: 1px;
  border: none;
  margin: 32px auto 40px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(212,105,74,0.3) 20%,
    var(--coral) 45%,
    var(--gold-light) 55%,
    rgba(212,144,26,0.3) 80%,
    transparent 100%);
  position: relative;
}
.hero-rule::after {
  content: '';
  position: absolute;
  top: -3px;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 7px;
  background: var(--coral);
  border-radius: 4px;
  filter: blur(4px);
  opacity: 0.65;
}

/* ── Badge ── */
.badge-level {
  display: inline-block;
  background: rgba(212,105,74,0.12);
  color: var(--coral-light);
  border: 1px solid rgba(212,105,74,0.32);
  font-family: 'Very Simple Chalk', cursive;
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 7px 18px;
  border-radius: 24px;
  margin-bottom: 32px;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
  animation: badge-pulse 3s ease-in-out infinite;
}

/* ── Eyebrow ── */
.eyebrow {
  font-family: 'Very Simple Chalk', cursive;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 14px;
  display: block;
}
.section-dark .eyebrow { color: var(--gold-light); }
.hero .eyebrow { color: var(--gold-light); width: fit-content; margin-left: auto; margin-right: auto; }

/* ── Conversation block ── */
.convo {
  margin: 2.4em auto;
  max-width: 560px;
  border-radius: 14px;
  overflow: hidden;
  font-size: 0.92rem;
  text-align: left;
  box-shadow:
    0 2px 0 rgba(255,255,255,0.04) inset,
    0 20px 60px rgba(0,0,0,0.45),
    0 4px 16px rgba(0,0,0,0.25),
    0 0 0 1px rgba(255,255,255,0.05);
}
.convo-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.61rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 12px 20px 2px;
  opacity: 0.6;
  display: block;
}
.convo-user {
  background: #1c1814;
  color: #ede3d6;
  padding: 2px 20px 20px;
}
.convo-user .convo-label { color: var(--gold-light); opacity: 0.85; }
.convo-claude {
  background: linear-gradient(160deg, #f8f3ee 0%, #f1e9e1 100%);
  color: var(--ink);
  padding: 2px 20px 20px;
  border-top: 1px solid rgba(212,105,74,0.1);
}
.convo-claude .convo-label { color: var(--coral-dark); opacity: 0.85; }

section:not(.hero) .convo {
  box-shadow: 0 8px 32px rgba(44,30,20,0.1), 0 0 0 1px rgba(44,30,20,0.06);
}

/* ── Prompt block ── */
.prompt-block {
  background: #171310;
  color: #e8ddd0;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.86rem;
  padding: 24px 26px;
  border-radius: 10px;
  border-left: 2px solid var(--gold);
  margin: 2.2em 0;
  overflow-x: auto;
  line-height: 1.68;
  box-shadow: 0 8px 32px rgba(0,0,0,0.22), 0 0 0 1px rgba(255,255,255,0.03);
}
.prompt-block .prompt-label {
  color: var(--gold-light);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 16px;
  display: block;
  opacity: 0.75;
}

/* ── Sections ── */
section { padding: 96px 0; }
.section-soft { background: var(--bg-soft); }

/* Series section — matrix hacker: near-black with neon green grid */
#series {
  background: linear-gradient(160deg, #010a03 0%, #031408 45%, #010a03 100%);
}

#series::before {
  background: radial-gradient(ellipse,
    rgba(0,255,100,0.15) 0%,
    rgba(0,200,80,0.06) 38%,
    rgba(0,150,60,0.02) 62%,
    transparent 75%) !important;
}

/* Scan-line grid overlay */
#series::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,255,70,0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,70,0.028) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

/* Borders only between consecutive light sections */
section + section:not(.hero):not(.section-dark):not(.section-orange):not(.section-about-orange):not(.section-white) {
  border-top: 1px solid var(--rule);
}
.section-dark + section,
section + .section-dark,
.section-orange + section,
section + .section-orange,
.section-about-orange + section,
section + .section-about-orange {
  border-top: none;
}

/* Light section interior accent line under h2 */
section:not(.hero):not(.section-dark):not(.section-page-dark) h2::after {
  content: '';
  display: block;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--coral), var(--gold));
  margin-top: 14px;
  border-radius: 2px;
}

/* Warm ambient glow on plain sections — excludes all dark variants */
section:not(.hero):not(.section-dark):not(.section-soft):not(.section-about-dark):not(.section-orange):not(.section-about-orange):not(.section-white):not(.section-page-dark) {
  background: linear-gradient(180deg, var(--bg) 0%, #fdf8f2 100%);
}

.section-dark {
  background: var(--hero-bg);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.section-dark::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translateX(-50%) translateY(-50%);
  width: 1000px;
  height: 700px;
  background: radial-gradient(ellipse,
    rgba(212,144,26,0.35) 0%,
    rgba(212,105,74,0.18) 30%,
    rgba(212,105,74,0.06) 60%,
    transparent 75%);
  pointer-events: none;
}
.section-dark .container { position: relative; z-index: 1; }
.section-dark h2 {
  color: #fff;
  margin-top: 0;
  text-shadow: 0 0 60px rgba(212,144,26,0.3);
}
.section-dark p { color: rgba(255,255,255,0.56); }
.section-dark h2::after { display: none; }

/* ── Books grid ── */
.books { display: grid; grid-template-columns: 1fr; gap: 18px; margin-top: 2em; }
@media (min-width: 560px) { .books { grid-template-columns: 1fr 1fr; } }

/* Gradient border via padding-box/border-box — works reliably */
.book-card {
  border-radius: 12px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
  background: var(--bg);
  border: 1px solid var(--rule);
}
.book-card:hover {
  transform: translateY(-6px);
  background:
    linear-gradient(var(--bg), var(--bg)) padding-box,
    linear-gradient(135deg, var(--coral) 0%, var(--gold-light) 50%, var(--coral-light) 100%) border-box;
  border: 1px solid transparent;
  box-shadow:
    0 20px 60px rgba(44,30,20,0.16),
    0 6px 20px rgba(212,105,74,0.14);
}
.book-card .meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  color: var(--ink-mute);
  margin-bottom: 1em;
  text-transform: uppercase;
  letter-spacing: 0.13em;
}
.book-card h3 { margin: 0 0 0.5em; font-size: 1.1rem; }
.book-card p { font-size: 0.91rem; color: var(--ink-soft); flex: 1; margin-bottom: 0; }

.book-card.live {
  background:
    linear-gradient(150deg, #fff8f4 0%, #fffcf9 100%) padding-box,
    linear-gradient(135deg, var(--coral), var(--gold-light)) border-box;
  border: 1px solid transparent;
  box-shadow: 0 4px 24px rgba(212,105,74,0.1);
}
.book-card.live::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--coral-dark), var(--coral-light), var(--gold-light));
  border-radius: 12px 12px 0 0;
}
.book-card.live .meta { color: var(--coral); }
.book-card.live:hover { transform: translateY(-6px); box-shadow: 0 20px 60px rgba(44,30,20,0.16), 0 6px 20px rgba(212,105,74,0.18); }

.book-num {
  position: absolute;
  bottom: -16px; right: 6px;
  font-family: 'DM Serif Display', serif;
  font-size: 7.5rem;
  color: var(--coral);
  opacity: 0.08;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

/* ── Buttons ── */
.btn {
  display: inline-block;
  background: var(--coral);
  color: #fff;
  padding: 14px 32px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.96rem;
  border: none;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  letter-spacing: 0.025em;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  position: relative;
  overflow: hidden;
}
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,0.25) 50%, transparent 65%);
  background-size: 400% 100%;
  background-position: -400% center;
  transition: none;
}
.btn:hover {
  background: var(--coral-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(212,105,74,0.45), 0 3px 10px rgba(212,105,74,0.25);
}
.btn:hover::after { animation: shimmer 0.65s ease forwards; }
.btn:disabled { opacity: 0.5; cursor:default; transform:none; box-shadow:none; }

.btn-ghost {
  background: transparent;
  color: var(--coral);
  border: 1.5px solid rgba(212,105,74,0.4);
}
.btn-ghost::after { display: none; }
.btn-ghost:hover {
  background: rgba(212,105,74,0.06);
  border-color: var(--coral);
  box-shadow: none;
  transform: translateY(-1px);
}

.btn-light {
  background: rgba(255,255,255,0.96);
  color: var(--coral-dark);
  font-weight: 700;
}
.btn-light::after { display: none; }
.btn-light:hover,
.hero .btn-light:hover,
.section-dark .btn-light:hover {
  background: #fff;
  color: var(--coral-dark) !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}

/* ── Badge amber ── */
.badge-amber {
  display: inline-block;
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  color: #fff;
  font-size: 0.66rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 11px;
  border-radius: 4px;
  vertical-align: middle;
  text-shadow: 0 1px 2px rgba(0,0,0,0.18);
}

/* ── Newsletter form ── */
.nl-form { max-width: 460px; margin-top: 1.6em; }
.nl-form .row { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.nl-form input[type="text"],
.nl-form input[type="email"] {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 8px;
  font-size: 0.97rem;
  font-family: 'Outfit', sans-serif;
  background: rgba(255,255,255,0.1);
  color: #fff;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2) inset;
}
.nl-form input::placeholder { color: rgba(255,255,255,0.28); }
.nl-form input:focus {
  outline: none;
  border-color: rgba(212,105,74,0.6);
  background: rgba(255,255,255,0.1);
  box-shadow: 0 0 0 4px rgba(212,105,74,0.14);
}
.nl-honey { display: none !important; }
.nl-msg { font-size: 0.94rem; min-height: 1.6em; color: rgba(255,255,255,0.58); }
.nl-msg.ok  { color: #6ee7b7; font-weight: 500; }
.nl-msg.err { color: #fca5a5; }

.nl-form-light input[type="text"],
.nl-form-light input[type="email"] {
  border: 1px solid #d5c8c0;
  background: #fff;
  color: var(--ink);
}
.nl-form-light input::placeholder { color: var(--ink-mute); }
.nl-form-light input:focus { border-color: var(--coral); box-shadow: 0 0 0 3px rgba(212,105,74,0.1); }
.nl-form-light .nl-msg { color: var(--ink-soft); }
.nl-form-light .nl-msg.ok  { color: var(--ok); }
.nl-form-light .nl-msg.err { color: var(--err); }

/* ── Learn list ── */
.learn-list li { margin-bottom: 0.65em; }
.learn-list li strong {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85em;
  background: var(--coral-pale);
  color: var(--coral-dark);
  padding: 2px 7px;
  border-radius: 3px;
  font-weight: 500;
}

/* ── Excerpt ── */
.excerpt {
  border-left: 2px solid var(--gold);
  padding: 6px 0 6px 22px;
  margin: 2.2em 0;
  color: var(--ink-soft);
  font-style: italic;
  font-family: 'DM Serif Display', serif;
  font-size: 1.08rem;
  line-height: 1.55;
}

/* ── Solid burnt-orange section ── */
.section-orange {
  background: #C04E14 !important;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.section-orange h2 { color: #fff; text-shadow: none; }
.section-orange h2::after {
  background: linear-gradient(90deg, rgba(255,255,255,0.55), rgba(255,255,255,0.15)) !important;
}
.section-orange .eyebrow { color: rgba(255,255,255,0.72); }
.section-orange p { color: rgba(255,255,255,0.82); }
.section-orange .about-lede { color: rgba(255,255,255,0.95) !important; border-left-color: rgba(255,255,255,0.5) !important; }
.section-orange a { color: #fff; }
.section-orange a.btn { color: #fff !important; }
.section-orange a.btn:hover { color: #fff !important; }

/* About section orange variant (slightly darker) */
.section-about-orange {
  background: #A83D0E;
}

/* ── White section ── */
.section-white {
  background: #fff !important;
  color: var(--ink);
}
.section-white h2 { color: var(--ink); margin-top: 0; text-shadow: none; }
.section-white .eyebrow { color: var(--coral); }
.section-white p { color: var(--ink-soft); }
.section-white .small { color: var(--ink-mute); }

/* ── Footer ── */
.site-footer {
  background: #180d04;
  border-top: 1px solid rgba(212,105,74,0.12);
  padding: 40px 0;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.26);
}
.site-footer .container { display:flex; justify-content:space-between; flex-wrap:wrap; gap:12px; align-items:center; }
.site-footer a { color: rgba(255,255,255,0.26); text-decoration:none; transition:color 0.2s; }
.site-footer a:hover { color: var(--gold-light); }

/* ── Chalk utility ── */
.chalk {
  font-family: 'Very Simple Chalk', cursive;
  letter-spacing: 0.06em;
}

/* Book card titles use chalk to echo the cover aesthetic */
.book-card-featured h3,
.book-card-dark h3 {
  font-family: 'Very Simple Chalk', cursive;
  letter-spacing: 0.04em;
  font-size: 1.75rem;
  line-height: 1.15;
}

/* ── Utilities ── */
.muted { color: var(--ink-mute); }
.small { font-size: 0.87rem; }
.center { text-align: center; }
.mt1 { margin-top: 1em; }
.mt2 { margin-top: 2em; }

/* Fade-up class added by animations.js */
.fade-up { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* ── Responsive ── */
@media (max-width: 600px) {
  .hero { padding: 80px 0 70px; text-align: left; }
  .hero .container { text-align: left; }
  .hero::before { width: 500px; height: 500px; }
  .hero h1 { font-size: 3rem; }
  .hero .lede, .hero p { margin-left: 0; margin-right: 0; }
  .badge-level { margin-left: 0; }
  .hero-rule { margin-left: 0; }
  .convo { max-width: 100%; }
  section { padding: 64px 0; }
}

/* ── Modal ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(12,11,7,0.85);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.modal-overlay.visible { opacity: 1; pointer-events: all; }
.modal-box {
  background: var(--hero-mid);
  border: 1px solid rgba(212,105,74,0.2);
  border-radius: 16px;
  padding: 44px 38px;
  max-width: 420px; width: 100%;
  position: relative; color: #fff;
  box-shadow:
    0 40px 100px rgba(0,0,0,0.7),
    0 0 0 1px rgba(255,255,255,0.03) inset,
    0 0 80px rgba(212,105,74,0.08) inset;
}
.modal-box::before {
  content: '';
  position: absolute;
  top: 0; left: 24px; right: 24px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,105,74,0.7), rgba(212,144,26,0.5), transparent);
}
.modal-close {
  position: absolute; top: 18px; right: 20px;
  background: none; border: none;
  color: rgba(255,255,255,0.25);
  font-size: 1.2rem; cursor: pointer; padding: 4px 6px; line-height: 1;
  transition: color 0.2s;
}
.modal-close:hover { color: rgba(255,255,255,0.8); }
.modal-box h3 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.6rem; color: #fff; margin: 0 0 0.35em;
}
.modal-box p { color: rgba(255,255,255,0.5); font-size: 0.93rem; margin-bottom: 1.5em; }
.modal-box .eyebrow { color: var(--gold-light); margin-bottom: 12px; }

/* ── Blog post cards ── */
.post-card {
  border-bottom: 1px solid var(--rule);
  padding: 2em 0;
  transition: padding-left 0.25s ease;
}
.post-card:first-child { padding-top: 0; }
.post-card:last-child { border-bottom: none; }
.post-card:hover { padding-left: 6px; }
.post-card h3 { margin: 0.2em 0 0.45em; font-size: 1.12rem; }
.post-card p { margin: 0 0 0.9em; color: var(--ink-soft); font-size: 0.93rem; }

/* ── Pull quote / featured text ── */
.pull-quote {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  line-height: 1.35;
  color: var(--ink);
  border-left: 3px solid var(--coral);
  padding: 8px 0 8px 28px;
  margin: 2.5em 0;
  font-style: italic;
}
.section-dark .pull-quote {
  color: rgba(255,255,255,0.85);
  border-left-color: var(--gold-light);
}

/* ── About section accent ── */
.about-lede {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(1.15rem, 2.5vw, 1.5rem);
  line-height: 1.45;
  color: var(--ink-soft);
  font-style: italic;
  margin-bottom: 1.5em;
}

/* ── Horizontal section rule ── */
.section-rule {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--rule) 20%, var(--rule) 80%, transparent);
  border: none;
  margin: 0;
}

/* ── Highlighted inline stat ── */
.stat-inline {
  font-family: 'DM Serif Display', serif;
  font-size: 1.1em;
  color: var(--coral);
  font-style: normal;
}

/* ── Featured book card (Book 1) ── */
.book-card-featured {
  background: linear-gradient(135deg, #1c1710 0%, #0e0d08 100%);
  border: 1px solid rgba(212,105,74,0.22);
  border-radius: 16px;
  padding: 44px 48px;
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}
.book-card-featured::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--coral-dark), var(--coral-light) 50%, var(--gold-light));
}
.book-card-featured::after {
  content: '';
  position: absolute;
  top: 40%; left: 40%;
  transform: translateX(-50%) translateY(-50%);
  width: 700px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(ellipse,
    rgba(212,105,74,0.3) 0%,
    rgba(212,105,74,0.14) 35%,
    rgba(212,144,26,0.06) 60%,
    transparent 72%);
  pointer-events: none;
}
.book-card-featured:hover {
  border-color: rgba(212,105,74,0.45);
  box-shadow: 0 24px 60px rgba(0,0,0,0.4), 0 0 0 1px rgba(212,105,74,0.15);
}
.book-card-featured .bcf-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--coral-light);
  margin-bottom: 14px;
  position: relative; z-index: 1;
}
.book-card-featured h3 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: #fff;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
  position: relative; z-index: 1;
}
.book-card-featured p {
  color: rgba(255,255,255,0.52);
  max-width: 520px;
  margin-bottom: 2em;
  font-size: 1rem;
  position: relative; z-index: 1;
}
.book-card-featured .bcf-num {
  position: absolute;
  right: 24px;
  bottom: -30px;
  font-family: 'DM Serif Display', serif;
  font-size: 14rem;
  color: var(--coral-light);
  opacity: 0.11;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

/* Featured card two-column layout with cover */
.bcf-inner {
  display: flex;
  gap: 36px;
  align-items: flex-start;
  position: relative;
  z-index: 1;
}
.bcf-text { flex: 1; min-width: 0; }
.bcf-cover { flex-shrink: 0; }
.bcf-cover-img {
  width: 130px;
  border-radius: 6px;
  display: block;
  box-shadow:
    0 12px 40px rgba(0,0,0,0.55),
    0 3px 10px rgba(0,0,0,0.4),
    0 0 0 1px rgba(255,255,255,0.06);
}
@media (max-width: 560px) {
  .bcf-inner { flex-direction: column-reverse; gap: 20px; }
  .bcf-cover-img { width: 100px; }
}

/* ── Dark book cards for coming-soon books ── */
.book-card-dark {
  background: linear-gradient(135deg, #1c1008 0%, #160d06 100%) padding-box,
    linear-gradient(135deg, rgba(212,105,74,0.18) 0%, rgba(212,144,26,0.07) 100%) border-box;
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}
.book-card-dark::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(212,105,74,0.35) 40%, rgba(212,144,26,0.2) 60%, transparent 100%);
  opacity: 0;
  transition: opacity 0.25s ease;
}
.book-card-dark:hover {
  transform: translateY(-5px);
  background:
    linear-gradient(135deg, #1c1610 0%, #161209 100%) padding-box,
    linear-gradient(135deg, var(--coral) 0%, var(--gold-light) 55%, var(--coral-light) 100%) border-box;
  box-shadow:
    0 20px 56px rgba(0,0,0,0.45),
    0 0 32px rgba(212,105,74,0.12);
}
.book-card-dark:hover::before { opacity: 1; }
.book-card-dark .meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.64rem;
  color: rgba(255,255,255,0.3);
  margin-bottom: 0.9em;
  text-transform: uppercase;
  letter-spacing: 0.13em;
}
.book-card-dark h3 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  font-size: 1.25rem;
  color: rgba(255,255,255,0.92);
  margin: 0 0 0.5em;
  letter-spacing: -0.015em;
}
.book-card-dark p {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.48);
  flex: 1;
  margin-bottom: 0;
  line-height: 1.6;
}
.book-card-dark .book-num {
  color: var(--coral);
  opacity: 0.15;
}

/* Dark books grid */
.books-dark-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
@media (max-width: 560px) {
  .books-dark-grid { grid-template-columns: 1fr; }
  .book-card-featured { padding: 32px 28px; }
}

/* About section pull quote */
.about-lede {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(1.2rem, 2.5vw, 1.55rem);
  line-height: 1.4;
  color: var(--ink-soft);
  font-style: italic;
  margin-bottom: 1.8em;
  padding-left: 24px;
  border-left: 2px solid var(--coral);
}

/* ── About section: orange accent — explicit class only ── */
/* NOTE: removed main > section:last-child positional override — it broke
   single-section pages (newsletter, bundles) by forcing them orange. */

/* ── Coming-soon badge on featured cards ── */
.book-card-featured .badge-soon {
  background: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.6);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
}

/* ── About section (orange) ── */
.section-about-dark {
  background: #A83D0E;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.section-about-dark::before {
  content: '';
  position: absolute;
  top: 50%; right: -200px;
  transform: translateY(-50%);
  width: 700px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0,0,0,0.18) 0%, transparent 65%);
  pointer-events: none;
}
.section-about-dark .container { position: relative; z-index: 1; }
.section-about-dark h2 { color: #fff; text-shadow: none; }
.section-about-dark h2::after {
  display: block; content: '';
  width: 40px; height: 2px;
  background: linear-gradient(90deg, rgba(255,255,255,0.6), rgba(255,255,255,0.2));
  margin-top: 14px; border-radius: 2px;
}
.section-about-dark .eyebrow { color: rgba(255,255,255,0.72); }
.section-about-dark p { color: rgba(255,255,255,0.82); }
.section-about-dark .about-lede {
  color: rgba(255,255,255,0.95);
  border-left-color: rgba(255,255,255,0.5);
}


/* ═══════════════════════════════════════════
   v20 — glow system · terminal block · hooks
   ═══════════════════════════════════════════ */

/* Convo block — glowing top accent line */
.convo { position: relative; }
.convo::before {
  content: '';
  position: absolute;
  top: -1px; left: 12%; right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,105,74,0.6), rgba(212,144,26,0.4), transparent);
  pointer-events: none;
  z-index: 2;
}

/* Stronger glow in dark/hero contexts */
.hero .convo,
.section-dark .convo {
  box-shadow:
    0 2px 0 rgba(255,255,255,0.04) inset,
    0 24px 70px rgba(0,0,0,0.6),
    0 4px 16px rgba(0,0,0,0.35),
    0 0 0 1px rgba(255,255,255,0.06),
    0 0 80px rgba(212,105,74,0.13),
    0 0 200px rgba(212,105,74,0.05);
}

/* Excerpt — hover glow */
.excerpt {
  transition: border-color 0.3s ease, box-shadow 0.3s ease, padding-left 0.3s ease;
}
.excerpt:hover {
  border-left-color: var(--gold-light);
  box-shadow: -6px 0 24px rgba(212,144,26,0.1);
  padding-left: 26px;
}

/* Learn-list keys — hover glow */
.learn-list li strong {
  transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}
.learn-list li strong:hover {
  background: var(--coral);
  color: #fff;
  box-shadow: 0 0 10px rgba(212,105,74,0.4), 0 0 22px rgba(212,105,74,0.14);
  cursor: default;
}

/* Book page hero cover — glow on hover */
.hero img {
  transition: box-shadow 0.35s ease, filter 0.35s ease !important;
}
.hero img:hover {
  box-shadow:
    0 20px 60px rgba(0,0,0,0.72),
    0 4px 16px rgba(0,0,0,0.5),
    0 0 40px rgba(212,105,74,0.22),
    0 0 80px rgba(212,105,74,0.07),
    0 0 0 1px rgba(255,255,255,0.1) !important;
  filter: brightness(1.07) !important;
}

/* Prompt block — hover glow */
.prompt-block {
  transition: box-shadow 0.3s ease;
}
.prompt-block:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.3), 0 0 0 1px rgba(255,255,255,0.04), 0 0 60px rgba(212,144,26,0.09);
}

/* ── Terminal block ── */
.term {
  background: #080807;
  color: #b0a898;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.83rem;
  line-height: 1.78;
  padding: 46px 24px 22px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.05);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.02) inset,
    0 12px 40px rgba(0,0,0,0.45),
    0 0 60px rgba(212,105,74,0.05);
  overflow-x: auto;
  position: relative;
  margin: 2.2em 0;
  white-space: pre;
}
.term::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 36px;
  background: #111009;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  border-radius: 10px 10px 0 0;
  pointer-events: none;
}
.term::after {
  content: '● ● ●';
  position: absolute;
  top: 11px; left: 15px;
  font-size: 9px;
  color: rgba(255,255,255,0.2);
  letter-spacing: 4px;
  pointer-events: none;
}
.term-title {
  position: absolute;
  top: 11px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  color: rgba(255,255,255,0.22);
  letter-spacing: 0.08em;
  pointer-events: none;
  white-space: nowrap;
}
.t-prompt { color: rgba(212,105,74,0.7); user-select: none; }
.t-cmd    { color: #e8ddd0; font-weight: 500; }
.t-green  { color: #7ac06a; }
.t-amber  { color: #d4901a; }
.t-dim    { color: rgba(255,255,255,0.3); }
.t-red    { color: #c05050; }
.t-hi     { color: #e8c87a; font-weight: 500; }
.t-path   { color: #7a9abf; }
.t-num    { color: #c080a0; }
.kv-row   { display: flex; gap: 16px; }
.kv-key   { color: rgba(255,255,255,0.32); min-width: 140px; flex-shrink: 0; }
.kv-ok    { color: #7ac06a; }
.kv-warn  { color: #d4901a; }
.kv-err   { color: #c05050; }

/* ── Inline hook tag ── */
.hook-tag {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78em;
  background: rgba(212,105,74,0.1);
  color: var(--coral-light);
  border: 1px solid rgba(212,105,74,0.22);
  padding: 1px 8px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.hook-tag:hover {
  background: rgba(212,105,74,0.18);
  border-color: rgba(212,105,74,0.45);
  box-shadow: 0 0 8px rgba(212,105,74,0.2);
  cursor: default;
}
.section-dark .hook-tag,
.hero .hook-tag {
  background: rgba(212,105,74,0.12);
  color: var(--coral-light);
  border-color: rgba(212,105,74,0.28);
}

/* btn hover — tighter glow ring */
.btn:hover {
  box-shadow: 0 8px 28px rgba(212,105,74,0.45), 0 3px 10px rgba(212,105,74,0.25), 0 0 0 1px rgba(212,105,74,0.18);
}

/* ═══════════════════════════════════════════
   v22 — site-wide dark aesthetic · HUD chrome
   ═══════════════════════════════════════════ */

/* hero-hacker base: shared dark bg + suppress coral orb + white h1.
   index.html's inline <style> adds the 3-column layout overrides on top. */
.hero.hero-hacker {
  background-color: #000a04;
}
.hero.hero-hacker::before,
.hero.hero-hacker::after { display: none; }
.hero.hero-hacker h1 {
  background: none !important;
  -webkit-background-clip: unset !important;
  background-clip: unset !important;
  -webkit-text-fill-color: #fff !important;
  color: #fff;
  filter: none;
}

/* HUD corner readouts */
.hk-hud {
  position: absolute; pointer-events: none; z-index: 2;
  font-family: 'JetBrains Mono', monospace;
  font-size: .56rem; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(0,255,180,.45); line-height: 1.8;
}
.hk-hud-tl { top: 14px; left: 20px; text-align: left; }
.hk-hud-tr { top: 14px; right: 20px; text-align: right; }
.hk-hud-bl { bottom: 14px; left: 20px; }
.hk-hud-br { bottom: 14px; right: 20px; text-align: right; }

/* Corner brackets */
.hk-bk {
  position: absolute; width: 20px; height: 20px;
  border-color: rgba(0,255,180,.32); border-style: solid;
  pointer-events: none; z-index: 2;
}
.hk-bk-tl { top: 8px; left: 8px;   border-width: 1px 0 0 1px; }
.hk-bk-tr { top: 8px; right: 8px;  border-width: 1px 1px 0 0; }
.hk-bk-bl { bottom: 8px; left: 8px;  border-width: 0 0 1px 1px; }
.hk-bk-br { bottom: 8px; right: 8px; border-width: 0 1px 1px 0; }

/* Dark content section — used on secondary pages to replace light sections */
.section-page-dark {
  background: #0c0b07 !important;
  color: rgba(255,255,255,0.75);
  position: relative;
}
.section-page-dark h2 { color: #fff; }
.section-page-dark h3 { color: rgba(255,255,255,0.9); }
.section-page-dark p  { color: rgba(255,255,255,0.65); }
.section-page-dark a  { color: var(--coral-light); }
.section-page-dark a.btn { color: #fff !important; }
.section-page-dark a.btn:hover { color: #fff !important; }
.section-page-dark code { background: rgba(212,105,74,0.12); color: var(--coral-light); }
.section-page-dark h2::after { display: none; }
.section-page-dark .eyebrow { color: var(--gold-light); }
.section-page-dark strong { color: rgba(255,255,255,0.88); }
.section-page-dark .muted,
.section-page-dark .small { color: rgba(255,255,255,0.38); }

/* Book thumb strip inside dark sections */
.section-page-dark .book-strip-thumb {
  color: rgba(255,255,255,0.7);
}
.section-page-dark .book-strip-thumb span {
  color: rgba(255,255,255,0.55);
}
