/* ─────────────────────────────────────────────────────────────
   Tailwind v4. Theme + utilities only (NO preflight) during the
   CSS migration, so existing hand-written styles stay untouched.
   @theme mirrors the design tokens below so utilities (bg-bg-1,
   text-ink, text-vio, font-display, border-line, …) match exactly.
   Add preflight once globals.css is fully retired.
   ───────────────────────────────────────────────────────────── */
@import "tailwindcss/theme.css";
@import "tailwindcss/utilities.css";
@plugin "@tailwindcss/typography";
/* shadcn/ui (issue #087) — enter/exit + zoom/slide animation utilities
   (animate-in, fade-in-0, zoom-in-95, slide-in-from-*) used by the
   dialog / popover / tooltip primitives. Additive; does not affect
   legacy hand-written CSS. */
@plugin "tailwindcss-animate";

@theme {
  --color-bg: #0A0A0B;
  --color-bg-1: #131316;
  --color-bg-2: #1A1A1D;
  --color-bg-3: #212125;
  --color-bg-4: #28282C;

  --color-ink: #F5F5F4;
  --color-ink-2: #DDDDDA;
  --color-ink-3: #B5B5B2;
  --color-mute: #8E8E8B;
  --color-mute-2: #5A5A5E;

  /* Reference the runtime vars, not literals: the active theme overrides
     --vio on <html> (layout.tsx sets it to #FFA630 orange). Hardcoding the
     :root rose fallback here made every bg-vio/text-vio utility render pink
     while legacy var(--vio) CSS rendered orange. */
  --color-vio: var(--vio);
  --color-vio-2: var(--vio-2);
  --color-vio-3: var(--vio-3);
  --color-vio-ink: var(--vio-ink);

  --color-warn: #F2C66B;
  --color-line: rgb(245 245 244 / 0.12);
  --color-line-2: rgb(245 245 244 / 0.20);
  --color-line-3: rgb(245 245 244 / 0.32);

  --font-display: "AWS Diatype Mono", "Geist", -apple-system, system-ui, sans-serif;
  --font-sans: "AWS Diatype", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --font-mono: "Fragment Mono", "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --font-pixel: "VT323", "JetBrains Mono", monospace;
}

/* ─────────────────────────────────────────────────────────────
   Fonts — AWS Diatype family + Fragment Mono (self-hosted)
   ───────────────────────────────────────────────────────────── */
