/* ============================================================
   The Recruiting AI Adoption Playbook — Ebook Styles
   ============================================================ */

:root {
  --ink: #0d1b2a;
  --ink-soft: #29384a;
  --cream: #fbf6ee;
  --cream-deep: #f3ead9;
  --paper: #ffffff;
  --rule: #d9cdb5;
  --coral: #c84b31;
  --coral-deep: #a23a24;
  --navy: #1b3a5b;
  --gold: #b58a35;
  --muted: #6b7280;

  --serif: "Fraunces", "Source Serif Pro", "Georgia", "Times New Roman", serif;
  --sans:  "Inter", "Helvetica Neue", "Arial", system-ui, -apple-system, sans-serif;
  --mono:  "JetBrains Mono", "SFMono-Regular", Menlo, Consolas, monospace;

  --max: 760px;
  --max-wide: 980px;
}

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700;9..144,800&family=Inter:wght@300;400;500;600;700&display=swap');

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Layout shell ---------- */

.page {
  max-width: var(--max);
  margin: 0 auto;
  padding: 64px 32px 96px;
}

.page--wide {
  max-width: var(--max-wide);
}

/* ---------- Top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  background: rgba(251, 246, 238, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
  z-index: 50;
}

.topbar-inner {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 14px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.topbar a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 500;
}

.topbar a:hover { color: var(--coral); }

.topbar .brand {
  font-family: var(--serif);
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
  font-size: 16px;
  color: var(--ink);
}

.topbar .brand span { color: var(--coral); }

/* ---------- Typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.015em;
}

h1 { font-size: 48px; margin: 0 0 16px; }
h2 { font-size: 32px; margin: 56px 0 16px; }
h3 { font-size: 22px; margin: 36px 0 12px; }
h4 { font-size: 18px; margin: 24px 0 8px; font-family: var(--sans); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--coral); }

p { margin: 0 0 18px; }

a { color: var(--coral-deep); }

strong { color: var(--ink); }

ul, ol { margin: 0 0 22px; padding-left: 22px; }
li { margin-bottom: 8px; }

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 48px 0;
}

/* ---------- Chapter header ---------- */

.chapter-header {
  margin-bottom: 56px;
  padding-bottom: 32px;
  border-bottom: 2px solid var(--ink);
}

.chapter-eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 14px;
}

.chapter-header h1 { font-size: 52px; margin-bottom: 8px; }

.chapter-lede {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.45;
  color: var(--ink-soft);
  margin-top: 16px;
  max-width: 640px;
}

/* ---------- Pull quotes ---------- */

.pullquote {
  margin: 40px -16px;
  padding: 36px 36px 28px 84px;
  background: var(--paper);
  border-left: 6px solid var(--coral);
  border-radius: 4px;
  position: relative;
  box-shadow: 0 2px 18px rgba(13, 27, 42, 0.05);
}

.pullquote::before {
  content: "\201C";
  font-family: var(--serif);
  font-size: 96px;
  line-height: 1;
  position: absolute;
  top: 14px;
  left: 24px;
  color: var(--coral);
  opacity: 0.4;
}

.pullquote-text {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.45;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 18px;
}

.pullquote-attr {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--muted);
}

.pullquote-attr strong { color: var(--ink); }

.pullquote-attr a {
  color: var(--coral-deep);
  text-decoration: none;
  font-weight: 500;
  margin-left: auto;
  border-bottom: 1px solid currentColor;
}

.pullquote-attr a:hover { color: var(--ink); }

/* ---------- Guest cards (inline) ---------- */

.guest-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 20px;
  align-items: start;
  margin: 36px 0;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.guest-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(13, 27, 42, 0.08);
  border-color: var(--coral);
}

.guest-photo {
  width: 120px;
  height: 120px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--cream-deep);
  flex-shrink: 0;
}

.guest-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.guest-initials {
  width: 120px;
  height: 120px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--navy), var(--coral));
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-size: 44px;
  font-weight: 700;
}

.guest-name {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 4px;
}

.guest-title {
  font-size: 14px;
  color: var(--muted);
  margin: 0 0 12px;
}

.guest-episode {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-soft);
  margin: 0 0 10px;
}

