/* GENERATED by apps/web/scripts/bundle-page-css.mjs — do not edit.
 * Source: apps/web/public/styles/pages/home-page.css
 * Flattened from 27 @import'd files into one render-blocking request. */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@100..900&family=Newsreader:ital,wght@0,200..800;1,200..800&display=swap");

:root {
  /* Default to LIGHT (the product default for everyone). This is what the very
     first paint uses before the theme boot script runs, so there is no
     flash-of-OS-theme on load — critical on mobile, where the OS is often dark.
     The toggle narrows/overrides via [data-theme] below: an explicit "system"
     choice restores "light dark" so light-dark() tracks the OS live. */
  color-scheme: light;

  --font-fallback: "Inter", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-primary: var(--font-inter, var(--font-fallback));
  --font-secondary: var(--font-newsreader, var(--font-fallback));
  --font-code: "SF Mono", "SFMono-Regular", Consolas, "Liberation Mono", Menlo,
    Courier, monospace;

  /* ============================================================
     SEMANTIC COLOR TOKENS
     Every themeable color is light-dark(<light>, <dark>). The browser
     resolves it from the element's used color-scheme (inherited from :root),
     so a single token definition serves both themes. Migrate raw hex / rgba
     onto these — never hard-code a themeable color in a leaf file again.
     Dark values are ChatGPT-anchored and WCAG-AA verified (see
     docs/adr/dark-mode-and-token-system-2026-06.md).
     ============================================================ */

  /* Surfaces — page ground up through overlays. Light mode: off-white page,
     white cards sit close to it. Dark mode uses a DIFFERENT philosophy: a TRUE
     BLACK page with components lifted as distinct greys, so cards clearly float
     (depth reads via the lightness ladder since shadows vanish on black). */
  --surface: light-dark(#faf9f6, #000000);
  --surface-raised: light-dark(#ffffff, #1a1a1c);
  --surface-sunken: light-dark(#f8f8f8, #0d0d0f);
  --surface-overlay: light-dark(#ffffff, #242426);
  /* Sent-message (user) chat bubble: a soft grey that floats off the page in
     both themes (charcoal on the black page, warm light-grey on the off-white
     page) — instead of a hard white/ink block. Text uses --ink for contrast. */
  --chat-bubble-user: light-dark(#eeece8, #2c2c2e);
  --surface-scrim: light-dark(rgba(0, 0, 0, 0.42), rgba(0, 0, 0, 0.62));
  /* Frosted dialog/dock backdrop — a LIGHT blur over the page in light mode,
     a dark dim in dark mode (used with backdrop-filter). Distinct from the pure
     dark scrim above. */
  --surface-backdrop: light-dark(rgba(248, 248, 247, 0.72), rgba(18, 18, 20, 0.6));

  /* Ink — text ladder. MUST be solid (or alpha-on-black in light only); the
     dark values are solid greys, never low-alpha white, so contrast is
     deterministic over any surface. */
  --ink: light-dark(#111111, #ececec);
  --ink-muted: light-dark(rgba(0, 0, 0, 0.56), #b4b4b4);
  --ink-faint: light-dark(rgba(0, 0, 0, 0.4), #8e8e93);
  --ink-inverse: light-dark(#ffffff, #1c1c1e);

  /* Lines / borders. Dark values are intentionally higher-alpha than a literal
     10% hairline: on the true-black ground a 6–10% white line is nearly
     invisible (table rules, tab underlines, list dividers), so they're bumped
     for legibility. */
  --line: light-dark(#efece6, rgba(255, 255, 255, 0.15));
  --line-strong: light-dark(#d9d9d9, rgba(255, 255, 255, 0.24));
  --line-faint: light-dark(#e8e5df, rgba(255, 255, 255, 0.1));

  /* Accent — the real app accent (#1d4ed8), lightened in dark for AA. */
  --accent: light-dark(#1d4ed8, #4d9fff);
  --accent-hover: light-dark(#1640b8, #6cb2ff);
  --accent-ink: light-dark(#ffffff, #0a1220);
  /* Accent tint fill + line — the faint blue "current/running/highlighted"
     callouts (rgba(36,128,237,.045-.07) fills, rgba(29,78,216,.16-.22) borders). */
  --accent-tint: light-dark(rgba(36, 128, 237, 0.07), rgba(77, 159, 255, 0.16));
  --accent-line: light-dark(rgba(29, 78, 216, 0.2), rgba(77, 159, 255, 0.34));
  /* Info / queued — indigo status, distinct from the link accent. */
  --info: light-dark(#4f46e5, #8b87f0);

  /* State — success / danger / warning. Each: base + tint fill + line. */
  --success: light-dark(#65c466, #3fcf5f);
  --success-tint: light-dark(rgba(101, 196, 102, 0.13), rgba(63, 207, 95, 0.16));
  --success-line: light-dark(rgba(101, 196, 102, 0.45), rgba(63, 207, 95, 0.42));
  --danger: light-dark(#ea3223, #ff6257);
  --danger-hover: light-dark(#d42c20, #ff7a70);
  --danger-tint: light-dark(rgba(234, 50, 35, 0.07), rgba(255, 98, 87, 0.14));
  --danger-line: light-dark(rgba(234, 50, 35, 0.22), rgba(255, 98, 87, 0.34));
  --warning: light-dark(#b45309, #f5b942);
  --warning-tint: light-dark(rgba(180, 83, 9, 0.1), rgba(245, 185, 66, 0.14));
  --warning-line: light-dark(rgba(180, 83, 9, 0.3), rgba(245, 185, 66, 0.34));
  /* Text/icon on a SOLID --warning fill (white in light; dark in dark, since the
     dark warning is a light amber). */
  --warning-ink: light-dark(#ffffff, #2a1500);

  /* Interaction overlays — black wash in light, white wash in dark. light-dark()
     does the black->white flip for free; consumers just use the token. */
  --hover-bg: light-dark(rgba(0, 0, 0, 0.04), rgba(255, 255, 255, 0.055));
  --active-bg: light-dark(rgba(0, 0, 0, 0.07), rgba(255, 255, 255, 0.09));
  --selected-bg: light-dark(rgba(29, 78, 216, 0.08), rgba(77, 159, 255, 0.16));

  /* Focus + selection */
  --focus-ring: light-dark(rgba(0, 122, 255, 0.5), rgba(108, 178, 255, 0.6));
  --selection-bg: light-dark(#e8e5df, rgba(77, 159, 255, 0.3));
  --selection-color: light-dark(#111111, #ffffff);

  /* Elevation — geometry is constant; only the shadow color flips per theme.
     Dark shadows are much heavier (a soft black shadow is invisible on dark). */
  --shadow-color-weak: light-dark(rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.45));
  --shadow-color: light-dark(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.55));
  --shadow-color-strong: light-dark(rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.7));
  --shadow-sm: 0 1px 2px var(--shadow-color-weak);
  --shadow-md: 0 12px 32px var(--shadow-color);
  --shadow-lg: 0 24px 64px -18px var(--shadow-color-strong),
    0 2px 8px var(--shadow-color-weak);

  /* ---- Back-compat aliases: old token names → new semantic tokens. Keeps
     existing consumers working (and themed) during/after the leaf migration.
     Light values are preserved exactly; only the alias target changed. ---- */
  --body-color: var(--ink);
  --heading-color: var(--ink);
  --body-bg: var(--surface);
  --muted: light-dark(rgba(0, 0, 0, 0.4), #b4b4b4);
  --link-color: var(--accent);
  --soft-line: var(--line-faint);
  --focus-color: var(--focus-ring);
  --success-color: var(--success);
  --danger-color: var(--danger);
  --danger-color-hover: var(--danger-hover);
  --danger-soft-tint: var(--danger-tint);
  --danger-soft-line: var(--danger-line);

  /* Warm-surface pilot RETIRED into the neutral cool scale (one system, themes
     to dark for free). These four are kept as permanent neutral aliases so the
     ~40 var(--warm-*) consumers stay terse and themed — do NOT reintroduce warm
     values here. New code should prefer the canonical --surface-*/--line/--ink. */
  --warm-surface: var(--surface);
  --warm-panel: var(--surface-raised);
  --warm-line: var(--line);
  --warm-ink: var(--ink);

  --researcher-page-width: 64rem;

  /* Motion language (shared so surfaces don't re-derive easings/durations).
     --ease-drawer is the iOS/Vaul "settle" curve; --ease-out-soft is a
     standard decelerate used for entrances and micro-interactions. */
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-out-soft: cubic-bezier(0, 0, 0.2, 1);
  --dur-panel: 320ms;
  --dur-drawer: 360ms;
  --dur-sheet: 380ms;
  --dur-entrance: 300ms;
  --dur-micro: 150ms;
  --stagger-step: 50ms;
}

/* Theme override: the toggle sets data-theme on <html>; that narrows
   color-scheme to a single scheme, which flips every light-dark() token.
   "system" (or no attribute) leaves both schemes active = follow the OS. */
:root[data-theme="light"] {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
}

:root[data-theme="system"] {
  color-scheme: light dark;
}

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 180ms;
  animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
  mix-blend-mode: normal;
}

::view-transition-old(root) {
  animation-name: researcher-page-out;
}

::view-transition-new(root) {
  animation-name: researcher-page-in;
}

::view-transition-old(researcher-chat-composer),
::view-transition-new(researcher-chat-composer) {
  animation-duration: 210ms;
  animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
}

@keyframes researcher-page-out {
  from {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    opacity: 0;
    transform: translate3d(0, -0.25rem, 0) scale(0.998);
  }
}

@keyframes researcher-page-in {
  from {
    opacity: 0;
    transform: translate3d(0, 0.45rem, 0) scale(0.998);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

* {
  box-sizing: border-box;
}

html {
  background: var(--body-bg);
  color: var(--body-color);
  scroll-behavior: smooth;
  scroll-padding-top: 5.25rem;
  overflow-anchor: none;
}

html,
html body {
  min-height: 100%;
}

body {
  margin: 0;
  overflow-y: scroll;
  background: var(--body-bg);
  color: var(--body-color);
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.25rem;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  text-size-adjust: none;
  backface-visibility: hidden;
}

[hidden] {
  display: none !important;
}

main {
  width: 100%;
  margin: 0 auto;
  padding: 5rem 1rem 2.5rem;
}

@media screen and (max-width: 768px) {
  main {
    padding: 2rem 1.5rem 2.5rem;
  }
}

article {
  max-width: none;
}

.site-nav {
  display: grid;
  grid-template-columns: auto 1fr repeat(4, auto);
  align-items: center;
  gap: 0.875rem;
  /* Clear the iOS notch on pages that opt into edge-to-edge (viewport-fit=cover,
     e.g. the entity/job chat surfaces). Resolves to 0 everywhere else, so this
     is a no-op on pages without viewport-fit=cover. */
  padding-top: env(safe-area-inset-top);
  padding-bottom: 2.5rem;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 460;
  line-height: 1.25rem;
  letter-spacing: -0.0025rem;
}

/* Account avatar dropdown — bundles the create actions (New run, New topic),
   Pricing, Docs, a collapsible theme chooser, and Log out. The container is the
   grid cell; the menu is absolutely positioned beneath the avatar. */
.site-nav-account {
  position: relative;
}

.site-nav-account-login {
  border: 0;
  background: none;
  padding: 0;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.15s ease;
}

.site-nav-account-login:hover {
  color: var(--ink);
}

.site-nav-account-menu {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  z-index: 40;
  min-width: 15rem;
  display: flex;
  flex-direction: column;
  padding: 0.375rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.625rem;
  background: var(--warm-panel);
  box-shadow:
    0 0.5rem 1.5rem var(--shadow-color),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
}

.site-nav-account-menu[hidden] {
  display: none;
}

.site-nav-account-menu-item {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 0.4375rem 0.625rem;
  border: 0;
  border-radius: 0.4375rem;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.8125rem;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition:
    color 0.12s ease,
    background-color 0.12s ease;
}

.site-nav-account-menu-item:hover {
  color: var(--ink);
  background: var(--hover-bg);
}

.site-nav-account-trigger:focus-visible,
.site-nav-account-menu-item:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}

/* Coarse pointers (touch) — keep the tappable rows at the ~44px minimum. */
@media (pointer: coarse) {
  .site-nav-account-menu-item {
    min-height: 2.75rem;
    display: flex;
    align-items: center;
  }
}

.site-nav-account-menu-divider {
  height: 1px;
  margin: 0.3125rem 0.375rem;
  background: var(--soft-line);
}

.site-nav-account-menu-logout {
  color: var(--danger);
}

.site-nav-account-menu-logout:hover {
  color: var(--danger);
  background: var(--danger-tint);
}

/* Create group — the primary "New run" / "New topic" actions at the top of the
   menu. Emphasized (ink, not muted) so they read as the main reason to open it. */
.site-nav-account-menu-group {
  display: flex;
  flex-direction: column;
}

.site-nav-account-menu-create {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink);
  font-weight: 500;
}

.site-nav-account-menu-icon {
  display: inline-grid;
  place-items: center;
  width: 1rem;
  height: 1rem;
  color: var(--ink-muted);
  transition: color 0.12s ease;
}

.site-nav-account-menu-icon svg {
  width: 0.875rem;
  height: 0.875rem;
}

.site-nav-account-menu-create:hover .site-nav-account-menu-icon {
  color: var(--ink);
}

/* Theme chooser as a collapsible secondary row, not an always-open block. */
.site-nav-account-theme {
  display: flex;
  flex-direction: column;
}

.site-nav-account-theme-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-nav-account-theme-icon,
.site-nav-account-theme-chevron {
  display: inline-grid;
  place-items: center;
  color: currentColor;
}

.site-nav-account-theme-icon {
  width: 1rem;
  height: 1rem;
}

.site-nav-account-theme-icon svg {
  width: 1rem;
  height: 1rem;
}

.site-nav-account-theme-value {
  margin-left: auto;
  font-size: 0.75rem;
  opacity: 0.65;
}

.site-nav-account-theme-chevron {
  width: 0.875rem;
  height: 0.875rem;
  opacity: 0.65;
  transition: transform 0.15s ease;
}

.site-nav-account-theme-chevron svg {
  width: 0.875rem;
  height: 0.875rem;
}

.site-nav-account-theme.is-open .site-nav-account-theme-chevron {
  transform: rotate(180deg);
}

.site-nav-account-theme-panel {
  padding-top: 0.125rem;
  /* Entrance paired with the chevron rotation so the reveal feels deliberate
     rather than a snap while the chevron animates. */
  animation: site-nav-theme-panel-in 0.15s ease;
}

.site-nav-account-theme-panel[hidden] {
  display: none;
}

@keyframes site-nav-theme-panel-in {
  from {
    opacity: 0;
    transform: translateY(-0.25rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Respect reduced-motion: no chevron spin, item transitions, or panel reveal. */
@media (prefers-reduced-motion: reduce) {
  .site-nav-account-menu-item,
  .site-nav-account-menu-icon,
  .site-nav-account-trigger,
  .site-nav-account-theme-chevron {
    transition: none;
  }

  .site-nav-account-theme.is-open .site-nav-account-theme-chevron {
    transform: none;
  }

  .site-nav-account-theme-panel {
    animation: none;
  }
}

.legal-page main {
  width: min(100%, 42rem);
}

/*
 * Menu sheet — shared mobile bottom-sheet behavior for popup menus.
 *
 * Desktop keeps each menu's own anchored-popover styling; at the mobile
 * breakpoint the same element re-renders as a bottom sheet: pinned to the
 * viewport bottom with a rounded top, grab handle, scrim backdrop, and a
 * slide-up entrance.
 *
 * Contract (see shared/menu-sheet.js for the JS side):
 *   1. Add `menu-sheet` to the popup element, alongside its own classes.
 *   2. While open, render a sibling `menu-sheet-backdrop` element that
 *      dismisses the menu on click.
 *   3. While open, set `menu-sheet-open` on <body> (scroll lock; only has
 *      effect under the sheet breakpoint).
 *
 * Consumers: site-nav account menu (shared/site-nav-account.js),
 * FilterDropdown (shared/filter-dropdown.js), RunActionsMenu
 * (account/usage-row.js).
 *
 * The 680px breakpoint matches the existing mobile-sheet precedent (the job
 * sources drawer in styles/job/source-dialog/source-refs.css) and the
 * runs-table mobile swap. Sheet selectors are doubled (.menu-sheet.menu-sheet)
 * on purpose: this file ships early in every page bundle (via base.css), so
 * the sheet must out-specify each menu's own skin rules (e.g. .rfilter-menu's
 * anchored positioning) that appear later in the bundle.
 */

.menu-sheet-backdrop {
  display: none;
}

@media (max-width: 680px) {
  .menu-sheet-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    /* One below the sheet; the pair sits at the same layer as the other
       mobile sheet (job sources drawer overlay, z-index 130), above the
       site-nav menu layer (40). */
    z-index: 130;
    border: 0;
    margin: 0;
    padding: 0;
    background: var(--surface-scrim);
    /* Same duration as the sheet's slide so the pair reads as one motion. */
    animation: menu-sheet-backdrop-in 0.25s ease;
  }

  .menu-sheet.menu-sheet {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 131;
    width: auto;
    min-width: 0;
    max-width: none;
    max-height: 80dvh;
    overflow-y: auto;
    /* Keep edge scrolls inside the sheet — without this, iOS chains the
       scroll into the page behind the scrim and rubber-bands it. */
    overscroll-behavior: contain;
    margin: 0;
    /* Bottom padding clears the home indicator; the handle provides its own
       top spacing. */
    padding: 0.5rem 0.625rem calc(0.625rem + env(safe-area-inset-bottom));
    border: 0;
    border-top: 1px solid var(--line);
    border-radius: 1rem 1rem 0 0;
    background: var(--warm-panel);
    box-shadow: 0 -0.5rem 2rem var(--shadow-color);
    animation: menu-sheet-in 0.25s cubic-bezier(0.32, 0.72, 0, 1);
  }

  .menu-sheet.menu-sheet[hidden] {
    display: none;
  }

  /* Grab handle — sticky (not absolute) so it stays pinned to the top of the
     sheet when a tall menu scrolls. In-flow, so it works whether the menu is
     a flex column, a grid, or a plain list. */
  .menu-sheet.menu-sheet::before {
    content: "";
    position: sticky;
    top: 0;
    display: block;
    flex: none;
    width: 2.25rem;
    height: 0.25rem;
    margin: 0 auto 0.625rem;
    border-radius: 999px;
    background: var(--line-strong, var(--line));
  }

  /* Rows read as a touch list inside a sheet: comfortable height plus a bit
     more inset and type than the desktop popover rows. */
  .menu-sheet.menu-sheet .site-nav-account-menu-item,
  .menu-sheet.menu-sheet .rfilter-item,
  .menu-sheet.menu-sheet .account-row-menu-item {
    display: flex;
    align-items: center;
    min-height: 2.75rem;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
    font-size: 0.9375rem;
  }

  body.menu-sheet-open {
    overflow: hidden;
  }
}

@keyframes menu-sheet-in {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes menu-sheet-backdrop-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .menu-sheet.menu-sheet,
  .menu-sheet-backdrop {
    animation: none;
  }
}

/* Theme chooser — a System / Light / Dark segmented control that lives inside
   the account dropdown menu (rendered by shared/site-nav-account.js, built by
   shared/theme.js). Styled entirely from semantic tokens so it themes itself.
   Revealed by the collapsible "Theme" row in the account menu. */

.theme-control {
  display: flex;
  flex-direction: column;
  gap: 0.0625rem;
}

.theme-control-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  box-sizing: border-box;
  padding: 0.4375rem 0.5625rem;
  border: 0;
  border-radius: 0.4375rem;
  background: none;
  color: var(--ink-muted);
  font: inherit;
  font-size: 0.8125rem;
  line-height: 1.1;
  text-align: left;
  cursor: pointer;
  transition:
    color 0.12s ease,
    background-color 0.12s ease;
}

.theme-control-option:hover {
  color: var(--ink);
  background: var(--hover-bg);
}

.theme-control-option:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: -1px;
}

@media (prefers-reduced-motion: reduce) {
  .theme-control-option {
    transition: none;
  }
}

.theme-control-option.is-active {
  color: var(--ink);
  background: var(--selected-bg);
}

.theme-control-icon {
  display: inline-grid;
  place-items: center;
  width: 1rem;
  height: 1rem;
  color: currentColor;
}

.theme-control-icon svg {
  width: 1rem;
  height: 1rem;
}

.theme-control-label {
  margin-right: auto;
}

.theme-control-option.is-active::after {
  content: "";
  width: 0.875rem;
  height: 0.875rem;
  margin-left: 0.5rem;
  background: currentColor;
  -webkit-mask: var(--theme-check) center / contain no-repeat;
  mask: var(--theme-check) center / contain no-repeat;
}

:root {
  --theme-check: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2.4" stroke-linecap="round" stroke-linejoin="round"><path d="M5 12.5l4.5 4.5L19 7"/></svg>');
}

.brand-link {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  width: 1.5rem;
  height: 1.5rem;
}

.site-nav a {
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.site-nav-account.has-avatar {
  display: inline-flex;
  align-items: center;
}

.site-nav-account-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
  transition: color 0.15s ease;
}

.site-nav-account-trigger:hover,
.site-nav-account[data-open="true"] .site-nav-account-trigger {
  color: var(--ink);
}

.site-nav-balance {
  font-variant-numeric: tabular-nums;
  font-weight: 480;
}

.site-nav-avatar {
  display: inline-grid;
  place-items: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--ink-inverse);
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1;
  text-transform: uppercase;
}

.brand-mark {
  width: 1.25rem;
  height: 1.25rem;
  display: block;
  border-radius: 999px;
}

.brand-footer {
  padding: 1rem 0 0;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted);
  letter-spacing: 0.01em;
}

.brand-footer a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
  font-weight: 450;
  display: inline-flex;
  align-items: center;
  gap: 0.25em;
}

.brand-footer a:hover {
  color: var(--heading-color);
}

.brand-footer-logo {
  display: inline-block;
  width: 0.875em;
  height: 0.875em;
  flex-shrink: 0;
  opacity: 0.5;
  transition: opacity 0.2s ease;
}

.brand-footer a:hover .brand-footer-logo {
  opacity: 0.7;
}

blockquote,
dd,
dl,
dt,
fieldset,
figure,
h1,
h2,
h3,
h4,
h5,
h6,
hr,
html,
iframe,
legend,
li,
ol,
p,
pre,
textarea,
ul {
  margin: 0;
  padding: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--heading-color);
  position: relative;
  display: flex;
  text-wrap: balance;
  -webkit-text-stroke: 0.001px transparent;
  font-weight: 400;
  line-height: normal;
  letter-spacing: 0;
}

h1 {
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.00813rem;
}

h2,
h3 {
  font-size: 0.875rem;
  font-weight: 560;
  letter-spacing: -0.00563rem;
}

h3 {
  font-weight: 500;
}

p,
li,
dl {
  font-size: 0.875rem;
  font-weight: 460;
  line-height: 1.25rem;
  letter-spacing: -0.00563rem;
}

p strong,
li strong,
dl strong {
  font-weight: 600;
}

time {
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 460;
  line-height: 1.25rem;
  letter-spacing: -0.00563rem;
}

a {
  color: inherit;
  text-decoration: none;
}

.basic-link,
.nav a {
  position: relative;
  display: inline;
  color: inherit;
  font-weight: inherit;
  line-height: inherit;
  transition: all 0.2s ease;
}

.basic-link::before,
.nav a::before {
  pointer-events: none;
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  border-radius: 2px;
  background: var(--line-strong);
  opacity: 1;
  transition: inherit;
}

.basic-link:hover::before,
.nav a:hover::before {
  background: var(--ink-faint);
}

.basic-link:focus-visible,
.nav a:focus-visible {
  border-radius: 2px;
  padding: 0 2px;
  margin: 0 -2px;
  transition: none;
  outline: 2px solid var(--focus-color);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  padding-top: 1rem;
}

hr {
  border: 0;
  display: block;
  width: 3.125rem;
  height: 1px;
  background: var(--soft-line);
  margin: 2.5rem 0 2rem;
}

.shell {
  width: min(100%, 70ch);
  max-width: none;
  margin-inline: auto;
}

header {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0 0 0.5rem;
}

header h1 {
  color: var(--ink);
  font-weight: 500;
}

header h1,
header time {
  font-size: 0.875rem;
  line-height: 1.25rem;
  letter-spacing: -0.00563rem;
}

.lede {
  color: var(--muted);
}

article > p,
article > p + h1 {
  padding-top: 1rem;
}

article > p + h2 {
  padding-top: 2.25rem;
}

article > p + h3,
article > p + h4,
article > p + h5,
article > p + h6 {
  padding-top: 1rem;
}

article h1 + ol,
article h1 + ul,
article h2 + ol,
article h2 + ul,
article h3 + ol,
article h3 + ul,
article h4 + ol,
article h4 + ul,
article h5 + ol,
article h5 + ul,
article h6 + ol,
article h6 + ul {
  padding-top: 1.5rem;
}

/* Prose-section spacing, for genuine reading content only. `.shell` doubles as
   an app-layout shell (metrics, run, topic pages reuse `<article class="shell">`),
   so their layout `<section>`s — which always carry a class — must NOT inherit
   this prose top-band. Scoping to unclassed sections keeps the spacing where it
   belongs (cli/pricing prose) and stops the phantom gap above tables/grids. */
article > section:not([class]) {
  padding-top: 2.25rem;
}

article > section:not([class]) > p + p {
  padding-top: 0.5rem;
}

/*
 * Single source of truth for the home + signed-in dashboard component styles.
 * styles/home.css is the canonical superset of every home/* leaf; account now
 * has its own slim account-page.css entrypoint.
 */
.harness-diagram {
  display: grid;
  gap: 0.75rem;
}

.home-start-run {
  padding-top: 1rem;
}

.home-auth-pending #home-marketing-shell {
  display: none;
}

.home-auth-pending .site-nav {
  visibility: hidden;
}

.runs-auth-page.home-auth-pending .site-nav {
  visibility: visible;
}

.home-page:not(.home-authenticated) [data-chat-nav] {
  display: none;
}

.home-authenticated #home-marketing-shell {
  display: none;
}

.home-auth-pending main,
.home-authenticated main {
  width: min(100%, var(--researcher-page-width, 64rem));
}

.home-auth-pending article,
.home-authenticated article {
  width: 100%;
  max-width: none;
}

.signed-in-home {
  display: grid;
  gap: 0;
  padding-top: 2.5rem;
}

.signed-in-home-start {
  width: 100%;
}

.signed-in-home-runs {
  padding-top: 2rem;
}

/* Runs | Topics tabs — section-label typography with active/inactive states. */
.signed-in-home-tabs {
  display: flex;
  align-items: baseline;
  gap: 1rem;
}

.signed-in-home-tab {
  appearance: none;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0 0 0.75rem;
  color: var(--muted);
  font: inherit;
  font-size: 0.75rem;
  font-weight: 520;
  letter-spacing: 0;
  line-height: 1rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 160ms ease;
}

.signed-in-home-tab:hover {
  color: var(--ink);
}

.signed-in-home-tab.is-active {
  color: var(--ink);
}

/* Compact new-topic affordance so the heading height matches both tabs. */
.signed-in-home-runs .account-section-heading .account-secondary-link {
  margin-top: -0.25rem;
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
}

/* "Load more runs" — centered footer below the runs table so the dashboard can
   page through the whole history instead of stopping at the first page. */
.home-runs-load-more {
  display: flex;
  justify-content: center;
  padding: 1rem 0 0.5rem;
}

.runs-auth-state {
  display: grid;
  gap: 0.5rem;
  max-width: 32rem;
  padding-top: 2.5rem;
}

.runs-auth-title {
  margin: 0;
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 650;
  line-height: 1.55rem;
  letter-spacing: 0;
}

.runs-auth-detail {
  margin: 0;
  color: var(--muted-text);
  font-size: 0.9375rem;
  line-height: 1.45rem;
}

.runs-auth-action {
  justify-self: start;
  margin-top: 0.5rem;
}

.signed-in-home-start .chat-attachment-list {
  width: 100%;
}

.platform-stats-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
}

.platform-stat {
  display: grid;
  align-content: start;
  gap: 0.1875rem;
  min-width: 0;
  padding: 0.875rem 1rem;
}

.platform-stat + .platform-stat {
  border-left: 1px solid var(--soft-line);
}

.platform-stat-label,
.platform-stat-detail {
  min-width: 0;
  overflow: hidden;
  color: var(--muted-text);
  font-size: 0.75rem;
  line-height: 1rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.platform-stat-value {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  font-size: 1.1875rem;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  line-height: 1.5rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 52rem) {
  .runs-auth-page .site-nav {
    grid-template-columns: auto 1fr auto;
  }

  .runs-auth-page .site-nav span,
  .runs-auth-page .site-nav a[href="/pricing/"],
  .runs-auth-page .site-nav a[href="/api/"],
  .runs-auth-page .site-nav [data-account-nav] {
    display: none;
  }

  .platform-stats-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .platform-stat {
    border-top: 1px solid var(--soft-line);
  }

  .platform-stat:nth-child(-n + 2) {
    border-top: 0;
  }

  .platform-stat:nth-child(odd) {
    border-left: 0;
  }
}

@media (max-width: 34rem) {
  .platform-stats-strip {
    grid-template-columns: 1fr;
  }

  .platform-stat,
  .platform-stat:nth-child(-n + 2) {
    border-top: 1px solid var(--soft-line);
  }

  .platform-stat:first-child {
    border-top: 0;
  }

  .platform-stat + .platform-stat {
    border-left: 0;
  }
}

.chat-composer-shell,
.home-start-composer,
.job-run-chat-composer,
.job-chat-composer {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--warm-panel);
  box-shadow:
    0 0.625rem 1.75rem var(--shadow-color-weak),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    opacity 140ms ease,
    transform 170ms cubic-bezier(0.215, 0.61, 0.355, 1);
}

/* Run/run-analyst chatbars are flat — the border (and focus ring) carry them;
   the floating drop shadow reads as a regression against the dark ground. The
   home composer (.home-start-composer) keeps its lift. */
.chat-composer-shell,
.job-run-chat-composer,
.job-chat-composer {
  box-shadow: none;
}

.chat-composer-shell:focus-within,
.job-run-chat-composer:focus-within,
.job-chat-composer:focus-within {
  border-color: var(--line-strong);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.home-start-composer:focus-within {
  border-color: var(--line-strong);
  box-shadow:
    inset 0 0 0 1px var(--line-strong),
    0 0.75rem 2rem var(--shadow-color-weak),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
}

/* Persona (entity) chat composer sits flat against the panel — no drop shadow
   (the run/job chat composer keeps its shadow). */
.entity-page .job-chat-composer {
  box-shadow: none;
}
.entity-page .job-chat-composer:focus-within {
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.home-start-composer {
  position: relative;
  overflow: hidden;
  min-height: 2.875rem;
  padding: 0.375rem 0.4375rem 0.375rem 0.75rem;
  view-transition-name: researcher-chat-composer;
  contain: layout;
}

.home-start-composer.has-youtube-intent {
  grid-template-columns: auto minmax(0, 1fr) auto auto auto;
}

.chat-attachment-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  width: min(100%, 56rem);
  margin: 0.5rem auto 0;
}

.chat-attachment-chip {
  appearance: none;
  max-width: 16rem;
  overflow: hidden;
  border: 1px solid var(--soft-line);
  border-radius: 999px;
  background: var(--hover-bg);
  color: var(--ink-muted);
  padding: 0.25rem 0.625rem;
  font: inherit;
  font-size: 0.75rem;
  line-height: 1rem;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.chat-attachment-chip:hover {
  border-color: var(--line-strong);
  background: var(--hover-bg);
  color: var(--ink);
}

.home-start-composer button {
  appearance: none;
  display: inline-grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  padding: 0;
  font: inherit;
}

.home-start-composer > button:first-child {
  width: 1.75rem;
  height: 1.75rem;
  min-width: 1.75rem;
  min-height: 1.75rem;
  border: 0;
  background: var(--hover-bg);
  color: var(--ink-faint);
  font-size: 1.125rem;
  line-height: 1;
  outline: none;
}

.home-start-composer > button:first-child:hover {
  background: var(--active-bg);
  color: var(--ink-muted);
}

.home-start-composer > button:first-child:disabled {
  cursor: progress;
  opacity: 0.8;
}

.home-start-composer input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.875rem;
  line-height: 1.25rem;
  padding: 0.125rem 0;
}

.home-start-composer input:focus {
  outline: 0;
}

.home-start-composer input::placeholder {
  color: var(--ink-faint);
}

.home-start-submit {
  width: 2rem;
  height: 2rem;
  background: var(--ink);
  color: var(--ink-inverse);
  cursor: pointer;
  transition:
    background 140ms ease,
    transform 140ms ease;
}

.home-start-submit:hover {
  background: light-dark(#000000, #ffffff);
  transform: translateY(-0.03125rem);
}

.home-start-submit:disabled {
  background: light-dark(#e9e9e9, #2f2f31);
  color: var(--ink-faint);
  cursor: default;
  transform: none;
}

.home-start-submit.is-busy:disabled {
  background: light-dark(#000000, #ffffff);
  color: var(--ink-inverse);
  cursor: progress;
  opacity: 1;
}

.home-start-submit svg {
  width: 1rem;
  height: 1rem;
}

.home-start-submit-spinner {
  width: 0.875rem;
  height: 0.875rem;
  border: 0.125rem solid color-mix(in srgb, var(--ink-inverse) 34%, transparent);
  border-top-color: var(--ink-inverse);
  border-radius: 999px;
  animation: home-start-spin 700ms linear infinite;
}

.home-start-intent-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3125rem;
  min-height: 1.75rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--hover-bg);
  color: var(--ink-muted);
  padding: 0.125rem 0.5625rem;
  font-size: 0.75rem;
  font-weight: 560;
  line-height: 1;
  white-space: nowrap;
}

.home-start-intent-pill.is-starting {
  border-color: var(--line-strong);
  background: var(--hover-bg);
  color: var(--ink);
}

.home-start-intent-pill svg {
  width: 1rem;
  height: 1rem;
}

.home-start-status-dot {
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: 999px;
  background: var(--ink);
  animation: home-start-pulse 900ms ease-in-out infinite;
}

.home-start-chat-button {
  min-width: 2.75rem;
  min-height: 1.75rem;
  border: 1px solid var(--line) !important;
  background: var(--hover-bg);
  color: var(--ink-muted);
  padding: 0 0.625rem !important;
  font-size: 0.75rem !important;
  font-weight: 560;
  cursor: pointer;
  transition:
    background-color 140ms ease,
    border-color 140ms ease,
    color 140ms ease;
}

.home-start-chat-button:hover,
.home-start-chat-button:focus-visible {
  border-color: var(--line-strong) !important;
  background: var(--hover-bg);
  color: var(--ink);
}

.home-start-composer.is-submitting {
  border-color: var(--line-strong);
  box-shadow:
    0 0.75rem 2rem var(--shadow-color-weak),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
  opacity: 0.92;
  transform: translateY(-0.0625rem);
}

@keyframes home-start-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes home-start-pulse {
  0%,
  100% {
    opacity: 0.28;
    transform: scale(0.82);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-start-status-dot,
  .home-start-submit-spinner {
    animation: none;
  }
}

.home-chat-modal-open,
.home-chat-modal-closing {
  overflow: hidden;
}

.home-chat-modal-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  background: var(--surface-backdrop);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 1rem;
}

.home-chat-modal-layer.is-open {
  animation: job-chat-modal-backdrop-in 180ms cubic-bezier(0.215, 0.61, 0.355, 1) both;
}

.home-chat-modal-layer.is-closing {
  animation: job-chat-modal-backdrop-out 160ms cubic-bezier(0.215, 0.61, 0.355, 1) both;
}

.home-chat-modal {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: min(100%, 64rem);
  height: min(100%, calc(100dvh - 2rem));
  overflow: hidden;
  border: 1px solid var(--soft-line);
  border-radius: 0.75rem;
  background: var(--warm-panel);
  box-shadow:
    0 0.75rem 1.75rem var(--shadow-color-weak),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
}

.home-chat-modal-layer.is-open .home-chat-modal {
  animation: job-chat-modal-panel-in 210ms cubic-bezier(0.215, 0.61, 0.355, 1) both;
  will-change: transform, opacity;
}

.home-chat-modal-layer.is-closing .home-chat-modal {
  animation: job-chat-modal-panel-out 160ms cubic-bezier(0.215, 0.61, 0.355, 1) both;
  will-change: transform, opacity;
}

.home-chat-modal-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  min-height: 3.75rem;
  border-bottom: 1px solid var(--soft-line);
  padding: 0.75rem 0.875rem;
}

.home-chat-modal-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: auto;
  height: auto;
  color: var(--ink);
  font-size: 0.875rem;
  font-weight: 620;
  line-height: 1.25rem;
  text-decoration: none;
}

.home-chat-modal-header h2 {
  margin: 0.0625rem 0 0;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 650;
  line-height: 1.1875rem;
}

.home-chat-modal-close {
  appearance: none;
  display: inline-grid;
  place-items: center;
  width: 1.875rem;
  height: 1.875rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-faint);
  padding: 0;
  cursor: pointer;
}

.home-chat-modal-close:hover,
.home-chat-modal-close:focus-visible {
  background: var(--hover-bg);
  color: var(--ink);
}

.home-chat-modal-close svg {
  width: 1rem;
  height: 1rem;
}

.home-chat-modal-frame-wrap,
.home-chat-modal-frame {
  width: 100%;
  height: 100%;
  min-height: 0;
}

.home-chat-modal-frame {
  display: block;
  border: 0;
  background: var(--warm-panel);
}

.harness-diagram {
  /* The diagram earns more than the 70ch text column: bleed out to its
     natural width and recenter, clamped to the viewport on small screens. */
  width: min(60rem, calc(100vw - 2.5rem));
  position: relative;
  left: 50%;
  transform: translateX(-50%);
}

.harness-svg {
  display: block;
  width: 100%;
  height: auto;
  color: var(--ink-faint);
  overflow: visible;
}

.harness-node rect {
  fill: var(--surface-raised);
  stroke: var(--soft-line);
  stroke-width: 1;
  filter: drop-shadow(0 1px 0 var(--shadow-color-weak));
  transition: stroke 0.2s ease, fill 0.2s ease;
}

.harness-node text {
  fill: var(--ink);
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 560;
  letter-spacing: 0;
}

.harness-node .muted-label {
  fill: var(--ink-faint);
  font-size: 12px;
  font-weight: 460;
}

.harness-output-tray rect {
  fill: var(--surface-sunken);
  stroke: var(--line);
  stroke-width: 1;
}

.harness-secondary-node rect {
  fill: var(--surface-sunken);
  stroke: var(--line);
  filter: none;
}

.harness-secondary-node text {
  fill: var(--ink-muted);
  font-size: 12px;
  font-weight: 520;
}

.harness-link {
  fill: none;
  stroke: currentColor;
  stroke-width: 1;
  marker-end: url("#arrow");
}

.secondary-link {
  stroke-dasharray: 3 4;
  color: var(--line-strong);
}

.harness-pulse {
  fill: var(--ink);
  offset-rotate: 0deg;
}

.pulse-a {
  offset-path: path("M128 70H192");
  animation: harness-flow 2.4s linear infinite;
}

.pulse-b {
  offset-path: path("M324 70H388");
  animation: harness-flow 2.4s linear 0.35s infinite;
}

.pulse-c {
  offset-path: path("M540 70H604");
  animation: harness-flow 2.4s linear 0.7s infinite;
}

.pulse-d {
  offset-path: path("M680 109V192");
  animation: harness-flow 2.4s linear 1.05s infinite;
}

.pulse-e {
  offset-path: path("M604 231H540");
  animation: harness-flow 2.4s linear 1.4s infinite;
}

.pulse-f {
  offset-path: path("M388 231H324");
  animation: harness-flow 2.4s linear 1.75s infinite;
}

.pulse-g {
  offset-path: path("M192 231H128");
  animation: harness-flow 2.4s linear 2.1s infinite;
}

.pulse-loop {
  offset-path: path("M636 192C604 154 544 150 502 112");
  animation: harness-flow 3.2s linear 1.2s infinite;
}

.pulse-recall {
  offset-path: path("M92 314C60 250 110 130 220 109");
  animation: harness-flow 4.8s linear 2.4s infinite;
}

.harness-loop-label {
  fill: var(--ink-faint);
  font-family: var(--font-primary);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.link-loop {
  stroke-dasharray: 3 4;
  color: var(--line-strong);
}

.node-agent rect {
  animation: harness-node 8s ease-in-out infinite;
}

.node-plan rect {
  animation: harness-node 8s ease-in-out 1s infinite;
}

.node-acquire rect {
  animation: harness-node 8s ease-in-out 2s infinite;
}

.node-extract rect {
  animation: harness-node 8s ease-in-out 3s infinite;
}

.node-review rect {
  animation: harness-node 8s ease-in-out 4s infinite;
}

.node-merge rect {
  animation: harness-node 8s ease-in-out 5s infinite;
}

.node-report rect {
  animation: harness-node 8s ease-in-out 6s infinite;
}

.node-run rect {
  animation: harness-node 8s ease-in-out 7s infinite;
}

@keyframes harness-flow {
  0% {
    offset-distance: 0%;
    opacity: 0;
  }

  12% {
    opacity: 0.85;
  }

  88% {
    opacity: 0.85;
  }

  100% {
    offset-distance: 100%;
    opacity: 0;
  }
}

@keyframes harness-node {
  0%,
  100% {
    fill: var(--surface-raised);
    stroke: var(--soft-line);
  }

  45%,
  55% {
    fill: var(--hover-bg);
    stroke: var(--line-strong);
  }
}

.prompt-stack {
  display: grid;
  gap: 0.25rem;
}

.prompt-stack .copy-command {
  margin-top: 0.5rem;
}

dl {
  width: fit-content;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 0.375rem;
  padding-top: 2.25rem;
}

dt {
  color: var(--muted);
  font-weight: 460;
}

dd {
  margin: 0;
  color: var(--ink-muted);
}

pre {
  margin-top: 0.75rem;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
  border-radius: 0.5rem;
  background: var(--surface-sunken);
  color: var(--ink);
  padding: 0.875rem 1rem;
  font-family: var(--font-code);
  font-size: 0.8125rem;
  font-weight: 400;
  line-height: 1.55;
}

.copy-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.75rem;
}

.copy-command {
  appearance: none;
  border: 1px solid var(--soft-line);
  border-radius: 0.375rem;
  background: var(--surface-sunken);
  color: var(--ink);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.75rem;
  padding: 0.625rem 0.875rem;
  text-align: left;
  width: 100%;
  max-height: 2.875rem;
  overflow: hidden;
}

.copy-command code {
  display: block;
  flex: 1;
  padding: 0;
  background: none;
  color: inherit;
  font-family: var(--font-code);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  min-width: 0;
  line-height: 1.2;
  font-size: 0.8125rem;
}

.copy-command code::before {
  display: none;
}

.copy-command:hover {
  border-color: var(--line);
}

.copy-command:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}

.copy-command-icon {
  flex-shrink: 0;
  color: var(--ink-muted);
}

.copy-command[data-copied="true"] .copy-command-icon {
  color: var(--success);
}

.copy-command-copy,
.copy-command-check {
  transform-origin: center;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.copy-command-copy {
  opacity: 1;
  transform: scale(1);
}

.copy-command-check {
  opacity: 0;
  transform: scale(0.8);
}

.copy-command[data-copied="true"] .copy-command-copy {
  opacity: 0;
  transform: scale(0.8);
}

.copy-command[data-copied="true"] .copy-command-check {
  opacity: 1;
  transform: scale(1);
}

.features-grid .feature-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.625rem;
  padding-top: 1rem;
  list-style: none;
}

.features-grid .feature-list li {
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  padding: 0.75rem 0.875rem;
  font-family: var(--font-primary);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.features-grid .feature-list h3 {
  padding: 0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
}

.features-grid .feature-list p {
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--ink-muted);
}

.features-grid .feature-list code {
  font-size: 0.7rem;
}

.example-runs + .features-grid {
  padding-top: 2.75rem;
}

.example-runs {
  padding-top: 2.5rem;
}

@media (max-width: 32rem) {
  .features-grid .feature-list {
    grid-template-columns: minmax(0, 1fr);
  }
}

.example-runs .example-list {
  display: grid;
  gap: 0.5rem;
  padding-top: 1rem;
  list-style: none;
}

.example-runs .example-list li {
  padding: 0;
}

.example-runs .example-list a {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  padding: 0.75rem 0.875rem;
  text-decoration: none;
  color: inherit;
  font-family: var(--font-primary);
  transition: border-color 120ms ease, background 120ms ease;
}

.example-runs .example-list a:hover,
.example-runs .example-list a:focus-visible {
  border-color: var(--line-strong);
  background: var(--hover-bg);
}

.example-runs .example-title {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.3;
}

.example-runs .example-meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.deliverables {
  padding-top: 2.5rem;
}

.deliverables h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
}

.deliverable-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.625rem;
  padding-top: 1rem;
}

.deliverable {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-width: 0;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  padding: 0.875rem 1rem 1rem;
  font-family: var(--font-primary);
}

.deliverable h3 {
  padding: 0.125rem 0 0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
}

.deliverable p {
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--ink-muted);
}

.deliverable-visual {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.4375rem;
  min-height: 6.6875rem;
  border: 1px solid var(--line);
  border-radius: 0.375rem;
  background: var(--surface-sunken);
  padding: 0.625rem 0.6875rem;
}

.deliverable-line {
  display: block;
  width: var(--w, 100%);
  height: 0.25rem;
  border-radius: 999px;
  background: var(--line);
}

.deliverable-line.is-heading {
  width: 52%;
  height: 0.375rem;
  background: var(--ink-faint);
}

.deliverable-row {
  display: flex;
  align-items: center;
  gap: 0.4375rem;
  min-width: 0;
}

.deliverable-row .deliverable-line {
  flex: 0 1 var(--w, 100%);
}

.deliverable-tag {
  flex: 0 0 auto;
  min-width: 2.625rem;
  text-align: center;
  border: 1px solid var(--soft-line);
  border-radius: 0.25rem;
  background: var(--warm-panel);
  padding: 0 0.25rem;
  font-size: 0.5625rem;
  font-weight: 600;
  line-height: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
}

.deliverable-visual-stack {
  position: relative;
  z-index: 0;
  margin: 0 0.375rem 0.375rem 0;
  min-height: 6.3125rem;
  background: var(--warm-panel);
}

.deliverable-visual-stack::before,
.deliverable-visual-stack::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border: 1px solid var(--line);
  border-radius: 0.375rem;
  background: var(--warm-panel);
}

.deliverable-visual-stack::before {
  transform: translate(0.1875rem, 0.1875rem);
}

.deliverable-visual-stack::after {
  transform: translate(0.375rem, 0.375rem);
}

.deliverable-file {
  display: block;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.625rem;
  line-height: 1rem;
  color: var(--ink-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.deliverable-file em {
  font-style: normal;
  color: var(--muted);
}

@media (max-width: 40rem) {
  .deliverable-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .deliverable-visual {
    min-height: 0;
  }
}

.auth-panel {
  display: grid;
  gap: 0.875rem;
}

.auth-panel label {
  display: grid;
  gap: 0.375rem;
  color: var(--ink);
  font-size: 0.8125rem;
  font-weight: 520;
  line-height: 1.25rem;
}

.auth-panel input {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  color: var(--ink);
  padding: 0.625rem 0.75rem;
  font: inherit;
  letter-spacing: 0;
}

.auth-panel button {
  width: fit-content;
  border: 1px solid var(--ink);
  border-radius: 0.5rem;
  background: var(--ink);
  color: var(--ink-inverse);
  padding: 0.5rem 0.75rem;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 560;
  cursor: pointer;
}

.auth-panel button:disabled {
  cursor: default;
  opacity: 0.55;
}

.capability-cards {
  padding-top: 2.5rem;
}

.capability-cards h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
}

.capability-cards .lede {
  padding-top: 0.25rem;
}

.capability-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.625rem;
  padding-top: 0.625rem;
}

.capability-card {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  padding: 0.875rem 1rem 1rem;
  font-family: var(--font-primary);
  min-width: 0;
}

.capability-card-wide {
  margin-top: 1rem;
}

.capability-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  text-align: left;
}

.capability-card-head h3 {
  display: block;
  justify-self: start;
  padding: 0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
}

.capability-card-head .capability-card-meta,
.capability-card-head .status-pill {
  justify-self: end;
}

.capability-card-meta {
  font-size: 0.6875rem;
  color: var(--muted);
  white-space: nowrap;
}

.capability-card > p {
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--ink-muted);
}

/* --- shared demo chrome ------------------------------------------------ */

.capability-demo {
  display: flex;
  flex-direction: column;
  gap: 0.4375rem;
  border: 1px solid var(--line);
  border-radius: 0.4375rem;
  background: var(--surface-sunken);
  padding: 0.625rem 0.6875rem;
  overflow: hidden;
}

.capability-url {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  min-width: 0;
  align-self: flex-start;
  max-width: 100%;
  border: 1px solid var(--soft-line);
  border-radius: 999px;
  background: var(--warm-panel);
  padding: 0.1875rem 0.5625rem 0.1875rem 0.4375rem;
  font-size: 0.6875rem;
  line-height: 1rem;
  color: var(--ink-muted);
}

.capability-url svg {
  flex: 0 0 auto;
  width: 0.8125rem;
  height: 0.8125rem;
}

.capability-url span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* --- article / video extraction rows ----------------------------------- */

.capability-extract {
  display: flex;
  flex-direction: column;
  gap: 0.3125rem;
}

.capability-extract-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.6875rem;
  line-height: 1rem;
  color: var(--ink-muted);
  opacity: 0;
  animation: capability-row-in 9s ease infinite;
}

.capability-extract-row .capability-count {
  flex: 0 0 auto;
  min-width: 1.375rem;
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}

.capability-extract-row .capability-bar {
  flex: 1 1 auto;
  height: 1px;
  border-radius: 999px;
  background: var(--line);
  position: relative;
  overflow: hidden;
}

.capability-extract-row .capability-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--ink);
  transform: scaleX(var(--fill, 0.6));
  transform-origin: left;
}

.capability-extract-row:nth-child(1) { animation-delay: 0.4s; }
.capability-extract-row:nth-child(2) { animation-delay: 1s; }
.capability-extract-row:nth-child(3) { animation-delay: 1.6s; }
.capability-extract-row:nth-child(4) { animation-delay: 2.2s; }

@keyframes capability-row-in {
  0% { opacity: 0; transform: translateY(0.1875rem); }
  6%, 86% { opacity: 1; transform: translateY(0); }
  94%, 100% { opacity: 0; transform: translateY(0); }
}

.capability-quote {
  border-left: 2px solid var(--line-strong);
  padding: 0.0625rem 0 0.0625rem 0.5625rem;
  font-family: var(--font-serif, Newsreader, serif);
  font-size: 0.75rem;
  font-style: italic;
  line-height: 1.4;
  color: var(--ink-muted);
  opacity: 0;
  animation: capability-row-in 9s ease infinite;
  animation-delay: 2.9s;
}

.capability-quote .capability-quote-attribution {
  display: block;
  padding-top: 0.1875rem;
  font-family: var(--font-primary);
  font-size: 0.625rem;
  font-style: normal;
  color: var(--muted);
}

.capability-timestamp {
  display: inline-block;
  border-radius: 0.25rem;
  background: var(--accent-tint);
  color: var(--accent);
  padding: 0 0.25rem;
  font-family: var(--font-primary);
  font-size: 0.625rem;
  font-style: normal;
  font-weight: 600;
  line-height: 0.9375rem;
  font-variant-numeric: tabular-nums;
}

/* --- deep research mock run --------------------------------------------- */

.capability-run-demo {
  gap: 0;
  padding: 0.125rem 0.6875rem 0.5625rem;
}

.capability-run-demo .job-progress {
  padding-top: 0.875rem;
  padding-bottom: 0.75rem;
}

.capability-run-demo .job-progress .job-progress-step-button {
  cursor: default;
}

.capability-run-stats {
  display: flex;
  align-items: baseline;
  gap: 0.375rem;
  font-size: 0.6875rem;
  line-height: 1rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.capability-run-stats strong {
  font-weight: 600;
  color: var(--ink);
}

.capability-run-stats .capability-run-stat-sep {
  color: var(--ink-faint);
}

@media (max-width: 32rem) {
  .capability-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .capability-run-demo .job-progress ol {
    gap: 0.4375rem;
  }

  .capability-run-demo .job-progress li {
    font-size: 0.5625rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .capability-extract-row,
  .capability-quote {
    animation: none;
    opacity: 1;
  }
}

/* Skill cartridges — the Researcher skill as a holographic game cartridge
   you slot into your agent. Replaces the v1 "Prompt your agent" buttons. */

.skill-cartridges {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem 2.5rem;
  padding-top: 1.5rem;
}

.skill-cartridges-head {
  max-width: 24rem;
}

.skill-cartridges h2 {
  padding: 0;
}

.skill-cartridges .lede {
  margin-top: 0.375rem;
}

.cartridge-row {
  display: grid;
  justify-items: center;
  padding: 0.5rem 0 0.25rem;
}

.cartridge {
  appearance: none;
  border: 0;
  padding: 0;
  background: none;
  font: inherit;
  cursor: pointer;
  display: grid;
  gap: 0.75rem;
  justify-items: center;
  min-width: 0;
}

.cartridge:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 4px;
  border-radius: 12px;
}

.cartridge-bay {
  position: relative;
  display: grid;
  justify-items: center;
  width: 100%;
}

/* ---- the cartridge body: hypermetal chrome ---- */

.cartridge-shell {
  position: relative;
  z-index: 2;
  width: 22rem;
  max-width: 100%;
  display: grid;
  gap: 0.625rem;
  padding: 0.75rem 0.75rem 0;
  border-radius: 14px 14px 6px 6px;
  background:
    linear-gradient(
      115deg,
      rgba(255, 184, 216, 0.34),
      rgba(168, 216, 255, 0.34) 28%,
      rgba(170, 255, 205, 0.26) 52%,
      rgba(206, 178, 255, 0.34) 76%,
      rgba(255, 190, 178, 0.34)
    ),
    linear-gradient(180deg, #eef0f4, #a9b0bd 42%, #e6e9ee 58%, #7e8595);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(0, 0, 0, 0.3),
    inset 1px 0 0 rgba(255, 255, 255, 0.45),
    0 0 0 1px rgba(20, 24, 38, 0.1),
    0 12px 28px var(--shadow-color-strong);
  transition: transform 260ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cartridge-grip {
  height: 0.5rem;
  border-radius: 999px;
  background: repeating-linear-gradient(
    90deg,
    rgba(20, 24, 38, 0.22) 0 0.375rem,
    rgba(255, 255, 255, 0) 0.375rem 0.75rem
  );
}

/* ---- holographic label window ---- */

.cartridge-window {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  align-content: center;
  align-items: center;
  column-gap: 0.9rem;
  row-gap: 0.15rem;
  padding: 0.9rem 1rem;
  border-radius: 8px;
  text-align: left;
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.18),
    inset 0 2px 6px rgba(0, 0, 0, 0.22);
}

.cartridge-holo {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      115deg,
      rgba(255, 255, 255, 0.22) 0 2px,
      rgba(255, 255, 255, 0) 2px 7px
    ),
    conic-gradient(
      from 210deg at 50% 120%,
      #ffd6e8,
      #d6ecff 18%,
      #d4ffe3 36%,
      #fff6cf 52%,
      #e8d6ff 70%,
      #ffd9d2 86%,
      #ffd6e8
    );
  filter: saturate(1.2);
}

.cartridge-sheen {
  position: absolute;
  top: -30%;
  bottom: -30%;
  left: -45%;
  width: 45%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.75) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-14deg);
  pointer-events: none;
}

.cartridge-art {
  position: relative;
  grid-row: 1 / 3;
  align-self: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 10px;
  overflow: hidden;
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.85),
    0 3px 10px var(--shadow-color-strong);
}

