/* ============================================
   KI VERSTEHEN — Design System
   Warm Cream + Teal + Coral
   ============================================ */

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

:root {
  /* Colors */
  --cream: #FDF8F3;
  --cream-deep: #F5EDE0;
  --cream-warm: #FAF2E7;
  --surface: #FFFFFF;
  --teal: #2F8F86;
  --teal-deep: #1F6B67;
  --teal-soft: #DDEFEC;
  --teal-tint: #EBF6F3;
  --coral: #E89270;
  --coral-deep: #C76A47;
  --coral-soft: #FCE3D6;
  --coral-tint: #FCF0E7;
  --sun: #F4C95D;
  --sun-soft: #FCEFC9;
  --lavender: #B8A4D4;
  --lavender-soft: #ECE4F5;
  --ink: #1F2937;
  --ink-soft: #4B5563;
  --ink-muted: #8B8275;
  --line: #E8DFD0;
  --line-soft: #F0E8D9;

  /* Type */
  --font-serif: 'Fraunces', 'Georgia', serif;
  --font-sans: 'Inter', system-ui, sans-serif;

  /* Spacing & radii */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 22px;
  --r-xl: 32px;
  --shadow-soft: 0 4px 20px rgba(47, 67, 80, 0.06);
  --shadow-lift: 0 12px 36px rgba(47, 67, 80, 0.10);
  --shadow-card: 0 2px 10px rgba(47, 67, 80, 0.04);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

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

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(253, 248, 243, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.nav-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 22px;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-logo-dot {
  width: 14px; height: 14px;
  background: var(--coral);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 4px var(--coral-soft);
}
.nav-links {
  display: flex;
  gap: 26px;
  list-style: none;
  align-items: center;
}
.nav-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  transition: color .2s;
}
.nav-links a:hover { color: var(--teal); }
.nav-cta {
  background: var(--ink);
  color: var(--cream);
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  font-size: 24px;
  cursor: pointer;
  color: var(--ink);
}

@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--cream);
    padding: 20px 32px;
    border-bottom: 1px solid var(--line);
    gap: 16px;
    align-items: flex-start;
  }
}

/* ============================================
   LAYOUT WRAPPERS
   ============================================ */
.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;
}
.wrap-narrow {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   HERO (HOMEPAGE)
   ============================================ */
.hero {
  padding: 80px 0 60px;
  position: relative;
  overflow: hidden;
}
.hero-eyebrow {
  display: inline-block;
  background: var(--coral-soft);
  color: var(--coral-deep);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .02em;
  margin-bottom: 20px;
}
.hero-title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  max-width: 900px;
  margin-bottom: 24px;
}
.hero-title em {
  font-style: italic;
  color: var(--teal);
}
.hero-lead {
  font-size: 20px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 640px;
  margin-bottom: 36px;
}
.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  border: 0;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s;
}
.btn-primary {
  background: var(--ink);
  color: var(--cream);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.btn-secondary {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
}
.btn-secondary:hover { background: var(--cream-deep); }

/* Hero decoration blobs */
.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: .5;
  z-index: -1;
}
.hero-blob.b1 { background: var(--coral); width: 320px; height: 320px; top: -80px; right: 8%; opacity: .3; }
.hero-blob.b2 { background: var(--teal); width: 260px; height: 260px; top: 30%; right: 20%; opacity: .25; }
.hero-blob.b3 { background: var(--sun); width: 220px; height: 220px; bottom: -60px; left: 5%; opacity: .35; }

/* ============================================
   SECTIONS
   ============================================ */
.section {
  padding: 80px 0;
}
.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 56px;
}
.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: 13px;
  color: var(--teal);
  font-weight: 600;
  margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
}
.section-lead {
  font-size: 18px;
  color: var(--ink-soft);
  line-height: 1.6;
}