@font-face {
  font-family: "AWS Diatype";
  src: url("/assets/fonts/AWSDiatype-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "AWS Diatype Mono";
  src: url("/assets/fonts/AWSDiatypeRoundedSemi-Mono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "AWS Diatype Mono";
  src: url("/assets/fonts/AWSDiatypeRoundedSemi-Mono-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fragment Mono";
  src: url("/assets/fonts/FragmentMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ─────────────────────────────────────────────────────────────
   Ralphy — Higgsfield-language redesign.
   Pure black, white, single violet accent.
   Display: bold ALL-CAPS sans, tight tracking.
   Background: subtle dot-grid behind hero/sections.
   ───────────────────────────────────────────────────────────── */
:root {
  --bg:        #0A0A0B;
  --bg-1:      #131316;
  --bg-2:      #1A1A1D;
  --bg-3:      #212125;
  --bg-4:      #28282C;

  --ink:       #F5F5F4;
  --ink-2:     #DDDDDA;
  --ink-3:     #B5B5B2;
  --mute:      #8E8E8B;
  --mute-2:    #5A5A5E;

  --vio:       #E87BA1;     /* poised dusty rose — terminal pink, calmer */
  --vio-2:     #F2A0BD;
  --vio-3:     #C75C82;
  --vio-ink:   #6E2F4A;

  --warn:      #F2C66B;
  --line:      rgb(245 245 244 / 0.12);
  --line-2:    rgb(245 245 244 / 0.20);
  --line-3:    rgb(245 245 244 / 0.32);

  /* Display = AWS Diatype Rounded Semi-Mono Bold (uppercase headings).
     Sans    = AWS Diatype Regular (body).
     Mono    = Fragment Mono Regular (terminal & code). */
  --font-display: "AWS Diatype Mono", "Geist", -apple-system, system-ui, sans-serif;
  --font-sans:    "AWS Diatype", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --font-mono:    "Fragment Mono", "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --font-pixel:   "VT323", "JetBrains Mono", monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body { overflow-x: hidden; min-height: 100dvh; }
::selection { background: var(--vio); color: var(--bg); }
a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }

/* ─────────────────────────────────────────────────────────────
   Decorative dot-grid background — sits in a fixed layer.
   Subtle, fades at edges. Used as Higgsfield does.
   ───────────────────────────────────────────────────────────── */
.dot-bg {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(rgb(245 245 244 / 0.07) 1.1px, transparent 1.4px);
  background-size: 18px 18px;
  background-position: 0 0;
  mask-image: radial-gradient(ellipse at 50% 30%, black 0%, black 40%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 30%, black 0%, black 40%, transparent 80%);
}

/* ─────────────────────────────────────────────────────────────
   Display type — uppercase, tight, heavy
   ───────────────────────────────────────────────────────────── */
.display, h1.display, h2.display {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 0.96;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0;
}
.display .acc { color: var(--vio); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--mute);
  letter-spacing: 0;
}
.eyebrow .dot {
  width: 7px; height: 7px; background: var(--vio);
  border-radius: 1px;
}

.mono  { font-family: var(--font-mono); }

/* ─────────────────────────────────────────────────────────────
   Buttons
   ───────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 18px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 13.5px;
  letter-spacing: 0.01em;
  background: transparent;
  color: var(--ink);
  white-space: nowrap;
  transition: transform 180ms ease, background 180ms ease,
              border-color 180ms ease, color 180ms ease;
}
.btn:hover { background: var(--bg-2); border-color: var(--line-3); transform: translateY(-1px); }

.btn-vio {
  position: relative;
  background: var(--vio);
  color: var(--bg);
  border-color: var(--vio);
  overflow: hidden;
  isolation: isolate;
  transition: transform 180ms ease;
}
.btn-vio::before {
  content: "";
  position: absolute;
  left: 50%; bottom: 0;
  width: 220%;
  aspect-ratio: 1 / 1;
  background: #F5F5F4;
  border-radius: 50%;
  transform: translate(-50%, 60%) scale(0);
  transform-origin: center center;
  transition: transform 1120ms cubic-bezier(0.34, 1.56, 0.64, 1);
  /* Sit below in-flow content — `isolation: isolate` on .btn-vio keeps the
     negative z-index scoped to this stacking context. */
  z-index: -1;
}
.btn-vio:hover { transform: none; }
.btn-vio:hover::before { transform: translate(-50%, 60%) scale(1); }
.btn .star-count {
  font-family: var(--font-mono);
  background: rgb(0 0 0 / 0.18);
  padding: 1px 6px;
  border-radius: 999px;
  font-size: 11.5px;
  letter-spacing: 0;
}

/* ─────────────────────────────────────────────────────────────
   Layout
   ───────────────────────────────────────────────────────────── */
.container { max-width: 1240px; margin: 0 auto;
  padding-left: 28px; padding-right: 28px;
  position: relative; z-index: 1;
}
.container-narrow { max-width: 980px; margin: 0 auto;
  padding-left: 28px; padding-right: 28px;
  position: relative; z-index: 1;
}

/* Width tokens — drive section rhythm. Use sparingly: most sections
   stay at the default 1240. Pick a width to deliberately break the
   linear feel — wider for visual content (showcase rail, mosaic),
   narrower for reading-focused sections (long-form quotes, manifesto).
   Pair with .container so common padding rules apply.

   Apply as a second class on the same element:
     <div className="container container-w-1480">
*/

.container-w-1480 { max-width: 1480px; }
.container-w-1760 { max-width: 1760px; }

section { position: relative; padding-top: 80px; }
@media (min-width: 900px) { section { padding-top: 120px; } }

/* Reveal — no-op */
.reveal, .reveal.in, .reveal.d1, .reveal.d2, .reveal.d3, .reveal.d4 {
  opacity: 1; transform: none;
}

/* ─────────────────────────────────────────────────────────────
   Nav — floating pill (kiro.dev style)
   ───────────────────────────────────────────────────────────── */
/* ─── Navbar ────────────────────────────────────────────────────────
   Per BRAND_DESIGN §3 / §4 / §5: pill geometry only, solid bg-1
   plate, no border, no shadow, no backdrop-blur. The bento-step
   contrast between bg (page) and bg-1 (nav plate) is what makes the
   nav read as elevated — no glass effect needed. */
.nav {
  position: sticky; top: 14px; z-index: 50;
  display: flex; justify-content: center;
  padding: 0 16px;
  pointer-events: none;
}

/* ── Logo eyes — looking + blinking animation ── */
@keyframes logoEyesLook {
  0%, 12%   { transform: translateX(0); }
  20%, 28%  { transform: translateX(-70px); }
  40%       { transform: translateX(0); }
  52%, 68%  { transform: translateX(70px); }
  80%, 100% { transform: translateX(0); }
}
@keyframes logoEyesBlink {
  0%, 42%   { transform: scaleY(1); }
  45%       { transform: scaleY(0.05); }
  48%, 78%  { transform: scaleY(1); }
  81%      { transform: scaleY(0.05); }
  84%, 100% { transform: scaleY(1); }
}
.logo-eyes-look {
  animation: logoEyesLook 6s ease-in-out infinite;
}
.logo-eye-blink {
  transform-box: fill-box;
  transform-origin: center;
  animation: logoEyesBlink 6s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .logo-eyes-look, .logo-eye-blink { animation: none; }
}

.nav-name .v {
  display: none;
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 11px;
  color: var(--mute);
  background: var(--bg-3);
  padding: 2px 7px;
  border-radius: 999px;
  margin-left: 10px;
  vertical-align: 3px;
  letter-spacing: 0;
}
@media (min-width: 1100px) { .nav-name .v { display: inline; } }

/* Mobile burger now takes over below 1200px — wide enough that
   tablet-portrait still gets the sheet, but the floating pill on
   landscape laptops still shows full inline nav. */
@media (min-width: 1200px) { .nav-links { display: flex; } }

@media (min-width: 1100px) { .nav-kbd { display: inline-flex; } }

.nav-cta .star-count {
  font-family: var(--font-mono);
  background: rgb(0 0 0 / 0.18);
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0;
  transition: background 1100ms ease;
}
.nav-cta:hover .star-count { background: rgb(0 0 0 / 0.22); }

/* ─────────────────────────────────────────────────────────────
   Hero — centered title, sub, tab switcher, 3 install cards
   ───────────────────────────────────────────────────────────── */
.hero {
  padding-top: 80px;
  padding-bottom: 24px;
  text-align: center;
}
@media (min-width: 900px) { .hero { padding-top: 120px; padding-bottom: 56px; } }

.hero h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(40px, 6.4vw, 80px);
  line-height: 1.04;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 auto;
  max-width: 20ch;
  text-wrap: balance;
}
.hero h1 .acc { color: var(--vio); }
/* Cycling agent name + icon — kiro.dev style swap */
.cycle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: -0.04em;
  position: relative;
  overflow: hidden;
  height: 1.15em;
  width: 8em;
  flex-shrink: 0;
}

@keyframes cycleIn {
  from { transform: translateY(-110%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}
@keyframes cycleOut {
  from { transform: translateY(0);    opacity: 1; }
  to   { transform: translateY(110%); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .cycle-row.entering, .cycle-row.leaving { animation: none; }
}
.cycle-row .ic {
  display: inline-grid; place-items: center;
  width: 0.78em; height: 0.78em;
  line-height: 0;
}
.cycle-row .ic svg { width: 100%; height: 100%; display: block; }
.cycle-row.out { transform: translateY(-110%); opacity: 0; }
.cycle-row.in  { transform: translateY(110%); opacity: 0; }
.cycle-row.now { transform: translateY(0); opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .cycle-row { transition: none; }
}
.display .glyph {
  display: inline-grid; place-items: center;
  width: 0.9em; height: 0.9em;
  background: transparent;
  margin: 0 0.06em -0.05em;
  vertical-align: -0.05em;
}

/* Tab switcher under hero subtitle (MCP / CLI / Skill style) */
/* Tab switcher — Higgsfield-style: compact, refined, white-pill active */

.tab {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  color: var(--ink-3);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}
.tab:hover:not(.active) { color: var(--ink-2); }
.tab.active {
  background: rgb(255 255 255 / 0.96);
  color: #0A0A0B;
  box-shadow: 0 1px 1px rgb(0 0 0 / 0.35),
              0 0 0 1px rgb(255 255 255 / 0.18) inset;
}
.tab .ic {
  display: inline-flex; align-items: center;
  width: 16px; height: 16px;
  color: var(--ink-3);
}
.tab.active .ic { color: #0A0A0B; }
.tab .ic svg { width: 16px; height: 16px; display: block; }

/* Switcher row — two tab groups + github link. On narrow viewports
   we collapse to centered, wrapped rows so the inner Agent + Github
   block also breaks across lines instead of overflowing horizontally. */

.switcher-row > .flex { flex-wrap: wrap; }
@media (max-width: 720px) {
  .switcher-row {
    justify-content: center;
    gap: 10px;
  }
  .switcher-row > .flex {
    justify-content: center;
    width: 100%;
    gap: 8px;
  }
}

/* Numbered install steps */

@media (min-width: 900px) {
  .install-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.install-step .head { display: flex; align-items: center; gap: 12px; }
.install-step .num {
  width: 28px; height: 28px;
  display: grid; place-items: center;
  border-radius: 999px;
  background: var(--bg-3);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 700;
}

.install-step .desc {
  color: var(--ink-3); font-size: 14px; line-height: 1.55;
}
.install-step .desc .inl {
  font-family: var(--font-mono);
  background: color-mix(in srgb, var(--vio) 12%, transparent);
  padding: 1px 6px; border-radius: 5px;
  color: var(--vio-2); font-size: 12.5px;
}
.install-step .cmd {
  margin-top: auto;
  display: flex; align-items: center; gap: 8px;
  padding: 13px 16px;
  background: #050506;
  border: 0;
  border-radius: 11px;
  font-family: var(--font-mono);
  font-size: 13.5px;
  color: var(--ink);
  cursor: pointer;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  text-align: left;
  transition: background 180ms ease;
}
.install-step .cmd .cmd-text {
  min-width: 0;
  flex: 1;
  overflow-wrap: anywhere;
  word-break: break-word;
  line-height: 1.45;
}
.install-step .cmd:hover { background: #0A0A0B; }
.install-step .cmd .pr { color: var(--vio); }
.install-step .cmd .copy {
  margin-left: auto; color: var(--mute);
  display: inline-flex; align-items: center;
}
.install-step .cmd.copied .copy { color: var(--vio); }

/* ─────────────────────────────────────────────────────────────
   Section header — centered display + sub
   ───────────────────────────────────────────────────────────── */

.section-head h2 .acc { color: var(--vio); }
.section-head .sub {
  margin: 16px auto 0;
  max-width: 620px;
  font-size: clamp(14.5px, 1.05vw, 16px);
  color: var(--ink-3);
  line-height: 1.55;
}

/* ─────────────────────────────────────────────────────────────
   HowItWorks — editorial "chapter" layout. Deliberately *not* a
   bento plate (that pattern is owned by Roadmap). Each step reads
   like a magazine chapter:
     • huge display-font number ("01", ~140px) as a visual anchor
     • thin horizontal rule + mono kicker eyebrow on the same line
     • full-width display-font title under the head
     • two-column body: long-form copy + embedded terminal
       (reverse swaps columns on desktop)
   No outer card chrome — separation between chapters comes from
   spacing only.
   ───────────────────────────────────────────────────────────── */

@media (max-width: 720px) {
  .duo-stack { gap: 64px; }
}

.chapter {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Head row — full width across the chapter, sits above the 2-col body */
.chapter-head {
  display: flex;
  align-items: center;
  gap: 20px;
  min-width: 0;
}
/* Reverse mirroring only applies on the 2-col desktop layout. On
   mobile the body stacks vertically so left-to-right head reading
   stays consistent across all chapters. */
@media (min-width: 960px) {
  .chapter.reverse .chapter-head { flex-direction: row-reverse; }
}

/* Body — title+copy on one side, terminal on the other. Terminal
   sits in the wider column regardless of reverse. */

@media (min-width: 960px) {
  .chapter-body {
    grid-template-columns: 1fr 1.6fr;
    gap: 56px;
  }
  .chapter.reverse .chapter-body {
    grid-template-columns: 1.6fr 1fr;
  }
  .chapter.reverse .chapter-text { order: 2; }
  .chapter.reverse .chapter-term { order: 1; }
}

.chapter-text {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}
/* In reverse, title + copy block right-aligns so it visually
   anchors toward the giant number on that side of the head row.
   Only on the desktop 2-col layout — on mobile both sides stack
   single-column and left-align stays universally readable. */
@media (min-width: 960px) {
  .chapter.reverse .chapter-title {
    margin-left: auto;
    text-align: right;
  }
  .chapter.reverse .chapter-copy {
    margin-left: auto;
    text-align: right;
  }
}

.chapter-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(28px, 3.6vw, 48px);
  letter-spacing: -0.02em;
  line-height: 1.04;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
  max-width: 22ch;
}
.chapter-title .acc { color: var(--vio); }

.chapter-copy {
  font-size: 17px;
  color: var(--ink-3);
  line-height: 1.65;
  margin: 0;
  max-width: 56ch;
}
.chapter-copy .inl {
  font-family: var(--font-mono);
  font-size: 0.88em;
  color: var(--vio-2);
  background: color-mix(in srgb, var(--vio) 12%, transparent);
  padding: 1px 6px;
  border-radius: 4px;
}
.chapter-copy .acc { color: var(--vio); }
.chapter-term { width: 100%; min-width: 0; }

/* ─────────────────────────────────────────────────────────────
   Terminal block (used in duos + install)
   ───────────────────────────────────────────────────────────── */
.term {
  background: var(--bg-1);
  border-radius: 14px;
  overflow: hidden;
}

.tty-lights .r { background: #555; }
.tty-lights .y { background: #555; }
.tty-lights .g { background: #555; }

.term-body .cmt { color: var(--mute-2); }
.term-body .prm { color: var(--vio); }
.term-body .ok  { color: #B0E3B5; }
.term-body .acc { color: var(--vio-2); }
.term-body .dim { color: var(--mute); }
.term-body .keyword { color: var(--vio); }
.term-body .str { color: #E0D6A8; }

/* ─────────────────────────────────────────────────────────────
   Showcase — big oversized category cards (Higgsfield style)
   ───────────────────────────────────────────────────────────── */

.show-card .overlay {
  position: absolute; inset: 0; z-index: 3;
  background: linear-gradient(180deg, rgb(0 0 0 / 0.35) 0%, transparent 35%, rgb(0 0 0 / 0.75) 100%);
}

.show-card .ttl .plus {
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 999px;
  background: white; color: var(--bg);
  flex-shrink: 0;
}
.show-card .label {
  position: absolute; top: 14px; left: 14px; z-index: 4;
  font-family: var(--font-mono);
  background: rgb(0 0 0 / 0.55);
  border: 1px solid rgb(255 255 255 / 0.12);
  color: white;
  padding: 3px 8px; border-radius: 5px;
  font-size: 10.5px;
  backdrop-filter: blur(6px);
}

/* ─────────────────────────────────────────────────────────────
   Mosaic — Pinterest-style masonry. Flex row of N columns;
   greedy-packed by aspect weight in JS so all columns end up
   close in height. The row aligns to center vertically so any
   leftover height-delta is split top/bottom (not bottom-only).
   ───────────────────────────────────────────────────────────── */
.mosaic {
  display: flex;
  gap: 12px;
  max-width: 880px;
  margin: 0 auto;
  align-items: stretch;
  justify-content: center;
}
.mosaic-col {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
/* Infinite-scroll marquee container. Each .mosaic-col--marquee is a
   vertical viewport; .mosaic-col-track holds the clips duplicated twice
   and animates -50% so the loop is seamless. */
.mosaic-marquee {
  height: clamp(560px, 78vh, 820px);
  overflow: hidden;
  align-items: stretch;
  mask-image: linear-gradient(to bottom, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 8%, black 92%, transparent 100%);
}
.mosaic-col--marquee {
  overflow: hidden;
  position: relative;
}
.mosaic-col-track {
  display: flex;
  flex-direction: column;
  animation-name: marquee-up;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  will-change: transform;
}
/* Use margin-bottom (not gap) so the duplicated content has the same
   rhythm at the loop join — translate(-50%) lands seamlessly. */
.mosaic-col-track > * { margin-bottom: 12px; }
.dir-up .mosaic-col-track { animation-name: marquee-up; }
.dir-down .mosaic-col-track { animation-name: marquee-down; }
.mosaic-col--marquee:hover .mosaic-col-track { animation-play-state: paused; }
@keyframes marquee-up {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(0, -50%, 0); }
}
@keyframes marquee-down {
  from { transform: translate3d(0, -50%, 0); }
  to   { transform: translate3d(0, 0, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .mosaic-col-track { animation: none !important; }
}
.mosaic .tile-v {
  display: block;
  width: 100%;
  position: relative; overflow: hidden;
  border-radius: 14px;
  background: #000;
  cursor: pointer;
  isolation: isolate;
  transition: border-color 240ms ease;
}
.mosaic .tile-v:hover { border-color: var(--line-3); }
.mosaic .tile-v video,
.mosaic .tile-v img {
  width: 100%; height: 100%;
  object-fit: cover;
  position: absolute; inset: 0;
  pointer-events: none;
}
.mosaic .tile-v .overlay {
  position: absolute; inset: 0; z-index: 3;
  background: linear-gradient(180deg, rgb(0 0 0 / 0.35) 0%, transparent 30%);
  pointer-events: none;
}
.mosaic .tile-v .label {
  position: absolute; top: 12px; left: 50%; z-index: 4;
  transform: translateX(-50%);
  font-family: var(--font-sans);
  font-weight: 500;
  color: #FFFFFF;
  font-size: 13px;
  letter-spacing: -0.005em;
  text-shadow: 0 1px 6px rgb(0 0 0 / 0.6);
  white-space: nowrap;
  background: transparent;
  border: none;
  padding: 0;
}
.mosaic .tile-v .bot {
  position: absolute; bottom: 10px; left: 12px; right: 12px; z-index: 4;
}
.mosaic .tile-v .ttl {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  color: white;
  text-shadow: 0 1px 4px rgb(0 0 0 / 0.5);
  line-height: 1.15;
}
.mosaic .tile-v .meta {
  font-family: var(--font-mono);
  font-size: 10px;
  color: rgb(255 255 255 / 0.7);
  margin-top: 4px;
}
.mosaic .tile-v .play {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  z-index: 4; pointer-events: none;
  opacity: 0; transition: opacity 220ms ease;
}
.mosaic .tile-v:hover .play { opacity: 1; }
.mosaic .tile-v .play span {
  display: grid; place-items: center;
  width: 52px; height: 52px;
  border-radius: 999px;
  background: var(--vio);
  color: var(--bg);
}
/* Aspect classes — drive tile height in the column flow. */
.t-v1, .t-v2 { aspect-ratio: 9 / 16; }
.t-sq { aspect-ratio: 1 / 1; }
.t-h2, .t-h3 { aspect-ratio: 16 / 9; }
@media (max-width: 720px) { .mosaic { max-width: 560px; gap: 8px; } .mosaic-col { gap: 8px; } }
@media (max-width: 480px) { .mosaic { max-width: 360px; } }

/* ─────────────────────────────────────────────────────────────
   Lightbox
   ───────────────────────────────────────────────────────────── */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgb(0 0 0 / 0.95);
  backdrop-filter: blur(10px);
  display: grid; place-items: center;
  padding: 28px;
  animation: fadeOnly 220ms ease;
}
@keyframes fadeOnly { from { opacity: 0; } to { opacity: 1; } }
.lightbox .stage {
  position: relative;
  display: inline-block;
  max-width: min(95vw, 1280px);
  max-height: 90vh;
  border-radius: 20px; overflow: hidden;
  background: black;
  border: 1px solid var(--line-3);
  line-height: 0;
}
.lightbox video {
  display: block;
  max-width: min(95vw, 1280px);
  max-height: 90vh;
  width: auto; height: auto;
  object-fit: contain;
}
.lightbox .lb-close,
.lightbox .nav-btn {
  position: absolute;
  width: 44px; height: 44px; border-radius: 999px;
  background: var(--bg-2);
  border: 1px solid var(--line-2);
  color: var(--ink); display: grid; place-items: center;
}
.lightbox .lb-close { top: 24px; right: 24px; }
.lightbox .nav-btn { top: 50%; transform: translateY(-50%); }
.lightbox .nav-prev { left: 24px; }
.lightbox .nav-next { right: 24px; }
.lightbox .lb-meta {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 64px 24px 20px;
  pointer-events: none;
  background: linear-gradient(to top, rgb(0 0 0 / 0.78) 0%, rgb(0 0 0 / 0.45) 55%, transparent 100%);
  color: var(--ink);
}
.lightbox .lb-meta-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--vio-2);
  margin-bottom: 8px;
}
.lightbox .lb-meta-title {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 18px;
  letter-spacing: -0.005em;
  line-height: 1.15;
  color: #fff;
}
.lightbox .lb-mute {
  position: absolute; top: 16px; left: 16px; z-index: 4;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 999px;
  background: rgb(0 0 0 / 0.55);
  border: 1px solid rgb(255 255 255 / 0.18);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: background 180ms ease, transform 180ms ease;
}
.lightbox .lb-mute:hover { background: rgb(0 0 0 / 0.75); transform: scale(1.05); }

/* ─────────────────────────────────────────────────────────────
   Pixel mascot (small, used as logo glyph + as standalone)
   ───────────────────────────────────────────────────────────── */
.mascot-svg {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  display: block;
}

/* ─────────────────────────────────────────────────────────────
   Stack chip rows + chips
   Sizing draws from practicum.yandex's chip density: generous
   padding (10×18), larger mono labels (14px), 22px brand glyphs.
   ───────────────────────────────────────────────────────────── */
.chip {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--bg-2);
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.25;
  transition: background 160ms ease, transform 160ms ease;
}
.chip:has(.ic img):hover { transform: translateY(-1px); }
.chip .ic {
  display: inline-flex;
  align-items: center; justify-content: center;
  width: 22px; height: 22px;
  color: var(--vio); /* default tint for currentColor SVGs */
  flex-shrink: 0;
}
.chip .ic svg { width: 22px; height: 22px; display: block; }
.chip .ic img { width: 22px; height: 22px; display: block; }

/* Per-brand tints — apply to inline currentColor SVGs only. The
   <img>-loaded brand SVGs already carry their authentic colours,
   so these rules don't affect them. */
.chip .ic[data-brand="el"]       { color: var(--ink); }
.chip .ic[data-brand="kling"]    { color: #FF7A00; }
.chip .ic[data-brand="seedance"] { color: var(--ink); }
.chip .ic[data-brand="amazon"]   { color: #FF9900; }

.chip.muted {
  background: transparent;
  color: var(--mute);
}
/* Muted chips override all per-brand colours back to mute, and
   desaturate the full-colour brand <img> icons so they read as
   "secondary" not "primary". */
.chip.muted .ic { color: var(--mute) !important; }
.chip.muted .ic img { filter: saturate(0) opacity(0.55); }

@media (max-width: 700px) {
  .chip-row { grid-template-columns: 1fr; gap: 12px; padding: 18px 0; }
  .chip-row .lbl { padding-top: 0; font-size: 13.5px; }
  .chip { padding: 9px 16px; font-size: 13.5px; }
  .chip .ic, .chip .ic svg, .chip .ic img { width: 20px; height: 20px; }
}

/* Container for chip-rows */

@media (max-width: 700px) {
  .stack-card { padding: 8px 18px; border-radius: 18px; }
}

/* ─────────────────────────────────────────────────────────────
   Style grid (templates)
   ───────────────────────────────────────────────────────────── */

@media (min-width: 700px)  { .style-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .style-grid { grid-template-columns: repeat(5, 1fr); } }

.style-tile .head { display: flex; align-items: center; justify-content: space-between; }
.style-tile .kicker {
  font-family: var(--font-mono);
  color: var(--mute);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.style-tile .copy { font-size: 14px; color: var(--ink-3); line-height: 1.55; }
.pill {
  display: inline-flex; align-items: center;
  padding: 2px 7px; border-radius: 4px;
  font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: 0.04em; text-transform: uppercase;
}

/* ─────────────────────────────────────────────────────────────
   Roadmap — accordion of category cards. Each card opens to a
   grid of mini-cards (3 cols), one per item. Items already shipped
   carry a checkmark before the title; "in progress" items get a
   small kicker; "planned" items are visually identical (no markers).
   ───────────────────────────────────────────────────────────── */

/* Big rounded "chapter" number badge in the corner — matches the
   educational-module look that inspired this design */

/* accordion body — grid-template-rows 0fr→1fr is the modern
   animatable height idiom (Chrome 117+, Safari 17+, FF 124+) */

/* Mini-card grid — items sit inside the parent card with simple
   spacing, no per-cell borders or hairline dividers. Status reads
   from the ✓ checkmark and `in progress` tag, not from chrome. */

@media (max-width: 1100px) { .roadmap-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px)  { .roadmap-grid { grid-template-columns: 1fr; padding: 4px 18px 22px; } }

@media (max-width: 720px) {
  .roadmap-card-head {
    padding: 22px;
    gap: 16px;
  }
  .roadmap-card-title { font-size: 22px; }
  .roadmap-card-why { font-size: 13.5px; }
  .roadmap-mini { padding: 18px 20px; min-height: 0; }
}

/* ─────────────────────────────────────────────────────────────
   Community cards
   ───────────────────────────────────────────────────────────── */

@media (min-width: 700px)  { .channel-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .channel-grid { grid-template-columns: repeat(4, 1fr); } }

.channel-card .glyph { color: var(--vio); display: grid; place-items: center; }

.eyebrow-hl {
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  color: var(--ink);
  display: inline-block;
}
.hl {
  position: relative;
  display: inline-block;
  color: var(--ink);
  isolation: isolate;
  padding: 0 0.18em;
}
.hl::before {
  content: "";
  position: absolute;
  left: -0.04em; right: -0.04em;
  top: 12%; bottom: 8%;
  background: var(--vio);
  z-index: -1;
  border-radius: 3px;
  transform: rotate(-1.2deg) skewX(-6deg);
  opacity: 0.95;
}

.channel-card .arr {
  font-family: var(--font-mono); color: var(--vio); font-size: 13px;
}

/* ─────────────────────────────────────────────────────────────
   Final CTA — solid accent block, mascot peek
   ───────────────────────────────────────────────────────────── */

/* Light pill button (Star on GitHub) */

.cta-btn-light .star-count {
  font-family: var(--font-mono);
  background: rgb(0 0 0 / 0.08);
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11.5px;
  letter-spacing: 0;
  color: #0A0A0B;
}

/* CLI button — dark pill with terminal-like preview baked in */

.cta-btn-cli .cta-cli-cmd .prm { color: var(--vio); margin-right: 4px; }
.cta-btn-cli .cta-cli-cmd .dim { color: rgb(245 245 244 / 0.55); }

.cta-btn-cli.copied .cta-cli-copy { color: #B0E3B5; }

/* Mascot peeking from bottom — clipped by the rounded block */

@media (max-width: 640px) {
  .cta-btn-cli .cta-cli-cmd { display: none; }
  .cta-block { padding: 64px 24px 0; }
}

/* ─────────────────────────────────────────────────────────────
   Sticky install bar
   ───────────────────────────────────────────────────────────── */
.sticky-bar {
  position: fixed; left: 0; right: 0; bottom: 16px;
  z-index: 60;
  display: flex; justify-content: center;
  padding: 0 16px;
  pointer-events: none;
  transition: transform 240ms ease, opacity 240ms ease;
}
.sticky-bar.hidden { opacity: 0; transform: translateY(20px); }
.sticky-bar .inner {
  pointer-events: auto;
  display: flex; align-items: center; gap: 8px;
  background: var(--bg-1);
  border: 1px solid var(--line-2);
  border-radius: 999px;
  padding: 6px 6px 6px 8px;
  max-width: 720px; width: 100%;
  box-shadow: 0 20px 50px -20px rgb(0 0 0 / 0.6);
}
.sticky-bar .cmd {
  flex: 1; min-width: 0;
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #050506;
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 13px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  border: 1px solid transparent;
}
.sticky-bar .cmd:hover { border-color: var(--vio); }
.sticky-bar .cmd .ico { color: var(--vio); display: grid; place-items: center; }
.sticky-bar .cmd .dollar { color: var(--vio); }
.sticky-bar .cmd .copy {
  margin-left: auto; flex-shrink: 0;
  font-family: var(--font-mono); font-size: 11px;
  padding: 2px 7px; border-radius: 999px;
  background: transparent; color: var(--mute);
  border: 1px solid var(--line-2);
}
.sticky-bar .cmd.copied .copy { background: var(--vio); color: var(--bg); border-color: var(--vio); }

/* ─────────────────────────────────────────────────────────────
   Footer
   ───────────────────────────────────────────────────────────── */
.footer {
  margin-top: 96px;
  border-top: 1px solid var(--line);
  padding: 40px 0;
  color: var(--mute);
  font-size: 13px;
}
.footer .row {
  display: flex; flex-wrap: wrap; gap: 24px;
  align-items: center; justify-content: space-between;
}

/* ─────────────────────────────────────────────────────────────
   Misc helpers
   ───────────────────────────────────────────────────────────── */
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }

.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mt-8 { margin-top: 32px; }
.mt-10 { margin-top: 40px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.text-center { text-align: center; }
.relative { position: relative; }

/* ─── Blog article (slug-addressable MDX) ──────────────────────────────
   Typography mirrors doka.guide's actual rendered article:
     prose column   ~1020px
     body           24px / lh 1.5
     h1             56px / lh 1.06
     h2             42px / lh 1.12
     h3             32px / lh 1.18
     h4             26px / lh 1.25
   clamp() degrades these on narrower viewports. */

.blog-article .container { max-width: 1020px; }

/* Page-level H1 — rendered from frontmatter.title, sits above the byline
   row. Matches the .blog-body h1 sizing so an article with the title in
   MDX vs in frontmatter looks identical. */

/* Byline — masthead row under the H1. Avatar(s) + name(s), date, then
   an optional category chip. Inline editorial layout — no plate, no bg.
   Modeled on the PostHog blog header. */

 /* kill the chip-link arrow */

/* When the browser can't load the avatar img it draws the broken-image
   glyph (and any alt text). Hide that — the wrapper's bg + initials
   show through. */

.blog-body {
  color: var(--ink-2);
  font-size: clamp(18px, 1.6vw, 24px);
  line-height: 1.5;
}
.blog-body h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(40px, 4.6vw, 56px);
  letter-spacing: -0.018em;
  line-height: 1.06;
  text-transform: uppercase;
  margin: 14px 0 40px;
  color: var(--ink);
  text-wrap: balance;
}
.blog-body h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(30px, 3.4vw, 42px);
  letter-spacing: -0.012em;
  text-transform: uppercase;
  line-height: 1.12;
  margin: 72px 0 24px;
  color: var(--ink);
}
.blog-body h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(24px, 2.5vw, 32px);
  letter-spacing: -0.005em;
  text-transform: uppercase;
  line-height: 1.18;
  margin: 48px 0 18px;
  color: var(--ink);
}
.blog-body h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(20px, 1.9vw, 26px);
  letter-spacing: -0.005em;
  text-transform: uppercase;
  line-height: 1.25;
  margin: 36px 0 14px;
  color: var(--ink);
}
.blog-body p {
  margin: 0 0 28px;
  color: var(--ink-2);
}
.blog-body p:has(+ ul), .blog-body p:has(+ ol) { margin-bottom: 16px; }
.blog-body strong { color: var(--ink); font-weight: 600; }
.blog-body del { color: var(--mute); text-decoration-color: var(--mute-2); }

/* Native markdown table (via remark-gfm). Lighter sibling of
   <ComparisonTable> — use it for plain key/value matrices. Tables
   are wrapped in <.mdx-table-scroll> by the MDX components map
   (ScrollTable override), giving them horizontal scroll on narrow
   viewports without breaking table layout semantics. */
.blog-body .mdx-table-scroll {
  margin: 32px 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  scrollbar-color: var(--bg-3) transparent;
}
.blog-body .mdx-table-scroll::-webkit-scrollbar { height: 6px; }
.blog-body .mdx-table-scroll::-webkit-scrollbar-thumb {
  background: var(--bg-3);
  border-radius: 999px;
}
.blog-body table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
  font-size: 15px;
  background: var(--bg-1);
  border-radius: 14px;
  overflow: hidden;
  min-width: max-content;
}
.blog-body thead { background: var(--bg-2); }
.blog-body th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  padding: 14px 18px;
  font-weight: 500;
}
.blog-body td {
  padding: 14px 18px;
  color: var(--ink-2);
  box-shadow: inset 0 1px 0 var(--line);
}
.blog-body tr:first-child td { box-shadow: none; }
.blog-body td code,
.blog-body th code { background: var(--bg-3); }
.blog-body em { color: var(--ink); font-style: italic; }
.blog-body ul, .blog-body ol {
  margin: 0 0 32px;
  padding-left: 28px;
  color: var(--ink-2);
}
.blog-body li { margin: 0 0 12px; line-height: 1.5; }
.blog-body li::marker { color: var(--mute); }
.blog-body blockquote {
  margin: 32px 0;
  padding: 18px 24px;
  background: var(--bg-1);
  border-radius: 12px;
  color: var(--ink-2);
  font-size: 0.95em;
}
.blog-body hr {
  border: 0;
  height: 1px;
  background: var(--line);
  margin: 48px 0;
}
@media (max-width: 720px) {
  .blog-article { padding: 64px 0 96px; }
  .blog-body p { margin-bottom: 20px; }
  .blog-body h2 { margin-top: 48px; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   MDX — blog article components
   ───────────────────────────────────────────────────────────────────────────
   Drop-in replacement for the MDX section in landing/app/globals.css.

   In globals.css there is currently a region of selectors that begins around
   `.blog-body .mdx-lede {` and ends after `.blog-body .mdx-pullquote cite {`
   (mobile overrides included). REPLACE that entire region with the rules in
   this file. The non-MDX `.blog-article` / `.blog-body` reset above it
   (margins, headings, links, paragraphs) stays as-is.

   Variant picks (locked):
     01 Tags         · C — sharp uppercase chip
     02 Inline links · D — mono chip, command-style
     03 Inline code  · A — mono on bg-2 plate
     04 Code blocks  · B — filename tab top
     05 Callouts     · D — big glyph plate
     06 CTA banner   · B — full-bleed orange plate
     07 Link cards   · D — listing of related links
     08 Compare      · B (cards) default; A (rows) via layout="rows"
     09 Pricing      · A (striped rows) + PriceHero (D)
     10 FAQ          · A, native single-open via <details name="">
     11 Pull quote   · D — author plate, avatar
     12 Stat strips  · A (three-up) + BarStats (D)
     13 Steps        · B — vertical timeline
     14 Figures      · A (caption below) with optional gallery (D)
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── Default `a` inside the blog body — variant 02-D ─────────────
   Mono chip with `→` prefix. Strong stylistic choice: every inline
   link reads as "follow this". If a particular paragraph needs a
   quieter link, wrap text in <span> or use a footnote.
   ───────────────────────────────────────────────────────────────── */
/* Scope the chip styling to inline links only — component-level
   anchors (mdx-cta, mdx-linklist-row) get their own full styling.
   Using :not() instead of a cancel rule avoids the specificity war
   where `initial` reverts to user-agent defaults (serif font, no bg)
   and breaks the orange CTA + link-list rows. */
.blog-body a:not(.mdx-cta):not(.mdx-linklist-row):not(.nav-back) {
  color: var(--ink);
  background: var(--bg-2);
  padding: 1px 8px 2px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.92em;
  line-height: 1.4;
  text-decoration: none;
  white-space: nowrap;
  transition: background 160ms ease;
}
.blog-body a:not(.mdx-cta):not(.mdx-linklist-row):not(.nav-back)::before {
  content: "→";
  color: var(--vio);
  margin-right: 6px;
}
.blog-body a:not(.mdx-cta):not(.mdx-linklist-row):not(.nav-back):hover {
  background: var(--bg-3);
}

/* ─── Inline code — variant 03-A ──────────────────────────────────
   Bare `backticks` in MDX. */
.blog-body :not(pre) > code,
.blog-body .mdx-code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--bg-2);
  color: var(--ink);
  padding: 2px 7px;
  border-radius: 4px;
}

/* ─── Lede ──────────────────────────────────────────────────────── */
.blog-body .mdx-lede {
  font-size: 22px;
  line-height: 1.5;
  color: var(--ink);
  margin: 0 0 40px;
  max-width: 64ch;
  font-weight: 400;
}
/* MDX wraps inner text in <p>; inherit Lede's typography so the inner
   paragraph doesn't pick up the default blog-body p margins / color. */
.blog-body .mdx-lede > p {
  margin: 0;
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
}

/* ═════════════════════════════════════════════════════════════════
   01 · Tag — variant C (sharp uppercase chip)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-tag {
  display: inline-block;
  padding: 1px 7px 2px;
  border-radius: 3px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.72em;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  vertical-align: 2px;
  line-height: 1.4;
  white-space: nowrap;
}
.blog-body .mdx-tag-neutral {
  background: var(--ink);
  color: var(--bg);
}
.blog-body .mdx-tag-accent {
  background: var(--vio);
  color: var(--bg);
}
.blog-body .mdx-tag-warn {
  background: var(--warn, #F2C66B);
  color: var(--bg);
}

/* ═════════════════════════════════════════════════════════════════
   05 · Callout — variant D (big glyph plate)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-callout {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  background: var(--bg-1);
  border-radius: 18px;
  padding: 26px 28px;
  margin: 32px 0;
}
.blog-body .mdx-callout-glyph {
  width: 78px;
  height: 78px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 38px;
  line-height: 1;
  color: var(--bg);
}
.blog-body .mdx-callout-info   .mdx-callout-glyph { background: var(--ink); }
.blog-body .mdx-callout-good   .mdx-callout-glyph { background: var(--vio); }
.blog-body .mdx-callout-warn   .mdx-callout-glyph { background: var(--warn, #F2C66B); }
.blog-body .mdx-callout-danger .mdx-callout-glyph { background: #E89094; }
.blog-body .mdx-callout-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 6px;
}
.blog-body .mdx-callout-content { color: var(--ink-3); font-size: 16px; line-height: 1.5; }
.blog-body .mdx-callout-content > :first-child { margin-top: 0; }
.blog-body .mdx-callout-content > :last-child { margin-bottom: 0; }
.blog-body .mdx-callout-content p { margin: 0; }

/* ═════════════════════════════════════════════════════════════════
   06 · CTA — variant B (full-bleed orange plate)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: center;
  background: var(--vio);
  color: var(--bg);
  border-radius: 22px;
  padding: 32px 36px;
  margin: 40px 0;
  text-decoration: none;
  transition: transform 180ms ease;
}
.blog-body .mdx-cta:hover { transform: translateY(-2px); }
.blog-body .mdx-cta-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 30px;
  letter-spacing: -0.02em;
  line-height: 1.0;
  text-transform: uppercase;
  margin: 0 0 8px;
  color: var(--bg);
}
.blog-body .mdx-cta-caption {
  margin: 0;
  color: rgb(10 10 11 / 0.7);
  font-size: 15px;
  max-width: 44ch;
  line-height: 1.5;
}
.blog-body .mdx-cta-caption .mdx-code,
.blog-body .mdx-cta-caption code {
  background: rgb(10 10 11 / 0.16);
  color: var(--bg);
}
.blog-body .mdx-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--bg);
  color: var(--ink);
  padding: 14px 22px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
}
.blog-body .mdx-cta-arrow {
  color: var(--vio);
  font-family: var(--font-mono);
  transition: transform 180ms ease;
}
.blog-body .mdx-cta:hover .mdx-cta-arrow { transform: translateX(4px); }

/* ═════════════════════════════════════════════════════════════════
   07 · LinkList — variant D (related-listing)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-linklist {
  background: var(--bg-1);
  border-radius: 16px;
  padding: 8px 0;
  margin: 32px 0;
  display: block;
}
.blog-body .mdx-linklist-head {
  padding: 14px 22px 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mute);
  margin: 0;
}
.blog-body .mdx-linklist-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 22px;
  color: var(--ink);
  text-decoration: none;
}
.blog-body .mdx-linklist-row + .mdx-linklist-row {
  box-shadow: inset 0 1px 0 var(--line);
}
.blog-body .mdx-linklist-row:hover { background: var(--bg-2); }
.blog-body .mdx-linklist-num {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--mute);
  width: 26px;
  text-align: right;
  flex-shrink: 0;
}
.blog-body .mdx-linklist-title { flex: 1; font-size: 16px; line-height: 1.4; }
.blog-body .mdx-linklist-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--mute);
  flex-shrink: 0;
}
.blog-body .mdx-linklist-arrow {
  color: var(--vio);
  font-family: var(--font-mono);
  flex-shrink: 0;
  transition: transform 180ms ease;
}
.blog-body .mdx-linklist-row:hover .mdx-linklist-arrow { transform: translateX(4px); }

/* ═════════════════════════════════════════════════════════════════
   08 · ComparisonTable
       cards (B, default) — column-per-vendor
       rows  (A)          — striped rows, dense layout
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-compare { margin: 36px 0; }
.blog-body .mdx-compare-caption {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--mute);
  text-align: center;
  line-height: 1.5;
}

/* ── B · Cards ── */
/* Column count is passed via `--cmp-cols` from the component (inline
   style) — putting it on a CSS var instead of `style.gridTemplateColumns`
   lets the mobile rule collapse to a single column without fighting
   inline-style specificity. */
.blog-body .mdx-cmp-cards {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(var(--cmp-cols, 3), minmax(0, 1fr));
}
.blog-body .mdx-cmp-card {
  background: var(--bg-1);
  border-radius: 18px;
  padding: 22px 22px 14px;
  display: grid;
  gap: 8px;
}
.blog-body .mdx-cmp-card.is-accent {
  background: var(--vio);
  color: var(--bg);
}
.blog-body .mdx-cmp-card-head {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
  color: var(--ink);
}
.blog-body .mdx-cmp-card.is-accent .mdx-cmp-card-head { color: var(--bg); }
.blog-body .mdx-cmp-card-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 12px;
  padding: 10px 0;
  box-shadow: inset 0 -1px 0 var(--line);
  font-size: 14px;
}
.blog-body .mdx-cmp-card-row:last-child { box-shadow: none; }
.blog-body .mdx-cmp-card.is-accent .mdx-cmp-card-row {
  box-shadow: inset 0 -1px 0 rgb(10 10 11 / 0.18);
}
.blog-body .mdx-cmp-card-lbl { color: var(--ink-3); }
.blog-body .mdx-cmp-card.is-accent .mdx-cmp-card-lbl { color: rgb(10 10 11 / 0.62); }
.blog-body .mdx-cmp-card-val {
  font-family: var(--font-mono);
  color: var(--ink-2);
  font-size: 13px;
}

/* ── A · Rows (also used by PricingTable) ── */
/* Wrapper enables horizontal scroll on narrow viewports without
   destroying the grid layout. The grid itself keeps its desktop
   columns; the wrapper clips + scrolls. min-width inside the grid
   forces the columns to render at their natural width rather than
   squashing. */
.blog-body .mdx-cmp-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  /* Subtle fade hint on the right edge so the affordance reads as
     "more content over there" rather than a cut-off card. Hidden
     once the user scrolls to the end via scroll-padding trick. */
  scrollbar-color: var(--bg-3) transparent;
}
.blog-body .mdx-cmp-scroll::-webkit-scrollbar { height: 6px; }
.blog-body .mdx-cmp-scroll::-webkit-scrollbar-thumb {
  background: var(--bg-3);
  border-radius: 999px;
}
.blog-body .mdx-cmp-grid {
  border-radius: 14px;
  overflow: hidden;
  display: grid;
  font-size: 15px;
  min-width: max-content;
}
.blog-body .mdx-cmp-h {
  background: var(--bg-1);
  color: var(--mute);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 18px;
}
.blog-body .mdx-cmp-h.is-accent { color: var(--vio); }
/* Center value-column headers so they line up with the centered tick /
   text cells below. First grid column stays left-aligned because that's
   the feature / label column. */
.blog-body .mdx-cmp-grid > .mdx-cmp-h { text-align: center; }
.blog-body .mdx-cmp-grid > .mdx-cmp-h:first-child { text-align: left; }
.blog-body .mdx-cmp-c {
  padding: 16px 18px;
  background: var(--bg-1);
  color: var(--ink-2);
}
/* Alternating row stripe. Earlier we relied on `:nth-of-type(8n+5..8)`
   which silently assumes a 4-column grid (1 feature + 3 brands) — in
   tables with a different brand count the modulo math falls on the
   wrong cells, producing half-striped rows with a visible vertical
   seam down the middle. The component now tags every cell of an odd
   row with `.is-stripe`, so the stripe is correct regardless of how
   many columns the table has. */
.blog-body .mdx-cmp-grid > .mdx-cmp-c { background: var(--bg-1); }
.blog-body .mdx-cmp-grid > .mdx-cmp-c.is-stripe { background: var(--bg-2); }
.blog-body .mdx-cmp-c-feat .lbl { display: block; color: var(--ink); font-weight: 500; }
.blog-body .mdx-cmp-c-feat .sub { display: block; color: var(--mute); font-size: 13px; margin-top: 2px; }
.blog-body .mdx-cmp-c-val { text-align: center; }
.blog-body .mdx-cmp-c-text {
  font-family: var(--font-mono);
  font-size: 14px;
  text-align: center;
}
.blog-body .mdx-cmp-c-text.is-accent { color: var(--vio); font-weight: 700; }

/* Ticks and chips */
.blog-body .mdx-tick {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--vio);
}
.blog-body .mdx-tick.on-accent { color: var(--bg); }
.blog-body .mdx-tick-no { color: var(--mute-2); font-weight: 400; }
.blog-body .mdx-tick-na { color: var(--mute-2); font-weight: 400; }
.blog-body .mdx-cell-chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--bg-3);
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 12px;
}
.blog-body .mdx-cell-text {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--ink-2);
}

/* ═════════════════════════════════════════════════════════════════
   09 · PriceHero — variant D
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-pricehero {
  background: var(--bg-1);
  border-radius: 22px;
  padding: 32px 36px;
  margin: 40px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 36px;
  align-items: center;
}
.blog-body .mdx-pricehero-eye {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--vio);
  margin: 0 0 10px;
}
.blog-body .mdx-pricehero-ttl {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 28px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--ink);
  line-height: 1.04;
}
.blog-body .mdx-pricehero-sub {
  color: var(--ink-3);
  font-size: 15px;
  margin: 8px 0 0;
  max-width: 38ch;
  line-height: 1.5;
}
.blog-body .mdx-pricehero-r { text-align: right; }
.blog-body .mdx-pricehero-big {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(56px, 8vw, 88px);
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: var(--vio);
  margin: 0;
}
.blog-body .mdx-pricehero-big small {
  font-size: 14px;
  color: var(--mute);
  font-family: var(--font-mono);
  font-weight: 400;
  letter-spacing: 0;
  margin-left: 4px;
}
.blog-body .mdx-pricehero-cap {
  color: var(--mute);
  font-size: 13px;
  margin: 6px 0 0;
  font-family: var(--font-mono);
}

/* ═════════════════════════════════════════════════════════════════
   10 · FAQ — variant A, single-open accordion
   Now backed by a framer-motion client component (Faq.tsx) — height
   and opacity animate on toggle, chevron rotates via motion.span.
   Markup: <div.mdx-faq-item> > <button.mdx-faq-q> + <div.mdx-faq-a>.
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-faq {
  background: var(--bg-1);
  border-radius: 16px;
  overflow: hidden;
  margin: 32px 0;
}
.blog-body .mdx-faq-item { margin: 0; }
.blog-body .mdx-faq-item + .mdx-faq-item {
  box-shadow: inset 0 1px 0 var(--line);
}
.blog-body .mdx-faq-q {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 24px;
  width: 100%;
  background: transparent;
  border: 0;
  outline: 0;
  text-align: left;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 16px;
  color: var(--ink);
  cursor: pointer;
  user-select: none;
  transition: background 160ms ease;
}
.blog-body .mdx-faq-q:hover { background: var(--bg-2); }
.blog-body .mdx-faq-q:focus-visible {
  background: var(--bg-2);
  box-shadow: inset 2px 0 0 var(--vio);
}
.blog-body .mdx-faq-chev {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 18px;
  color: var(--vio);
  flex-shrink: 0;
  /* Rotation handled by framer-motion via animate prop. */
}
.blog-body .mdx-faq-a {
  padding: 0 24px 22px 56px;
  color: var(--ink-3);
  font-size: 15.5px;
  line-height: 1.6;
}
.blog-body .mdx-faq-a > :first-child { margin-top: 0; }
.blog-body .mdx-faq-a > :last-child { margin-bottom: 0; }
.blog-body .mdx-faq-a p { margin: 0 0 14px; }
.blog-body .mdx-faq-a p:last-child { margin-bottom: 0; }

/* ═════════════════════════════════════════════════════════════════
   11 · PullQuote — variant D (author plate, avatar)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-pullquote {
  margin: 40px 0;
  padding: 26px 28px;
  background: var(--bg-1);
  border-radius: 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 28px;
  align-items: center;
  border-left: none;  /* override blog-body default blockquote */
}
.blog-body .mdx-pullquote-text,
.blog-body .mdx-pullquote-text p {
  margin: 0;
  font-size: 19px;
  line-height: 1.5;
  color: var(--ink-2);
  font-style: italic;
}
.blog-body .mdx-pullquote-who {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 14px;
  align-items: center;
}
.blog-body .mdx-pullquote-avatar {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: var(--vio);
  color: var(--bg);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0;
}
.blog-body .mdx-pullquote-name {
  font-size: 14px;
  color: var(--ink);
  font-weight: 600;
}
.blog-body .mdx-pullquote-role {
  font-size: 12.5px;
  color: var(--mute);
  font-family: var(--font-mono);
  margin-top: 2px;
}