.cartridge-art img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.cartridge-name {
  position: relative;
  align-self: end;
  color: #141414;
  font-size: 1.0625rem;
  font-weight: 720;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.cartridge-kind {
  position: relative;
  align-self: start;
  color: rgba(0, 0, 0, 0.55);
  font-size: 0.5625rem;
  font-weight: 680;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ---- iridescent chrome connector pins ---- */

.cartridge-pins {
  height: 0.6rem;
  margin: 0 1.25rem;
  border-radius: 2px 2px 0 0;
  background:
    linear-gradient(
      90deg,
      rgba(255, 214, 232, 0.55),
      rgba(214, 236, 255, 0.55) 30%,
      rgba(212, 255, 227, 0.5) 55%,
      rgba(232, 214, 255, 0.55) 80%,
      rgba(255, 217, 210, 0.55)
    ),
    repeating-linear-gradient(
      90deg,
      #f8f9fb 0 0.4rem,
      #b9bec9 0.4rem 0.5rem,
      #6f7480 0.5rem 0.7rem
    );
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

/* ---- the console deck it inserts into ---- */

.cartridge-deck {
  position: relative;
  z-index: 3;
  width: 24.25rem;
  max-width: 100%;
  margin-top: -0.125rem;
  display: grid;
  gap: 0.5rem;
  padding-bottom: 0.6rem;
  border: 1px solid var(--soft-line);
  border-radius: 14px;
  background: linear-gradient(180deg, #ededeb, #fafaf9 55%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 2px 6px var(--shadow-color);
}

.cartridge-slot {
  position: relative;
  height: 1.2rem;
}

.cartridge-slot::before {
  content: "";
  position: absolute;
  left: 1rem;
  right: 1.75rem;
  top: 50%;
  height: 0.3rem;
  transform: translateY(-50%);
  border-radius: 999px;
  background: var(--ink);
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.8);
}

.deck-agents {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
}

.deck-agent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--warm-panel);
  overflow: hidden;
  box-shadow: 0 1px 2px var(--shadow-color-weak);
}

.deck-agent img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.deck-agent svg {
  width: 0.95rem;
  height: 0.95rem;
  display: block;
}

.deck-agent-openai {
  color: var(--ink);
}

.deck-agent-anthropic {
  color: #d97757;
}

.cartridge-slot-led {
  position: absolute;
  right: 0.7rem;
  top: 50%;
  width: 0.3rem;
  height: 0.3rem;
  transform: translateY(-50%);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.16);
  transition: background 200ms ease, box-shadow 200ms ease;
}