/* ============================================
   TOPIC GRID (HOMEPAGE CARDS)
   ============================================ */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.topic-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 28px 26px;
  text-decoration: none;
  color: var(--ink);
  border: 1px solid var(--line-soft);
  transition: transform .25s, box-shadow .25s, border-color .25s;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
}
.topic-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
  border-color: var(--teal);
}
.topic-card-num {
  font-family: var(--font-serif);
  font-size: 14px;
  color: var(--ink-muted);
  font-weight: 500;
}
.topic-card-icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  background: var(--teal-soft);
  margin-bottom: 6px;
}
.topic-card.acc-coral .topic-card-icon { background: var(--coral-soft); }
.topic-card.acc-sun .topic-card-icon { background: var(--sun-soft); }
.topic-card.acc-lavender .topic-card-icon { background: var(--lavender-soft); }
.topic-card-title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.2;
}
.topic-card-desc {
  font-size: 15px;
  color: var(--ink-soft);
  line-height: 1.55;
}
.topic-card-arrow {
  margin-top: auto;
  color: var(--teal);
  font-weight: 600;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ============================================
   TOPIC PAGE HEADER
   ============================================ */
.topic-hero {
  padding: 56px 0 40px;
  background: linear-gradient(180deg, var(--cream-warm) 0%, var(--cream) 100%);
  border-bottom: 1px solid var(--line-soft);
}
.breadcrumb {
  font-size: 14px;
  color: var(--ink-muted);
  margin-bottom: 28px;
}
.breadcrumb a { color: var(--ink-soft); text-decoration: none; }
.breadcrumb a:hover { color: var(--teal); }
.breadcrumb .sep { margin: 0 8px; color: var(--ink-muted); }
.topic-meta {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.chip {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  background: var(--teal-soft);
  color: var(--teal-deep);
}
.chip.coral { background: var(--coral-soft); color: var(--coral-deep); }
.chip.sun { background: var(--sun-soft); color: #8B6914; }
.chip.lavender { background: var(--lavender-soft); color: #5E4A8B; }
.topic-title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin-bottom: 18px;
  max-width: 880px;
}
.topic-lead {
  font-size: 22px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 740px;
  font-family: var(--font-serif);
  font-weight: 400;
}

/* ============================================
   ARTICLE CONTENT
   ============================================ */
.article {
  padding: 60px 0 80px;
}
.article-body {
  max-width: 760px;
  margin: 0 auto;
}
.article-body h2 {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 32px;
  line-height: 1.2;
  margin: 48px 0 18px;
  letter-spacing: -0.01em;
}
.article-body h2:first-child { margin-top: 0; }
.article-body h3 {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 22px;
  margin: 32px 0 12px;
}
.article-body p {
  font-size: 18px;
  line-height: 1.75;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.article-body strong { color: var(--ink); font-weight: 600; }
.article-body em { color: var(--teal-deep); font-style: italic; }
.article-body ul, .article-body ol {
  margin: 0 0 22px 22px;
  font-size: 18px;
  line-height: 1.75;
  color: var(--ink-soft);
}
.article-body li { margin-bottom: 8px; }
.article-body a {
  color: var(--teal);
  text-decoration: underline;
  text-decoration-color: var(--teal-soft);
  text-underline-offset: 3px;
}

/* ============================================
   CALLOUT BOXES
   ============================================ */
.callout {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 24px 28px;
  margin: 28px 0;
  border-left: 5px solid var(--teal);
  box-shadow: var(--shadow-card);
}
.callout-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--teal);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.callout-label::before {
  content: '';
  width: 8px; height: 8px;
  background: var(--teal);
  border-radius: 50%;
}
.callout p { margin-bottom: 8px; font-size: 17px; }
.callout p:last-child { margin-bottom: 0; }

.callout.analogie { background: var(--coral-tint); border-left-color: var(--coral); }
.callout.analogie .callout-label { color: var(--coral-deep); }
.callout.analogie .callout-label::before { background: var(--coral-deep); }

.callout.merke { background: var(--teal-tint); border-left-color: var(--teal); }
.callout.merke .callout-label { color: var(--teal-deep); }
.callout.merke .callout-label::before { background: var(--teal-deep); }

.callout.beispiel { background: var(--sun-soft); border-left-color: var(--sun); }
.callout.beispiel .callout-label { color: #8B6914; }
.callout.beispiel .callout-label::before { background: #C49826; }

.callout.warnung { background: var(--lavender-soft); border-left-color: var(--lavender); }
.callout.warnung .callout-label { color: #5E4A8B; }
.callout.warnung .callout-label::before { background: var(--lavender); }

/* Pull quote */
.pull-quote {
  font-family: var(--font-serif);
  font-size: 28px;
  line-height: 1.35;
  color: var(--ink);
  font-style: italic;
  font-weight: 400;
  text-align: center;
  padding: 32px 0;
  margin: 32px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.pull-quote::before { content: '"'; color: var(--coral); font-size: 60px; line-height: 0; vertical-align: -24px; }

/* Inline highlight */
.hl {
  background: linear-gradient(180deg, transparent 55%, var(--sun-soft) 55%);
  padding: 0 2px;
}

/* Glossary term tooltip */
.term {
  border-bottom: 1.5px dotted var(--coral);
  cursor: help;
  color: var(--coral-deep);
  font-weight: 500;
}

/* ============================================
   FEATURE / EXPLAINER GRID
   ============================================ */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin: 28px 0;
}
.feature-cell {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 22px;
  border: 1px solid var(--line-soft);
}
.feature-cell-num {
  font-family: var(--font-serif);
  font-size: 32px;
  color: var(--coral);
  font-weight: 500;
  line-height: 1;
  margin-bottom: 10px;
}
.feature-cell h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink);
}
.feature-cell p {
  font-size: 15px !important;
  line-height: 1.55 !important;
  margin: 0 !important;
}

/* Compare / vs table */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 28px 0;
}
.compare-cell {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 24px;
  border: 1px solid var(--line-soft);
}
.compare-cell h4 {
  font-family: var(--font-serif);
  font-size: 20px;
  margin-bottom: 12px;
}
.compare-cell.left h4 { color: var(--teal-deep); }
.compare-cell.right h4 { color: var(--coral-deep); }
.compare-cell ul { margin: 0 0 0 18px; font-size: 16px; }

@media (max-width: 640px) {
  .compare { grid-template-columns: 1fr; }
}

/* Step process */
.steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 28px 0;
  counter-reset: step;
}
.step {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 20px 24px 20px 72px;
  position: relative;
  border: 1px solid var(--line-soft);
  counter-increment: step;
}
.step::before {
  content: counter(step);
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 36px; height: 36px;
  background: var(--teal);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-family: var(--font-serif);
}
.step h4 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 4px;
}
.step p { font-size: 15px !important; margin: 0 !important; line-height: 1.6 !important; }

/* Recap box */
.recap {
  background: linear-gradient(135deg, var(--teal-tint) 0%, var(--cream-warm) 100%);
  border-radius: var(--r-lg);
  padding: 36px;
  margin: 48px 0 0;
  border: 1px solid var(--teal-soft);
}
.recap-label {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--teal-deep);
  font-weight: 700;
  margin-bottom: 10px;
}
.recap h3 {
  font-family: var(--font-serif);
  font-size: 26px;
  margin-bottom: 16px;
}
.recap ul {
  margin-left: 22px;
  font-size: 17px;
  color: var(--ink);
}
.recap li { margin-bottom: 8px; }

