/* ============================================================
   furnizsh — shared stylesheet
   https://github.com/Wosmos/furnizsh

   Direction: "dark, warm, furnished". Terminals are dark, so the
   site is dark — but this is a well-appointed room, not a neon
   sign. There is deliberately no glow anywhere: the setup itself
   removed both the bloom and CRT shaders in favour of sharp text,
   so a glowing site would be advertising something the product
   doesn't do.

   The only bright thing on any page is the fish.
   ============================================================ */

/* ------------------------------------------------------------
   Tokens

   Dark-first: the bare :root block carries the complete dark
   palette, and light is the override. Every colour is defined
   here and nowhere else, so no rule can depend on a token that
   only exists inside a media query.
   ------------------------------------------------------------ */
:root {
  /* warm near-black rather than the blue-black of a terminal theme */
  --ground:     #0F0E13;
  --surface:    #17161D;
  --surface-2:  #1F1D26;
  --surface-3:  #282631;
  --line:       #2C2A35;
  --line-soft:  #201E28;

  --ink:        #E8E5EE;
  --ink-dim:    #A6A1B4;
  --ink-faint:  #8A8594;

  --teal:       #94E2D5;
  --mauve:      #CBA6F7;
  --peach:      #FAB387;
  --green:      #A6E3A1;
  --blue:       #89B4FA;
  --yellow:     #F9E2AF;

  --accent:     var(--teal);
  --accent-ink: #0B1E1A;

  --shadow:     0 24px 48px -28px rgba(0,0,0,.75);
  --shadow-sm:  0 8px 20px -14px rgba(0,0,0,.6);

  --mono: "JetBrains Mono", "JetBrainsMono Nerd Font Mono", ui-monospace,
          SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;

  --measure: 68ch;
  --wide:    1120px;
  --r-sm: 8px;
  --r:    14px;
  --r-lg: 20px;

  --fs-xs:   .75rem;
  --fs-sm:   .8438rem;
  --fs-base: 1rem;
  --fs-lg:   1.125rem;
  --fs-xl:   1.375rem;
  --fs-2xl:  1.75rem;
  --fs-3xl:  2.25rem;
  --fs-hero: clamp(3rem, 11vw, 6.25rem);

  /* Which theme-switch slot the thumb sits in. JS overrides it per switch;
     0 is Auto, which is also the state before JS runs. */
  --theme-i: 0;

  /* Palette of the theme preview currently being drawn. Each .tabpanel sets
     its own; these are the neon values, so a panel that somehow lost its
     inline palette still renders as a real theme rather than unstyled. */
  --t-bg:     #080A0C;
  --t-fg:     #D6E4E5;
  --t-dim:    #5C7275;
  --t-accent: #00F5D4;
  --t-green:  #A6E3A1;
  --t-blue:   #61D0FF;
  --t-yellow: #F9E2AF;
  --t-red:    #FF6B81;

  /* per-element reveal delay; JS overrides it inline to stagger a group */
  --d: 0ms;
}

/* Light: a warm paper ground rather than a cold white. Accents darken
   and desaturate so every one clears 4.5:1 — verified, not guessed. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --ground:     #F7F5F3;
    --surface:    #FFFFFF;
    --surface-2:  #F0EDEA;
    --surface-3:  #E7E3DF;
    --line:       #DBD6D1;
    --line-soft:  #EAE6E2;

    --ink:        #1B1920;
    --ink-dim:    #55505F;
    --ink-faint:  #6E6879;

    --teal:       #0F7C6D;
    --mauve:      #7A3FBE;
    --peach:      #9C5216;
    --green:      #33702F;
    --blue:       #2A5FC7;
    --yellow:     #7A5D00;

    --accent-ink: #FFFFFF;
    --shadow:     0 20px 44px -30px rgba(40,32,28,.45);
    --shadow-sm:  0 8px 18px -14px rgba(40,32,28,.35);
  }
}

:root[data-theme="light"] {
  --ground:     #F7F5F3;
  --surface:    #FFFFFF;
  --surface-2:  #F0EDEA;
  --surface-3:  #E7E3DF;
  --line:       #DBD6D1;
  --line-soft:  #EAE6E2;

  --ink:        #1B1920;
  --ink-dim:    #55505F;
  --ink-faint:  #6E6879;

  --teal:       #0F7C6D;
  --mauve:      #7A3FBE;
  --peach:      #9C5216;
  --green:      #33702F;
  --blue:       #2A5FC7;
  --yellow:     #7A5D00;

  --accent-ink: #FFFFFF;
  --shadow:     0 20px 44px -30px rgba(40,32,28,.45);
  --shadow-sm:  0 8px 18px -14px rgba(40,32,28,.35);
}

/* ------------------------------------------------------------
   base
   ------------------------------------------------------------ */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--fs-base);
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