/* ═════════════════════════════════════════════════════════════════
   12 · Stats — variant A (three-up plates) + BarStats (D)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-statrow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 32px 0;
}
.blog-body .mdx-stat {
  background: var(--bg-1);
  border-radius: 18px;
  padding: 26px 24px;
}
.blog-body .mdx-stat-value {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 48px;
  line-height: 0.95;
  letter-spacing: -0.025em;
  color: var(--vio);
  margin-bottom: 8px;
}
.blog-body .mdx-stat-label {
  font-size: 13.5px;
  color: var(--ink-3);
  line-height: 1.4;
}

.blog-body .mdx-barstats {
  background: var(--bg-1);
  border-radius: 18px;
  padding: 26px 28px;
  margin: 32px 0;
  display: grid;
  gap: 18px;
}
.blog-body .mdx-barstats-row {
  display: grid;
  grid-template-columns: minmax(160px, 220px) 1fr 72px;
  gap: 20px;
  align-items: center;
}
.blog-body .mdx-barstats-lbl {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mute);
}
.blog-body .mdx-barstats-lbl b {
  color: var(--ink);
  font-weight: 500;
}
.blog-body .mdx-barstats-bar {
  height: 8px;
  background: var(--bg-3);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}
.blog-body .mdx-barstats-bar i {
  display: block;
  height: 100%;
  background: var(--ink-2);
  border-radius: 999px;
}
.blog-body .mdx-barstats-bar.is-accent i { background: var(--vio); }
.blog-body .mdx-barstats-v {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  color: var(--ink);
  text-align: right;
  letter-spacing: -0.01em;
}

/* ═════════════════════════════════════════════════════════════════
   13 · Steps — variant B (vertical timeline)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-steps {
  list-style: none;
  margin: 32px 0;
  padding: 0 0 0 8px;
  display: grid;
  gap: 28px;
  counter-reset: step;
}
.blog-body .mdx-step {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  position: relative;
  counter-increment: step;
}
/* Connector line: emitted by every step EXCEPT the last, starting just
   below the circle (top: 60px = circle height 56 + 4px breath) and
   extending down through the gap into the next circle. Using ::after
   on the current step (rather than ::before on the next) lets us
   pin the line to a stable origin — the current circle's center
   column at left:27. */