/* ============================================
   PAGE NAVIGATION (PREV/NEXT)
   ============================================ */
.page-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.page-nav a {
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  padding: 20px 24px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color .2s, transform .2s;
}
.page-nav a:hover { border-color: var(--teal); transform: translateY(-2px); }
.page-nav-label {
  font-size: 13px;
  color: var(--ink-muted);
  margin-bottom: 4px;
}
.page-nav-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 500;
}
.page-nav .next { text-align: right; }

@media (max-width: 640px) {
  .page-nav { grid-template-columns: 1fr; }
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--ink);
  color: var(--cream);
  padding: 64px 0 32px;
  margin-top: 80px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer h5 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--coral);
  margin-bottom: 18px;
  font-weight: 700;
}
.footer ul { list-style: none; }
.footer li { margin-bottom: 8px; }
.footer a {
  color: rgba(253, 248, 243, 0.7);
  text-decoration: none;
  font-size: 14px;
  transition: color .2s;
}
.footer a:hover { color: var(--cream); }
.footer-brand {
  font-family: var(--font-serif);
  font-size: 24px;
  margin-bottom: 12px;
  color: var(--cream);
}
.footer-tag {
  font-size: 14px;
  color: rgba(253, 248, 243, 0.6);
  line-height: 1.6;
  max-width: 280px;
}
.footer-bottom {
  border-top: 1px solid rgba(253, 248, 243, 0.15);
  padding-top: 24px;
  font-size: 13px;
  color: rgba(253, 248, 243, 0.5);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ============================================
   QUICK STATS BAND
   ============================================ */
.stats {
  background: var(--surface);
  border-radius: var(--r-xl);
  padding: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 32px;
  margin: 40px 0;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--line-soft);
}
.stat { text-align: center; }
.stat-num {
  font-family: var(--font-serif);
  font-size: 48px;
  font-weight: 500;
  color: var(--teal);
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.4;
}