/* ---- action line under the cartridge ---- */

.cartridge-action {
  display: grid;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1rem;
  white-space: nowrap;
}

.cartridge-action .copy-label,
.cartridge-action .copied-label {
  grid-area: 1 / 1;
  transition:
    color 180ms ease,
    opacity 180ms ease,
    transform 220ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.cartridge-action .copy-label {
  color: var(--ink-muted);
}

.cartridge-action .copied-label {
  color: var(--success-color);
  opacity: 0;
  transform: translateY(0.25rem);
  pointer-events: none;
}

.cartridge-action .copied-label::before {
  content: "";
  display: inline-block;
  width: 0.4rem;
  height: 0.65rem;
  margin-right: 0.35rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(42deg) translateY(-0.05rem);
}

/* ---- hover: lift, shimmer, sheen sweep ---- */

.cartridge:hover .cartridge-shell,
.cartridge:focus-visible .cartridge-shell {
  transform: translateY(-0.375rem) rotate(-1.2deg);
}

.cartridge:hover .cartridge-holo,
.cartridge:focus-visible .cartridge-holo {
  animation: cartridge-holo-shift 2.8s linear infinite;
}

.cartridge:hover .cartridge-sheen,
.cartridge:focus-visible .cartridge-sheen {
  animation: cartridge-sheen-sweep 1.6s ease-in-out infinite;
}

@keyframes cartridge-holo-shift {
  to {
    filter: saturate(1.2) hue-rotate(360deg);
  }
}

@keyframes cartridge-sheen-sweep {
  0% {
    left: -45%;
  }
  60%,
  100% {
    left: 130%;
  }
}

/* ---- copied: slot the cartridge in, LED goes green ---- */

.cartridge[data-copied="true"] .cartridge-shell {
  transform: translateY(0.55rem);
  transition-timing-function: cubic-bezier(0.32, 0, 0.67, 0);
  transition-duration: 180ms;
}

.cartridge[data-copied="true"] .cartridge-holo {
  animation: cartridge-holo-shift 0.9s linear infinite;
}

.cartridge[data-copied="true"] .cartridge-slot-led {
  background: var(--success-color);
  box-shadow: 0 0 6px 1px var(--success-tint);
}

.cartridge[data-copied="true"] .cartridge-action .copy-label {
  opacity: 0;
  transform: translateY(-0.25rem);
}

.cartridge[data-copied="true"] .cartridge-action .copied-label {
  opacity: 1;
  transform: translateY(0);
}

/* ---- layout + motion preferences ---- */

@media (max-width: 720px) {
  .skill-cartridges {
    grid-template-columns: 1fr;
  }

  .cartridge-shell,
  .cartridge-deck {
    max-width: 18rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cartridge-shell,
  .cartridge-action .copy-label,
  .cartridge-action .copied-label {
    transition: none;
  }

  .cartridge:hover .cartridge-shell,
  .cartridge:focus-visible .cartridge-shell,
  .cartridge[data-copied="true"] .cartridge-shell {
    transform: none;
  }

  .cartridge:hover .cartridge-holo,
  .cartridge:focus-visible .cartridge-holo,
  .cartridge[data-copied="true"] .cartridge-holo,
  .cartridge:hover .cartridge-sheen,
  .cartridge:focus-visible .cartridge-sheen {
    animation: none;
  }
}

/*
 * Signed-in dashboard run filter bar: Researcher-style dropdowns (Source type +
 * Run kind) on the left, a text search on the right — one row. The .rfilter
 * dropdown (apps/web/public/shared/filter-dropdown.js) is a reusable primitive:
 * a pill trigger that goes accent-tinted when a filter is active, plus a popover
 * menu matching the site-nav account menu surface.
 */
.dashboard-runs-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  padding-top: 0.875rem;
}

.dashboard-runs-selects {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* ── Researcher dropdown ───────────────────────────────────────────────── */
.rfilter {
  position: relative;
  display: inline-flex;
}

.rfilter-trigger {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.15rem;
  letter-spacing: -0.00563rem;
  padding: 0.3125rem 0.75rem 0.3125rem 0.875rem;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.rfilter-trigger:hover {
  border-color: var(--ink-faint);
  background: var(--hover-bg);
}

/* Active = a non-"All" value is selected: the reference's accent pill, in
   Researcher blue. */
.rfilter-trigger.is-active {
  color: var(--accent);
  border-color: var(--accent-line);
  background: var(--accent-tint);
  font-weight: 560;
}

.rfilter-trigger:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.rfilter-chevron {
  width: 0.7rem;
  height: 0.7rem;
  flex: none;
  opacity: 0.65;
  transition: transform 160ms ease;
}

.rfilter-trigger[aria-expanded="true"] .rfilter-chevron {
  transform: rotate(180deg);
}

.rfilter-menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  z-index: 40;
  min-width: 100%;
  width: max-content;
  max-width: 16rem;
  margin: 0;
  padding: 0.3125rem;
  list-style: none;
  border: 1px solid var(--soft-line);
  border-radius: 0.625rem;
  background: var(--warm-panel);
  box-shadow:
    0 0.5rem 1.5rem var(--shadow-color),
    0 0.0625rem 0.125rem var(--shadow-color-weak);
}

.rfilter-item {
  display: flex;
  align-items: center;
  gap: 0.4375rem;
  width: 100%;
  box-sizing: border-box;
  padding: 0.4375rem 0.5rem 0.4375rem 0.375rem;
  border: 0;
  border-radius: 0.4375rem;
  background: none;
  color: var(--ink-muted);
  font: inherit;
  font-size: 0.8125rem;
  text-align: left;
  cursor: pointer;
  transition: color 0.12s ease, background-color 0.12s ease;
}

.rfilter-item:hover {
  color: var(--ink);
  background: var(--hover-bg);
}

.rfilter-item.is-selected {
  color: var(--accent);
}

.rfilter-item:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: -2px;
}

/* The check reserves its space so labels stay aligned whether or not selected. */
.rfilter-check {
  width: 0.85rem;
  height: 0.85rem;
  flex: none;
  color: var(--accent);
  opacity: 0;
}

.rfilter-item.is-selected .rfilter-check {
  opacity: 1;
}

.rfilter-item-label {
  flex: 1 1 auto;
}

.rfilter-item-count {
  color: var(--ink-faint);
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
}

.rfilter-item.is-selected .rfilter-item-count {
  color: var(--accent);
  opacity: 0.75;
}

@media (pointer: coarse) {
  .rfilter-item {
    min-height: 2.75rem;
  }
}

/* ── Search ────────────────────────────────────────────────────────────── */
.dashboard-runs-search {
  margin-left: auto;
  flex: 0 1 16rem;
  min-width: 9rem;
}

.dashboard-runs-search-input {
  width: 100%;
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.8125rem;
  line-height: 1.15rem;
  letter-spacing: -0.00563rem;
  padding: 0.3125rem 0.875rem;
  transition: border-color 160ms ease, color 160ms ease;
}

.dashboard-runs-search-input::placeholder {
  color: var(--ink-faint);
}

.dashboard-runs-search-input:hover {
  border-color: var(--line-strong);
}

.dashboard-runs-search-input:focus-visible {
  outline: none;
  border-color: var(--line-strong);
}

/* Breathing room between the bar and the table / empty state below it. */
.dashboard-runs-filter + .research-table-wrapper {
  padding-top: 0.625rem;
}

@media screen and (max-width: 560px) {
  .dashboard-runs-search {
    flex-basis: 100%;
    margin-left: 0;
  }
}

.research-table-wrapper {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  padding-top: 0.875rem;
}

.research-table {
  width: 100%;
  max-width: 100%;
  border-spacing: 0;
  border-collapse: collapse;
  font-size: 0.8125rem;
  table-layout: fixed;
}

.research-table thead tr th {
  padding: 0.375rem 0.75rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-weight: 500;
  line-height: 1.15rem;
  letter-spacing: -0.00563rem;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.research-table thead tr th:first-child {
  padding-left: 0;
}

.research-table thead tr th:last-child {
  padding-right: 0;
}

.research-table tbody {
  color: var(--ink-faint);
}

.research-table tbody tr {
  transition:
    background-color 90ms ease,
    opacity 90ms ease;
}

.research-table tbody tr.is-entering {
  animation: research-row-enter 140ms cubic-bezier(0.215, 0.61, 0.355, 1);
  animation-delay: var(--research-row-enter-delay, 0ms);
  animation-fill-mode: both;
}

@media (hover: hover) and (pointer: fine) {
  .research-table tbody:hover tr {
    opacity: 0.48;
  }

  .research-table tbody tr:hover {
    opacity: 1;
  }
}

.research-table tbody tr.is-clickable {
  cursor: pointer;
}

.research-table tbody tr.is-clickable:active {
  background: var(--hover-bg);
}

.research-table tbody tr td {
  padding: 0.375rem 0.75rem;
  border-bottom: 1px solid var(--line);
  font-weight: 460;
  line-height: 1.15rem;
  letter-spacing: -0.00563rem;
  vertical-align: middle;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 0;
}

.research-table tbody tr td:first-child {
  padding-left: 0;
  color: var(--ink);
}

@keyframes research-row-enter {
  0% {
    opacity: 0;
    transform: translateY(0.2rem);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .research-table tbody tr.is-entering {
    animation: none;
  }
}

.research-table tbody tr td:last-child {
  padding-right: 0;
}

.research-table-empty {
  color: var(--muted);
  white-space: normal;
}

.research-markdown-table-wrapper {
  margin: 0.75rem 0 1rem;
  padding-top: 0;
}

.research-markdown-table {
  table-layout: auto;
}

.research-markdown-table tbody,
.research-markdown-table tbody tr td {
  color: var(--ink);
}

.research-markdown-table-wide {
  table-layout: fixed;
}

.research-markdown-table-wide thead tr th,
.research-markdown-table-wide tbody tr td {
  min-width: 11rem;
}

.research-markdown-table-wide thead tr th:first-child,
.research-markdown-table-wide tbody tr td:first-child {
  min-width: 13rem;
}

.research-markdown-table tbody tr td {
  white-space: normal;
  vertical-align: top;
  overflow-wrap: normal;
  word-break: normal;
  overflow: visible;
  text-overflow: clip;
  max-width: none;
}

.research-markdown-table tbody tr td:first-child {
  width: auto;
}

@media screen and (max-width: 640px) {
  .research-markdown-table-stack.research-markdown-table {
    display: block;
    width: 100%;
    border: 0;
  }

  .research-markdown-table-stack thead {
    display: none;
  }

  .research-markdown-table-stack tbody,
  .research-markdown-table-stack tbody tr {
    display: block;
    width: 100%;
  }

  .research-markdown-table-stack tbody tr {
    padding: 0.875rem 0;
    border-top: 1px solid var(--line);
    border-bottom: 0;
  }

  .research-markdown-table-stack tbody tr:first-child {
    border-top: 0;
    padding-top: 0;
  }

  .research-markdown-table-stack tbody tr:last-child {
    padding-bottom: 0;
  }

  .research-markdown-table-stack tbody tr td {
    display: block;
    padding: 0;
    border-bottom: 0;
    max-width: none;
    width: 100%;
  }

  .research-markdown-table-stack tbody tr td:first-child {
    color: var(--ink);
    font-weight: 560;
    font-size: 0.9375rem;
    line-height: 1.25rem;
    letter-spacing: -0.00813rem;
    margin-bottom: 0.5rem;
    padding: 0;
  }

  .research-markdown-table-stack tbody tr td:not(:first-child) {
    margin-top: 0.625rem;
  }

  .research-markdown-table-stack tbody tr td[data-label]::before {
    content: attr(data-label);
    display: block;
    color: var(--ink-faint);
    font-size: 0.75rem;
    font-weight: 460;
    line-height: 1rem;
    letter-spacing: -0.0025rem;
    margin-bottom: 0.25rem;
  }

  .research-markdown-table-wrapper:has(.research-markdown-table-stack) {
    overflow-x: visible;
    padding-top: 0.5rem;
  }
}

@media screen and (max-width: 680px) {
  .research-table-wrapper {
    padding-top: 0.75rem;
  }
}

.research-table-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
  padding-top: 0.875rem;
}

.research-table-filters[hidden] {
  display: none;
}

.research-table-filter {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-faint);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 480;
  line-height: 1.15rem;
  letter-spacing: -0.00563rem;
  padding: 0.25rem 0.75rem;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.research-table-filter:hover {
  color: var(--ink);
  border-color: var(--line-strong);
}

.research-table-filter.is-active {
  color: var(--ink);
  border-color: var(--line-strong);
  font-weight: 560;
}

.research-table-filter-count {
  color: var(--ink-faint);
  font-size: 0.75rem;
  font-weight: 460;
  font-variant-numeric: tabular-nums;
}

.research-table-filter.is-active .research-table-filter-count {
  color: var(--ink-faint);
}

.research-table-filters + .research-table-wrapper {
  padding-top: 0.625rem;
}

/*
 * Shared column-width + cell rules for the named research-table variants.
 * Moved here from account/styles/usage.css so the table component lives with
 * its base definition and every page that renders these tables (dashboard,
 * account, server-rendered /runs) stays in sync.
 */
.research-table-usage th:nth-child(1),
.research-table-usage td:nth-child(1) {
  width: 43%;
}

.research-table-usage th:nth-child(2),
.research-table-usage td:nth-child(2),
.research-table-usage th:nth-child(3),
.research-table-usage td:nth-child(3) {
  width: 10%;
}

.research-table-usage th:nth-child(4),
.research-table-usage td:nth-child(4) {
  width: 27%;
}

.research-table-usage th:nth-child(5),
.research-table-usage td:nth-child(5) {
  width: 10%;
}

.research-table-topics th:nth-child(1),
.research-table-topics td:nth-child(1) {
  width: 52%;
}

.research-table-topics th:nth-child(2),
.research-table-topics td:nth-child(2),
.research-table-topics th:nth-child(3),
.research-table-topics td:nth-child(3),
.research-table-topics th:nth-child(4),
.research-table-topics td:nth-child(4) {
  width: 16%;
}

.research-table-entities th:nth-child(1),
.research-table-entities td:nth-child(1) {
  width: 52%;
}

.research-table-entities th:nth-child(2),
.research-table-entities td:nth-child(2),
.research-table-entities th:nth-child(3),
.research-table-entities td:nth-child(3),
.research-table-entities th:nth-child(4),
.research-table-entities td:nth-child(4) {
  width: 16%;
}

.home-entity-cell {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-width: 0;
}

.home-entity-avatar {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--surface-sunken);
}

.home-entity-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink-faint);
}

