/* flymy.ai blog: the shared look of the guide posts (blog/<slug>/index.html).
   Editorial layout: a header over one text column, a wide hero image, and on wide screens a slim
   sticky table of contents beside the column. Brand: #f5f5f7, #1a1a1a, violet #7c3aed, Geist.
   Linked with a ?v= content hash (scripts/bust_assets.py); the header and footer keep their own CSS. */

:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --ink: #1a1a1a;
  --ink-2: #2f2f36;
  --muted: #62626b;
  --faint: #8b8b94;
  --line: rgba(0, 0, 0, 0.08);
  --line-strong: rgba(0, 0, 0, 0.14);
  --violet: #7c3aed;
  --violet-ink: #6d28d9;
  --violet-deep: #4c1d95;
  --violet-soft: rgba(124, 58, 237, 0.06);
  --violet-tint: rgba(124, 58, 237, 0.09);
  --violet-line: rgba(109, 40, 217, 0.22);
  --graphite: #141418;
  --graphite-2: #1c1c22;
  --graphite-line: rgba(255, 255, 255, 0.08);
  --green: #15803d;
  --green-soft: rgba(21, 128, 61, 0.08);
  --red: #b42318;
  --red-soft: rgba(180, 35, 24, 0.07);
  --gradient-main: linear-gradient(135deg, #09090b, #6d28d9);
  --font-display: 'Geist Sans', 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Geist Sans', 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --measure: 720px;
  --frame: 1104px;
  --shadow-soft: 0 1px 2px rgba(17, 12, 46, 0.04), 0 14px 34px -18px rgba(17, 12, 46, 0.2);
}

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

html {
  scroll-behavior: smooth;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body { background: var(--bg); min-height: 100vh; }
::selection { background: rgba(124, 58, 237, 0.18); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ---------- Page frame ---------- */

.page-shell { position: relative; z-index: 1; padding: 132px 0 112px; }
/* the dot grid of the site, only behind the header and the hero, fading out */
.page-shell::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 980px;
  background-image: radial-gradient(rgba(0, 0, 0, 0.055) 1px, transparent 1.2px);
  background-size: 28px 28px;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, 0.6) 45%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, 0.6) 45%, transparent 100%);
  pointer-events: none;
  z-index: -1;
}

.post { width: 100%; max-width: var(--frame); margin: 0 auto; padding: 0 24px; }
.post-head { max-width: var(--measure); margin: 0 auto; }
.post-head .article-sub, .post-head .byline { max-width: var(--measure); }

.crumbs {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--faint);
  margin-bottom: 30px;
}
.crumbs a { color: var(--muted); text-decoration: none; transition: color 0.15s ease; }
.crumbs a:hover { color: var(--violet-ink); }

.post-kicker {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--violet-ink);
  margin-bottom: 20px;
}
.post-kicker::before { content: ''; width: 8px; height: 8px; background: var(--violet); flex: none; }
.post-kicker .sep { color: var(--faint); }

h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(36px, 4.4vw, 56px);
  line-height: 1.04;
  letter-spacing: -0.045em;
  color: var(--ink);
  margin-bottom: 22px;
  text-wrap: balance;
}
.article-sub {
  font-size: 20px;
  line-height: 1.55;
  letter-spacing: -0.005em;
  color: var(--muted);
  text-wrap: pretty;
}
.article-sub code {
  font-family: var(--font-mono);
  font-size: 0.82em;
  color: var(--ink-2);
  background: rgba(0, 0, 0, 0.05);
  border-radius: 6px;
  padding: 1px 6px;
}

.byline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 28px;
  font-size: 14px;
  color: var(--muted);
}
.byline-avatar { width: 30px; height: 30px; border-radius: 9px; display: block; flex: none; box-shadow: 0 0 0 1px var(--line); }
.byline strong { color: var(--ink); font-weight: 600; }
.byline .dot { width: 3px; height: 3px; border-radius: 999px; background: var(--faint); }

/* ---------- Hero ---------- */