code, kbd, pre { font-family: var(--mono); }
code { font-size: .92em; color: var(--peach); }

img { max-width: 100%; height: auto; }

.wrap { width: min(100% - 2.5rem, var(--wide)); margin-inline: auto; }
.prose { max-width: var(--measure); }

h1, h2, h3, h4 { font-family: var(--mono); text-wrap: balance; margin: 0; letter-spacing: -.02em; }
p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

.eyebrow {
  font-family: var(--mono);
  font-size: var(--fs-xs);
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 .75rem;
}
.lede { font-size: var(--fs-lg); color: var(--ink-dim); }
.muted { color: var(--ink-dim); }

/* ------------------------------------------------------------
   top bar
   ------------------------------------------------------------ */
.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: color-mix(in srgb, var(--ground) 86%, transparent);
  border-bottom: 1px solid var(--line-soft);
}
.topbar-inner { display: flex; align-items: center; gap: 1.25rem; padding-block: .7rem; }

.brand {
  display: flex; align-items: center; gap: .55rem;
  font-family: var(--mono); font-weight: 800; font-size: 1.05rem;
  letter-spacing: -.045em; color: var(--ink); text-decoration: none; white-space: nowrap;
}
.brand img { width: 26px; height: 26px; }

.topnav { display: flex; gap: 1.15rem; margin-left: auto; }
.topnav a {
  font-family: var(--mono); font-size: var(--fs-sm);
  color: var(--ink-dim); text-decoration: none;
}
.topnav a:hover { color: var(--ink); }
.topnav a[aria-current="page"] { color: var(--accent); }

.theme-switch {
  position: relative;
  display: flex; padding: 2px; flex: none;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px;
}
/* One thumb that slides, rather than a background jumping between buttons.
   No gap between buttons, so each is exactly a third and translateX(100%)
   lands the thumb precisely on the next one. */
.theme-thumb {
  position: absolute; z-index: 0;
  top: 2px; bottom: 2px; left: 2px;
  width: calc((100% - 4px) / 3);
  border-radius: 999px;
  background: var(--accent);
  transform: translateX(calc(var(--theme-i, 0) * 100%));
  transition: transform .3s cubic-bezier(.4, 0, .2, 1);
}
@media (prefers-reduced-motion: reduce) { .theme-thumb { transition: none; } }
.theme-switch button {
  position: relative; z-index: 1;
  flex: 1 1 0; min-width: 4.1rem;
  font-family: var(--mono); font-size: var(--fs-xs);
  padding: .3rem .62rem; border: 0; border-radius: 999px;
  background: transparent; color: var(--ink-faint); cursor: pointer; line-height: 1.4;
  transition: color .2s;
}
.theme-switch button:hover { color: var(--ink); }
.theme-switch button[aria-pressed="true"] { color: var(--accent-ink); font-weight: 600; }

/* ------------------------------------------------------------
   sections
   ------------------------------------------------------------ */
section { padding-block: clamp(3rem, 7vw, 5.5rem); }
section + section { border-top: 1px solid var(--line-soft); }

.section-head { margin-bottom: 2rem; max-width: var(--measure); }
.section-head h1,
.section-head h2 {
  font-size: var(--fs-2xl); font-weight: 700;
  display: flex; align-items: baseline; gap: .55rem;
}
.section-head h1::before,
.section-head h2::before { content: "❯"; color: var(--accent); font-size: .75em; flex: none; }
.section-head p { margin-top: .6rem; }