.blog-body .mdx-step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 27px;
  top: 60px;
  bottom: -32px;
  width: 2px;
  background: var(--bg-3);
}
.blog-body .mdx-step-num {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background: var(--bg-1);
  color: var(--vio);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  display: grid;
  place-items: center;
  letter-spacing: -0.02em;
}
.blog-body .mdx-step-num:empty::before {
  content: counter(step, decimal-leading-zero);
}
.blog-body .mdx-step-ttl {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin: 6px 0 6px;
}
.blog-body .mdx-step-text {
  color: var(--ink-3);
  font-size: 15.5px;
  line-height: 1.6;
  max-width: 64ch;
}
.blog-body .mdx-step-text > :first-child { margin-top: 0; }
.blog-body .mdx-step-text > :last-child { margin-bottom: 0; }
.blog-body .mdx-step-text p { margin: 0 0 10px; }
.blog-body .mdx-step-text p:last-child { margin-bottom: 0; }

/* ═════════════════════════════════════════════════════════════════
   14 · Figure — variant A (caption below) + optional gallery (D)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-figure {
  margin: 32px 0;
}
.blog-body .mdx-figure-cell {
  display: block;
  background: var(--bg-1);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  aspect-ratio: 16 / 9;
}
.blog-body .mdx-figure-cell img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.blog-body .mdx-figure-cell-empty::after {
  content: "Image missing";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--mute);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.blog-body .mdx-figure-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.blog-body .mdx-figure-gallery .mdx-figure-cell {
  aspect-ratio: 4 / 5;
}
.blog-body .mdx-figure-label {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 4px 10px;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  border-radius: 4px;
}
.blog-body .mdx-figure figcaption {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--mute);
  line-height: 1.5;
}
.blog-body .mdx-figure figcaption b {
  color: var(--ink-2);
  font-weight: 500;
  margin-right: 8px;
}

/* ═════════════════════════════════════════════════════════════════
   04 · CodeBlock — variant B (filename tab top)
   Bare ```fenced``` code in MDX also picks up the same shell (no tab)
   via the .blog-body pre rules at the end of this file.
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-codeblock {
  margin: 32px 0;
}
.blog-body .mdx-codeblock-bar {
  display: flex;
  align-items: stretch;
  font-family: var(--font-mono);
  font-size: 12.5px;
}
.blog-body .mdx-codeblock-tab {
  background: var(--bg-2);
  color: var(--ink);
  padding: 9px 14px 9px 16px;
  border-radius: 10px 10px 0 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.blog-body .mdx-codeblock-tab .ic { color: var(--vio); }
.blog-body .mdx-codeblock-meta {
  margin-left: auto;
  color: var(--mute);
  padding: 9px 14px;
  align-self: center;
}
.blog-body .mdx-codeblock pre {
  margin: 0;
  background: var(--bg-2);
  color: var(--ink);
  border-radius: 0 14px 14px 14px;
  padding: 22px 26px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.7;
  overflow-x: auto;
  white-space: pre;
}
.blog-body .mdx-codeblock pre code {
  font-family: inherit;
  background: transparent;
  padding: 0;
  border-radius: 0;
  font-size: inherit;
  color: inherit;
}

/* Bare ```fence``` code blocks — match the CodeBlock shell, no tab. */
.blog-body > pre,
.blog-body p + pre,
.blog-body pre:not(.mdx-codeblock pre) {
  margin: 32px 0;
  background: var(--bg-2);
  color: var(--ink);
  border-radius: 14px;
  padding: 22px 26px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.7;
  overflow-x: auto;
}
.blog-body pre code {
  font-family: inherit;
  background: transparent;
  padding: 0;
  border-radius: 0;
  color: inherit;
}