.post-hero { margin: 52px auto 68px; max-width: var(--frame); }
.post-hero img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 24px;
  background: #ececf0;
  box-shadow: 0 1px 2px rgba(17, 12, 46, 0.05), 0 42px 90px -46px rgba(17, 12, 46, 0.42);
}

/* ---------- Column and table of contents ---------- */

.post-grid { max-width: var(--measure); margin: 0 auto; }
.post-grid > article { min-width: 0; }

.toc { margin: 0 0 44px; }
.toc details { border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, 0.72); }
.toc summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.toc summary::-webkit-details-marker { display: none; }
.toc summary::after {
  content: '';
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.2s ease;
}
.toc details[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.toc ol { list-style: none; padding: 0 18px 12px; }
.toc a {
  display: block;
  padding: 7px 0 7px 14px;
  border-left: 2px solid transparent;
  font-size: 15px;
  line-height: 1.4;
  color: var(--ink-2);
  text-decoration: none;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.toc a:hover { color: var(--violet-ink); }
.toc a.is-active { color: var(--violet-ink); border-left-color: var(--violet); }

@media (min-width: 1200px) {
  .post-head { margin: 0; max-width: 900px; }
  .post-grid {
    max-width: none;
    display: grid;
    grid-template-columns: minmax(0, var(--measure)) 232px;
    column-gap: 80px;
    justify-content: space-between;
    align-items: start;
  }
  .post-grid > article { grid-column: 1; grid-row: 1; }
  .post-grid > .toc { grid-column: 2; grid-row: 1; position: sticky; top: 108px; margin: 0; }
  .toc details { border: 0; background: none; border-radius: 0; }
  .toc summary { padding: 0 0 14px 16px; }
  .toc details[open] summary { pointer-events: none; }
  .toc details[open] summary::after { display: none; }
  .toc ol { padding: 0; border-left: 1px solid var(--line); max-height: calc(100vh - 180px); overflow-y: auto; }
  .toc a { margin-left: -1px; padding: 6px 0 6px 16px; font-size: 13.5px; color: var(--muted); }
  .toc a:hover, .toc a.is-active { color: var(--ink); }
  .toc a.is-active { border-left-color: var(--violet); }
}

/* ---------- Article text ---------- */

article h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 32px;
  line-height: 1.16;
  letter-spacing: -0.035em;
  color: var(--ink);
  margin: 80px 0 18px;
  scroll-margin-top: 104px;
  text-wrap: balance;
}
article h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 21px;
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 42px 0 12px;
  scroll-margin-top: 104px;
}
article p { font-size: 18px; line-height: 1.72; color: var(--ink-2); margin: 0 0 22px; text-wrap: pretty; }
article strong { color: var(--ink); font-weight: 600; }
article a {
  color: var(--violet-ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--violet-line);
  text-underline-offset: 4px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}
article a:hover { color: var(--violet-deep); text-decoration-color: currentColor; }
article code {
  font-family: var(--font-mono);
  font-size: 0.84em;
  color: #34343c;
  background: rgba(17, 12, 46, 0.055);
  border-radius: 6px;
  padding: 2px 6px;
  overflow-wrap: anywhere;
}

article ul, article ol { margin: 0 0 26px; list-style: none; }
article ul > li {
  position: relative;
  padding-left: 26px;
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink-2);
  margin-bottom: 10px;
}
/* a single pixel of the wing as the bullet */
article ul > li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 0.72em;
  width: 6px;
  height: 6px;
  background: var(--violet);
}
article ol { counter-reset: item; }
article ol > li {
  counter-increment: item;
  position: relative;
  padding-left: 38px;
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink-2);
  margin-bottom: 12px;
}
article ol > li::before {
  content: counter(item);
  position: absolute;
  left: 0;
  top: 0.15em;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--violet-ink);
  background: var(--violet-tint);
}