/* ------------------------------------------------------------
   hero
   ------------------------------------------------------------ */
.hero { padding-block: clamp(2.5rem, 7vw, 4.5rem) clamp(2.5rem, 6vw, 4rem); }
.hero-grid {
  display: grid; grid-template-columns: minmax(0,1fr) minmax(0,420px);
  gap: clamp(1.5rem, 5vw, 4rem); align-items: center;
}
.hero h1 {
  font-size: var(--fs-hero); font-weight: 800;
  letter-spacing: -.055em; line-height: .95; margin-bottom: .5rem;
}
.hero .tagline {
  font-family: var(--mono); font-size: clamp(1rem, 2.4vw, 1.35rem);
  color: var(--ink-dim); margin-bottom: 2rem;
}
.hero .blurb { max-width: 46ch; color: var(--ink-dim); margin-bottom: 1.75rem; }
.hero-art { justify-self: center; }
.hero-art img { width: min(100%, 400px); filter: drop-shadow(var(--shadow)); }

.badges { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: 1.5rem; }
.badge {
  font-family: var(--mono); font-size: var(--fs-xs);
  padding: .28rem .62rem; border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-dim); background: var(--surface);
}
.badge b { font-weight: 600; color: var(--green); }
.badge.warn b { color: var(--peach); }

/* ------------------------------------------------------------
   terminal block
   ------------------------------------------------------------ */