.guest-cta {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--coral);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-decoration: none;
  border-bottom: 1.5px solid var(--coral);
  padding-bottom: 2px;
}

/* ---------- Sidebar callouts ---------- */

.callout {
  margin: 32px 0;
  padding: 24px 28px;
  background: var(--cream-deep);
  border-left: 4px solid var(--gold);
  border-radius: 4px;
  position: relative;
}

.callout-eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
}

.callout-jonathan {
  background: linear-gradient(180deg, #f8f1e3, var(--cream-deep));
  border-left-color: var(--navy);
}

.callout-jonathan .callout-eyebrow {
  color: var(--navy);
}

.callout h3 {
  font-size: 19px;
  margin: 0 0 10px;
}

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

.callout-pro {
  background: #eef4ec;
  border-left-color: #3a6b4a;
}

.callout-pro .callout-eyebrow {
  color: #3a6b4a;
}

.callout-warn {
  background: #fcefe6;
  border-left-color: var(--coral);
}

.callout-warn .callout-eyebrow {
  color: var(--coral-deep);
}

/* ---------- Tables / lists ---------- */

.do-dont {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin: 32px 0;
}

.do-dont .col {
  background: var(--paper);
  border-top: 4px solid;
  padding: 20px 24px;
  border-radius: 4px;
}

.do-dont .do { border-color: #3a6b4a; }
.do-dont .dont { border-color: var(--coral); }

.do-dont h4 {
  margin-top: 0;
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 13px;
}

.do-dont .do h4 { color: #3a6b4a; }
.do-dont .dont h4 { color: var(--coral); }

.do-dont ul {
  padding-left: 20px;
  margin: 0;
}

/* ---------- Bottom nav ---------- */

.chapter-nav {
  margin-top: 80px;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
}

.chapter-nav a {
  display: block;
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
}

.chapter-nav .prev { text-align: left; }
.chapter-nav .toc  { text-align: center; }
.chapter-nav .next { text-align: right; }

.chapter-nav small {
  display: block;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 600;
}

.chapter-nav .toc a {
  font-family: var(--serif);
  font-style: italic;
  color: var(--coral);
}

.chapter-nav a:hover { color: var(--coral); }

/* ---------- Cover page ---------- */

.cover {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--ink) 0%, var(--navy) 100%);
  color: var(--cream);
  display: flex;
  align-items: center;
  padding: 80px 32px;
  position: relative;
  overflow: hidden;
}

.cover::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(200, 75, 49, 0.3), transparent 70%);
  border-radius: 50%;
}

.cover::after {
  content: "";
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(181, 138, 53, 0.2), transparent 70%);
  border-radius: 50%;
}

.cover-inner {
  max-width: var(--max-wide);
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
}

.cover-eyebrow {
  font-size: 13px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 24px;
  font-weight: 600;
}

.cover h1 {
  color: var(--cream);
  font-size: clamp(48px, 7vw, 88px);
  line-height: 1.02;
  margin-bottom: 24px;
  letter-spacing: -0.025em;
}

.cover h1 em {
  color: var(--gold);
  font-style: normal;
}

.cover-deck {
  font-family: var(--serif);
  font-size: clamp(20px, 2.4vw, 28px);
  line-height: 1.4;
  max-width: 640px;
  color: rgba(251, 246, 238, 0.85);
  margin-bottom: 48px;
}

.cover-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  font-size: 14px;
  color: rgba(251, 246, 238, 0.75);
  letter-spacing: 0.05em;
  border-top: 1px solid rgba(251, 246, 238, 0.2);
  padding-top: 28px;
}

.cover-meta strong { color: var(--cream); display: block; font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 4px; }

.cover-cta {
  display: inline-block;
  margin-top: 36px;
  padding: 16px 28px;
  background: var(--coral);
  color: var(--cream);
  text-decoration: none;
  font-weight: 600;
  border-radius: 4px;
  letter-spacing: 0.04em;
  transition: background 0.2s ease;
}

.cover-cta:hover { background: var(--coral-deep); color: var(--cream); }