.pull-quote {
  margin: 36px 0;
  padding: 2px 0 2px 24px;
  border-left: 2px solid var(--violet);
  font-family: var(--font-display);
  font-size: 24px;
  line-height: 1.38;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.fine, article p.fine { font-size: 14px; line-height: 1.6; color: var(--faint); }
.sources { margin: 10px 0 22px; font-size: 13.5px; line-height: 1.6; color: var(--faint); }
.sources a { color: var(--muted); }
.gradient-word { background-image: var(--gradient-main); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* In short */
.takeaways { margin: 0 0 56px; padding: 6px 0 2px 26px; border-left: 2px solid var(--violet); }
.takeaways .label {
  display: block;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--violet-ink);
  margin-bottom: 16px;
}
.takeaways ul { margin-bottom: 0; }
.takeaways ul > li { font-size: 17px; line-height: 1.65; margin-bottom: 12px; }

/* ---------- Figures ---------- */

figure { margin: 40px 0 44px; }
figure img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}
figure.shot img { max-width: 540px; margin: 0 auto; border: 1px solid var(--line); }
figcaption { margin-top: 14px; font-size: 13.5px; line-height: 1.55; color: var(--faint); }
figure.shot figcaption { max-width: 540px; margin-left: auto; margin-right: auto; }

/* generated illustrations inside the article */
.post-hero picture, figure.art picture { display: block; }
figure.art img { border-radius: 18px; background: #ececf0; box-shadow: 0 1px 2px rgba(17, 12, 46, 0.05), 0 28px 60px -36px rgba(17, 12, 46, 0.4); }
figure.art figcaption { margin-top: 14px; }

/* ---------- Feature grid, stats, steps ---------- */

.features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 44px;
  margin: 30px 0 26px;
  border-top: 1px solid var(--line);
}
.feature { padding: 24px 0 8px; border-bottom: 1px solid var(--line); }
.feature .kicker {
  display: block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--violet-ink);
  margin-bottom: 10px;
}
article .feature h3 { margin: 0 0 8px; font-size: 19px; }
article .feature p { font-size: 15.5px; line-height: 1.62; color: var(--muted); margin-bottom: 16px; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 30px 0 14px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.stat-cell { padding: 24px 18px 22px 0; }
.stat-cell + .stat-cell { padding-left: 22px; border-left: 1px solid var(--line); }
.stat-cell .num {
  display: block;
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.045em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.stat-cell .what { display: block; font-size: 13.5px; line-height: 1.45; color: var(--muted); margin-top: 10px; }

.steps { margin: 26px 0 26px; }
.step { position: relative; margin: 0 0 0 5px; padding: 0 0 10px 32px; border-left: 1px solid var(--line-strong); }
.step:last-child { border-left-color: transparent; padding-bottom: 0; }
.step::before {
  content: '';
  position: absolute;
  left: -5px;
  top: 7px;
  width: 9px;
  height: 9px;
  background: var(--violet);
  box-shadow: 0 0 0 5px var(--bg);
}
article .step h3 { margin: 0 0 10px; }
article .step p { margin-bottom: 14px; }
article .step ul > li { font-size: 16.5px; }

/* ---------- Prompts and code ---------- */

.try {
  margin: 20px 0 28px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}
.try-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 10px 9px 18px;
  border-bottom: 1px solid var(--line);
}
.try-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--violet-ink);
}
.try-label::before { content: ''; width: 6px; height: 6px; background: var(--violet); }
.try-copy, .code-copy {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--violet-ink);
  background: var(--violet-tint);
  border: 0;
  border-radius: 8px;
  padding: 6px 12px;
  min-height: 30px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.try-copy:hover, .code-copy:hover { background: rgba(124, 58, 237, 0.16); }