/* highlight.js theme — palette mapped onto our tokens. Server-rendered
   by rehype-highlight at build time, zero JS at runtime. */
.blog-body .hljs              { color: var(--ink); background: transparent; }
.blog-body .hljs-comment,
.blog-body .hljs-quote         { color: var(--mute); font-style: italic; }
.blog-body .hljs-keyword,
.blog-body .hljs-selector-tag,
.blog-body .hljs-literal,
.blog-body .hljs-section,
.blog-body .hljs-link           { color: var(--vio); }
.blog-body .hljs-built_in,
.blog-body .hljs-type           { color: #F2A0BD; }
.blog-body .hljs-string,
.blog-body .hljs-meta-string    { color: var(--warn, #F2C66B); }
.blog-body .hljs-number,
.blog-body .hljs-attr,
.blog-body .hljs-symbol,
.blog-body .hljs-bullet,
.blog-body .hljs-template-tag,
.blog-body .hljs-template-variable { color: #C8A2FF; }
.blog-body .hljs-title,
.blog-body .hljs-name,
.blog-body .hljs-function .hljs-title,
.blog-body .hljs-class .hljs-title { color: var(--ink); font-weight: 600; }
.blog-body .hljs-tag             { color: var(--ink-3); }
.blog-body .hljs-attribute       { color: var(--vio-2, #F2A0BD); }
.blog-body .hljs-variable,
.blog-body .hljs-params          { color: var(--ink-2); }
.blog-body .hljs-meta            { color: var(--mute); }
.blog-body .hljs-emphasis        { font-style: italic; }
.blog-body .hljs-strong          { font-weight: 700; }
.blog-body .hljs-addition        { color: #7BD89E; }
.blog-body .hljs-deletion        { color: #E89094; }

/* ═════════════════════════════════════════════════════════════════
   CodeTabs — multi-filename group built on the CodeBlock chrome.
   Each tab uses the same .mdx-codeblock-tab pill as a single
   <CodeBlock filename …>; the active tab connects with the panel
   below, inactive tabs sit one bg-step darker.
   Class composition: <div class="mdx-codeblock mdx-codetabs">
   reuses every base codeblock rule, this section only adds the
   multi-tab specifics.
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-codetabs .mdx-codeblock-bar {
  /* allow the tab row to wrap rather than overflow on narrow viewports */
  flex-wrap: wrap;
  gap: 2px;
  padding-right: 12px;
}
.blog-body .mdx-codetabs-tab {
  /* button reset on top of base .mdx-codeblock-tab styles */
  border: 0;
  cursor: pointer;
  background: var(--bg-1);
  color: var(--mute);
  font: inherit;
  transition: color 160ms ease, background 160ms ease;
}
.blog-body .mdx-codetabs-tab .ic { color: var(--mute-2); }
.blog-body .mdx-codetabs-tab:hover {
  color: var(--ink-3);
  background: var(--bg-3);
}
.blog-body .mdx-codetabs-tab.is-active {
  /* connects with the panel below — same bg as <pre> */
  background: var(--bg-2);
  color: var(--ink);
}
.blog-body .mdx-codetabs-tab.is-active .ic { color: var(--vio); }
.blog-body .mdx-codetabs-tab:focus-visible {
  outline: 2px solid var(--vio);
  outline-offset: -2px;
}
.blog-body .mdx-codetabs-panel {
  /* match the base .mdx-codeblock pre — same bg, padding, font */
  background: var(--bg-2);
  color: var(--ink);
  padding: 22px 26px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.7;
  overflow-x: auto;
  /* don't round under the tab row */
  border-radius: 0 14px 14px 14px;
}
.blog-body .mdx-codetabs-panel pre {
  background: transparent;
  margin: 0;
  padding: 0;
  border-radius: 0;
}

/* ═════════════════════════════════════════════════════════════════
   Legacy — TeamRecs (kept for ralphy-vs-higgsfield article)
   ═════════════════════════════════════════════════════════════════ */
.blog-body .mdx-recs {
  background: var(--bg-1);
  border-radius: 16px;
  padding: 8px 24px;
  margin: 32px 0;
}
.blog-body .mdx-rec {
  padding: 18px 0;
  box-shadow: inset 0 -1px 0 var(--line);
}
.blog-body .mdx-rec:last-child { box-shadow: none; }
.blog-body .mdx-rec-team {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--vio);
  margin: 0 0 6px;
}
.blog-body .mdx-rec-body,
.blog-body .mdx-rec-body p { margin: 0; color: var(--ink-3); font-size: 15.5px; line-height: 1.55; font-style: normal; }
.blog-body .mdx-rec-pick { color: var(--ink); font-weight: 600; }

/* ═════════════════════════════════════════════════════════════════
   Mobile
   ═════════════════════════════════════════════════════════════════ */
@media (max-width: 760px) {
  .blog-body .mdx-cta,
  .blog-body .mdx-pullquote,
  .blog-body .mdx-pricehero {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .blog-body .mdx-pricehero-r { text-align: left; }

  .blog-body .mdx-callout {
    grid-template-columns: 56px 1fr;
    gap: 18px;
    padding: 22px 22px;
  }
  .blog-body .mdx-callout-glyph {
    width: 56px;
    height: 56px;
    font-size: 28px;
    border-radius: 12px;
  }

  .blog-body .mdx-statrow {
    grid-template-columns: 1fr;
  }
  /* Cards variant — stack to a single column on mobile. Note we
     override `grid-template-columns` directly (not the `--cmp-cols`
     var the component sets inline): inline custom-property
     declarations beat stylesheet declarations of the same var, so
     touching the var in CSS wouldn't win. There is no inline
     grid-template-columns, so this overrides cleanly. */
  .blog-body .mdx-cmp-cards {
    grid-template-columns: 1fr;
  }

  .blog-body .mdx-barstats-row {
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "lbl v"
      "bar bar";
    gap: 8px 16px;
  }
  .blog-body .mdx-barstats-lbl { grid-area: lbl; }
  .blog-body .mdx-barstats-v   { grid-area: v; }
  .blog-body .mdx-barstats-bar { grid-area: bar; }

  .blog-body .mdx-figure-gallery { grid-template-columns: 1fr; }

  /* Rows / pricing tables keep their desktop column widths and scroll
     horizontally inside .mdx-cmp-scroll. Native markdown tables behave
     the same via .mdx-table-scroll. Both communicate "more →" with the
     thin scrollbar; no clipped columns, no faux-mobile reshuffle. */
  .blog-body .mdx-cmp-c,
  .blog-body .mdx-cmp-h { padding-left: 14px; padding-right: 14px; }
  .blog-body td,
  .blog-body th { padding-left: 14px; padding-right: 14px; }

  /* LinkList — keep num + title on the first line; meta drops below
     so the title doesn't squeeze against the right edge. */
  .blog-body .mdx-linklist-row {
    flex-wrap: wrap;
    column-gap: 14px;
    row-gap: 4px;
    padding: 14px 18px;
  }
  .blog-body .mdx-linklist-num { width: 22px; }
  .blog-body .mdx-linklist-title { flex: 1 1 auto; min-width: 0; }
  .blog-body .mdx-linklist-meta {
    flex: 1 0 100%;
    order: 3;
    padding-left: 36px;
  }
  .blog-body .mdx-linklist-arrow { order: 2; }

  /* TeamRecs cards — stack and tighten padding. */
  .blog-body .mdx-rec {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 22px 22px;
  }

  /* CodeBlock — shrink padding so long lines have room to breathe
     inside the (already overflow-x: auto) <pre>. */
  .blog-body .mdx-codeblock pre,
  .blog-body pre:not(.mdx-codeblock pre) {
    padding: 18px 18px;
    font-size: 13px;
  }
}

/* ─── Skills gallery page ─────────────────────────────────────────────
   Visual language mirrors the Roadmap section: bg-tint plates on the
   page surface, no strokes, no dashed dividers. Hierarchy comes from
   background contrast steps (bg → bg-1 → bg-2 → bg-3) and spacing. */

.skills-hero .eyebrow {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--vio);
  margin-bottom: 18px;
}

/* Filter row — pill-tabs that drive the listing's namespace filter.
   Wraps as a horizontal scroll-row on tight viewports. */

.skill-filter.is-active {
  background: var(--ink);
  color: var(--bg);
}

.skill-filter.is-active .skill-filter-count {
  background: rgb(0 0 0 / 0.18);
  color: var(--bg);
}

/* Wide cards — full-width plates stacked vertically. Two-column
   body grid (info on the left, i/o + cta aside on the right).
   `position: relative` is required by framer-motion's popLayout
   mode — exiting cards get position:absolute and must be scoped
   to the list bounds, not the document body, or the surviving
   cards visibly jump while the layout snaps around the rogue. */

@media (max-width: 720px) {
  .skill-wide { padding: 24px 22px; gap: 20px; border-radius: 18px; }
}

@media (min-width: 880px) {
  .skill-wide-body {
    grid-template-columns: 1fr 340px;
    gap: 40px;
    align-items: center;
  }
}

/* Aside (right column on desktop): IO plate + CTA */

/* How-skills-work explainer block — same bg-1 plate language. */

/* ─────────────────────────────────────────────────────────────
   Blog index — hero + tag-filterable card grid
   Same bento language as /skills (filter chips, bg-1 plates).
   ───────────────────────────────────────────────────────────── */

.blog-filter.is-active { background: var(--ink); color: var(--bg); }

.blog-filter.is-active .blog-filter-count {
  background: rgb(0 0 0 / 0.18);
  color: var(--bg);
}

@media (min-width: 720px) {
  .blog-list { grid-template-columns: 1fr 1fr; gap: 18px; }
}
@media (min-width: 1100px) {
  .blog-list { grid-template-columns: 1fr 1fr 1fr; }
}

/* ─────────────────────────────────────────────────────────────
   Mobile burger menu + animated sheet
   Hidden ≥1000px (the .nav-links breakpoint). Sheet drops below
   the floating nav pill; backdrop scrim sits behind it. Animation
   handled by framer-motion in components/Nav.tsx — CSS only owns
   layout, sizing, and visibility.
   ───────────────────────────────────────────────────────────── */

@media (min-width: 1200px) {
  .nav-burger { display: none; }
}

/* Hide secondary nav-right items on tight viewports so the burger
   carries them. Docs is duplicated in the sheet; the star CTA gets
   its own row in the sheet. */
@media (max-width: 720px) {
  .nav-ghost { display: none; }
  .nav-cta { display: none; }
  .nav-inner { padding: 8px 8px 8px 16px; gap: 10px; }
  .nav { top: 10px; padding: 0 10px; }
}

/* The parent <header className="nav"> sets pointer-events: none on
   itself so the floating pill doesn't block clicks on the page below.
   The scrim + sheet are children of <header>, so they inherit none —
   without explicit `auto`, every tap-through fails. That was the
   "links not clickable in burger" bug. */

.nav-sheet {
  position: fixed;
  top: 76px;
  left: 16px;
  right: 16px;
  z-index: 60;
  max-width: 520px;
  margin: 0 auto;
  padding: 12px;
  background: var(--bg-1);
  border-radius: 22px;
  max-height: calc(100dvh - 100px);
  overflow-y: auto;
  pointer-events: auto;
}
@media (min-width: 1200px) {
  .nav-sheet, .nav-scrim { display: none; }
}

/* Sheet header — title + an explicit close button, so the user has
   three ways to dismiss the menu (close button, scrim tap, Escape). */

/* Star-count chip inside the CTA pill. On the cream ink background
   we need a darker plate with dark text — previously was rgb(0 0 0)
   with color: var(--bg) which read as black-on-black on some screens.
   Now: bg-2 plate with full ink text for unambiguous contrast. */

/* ─────────────────────────────────────────────────────────────
   Library — /library + /library/[slug]
   BRAND_DESIGN compliance:
     §3 binary radii — pills 999px, cards 18px, sharp 0 for chips
     §4 no shadows — depth via bg-step contrast (bg → bg-1 → bg-2)
     §5 no borders on cards/buttons/pills — bg-tint separates
     §1 big type — h1 keeps .skills-h1, h2 set at 28-32px
   ───────────────────────────────────────────────────────────── */

/* Library listing — filter bar + tag row + masonry grid.
   Pinterest-style multi-column flow so cards reflow naturally based on
   each cover's natural aspect. Same pattern the landing's Showcase uses. */

/* Filter UI — full-width search bar on top, then kind chips, then tag chips.
   Inactive chip = bg-1 (same as cards). Active chip = solid vio fill so it
   reads at a glance, no hunting for tint deltas. */

.lib-search-input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  padding: 2px 0;
  min-width: 0;
}
.lib-search-input::placeholder { color: var(--mute-2); }

.lib-chip.is-active {
  color: var(--bg);
  background: var(--vio);
  font-weight: 600;
}
.lib-chip.is-active:hover { background: var(--vio-2); }

.lib-tagchip.is-active {
  color: var(--bg);
  background: var(--vio);
}
.lib-tagchip.is-active:hover { background: var(--vio-2); }

.lib-tagchip.is-active .lib-tagchip-count { color: rgb(0 0 0 / 0.55); }

@media (max-width: 1100px) { .lib-grid { columns: 2; } }
@media (max-width: 640px)  { .lib-grid { columns: 1; } }

/* Cover — the image is flush with the card's left/right/top edges and has
   its OWN border-radius on all 4 corners. Top corners align with the card
   corners (same radius). Bottom corners curve inward, revealing the card
   bg-1 in the pinch — that's the "double-rounded" effect, no padding
   between card and image. */

/* Detail page — back link */

/* Detail page — CTA. The shape echoes the landing's install-cmd block: a
   dark code-style line you click to copy. No candy orange-on-orange pill.
   Visual hierarchy reads: eyebrow → code row → hint. The whole row is the
   button so the affordance is unambiguous. */

/* Detail page — Examples grid */

/* Examples grid — each tile is a MediaPlayer (raw image/video + own expand
   button). Caption below. No bespoke card chrome. */

@media (max-width: 1100px) { .lib-examples-grid { columns: 2; } }
@media (max-width: 640px)  { .lib-examples-grid { columns: 1; } }

/* Detail-page hero — split layout. Left column has the media (capped so a
   9:16 vertical doesn't dominate); right column has title, tagline, CTA.
   Long-form body / examples flow underneath in single-column. Mobile
   stacks media on top, content below. */

.lib-hero-media-sticky {
  position: sticky;
  top: 96px;
  max-width: 420px;
}
.lib-hero-media-sticky .mp-shell { max-height: 70vh; }
.lib-hero-media-sticky .mp-video,
.lib-hero-media-sticky .mp-image {
  max-height: 70vh;
  object-fit: contain;
}

@media (max-width: 900px) {
  .lib-hero { padding: 72px 0 16px; }
  .lib-hero-split { grid-template-columns: 1fr; gap: 28px; }
  .lib-hero-media-sticky { position: static; max-width: 100%; margin: 0 auto; }
  /* No height cap on mobile — let the inline media use the container width
     proportional to its natural aspect. Cap was making 9:16 videos render
     at ~70% of available width which felt squashed. */
  .lib-hero-media-sticky .mp-shell { max-height: none; }
}

/* ─────────────────────────────────────────────────────────────
   MediaPlayer — uniform shell for images + videos.
   Adapted from the reference shadcn/Tailwind player. Animated entrance,
   hover-to-reveal controls block at the bottom (glassy chip), inline
   progress + volume sliders, 4-speed selector.
   ───────────────────────────────────────────────────────────── */
.mp-shell {
  position: relative;
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  background: #050506;
}
.mp-shell-video { cursor: pointer; }
.mp-shell-clickable { cursor: zoom-in; }
.mp-shell-clickable:focus-visible { outline: 2px solid var(--vio); outline-offset: 2px; }
.mp-shell-image:hover .mp-expand,
.mp-shell-video:hover .mp-expand { opacity: 1; }
.mp-shell-fs {
  background: transparent;
  border-radius: 18px;
  cursor: default;
}
.mp-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #050506;
}
.mp-image {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  background: #050506;
}

.mp-controls {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 10px;
  padding: 14px 16px;
  background: rgb(17 17 17 / 0.66);
  backdrop-filter: blur(14px);
  border-radius: 16px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.mp-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Expand-to-fullscreen affordance — floats top-right on the inline player. */
.mp-expand {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  background: rgb(17 17 17 / 0.66);
  backdrop-filter: blur(8px);
  color: var(--ink);
  border-radius: 999px;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms cubic-bezier(0.22, 1, 0.36, 1), background 180ms;
  z-index: 5;
}
.mp-expand:hover { background: rgb(17 17 17 / 0.86); }
/* On images the expand affordance is purely decorative — the whole shell
   is the click target, but the icon should still light up on hover. */
.mp-expand-static { pointer-events: none; }
.mp-shell-image:hover .mp-expand-static { background: rgb(17 17 17 / 0.86); }
@media (hover: none) { .mp-expand { opacity: 1; } }

/* While a MediaPlayer is expanded, hide the sticky nav — its own
   stacking context outranks fixed-position descendants on some browsers,
   so we kill it at the source instead of fighting z-index. */
body.mp-modal-open .nav { visibility: hidden; }

/* Fullscreen overlay — opaque backdrop, large media, sits above everything. */
.mp-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgb(5 5 6 / 0.98);
  backdrop-filter: blur(20px);
  display: grid;
  place-items: center;
  padding: 24px;
}
.mp-fullscreen-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: min(98vw, 1600px);
  max-height: 96vh;
  width: 100%;
  height: 100%;
}
.mp-fullscreen-stage .mp-shell {
  max-width: min(98vw, 1600px);
  max-height: 96vh;
  background: transparent;
  width: auto;
  height: auto;
}
.mp-fullscreen-stage .mp-video,
.mp-fullscreen-stage .mp-image {
  max-height: 96vh;
  max-width: min(98vw, 1600px);
  width: auto;
  height: auto;
  object-fit: contain;
}
.mp-fullscreen-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: var(--bg-1);
  color: var(--ink);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 180ms cubic-bezier(0.22, 1, 0.36, 1);
}
.mp-fullscreen-close:hover { background: var(--bg-2); }

/* Mobile: lose the 24px frame, let media use the full viewport.
   For videos the expand-button calls requestFullscreen() and the native
   player takes over (no custom modal involved). This block mostly
   targets the image modal. */
@media (max-width: 720px) {
  .mp-fullscreen { padding: 0; }
  .mp-fullscreen-stage {
    max-width: 100vw;
    max-height: 100dvh;
    width: 100vw;
    height: 100dvh;
  }
  .mp-fullscreen-stage .mp-shell {
    max-width: 100vw;
    max-height: 100dvh;
    width: 100vw;
    height: auto;
    border-radius: 0;
  }
  .mp-fullscreen-stage .mp-video,
  .mp-fullscreen-stage .mp-image {
    width: 100vw;
    max-width: 100vw;
    max-height: 100dvh;
    height: auto;
    object-fit: contain;
  }
  .mp-fullscreen-close {
    top: 14px;
    right: 14px;
    width: 40px;
    height: 40px;
    background: rgb(17 17 17 / 0.82);
    backdrop-filter: blur(8px);
  }
}
.mp-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mp-row-progress { gap: 12px; }
.mp-row-bottom { justify-content: space-between; gap: 16px; }

.mp-group {
  display: flex;
  align-items: center;
  gap: 6px;
}
.mp-time {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  min-width: 32px;
}

.mp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  border-radius: 999px;
  cursor: pointer;
  transition: background 180ms cubic-bezier(0.22, 1, 0.36, 1);
}
.mp-btn:hover { background: rgb(17 17 17 / 0.82); }

.mp-speeds { gap: 4px; }
.mp-speed {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  padding: 0 9px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11.5px;
  border-radius: 999px;
  cursor: pointer;
  letter-spacing: 0;
  transition: background 180ms cubic-bezier(0.22, 1, 0.36, 1), color 180ms;
}
.mp-speed:hover { background: rgb(17 17 17 / 0.82); }
.mp-speed.is-active {
  background: rgb(17 17 17 / 0.82);
  color: var(--vio-2);
}

.mp-slider {
  position: relative;
  width: 100%;
  height: 4px;
  background: rgb(255 255 255 / 0.18);
  border-radius: 999px;
  cursor: pointer;
}
.mp-slider-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: var(--ink);
  border-radius: 999px;
}
.mp-progress { flex: 1; }
.mp-vol-slider { width: 80px; }