.research-table-usage-admin {
  min-width: 74rem;
}

.research-table-usage-admin th:nth-child(1),
.research-table-usage-admin td:nth-child(1) {
  width: 24%;
}

.research-table-usage-admin th:nth-child(2),
.research-table-usage-admin td:nth-child(2) {
  width: 15%;
}

.research-table-usage-admin th:nth-child(3),
.research-table-usage-admin td:nth-child(3),
.research-table-usage-admin th:nth-child(4),
.research-table-usage-admin td:nth-child(4),
.research-table-usage-admin th:nth-child(5),
.research-table-usage-admin td:nth-child(5),
.research-table-usage-admin th:nth-child(6),
.research-table-usage-admin td:nth-child(6),
.research-table-usage-admin th:nth-child(7),
.research-table-usage-admin td:nth-child(7),
.research-table-usage-admin th:nth-child(8),
.research-table-usage-admin td:nth-child(8),
.research-table-usage-admin th:nth-child(9),
.research-table-usage-admin td:nth-child(9) {
  width: 7%;
}

.research-table-usage-admin th:nth-child(10),
.research-table-usage-admin td:nth-child(10) {
  width: 17%;
}

.research-table-usage tbody tr td {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.research-table-skeleton-row td {
  height: 2.5rem;
}

/*
 * Canonical run/topic status color map.
 *
 * Three class families consume the same logical states (succeeded, running,
 * queued, paused, failed/cancelled, ...). They are kept as separate classes
 * because different JS surfaces emit different prefixes, but their colors are
 * defined together here so they can never drift:
 *
 *   .status-text-*   — inline status text in run/runs tables (research-table)
 *   .account-status-* — account/dashboard status text + topic states
 *
 * The .status-pill / .status-<state> pill variants (background + border + color)
 * live with the pill layout in /styles/job/status-message.css.
 */

/* --- Inline status text (run tables, server-rendered /runs) --- */
.status-text-succeeded {
  color: var(--success-color);
}

.status-text-running {
  color: var(--accent);
  animation: job-running-pill 2.2s ease-in-out infinite;
}

.status-text-queued {
  color: var(--info);
}

.status-text-paused {
  color: var(--warning);
}

.status-text-failed,
.status-text-cancelled,
.status-text-canceled {
  color: var(--danger-color);
}

/* --- Account / dashboard status text + topic lifecycle states --- */
.account-status {
  display: inline-block;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  color: var(--ink-faint);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-status-succeeded {
  color: var(--success);
}

.account-status-running {
  color: var(--accent);
  animation: account-running-status 1.7s ease-in-out infinite;
}

.account-status-queued {
  color: var(--info);
}

.account-status-paused {
  color: var(--warning);
}

.account-status-failed,
.account-status-canceled,
.account-status-cancelled {
  color: var(--danger-color);
}

/* Topic statuses — paused/archived fall through to the muted base color. */
.account-status-active {
  color: var(--success);
}

.account-status-bootstrapping {
  color: var(--accent);
  animation: account-running-status 1.7s ease-in-out infinite;
}

.account-status-bootstrap-failed {
  color: var(--danger-color);
}

@keyframes account-running-status {
  0%,
  100% {
    opacity: 0.62;
  }
  50% {
    opacity: 1;
  }
}

/*
 * Shared research-table column-width + cell rules moved to
 * /styles/tables.css (see "Shared column-width" block). Account-specific
 * styling (usage rows, status colors, action buttons) remains below.
 */

.account-usage-skeleton {
  display: block;
  height: 0.625rem;
  max-width: 100%;
  overflow: hidden;
  border-radius: 0.25rem;
  background: linear-gradient(
    90deg,
    var(--hover-bg) 0%,
    var(--active-bg) 45%,
    var(--hover-bg) 90%
  );
  background-size: 220% 100%;
  animation: account-usage-skeleton 1.2s ease-in-out infinite;
}

.account-usage-skeleton + .account-usage-skeleton {
  margin-top: 0.375rem;
}

.account-usage-skeleton-wide {
  width: min(18rem, 78%);
}

.account-usage-skeleton-short {
  width: min(7rem, 42%);
}

.account-usage-skeleton-price {
  width: 3.75rem;
}

.account-usage-skeleton-actions {
  width: 8.5rem;
}

@keyframes account-usage-skeleton {
  0% {
    background-position: 120% 0;
  }
  100% {
    background-position: -120% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .account-usage-skeleton {
    animation: none;
  }
}

.account-usage-topic-row {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-width: 0;
}

.account-usage-thumbnail {
  width: 3.25rem;
  aspect-ratio: 16 / 9;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 0.25rem;
  background: var(--surface-sunken);
  object-fit: cover;
}

/* Fallback tile when a run has no source image: the title's first letter on a
   subtle surface gradient, so every row stays visually consistent. */
.account-usage-thumbnail-monogram {
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, var(--surface-raised), var(--surface-sunken));
  color: var(--ink-faint);
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1;
  text-transform: uppercase;
  user-select: none;
}

.account-usage-topic,
.account-usage-time {
  display: grid;
  gap: 0.125rem;
  min-width: 0;
}

.account-usage-meta {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}

.account-usage-dot {
  color: var(--ink-faint);
  flex-shrink: 0;
}

.account-usage-title,
.account-usage-status {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
}

/* .account-status / .account-status-* colors live in
 * /styles/components/status.css */

.account-usage-price,
.account-usage-cost {
  min-width: 0;
  color: var(--ink-muted);
  font-variant-numeric: tabular-nums;
}

.account-run-id {
  color: var(--ink-muted);
  font: inherit;
  font-variant-numeric: tabular-nums;
}

.account-run-id-button {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.account-run-id-button:hover,
.account-run-id-button:focus-visible {
  color: var(--ink);
  text-decoration: underline;
}

.account-usage-actions {
  min-width: 0;
  overflow: visible;
  text-overflow: clip;
  text-align: left;
}

.account-usage-actions-inner {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  min-height: 1.5rem;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.account-icon-button {
  display: inline-grid;
  width: 1.5rem;
  height: 1.5rem;
  place-items: center;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-muted);
  font: inherit;
  padding: 0;
  cursor: pointer;
  transition: color 0.15s ease;
}

.account-icon-button:hover {
  color: var(--ink);
}

.account-usage-time {
  justify-items: start;
  color: var(--ink-faint);
}

.research-table-usage .account-secondary-link {
  min-width: 5.75rem;
  justify-content: center;
  padding: 0.375rem 0.625rem;
}

.research-table-usage .account-run-action {
  min-width: 3.75rem;
}

.account-error {
  color: var(--danger-color);
  font-size: 0.8125rem;
  line-height: 1.25rem;
}

.account-continuation-banner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.account-continuation-copy {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
}

.account-continuation-copy p {
  margin: 0;
}

/* ── Per-row ⋮ actions menu ───────────────────────────────────────────────
 * Collapses every row action into one dropdown. Hidden on desktop (the inline
 * icon row is used there); revealed on mobile by the media query below so the
 * runs table can shed its icon column and give the thumbnail + title room. */
.account-row-menu {
  position: relative;
  display: none;
}

.account-row-menu-list {
  position: absolute;
  top: calc(100% + 0.25rem);
  right: 0;
  z-index: 30;
  min-width: 9.5rem;
  display: grid;
  gap: 0.0625rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.625rem;
  background: var(--surface-raised);
  box-shadow: 0 0.5rem 1.5rem var(--shadow-color);
  padding: 0.25rem;
}

.account-row-menu-item {
  appearance: none;
  display: block;
  width: 100%;
  border: 0;
  border-radius: 0.4375rem;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.8125rem;
  line-height: 1.25rem;
  text-align: left;
  white-space: nowrap;
  padding: 0.4375rem 0.625rem;
  cursor: pointer;
}

.account-row-menu-item:hover:not(:disabled),
.account-row-menu-item:focus-visible {
  background: var(--hover-bg);
  outline: none;
}

.account-row-menu-item:disabled {
  color: var(--ink-faint);
  cursor: default;
}

.account-row-menu-item.is-danger {
  color: var(--danger);
}

.account-row-menu-item.is-danger:hover:not(:disabled) {
  background: var(--danger-tint);
}

/* Mobile: trim the dashboard / account runs table to [thumbnail + name] ·
 * Billed · ⋮ — collapse the inline action icons into the ⋮ menu and drop the
 * Budget (col 2) and Age (col 5) columns. Scoped away from the server-rendered
 * /runs card-stack (.runs-page) and the wide admin table. */
@media screen and (max-width: 680px) {
  body.home-page .research-table-usage:not(.research-table-usage-admin) th:nth-child(2),
  body.home-page .research-table-usage:not(.research-table-usage-admin) td:nth-child(2),
  body.home-page .research-table-usage:not(.research-table-usage-admin) th:nth-child(5),
  body.home-page .research-table-usage:not(.research-table-usage-admin) td:nth-child(5) {
    display: none;
  }

  body.home-page .research-table-usage:not(.research-table-usage-admin) th:nth-child(1),
  body.home-page .research-table-usage:not(.research-table-usage-admin) td:nth-child(1) {
    width: auto;
  }

  body.home-page .research-table-usage:not(.research-table-usage-admin) th:nth-child(3),
  body.home-page .research-table-usage:not(.research-table-usage-admin) td:nth-child(3) {
    width: 4rem;
    text-align: right;
  }

  body.home-page .research-table-usage:not(.research-table-usage-admin) th:nth-child(4),
  body.home-page .research-table-usage:not(.research-table-usage-admin) td:nth-child(4) {
    width: 2.5rem;
    text-align: right;
  }

  /* Blank the "Actions" header over the ⋮ column (keeps the column for width). */
  body.home-page .research-table-usage:not(.research-table-usage-admin) thead th:nth-child(4) {
    font-size: 0;
  }

  /* Swap the inline icon row → ⋮ menu. */
  body.home-page .research-table-usage:not(.research-table-usage-admin) .account-usage-actions-inner {
    display: none;
  }

  body.home-page .research-table-usage:not(.research-table-usage-admin) .account-row-menu {
    display: inline-flex;
  }

  /* No overflow-escape hacks needed here: the ⋮ menu renders as a fixed
     bottom sheet on mobile (styles/base/menu-sheet.css), which clipping
     ancestors cannot cut off. */
}

.status-pill {
  appearance: none;
  display: inline-flex;
  position: relative;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  min-width: 4.5rem;
  border: 1px solid var(--soft-line);
  border-radius: 999px;
  background: var(--warm-panel);
  color: var(--ink-muted);
  padding: 0.1875rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1rem;
  letter-spacing: 0;
  text-transform: none;
  cursor: default;
}

.status-pill-has-detail {
  cursor: help;
}

.status-pill-has-detail::after {
  content: attr(data-status-detail);
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  z-index: 10;
  width: min(22rem, calc(100vw - 2rem));
  border: 1px solid var(--soft-line);
  border-radius: 0.625rem;
  background: var(--warm-panel);
  box-shadow: 0 12px 32px var(--shadow-color);
  color: var(--ink);
  padding: 0.625rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 460;
  line-height: 1.25rem;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  white-space: normal;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-0.25rem);
  transition: opacity 120ms ease, transform 120ms ease;
}

.status-pill-has-detail:hover::after,
.status-pill-has-detail:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}

.status-pending,
.status-queued {
  border-color: var(--line);
  background: var(--surface-sunken);
  color: var(--ink-muted);
}

.status-succeeded {
  border-color: var(--success-line);
  background: var(--success-tint);
  color: var(--success-color);
}

.status-warning {
  border-color: var(--warning-line);
  background: var(--warning-tint);
  color: var(--warning);
}

.status-running,
.status-loading,
.status-generating-report {
  border-color: var(--accent-line);
  background: var(--accent-tint);
  color: var(--accent);
}

.status-running,
.status-loading,
.status-generating-report,
.job-progress.is-running li.is-active .job-progress-track {
  will-change: transform, opacity, background-position, box-shadow;
}

.status-running,
.status-loading,
.status-generating-report {
  animation: job-running-pill 2.2s ease-in-out infinite;
}

.status-failed,
.status-auth {
  border-color: var(--danger-line);
  background: var(--danger-tint);
  color: var(--danger-color);
}

.status-cancelled,
.status-paused,
.status-missing {
  border-color: var(--line);
  background: var(--surface-sunken);
  color: var(--ink-muted);
}

.status-awaiting-funding {
  border-color: var(--warning-line);
  background: var(--warning-tint);
  color: var(--warning);
}

.job-message {
  margin-top: 1rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.5rem;
  background: var(--warm-panel);
  color: var(--ink-muted);
  padding: 0.75rem 0.875rem;
  font-size: 0.875rem;
  font-weight: 460;
  line-height: 1.25rem;
  letter-spacing: -0.00563rem;
}

.job-message-warning {
  border-color: var(--warning-line);
  background: var(--warning-tint);
  color: var(--warning);
}

.job-message-error {
  border-color: var(--danger-soft-line);
  background: var(--danger-tint);
  color: var(--danger-color);
}

.job-message-neutral {
  border-color: var(--soft-line);
  background: var(--warm-panel);
  color: var(--ink-muted);
}

.job-funding-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
  border: 1px dashed var(--warning-line);
  border-radius: 0.625rem;
  background: var(--warning-tint);
  color: var(--warning);
  padding: 0.875rem 1rem;
}