.cover-cta.outline {
  background: transparent;
  color: var(--cream);
  border: 1.5px solid rgba(251, 246, 238, 0.4);
  margin-left: 12px;
}

.cover-cta.outline:hover { border-color: var(--cream); background: rgba(251, 246, 238, 0.08); }

/* ---------- TOC ---------- */

.toc-section {
  background: var(--paper);
  padding: 80px 32px;
}

.toc-inner {
  max-width: var(--max-wide);
  margin: 0 auto;
}

.toc-inner h2 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--coral);
  font-family: var(--sans);
  font-weight: 600;
  margin: 0 0 24px;
}

.toc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 0;
  margin-top: 8px;
}

.toc-item {
  display: block;
  padding: 22px 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  color: var(--ink);
  transition: padding-left 0.2s ease;
}

.toc-item:hover {
  padding-left: 8px;
  background: var(--cream);
}

.toc-num {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--coral);
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.toc-title {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.25;
}

.toc-summary {
  font-size: 14px;
  color: var(--muted);
  margin-top: 6px;
}

/* ---------- Guest gallery (page 12) ---------- */

.guest-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 40px 0;
}

.gallery-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.gallery-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(13, 27, 42, 0.1);
  border-color: var(--coral);
}

.gallery-photo {
  aspect-ratio: 16 / 9;
  background: var(--cream-deep);
  overflow: hidden;
}

.gallery-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

.gallery-photo.initials {
  background: linear-gradient(135deg, var(--navy), var(--coral));
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-size: 56px;
  font-weight: 700;
}