@media (max-width: 540px) {
  .mp-row-bottom { flex-wrap: wrap; }
  .mp-vol-slider { width: 60px; }
  .mp-speeds { gap: 2px; }
  .mp-speed { padding: 0 7px; font-size: 11px; }
}

/* Long inline-code strings (curl URLs, slug-qualified commands) must wrap
   at arbitrary characters or they blow out the container on narrow
   viewports. Pre-formatted code blocks keep their own scroll behaviour. */

/* (legacy `.lib-lightbox` block removed — examples now use MediaPlayer's
   own fullscreen overlay so there's a single modal grammar across the
   site.) */

/* Detail page — Body block (reuses .blog-body, just trims top spacing) */

.lib-body { margin-top: 8px; }

/* ── Skills marketplace ───────────────────────────────────────── */

.skill-filter.is-active { background: var(--ink); color: var(--bg); }

/* ── Skill detail ─────────────────────────────────────────────── */

/* One visual block: file tree + content pane. Only the content pane scrolls. */

.skill-tree-file.is-active { background: var(--vio); color: var(--bg); }

.skill-tree-file.is-active .skill-tree-icon { opacity: 1; }

.skill-doc {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg-1);
  border-radius: 10px;
  overflow: hidden;
}

/* Page (non-modal) detail: the block gets a bounded height so content scrolls. */