.job-funding-panel-lock {
  flex-shrink: 0;
  font-size: 1rem;
  line-height: 1.25rem;
}

.job-funding-panel-copy {
  flex: 1 1 16rem;
  min-width: 0;
}

.job-funding-panel-title {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25rem;
  letter-spacing: -0.00563rem;
}

.job-funding-panel-detail {
  margin: 0.125rem 0 0;
  font-size: 0.8125rem;
  font-weight: 460;
  line-height: 1.25rem;
  color: var(--warning);
}

.job-funding-panel-actions {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 0.5rem;
}

.job-funding-panel-fund {
  appearance: none;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--warning-line);
  border-radius: 999px;
  background: var(--warning);
  color: var(--warning-ink);
  padding: 0.3125rem 0.875rem;
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 560;
  line-height: 1.25rem;
  text-decoration: none;
  cursor: pointer;
}

.job-funding-panel-fund:hover {
  background: color-mix(in srgb, var(--warning) 82%, black);
}

.job-funding-panel-resume {
  appearance: none;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--warning-line);
  border-radius: 999px;
  background: transparent;
  color: var(--warning);
  padding: 0.3125rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 560;
  line-height: 1.25rem;
  cursor: pointer;
}

.job-funding-panel-resume:hover {
  background: var(--warning-tint);
}