/* ============================================
   ANIMATIONS
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
.float { animation: float 6s ease-in-out infinite; }

/* Token visualization */
.token-demo {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 22px;
  background: var(--surface);
  border-radius: var(--r-md);
  border: 1px solid var(--line-soft);
  margin: 24px 0;
  font-family: var(--font-serif);
  font-size: 20px;
}
.token-demo .tok {
  background: var(--teal-soft);
  color: var(--teal-deep);
  padding: 4px 10px;
  border-radius: 6px;
}
.token-demo .tok:nth-child(3n) { background: var(--coral-soft); color: var(--coral-deep); }
.token-demo .tok:nth-child(5n) { background: var(--sun-soft); color: #8B6914; }

/* Neuron visualisation */
.neural-vis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  align-items: center;
  padding: 32px;
  background: var(--surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--line-soft);
  margin: 28px 0;
  position: relative;
}
.neural-col { display: flex; flex-direction: column; gap: 16px; align-items: center; }
.neuron {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 6px var(--teal-soft);
}
.neuron.coral { background: var(--coral); box-shadow: 0 0 0 6px var(--coral-soft); }
.neural-label {
  font-size: 12px;
  color: var(--ink-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  text-align: center;
  margin-bottom: 6px;
}

/* Code-ish block */
.code-block {
  background: #1F2937;
  color: #FDF8F3;
  padding: 20px 24px;
  border-radius: var(--r-md);
  font-family: 'SF Mono', Consolas, monospace;
  font-size: 14px;
  line-height: 1.7;
  overflow-x: auto;
  margin: 24px 0;
}
.code-block .c-comment { color: #8B8275; }
.code-block .c-key { color: #E89270; }
.code-block .c-str { color: #A4D4C8; }

/* Responsive */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .section { padding: 60px 0; }
  .wrap { padding: 0 22px; }
  .hero { padding: 60px 0 40px; }
  .hero-lead { font-size: 18px; }
  .article-body p { font-size: 17px; }
}

/* ============================================
   MOBILE FIXES — applied across all article/blog pages
   Prevents horizontal scroll, gives content breathing room
   ============================================ */
html, body { overflow-x: hidden; }

/* Media never breaks out of its container */
img, svg, video, canvas, iframe, picture {
  max-width: 100%;
  height: auto;
}

@media (max-width: 760px) {
  /* Wrapper paddings */
  .wrap { padding: 0 18px; }
  .wrap-narrow { padding: 0 18px; }

  /* Navigation */
  .nav-inner { padding: 14px 18px; gap: 12px; }
  .nav-logo { font-size: 19px; }
  .nav-cta { padding: 9px 14px; font-size: 13px; }

  /* Article container — was edge-to-edge on mobile, now has padding */
  .article { padding: 40px 0 60px; }
  .article-body { padding: 0 18px; }

  /* Topic / Hero header */
  .topic-hero { padding: 40px 0 32px; }
  .topic-lead { font-size: 18px; line-height: 1.5; }
  .topic-meta { margin-bottom: 14px; }
  .breadcrumb { margin-bottom: 20px; font-size: 13px; }

  /* Article typography */
  .article-body h2 { font-size: 26px; margin: 36px 0 14px; }
  .article-body h3 { font-size: 19px; margin: 26px 0 10px; }
  .article-body p { font-size: 16.5px; line-height: 1.7; }
  .article-body ul,
  .article-body ol { font-size: 16.5px; line-height: 1.7; margin-left: 20px; }

  /* Callouts — were 24px 28px, too much on narrow screens */
  .callout { padding: 18px 20px; margin: 22px 0; }
  .callout p { font-size: 15.5px; }

  /* Pull quote */
  .pull-quote { font-size: 22px; padding: 24px 0; margin: 24px 0; line-height: 1.4; }
  .pull-quote::before { font-size: 44px; vertical-align: -18px; }

  /* Recap — was 36px padding */
  .recap { padding: 24px; margin: 36px 0 0; }
  .recap h3 { font-size: 22px; }
  .recap ul { font-size: 16px; margin-left: 20px; }

  /* Grids: drop multi-col on mobile */
  .feature-grid { grid-template-columns: 1fr; gap: 12px; }
  .feature-cell { padding: 18px; }

  .topic-grid { grid-template-columns: 1fr; gap: 16px; }
  .topic-card { padding: 22px 20px; }

  /* Stats band — was 40px padding */
  .stats { padding: 24px; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
  .stat-num { font-size: 36px; }

  /* Process steps */
  .step { padding: 16px 18px 16px 58px; }
  .step::before { left: 12px; width: 32px; height: 32px; font-size: 14px; }

  /* Code blocks */
  .code-block { padding: 14px 16px; font-size: 13px; border-radius: var(--r-sm); }

  /* Neuron visualisation */
  .neural-vis { padding: 20px; gap: 16px; }
  .neuron { width: 28px; height: 28px; box-shadow: 0 0 0 4px var(--teal-soft); }
  .neuron.coral { box-shadow: 0 0 0 4px var(--coral-soft); }

  /* Token demo */
  .token-demo { padding: 16px; font-size: 16px; }

  .section { padding: 50px 0; }
  .section-header { margin-bottom: 36px; }
}

@media (max-width: 480px) {
  .wrap, .wrap-narrow { padding: 0 14px; }
  .nav-inner { padding: 12px 14px; }
  .nav-logo { font-size: 17px; }
  .nav-logo-dot { width: 11px; height: 11px; box-shadow: 0 0 0 3px var(--coral-soft); }

  .article-body { padding: 0 14px; }
  .topic-hero { padding: 32px 0 26px; }
  .topic-lead { font-size: 16.5px; }

  .article-body h2 { font-size: 23px; margin: 30px 0 12px; }
  .article-body h3 { font-size: 18px; }
  .article-body p,
  .article-body ul,
  .article-body ol { font-size: 16px; }

  .callout { padding: 16px; margin: 20px 0; }
  .callout p { font-size: 15px; }

  .pull-quote { font-size: 20px; padding: 20px 0; }
  .pull-quote::before { font-size: 38px; }

  .recap { padding: 20px; }
  .recap h3 { font-size: 20px; }
  .recap ul { font-size: 15.5px; }

  .stats { padding: 20px; grid-template-columns: 1fr 1fr; gap: 16px; }
  .stat-num { font-size: 30px; }
  .stat-label { font-size: 13px; }

  .step { padding: 14px 16px 14px 52px; }
  .step::before { width: 28px; height: 28px; font-size: 13px; }
}