.gallery-body {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.gallery-name {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  margin: 0 0 2px;
}

.gallery-title {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.gallery-episode {
  font-size: 14px;
  line-height: 1.4;
  color: var(--ink-soft);
  margin: 0 0 14px;
  flex: 1;
}

.gallery-cta {
  font-size: 12px;
  font-weight: 600;
  color: var(--coral);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- AI COEE org diagram ---------- */

.coee-diagram {
  margin: 40px 0;
  padding: 32px;
  background: var(--paper);
  border-radius: 8px;
  border: 1px solid var(--rule);
}

.coee-ceo {
  text-align: center;
  background: var(--ink);
  color: var(--cream);
  padding: 14px 22px;
  border-radius: 4px;
  display: inline-block;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.coee-line {
  width: 2px;
  height: 28px;
  background: var(--ink-soft);
  margin: 0 auto;
}

.coee-box {
  background: linear-gradient(135deg, var(--coral), var(--coral-deep));
  color: var(--cream);
  padding: 24px 28px;
  border-radius: 6px;
  text-align: center;
  margin: 0 auto;
  max-width: 480px;
}

.coee-box h3 { color: var(--cream); margin: 0 0 4px; font-size: 26px; }
.coee-box p { margin: 0; font-size: 14px; opacity: 0.85; }

.coee-pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 32px;
}

.coee-pillar {
  background: var(--cream);
  padding: 22px 20px;
  border-radius: 4px;
  border-top: 4px solid var(--gold);
}

.coee-pillar h4 {
  font-family: var(--serif);
  font-size: 16px;
  margin: 0 0 8px;
  color: var(--ink);
  text-transform: none;
  letter-spacing: 0;
}

.coee-pillar ul {
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.5;
}

.coee-pillar li { margin-bottom: 4px; }

/* ---------- Phase strip ---------- */

.phase-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 24px 0 40px;
  padding: 16px 20px;
  background: var(--paper);
  border-radius: 4px;
  font-size: 12px;
  border: 1px solid var(--rule);
}

.phase-strip span {
  padding: 4px 10px;
  border-radius: 3px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.phase-strip .current {
  background: var(--coral);
  color: var(--cream);
  font-weight: 600;
}

/* ---------- CTA closing ---------- */

.cta-hero {
  background: linear-gradient(135deg, var(--ink), var(--navy));
  color: var(--cream);
  padding: 64px 48px;
  border-radius: 12px;
  margin: 40px 0;
  text-align: center;
}

.cta-hero h2 {
  color: var(--cream);
  font-size: 36px;
  margin: 0 0 16px;
}

.cta-hero p {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.5;
  max-width: 580px;
  margin: 0 auto 28px;
  color: rgba(251, 246, 238, 0.85);
}

.cta-button {
  display: inline-block;
  padding: 16px 32px;
  background: var(--coral);
  color: var(--cream);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  transition: background 0.2s ease;
}

.cta-button:hover { background: var(--coral-deep); color: var(--cream); }

/* ---------- Page numbers / print ---------- */

.page-footer {
  margin-top: 80px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ---------- Download badge ---------- */

.download-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  margin-top: 16px;
}

.download-badge:hover { border-color: var(--coral); color: var(--coral); }

/* ---------- Responsive ---------- */

@media (max-width: 720px) {
  .page { padding: 40px 22px 64px; }
  h1 { font-size: 36px; }
  h2 { font-size: 26px; }
  .chapter-header h1 { font-size: 40px; }
  .chapter-lede { font-size: 19px; }
  .pullquote { margin: 32px 0; padding: 28px 24px 24px 64px; }
  .pullquote::before { font-size: 72px; left: 16px; }
  .pullquote-text { font-size: 19px; }
  .guest-card { grid-template-columns: 80px 1fr; gap: 16px; padding: 16px; }
  .guest-photo, .guest-initials { width: 80px; height: 80px; font-size: 32px; }
  .do-dont { grid-template-columns: 1fr; }
  .coee-pillars { grid-template-columns: 1fr; }
  .chapter-nav { grid-template-columns: 1fr; gap: 16px; text-align: center; }
  .chapter-nav .prev, .chapter-nav .next { text-align: center; }
  .cover { padding: 48px 22px; }
}

/* ---------- Print styles (PDF) ---------- */

@media print {
  body { background: white; font-size: 11pt; }
  .topbar, .chapter-nav, .cover-cta, .download-badge { display: none !important; }
  .page { padding: 0; max-width: 100%; }
  .cover { min-height: auto; padding: 40px; page-break-after: always; }
  .chapter-header { page-break-before: always; }
  h1, h2, h3 { page-break-after: avoid; }
  .pullquote, .guest-card, .callout { page-break-inside: avoid; }
  a { color: var(--ink); text-decoration: none; }
  .guest-cta::after, .gallery-cta::after { content: ""; }
}

/* ============================================================
   PDF Email Gate Modal
   ============================================================ */

.pdf-gate {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}

.pdf-gate-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13, 27, 42, 0.78);
  backdrop-filter: blur(6px);
}

.pdf-gate-card {
  position: relative;
  background: var(--paper);
  color: var(--ink);
  padding: 40px 44px;
  border-radius: 12px;
  max-width: 520px;
  width: 100%;
  box-shadow: 0 24px 64px rgba(0,0,0,0.4);
  z-index: 1;
}

.pdf-gate-card h2 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 700;
  color: var(--ink);
}

.pdf-gate-card p {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0 0 20px;
}

.pdf-gate-eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 12px;
}

.pdf-gate-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: none;
  border: 0;
  font-size: 26px;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
  padding: 8px;
}
.pdf-gate-close:hover { color: var(--ink); }

.pdf-gate-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 14px 0 6px;
}

.pdf-gate-card input[type="text"],
.pdf-gate-card input[type="email"] {
  display: block;
  width: 100%;
  padding: 12px 14px;
  font-family: var(--sans);
  font-size: 15px;
  border: 1px solid var(--rule);
  border-radius: 5px;
  background: var(--cream);
  color: var(--ink);
  box-sizing: border-box;
}
.pdf-gate-card input:focus {
  outline: none;
  border-color: var(--coral);
  background: var(--paper);
}

.pdf-gate-submit {
  display: inline-block;
  margin-top: 22px;
  padding: 14px 24px;
  background: var(--coral);
  color: var(--cream);
  border: 0;
  border-radius: 4px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  text-decoration: none;
  width: 100%;
  text-align: center;
}
.pdf-gate-submit:hover { background: var(--coral-deep); color: var(--cream); }

.pdf-gate-fineprint {
  font-size: 12px !important;
  color: var(--muted) !important;
  margin: 14px 0 0 !important;
  text-align: center;
}
.pdf-gate-fineprint a { color: var(--coral-deep); }