.job-funding-panel-resume:disabled {
  opacity: 0.6;
  cursor: default;
}

.job-dialog.job-funding-dialog {
  width: min(24rem, calc(100vw - 2rem));
  box-shadow: 0 1.25rem 4rem var(--shadow-color);
}

.job-funding-dialog-header {
  position: relative;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-bottom: none;
  padding: 1.125rem 1.25rem 0;
}

.job-funding-dialog-header .job-dialog-close {
  position: absolute;
  top: 0.5rem;
  right: 0.625rem;
}

.job-funding-dialog-header h2,
.job-funding-dialog-status,
.job-funding-address-description {
  margin: 0;
}

.job-funding-dialog-header h2 {
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.375rem;
}

.job-funding-dialog-content {
  display: grid;
  gap: 1rem;
  padding: 1rem 1.25rem 1.25rem;
  justify-items: center;
  text-align: center;
}

/* Card on-ramp CTA — the secondary path below the USDC deposit flow (beta,
   US-only, unavailable in New York). */
.job-funding-card-cta {
  display: grid;
  gap: 0.5rem;
  justify-items: center;
  width: 100%;
  max-width: 18rem;
}

.job-funding-card-button {
  width: 100%;
}

.job-funding-card-hint {
  color: var(--ink-muted);
  font-size: 0.75rem;
  line-height: 1.15rem;
  max-width: 17rem;
}