.term {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow);
}
.term-bar {
  display: flex; align-items: center; gap: .4rem;
  padding: .6rem .8rem; background: var(--surface-2);
  border-bottom: 1px solid var(--line);
}
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.dot.r { background: #E06C6C; } .dot.y { background: #D9A441; } .dot.g { background: #4FA96B; }
.term-title { margin-left: auto; font-family: var(--mono); font-size: var(--fs-xs); color: var(--ink-faint); }
.term-body {
  padding: 1rem 1.05rem 1.15rem;
  font-family: var(--mono); font-size: var(--fs-sm); line-height: 1.9; overflow-x: auto;
}
.term-body .line { display: flex; gap: .5rem; align-items: flex-start; }
.term-body .p { color: var(--accent); flex: none; }
.term-body .cmd { color: var(--ink); word-break: break-all; }
.term-body .out { color: var(--ink-faint); padding-left: 1.2rem; }
.term-body .ok { color: var(--green); }
.term-actions { display: flex; gap: .45rem; padding: 0 1.05rem 1.05rem; flex-wrap: wrap; }

/* ------------------------------------------------------------
   Install terminal — every command is its own click target, so
   there is no separate Copy button to keep in sync with it.
   ------------------------------------------------------------ */
.install-term .term-body { padding: 1.1rem .6rem 1.25rem; line-height: 1.75; }

/* Comments carry what the cards used to say. */
.install-term .c {
  color: var(--ink-faint);
  margin: 1.4rem 0 .35rem; padding: 0 .45rem;
  font-size: var(--fs-sm); line-height: 1.6;
}
.install-term .c:first-child { margin-top: 0; }

.cmdline {
  display: flex; align-items: center; gap: .55rem;
  width: 100%; margin: 0; padding: .3rem .45rem;
  border: 0; border-radius: 8px;
  background: transparent; color: inherit;
  font: inherit; text-align: left; cursor: pointer;
  transition: background .15s;
}
.cmdline:hover,
.cmdline:focus-visible { background: var(--surface-2); }
.cmdline .p   { color: var(--accent); flex: none; }
.cmdline .cmd { color: var(--ink); word-break: break-all; }

/* The icon holds its slot at all times so rows never reflow on hover. */
.copy-slot {
  flex: none; margin-left: auto; display: grid; place-items: center;
  width: 1.6rem; height: 1.6rem; color: var(--ink-faint);
  opacity: 0; transition: opacity .15s, color .15s;
}
.cmdline:hover .copy-slot,
.cmdline:focus-visible .copy-slot { opacity: 1; }
.copy-slot svg { width: 15px; height: 15px; grid-area: 1 / 1; }
.copy-slot .done-ico { opacity: 0; color: var(--green); }

.cmdline[data-copied] .copy-slot { opacity: 1; }
.cmdline[data-copied] .copy-ico  { opacity: 0; }
.cmdline[data-copied] .done-ico  { opacity: 1; }

/* Touch has no hover, so the affordance has to be permanent there. */
@media (hover: none) {
  .copy-slot { opacity: .55; }
}


/* ------------------------------------------------------------
   buttons
   ------------------------------------------------------------ */
.btn {
  font-family: var(--mono); font-size: var(--fs-sm);
  padding: .5rem .9rem; border-radius: var(--r-sm);
  border: 1px solid var(--line); background: var(--surface-2); color: var(--ink);
  cursor: pointer; text-decoration: none; display: inline-block;
  transition: border-color .15s, color .15s, background .15s;
}
.btn:hover { border-color: var(--accent); color: var(--accent); }
.btn.primary {
  background: var(--accent); color: var(--accent-ink);
  border-color: var(--accent); font-weight: 600;
}
.btn.primary:hover { filter: brightness(1.08); color: var(--accent-ink); }
.btn[data-copied="1"] { color: var(--green); border-color: var(--green); }
.cta-row { display: flex; flex-wrap: wrap; gap: .55rem; margin-top: 1.5rem; }

/* ------------------------------------------------------------
   cards / grid
   ------------------------------------------------------------ */
.grid {
  display: grid; gap: 1px; background: var(--line-soft);
  border: 1px solid var(--line-soft); border-radius: var(--r); overflow: hidden;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.grid.three { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { background: var(--ground); padding: 1.4rem 1.45rem; }
.card h3 { font-size: var(--fs-base); font-weight: 700; margin-bottom: .45rem; }
.card p { font-size: var(--fs-sm); color: var(--ink-dim); }
.card .mark {
  font-family: var(--mono); font-size: var(--fs-xs);
  color: var(--accent); display: block; margin-bottom: .6rem; letter-spacing: .04em;
}
.card .big {
  font-family: var(--mono); font-size: 2.1rem; font-weight: 800;
  letter-spacing: -.04em; color: var(--accent); line-height: 1; margin-bottom: .3rem;
}

/* ------------------------------------------------------------
   palette chips — collected objects, not emitted light
   ------------------------------------------------------------ */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.chip {
  width: 46px; height: 46px; border-radius: 10px;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(0,0,0,.25);
}
.chip-row { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; }

/* prompt preview, drawn in CSS so it needs no special font */
.prompt-demo {
  display: flex; align-items: stretch; flex-wrap: wrap;
  font-family: var(--mono); font-size: var(--fs-xs);
  border-radius: 8px; overflow: hidden; margin-top: 1rem;
}
.seg { padding: .35rem .75rem; color: #11111B; font-weight: 600; white-space: nowrap; }
.seg.tail { background: var(--surface-3); color: var(--ink-dim); font-weight: 400; flex: 1; min-width: 4rem; }

/* ------------------------------------------------------------
   tables
   ------------------------------------------------------------ */
.table-scroll {
  overflow-x: auto; margin-top: 1.5rem;
  border: 1px solid var(--line); border-radius: var(--r); background: var(--surface);
}
table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); min-width: 560px; }
th, td { text-align: left; padding: .72rem .95rem; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
th {
  font-family: var(--mono); font-size: var(--fs-xs); letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-faint); font-weight: 500;
  background: var(--surface-2); border-bottom-color: var(--line);
}
tbody tr:last-child td { border-bottom: none; }
td.k { font-family: var(--mono); color: var(--accent); white-space: nowrap; }
td.was { font-family: var(--mono); color: var(--ink-faint); white-space: nowrap; text-decoration: line-through; }
.yes { color: var(--green); font-family: var(--mono); }

/* ------------------------------------------------------------
   FAQ
   ------------------------------------------------------------ */
.faq { margin-top: 1.5rem; max-width: var(--measure); }
.faq details {
  border-bottom: 1px solid var(--line-soft); padding: .3rem 0;
}
.faq summary {
  cursor: pointer; padding: .9rem 0; font-weight: 600;
  font-family: var(--mono); font-size: var(--fs-sm); list-style: none;
  display: flex; align-items: baseline; gap: .6rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "+"; color: var(--accent); font-weight: 700; flex: none; }
.faq details[open] summary::before { content: "−"; }
.faq details p { font-size: var(--fs-sm); color: var(--ink-dim); padding: 0 0 1rem 1.35rem; }

.note {
  font-size: var(--fs-sm); color: var(--ink-dim);
  border-left: 2px solid var(--peach); padding-left: 1rem;
  margin-top: 1.5rem; max-width: var(--measure);
}

/* ------------------------------------------------------------
   footer
   ------------------------------------------------------------ */
footer {
  border-top: 1px solid var(--line-soft);
  padding-block: 2.75rem 3.5rem; font-size: var(--fs-sm); color: var(--ink-dim);
}
.footer-grid { display: flex; flex-wrap: wrap; gap: 2rem; justify-content: space-between; align-items: start; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.1rem; }
.footer-links a { color: var(--ink-dim); text-decoration: none; font-family: var(--mono); font-size: var(--fs-sm); }
.footer-links a:hover { color: var(--accent); }
.credits { font-size: var(--fs-xs); color: var(--ink-faint); margin-top: 1.6rem; max-width: 62ch; line-height: 1.7; }

.made-by { font-size: var(--fs-xs); color: var(--ink-faint); margin-top: .75rem; }
.made-by a { display: inline-flex; align-items: center; gap: .4em; color: inherit; text-decoration: none; }
.made-by a:hover { color: var(--ink-dim); }
.footer-wordmark { height: 12px; width: auto; opacity: .7; transition: opacity .15s; }
.made-by a:hover .footer-wordmark { opacity: 1; }

/* the wordmark svg is fixed white-fill (built for dark backgrounds), so
   light mode needs it flipped rather than left invisible */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .footer-wordmark { filter: invert(1); }
}
:root[data-theme="light"] .footer-wordmark { filter: invert(1); }

/* ------------------------------------------------------------
   scroll reveal — elements are only hidden once JS can reveal
   them, so the page reads fully without JavaScript
   ------------------------------------------------------------ */
.reveal {
  opacity: 0; transform: translateY(14px);
  transition: opacity .5s cubic-bezier(.22,.61,.36,1), transform .5s cubic-bezier(.22,.61,.36,1);
  transition-delay: var(--d, 0ms);
}
.reveal.shown { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 940px) {
  .hero-grid { grid-template-columns: minmax(0,1fr); }
  .hero-art { order: -1; }
  .hero-art img { width: min(70%, 280px); }
  .topnav { display: none; }
}
@media (max-width: 560px) {
  section { padding-block: 2.75rem; }
  .term-body { font-size: var(--fs-xs); }
  .theme-switch button { padding: .3rem .5rem; }
}


/* ------------------------------------------------------------
   The stack, scrolling. A band under the hero that carries the
   tool list without spending hero space on it.
   ------------------------------------------------------------ */
.marquee {
  position: relative;
  overflow: hidden;
  margin: 0 0 4rem;
  padding: 1rem 0;
  border-block: 1px solid var(--line);
  background: var(--surface);
  /* Fade both ends so items enter and leave rather than being cut off. */
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track { display: flex; width: max-content; }
.marquee-run {
  display: flex; align-items: center; gap: 1.5rem;
  padding-right: 1.5rem;
  font-family: var(--mono);
  font-size: var(--fs-sm);
  color: var(--ink-dim);
  white-space: nowrap;
}
.marquee-run i { color: var(--accent); font-style: normal; opacity: .55; }

/* Each run is exactly half the track, so -50% lands on a seam. */
@media (prefers-reduced-motion: no-preference) {
  .marquee-track { animation: marquee 38s linear infinite; }
  .marquee:hover .marquee-track { animation-play-state: paused; }
}
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}


.footer-brand { font-size: 1.2rem; }
.footer-note  { margin: .5rem 0 0; color: var(--ink-faint); font-size: var(--fs-sm); }

/* ------------------------------------------------------------
   A faint grain over the whole page. Inline SVG turbulence, so
   it costs no request and stays inside the CSP. Deliberately
   near-invisible - it should read as paper, not as an effect.
   ------------------------------------------------------------ */
body::before {
  content: ""; position: fixed; inset: 0; z-index: 0;
  pointer-events: none;
  opacity: .022;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
:root:not([data-theme="dark"]) body::before { opacity: .03; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body::before { opacity: .022; }
}
:root[data-theme="dark"] body::before { opacity: .022; }
/* Everything real sits above the grain. */
body > * { position: relative; z-index: 1; }


/* ------------------------------------------------------------
   Theme tabs — one full terminal per theme instead of four
   cramped columns. Each panel sets its own palette as --t-*
   tokens, so the preview is genuinely in that theme rather
   than approximating it with a few swatches.
   ------------------------------------------------------------ */
.theme-tabs { margin-top: 1.5rem; }

.tablist {
  display: flex; flex-wrap: wrap; gap: .4rem;
  margin-bottom: 1.1rem;
}
.tab {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .5rem .85rem;
  font-family: var(--mono); font-size: var(--fs-sm);
  color: var(--ink-dim); cursor: pointer;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 999px;
  transition: color .15s, border-color .15s, background .15s;
}
.tab:hover { color: var(--ink); }
.tab .swatch {
  width: .7rem; height: .7rem; border-radius: 3px; flex: none;
  box-shadow: 0 0 0 1px rgb(0 0 0 / .25) inset;
}
.tab[aria-selected="true"] {
  color: var(--ink); background: var(--surface-2); border-color: var(--ink-faint);
}
.tab-tag {
  font-size: var(--fs-xs); color: var(--accent);
  border: 1px solid var(--line); border-radius: 999px; padding: 0 .38rem;
}

.tabpanel[hidden] { display: none; }

/* ---- the preview itself ---- */
.theme-shot {
  border: 1px solid var(--line); border-radius: var(--r);
  overflow: hidden; box-shadow: var(--shadow);
  background: var(--t-bg);
}
.shot-bar {
  display: flex; align-items: center; gap: .4rem;
  padding: .6rem .8rem;
  background: color-mix(in srgb, var(--t-bg) 80%, #fff 8%);
  border-bottom: 1px solid color-mix(in srgb, var(--t-bg) 60%, #fff 12%);
}
.shot-title {
  margin-left: auto; font-family: var(--mono); font-size: var(--fs-xs);
  color: var(--t-dim);
}
.shot-body {
  padding: 1rem 1.1rem 1.2rem;
  font-family: var(--mono); font-size: var(--fs-sm); line-height: 1.85;
  color: var(--t-fg); overflow-x: auto;
}
.shot-body .ps1 { display: flex; margin-top: .55rem; }
.shot-body .ps1:first-child { margin-top: 0; }
.shot-body .seg {
  padding: .05rem .6rem; font-size: var(--fs-xs); font-weight: 600;
  white-space: nowrap;
}
.shot-body .seg:first-child { border-radius: 4px 0 0 4px; }
.shot-body .seg:last-child  { border-radius: 0 4px 4px 0; }

.shot-body .row { display: flex; gap: .55rem; white-space: nowrap; }
.shot-body .ps  { color: var(--t-accent); }
.shot-body .in  { color: var(--t-fg); }
.shot-body .out { color: var(--t-dim); padding-left: 0; }
.shot-body .d   { color: var(--t-blue); }
.shot-body .f   { color: var(--t-fg); }
.shot-body .br  { color: var(--t-dim); }
.shot-body .mod { color: var(--t-yellow); }
.shot-body .add { color: var(--t-green); }
.shot-body .cur {
  width: .55em; background: var(--t-accent); display: inline-block;
}
@media (prefers-reduced-motion: no-preference) {
  .shot-body .cur { animation: blink 1.15s steps(1) infinite; }
}
@keyframes blink { 0%, 49% { opacity: 1 } 50%, 100% { opacity: 0 } }

.theme-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem;
  margin-top: 1.1rem;
}
.theme-meta .chips { margin: 0; }
.theme-ids  { margin: 0; font-family: var(--mono); font-size: var(--fs-sm); }
.theme-blurb { margin: 0; color: var(--ink-dim); flex: 1 1 22ch; min-width: 22ch; }