/* Wraps the explorer block + the footer action bar. */

/* Footer action bar (matches the reference: closes off the content block). */

/* Scrollbar styling is the one genuinely CSS-only bit (pseudo-elements).
   Applied via the `skill-scroll` class on the tree + doc panes. */
.skill-scroll { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.skill-scroll::-webkit-scrollbar { width: 10px; }
.skill-scroll::-webkit-scrollbar-track { background: transparent; }
.skill-scroll::-webkit-scrollbar-thumb {
  background: var(--line-2);
  border-radius: 999px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
.skill-scroll::-webkit-scrollbar-thumb:hover { background: var(--line-3); background-clip: padding-box; }

/* ── Skill detail modal (intercepted route) ───────────────────── */

@keyframes skill-modal-fade { from { opacity: 0; } to { opacity: 1; } }

@keyframes skill-modal-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Modal variant: column with fixed header + flex content block; only the
   content pane inside .skill-doc scrolls. */

/* ── Skill-doc typography (denser than blog articles) ─────────── */
.skill-doc .lib-body { font-size: 13.5px; line-height: 1.6; color: var(--ink-2); }
.skill-doc .lib-body h1,
.skill-doc .lib-body h2,
.skill-doc .lib-body h3,
.skill-doc .lib-body h4 {
  text-transform: none;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.skill-doc .lib-body h1 { font-size: 1.35rem; margin: 0.2rem 0 0.7rem; line-height: 1.15; }
.skill-doc .lib-body h2 { font-size: 1.05rem; margin: 1.4rem 0 0.5rem; line-height: 1.2; }
.skill-doc .lib-body h3 { font-size: 0.94rem; margin: 1.1rem 0 0.4rem; }
.skill-doc .lib-body h4 { font-size: 0.86rem; margin: 0.9rem 0 0.35rem; }
.skill-doc .lib-body p { margin: 0 0 0.7rem; }
.skill-doc .lib-body ul, .skill-doc .lib-body ol { margin: 0 0 0.8rem; padding-left: 1.2rem; }
.skill-doc .lib-body li { margin: 0 0 0.35rem; line-height: 1.55; }
.skill-doc .lib-body :not(pre) > code { font-size: 0.8em; padding: 0.1em 0.35em; }
.skill-doc .lib-body pre { font-size: 12px; line-height: 1.5; padding: 0.85rem 1rem; border-radius: 8px; }
.skill-doc .lib-body table { font-size: 12.5px; }
.skill-doc .lib-body th, .skill-doc .lib-body td { padding: 6px 10px; }
.skill-doc .lib-body h2:first-child,
.skill-doc .lib-body h1:first-child { margin-top: 0; }

@media (max-width: 760px) {
  .skill-explorer { grid-template-columns: 1fr; }
  .skill-tree { position: static; }
  .skill-search { min-width: 0; flex: 1; }
  .skill-modal-scroll { padding: 1.4rem 1.1rem 1.6rem; }
}

/* ── Sticker-pack checkerboard backing (library detail, issue 060) ──────────── */
/* Transparent die-cut sticker PNGs need a neutral checker so the alpha reads.
   Uses bg-tint steps only — no visible borders. */
.sticker-checker {
  background-color: var(--color-bg-2);
  background-image:
    linear-gradient(45deg, var(--color-bg-1) 25%, transparent 25%),
    linear-gradient(-45deg, var(--color-bg-1) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--color-bg-1) 75%),
    linear-gradient(-45deg, transparent 75%, var(--color-bg-1) 75%);
  background-size: 16px 16px;
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
}