/* "or pay with card" divider between the deposit-address flow and the card CTA. */
.job-funding-or {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  width: 100%;
  max-width: 18rem;
  color: var(--ink-faint);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.job-funding-or::before,
.job-funding-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--soft-line, var(--hairline, rgba(0, 0, 0, 0.1)));
}

.job-funding-dialog-status,
.job-funding-address-description {
  color: var(--ink-muted);
  font-size: 0.8125rem;
  font-weight: 450;
  line-height: 1.25rem;
  max-width: 19rem;
}

.job-funding-dialog-status.is-error {
  color: var(--danger-color);
}

/* Network selector — one pill dropdown replaces the per-chain chip row. */
.job-funding-chain-field {
  position: relative;
  width: 100%;
  max-width: 18rem;
}

.job-funding-chain-select {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  border: 1px solid var(--soft-line);
  border-radius: 0.875rem;
  background: var(--warm-panel);
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 560;
  line-height: 1.25rem;
  padding: 0.75rem 2.5rem 0.75rem 1rem;
  text-align: left;
  cursor: pointer;
}

.job-funding-chain-select:hover {
  border-color: var(--line-strong);
}

.job-funding-chain-select:focus-visible {
  outline: 0;
  border-color: var(--line-strong);
  box-shadow: 0 0 0 3px var(--shadow-color-weak);
}

