/* Shared article stylesheet. Same tokens as the site: white canvas, bold
   headlines, mono stamps, electric accent. Change --accent to re-color. */
:root {
  --ink: #0b0b0f; --muted: #5b5b66; --faint: #8a8a94; --line: #e8e8ec; --wash: #f5f6f8;
  --accent: #2e5bff; --accent-hover: #1e45e0;
  --display: 'Inter Tight', 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Menlo, monospace;
}
* { box-sizing: border-box; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
html, body { margin: 0; padding: 0; background: #fff; color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Site bar */
.site-bar { border-bottom: 1px solid var(--line); }
.site-bar .inner { max-width: 1040px; margin: 0 auto; padding: 0 20px; height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.wordmark { font-family: var(--display); font-weight: 800; font-size: 18px; letter-spacing: -0.02em; color: var(--ink); }
.wordmark .dot { color: var(--accent); }
.site-bar nav { display: flex; gap: 18px; font-size: 14px; font-weight: 500; }
.site-bar nav a { color: var(--muted); }
.site-bar nav a:hover { color: var(--ink); }

.wrap { max-width: 680px; margin: 0 auto; padding: 0 20px 96px; }

/* Masthead */
.masthead { padding: 56px 0 36px; border-bottom: 1px solid var(--line); }
@media (min-width: 760px) { .masthead { padding: 80px 0 44px; } }
.byline { font-family: var(--mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin: 0 0 16px; }
h1 { font-family: var(--display); font-weight: 800; font-size: clamp(36px, 7vw, 56px); line-height: 1.02; letter-spacing: -0.025em; margin: 0 0 22px; }
.lede { font-size: 19px; line-height: 1.55; color: var(--muted); margin: 0; max-width: 60ch; }
.disclaimer, .note { font-family: var(--mono); font-size: 12px; line-height: 1.6; color: var(--muted); background: var(--wash); border-radius: 10px; padding: 12px 14px; margin: 24px 0 0; }

/* Chapters */
section.chapter { padding-top: 56px; }
.chapter-head { display: grid; grid-template-columns: 56px 1fr; align-items: baseline; gap: 16px; margin-bottom: 6px; }
.numeral { font-family: var(--mono); font-size: 13px; color: var(--accent); letter-spacing: 0.08em; }
h2 { font-family: var(--display); font-weight: 800; font-size: clamp(26px, 4.5vw, 34px); letter-spacing: -0.02em; line-height: 1.1; margin: 0; }
.chapter-dek { grid-column: 2; font-size: 15px; color: var(--muted); margin: 0 0 24px; max-width: 56ch; }
.chapter-rule { height: 1px; background: var(--line); margin: 0 0 28px; }

/* Lessons / steps */
.lesson, .step { display: grid; grid-template-columns: 56px 1fr; gap: 16px; margin-bottom: 26px; }
.stamp { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; color: var(--accent); border: 1px solid var(--line); border-radius: 6px; padding: 3px 6px; text-align: center; height: fit-content; white-space: nowrap; margin-top: 3px; }
.lesson p, .step p { margin: 0; font-size: 17px; line-height: 1.7; }
.lesson strong, .step strong { font-weight: 700; color: var(--ink); }

/* Prompt block */
.prompt-block { background: var(--wash); border: 1px solid var(--line); border-radius: 16px; padding: 22px 20px; overflow-x: auto; }
.prompt-block pre { margin: 0; font-family: var(--mono); font-size: 13px; line-height: 1.7; color: var(--ink); white-space: pre-wrap; }
.copy-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; }
.prompt-label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.copy-row .prompt-label { margin: 0; }
.btn { font-family: var(--sans); font-weight: 600; font-size: 15px; color: #fff; background: var(--accent); border: 0; border-radius: 12px; padding: 11px 16px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; }
.btn:hover { background: var(--accent-hover); color: #fff; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn.ghost:hover { border-color: var(--ink); color: var(--ink); }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }

/* Closing */
.close-block { margin-top: 64px; padding-top: 36px; border-top: 1px solid var(--line); }
.close-block p { font-family: var(--display); font-weight: 800; font-size: 26px; line-height: 1.25; letter-spacing: -0.02em; margin: 0; max-width: 30ch; }

/* Footer nudge */
.article-foot { margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; font-size: 14px; color: var(--muted); }

@media (max-width: 560px) {
  .chapter-head, .lesson, .step { grid-template-columns: 44px 1fr; gap: 12px; }
  .chapter-dek { grid-column: 2; }
  .stamp { font-size: 10px; padding: 2px 5px; }
  .site-bar nav { gap: 12px; font-size: 13px; }
}

/* Nav call-to-action button (matches the site header) */
.site-bar nav { align-items: center; }
.site-bar nav .nav-cta { background: var(--accent); color: #fff; font-weight: 600; padding: 9px 14px; border-radius: 10px; margin-left: 6px; }
.site-bar nav .nav-cta:hover { background: var(--accent-hover); color: #fff; }
@media (max-width: 480px) { .site-bar nav .nav-cta { padding: 7px 10px; } }

/* Mobile nav: hamburger + dropdown panel */
.site-bar { position: relative; }
.nav-toggle { display: none; width: 40px; height: 40px; border: 0; background: transparent; padding: 8px; cursor: pointer; flex-direction: column; justify-content: center; gap: 5px; border-radius: 8px; }
.nav-toggle span { display: block; height: 2px; background: var(--ink); border-radius: 2px; }
@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .site-bar nav { display: none; position: absolute; top: 60px; left: 0; right: 0; flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 16px; font-size: 17px; z-index: 10; }
  .site-bar.open nav { display: flex; }
  .site-bar nav a { padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
  .site-bar nav .nav-cta { margin: 12px 0 0; text-align: center; justify-content: center; padding: 13px 16px; border-bottom: 0; color: #fff; }
}
@media (max-width: 640px) {
  .site-bar nav { align-items: stretch; text-align: left; }
  .site-bar nav .nav-cta { display: flex; }
}
.site-bar.open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.site-bar.open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-bar.open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hamburger: blue square, white lines */
.nav-toggle { background: var(--accent); border-radius: 10px; width: 42px; height: 42px; padding: 11px; }
.nav-toggle span { background: #fff; }
.nav-toggle:hover { background: var(--accent-hover); }