.try-copy:focus-visible, .code-copy:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; }
.try-text {
  padding: 16px 18px 18px;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* terminal, config and code: graphite */
.try.try--code { background: var(--graphite); border-color: var(--graphite); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1), 0 18px 40px -22px rgba(17, 12, 46, 0.55); }
.try--code .try-head { border-bottom-color: var(--graphite-line); background: var(--graphite-2); }
.try--code .try-label { color: #a6a6b2; }
.try--code .try-label::before { background: #a78bfa; }
.try--code .try-copy { color: #ecebf7; background: rgba(255, 255, 255, 0.08); }
.try--code .try-copy:hover { background: rgba(255, 255, 255, 0.15); }
.try--code .try-text { font-family: var(--font-mono); font-size: 14px; line-height: 1.75; color: #ececf1; }

pre.code {
  margin: 20px 0 28px;
  padding: 18px 20px;
  border-radius: 14px;
  background: var(--graphite);
  color: #ececf1;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.75;
  overflow-x: auto;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1), 0 18px 40px -22px rgba(17, 12, 46, 0.55);
  -webkit-overflow-scrolling: touch;
}
pre.code code { font: inherit; color: inherit; background: none; padding: 0; border-radius: 0; overflow-wrap: normal; white-space: pre; }
.code-wrap { position: relative; }
.code-wrap pre.code { padding-right: 84px; }
.code-wrap .code-copy { position: absolute; top: 10px; right: 10px; color: #ecebf7; background: rgba(255, 255, 255, 0.08); }
.code-wrap .code-copy:hover { background: rgba(255, 255, 255, 0.15); }

/* ---------- Model cards and badges ---------- */

article ul.models { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 24px 0 22px; }
article ul.models > li {
  margin: 0;
  padding: 20px 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  font-size: 15px;
  line-height: 1.6;
}
article ul.models > li::before { display: none; }
article ul.models > li.fastest { border-color: var(--violet-line); background: linear-gradient(180deg, #ffffff, #faf7ff); }
.model-name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.model-name code { font-size: 14px; }
.badge {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--violet-ink);
  background: var(--violet-tint);
  border-radius: 6px;
  padding: 3px 8px;
}
.model-meta { display: block; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }

/* ---------- Diagrams ---------- */

.diagram .dg {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px 22px;
  background:
    radial-gradient(rgba(17, 12, 46, 0.075) 1px, transparent 1.3px) 0 0 / 18px 18px,
    linear-gradient(180deg, #fcfcfd, #f7f7fa);
}

.flow { display: flex; align-items: center; }
.fl-step, .fl-way, .fl-project, .fl-version, .fl-pass, .fl-fail {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  padding: 13px 13px;
  min-width: 0;
  box-shadow: 0 1px 2px rgba(17, 12, 46, 0.05), 0 12px 26px -18px rgba(17, 12, 46, 0.3);
}
.fl-step { flex: 1 1 0; min-width: 0; }
.fl-step b, .fl-out b, .fl-way b, .fl-project b, .fl-version b {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 4px;
}
.fl-step span, .fl-out span, .fl-way span { display: block; font-size: 13px; line-height: 1.45; color: var(--muted); }
.fl-step.judge, .fl-step.fl-you, .fl-way, .fl-project { border-color: var(--violet-line); background: linear-gradient(180deg, #ffffff, #f8f5ff); }
.fl-version { border-style: dashed; border-color: var(--line-strong); box-shadow: none; background: rgba(255, 255, 255, 0.7); }
.fl-arrow {
  position: relative;
  flex: 0 0 22px;
  align-self: center;
  height: 1.5px;
  margin: 0 4px;
  background: var(--violet-line);
  font-size: 0;
  color: transparent;
}
.fl-arrow::after {
  content: '';
  position: absolute;
  right: -1px;
  top: 50%;
  width: 7px;
  height: 7px;
  border-top: 1.5px solid var(--violet);
  border-right: 1.5px solid var(--violet);
  transform: translateY(-50%) rotate(45deg);
}
.fl-out { flex: 1.25 1 0; min-width: 0; display: grid; gap: 10px; }
.fl-pass { border-color: rgba(21, 128, 61, 0.3); background: linear-gradient(180deg, #ffffff, #f3faf5); }
.fl-fail { border-color: rgba(180, 35, 24, 0.26); background: linear-gradient(180deg, #ffffff, #fdf5f4); }
.fl-pass b { color: var(--green); }
.fl-fail b { color: var(--red); }
.flow code, .fl-out code, .fl-step code, .fl-step span code { font-size: 11px; padding: 1px 5px; white-space: normal; word-break: normal; overflow-wrap: break-word; }
.fl-step b code { font-size: 12.5px; }

.tl { display: grid; gap: 18px; }
.tl-row { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 16px; align-items: center; }
.tl-label { font-size: 14px; font-weight: 600; color: var(--ink); line-height: 1.3; }
.tl-label em { display: block; font-style: normal; font-weight: 400; font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.tl-track { position: relative; display: flex; gap: 3px; height: 40px; padding: 3px; border-radius: 11px; background: rgba(17, 12, 46, 0.05); }
.seg {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  width: var(--w);
  padding: 0 6px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.seg.run { background: #1d1d24; color: #ffffff; justify-content: flex-start; padding-left: 10px; }
.seg.run.cut { background: repeating-linear-gradient(135deg, #1d1d24 0 8px, #34343e 8px 16px); }
.seg.next { background: var(--violet); color: #ffffff; }
.seg.done { background: #dcdce2; color: var(--ink); }
.seg.open { background: transparent; border: 1px dashed var(--line-strong); color: var(--muted); }
.tl-mark { position: absolute; top: -6px; bottom: -6px; left: var(--x); width: 0; border-left: 2px dashed var(--violet); }
.tl-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.tl-legend span { display: inline-flex; align-items: center; gap: 6px; }
.tl-legend i { display: inline-block; width: 14px; height: 10px; border-radius: 3px; }

/* ---------- Notes and tables ---------- */

.note {
  margin: 24px 0 28px;
  padding: 16px 20px;
  border-left: 2px solid #d97706;
  border-radius: 0 12px 12px 0;
  background: rgba(245, 158, 11, 0.08);
}
article .note p { margin: 0; font-size: 16.5px; line-height: 1.65; }

.table-wrap {
  margin: 26px 0 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; }
table.compare { min-width: 680px; }
th, td { text-align: left; vertical-align: top; padding: 13px 16px; border-bottom: 1px solid var(--line); color: var(--ink-2); }
thead th {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  background: #fafafb;
}
thead th.us { color: var(--violet-ink); }
tbody th { font-weight: 600; color: var(--ink); width: 18%; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
td.num { white-space: nowrap; font-variant-numeric: tabular-nums; }
table.compare tbody th { position: sticky; left: 0; z-index: 1; background: var(--surface); }
table.compare thead th:first-child { position: sticky; left: 0; z-index: 2; }
table code, .table-wrap td code, .table-wrap th code { font-size: 0.8em; padding: 1px 5px; }
table.compare td code { white-space: normal; overflow-wrap: anywhere; }
.table-hint { display: none; margin: 8px 0 0; font-size: 12.5px; color: var(--faint); }

/* ---------- FAQ ---------- */

.faq details { border-bottom: 1px solid var(--line); }
.faq h2 + details, .faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary { position: relative; list-style: none; cursor: pointer; padding: 20px 52px 20px 0; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { margin: 0; font-size: 19px; line-height: 1.42; letter-spacing: -0.015em; transition: color 0.15s ease; }
.faq summary:hover h3 { color: var(--violet-ink); }
.faq summary::before, .faq summary::after {
  content: '';
  position: absolute;
  right: 10px;
  top: 50%;
  width: 14px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.faq summary::after { transform: rotate(90deg); }
.faq details[open] summary::after { transform: rotate(0deg); opacity: 0; }
.faq .faq-answer { padding: 0 52px 6px 0; }
.faq .faq-answer p { font-size: 17px; line-height: 1.7; margin-bottom: 18px; }

/* ---------- Call to action and further reading ---------- */

.cta-panel {
  position: relative;
  overflow: hidden;
  margin-top: 80px;
  padding: 46px 42px;
  border-radius: 24px;
  color: #ffffff;
  background:
    radial-gradient(120% 150% at 0% 0%, rgba(124, 58, 237, 0.62), transparent 58%),
    radial-gradient(90% 120% at 100% 100%, rgba(124, 58, 237, 0.25), transparent 60%),
    var(--graphite);
  box-shadow: 0 40px 80px -40px rgba(17, 12, 46, 0.55);
}
.cta-panel::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.09) 1px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(110deg, transparent 35%, #000 100%);
  mask-image: linear-gradient(110deg, transparent 35%, #000 100%);
  pointer-events: none;
}
article .cta-panel h2 { position: relative; z-index: 1; margin: 0 0 12px; font-size: 32px; color: #ffffff; }
.cta-panel .gradient-word { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: #c4b5fd; }
article .cta-panel p { position: relative; z-index: 1; max-width: 540px; font-size: 17px; color: rgba(255, 255, 255, 0.74); margin-bottom: 26px; }
.cta-actions { position: relative; z-index: 1; display: flex; gap: 12px; flex-wrap: wrap; }
.btn-primary, .btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease, opacity 0.2s ease, border-color 0.2s ease;
}
article .btn-primary { background: #ffffff; color: var(--graphite); text-decoration: none; }
article .btn-primary:hover { opacity: 0.9; color: var(--graphite); }
article .btn-ghost { border: 1px solid rgba(255, 255, 255, 0.24); color: #ffffff; background: transparent; text-decoration: none; }
article .btn-ghost:hover { border-color: rgba(255, 255, 255, 0.5); color: #ffffff; }

article ul.related { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 20px; }
article ul.related > li { margin: 0; padding: 0; }
article ul.related > li::before { display: none; }
article ul.related a {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
  padding: 18px 20px;
  transition: border-color 0.15s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
article ul.related a span { display: block; margin-top: 6px; font-size: 14px; font-weight: 400; line-height: 1.5; letter-spacing: 0; color: var(--muted); }
article ul.related a:hover { border-color: var(--violet-line); box-shadow: var(--shadow-soft); transform: translateY(-2px); }
article ul.related a.has-thumb { padding: 0; }
article ul.related a.has-thumb img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: #ececf0; }
article ul.related a.has-thumb .rel-text { display: block; padding: 16px 20px 18px; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ---------- Small screens ---------- */

@media (max-width: 760px) {
  .page-shell { padding-top: 108px; padding-bottom: 88px; }
  .crumbs { margin-bottom: 22px; }
  .article-sub { font-size: 18px; }
  .byline { margin-top: 22px; font-size: 13.5px; }
  .post-hero { margin: 34px 0 44px; }
  .post-hero img { border-radius: 18px; }
  article h2 { font-size: 26px; margin-top: 60px; }
  article h3 { font-size: 19px; }
  article p, article ul > li, article ol > li { font-size: 17px; }
  .takeaways ul > li { font-size: 16.5px; }
  .features { grid-template-columns: minmax(0, 1fr); }
  .stat-row { grid-template-columns: minmax(0, 1fr); }
  .stat-cell, .stat-cell + .stat-cell { padding: 18px 0; border-left: 0; }
  .stat-cell + .stat-cell { border-top: 1px solid var(--line); }
  article ul.models, article ul.related { grid-template-columns: minmax(0, 1fr); }
  .diagram .dg { padding: 22px 16px; }
  .flow { flex-direction: column; align-items: stretch; }
  .fl-arrow { flex: 0 0 26px; width: 1.5px; height: 26px; margin: 6px auto; }
  .fl-arrow::after { right: auto; top: auto; left: 50%; bottom: -1px; transform: translateX(-50%) rotate(135deg); }
  .tl-row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .table-hint { display: block; }
  table.compare tbody th { width: 116px; min-width: 116px; }
  .pull-quote { font-size: 20px; }
  .cta-panel { padding: 34px 24px; border-radius: 20px; }
  article .cta-panel h2 { font-size: 26px; }
  .faq summary h3 { font-size: 17.5px; }
  .faq .faq-answer { padding-right: 0; }
}

@media (max-width: 480px) {
  .post { padding: 0 16px; }
  .post-hero { margin-left: -16px; margin-right: -16px; }
  .post-hero img { border-radius: 0; box-shadow: none; }
  .takeaways { padding-left: 18px; }
  .try-head { padding-left: 14px; }
  .try-text { padding: 14px 14px 16px; }
  .step { padding-left: 24px; }
}