.job-funding-chain-select:disabled {
  opacity: 0.6;
  cursor: default;
}

.job-funding-chain-chevron {
  position: absolute;
  top: 50%;
  right: 0.9375rem;
  transform: translateY(-50%);
  width: 1rem;
  height: 1rem;
  color: var(--ink-faint);
  pointer-events: none;
}

.job-funding-qr-frame {
  width: 100%;
  max-width: 13.5rem;
  border: 1px solid var(--soft-line);
  border-radius: 1.125rem;
  background: #ffffff;
  padding: 0.875rem;
}

.job-funding-qr-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0.375rem;
}

/* Address chip with an inline copy icon (was a full-width copy button). */
.job-funding-address-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  max-width: 20rem;
  border: 1px solid var(--soft-line);
  border-radius: 0.875rem;
  background: var(--warm-panel);
  padding: 0.5625rem 0.5625rem 0.5625rem 0.875rem;
}

.job-funding-address-row code {
  min-width: 0;
  font-family: var(--font-code);
  font-size: 0.8125rem;
  line-height: 1.25rem;
  color: var(--ink);
  word-break: break-all;
  text-align: left;
}

.job-funding-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  color: var(--ink-faint);
  cursor: pointer;
  padding: 0;
}

.job-funding-copy:hover:not(:disabled) {
  background: var(--hover-bg);
  color: var(--ink);
}

.job-funding-copy.is-copied {
  color: var(--ink);
}

.job-funding-copy:disabled {
  opacity: 0.5;
  cursor: default;
}

.job-funding-copy svg {
  width: 1rem;
  height: 1rem;
}

.job-funding-dialog-actions {
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  gap: 0.5rem;
  margin-top: 0.125rem;
}

.job-funding-dialog .job-dialog-button {
  width: 100%;
  min-height: 2.625rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 560;
}

.job-progress {
  position: relative;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.job-progress.has-active-loop {
  padding-top: 2.125rem;
}

.job-progress ol {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 0.75rem;
}

.job-progress li {
  display: block;
  color: var(--muted);
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 0.9375rem;
  letter-spacing: 0;
}

.job-progress-step-button {
  appearance: none;
  display: grid;
  grid-template-rows: 1px auto;
  gap: 0.4375rem;
  min-width: 0;
  width: 100%;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.job-progress-step-button:focus-visible {
  outline: 0;
}

.job-progress-step-button:focus-visible .job-progress-track {
  box-shadow: 0 0 0 0.1875rem var(--focus-ring);
}

.job-progress-step-button:hover .job-progress-track {
  background: var(--line-strong);
}

.job-progress-track {
  display: block;
  width: 100%;
  height: 1px;
  border-radius: 999px;
  background: var(--line);
  transition: background 160ms ease;
}

.job-progress-label {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  overflow: hidden;
  white-space: nowrap;
}

.job-progress-number {
  display: none;
}

.job-progress-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.job-progress-loop-count {
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--accent-tint);
  color: var(--accent);
  font-size: 0.625rem;
  font-weight: 600;
  line-height: 0.8125rem;
  padding: 0 0.25rem;
}

.job-progress-loop {
  position: absolute;
  top: 0.875rem;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4375rem;
  color: var(--ink-muted);
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 0.9375rem;
}

.job-progress-loop[hidden] {
  display: none;
}

.job-progress-loop-marker {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border-radius: 999px;
  border: 1px solid var(--accent-line);
  background: var(--accent-tint);
  color: var(--accent);
  padding: 0.03125rem 0.3125rem;
  font-size: 0.625rem;
  font-weight: 600;
  line-height: 0.8125rem;
}

.job-progress-loop-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.job-progress-loop-arc {
  position: absolute;
  top: 0.125rem;
  height: 0.625rem;
  color: var(--accent);
  pointer-events: none;
}

.job-progress-loop-arc[hidden] {
  display: none;
}

.job-progress-loop-arc::before {
  content: "";
  position: absolute;
  inset: 0 0 0.1875rem;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  border-left: 1px solid currentColor;
  border-radius: 0.625rem 0.625rem 0 0;
}

.job-progress-loop-arc::after {
  content: "";
  position: absolute;
  left: -0.125rem;
  bottom: 0.03125rem;
  width: 0.25rem;
  height: 0.25rem;
  border-left: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg);
}

.job-progress li.is-active {
  color: var(--accent);
}

.job-progress li.is-active .job-progress-track,
.job-progress li.is-complete .job-progress-track {
  background: var(--ink);
}

.job-progress li.is-loop-origin:not(.is-active) {
  color: var(--accent);
}

.job-progress li.is-loop-target:not(.is-active) {
  color: var(--accent);
}

.job-progress li.is-loop-origin .job-progress-track,
.job-progress li.is-loop-target .job-progress-track {
  background: var(--accent-line);
}

.job-progress.is-running li.is-active .job-progress-track {
  position: relative;
  overflow: hidden;
  background: var(--accent-tint);
}

.job-progress.is-running li.is-active .job-progress-track::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(36, 128, 237, 0.14) 0%,
    rgba(36, 128, 237, 0.48) 22%,
    #1d4ed8 50%,
    rgba(36, 128, 237, 0.48) 78%,
    rgba(36, 128, 237, 0.14) 100%
  );
  background-size: 180% 100%;
  animation: job-running-track 1.2s linear infinite;
}

.job-progress.is-succeeded li {
  color: var(--success);
}

.job-progress.is-succeeded li.is-active {
  color: var(--success-color);
}

.job-progress.is-succeeded li.is-active .job-progress-track,
.job-progress.is-succeeded li.is-complete .job-progress-track {
  background: var(--success-color);
}

.job-progress.is-paused li.is-active {
  color: var(--ink-faint);
}

.job-progress.is-paused li.is-active .job-progress-track {
  background: var(--line-strong);
}

.job-progress.is-failed li.is-active {
  color: var(--danger-color);
}

.job-progress.is-failed li.is-active .job-progress-track {
  background: var(--danger-color);
}

@keyframes job-running-pill {
  0%,
  100% {
    border-color: rgba(36, 128, 237, 0.22);
    background: rgba(36, 128, 237, 0.07);
    box-shadow: 0 0 0 rgba(36, 128, 237, 0);
  }
  50% {
    border-color: rgba(36, 128, 237, 0.32);
    background: rgba(36, 128, 237, 0.12);
    box-shadow: 0 0 0 0.2rem rgba(36, 128, 237, 0.06);
  }
}

@keyframes job-running-track {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .status-running,
  .status-loading,
  .job-page.is-run-loading #job-title::after,
  .job-value-loading::after,
  .job-page.is-run-loading #job-status::after,
  .job-progress.is-running li.is-active .job-progress-track::after {
    animation: none;
  }
}

@media (max-width: 680px) {
  .job-progress.has-active-loop {
    padding-top: 0.75rem;
  }

  .job-progress-loop {
    position: static;
    justify-content: flex-start;
    width: fit-content;
    max-width: 100%;
    margin-top: 0.5rem;
  }

  .job-progress-loop-arc {
    display: none;
  }
}

.footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  padding-top: 2rem;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 460;
  letter-spacing: -0.0025rem;
  line-height: 1.25rem;
}

.footer a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 0.1rem 0;
  transition: color 0.18s ease, opacity 0.18s ease;
}

.footer a::before {
  pointer-events: none;
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  border-radius: 2px;
  background: var(--line-strong);
  transition: background 0.18s ease, transform 0.18s ease;
}

.footer a:hover {
  color: var(--ink);
}

.footer a:hover::before {
  background: var(--line-strong);
  transform: translateY(-0.5px);
}

.footer-commit {
  margin-left: auto;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.75rem;
  letter-spacing: 0;
  color: var(--muted);
}

site-footer {
  display: block;
}

::selection {
  color: var(--selection-color);
  background: var(--selection-bg);
}

::-moz-selection {
  color: var(--selection-color);
  background: var(--selection-bg);
}

:focus-visible {
  outline: 2px solid var(--focus-color);
}
